WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

Networks - Servers
plus
plus
plus
plus
plus
plus
plus

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

The Net Use Command and Passing a Password

Keywords:     password encryption

Question:

I've added an NT command file to the end of my login script. The command file contains a program that can sense when RAS is being used to complete a dial-up connection to the domain at work from a remote location. If this is the case, a series of net use commands inside the command file are executed that connect me to the NT workstations in my office.

This all works fine, except that I must include my network login password as part of the net use command. This is a security breach of sorts. I want to pass an encrypted string to a WB program, have it translate the string into my password, then execute the net use commands. I've got everything done except a nice clean way to get the net use commands executed.

Answer:

How about:

RunShell(environment("ComSpec"),"/c net use \\whatever\share pwd1 && net use \\second\share pwd2 && ....',...)
All inside the .EXE, no .BAT files, and one command. If it's too long, you could create a variable containing the second param instead.
Article ID:   W13491
Filename:   Net Use Command and Passing Passwords.txt
File Created: 2001:01:26:15:06:06
Last Updated: 2001:01:26:15:06:06