This repository was archived by the owner on Jan 23, 2023. It is now read-only.
Native shims for libheimntlm inorder to support NTLM#5919
Closed
kapilash wants to merge 8 commits into
Closed
Conversation
201ef75 to
5647e74
Compare
| private const string ClientToServerSigningMagicKey = "session key to client-to-server signing key magic constant\0"; | ||
| private const string ServerToClientSigningMagicKey = "session key to server-to-client signing key magic constant\0"; | ||
| private const string ServerToClientSealingMagicKey = "session key to server-to-client sealing key magic constant\0"; | ||
| private const string ClientToServerSealingMagicKey = "session key to client-to-server sealing key magic constant\0"; |
Contributor
There was a problem hiding this comment.
Should these be pre- allocated/encoded, e.g.:
private static readonly byte[] s_clientToServerSigningMagicKey = Encoding.UTF8.GetBytes("session key to client-to-server signing key magic constant\0");
private static readonly byte[] s_serverToClientSigningMagicKey = Encoding.UTF8.GetBytes("session key to server-to-client signing key magic constant\0");
private static readonly byte[] s_serverToClientSealingMagicKey = Encoding.UTF8.GetBytes("session key to server-to-client sealing key magic constant\0");
private static readonly byte[] s_clientToServerSealingMagicKey = Encoding.UTF8.GetBytes("session key to client-to-server sealing key magic constant\0");...to avoid having to allocate a new byte[] and encode each time they are used?
Member
|
@kapilash, @vijaykota, should this PR be closed? |
Contributor
|
We are planning a few more changes to make the managed layer independent of the underlying library used by the shim (unmanaged) layer. After that we can close this till we figure out the library to use. |
14c43dd to
106a1dd
Compare
Introducing native shims for libheimntlm inorder to support NTLM
Use IncrementalHash instead of implementing it Use Names consistent with the other PR Conflicts: src/Common/src/Interop/Linux/System.Net.Security.Native/Interop.Ntlm.cs
Native Layer:
asserts
Introduced struct PAL_NtlmBuffer to have a clearer ownership of the resources owned by ntlm_buf
Managed Layer:
Cleaned up code that was a result of code evaluation.
Refactored classes from SafeHandles to simple classes or Disposable objects.
Proper handling of offsets in Debug.Asserts
1. UInt64 to ulong 2. Method name changed to fit the appropriate type being marshalled 3. Reduce the allocations done by using a static byte array
Renamed HeimdalNtlm to Ntlm Renamed HeimdalNtlmException to NtlmException Naming convention in the shim layer is NetNativeNtlm_<Functionality>
f1d7c34 to
7b2b358
Compare
Contributor
|
Closing this since we don't want to pursue the libheimntlm option |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Introducing native shims for libheimntlm inorder to support NTLM
This PR overwrites #5728