views:

69

answers:

0

I have an application that prints the contents of a URL (to a physical printer) at a certain point. I want this to happen automatically and without further user input. I am using SWT to load the URL into an SWT browser (that works int he background only - it is not visible) and print. The sole problem at this point is that the server wants to authorize me, popping up a dialog for a username/password. I've been able to get around this by putting the credentials in the URL (http://username:[email protected]/resource) but I imagine there must be a better way to do this.

For clarification, this is an authorization dialog, not an authentication dialog. I am aware of addAuthenticationListener, but this is never called since I am trying to authorize, not authenticate.