Thread: Win User Managment

  1. #1
    Registered User (TNT)'s Avatar
    Join Date
    Aug 2001
    Location
    UK
    Posts
    339

    Win User Managment

    Hey,

    I am planning on making some networking software like RM with printer managment/customizable security options e.t.c. I am working with some mates on this and it will be designed for win2k/xp.

    I need however to learn a little first. Is it very hard to manage users? e.g creating/deleteing/changing password/banning/unbanning e.t.c. If anyone could like provide me some source code of a user manager.

    Thanks for any help/pointers,
    TNT
    TNT
    You Can Stop Me, But You Cant Stop Us All

  2. #2
    Just one more wrong move. -KEN-'s Avatar
    Join Date
    Aug 2001
    Posts
    3,227
    I'd imagine that all you'd have to do is create a small database or write a linked list to disk...
    ex:

    Code:
    struct user{
        char name[20] //Username
             pwd[20]; //Password
        BOOL banned;  //Are they banned?
        struct user *next; //Pointer to next user node in list
    };
    And just do everything like a normal linked list..

  3. #3
    Registered User (TNT)'s Avatar
    Join Date
    Aug 2001
    Location
    UK
    Posts
    339
    Hey thanks,

    I need one more bit of info.

    Once i have verified that the user and pass are ok, i need to load up the desktop.

    Ideally i would like to load up a user folder which will be the same as win2ks stored here: c:\doucments and settings\username

    So basically i need to do what win2k logon does check the user & pass which i can now do, and then load up the profile from the documents and settings folder.

    Can anyone help?


    Thanks
    TNT
    TNT
    You Can Stop Me, But You Cant Stop Us All

  4. #4
    Just one more wrong move. -KEN-'s Avatar
    Join Date
    Aug 2001
    Posts
    3,227
    Question: If this is for 2k/NT/XP don't they already DO the whole desktop thing? You don't have to do anything...just let that carry on its default programming. You're just doing network logons.


    But anyhow, if you look in that foler there's a file called desktop.ini that you'll have to load, I think. (It's in the folder Local Settings)

  5. #5
    ‡ †hë Ö†hÈr sîÐè ‡ Nor's Avatar
    Join Date
    Nov 2001
    Posts
    299
    I read about switching the curent desktop here
    http://msdn.microsoft.com/library/en...insta_990z.asp

    But I just looked at it and it said that the link was broken.
    If it's microsoft. It's f%3®ked up

  6. #6
    Registered User (TNT)'s Avatar
    Join Date
    Aug 2001
    Location
    UK
    Posts
    339
    Hey thanks, but i have no desktop.ini in my docs and settings folder.

    Basically i am making my own custom login box. That checks it with a database if the pass is correct i need to load up the desktop and other settings.

    So what i need to know is how to make my proggy load before the xp shell login box.

    Then to load up the user profile and everything?.

    I may be approcing this the wrong way, i just need my own custom login box to check the user and pass and then load up the profile from the docs and settings folder.

    If you can recommend a better way then thanks.

    Sorry ive been alittle vague.

    Cheers,
    TNT
    TNT
    You Can Stop Me, But You Cant Stop Us All

  7. #7
    Just one more wrong move. -KEN-'s Avatar
    Join Date
    Aug 2001
    Posts
    3,227
    Documents and Settings/Username/Local Settings/Desktop.ini

  8. #8
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Posts
    5,793
    Originally posted by (TNT)

    So what i need to know is how to make my proggy load before the xp shell login box.
    Novell does this and replaces the standard WinLogon box......

    I can only assume it is done via a service as it has to run while no users are logged on (services can run under a special system account)........

    I cant offer much more help on this though......

  9. #9
    Registered User
    Join Date
    May 2002
    Posts
    132
    I can't really help with you getting your program to run prior to Win2k's logon box, however, I can suggest that what you do is store a "copy" of the desktop that the user has setup under their account. Or create a file that lists what was on the desktop. If you store a "copy" of the desktop, then simply delete everything that was on the desktop (first keeping a backup of it under the "default" user if its that, or save it under the proper user folder). Then copy the new user's desktop folder to the actual desktop.

    If you go the way with a file, use a .ini file. Have a section for [Shortcuts] and have a list of all the shortcuts under there. And have another section for [Files] that lists all the files that were on the desktop. Then when you go to recreate the desktop, copy the files listed under [Files] to the desktop (you probably would have to save these under the user's desktop directory or something). And then create shortcuts on the desktop for each shortcut listed under [Shortcuts]. This may be the way that desktop.ini works, not sure. Never really messed around with it.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Style Points
    By jason_m in forum C Programming
    Replies: 4
    Last Post: 05-28-2008, 06:15 AM
  2. Replies: 4
    Last Post: 04-03-2008, 09:07 PM
  3. Add/Delete Remotely a user
    By Scarvenger in forum Windows Programming
    Replies: 5
    Last Post: 03-24-2008, 08:36 AM
  4. ~ User Input script help~
    By indy in forum C Programming
    Replies: 4
    Last Post: 12-02-2003, 06:01 AM
  5. Stopping a user from typeing.
    By knave in forum C++ Programming
    Replies: 4
    Last Post: 09-10-2001, 12:21 PM