Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

auto login from desktop shortcut

Status
Not open for further replies.

malagash

Technical User
Aug 29, 2006
252
CA
I don't know if this is possible but I thought if anyplace had an answer this would be it.

I have several desktop shortcuts to various admin websites where I must enter a UN and PW.

IE7 remembers UNames but I have to enter the password everytime. I am a one man office on a computer that is never accessed by anyone else (not even the wife).

Can I format the website's address in the desktop shortcut to include the UName and PWord so I am logged in when I click on it?

TIA
 
In short, no. Different websites use different authentication mechanisms. For security, it's beginning to be more common to use techniques that even prevent the browser from being able to 'remember' your password in a login form. This sounds like what you are seeing. You could take a look at Internet Options, Content tab, Autocomplete Settings button to make sure the 'prompt to remember passwords' option is set, but it won't help if the site is configured to prevent this.
 
Hi

Smah is right, the browser's form autocompletion is easy to be fooled by dynamically generated pages. But FireFox with GreaseMonkey extension has more chances.

A basic user script to log in to a site would look like this :
Code:
// ==UserScript==
// @name           [green][i]Log in to Example[/i][/green]
// @namespace      [green][i][URL unfurl="true"]http://example.com/[/URL][/i][/green]
// @description    [green][i]Automatically logs in to the Example site.[/i][/green]
// @include        [green][i][URL unfurl="true"]http://tek-tips.com/login.htm[/URL][/i][/green]
// @include        [green][i][URL unfurl="true"]http://www.tek-tips.com/login.htm[/URL][/i][/green]
// ==/UserScript==

(function() {

document.[green][i]loginForm[/i][/green].[green][i]usernameField[/i][/green].value='[green][i]the username[/i][/green]';
document.[green][i]loginForm[/i][/green].[green][i]passwordField[/i][/green].value='[green][i]the password[/i][/green]';
document.[green][i]loginForm[/i][/green].submit();

}) ();
While the user script is execute in the given pages context, it has full access to its structure and has good chances to find the [tt]form[/tt] and the [tt]input[/tt]s even if they are randomly renamed each time the page is generated.

Feherke.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top