473,386 Members | 1,821 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

netsh error - 1312

I have seen numerous posts, both here and google, where people are having
this issue, but I have yet to see an explanation of the problem.

I have a WCF service that is working fine using http. But now we need to
upgrade it to use SSL. To do this we need to install and register a server
certificate.

I got a certificate (Web Server) from our enterprise cert server. Exported
it as a cer file and installed it on my development machine (Vista 64
ultimate, vs2008).

running netsh

netsh>http add sslcert ipport=0.0.0.0:5433
certhash=b6306171c7f42d54b59fd8c47d07d260b336e199 clientc
ertnegotiation=enable appid={e0456eb3-e143-4092-9f84-7527136625cd}

SSL Certificate add failed, Error: 1312
A specified logon session does not exist. It may already have been terminated.

where certhash is the thumbprint from the certificate and the appid is the
guid from the assemblyinfo.cs file on the server project.

What does 1312 indicate?
--
Scott Norberg
Nov 19 '08 #1
2 13379
Hi Scott,

From your description, you're trying to use HTTPS/SSL for a self hosted WCF
service. However, you're encountering the following error when registring
the SSL certifictae for the https port, correct?

===============
SSL Certificate add failed, Error: 1312
A specified logon session does not exist. It may already have been
terminated.
=============

I've just performed a local test, including test cert creating, ssl port
registering and WCF service host and running. For certificate creation and
ssl port registring, I followed this thread:

http://social.msdn.microsoft.com/for...cfc-5b11-4900-
b9bb-e7f4fac940c4/

There are two things you may have a further check:

1. When run the netsh command to register sslcert, have you used elevated
token(to start the commandline prompt)? This is necessary, otherwise ,the
normal permission is not sufficient.

2. My test use a test cert generated via "makecert.exe" (as mentioned in
the above thread). You can also try using a makecert generated cert to see
whether it works. If so, that means the problem is specific to certificate.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
ms****@microsoft.com.

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/en-us/subs...#notifications.

Note: MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 2 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions. Issues of this
nature are best handled working with a dedicated Microsoft Support Engineer
by contacting Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/en-us/subs.../aa948874.aspx
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.

--------------------
From: =?Utf-8?B?U2NvdHQ=?= <sn******@newsgroups.nospam>
Subject: netsh error - 1312
Date: Wed, 19 Nov 2008 15:19:00 -0800
I have seen numerous posts, both here and google, where people are having
this issue, but I have yet to see an explanation of the problem.

I have a WCF service that is working fine using http. But now we need to
upgrade it to use SSL. To do this we need to install and register a server
certificate.

I got a certificate (Web Server) from our enterprise cert server. Exported
it as a cer file and installed it on my development machine (Vista 64
ultimate, vs2008).

running netsh

netsh>http add sslcert ipport=0.0.0.0:5433
certhash=b6306171c7f42d54b59fd8c47d07d260b336e199 clientc
ertnegotiation=enable appid={e0456eb3-e143-4092-9f84-7527136625cd}

SSL Certificate add failed, Error: 1312
A specified logon session does not exist. It may already have been
terminated.

where certhash is the thumbprint from the certificate and the appid is the
guid from the assemblyinfo.cs file on the server project.

What does 1312 indicate?
--
Scott Norberg

Nov 20 '08 #2
Steven,

I had previously read that thread and ignored it because the options given
in the example did not match what was given from the makecert /? response.
The example uses both -sky and -r which are not shown.

I am using elevated privilege in my command box.

Running the example from the article I was able to create the certificate
and run the netsh command.

I still would like to know what the 1312 really indicates, And I still need
to know how to create a certificate from my enterprise certsvr for this
purpose.

I have found that these things always seem to work when you use makecert but
I can then never recreate a certificate from the cert server that does the
same thing. There must be an article (not a book) that tells how to do that,
any suggestions?
--
Scott Norberg
""Steven Cheng"" wrote:
Hi Scott,

