Add testing script for extauth
Make extauth script actually use the database