summaryrefslogtreecommitdiff
path: root/ext/openssl/ossl_x509store.c
diff options
context:
space:
mode:
authorgotoyuzo <gotoyuzo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-02-11 08:42:57 +0000
committergotoyuzo <gotoyuzo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-02-11 08:42:57 +0000
commitdd90ca0a3035c2c55fcbd00a8c86c63c5451e509 (patch)
treeb52c09f9992fd1e2cb5004b1cf8b2795cbd85f8c /ext/openssl/ossl_x509store.c
parent417073640454c7bd7d6fc184342ea47e29dab717 (diff)
* ext/openss/ossl_x509store.c (ossl_x509store_set_default_paths):
new method OpenSSL::X509::Store#set_default_paths. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@7945 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/openssl/ossl_x509store.c')
-rw-r--r--ext/openssl/ossl_x509store.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/ext/openssl/ossl_x509store.c b/ext/openssl/ossl_x509store.c
index cf1a2cdac4..b08f90cde8 100644
--- a/ext/openssl/ossl_x509store.c
+++ b/ext/openssl/ossl_x509store.c
@@ -239,6 +239,17 @@ ossl_x509store_add_path(VALUE self, VALUE dir)
}
static VALUE
+ossl_x509store_set_default_paths(VALUE self)
+{
+ X509_STORE *store;
+
+ GetX509Store(self, store);
+ X509_STORE_set_default_paths(store);
+
+ return Qnil;
+}
+
+static VALUE
ossl_x509store_add_cert(VALUE self, VALUE arg)
{
X509_STORE *store;
@@ -574,6 +585,7 @@ Init_ossl_x509store()
rb_define_method(cX509Store, "time=", ossl_x509store_set_time, 1);
rb_define_method(cX509Store, "add_path", ossl_x509store_add_path, 1);
rb_define_method(cX509Store, "add_file", ossl_x509store_add_file, 1);
+ rb_define_method(cX509Store, "set_default_paths", ossl_x509store_set_default_paths, 0);
rb_define_method(cX509Store, "add_cert", ossl_x509store_add_cert, 1);
rb_define_method(cX509Store, "add_crl", ossl_x509store_add_crl, 1);
rb_define_method(cX509Store, "verify", ossl_x509store_verify, -1);