NEW YORK – The younger brother and business partner of disgraced financier Bernard Madoff pleaded guilty Friday to charges he doctored documents for years, but he insisted he knew nothing about his brother’s historic Ponzi scheme and was “in total shock” when he found out about it.

An emotional Peter Madoff, 66, entered the plea in a deal that permits him to remain free on $5 million bail pending his Oct. 4 sentencing. He agreed not to contest a 10-year prison sentence and, several hours later, emerged from the courthouse into a rush of cameras and a car that awaited him.

“My family was torn apart as a result of my brother’s atrocious conduct,” he said. “I was reviled by strangers as well as friends who assumed that I knew about the Ponzi scheme.”

The plea to charges of conspiracy and falsifying records came in the same Manhattan courthouse where Bernard Madoff was led away in handcuffs in 2009 to serve a 150-year sentence.