Based on what you want to do, you don't need to manually connect to the database but simply call the vB API externally from a different site that's on the same server.
Take a look at this blog on how to login to vB from an external site.
http://www.vbulletin.com/forum/blogs...n-your-website
It calls the user API to login and did not have to manually connect to vB database.