April 15, 200422 yr Does anyone know how I can customize WinPE to automatically logon to a network share? I need to execute a batch file to map drives to a network share and I want to store the user credentials in the winbom.ini.
April 16, 200422 yr The base process (shell) runs as a local system account, which doesn't have the ability to connect to a network as itself. WinPE can't join a domain, so you can't log in natively with a domain account. So I assume you're talking about mapping a drive as another user, rather than trying to run the shell as a network account.The NET USE command works like a champ for mapping network drives with alternate credentials, but if you feed it a password, it's executed in clear text. Syntax isNET USE X: \\server\share /u:domain\userid passwordYou could throw this in a CMD file - either in the one defined as the shell (MS WinPE) or called by the shell CMD file. That's a way to accomplish what you're asking if you're not trying to accomplish anything fancy. As far as storing the credentials in the winbom.ini file, you could write CMD shell script to parse the file and pull a value out of it, but - yecch. I don't like plain-text passwords.The most elegant way would be to embed a network attachment statement in a vbs script (Requires the OC2.bat in MSPE), then using SCRENC to encode it as a vbe file. Technically reversible encryption, but good enough to hide from most prying eyes.
Create an account or sign in to comment