Every day, elected officials like those on this stage, but also all across the nation, devote themselves to improving our communities and our country. But all too often we've seen a politics where compromise is rejected as a dirty word, and policies are driven by special interests rather than the national interest. And that breeds a cynicism that threatens our democracy.

Every day, our civil servants do their jobs with professionalism -- protecting our national security and delivering the services that so many Americans expect. But as we've seen again in recent days, it only takes the misconduct of a few to further erode the people's trust in their government. That's unacceptable to me, and I know it's unacceptable to you.

And against this backdrop, what I said here four years ago remains true today: Our military remains the most trusted institution in America. When others have shirked their responsibilities, our Armed Forces have met every mission we've given them. When others have been distracted by petty arguments, our men and women in uniform come together as one American team.

And yet, we must acknowledge that even here, even in our military, we've seen how the misconduct of some can have effects that ripple far and wide. In our digital age, a single image from the battlefield of troops falling short of their standards can go viral and endanger our forces and undermine our efforts to achieve security and peace. Likewise, those who commit sexual assault are not only committing a crime, they threaten the trust and discipline that make our military strong. That's why we have to be determined to stop these crimes, because they've got no place in the greatest military on Earth.

So, Class of 2013, I say all this because you're about to assume the burden of leadership. As officers, you will be trusted with the most awesome of responsibilities -- the lives of the men and women under your command. And when your service is complete, many of you will go on to help lead your communities, America's companies. You will lead this country. And if we want to restore the trust that the American people deserve to have in their institutions, all of us have to do our part. And those of us in leadership -- myself included -- have to constantly strive to remain worthy of the public trust.

As you go forward in your careers, we need you to carry forth the values that you've learned at this institution, because our nation needs them now more than ever.

We need your Honor -- that inner compass that guides you, not when the path is easy and obvious, but when it's hard and uncertain; that tells you the difference between that which is right and that which is wrong. Perhaps it will be a moment when you think nobody is watching. But never forget that honor, like character, is what you do when nobody is looking. More likely it will be when you're in the spotlight, leading others --the men and women who are looking up to you to set an example. Never ask them to do what you don't ask of yourself. Live with integrity and speak with honesty and take responsibility and demand accountability.

We need your Honor and we need your Courage -- yes, the daring that tells you to move toward danger when every fiber of your being says to turn the other way. But even more than physical courage, we need your moral courage -- the strength to do what's right, especially when it's unpopular. Because at the end of the day and at the end of your career, you want to look in the mirror and say with confidence and with pride, I fulfilled my oath; I did my duty; I stayed true to my values.

We need your Honor and Courage, and we need your Commitment -- that sense of purpose that says I will try even harder, I will do even better in what I expect of myself, in the way I interact with others, including those of different backgrounds. It's no accident that our military is the most respected institution in America -- and one of the most diverse institutions in America. So recognize the dignity in every human being. Treat one another with respect. Remember that when we harness the talents of every man and every woman from every race and every religion and every creed, no nation can ever match us.

And, finally, we need your Resolve -- the same spirit reflected in your class motto: "Surrender to Nothing." If you seek an example, you don't need to look far, because not long ago, two midshipmen sat where you sat -- from the Class of 2006 -- and they inspire us today.

Here at the Academy, Brad Snyder was the captain of the swim team. He deployed to Afghanistan, and while rushing to the aid of his teammates, he stepped on an IED and lost both his eyes. With the support of family and friends, Brad learned to feel his way and move again. And before long, he was back in the swimming pool, where he said "I'm free." Then, just one year later, Brad competed at the London Paralympics and won three medals, including two golds.

And when Michelle and I welcomed our U.S. Olympians to the White House, Brad joined us -- standing tall, right in front. And, he said, "Overcoming adversity is a decision. You can let that beat you, or you can make the decision to move forward."

Here at the Academy, Matt Lampert was on the rowing team. He deployed to Afghanistan with his Marine special ops team. And as they entered a compound, an IED exploded and Matt lost both his legs. He endured a long and painful recovery. But with his new legs, he learned to walk again. He practiced, he trained, and then he passed his physical tests and deployed to Afghanistan again -- a double amputee, back in the fight.

And Matt recently completed his tour. He is back home and is looking ahead to many years of service. Reflecting on his journey -- his mission to return to his unit -- he said he was determined, "however long it was going to take."

So Class of 2013, I cannot promise you a life of comfort and ease, for you have chosen an ancient path -- the profession of arms -- which carries all the perils of our modern world. And just as classes before you could not know that they would find themselves at Coral Sea or Midway or Fallujah or Helmand, we cannot know sitting here today where your service will carry you.

But I do know this. As you say farewell to Bancroft Hall, as you make your way down Stribling Walk one last time, you're becoming the newest link in a storied chain. As I look into your eyes today, I see the same confidence and the same professionalism, the same fidelity to our values of those who've served before you -- the Jones and Nimitz and Lejeune and Burke, and, yes, the Snyder and the Lampert -- Americans who surrendered to nothing.

And I'm absolutely confident that you will uphold the highest of standards, and that your courage and honor and your commitment will see us through, and that you will always prove yourselves worthy of the trust our nation is placing in you today.

So, congratulations, Class of 2013. (Applause.) God bless our Navy, and God bless our Marine Corps. (Applause.) God bless our Armed Services. God bless these United States of America. (Applause.)