EX-5 2 exh51.txt LEGAL OPINION AND CONSENT Exhibit 5.1 May 28, 2008 L.B. Foster Company 415 Holiday Drive Pittsburgh, Pennsylvania 15220 Re: 2006 Omnibus Incentive Plan, as Amended and Restated March 6, 2008 (the "Plan") 500,000 Shares of Common Stock ------------------------------ Ladies and Gentlemen: We have acted as your counsel in connection with the registration with the Securities and Exchange Commission (the "Commission") of 500,000 shares of your Common Stock, $.01 par value per share (the "Shares"), that may be acquired under the Plan by participants in the Plan. In that connection, we have examined originals or copies certified or otherwise identified to our satisfaction of such documents, corporate records and other instruments as we have deemed necessary or appropriate for the purposes of this opinion. Based on the foregoing, we are of the opinion that the Shares, when issued or delivered, and paid for as may be required, in accordance with the provisions of the Plan, will have been validly issued and will be fully paid and nonassessable. In rendering this opinion we have of course assumed that the certificates evidencing the Shares will be properly executed and authenticated. We consent to the filing of this opinion with the Commission as an exhibit to Post-Effective Amendment No. 1 to the Registration Statement on Form S-8 for registration of the Shares under the Securities Act of 1933, as amended, and to the reference to us under "LEGAL OPINION" in the amended Prospectus included therein. Very truly yours, /s/ Buchanan Ingersoll & Rooney PC ---------------------------------- BUCHANAN INGERSOLL & ROONEY PC