Discussion Locked

Permission to change group members

0 helpful
55 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

After I changed and applied a few settings in a security template based on
the hisecweb template (I don't remember the exact changes), an ASP script
that uses ADSI stopped working.
The script changed group members of a new group (not a built in group).
Now the script returns an error message:

Active Directory error '80070005'
General access denied error
.asp, line

Does anyone know how to give a group of users (besides Administrators) the
permission to change group members?

The script runs as the user who logs on to an IIS 5.0 website on a Windows
2000 Server machine. The user is a member of the Users group (I would not
mind changing it to Power Users).

We tried logging on from the console to changegroups, but still did not
have permission unless we added the user to the Administrators group. I
tried applying the setup security template, but that did not help

My searching for the error number on the web did not reveal how to give the
access back.

Thank you for your help.

55 replies

by rkelly

To give the permission to change group membership you need to do the following.

Right click on either the Domain (if you want to change this for all groups) or the OU where you want to be able to change group membership, and select delegate control.

Add the users/groups you want to have the rights to the list of Selected Users or Groups, then select next. If you want you can just select the common task of Create,delete and manage groups - if you want to be more subtle you can create a custom delegation task. Do it for just Group objects, it is property specific and it is the Write MemberOf property.

Click on next and finish.

That is the degation done - your selected users and groups can now update memberships of groups.

by shanghai sam

This answer did not help because I do not have Active Directory installed, so I don't see how I can perform the steps.

by davidag

I do not have Active Directory installed, and I think that to follow your instructions I would have to have it installed. Sorry for not mentioning it before.

by rkelly

Now that I know AD isn't involved the answer should be straight forward. When you used the high security template on your computer, one of the things it does is remove all the users from the Local Power Users group.

Add the user that you wish to be able to do the update - assuming again that it is modifying purely local accounts - to the Local Power Users group this will give them the relevent access. Use Computer Management to do this task

by davidag

I added the users to the local Power Users account, but I still get an access denied error when I try to change someone's group membership.
I did notice that if I create a new Power User then create a group, that the new user may change membership to the new group, but the new user cannot change memberships to groups created before the user was created.
Thank you for response anyways.

by iancurtis

Think about what you just said, "an ASP script that uses ADSI stopped working." The error is also: Active Directory Error '80070005'

This has everything to do with the Active Directory whether you have it on this machine or not. If is using ADSI (Active Directory Service Interface), your scripting changes to the AD. And this is also where you error is. Even if this machine is not a Domain Controller it must be a member of a domain or you ADSI script would have nothing to communicate with. Leave your local users and groups alone and look to the Active Directory where the first reviewer said. Even if this machine is not a domain controller, the AD is the place to look. If you don't have the Admin tools installed on this machine(adminpak.msi on the cd), then sit down at the DC and do it.

The other alternative is to go through the hisecweb.inf line by line and reverse the settings on what looks to be relevant security changes. Then reapply that Reversed Template. Applying a different security template will not help in this case because it more than like has no entries for the change user authority.

IC

by davidag

The DC is an NT4 Server, so I don't see how I can make AD changes on it.
I will see about going through the hisecweb.inf, but I had applied it before the problem occurred and the system was working, so I don't think it is that template that is the problem. I think it is whatever changes that I made that I forgot (which is strange because I was trying to loosen the restrictions a bit).

by davidag

The machine is also not a Domain Controller, just a member server. The domain controller is an NT4 Server.

by rkelly

Right then one last go.

As a last ditch attempt you could add the user to Account Operators on the NT 4 Domain Controller this will let your account modify the membership of any group in your domain.

by shanghai sam

I think that will work, but I don't want the people who will log on to have access to the rest of the domain. They are only allowed to make changes to the data on part of the Win2K Server.

by esadacca

Don't overlook the obvious... Are you sure the user has been authenticated by the server? I've run into that pitfall far too many times!

If "Request.ServerVariables('LOGON_USER')" returns an empty string, then the user has NOT been authenticated, and the ADSI attempt will likely be made by "IUSR_servername", who probably doesn't have the appropriate access.

Here's some code to force an authentication:

sub ForceAuthentication()
dim i, intWhackLoc, str
if Request.ServerVariables("LOGON_USER") = "" Then
Response.Status = "401 access denied"
Response.End
end if
end sub

But why did it stop working? Maybe you had gone to a different page on the server that required an authentication. Then when you requested this script, the server saw you had already been authenticated, so ran the script with your permissions. If you hadn't authenticated at the other page, the server may have run the script as "IUSR_servername" and failed.

by davidag

The person running the website included a line to print out the name of the logged on user using
Request.ServerVariables("LOGON_USER")
, but it shows the correct user in the form of:
local_computer_name\username
instead of the IUSR_servername.

Thank you for your attempt.

by kenalmoore

By default Domain Admins and Enterprise Admins can only change user or group members.
To delegate control of a GPO to a user or group. Right click and go to properties of container, Group policy Tab,click properties, Security Tab, click Add (Selecta user of group), click OK, on permissions pane click Allow Read and Write.
Rules are user or group doesn't have control of GPO. Changes must be made on a Domain Controller (Window 2000. You cannot change the default containers Users, Computer or Built-In..
You mentioned you changed some settings before. It is very possible this created the problem!!! Your currently running a PDC with NT40. In my humble opinion, I would promote a BDC, take the PDC offline as back up. Use a Windows 2000 DNS server and DHCP servers seperately. Then upgrade the PDC to Windows 2000 and AD and DC.

by kenalmoore

Also, until you have Active Directory Adminstrators will only be able to change local policies not for the whole domain. I think that is understood.

by davidag

I don't know how to delegate control of a GPO if I do not have Active Directory installed on the machine.
I do think that the settings I changed created the problem, but I don't know how to undo what I did.
We will be upgrading our DC to Windows 2000 in the future, but I need to fix this problem before then.

by mike_mds

Any chance you could post or email me a screenshot of the local security settings on that machine (specifically the user rights assignment screen & security options screen?)

by shanghai sam

That is worth a shot. I don't know how to post to Tech Republic, so I will email them to you as an attachment.

by davidag

I have tried changing some settings on group policies, but it doesn't help: a power user is not allowed to change group membership in groups that were created after he or she was.
There must be a setting that I am missing, but I don't know what it is.

by Former member

Ah...create a new container for the group then make those membes admins of that container? Just a WAG...

by davidag

Don't I have to have AD installed to create containers? If not, how do I create a new containter. The computer does not have AD installed.

by kenalmoore

I have been watching the postings for this
troubling question you have.
In my humble opinion again. I read you have made changes and have run a scipt that changed group members. I think I would do a clean install and start over again, documenting each step of changes, one at a time to see what the results were. You have stated there is
"Active Directory error '80070005'
General access denied error
.asp, line "
Thats the indication, partner. Next, an ASP script that uses ADSI stopped working.
Well, kinda tells the story, don't you think.
To be blunt about it, Try reinstaling.
In the end you'll spend less time trying to fix it.

by davidag

I do think reinstalling windows will fix the problem, but the computer is a web and file server, so I am going to wait to do that last.
If no one gives a better answer and I decide it is time to reinstall, I will email you and you can repost your suggestion, and I will give you the points.

by wcraigmiles

The real problem is that you applied a security template that was based on Active Directory. Why are you running an ADSI script if you are not running AD? Open the hisecweb template and remove the security settings from the server. You also have applied security to certain parts of the registry. You will need to run regedt32 to fix that. Find the key controlling IIS proccesess.

It would be mch simpler if you had copied the exact setting in the template to a file and printed it before you applied it.

You best bet is a new copy of the server and registry. After the install, run a backup using MS's backup and get the system state date. Install IIS and get your system up and running properly. Then run the backup again and get thesystem state data again.

Before you apply any security template, copy the registry to a directory, and use backup dn get the system state info. This will allow you to back out any changes you made without reinstalling the entire server in the future.

by shanghai sam

We are running an ASP script that uses VBscript call the ADSI to access information about the users and group membership on the machine.
How can I remove the hisecweb security settings? I can see what the template sets things to, but I don't know how to undo the settings.
Where is the registry key that controls the IIS processes? I tried searching HKEY_LOCAL_MACHINE for IIS, but I did not see anything that looked like it affected the IIS processes.

by kenalmoore

Well, I will try again. I found something that may apply to your situation.
Check out the MS Knowledge Base article Q234926 and apply the 'inf' file for your server. I understand this loosens security restrictions.
If this does not work. Again, Clean install.
One other answer, do back up your system state after install server then again ater IIS. Do record all changes to security settings and profiles.

by kenalmoore

To import a security template, Go into Control Panel, open Local Security Policy, right click on Security Policy Settings, Import Policy. I think you should try the basicsv or setup security inf. This will modify your policy. The basicsv is default server policy.
Before doing that, go RUN, MMC and add the Security Configuration and Analysis snap-in.
Right click on the snap in and do 'Analyize computer Now'. Compare that with your current settings.
I hope this helps, it should reset all your setting back to default as originally installed. But no guarantee's.

by kenalmoore

Also, at RUN command line run MMC and add the Security Templetes and Security Configuration Analysis snap-ins.
On Security Analysis Configuration snap in. Right click and open/create a new data base. Then right click again, Run Analyze Computer now. You can view the log file. That will show up as red the problems. Double click on the Investigate. OK.
From the Security Configuration Analysis snap in, right click again, Configure computer now on the menu.
Also, instead of running the configuration analysis. Open the control panel, Administrative Tools, Local Security Policy.
On the Security Settings, right click and Import Policy. This will give you a list of templates. In my opinion I would use the "basicsv". This will set all defaults back to way the system was when installed.
This is not a guaretee that it will work.
But this is definately on the track of repairing your problem.

by davidag

I did try this before, but it did not help. I have read at MS that the templates' effects are cumulative, so maybe that is why it did not work. I guess that the basicsv does not mention all the settings that the hisecweb does.
I won't be messing with the security templates in the future :)

by nick l

Are the group permissions being changed by the ASP script directly or by a COM object that it invokes?
Didnt think that you could actually do this via ASP directly. Have only done this sort of permissions modification via creating a COM object that runs as an administrative user account and hence has the permissions, but is run by the enduser using their own permissions.
Therefore the enduser doesnt need administrative permissions, they only need access to the object, the object is configured to run as a user account that has privelidge. Therefore the user account that makes the group changes is not the enduser's account, rather the account that is configured into the object.
If this is your situation may be you are just chasinf through the wrong user account

Hope this is of help.

by nick l

Have just re-read this and it is about as clear as a goverment tax directive. Leave a note if any explanation is required

NickL

by davidag

Hmm...I'm don't know how to give a user access to the COM object. Would that be like finding the executables that are being called and making sure that the internet user has execute permission? I did not write the ASP script, but it sounds reasonable.

by frankp

It sounds like you didn't set ALL the permissions. When using active Directory services on an NTFS partition, you must not only set permissioning on the share, but also the Partition itself. I would suggest that you go to the server to do this. Using Windows Explorer, right click on the share. Note your permissions. Then right click on the share again, and look at the NTFS permissions (under the "Security" tab). Make sure they are identical (i.e. modify access given to the specific group). If that doesn't work, give the group full access in order to see if this is the root of your problem. Hope this helps.

by davidag

Neither the web server nor the primary domain server are running Active Directory

by bentgellerich

Well, intersting problem.

The reason why you can modify the Group Membership of a group created by this user is because in Windows NT, by default, everyone has the right to create Global Groups in the domain. When you create a group using this account, this user becomes the owner of the group and is able to modify membership as a result. Unfortunetly, in Windows NT, the only users who can change membership of all groups within the domain are Domain Admins and Administrators. If you add this user to one of these groups then you will be able to correct the problem.

In order to get things back to normal, well, you will have to reinstall (Sorry). The security template which uses ADSI scripts are not intended for Windows NT, however, theydo use an NTLM binding method which is why you were able to run this script on a Windows NT domain.

by estebandelatorre

Active Directory error '80070005'
General access denied error
.asp, line is a very general error, it does not have to be an active directory error, it's a very general error.
Add the user to the power users group or you should try to start from scratch (reinstall all over again.)

by davidag

I reinstalled windows on the machine, and the person who made the script added the users to the power users group, but they are not allowed to change group membership. If they are added to the administrator group then they can, but I don't wantto give them that much access to the machine.

by davidag

I reinstalled windows on the machine but left the data files (html, asp files) as they were. The permissions on the web files were erased, since I did not back up the users, and the permissions on the file were rebuilt to allow the authenticated users access.
Still can't change group membership unless the user is an administrator, but will check on having a user create a group and so be the owner and have permission that way.

by estebandelatorre

Active Directory error '80070005'
General access denied error
.asp, line is a very general error, it does not have to be an active directory error, it's a very general error.
Add the user to the power users group or you should try to start from scratch (reinstall all over again.)

From davidag on 08/09/01 10:03 AM EDT: I reinstalled windows on the machine, and the person who made the script added the users to the power users group, but they are not allowed to change group membership. If they are added to the administrator group then they can, but I don't want to give them that much access to the machine

NEW: MAKE SURE THE USERS HAVE LOG-ON LOCALLY RIGHTS!!

by shanghai sam

I added the log on locally right from the Local Security Policy program under Administrative Tools, but a user still cannot change group membership on a group he did not create through the script.
The users were also members of the Power Users group, so they did have that right already.
Maybe using ADSI is a bad idea in my case.

by kenalmoore

You asked me to re post the group policy delegation. Here it is. hope this helps your problem.

Group policies are inherited and are cumulative.

Policies applied when computer starts.

Delegate control of a GPO to a user.
A user to whom you delegate administrative control of a GPO
can alter only the group policy settings implemented by a GPO.
User cannot create new GPOs.
User gets READ and WRITE persmission.
How to delegate control?
Right click associated container. (OU)
select Properties. Group Policy TAB, select Properties.
Then select the Security TAB, then ADD tab.
Then select Users, computers or groups, select the user or group
to delegate too.

Also you can run the Delegate control wizard.
Right click the (OU) orcontainer, select Delegate Control
at the top of the list. This takes you directly to Add Users,
computers, or groups.

by davidag

I'm sorry I wasn't specific enough in my email to you. I had ment for you to repost your suggestion for me to reinstall, since I decided it was time to reinstall Windows.

I did reinstall, but it ended up not helping as much as I hoped. A power user is still not allowed to change group membership to a group unless if the power user created the group.

The answer you reposed unfortunately does not apply since the computer does not have AD installed.
Do you know if I can install AD without making the computer a domain controler? I just want it to be a member server.

by saihib

This just tells you how to grant permissions to COM objects.

At a command prompt, type: dcomcnfg.exe. The Distributed COM Configuration Properties dialog box is displayed.
Click the Default Security tab.
In the Default Access Permissions section, click Edit.
Ensure that you have "Allow Access" beside your name.
If you do not have "Allow Access" next to your name, either modify an existing profile or create a new profile that has the necessary permissions.
Apply all the changes.

by shanghai sam

Sounds like a good idea. I added the users who will be using the script through the web, so they had Allow Access, but the script reported the same error.
I don't know if ADSI is a DCOM application. I was reading up on ADSI and it said it is a COM interface.

by kdurichek

Is this question still open? Did you find an answer? If not please email me at allen.durichek@mevatec.com I might be able to help you. Might.

by shanghai sam

This acceptable rating is for being the first to suggest reinstalling. I could not email you at the address. My mail server could not deliver email to it.

by m.a. durkee

Certainly seems to have run the gambit of possible answers, check the following Security Requirements for IIS and ASP ; they may help get a handle on this troublesome problem.

ASP script directory Creator Owner: Full Control (All)(All)
System: ""
Admin: ""
IUSR: (None)(RX)
\WinNT\ Creator Owner: Full Control (All)(All)
System: ""
Admin: ""
IUSR: (WX)(X)
\WinNT\System32\ System: Full Control (All)(All)
Admin: ""
IUSR: (RX)(RX)
Inetsrv System: Full Control (All)(All)
Admin: ""
Everyone: (RX)(RX)

by shanghai sam

I think the permissions you gave for the \winnt directory is incorrect for the IUSR accoount. I should not give write and execute permissions to people browsing our web site.
An article at Microsoft agrees with this:
http://support.microsoft.com/support/kb/articles/Q187/5/06.ASP

I applied the permissions you suggested except for the write permission, and I applied the permission suggested at the URL above, but it does not work.

I tried earlier to log on locally and make changed tothe group members as the script was trying to do, but it did not work unless if the user had created the group. We may be going about it the wrong way.

This discussion is closed to new replies.