<PackageReference Include="Microsoft.Identity.Client" Version="4.85.2" />

Microsoft.Identity.Client.ManagedIdentity.V2.ICertificateCache

interface ICertificateCache
Process-local cache for an mTLS certificate and its endpoint. Expiration is based solely on certificate.NotAfter.
void Clear(ILoggerAdapter logger = null)

Clear all entries.

bool Remove(string cacheKey, ILoggerAdapter logger = null)

Remove an entry if present.

void Set(string cacheKey, CertificateCacheValue& modreq(System.Runtime.InteropServices.InAttribute) value, ILoggerAdapter logger = null)

bool TryGet(string cacheKey, out CertificateCacheValue value, ILoggerAdapter logger = null)

Try to get a cached certificate+endpoint+clientId for the specified cacheKey. Returns true and non-null outputs if found and not expired.