New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds emittion of user authentication success event. #76
Conversation
@swift-server-bot test this please |
1 similar comment
@swift-server-bot test this please |
b05da8d
to
cf827da
Compare
@swift-server-bot test this please |
1 similar comment
@swift-server-bot test this please |
cf827da
to
14a068d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice clean patch, I really like it.
@@ -16,6 +16,9 @@ protocol AcceptsUserAuthMessages { | |||
var userAuthStateMachine: UserAuthenticationStateMachine { get set } | |||
} | |||
|
|||
/// This event indicates that server accepted our response to authentication challenge. SSH session can be considered active after that. | |||
public struct UserAuthSuccessEvent {} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add a public init
to this? Otherwise users can't construct instances of it. We should also make it Hashable
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done!
One little nit and then we're good to go. |
Motivation: Currently there is now way to wait for successful SSH session establishment, the only way to continue is to try to create a child channel. Given that most clients are expecting the session to be active when both key exchange and user authenticaiton complete, I propose to emit UserAuthSuccessEvent. That way client can wait for that event or fail if there is an error in the pipeline. Modifications: - Adds UserAuthSuccessEvent event - Adds .event case to StateMachineInboundProcessResult - Adds emittion of event if StateMachineInboundProcessResult is .event - Adds two tests Result: Closes apple#39
14a068d
to
62077dc
Compare
Motivation:
Currently there is now way to wait for successful SSH session
establishment, the only way to continue is to try to create a child
channel. Given that most clients are expecting the session to be active
when both key exchange and user authenticaiton complete, I propose to
emit UserAuthSuccessEvent. That way client can wait for that event or
fail if there is an error in the pipeline.
Modifications:
Result:
Closes #39