BERLIN — After serving 15 years in a German prison for his role as an accomplice in the Sept. 11 terrorist attacks on the United States and being extradited last year to his native Morocco, Mounir el-Motassadeq was handed an envelope containing 7,000 euros in cash.

It was his prison wages — about $8,000 — including a monthly stipend.

Now, the German authorities are investigating what might have been a significant violation of the country’s foreign trade and payments law.

“When it comes to that money, we are looking into who gave exactly what instructions to whom,” Nana Frombach, a spokeswoman for the Hamburg district attorney’s office, said on Friday.

Ms. Frombach said investigators were scrutinizing who had authorized the payments to Mr. el-Motassadeq, a member of Al Qaeda and a friend of Mohamed Atta — one of the masterminds of the Sept. 11, 2001, attacks that killed thousands of people.