SafeEvpPKeyHandle.DuplicateHandle 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
建立另一個此類實例,該實例具有獨立的生命週期,但追蹤相同資源。
public:
System::Security::Cryptography::SafeEvpPKeyHandle ^ DuplicateHandle();
public System.Security.Cryptography.SafeEvpPKeyHandle DuplicateHandle();
member this.DuplicateHandle : unit -> System.Security.Cryptography.SafeEvpPKeyHandle
Public Function DuplicateHandle () As SafeEvpPKeyHandle
傳回
另一個此類實例,具有獨立的生命週期,但追蹤相同的資源。
例外狀況
此帳號無效。
備註
在 .NET 8 及更早版本中,此方法會建立一個新的 EVP_PKEY 實例。 在 .NET 9 及以後版本中,此方法會增加現有 EVP_PKEY 實例的參考計數,並回傳同一鍵的句柄。