A corporation is just a group of people. It's not possible for a corporation to be ethical or unethical, a corporation doesn't have a soul or a conscience.
It's possible for specific people inside a corporation to behave in unethical ways. However, the definition of maximizing shareholder value is not simply "make the stock price as high as possible in the short term." It's perfectly possible for executives in a corporation to take the high road as the optimal strategy for maximizing shareholder value.