Slowly trying to make this thing work reliably when restarting the demo.
This commit is contained in:
@@ -67,11 +67,9 @@ namespace NSspi.Contexts
|
|||||||
|
|
||||||
if( disposing )
|
if( disposing )
|
||||||
{
|
{
|
||||||
this.Credential.Dispose();
|
|
||||||
this.ContextHandle.Dispose();
|
this.ContextHandle.Dispose();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
this.Disposed = true;
|
this.Disposed = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -186,8 +186,20 @@ namespace TestClient
|
|||||||
this.initializing = false;
|
this.initializing = false;
|
||||||
this.lastServerToken = null;
|
this.lastServerToken = null;
|
||||||
|
|
||||||
this.Invoke( (Action)delegate()
|
this.BeginInvoke( (Action)delegate()
|
||||||
{
|
{
|
||||||
|
this.context.Dispose();
|
||||||
|
this.context = new ClientContext(
|
||||||
|
this.cred,
|
||||||
|
"",
|
||||||
|
ContextAttrib.InitIntegrity |
|
||||||
|
ContextAttrib.ReplayDetect |
|
||||||
|
ContextAttrib.SequenceDetect |
|
||||||
|
ContextAttrib.MutualAuth |
|
||||||
|
ContextAttrib.Delegate |
|
||||||
|
ContextAttrib.Confidentiality
|
||||||
|
);
|
||||||
|
|
||||||
UpdateButtons();
|
UpdateButtons();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -177,7 +177,8 @@ namespace TestProtocol
|
|||||||
if( e.SocketErrorCode == SocketError.ConnectionAborted ||
|
if( e.SocketErrorCode == SocketError.ConnectionAborted ||
|
||||||
e.SocketErrorCode == SocketError.Interrupted ||
|
e.SocketErrorCode == SocketError.Interrupted ||
|
||||||
e.SocketErrorCode == SocketError.OperationAborted ||
|
e.SocketErrorCode == SocketError.OperationAborted ||
|
||||||
e.SocketErrorCode == SocketError.Shutdown )
|
e.SocketErrorCode == SocketError.Shutdown ||
|
||||||
|
e.SocketErrorCode == SocketError.ConnectionReset )
|
||||||
{
|
{
|
||||||
// Shutting down.
|
// Shutting down.
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -63,6 +63,8 @@ namespace TestServer
|
|||||||
this.connected = false;
|
this.connected = false;
|
||||||
|
|
||||||
UpdateButtons();
|
UpdateButtons();
|
||||||
|
|
||||||
|
this.usernameTextbox.Text = this.serverCred.Name;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Form1_FormClosing( object sender, FormClosingEventArgs e )
|
private void Form1_FormClosing( object sender, FormClosingEventArgs e )
|
||||||
|
|||||||
Reference in New Issue
Block a user