You can speak out, but if you do you should first resign your Commission. The President is Commander in Chief, and officers under his command should publicly support his orders, even if they privately disagree. If they cannot, they need to resign.
A soldier takes an oath to the Constitution not to the President. That being said, you are correct, if he’s got a problem with order, resign and take your gripes to the press and public.
McChrystal can do a lot more damage out of the military then he can in. A bunch of interviews and a good book will go a long way to take care of Zero.
So, what you are saying, in effect, is that the military should follow orders blindly, as they did in the German army in WWII, regardless of the legality or the harm the orders do to the military. Over and above what the Officer owes to the CIC is what he owes to his troops. He should have spoken directly to the President and if that failed then he has every right nay, a duty, to speak out openly against the President against what he sees as harmful orders and policies. He will most likely lose his job in doing so but the people will be warned.
BTW, I think McA should have gone ahead and bombed the crap out of North Korea and the Chinese troops screaming down towards the south as he proposed. Truman was wrong, as history has well proven. Korea's cease fire is the reason we had to fight in Vietnam.