Construction from FSO threat virtual host

xiaoxiao2021-03-06  47

Now a lot of virtual hosts disable the standard components of the ASP: FileSystemObject, because this component provides powerful file system access capabilities for ASP, read, write, copy, delete, rename, write, copy, delete, rename, etc. on server hard drives ( Of course, this refers to the Windows NT / 2000 that is used by default. But after prohibiting this component, the consequences caused by all ASPs that use this component will not be able to run, and cannot meet the needs of customers. How to allow both FileSystemObject components, do not affect the security of the server (ie: Different virtual host users can not use the component to read and write the files)? Here is a method that I have obtained in the experiment, which is described below with Windows 2000 Server as an example. Open the resource manager on the server, right-click the drive letter of each hard disk partition or volume, select "Properties" in the pop-up menu, select the Security tab, you can see which accounts can be accessed to access this partition Volumes and access rights. After the default installation, "Everyone" has full control. Add "Administrators", "Backup Operators", "Power Users", "Users", etc., and give "full control" or corresponding permissions, pay attention, do not give "Guests" group, "IUSR_ machine name" these accounts any permissions. Then, "Everyone" group is then deleted from the list, so that only authorized groups and users can access this hard disk partition, and when the ASP is executed, it is access to the hard disk as "IUSR_ machine name", this is not given here User account permissions, ASP can also read and write files on the hard disk. The following is to set a separate user account to each virtual host user, and then assign each account to a directory that allows its fully controlled. As shown in the figure below, open "Computer Management" → "Local User and Group" → "User", click the right mouse button in the right column, select "New User" in the pop-up menu: "New User" dialog box According to the actual needs, "User Name", "Full Name", "Description", "Password", "Confirm Password", and to change the "user next login, change the password", select "Users cannot Change password "and" password never expire ". This example is a built-in account "IUSR_VHOST1" that establishes an anonymous access Internet information service for the user of the first virtual host, ie: all clients use http: //xxx.xxx.xxxx/ to access this virtual host, Identity to access. Enter the completion of the "creation". You can create multiple users according to actual needs. After the creation is complete, "Close": Now the newly established user has appeared in the account list, double-click the account in the list to further set: "IUSR_VHOST1" in the pop-up: That is, the new account that just created) Properties dialog box: Subordinate "tab: Just created account defaults belongs to the" User "group, select the group, click" Delete ": The present is as shown below, this Add "Add" again:

Find "Guests" in the "Select Group" dialog box pop-up, click "Add", this group will appear in the following text box, then click "OK": The appearance is the content shown in the following figure, point " Determine "Close this dialog box: Open" Internet Information Services ", start setting the virtual host, in this case, to explain the" first virtual host "setting as an example, right-click the host name, in the pop-up menu Select "Properties": Pop up a "first virtual host property" dialog box, can see the use of the virtual host user from the dialog box: "F: / vhost1" folder: temporarily, no matter what you just A Virtual Host Property dialog, switch to Source Manager, find "f: / vhost1" folder, right click, select "Properties" → "Security" tab, you can see the folder The default security setting is "Everyone" full control (depending on the content displayed by different situations), first "allowing the inheritance of the inheritance of the parent to the object to be transmitted to the object" to remove: The "Security" warning as shown below is pop-up, click "Delete": All groups and users in the Security tab will be empty (if not clear, please use "Delete" to empty it), then "Add" "Button. Add "administrator" as shown in the figure, add the new account "IUSR_VHOST1" created in the previous, will give full control permissions, but also add other groups or users according to actual needs, but must not put "guests" group , "IUSR_ machine name" these anonymous access to the account added! Switch to the previously opened "First Virtual Host Properties" dialog, open "Directory Security" tab, "Edit" on the anonymous access and verification control: The "Verification Method" other box (below the figure below) Show), click "Edit": "Anonymous User Account", the default is "IUSR_ Machine Name", click "Browse": Find the new account "IUSR_VHOST1" created in the "Select User" dialog box, double click At this time, the anonymous username is changed. When entering the previous creation in the password box, the password set for the account: OK, then the password: OK, complete it, click OK to close these dialogs. After this setting, the "first virtual host" user uses the ASP's FileSystemObject component to access its own directory: F: / vhost1, when trying to access other content, there will be, such as "no permissions", "The hard disk is not ready", "500 server internal error" and other errors prompts. Another: If the user needs to read the partition capacity of the hard disk and the serial number of the hard disk, the setting will not be read. If you want to read these and the entire partition related content, right click on the partition (volume) of the hard disk, select "Properties" → "Security", add this user's account to the list, and give at least "read "Permissions. Since the subdirectory under this volume has been set to "Prohibit the transfer of the inheritance rights from the parent to this object", the permission settings of the subdirectory below are not affected.

转载请注明原文地址:https://www.9cbs.com/read-80633.html

New Post(0)