Questions tagged [netsh]

netsh is the command name for the NetShell utility, which is used as a scripting interface for monitoring and configuring network interfaces, firewall, routing and remote access under Microsoft Windows.

Useful links: NETSH on technet. NETSH on SS64 help pages.

410 questions
5
votes
1 answer

netsh set multiple hostednetwork

I am trying to use two WIFI adapters to form a WLAN network. I know the following command can setup a hostednetwork and I have already done it. netsh wlan set hostednetwork [[mode={allow|disallow}] [[ssid=]WirelessNetworkName] [[key=]passphrase]…
panda
  • 1,344
  • 3
  • 14
  • 35
5
votes
4 answers

How to enable "Internet Connection Sharing" using command line?

Is there a way to enabled "Internet Connection Sharing" on Windows 7 (or higher) using command line? Perhaps using "netsh" or a similar command?
John Smith
  • 51
  • 1
  • 1
  • 3
5
votes
3 answers

Why is the netsh http add sslcert throwing error from Powershell ps1 file?

I am trying to add an sslcert using netsh http from within a powershell ps1 file, but it keeps throwing errors: $guid = [guid]::NewGuid() netsh http add sslcert ipport=0.0.0.0:443 certhash=5758B8D8248AA8B4E91DAA46F069CC1C39ABA718 appid={$guid}…
crazyTech
  • 1,379
  • 3
  • 32
  • 67
5
votes
1 answer

Syntax for netsh http url reservation for any IP address

I'm using IIS Express as my development web server with Visual Studio 2012. I want to be able to reach my site from wireless devices (smartphones, tablets, etc.) for testing and debugging. The wireless devices are on a separate LAN from the…
Carl Raymond
  • 4,429
  • 2
  • 25
  • 39
4
votes
4 answers

Adding SSL Certificate via "netsh.exe" does not last after a machine restart

I am currently building an ASP.Net MVC 3 eccomerce app that uses IIS Express for my development server. As we are accepting payments via the app we need to enforce SSL connections for the checkout process. After following Scott Hanselman's well…
gscragg
  • 145
  • 1
  • 7
4
votes
1 answer

netsh http add urlacl via Group Policy (GPO)

I have self-hosted WCF application that needs to listen on a URL on port 80. In order to do this, I need to add an entry to the HTTP.sys url list for a given user. I can do this with netsh http add urlacl or calling a Win32 API directly…
Travis
  • 2,654
  • 4
  • 26
  • 46
4
votes
2 answers

Connecting to Wireless Network in Batch file (One that isn't already one of your profiles)

So, I am currently trying to create a batch file to connect to a wireless network. So far I have the following... @echo off netsh wlan connect ssid="My SSID" name="My Name" pause It works fine, but the issue is that it can only connect to networks…
user8975033
4
votes
1 answer

Redirect ANY URL to a given IP (Localhost) in a netsh-created hostednetwork (Windows)

When I establish an access point via the netshell utility (netsh wlan start hostednetwork), I want all connected clients to be directed to the same page (preferably localhost) - regardless, which URL they are entering. I know this is very similar to…
Doc Brown
  • 41
  • 3
4
votes
1 answer

How do I disable the network connection from .NET without needing admin privileges?

I may be SOL on this but I thought I would give throw it out for possible solutions. I am writing a computer access control service to help me control my kids' computer use. Plan on open sourcing it when I have it working. It is written in VB.Net…
Brad Mathews
  • 1,567
  • 2
  • 23
  • 45
4
votes
2 answers

c# X509Certificate2 add certificate how mark as exportable

I have a .NET 4.0 program which is running localhost on port 9000. I want to support SSL and have a .pfx certificate to import. Because the program is running at multiple computers the programm itself is responsible to store the certificate and…
Justin
  • 2,960
  • 2
  • 34
  • 48
4
votes
1 answer

forwarding rdp traffic using netsh

I'm trying to set up port forwarding on windows machine. I have the following setup: Machine P with ip address 192.168.0.120 that is reachable from my network Machine D with ip address 192.168.120.6 that is reachable from machine D network only. I…
gor
  • 11,498
  • 5
  • 36
  • 42
4
votes
1 answer

Where is the certificate created using makecert.exe?

I need to have a "http*s*" enabled self hosted WCF service. Given that there need to be a certificate to have the service "s" enabled, I created the certificate using the following two commands in the same order: makecert.exe -sv SignRoot.pvk -cy…
DiligentKarma
  • 5,198
  • 1
  • 30
  • 33
4
votes
3 answers

Can't save old netsh http urlacl reservation

I was experimenting with the settings on a server, and it gave this information from netsh http show urlacl: Reserved URL : http://+:47001/wsman/ User: NT SERVICE\WinRM Listen: Yes Delegate: No User: NT…
Cody Konior
  • 727
  • 1
  • 7
  • 19
3
votes
2 answers

With AssemblyInfo.cs gone, where do I get my appid?

In the past, I would register the SSL cert of my application by running: netsh http add sslcert ipport=1.2.3.4:443 certhash=a4e9de3a1610ec4eae82fa81444061b8 appid={8792bd09737f8b48991bfce5c15f3700} Where the "appid" GUID came from the "assembly:…
Patrick
  • 356
  • 1
  • 10
3
votes
0 answers

nmcli slower than netsh stablishing connection

I want a crossplatform (linux and windows) solution for searching networks and connecting to them. In linux I use nmcli giving the SSID and the password. In windows I use netsh giving a profile xml wiht network information. The thing is that in…
Logan Ruiz
  • 81
  • 4