In a dynamically generated site (PHP, Python, pick your poison), 404 pages are normally handled dynamically to simply send a 404 header and display some error page on the URL that the user visited.
I'm wondering if a site has a large number of 404 pages and they for example, contain a significant number of links to help a visitor get to a useful part of the site, might a search engine see this as a cloaking of doorway pages?
I can't image search engines would generally punish you for having lots of 404s, you can't help people linking badly to you site but I can imaging they would punish you for cramming the 404 page with links.
As an extension of that. Is there any benefit of redirecting users to a single URL to display the 404 page, something like
http://www.domain.com/404? How would this affect SEO?