When a Windows 11 client attempts a PKINIT (smart card) logon to a Samba Active Directory domain, that uses Heimdal, the logon fails immediately. The Windows logon screen displays the error: "A null reference pointer was passed to the stub". This occurs even though the smart card is correctly configured and works when Credential Guard is disabled. According to Microsoft dochelp, Windows always includes dhKeyExpiration and serverDHNonce in PKINIT AS-REP, even though it does not reuse DH keys. I have been told that an updated MS-PKCA specification will explain this behavior. These fields are required for logon to succeed when using Credential Guard. This bug report was created primarily to track the upstream Heimdal issue, and once a suitable solution is found, to follow the update for lorikeet-heimdal.
Thanks for looking into these things Kacper. BTW, a habit we cultivate is to CC cifs-protocol@lists.samba.org into discussions with dochelp, so that they end up archived at https://lists.samba.org/archive/cifs-protocol/ -- of course only if there are no secrets.