Name
SPVM::Net::SSLeay::X509_STORE_CTX - X509_STORE_CTX Data Structure in OpenSSL
Description
Net::SSLeay::X509_STORE_CTX class in SPVM represents X509_STORE_CTX
data structure in OpenSSL.
Usage
use Net::SSLeay::X509_STORE_CTX;
Class Methods
get1_issuer
static method get1_issuer : int ($issuer_ref : Net::SSLeay::X509[], $ctx : Net::SSLeay::X509_STORE_CTX, $x : Net::SSLeay::X509);
Calls native X509_STORE_CTX_get1_issuer function given $issuer_ref, $ctx, $x.
And if its return value is 1, creates a new Net::SSLeay::X509 object, sets the pointer value of the new object to the value of the native output argument *issuer
, and sets $issuer_ref->[0]
to the new object.
And returns the return value of the native function.
Exceptions:
The output array of the Net::SSLeay::X509 $issuer_ref must be 1-length array. Otherwise an exception is thrown.
The Net::SSLeay::X509_STORE_CTX object $ctx must be defined. Otherwise an exception is thrown.
The X509 object $x must be defined. Otherwise an exception is thrown.
If X509_STORE_CTX_get1_issuer failed, an exception is thrown with eval_error_id
set to the basic type ID of Net::SSLeay::Error class.
Instance Methods
set_error
method set_error : void ($s : int);
Calls native X509_STORE_CTX_set_error function given the pointer value of the instance, $s.
get_error
method get_error : int ();
Calls native X509_STORE_CTX_get_error function given the pointer value of the instance, and returns its return value.
get_error_depth
method get_error_depth : int ();
Calls native X509_STORE_CTX_get_error_depth function given the pointer value of the instance, and returns its return value.
get_current_cert
method get_current_cert : Net::SSLeay::X509 ();
Calls native X509_STORE_CTX_get_current_cert function given the pointer value of the instance.
If its return value is NULL, returns undef.
Otherwise, increments the refernece count of its return value using native X509_up_ref function, creates a new Net::SSLeay::X509 object, sets the pointer value of the new object to the return value of the native function, and returns the new object.
See Also
Copyright & License
Copyright (c) 2024 Yuki Kimoto
MIT License