diff options
| author | Steven Fackler <[email protected]> | 2016-10-31 20:12:55 -0700 |
|---|---|---|
| committer | Steven Fackler <[email protected]> | 2016-10-31 20:12:55 -0700 |
| commit | f640613863f0b66bc004f9d9d89f73a31701d396 (patch) | |
| tree | 923728c8959f6582e5f6da5b7472b304ed387e1e /openssl/src/x509 | |
| parent | Update EcKey (diff) | |
| download | rust-openssl-f640613863f0b66bc004f9d9d89f73a31701d396.tar.xz rust-openssl-f640613863f0b66bc004f9d9d89f73a31701d396.zip | |
Update PKey
Diffstat (limited to 'openssl/src/x509')
| -rw-r--r-- | openssl/src/x509/mod.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/openssl/src/x509/mod.rs b/openssl/src/x509/mod.rs index 8a4941ea..d3f7fbc0 100644 --- a/openssl/src/x509/mod.rs +++ b/openssl/src/x509/mod.rs @@ -17,13 +17,13 @@ use asn1::Asn1Time; use bio::{MemBio, MemBioSlice}; use crypto::CryptoString; use hash::MessageDigest; -use pkey::{PKey, PKeyRef}; +use pkey::PKey; use rand::rand_bytes; use error::ErrorStack; use ffi; use nid::Nid; use opaque::Opaque; -use types::Ref; +use types::{OpenSslType, Ref}; #[cfg(ossl10x)] use ffi::{X509_set_notBefore, X509_set_notAfter, ASN1_STRING_data}; @@ -269,7 +269,7 @@ impl X509Generator { } /// Sets the certificate public-key, then self-sign and return it - pub fn sign(&self, p_key: &PKeyRef) -> Result<X509, ErrorStack> { + pub fn sign(&self, p_key: &Ref<PKey>) -> Result<X509, ErrorStack> { ffi::init(); unsafe { @@ -321,7 +321,7 @@ impl X509Generator { } /// Obtain a certificate signing request (CSR) - pub fn request(&self, p_key: &PKeyRef) -> Result<X509Req, ErrorStack> { + pub fn request(&self, p_key: &Ref<PKey>) -> Result<X509Req, ErrorStack> { let cert = match self.sign(p_key) { Ok(c) => c, Err(x) => return Err(x), |