Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CHMOD UNDER IIS?

Status
Not open for further replies.

SyberWolf

IS-IT--Management
Jan 22, 2003
15
US
The Problem:

I have found a flat-file database script that my company wants installed on their IIS server (6.0) - I have installed it on a unix server and it works fine. However, the IIS server doesn't like it.

I figured out the reason its not working is due to the fact of improper permissions. However, I can't set those permissions in IIS. In unix, a file that should be chmodded to 755 has the permissions of rwxr-xr-x but in IIS I don't have those options. I have tried everything. I have tried right clicking and selecting properties and such, but it just does not work. I have found their is no equivelent to X for eXecutable in those permissions. Also, in unix you have User, Group and World... in IIS you don't.

If it helps, the database is EZDB which you can find at ezperl.com - I would appreciate any and all help.


Thanks
 
there is no such command for IIS. scripts will be executed if there is a suitable ISAPI filter.

Does the IIS server in question have perl installed? I would guess this will be a requirement for running EZDB.

perl for IIS is available from


Chris.

Indifference will be the downfall of mankind, but who cares?
 
Yes... I already installed perl on this server. In fact, I have written scripts that save form results as files and email's those results to specific people. Those scripts didn't require permissions for some reason.

Let me explain this a little better.

I know their is no chmod for iis. I have searched for equivelents and found nothing.

You see, the ezdb.cgi file requires external files to work. It calls an html template thats located in a different folder and such. For that template to be called, it needs to have the appropriate permissions set. The ezdb.cgi file in unix has to have permissions set to 755 (User can Read-Write-eXecute, Group can Read-eXecute and World can Read-eXecute)and the external file it calls (or reads and displays) has to have permissions set to 666 (User can Read-Write, Group can Read-Write and World can Read-Write) or it won't work.

I installed this flat file database script on a unix server and I got it to work only after setting the permissions to every file requiring permissions.

In IIS there is the option to set permissions, but not by groups per se. In unix you have User, Group And World. In windows, it's not that simple..(obviously) - So I say to myself, "Okay, forget the groups and just set this file to be readable and exectuable..." But you can't set individual files to be executable like that.

With this script I need the following permssions translated per se from unix into windows however that may be done..

644
666
755
777

I am pulling out my hair on this. It is extremley important to get this to work..

If there is anyone out there who can help me on this I would greatly appreciate it. We have tried cacls, and perms command but it's not working. Also, The guy who set up and monitors the servers here does not want to embark on a "Guess and Check" mission.. He says it's too dangerous..

ARG!
Thanks in Advance..
 
I learned permissions in a Novell environment, and had a hard time switching over. Maybe I'm missing the point ... but I'll try.

In IIS, you can set your application's Virtual Directory permissions to: none, script, or execute. Under "configurations, Application Mappings" you can modify which extensions and methods are recognized. These settings affect how IIS reacts to various file types - how it processes them (not who can do what).

It sounds like you're wanting to set folder and file permissions, which is done at the system level. Go to the Properties Dialog for the folder/file of interest, pick the security tab, and click "permissions". On next dialog, click "add". On next dialog, double click the GROUP and click OK. Now you should be back on the Directory Permissions Dialog. Highlight the GROUP,and change the "type of access" to "special directory" (or special file). I'm guessing these options will look more familiar to you.

The other thing that is easy to miss, are the two check boxes on the Directory Permissions Dialog. They determine whether these settings are applied to folders, files, or both.

Hope this helps
 
That sort of helps..

Here is the message I get when trying to execute the ezdb.pl script:

Software error:
Undefined subroutine &main::get_msg called at c:\inetpub\ line 2590.

Now, it would seem that the script has errors but it doesnt. On unix, all I need to do is set all the permissions and it works. (Note that I got this message when trying to run the script on Unix before I applied/set the permissions.)

I have went in and tried everything you suggested and its not working. One reason may be that there are a lot of GROUPS to choose from. My question now would be which group is equivelent to Owner, which groups is equivalent to User and which is equivalent to World or everyone... There is a group called Everyone now that I think about it.

Also, New Question.. The ezdb.pl file has the Unix command in the script "flock" - Windows does not recognize that command so i went in and took out all the flock commands.. that shouldnt affect the script right?

Thanks
 
Sorry, I don't know UNIX commands. I think the GROUPS work alot differently in Windows. Do not use Everyone, as it is an automatic assignment; so you don't have good control over it's membership.


IUSR_{computer_name} is the account for your web visitors, it's like an "internet guest" account, so don't give them too much. I'm guessing it might be running under this account right now - by default. So I'd try setting the permissions for this account temporarily just to see if we're going the right direction. I'd also check the owner of the file(s), and set it to this account. Maybe your script is doing a compare based on this value.
If you don't have a Windows test server, then your Admin shouldn't complain about this as a tempory test.

If it works, then he might want to tighten it up. To do that you'd want to define a special user/group for this purpose. I know you can specify what user/group is initiating a service, but I've never tried doing this for a script. Maybe your Administrator can get it to run as a service? Or try the developer's forum for ideas?

My experience with this is limited to a couple standard applications; like MS Performance Monitor and SQL Server. They are already running as services, and I just have to add the user information in the "Services" listing.
 
I'm in the same boat,

Need to translate from chmod 0666 into the selection of MS security options for files/dirs for IUSR_{computer_name}.

Somewhere I read attrib command may be appropriate however attrib what?

Any help is really appreciated

Thanks

 
I can help with this! Open a DOS window and type:
help attrib

As UNIX people, you'll probably feel right at home.
:)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top