X509Certificate2Collection.ImportFromPem(ReadOnlySpan<Char>) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Imports a collection of RFC 7468 PEM-encoded certificates.
public:
void ImportFromPem(ReadOnlySpan<char> certPem);
public void ImportFromPem (ReadOnlySpan<char> certPem);
member this.ImportFromPem : ReadOnlySpan<char> -> unit
Public Sub ImportFromPem (certPem As ReadOnlySpan(Of Char))
Parameters
- certPem
- ReadOnlySpan<Char>
The text of the PEM-encoded X509 certificate collection.
Exceptions
The decoded contents of a PEM are invalid or corrupt and could not be imported.
Remarks
PEM-encoded items with a CERTIFICATE PEM label will be imported. PEM items with other labels will be ignored.
More advanced scenarios for loading certificates and can leverage PemEncoding to enumerate PEM-encoded values and apply any custom loading behavior.
Applies to
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