From your description, you're trying to use HTTPS/SSL for a self hosted WCF
service. However, you're encountering the following error when registring
the SSL certifictae for the https port, correct?

===============
SSL Certificate add failed, Error: 1312
A specified logon session does not exist. It may already have been
terminated.
=============

I've just performed a local test, including test cert creating, ssl port
registering and WCF service host and running. For certificate creation and
ssl port registring, I followed this thread:

http://social.msdn.microsoft.com/for...cfc-5b11-4900-
b9bb-e7f4fac940c4/

There are two things you may have a further check:

1. When run the netsh command to register sslcert, have you used elevated
token(to start the commandline prompt)? This is necessary, otherwise ,the
normal permission is not sufficient.

2. My test use a test cert generated via "makecert.exe" (as mentioned in
the above thread). You can also try using a makecert generated cert to see
whether it works. If so, that means the problem is specific to certificate.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
ms****@microsoft.com.

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/en-us/subs...#notifications.

Note: MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 2 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions. Issues of this
nature are best handled working with a dedicated Microsoft Support Engineer
by contacting Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/en-us/subs.../aa948874.aspx
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.

--------------------
From: =?Utf-8?B?U2NvdHQ=?= <sn******@newsgroups.nospam>
Subject: netsh error - 1312
Date: Wed, 19 Nov 2008 15:19:00 -0800
I have seen numerous posts, both here and google, where people are having
this issue, but I have yet to see an explanation of the problem.

I have a WCF service that is working fine using http. But now we need to
upgrade it to use SSL. To do this we need to install and register a server
certificate.

I got a certificate (Web Server) from our enterprise cert server. Exported
it as a cer file and installed it on my development machine (Vista 64
ultimate, vs2008).

running netsh

netsh>http add sslcert ipport=0.0.0.0:5433
certhash=b6306171c7f42d54b59fd8c47d07d260b336e199 clientc
ertnegotiation=enable appid={e0456eb3-e143-4092-9f84-7527136625cd}

SSL Certificate add failed, Error: 1312
A specified logon session does not exist. It may already have been
terminated.

where certhash is the thumbprint from the certificate and the appid is the
guid from the assemblyinfo.cs file on the server project.

What does 1312 indicate?
--
Scott Norberg
Nov 20 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: PiErre | last post by:
Hi All, I am trying to install win32 extension 162 on python 2.2.3 on a virtual (vmware) machine with win2k server sp3 (but I tested that the same happens on either win2k sp2 or win2ksp3 on a...
2
by: Adam Clauss | last post by:
I am building a GUI to wrap around some of the information/abilities contained within the program netsh. I have figured out how to use redirect the standardinput and standardoutput so that I can...
2
by: Logan McKinley | last post by:
I receive the following error about once ever thirty minutes. The error is ============================================================================ = Configuration Error Description: An...
2
by: Emil | last post by:
Hello, Two days ago I tried to create my first asp project but when I tried to create a new asp project I got the following error message: 'The web server reported the following error when...
5
by: Stephen | last post by:
Hi, I am converting webpage to Excel and its within a try catch block it creates an Excel Spreadsheet but at the sametime it gives this error ExceptionMessage:Thread was being aborted. Please...
15
by: David Lozzi | last post by:
Howdy, I have a function that uploads an image and that works great. I love ..Nets built in upload, so much easier than 3rd party uploaders! Now I am making a public function that will take the...
2
by: Tomas Vera | last post by:
Hello All, I have a web application that is required to copy a file from the WebServer to a remote web server (staging server to production server). I've created an application that maps the...
2
by: ttan | last post by:
I'm using c# to called a command line netsh ipsec static.... and the group policy store it on local even those I used "ipsec static set store location=domain" my question is how do I keep the...
4
by: FireWall | last post by:
Hi all, I have a question about the netsh command. I looked everywhere but nobody seems to have my problem. For the moment if i do "netsh wlan show profiles" i see my current network under the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.