Click here to Skip to main content
15,886,689 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am following the steps in this article to deploy a VS MVC 5 project. It used to work before(on different computer or server). I am trying to deploy from my CP not a server

Here is the Link of the steps: https://www.c-sharpcorner.com/article/deploying-your-Asp-Net-mvc-5-app-to-iis-8/

I get the issue at this part "Add “Everyone” and click “Share” to add it to the list"

"windows file sharing: Your system administrator has blocked you from running this program

The process creation has been blocked"

What I have tried:

Even though I have full permissions and I also tried to deploy using local admin account same issue.
Posted
Updated 29-Jan-20 4:58am

That article is dangerously wrong.

You don't need to create a shared folder to host an application in IIS. You just need to make sure the IIS_IUSRS group has read permissions on the folder.

And setting your application pool to run as LocalSystem is extremely dangerous. The slightest mistake in your application, or any unpatched security vulnerability in the framework or in any library that you're using, will allow an attacker to have unrestricted access to your server. There is almost never a need to do this, and it should only ever be done on tightly restricted applications by someone who absolutely knows what they're doing.

Quite frankly, I'm surprised and disappointed to see such poor advice from @ProudMonkey[^].
 
Share this answer
 
v2
Comments
AskalotLearnalot 29-Jan-20 10:40am    
How would other users access the application without it being shared.I agree with the second part of the comment but this is an internal application
Richard Deeming 29-Jan-20 10:43am    
Sharing the folder creates a Windows file share, which users can use to connect to the server using Windows Explorer to read the source code. This is almost never what you want.

Publishing the application in IIS creates a website (or an application within a website) which users can access using a web browser. This will execute the code and return the rendered results to the user.

There is no connection between the two. You can have a file share without publishing in IIS, and you can publish in IIS without a file share.
Dave Kreskowiak 29-Jan-20 11:18am    
You misunderstand what "Share" means in this context.

ProudMonkey is creating a file share in Windows to, incorrectly, enable a File System Deploy instead of Web Deploy. This is NOT done to enable multiple people to use the web application. It's only used to put your compiled application on the server.

You would NEVER do this is a production environment. Creating a file share on a web server gives malicious people something else to attack to get into the server and either do damage or steal information. On a production server, you would always turn off all file shares to reduce what is called the "attack surface" of the server.
AskalotLearnalot 29-Jan-20 12:15pm    
Thank you for explaining.without that step I was able to connect to my site. As far as web deploy I never seem to get it right if you have a useful link that would be great(other than Microsoft doc).
If you got code from a different site and had a problem with it - and you did - the logical, sensible thing to do is to see if that site has a forum associated with the article, and if it does ask there.

And it does. So ask there: the author should be a lot more familiar with his work than we will be.
 
Share this answer
 
Comments
AskalotLearnalot 29-Jan-20 10:10am    
I asked in the comment section. I couldn't find forum.
OriginalGriff 29-Jan-20 10:13am    
What do you think the "comments section" is, if it isn't a forum?
AskalotLearnalot 29-Jan-20 10:19am    
Your feedback is a comment not a solution, please put it in the comment section.
Really does not seem to be a code issue; it is more of a deployment issue, which you were able to do before but cannot now.

So the question becomes what has changed; and the answer is the machine you are deploying it to- and this puts the problem at this particular machine

Well the problem seems self-explanatory; for whatever reason you do not have permission to do this. This could be a simple permission issue (are you logged in as an Admin?), or could be more complex permission(Group Policy), or some sofware (anti-virus/malware) is causing you the grief.

Reference:
https://social.technet.microsoft.com/Forums/en-US/0be36839-94c5-4da8-88c9-a4e439fe5a47/problem-with-windows-file-sharing-your-system-administrator-has-blocked-you-from-running-this?forum=winservergen
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900