feat: Add SASL security layer support for GSSAPI#568
Open
vrlo wants to merge 2 commits intojcmturner:masterfrom
Open
feat: Add SASL security layer support for GSSAPI#568vrlo wants to merge 2 commits intojcmturner:masterfrom
vrlo wants to merge 2 commits intojcmturner:masterfrom
Conversation
Implements SASL security layers (RFC 4752) for GSSAPI/Kerberos authentication providing message integrity protection and confidentiality after authentication. Follows RFC 4121 (GSS-API v2 WrapToken format), RFC 4752 (GSSAPI SASL mechanism), and RFC 4422 (SASL framing with 4-byte length prefix). Tested against Windows Active Directory (LDAP on port 389). Co-Authored-By: Claude <noreply@anthropic.com>
Refactors GSS-API wrap token header construction to eliminate code duplication and implements proper filler byte calculation per RFC 4121 section 4.2.4 to eliminate crypto-system residue after decryption. Adds comprehensive test to verify RFC 4121 section 4.2.4 requirement that no crypto-system residue is present after decryption. Co-Authored-By: Claude <noreply@anthropic.com>
|
@vrlo: Thanks for your PR! If you can look for Channel Binding too, it will be nice :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this does
Implements SASL security layers (RFC 4752) for GSSAPI/Kerberos authentication
providing message integrity protection and confidentiality after authentication.
Follows RFC 4121 (GSS-API v2 WrapToken format), RFC 4752 (GSSAPI SASL mechanism),
and RFC 4422 (SASL framing with 4-byte length prefix).
Tested against Windows Active Directory (LDAP on port 389).
Fixes #567
Impact
This adds new APIs -- requires a minor version bump
Implementation
Three new components in
v8/gssapi:SecurityLayerSession - Session management for message wrapping/unwrapping:
SASL Framing - RFC 4422 framing with 4-byte length prefix:
SecureConn - Transparent
net.Connwrapper:Testing
Production tested against Windows Active Directory:
Compatibility
No breaking changes - all new exports:
SecurityLayer(type)SecurityLayerSession(type)SecureConn(type)NewSecurityLayerSession()(function)NewSecureConn()(function)Platform agnostic, zero external dependencies, targets v8 only.
Related issues
Builds on:
Note: This implements RFC 4121 (modern GSS-API v2). For RFC 1964 (legacy), see #460.