Create a new FileStore
instance.
This constructor is used internally by CGI::Session
. The user does not generally need to call it directly.
session
is the session for which this instance is being created. The session id must only contain alphanumeric characters; automatically generated session ids observe this requirement.
option
is a hash of options for the initializer. The following options are recognised:
the directory to use for storing the FileStore
file. Defaults to Dir::tmpdir
(generally “/tmp” on Unix systems).
the prefix to add to the session id when generating the filename for this session’s FileStore
file. Defaults to “cgi_sid_”.
the prefix to add to the session id when generating the filename for this session’s FileStore
file. Defaults to the empty string.
This session’s FileStore
file will be created if it does not exist, or opened if it does.
Create a new MemoryStore
instance.
session
is the session this instance is associated with. option
is a list of initialisation options. None are currently recognized.
Create a new NullStore
instance.
session
is the session this instance is associated with. option
is a list of initialisation options. None are currently recognised.
Create a new CGI::Session::PStore
instance
This constructor is used internally by CGI::Session
. The user does not generally need to call it directly.
session
is the session for which this instance is being created. The session id must only contain alphanumeric characters; automatically generated session ids observe this requirement.
option
is a hash of options for the initializer. The following options are recognised:
the directory to use for storing the PStore
file. Defaults to Dir::tmpdir
(generally “/tmp” on Unix systems).
the prefix to add to the session id when generating the filename for this session’s PStore
file. Defaults to the empty string.
This session’s PStore
file will be created if it does not exist, or opened if it does.
Create a new DRb::DRbSSLSocket::SSLConfig
instance
The DRb::DRbSSLSocket
will take either a config
Hash
or an instance of SSLConfig
, and will setup the certificate for its session for the configuration. If want it to generate a generic certificate, the bare minimum is to provide the :SSLCertName
From config
Hash:
An instance of OpenSSL::X509::Certificate
. If this is not provided, then a generic X509 is generated, with a correspond :SSLPrivateKey
A private key instance, like OpenSSL::PKey::RSA
. This key must be the key that signed the :SSLCertificate
An OpenSSL::X509::Certificate
, or Array of certificates that will used as ClientCAs in the SSL Context
A path to the directory of CA certificates. The certificates must be in PEM format.
A path to a CA certificate file, in PEM format.
A DH callback. See OpenSSL::SSL::SSLContext.tmp_dh_callback
This is the SSL verification mode. See OpenSSL::SSL::VERIFY_* for available modes. The default is OpenSSL::SSL::VERIFY_NONE
Number of CA certificates to walk, when verifying a certificate chain.
A callback to be used for additional verification. See OpenSSL::SSL::SSLContext.verify_callback
A OpenSSL::X509::Store
used for verification of certificates
Issuer name for the certificate. This is required when generating the certificate (if :SSLCertificate and :SSLPrivateKey were not given). The value of this is to be an Array of pairs:
[["C", "Raleigh"], ["ST","North Carolina"], ["CN","fqdn.example.com"]]
See also OpenSSL::X509::Name
A comment to be used for generating the certificate. The default is “Generated by Ruby/OpenSSL”
These values can be added after the fact, like a Hash
.
require 'drb/ssl' c = DRb::DRbSSLSocket::SSLConfig.new {} c[:SSLCertificate] = OpenSSL::X509::Certificate.new(File.read('mycert.crt')) c[:SSLPrivateKey] = OpenSSL::PKey::RSA.new(File.read('mycert.key')) c[:SSLVerifyMode] = OpenSSL::SSL::VERIFY_PEER c[:SSLCACertificatePath] = "/etc/ssl/certs/" c.setup_certificate
or
require 'drb/ssl' c = DRb::DRbSSLSocket::SSLConfig.new({ :SSLCertName => [["CN" => DRb::DRbSSLSocket.getservername]] }) c.setup_certificate
Creates a new instance of the Response
class and sets the status and string attributes
s*(((([“‘]).*?5)|*)*?)(/)?>/um, true)
<!ENTITY name SYSTEM
“…”> <!ENTITY name “…”>
Prints out the XML
document with no formatting – except if id_hack is set.
If set to true, then inserts whitespace before the close of an empty tag, so that IE’s bad XML
parser doesn’t choke.
Create a new pretty printer.
An object implementing ‘<<(String)’, to which the output will be written.
An integer greater than 0. The indentation of each level will be this number of spaces. If this is < 1, the behavior of this object is undefined. Defaults to 2.
If true, the printer will insert whitespace before closing empty tags, thereby allowing Internet Explorer’s XML
parser to function. Defaults to false.
Create a new element.