The state ethics agency Wednesday slapped $270,000 in fines on two firms that figured prominently in the corruption trials of disgraced ex-Assembly Speaker Sheldon Silver and former state Senate Majority Leader Dean Skelos.

Powerhouse real estate firm Glenwood Management was slapped with a $200, 000 penalty for multiple violations on the state’s lobbying laws, the Joint Commission on Public Ethics announced.

Administration for the Professions was hit with $70,000 in fines.

Glenwood Management — headed by 102-year-old Leonard Litwin — was a key player in the pay-to-play corruption cases of both convicted felons Silver and Skelos.

Glenwood retained the property tax law firm of Goldberg & Iryami in 2012 and 2013 “knowing that the firm paid Speaker Silver a referral fee and that Speaker Silver performed no work in connection with the Goldberg firm’s services to Glenwood,” JCOPE said in the settlement agreement.

At the time, Glenwood, which operates two dozen buildings in Manhattan, was lobbying Silver on issues affecting the real estate industry.

Glenwood associates also recommended that an environmental technology firm, Ab Tech Industries, hire Skelos’ troubled son, Adam, as a consultant and also arranged for a title insurance company to pay a referral fee to Adam.

Glenwood admitted it violated the law by failing to submit lobbying registration and reports that spelled out its meetings with Skelos.

Executives of Administrators for the Professions hired Adam Skelos at the behest of his father, Dean Skelos, then the senate majority leader, as a program manager for $75,000 plus health benefits.

The firm later retained Adam Skelos as a $3,000 per month consultant — again at his father’s urging — after supervisors complained that Adam was mostly a no-show.

The lobbying act bars firms from offering or providing gifts to public officials, such as a job to Skelos’ son.

The firm and a client, Physicians Reciprocal, depended on Albany for medical malpractice insurance funding and legislation.

Both firms agreed to cooperate and provide evidence in related investigations.