batch script

Archived from groups: microsoft.public.win2000.general,microsoft.public.win2000.group_policy,microsoft.public.win2000.ras_routing,microsoft.public.win2000.setup,microsoft.public.windows.server.general (More info?)

Hi

Since we implemented VPN some of our users wants to acces company shared
folder from their home computers.
So I'm wondering if it is possible to use a batch script to map shares from
server to a user who's computer is not part of a local company domain.
I set-up the following script:
net use x: \\server\docs /user:domainname\username
but user always needs to enter password for a 'username'. Is it possible to
include password in script so that users will only need to run batch file
without entering any password and get maped drivers on local computer? Or is
any other way to do this?

Thank you all in advance
Regards
Miha
6 answers Last reply
More about batch script
  1. Archived from groups: microsoft.public.win2000.general,microsoft.public.win2000.group_policy,microsoft.public.win2000.ras_routing,microsoft.public.win2000.setup,microsoft.public.windows.server.general (More info?)

    See attached script - It maps drives depending on user name or all users,
    removes mappings, and sets registry keys.

    HTH

    "Miha" <miha.bernik@isg.si> wrote in message
    news:%232tmVYRcFHA.3184@TK2MSFTNGP15.phx.gbl...
    >
    > Hi
    >
    > Since we implemented VPN some of our users wants to acces company shared
    > folder from their home computers.
    > So I'm wondering if it is possible to use a batch script to map shares
    > from
    > server to a user who's computer is not part of a local company domain.
    > I set-up the following script:
    > net use x: \\server\docs /user:domainname\username
    > but user always needs to enter password for a 'username'. Is it possible
    > to
    > include password in script so that users will only need to run batch file
    > without entering any password and get maped drivers on local computer? Or
    > is
    > any other way to do this?
    >
    > Thank you all in advance
    > Regards
    > Miha
    >
    >
    >
    >


    begin 666 map.vbs
    M3W!T:6]N($5X<&QI8VET#0I/;B!%<G)O<B!297-U;64@3F5X= T*#0I$:6T@
    M;V)J3F5T=V]R:RP@;V)J1')I=F5S+"!R=&Y#;W5N="P@5U-(4VAE;&P-"D-O
    M;G-T($9O<F-E4F5M;W9E(#T@5')U90T*0V]N<W0@57!D871E4')O9FEL92 ]
    M(%1R=64-"@T*"5-E="!O8FI.971W;W)K(#T@0W)E871E3V)J96-T*")74V-R
    M:7!T+DYE='=O<FLB*0T*"5-E="!O8FI$<FEV97,@/2!O8FI.971W;W)K+D5N
    M=6U.971W;W)K1')I=F5S#0H-"D9O<B!R=&Y#;W5N=" ](# @5&\@;V)J1')I
    M=F5S+D-O=6YT("T@,2!3=&5P(#(-"@E)9B!.;W0@;V)J1')I=F5S+DET96TH
    M<G1N0V]U;G0I(#T@(B(@5&AE;@T*"0EO8FI.971W;W)K+E)E;6]V94YE='=O
    M<FM$<FEV92!O8FI$<FEV97,N271E;2AR=&Y#;W5N="DL($9O<F-E4F5M;W9E
    M+"!5<&1A=&50<F]F:6QE#0H)16YD($EF#0I.97AT#0H);V)J3F5T=V]R:RY-
    M87!.971W;W)K1')I=F4@(E,Z(BP@(EQ<>'AX>'AX>'AX>%Q%)"(L(%5P9&%T
    M95!R;V9I;&4-"@T*4V5L96-T($-A<V4@;V)J3F5T=V]R:RY5<V5R3F%M92 -
    M"@E#87-E(")U<V5R;F%M93$B#0H)"6]B:DYE='=O<FLN36%P3F5T=V]R:T1R
    M:79E(")7.B(L(")<7'AX>'AX>'AX>'A<0R0B+"!5<&1A=&50<F]F:6QE+" B
    M061M:6YI<W1R871O<B(-"@D)#0H)0V%S92 B=7-E<FYA;64R(@T*"0EO8FI.
    M971W;W)K+DUA<$YE='=O<FM$<FEV92 B3SHB+" B7%QX>'AX>'AX>'AX7'-O
    M8VEA;"(L(%5P9&%T95!R;V9I;&4-"@D);V)J3F5T=V]R:RY-87!.971W;W)K
    M1')I=F4@(E8Z(BP@(EQ<>'AX>'AX>'AX>%Q087 B+"!5<&1A=&50<F]F:6QE
    M#0H)"6]B:DYE='=O<FLN36%P3F5T=V]R:T1R:79E(")9.B(L(")<7'AX>'AX
    M>'AX>'A<1493(BP@57!D871E4')O9FEL90T*"0EO8FI.971W;W)K+DUA<$YE
    M='=O<FM$<FEV92 B6CHB+" B7%QX>'AX>'AX>'AX7%)"0U)E<&]R=',B+"!5
    M<&1A=&50<F]F:6QE#0I%;F0@4V5L96-T#0H)4V5T(&]B:D1R:79E<R ]($YO
    M=&AI;F<-"@E3970@;V)J3F5T=V]R:R ]($YO=&AI;F<-"@E3970@5U-(4VAE
    M;&P@/2!74V-R:7!T+D-R96%T94]B:F5C="@B5U-C<FEP="Y3:&5L;"(I#0H)
    M5U-(4VAE;&PN4F5G5W)I=&4@(DA+15E?3$]#04Q?34%#2$E.15Q33T945T%2
    M15Q-:6-R;W-O9G1<17AC:&%N9V5<0VQI96YT7$]P=&EO;G-<1'5M<'-T97)!
    M;'=A>7-/;B(L(#$L(")214=?1%=/4D0B#0H)5U-(4VAE;&PN4F5G5W)I=&4@
    M(DA+15E?0U524D5.5%]54T527%-O9G1W87)E7%!O;&EC:65S7$UI8W)O<V]F
    M=%Q396-U<FET>5Q#:&5C:T%D;6EN4V5T=&EN9W,B+" Q+" B4D5'7T173U)$
    M(@T*"5=32%-H96QL+E)E9U=R:71E(")(2T597TQ/0T%,7TU!0TA)3D5<4V]F
    M='=A<F5<4&]L:6-I97-<36EC<F]S;V9T7%-E8W5R:71Y7$-H96-K061M:6Y3
    M971T:6YG<R(L(#$L(")214=?1%=/4D0B#0H)4V5T(%=32%-H96QL(#T@3F]T
    $:&EN9P``
    `
    end
  2. Archived from groups: microsoft.public.win2000.general,microsoft.public.win2000.group_policy,microsoft.public.win2000.ras_routing,microsoft.public.win2000.setup,microsoft.public.windows.server.general (More info?)

    I'm not quite sure if I understand the question completely but let me try
    and help out if I can. When you VPN into your network basically the user has
    already logged in and has been authenticated. So from the "run line he can
    execute a command like net use x: \\servername\sharename\foldername. You can
    also create a batch file and copy it the users desktop so when he connects
    to the VPN they can execute the batch file and it should map them.


    "Miha" <miha.bernik@isg.si> wrote in message
    news:%232tmVYRcFHA.3184@TK2MSFTNGP15.phx.gbl...
    >
    > Hi
    >
    > Since we implemented VPN some of our users wants to acces company shared
    > folder from their home computers.
    > So I'm wondering if it is possible to use a batch script to map shares
    > from server to a user who's computer is not part of a local company
    > domain.
    > I set-up the following script:
    > net use x: \\server\docs /user:domainname\username
    > but user always needs to enter password for a 'username'. Is it possible
    > to include password in script so that users will only need to run batch
    > file without entering any password and get maped drivers on local
    > computer? Or is any other way to do this?
    >
    > Thank you all in advance
    > Regards
    > Miha
    >
    >
    >
    >
  3. Archived from groups: microsoft.public.win2000.general,microsoft.public.win2000.group_policy,microsoft.public.win2000.ras_routing,microsoft.public.win2000.setup,microsoft.public.windows.server.general (More info?)

    From: "Miha" <miha.bernik@isg.si>

    |
    | Hi
    |
    | Since we implemented VPN some of our users wants to acces company shared
    | folder from their home computers.
    | So I'm wondering if it is possible to use a batch script to map shares from
    | server to a user who's computer is not part of a local company domain.
    | I set-up the following script:
    | net use x: \\server\docs /user:domainname\username
    | but user always needs to enter password for a 'username'. Is it possible to
    | include password in script so that users will only need to run batch file
    | without entering any password and get maped drivers on local computer? Or is
    | any other way to do this?
    |
    | Thank you all in advance
    | Regards
    | Miha
    |

    You should strongly consider the security ramifications of such a scipt. Anyone who gets
    access to the computer could then gain access to the company and possibly compramise the
    company's data and security. That's what passwords are for, security. In addition anyone
    can read the script and now has both the Username and Password !

    What you want to do is NOT a good idea.

    --
    Dave
    http://www.claymania.com/removal-trojan-adware.html
    http://www.ik-cs.com/got-a-virus.htm
  4. Archived from groups: microsoft.public.win2000.general,microsoft.public.win2000.group_policy,microsoft.public.win2000.ras_routing,microsoft.public.win2000.setup,microsoft.public.windows.server.general (More info?)

    Thank's. Your script are just right what we needed.
    Regards
    Miha

    "JHP" <goawayspam@GFY.com> je napisal v sporoèilo
    news:OmHhJcScFHA.1152@tk2msftngp13.phx.gbl ...
    >
    > See attached script - It maps drives depending on user name or all users,
    > removes mappings, and sets registry keys.
    >
    > HTH
    >
    > "Miha" <miha.bernik@isg.si> wrote in message
    > news:%232tmVYRcFHA.3184@TK2MSFTNGP15.phx.gbl...
    >>
    >> Hi
    >>
    >> Since we implemented VPN some of our users wants to acces company shared
    >> folder from their home computers.
    >> So I'm wondering if it is possible to use a batch script to map shares
    >> from
    >> server to a user who's computer is not part of a local company domain.
    >> I set-up the following script:
    >> net use x: \\server\docs /user:domainname\username
    >> but user always needs to enter password for a 'username'. Is it possible
    >> to
    >> include password in script so that users will only need to run batch file
    >> without entering any password and get maped drivers on local computer? Or
    >> is
    >> any other way to do this?
    >>
    >> Thank you all in advance
    >> Regards
    >> Miha
    >>
    >>
    >>
    >>
    >
    >
    >
  5. Archived from groups: microsoft.public.win2000.general,microsoft.public.win2000.group_policy,microsoft.public.win2000.ras_routing,microsoft.public.win2000.setup,microsoft.public.windows.server.general (More info?)

    Yes, but a VPN users only log's into our corporate network and not into
    local domain, so he needs to type his domain username and password to access
    resources on domain server. Or am I wrong?
    Regards
    Miha

    "AllenM" <allen.miyake@gmail.com> je napisal v sporoèilo
    news:e1PmYgScFHA.3492@TK2MSFTNGP14.phx.gbl ...
    >
    >
    > I'm not quite sure if I understand the question completely but let me try
    > and help out if I can. When you VPN into your network basically the user
    > has already logged in and has been authenticated. So from the "run line he
    > can execute a command like net use x: \\servername\sharename\foldername.
    > You can also create a batch file and copy it the users desktop so when he
    > connects to the VPN they can execute the batch file and it should map
    > them.
    >
    >
    > "Miha" <miha.bernik@isg.si> wrote in message
    > news:%232tmVYRcFHA.3184@TK2MSFTNGP15.phx.gbl...
    >>
    >> Hi
    >>
    >> Since we implemented VPN some of our users wants to acces company shared
    >> folder from their home computers.
    >> So I'm wondering if it is possible to use a batch script to map shares
    >> from server to a user who's computer is not part of a local company
    >> domain.
    >> I set-up the following script:
    >> net use x: \\server\docs /user:domainname\username
    >> but user always needs to enter password for a 'username'. Is it possible
    >> to include password in script so that users will only need to run batch
    >> file without entering any password and get maped drivers on local
    >> computer? Or is any other way to do this?
    >>
    >> Thank you all in advance
    >> Regards
    >> Miha
    >>
    >>
    >>
    >>
    >
    >
    >
  6. Archived from groups: microsoft.public.win2000.general,microsoft.public.win2000.group_policy,microsoft.public.win2000.ras_routing,microsoft.public.win2000.setup,microsoft.public.windows.server.general (More info?)

    Yes you're right, but our boss (he always want impossible) wan't to use this
    in the most easy way as possible - without typing any additional usernames
    and password.
    But as you have said, I'm really thinking of just give him a script that
    maps net drivers and he'll need to type his username and password manualy
    because of the security reasons.
    Regards
    Miha


    "David H. Lipman" <DLipman~nospam~@Verizon.Net> je napisal v sporoèilo
    news:uJFqesScFHA.1448@TK2MSFTNGP14.phx.gbl ...
    >
    > From: "Miha" <miha.bernik@isg.si>
    >
    > |
    > | Hi
    > |
    > | Since we implemented VPN some of our users wants to acces company shared
    > | folder from their home computers.
    > | So I'm wondering if it is possible to use a batch script to map shares
    > from
    > | server to a user who's computer is not part of a local company domain.
    > | I set-up the following script:
    > | net use x: \\server\docs /user:domainname\username
    > | but user always needs to enter password for a 'username'. Is it possible
    > to
    > | include password in script so that users will only need to run batch
    > file
    > | without entering any password and get maped drivers on local computer?
    > Or is
    > | any other way to do this?
    > |
    > | Thank you all in advance
    > | Regards
    > | Miha
    > |
    >
    > You should strongly consider the security ramifications of such a scipt.
    > Anyone who gets
    > access to the computer could then gain access to the company and possibly
    > compramise the
    > company's data and security. That's what passwords are for, security. In
    > addition anyone
    > can read the script and now has both the Username and Password !
    >
    > What you want to do is NOT a good idea.
    >
    > --
    > Dave
    > http://www.claymania.com/removal-trojan-adware.html
    > http://www.ik-cs.com/got-a-virus.htm
    >
    >
    >
Ask a new question

Read More

Microsoft Servers Windows