473,757 Members | 9,463 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Could python help to create hundreds of NT accounts ?

Not really being a programmer, but thinking that there must be a
better way than to do it by hand and havign a friend who likes to tell
me that python is the answer to everything I am hoping.

I have two NT4 domains, and I need to create instances of all the
account names from one in the other.

All accounts need to have identical group memberships to each other,
and different passwords.

I have in mind some program that will automatically generate a
password (I already wrote one of those) and write out to a csv file
username,passwd thgat we can refer to when the clients need to log
into their new account.

Because there are about 1600 accounts, I'd really love it if there
was a way to do this with a script.

I bought the Dietel How to Program Python book in an attempt to learn
this language, but it doesn't seem to have much in it related to NT
stuff like this.

IF anyone has done anything like this, or knows how, I'd love to
hear from you.

Cha!

nemir (at) hot mail dot com
Jul 18 '05 #1
3 1310
The Pywin32 windows extensions
( http://sourceforge.net/projects/pywin32/ )
contain functions to do just about any
kind of NT account management, the win32net
module in particular.
Mark Hammond's book Python Programming on
win32 is a very practical reference for this kind
of task.
hth
Roger

"google account" <my******@yahoo .com> wrote in message
news:e8******** *************** ***@posting.goo gle.com...
Not really being a programmer, but thinking that there must be a
better way than to do it by hand and havign a friend who likes to tell
me that python is the answer to everything I am hoping.

I have two NT4 domains, and I need to create instances of all the
account names from one in the other.

All accounts need to have identical group memberships to each other,
and different passwords.

I have in mind some program that will automatically generate a
password (I already wrote one of those) and write out to a csv file
username,passwd thgat we can refer to when the clients need to log
into their new account.

Because there are about 1600 accounts, I'd really love it if there
was a way to do this with a script.

I bought the Dietel How to Program Python book in an attempt to learn
this language, but it doesn't seem to have much in it related to NT
stuff like this.

IF anyone has done anything like this, or knows how, I'd love to
hear from you.

Cha!

nemir (at) hot mail dot com

Jul 18 '05 #2
> Because there are about 1600 accounts, I'd really love it if there
was a way to do this with a script.


Also google for tim golden wmi

It is very helpfull to deal with windows accounts
Jul 18 '05 #3
I needed to do something like this but with a little
twist. Client wanted to put user information in a
database and have servers add users to the domain
on the fly.

I wrote an NT service that:

1) Wakes up, scans database for new or changed users
2) Adds new users, removes deleted users, disables
users that are marked as disabled
3) Changes rights, password, etc. for changed users
4) Put some information in comment field that is used
by an application on the server.
5) Updates WTS information for this user to have a
default program run upon login.
6) Goes back to sleep.

I installed this on several servers and when I add
user to DB it appears in a few minutes on all servers.
Seems to work fine. I used Mark Hammond's Python
Programming on Win32 quite extensively, but it took
several weeks to track everything I needed down.
If you are interested, we could discuss a short
term consulting agreement to address your specific
problem.

FYI, Larry

"google account" <my******@yahoo .com> wrote in message
news:e8******** *************** ***@posting.goo gle.com...
Not really being a programmer, but thinking that there must be a
better way than to do it by hand and havign a friend who likes to tell
me that python is the answer to everything I am hoping.

I have two NT4 domains, and I need to create instances of all the
account names from one in the other.

All accounts need to have identical group memberships to each other,
and different passwords.

I have in mind some program that will automatically generate a
password (I already wrote one of those) and write out to a csv file
username,passwd thgat we can refer to when the clients need to log
into their new account.

Because there are about 1600 accounts, I'd really love it if there
was a way to do this with a script.

I bought the Dietel How to Program Python book in an attempt to learn
this language, but it doesn't seem to have much in it related to NT
stuff like this.

IF anyone has done anything like this, or knows how, I'd love to
hear from you.

Cha!

nemir (at) hot mail dot com

Jul 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1865
by: jiing | last post by:
I want to use web interface to do : 1. user accounts management (adminstration side) 2. personal password management (user side) 3. create actual accounts under windows 2003 server( for handling share folder) about 1&2, it can be solved by LDAP, phpldapadmin, phpGeneral, but 3, I do not know how to deal with I want to ask is there any web interface tools or method to solve problem 3?i.e., "Is there any web interface tools that can...
3
86477
by: Kay Lee | last post by:
Hi, I looked up os module to find out some method to move and copy files in python, but os doesn't support such methods. Is there any way to move & copy files in python? Thanks in adv.
9
2768
by: Francois Fernandes | last post by:
Hi! Is it possible to easyly integrate c++ classes in python? I don't want to use boost c++. Does anyone know how to start or where to find documentation for this? thx
4
6131
by: anders | last post by:
Hi! To create a new Windows account I use this code: const int UF_PASSWD_CANT_CHANGE = 0x0040; const int UF_DONT_EXPIRE_PASSWD = 0x10000; DirectoryEntry obDirEntry = new DirectoryEntry("WinNT://" + domain); DirectoryEntries entries = obDirEntry.Children; DirectoryEntry obUser = entries.Add(username, "User"); obUser.Properties.Add(name);
0
1540
by: joey.powell | last post by:
We have a website with hundreds of users. The users have each registered with their email addresses and other information, and these are stored in a Microsoft SQL Server database. The user accounts in the website are not in Active Directory, as the website uses Forms Authentication. We need to be able to query the MS SQL server database for all email addresses and then programmatically (C#) create a distribution list entry in our...
71
3345
by: Jack | last post by:
I understand that the standard Python distribution is considered the C-Python. Howerver, the current C-Python is really a combination of C and Python implementation. There are about 2000 Python files included in the Windows version of Python distribution. I'm not sure how much of the C-Python is implemented in C but I think the more modules implemented in C, the better performance and lower memory footprint it will get. I wonder if it's...
5
1654
by: geoffbache | last post by:
Hi all, I have a small python script that doesn't depend on anything except the standard interpreter. I would like to convert it to a small .exe file on Windows that can distributed alone without introducing additional dependencies. I need to assume, because of other python scripts, that anyone using this has python installed anyway so I hoped it would be possible to do this. (Why I want to do this is a bit involved but I can explain if...
6
1870
by: Frantisek Malina | last post by:
What is the best way to do the regular bash commands in native python? - create directory - create file - make a symlink - copy a file to another directory - move a file - set permissions I need to write a program that creates real application/FTP accounts
1
5454
by: Erick Perez - Quadrian Enterprises, S.A. | last post by:
Hi, I have a MS Windows AD domain, and have one OU with more tan 1000 users objects. When I try to read it, I hit the 1000 limit of AD while returning objects, so I'm asking for advice as to how to read them. Here is my actual code, it is not the cleanest as I am learning python. Suggestions are welcomed :) Runnig this script on RedHat 5.x with "python zimbra2.py" returns: {'info': '', 'desc': 'Size limit exceeded'}
0
9298
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9906
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8737
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7286
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6562
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5172
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5329
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3829
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2698
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.