다음을 통해 공유


HttpsURLConnection.LocalPrincipal Property

Definition

Returns the principal that was sent to the server during handshaking.

public virtual Java.Security.IPrincipal? LocalPrincipal { [Android.Runtime.Register("getLocalPrincipal", "()Ljava/security/Principal;", "GetGetLocalPrincipalHandler")] get; }
[<get: Android.Runtime.Register("getLocalPrincipal", "()Ljava/security/Principal;", "GetGetLocalPrincipalHandler")>]
member this.LocalPrincipal : Java.Security.IPrincipal

Property Value

the principal sent to the server. Returns an X500Principal of the end-entity certificate for X509-based cipher suites, and KerberosPrincipal for Kerberos cipher suites. If no principal was sent, then null is returned.

Attributes

Exceptions

if no connection has been established yet.

Remarks

Returns the principal that was sent to the server during handshaking.

Note: Subclasses should override this method. If not overridden, it will default to returning the X500Principal of the end-entity certificate that was sent to the server for certificate-based ciphersuites or, return null for non-certificate based ciphersuites, such as Kerberos.

Added in 1.5.

Java documentation for javax.net.ssl.HttpsURLConnection.getLocalPrincipal().

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to