Enum rustls_ffi::rustls_result
source · #[repr(u32)]
pub enum rustls_result {
Show 101 variants
Ok,
Io,
NullParameter,
InvalidDnsNameError,
Panic,
CertificateParseError,
PrivateKeyParseError,
InsufficientSize,
NotFound,
InvalidParameter,
UnexpectedEof,
PlaintextEmpty,
AcceptorNotReady,
AlreadyUsed,
NoCertificatesPresented,
DecryptError,
FailedToGetCurrentTime,
FailedToGetRandomBytes,
HandshakeNotComplete,
PeerSentOversizedRecord,
NoApplicationProtocol,
BadMaxFragmentSize,
UnsupportedNameType,
EncryptError,
CertEncodingBad,
CertExpired,
CertNotYetValid,
CertRevoked,
CertUnhandledCriticalExtension,
CertUnknownIssuer,
CertBadSignature,
CertNotValidForName,
CertInvalidPurpose,
CertApplicationVerificationFailure,
CertOtherError,
MessageHandshakePayloadTooLarge,
MessageInvalidCcs,
MessageInvalidContentType,
MessageInvalidCertStatusType,
MessageInvalidCertRequest,
MessageInvalidDhParams,
MessageInvalidEmptyPayload,
MessageInvalidKeyUpdate,
MessageInvalidServerName,
MessageTooLarge,
MessageTooShort,
MessageMissingData,
MessageMissingKeyExchange,
MessageNoSignatureSchemes,
MessageTrailingData,
MessageUnexpectedMessage,
MessageUnknownProtocolVersion,
MessageUnsupportedCompression,
MessageUnsupportedCurveType,
MessageUnsupportedKeyExchangeAlgorithm,
MessageInvalidOther,
PeerIncompatibleError,
PeerMisbehavedError,
InappropriateMessage,
InappropriateHandshakeMessage,
General,
AlertCloseNotify,
AlertUnexpectedMessage,
AlertBadRecordMac,
AlertDecryptionFailed,
AlertRecordOverflow,
AlertDecompressionFailure,
AlertHandshakeFailure,
AlertNoCertificate,
AlertBadCertificate,
AlertUnsupportedCertificate,
AlertCertificateRevoked,
AlertCertificateExpired,
AlertCertificateUnknown,
AlertIllegalParameter,
AlertUnknownCA,
AlertAccessDenied,
AlertDecodeError,
AlertDecryptError,
AlertExportRestriction,
AlertProtocolVersion,
AlertInsufficientSecurity,
AlertInternalError,
AlertInappropriateFallback,
AlertUserCanceled,
AlertNoRenegotiation,
AlertMissingExtension,
AlertUnsupportedExtension,
AlertCertificateUnobtainable,
AlertUnrecognisedName,
AlertBadCertificateStatusResponse,
AlertBadCertificateHashValue,
AlertUnknownPSKIdentity,
AlertCertificateRequired,
AlertNoApplicationProtocol,
AlertUnknown,
CertSCTMalformed,
CertSCTInvalidSignature,
CertSCTTimestampInFuture,
CertSCTUnsupportedVersion,
CertSCTUnknownLog,
}
Variants§
Ok
Io
NullParameter
InvalidDnsNameError
Panic
CertificateParseError
PrivateKeyParseError
InsufficientSize
NotFound
InvalidParameter
UnexpectedEof
PlaintextEmpty
AcceptorNotReady
AlreadyUsed
NoCertificatesPresented
DecryptError
FailedToGetCurrentTime
FailedToGetRandomBytes
HandshakeNotComplete
PeerSentOversizedRecord
NoApplicationProtocol
BadMaxFragmentSize
UnsupportedNameType
EncryptError
CertEncodingBad
CertExpired
CertNotYetValid
CertRevoked
CertUnhandledCriticalExtension
CertUnknownIssuer
CertBadSignature
CertNotValidForName
CertInvalidPurpose
CertApplicationVerificationFailure
CertOtherError
MessageHandshakePayloadTooLarge
MessageInvalidCcs
MessageInvalidContentType
MessageInvalidCertStatusType
MessageInvalidCertRequest
MessageInvalidDhParams
MessageInvalidEmptyPayload
MessageInvalidKeyUpdate
MessageInvalidServerName
MessageTooLarge
MessageTooShort
MessageMissingData
MessageMissingKeyExchange
MessageNoSignatureSchemes
MessageTrailingData
MessageUnexpectedMessage
MessageUnknownProtocolVersion
MessageUnsupportedCompression
MessageUnsupportedCurveType
MessageUnsupportedKeyExchangeAlgorithm
MessageInvalidOther
PeerIncompatibleError
PeerMisbehavedError
InappropriateMessage
InappropriateHandshakeMessage
General
AlertCloseNotify
AlertUnexpectedMessage
AlertBadRecordMac
AlertDecryptionFailed
AlertRecordOverflow
AlertDecompressionFailure
AlertHandshakeFailure
AlertNoCertificate
AlertBadCertificate
AlertUnsupportedCertificate
AlertCertificateRevoked
AlertCertificateExpired
AlertCertificateUnknown
AlertIllegalParameter
AlertUnknownCA
AlertAccessDenied
AlertDecodeError
AlertDecryptError
AlertExportRestriction
AlertProtocolVersion
AlertInsufficientSecurity
AlertInternalError
AlertInappropriateFallback
AlertUserCanceled
AlertNoRenegotiation
AlertMissingExtension
AlertUnsupportedExtension
AlertCertificateUnobtainable
AlertUnrecognisedName
AlertBadCertificateStatusResponse
AlertBadCertificateHashValue
AlertUnknownPSKIdentity
AlertCertificateRequired
AlertNoApplicationProtocol
AlertUnknown
CertSCTMalformed
CertSCTInvalidSignature
CertSCTTimestampInFuture
CertSCTUnsupportedVersion
CertSCTUnknownLog
Implementations§
source§impl rustls_result
impl rustls_result
source#[no_mangle]pub extern "C" fn rustls_error(
result: c_uint,
buf: *mut c_char,
len: size_t,
out_n: *mut size_t
)
#[no_mangle]pub extern "C" fn rustls_error(
result: c_uint,
buf: *mut c_char,
len: size_t,
out_n: *mut size_t
)
After a rustls function returns an error, you may call this to get a pointer to a buffer containing a detailed error message. The contents of the error buffer will be out_n bytes long, UTF-8 encoded, and not NUL-terminated.
#[no_mangle]pub extern "C" fn rustls_result_is_cert_error(result: c_uint) -> bool
Trait Implementations§
source§impl Clone for rustls_result
impl Clone for rustls_result
source§fn clone(&self) -> rustls_result
fn clone(&self) -> rustls_result
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for rustls_result
impl Debug for rustls_result
source§impl Display for rustls_result
impl Display for rustls_result
source§impl PartialEq<rustls_result> for rustls_result
impl PartialEq<rustls_result> for rustls_result
source§fn eq(&self, other: &rustls_result) -> bool
fn eq(&self, other: &rustls_result) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl TryFrom<u32> for rustls_result
impl TryFrom<u32> for rustls_result
§type Error = TryFromPrimitiveError<rustls_result>
type Error = TryFromPrimitiveError<rustls_result>
The type returned in the event of a conversion error.