Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Unix Script to create NT accounts?

by Marza (Vicar)
on Jul 10, 2002 at 18:32 UTC ( [id://180828]=perlquestion: print w/replies, xml ) Need Help??

Marza has asked for the wisdom of the Perl Monks concerning the following question:

As I mentioned in So you know Perl; but do you know programming? I was adding some functionality to the unix account creator script as well as re-writing some of the "extraneous" work that it did(ie 15 loops down to 5)

One aspect of the script was to create an NT account on your domain. The original author, set up a Telnet server on the domain controller and the Unix script would telnet into it and run a script there.

The one thing I don't like is the fact that he hard coded the account and the password!

I would like to eliminate the NT standalone script and be able to "feed" a routine to the domain controller.

Has anybody done something like this? Is there a better way or am I just being overly paranoid about security.

One person told me that XML should be able to do that? But from the preliminary scans I really don't see how>

Any suggestions on where to look would be appreciated

Replies are listed 'Best First'.
(wil) Re: Unix Script to create NT accounts?
by wil (Priest) on Jul 10, 2002 at 18:43 UTC
    Have you looked into the module Win32::NetAdmin available on CPAN? Specifically, look into the UserCreate function. Here's a snippet from the POD:

    UserCreate(server, userName, password, passwordAge, privilege, homeDir +, comment, flags, scriptPath) Creates a user on server with password, passwordAge, privilege, homeDi +r, comment, flags, and scriptPath.


    Take a look over the POD documentation, and if you need any assistance in implementing this in your code, just let us know.

    Cheers

    - wil

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://180828]
Approved by wil
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (4)
As of 2024-04-24 22:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found