Skip to content

feat(picky-krb): add IAKerb proxy message encoding/decoding - #531

Open
Rostyslav-Romanets wants to merge 1 commit into
Devolutions:masterfrom
Rostyslav-Romanets:add-iakerb-messages
Open

Rostyslav-Romanets wants to merge 1 commit into
Devolutions:masterfrom
Rostyslav-Romanets:add-iakerb-messages

Conversation

@Rostyslav-Romanets

@Rostyslav-Romanets Rostyslav-Romanets commented Sep 24, 2026 •

Copy link
Copy Markdown

This PR implements encoding and decoding of the IAKERB_PROXY message (IAKrbProxyMessage) according to the IAKERB specification. The implementation is also covered with unit-tests.

What is IAKERB

IAKERB extends Kerberos to support scenarios where the client cannot directly access the KDC. Instead, KDC messages are encapsulated in GSS-API tokens and exchanged through an IAKERB proxy. The server forwards these messages to the LocalKDC, allowing the client to obtain the required Kerberos tickets without direct network access to the KDC.

Microsoft recently introduced IAKERB support in Windows Insider builds as part of its effort to reduce NTLM dependency: https://techcommunity.microsoft.com/blog/windows-itpro-blog/reducing-ntlm-dependency-iakerb-and-localkdc-in-windows-insider-preview/4524615.

Related PRs

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Decoding does not enforce outer framing boundaries or handle valid unknown header extensions.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 1 High severity · 1 Medium severity · 1 Low severity

Open (3)
What changed in this PR

Adds IAKERB proxy message support for downstream Kerberos proxy integrations.

Changes:

  • Adds IAKERB headers, constants, error codes, and mechanism OID.
  • Implements proxy message encoding/decoding.
  • Adds DER round-trip tests.
File Description
picky-krb/​src/​messages.rs Defines the IAKERB header and tests.
picky-krb/​src/​gss_api.rs Implements proxy token encoding and decoding.
picky-krb/​src/​constants.rs Adds IAKERB token and error constants.
picky-asn1-x509/​src/​oids.rs Registers the IAKERB mechanism OID.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread picky-krb/src/gss_api.rs
Comment on lines +230 to +233
let max_len = data.len();
let mut reader = &mut data;
let Container { iakerb_oid } =
Container::deserialize(&mut picky_asn1_der::Deserializer::new_from_reader(&mut reader, max_len))?;
Comment thread picky-krb/src/messages.rs
Comment on lines +473 to +475
// This field is not specified in the RFC but present in real messages.
#[serde(default)]
pub flags: Optional<Option<ExplicitContextTag3<BitStringAsn1>>>,
Comment thread picky-krb/src/messages.rs
}
}

/// Opaque data, if sent by the server, MUST be copied by the client verbatim into the next IAKRB_PROXY message.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants