EX-23 4 new232.txt EXHIBIT 23.2 Consent of Independent Registered Public Accounting Firm We consent to the reference to our firm under the caption "Experts" in the Post-Effective Amendment No. 1 on Form S-8 to the Registration Statement on Form S-4 of Valero Energy Corporation and subsidiaries for the registration of 7,109,195 shares of its common stock and to the incorporation by reference therein of our report dated March 11, 2004, with respect to the consolidated financial statements of Valero Energy Corporation included in its Annual Report (Form 10-K) for the year ended December 31, 2004, filed with the Securities and Exchange Commission. /s/ Ernst & Young LLP San Antonio, Texas August 31, 2005