Off the top of my head I am not sure how you can do that. Since you have two separate applications, there really isn't a built-in way to share authentication info.
You could modify the code to look for a username and pwd on the URL, but that violates best practices around handling passwords. Another idea is to create a SSL-encrypted web service method that takes in the user name and pwd and issues an authentication cookie, but I'm not sure what you do with the cookie (maybe forcing GSP to use use cookie-less mode, which passes cookies on the URL?)
I'll continue to ponder this and post again if I think of anything new. I bet there is a creative solution for this.
Roger Martin
Creator and Lead Developer of Gallery Server Pro