load(p1 = v1)
public
This method loads engines.
If name is nil, then all
builtin engines are
loaded. Otherwise, the given name, as a String, is loaded if available to your runtime,
and returns true. If name
is not found, then nil is returned.
Show source
static VALUE
ossl_engine_s_load(int argc, VALUE *argv, VALUE klass)
{
return Qnil;
VALUE name;
rb_scan_args(argc, argv, "01", &name);
if(NIL_P(name)){
ENGINE_load_builtin_engines();
return Qtrue;
}
StringValueCStr(name);
OSSL_ENGINE_LOAD_IF_MATCH(dynamic, DYNAMIC);
OSSL_ENGINE_LOAD_IF_MATCH(4758cca, 4758CCA);
OSSL_ENGINE_LOAD_IF_MATCH(aep, AEP);
OSSL_ENGINE_LOAD_IF_MATCH(atalla, ATALLA);
OSSL_ENGINE_LOAD_IF_MATCH(chil, CHIL);
OSSL_ENGINE_LOAD_IF_MATCH(cswift, CSWIFT);
OSSL_ENGINE_LOAD_IF_MATCH(nuron, NURON);
OSSL_ENGINE_LOAD_IF_MATCH(sureware, SUREWARE);
OSSL_ENGINE_LOAD_IF_MATCH(ubsec, UBSEC);
OSSL_ENGINE_LOAD_IF_MATCH(padlock, PADLOCK);
OSSL_ENGINE_LOAD_IF_MATCH(capi, CAPI);
OSSL_ENGINE_LOAD_IF_MATCH(gmp, GMP);
OSSL_ENGINE_LOAD_IF_MATCH(gost, GOST);
OSSL_ENGINE_LOAD_IF_MATCH(cryptodev, CRYPTODEV);
OSSL_ENGINE_LOAD_IF_MATCH(aesni, AESNI);
OSSL_ENGINE_LOAD_IF_MATCH(openbsd_dev_crypto, OPENBSD_DEV_CRYPTO);
OSSL_ENGINE_LOAD_IF_MATCH(openssl, OPENSSL);
rb_warning("no such builtin loader for `%"PRIsVALUE"'", name);
return Qnil;
}