/third_party/rust/crates/rust-openssl/openssl/src/ |
D | ec.rs | 158 p.as_ptr(), in from_components() 159 a.as_ptr(), in from_components() 160 b.as_ptr(), in from_components() 161 ctx.as_ptr(), in from_components() 181 self.as_ptr(), in components_gfp() 182 p.as_ptr(), in components_gfp() 183 a.as_ptr(), in components_gfp() 184 b.as_ptr(), in components_gfp() 185 ctx.as_ptr(), in components_gfp() 208 self.as_ptr(), in components_gf2m() [all …]
|
D | bn.rs | 163 unsafe { ffi::BN_clear(self.as_ptr()) } in clear() 169 unsafe { cvt(ffi::BN_add_word(self.as_ptr(), w as ffi::BN_ULONG)).map(|_| ()) } in add_word() 175 unsafe { cvt(ffi::BN_sub_word(self.as_ptr(), w as ffi::BN_ULONG)).map(|_| ()) } in sub_word() 181 unsafe { cvt(ffi::BN_mul_word(self.as_ptr(), w as ffi::BN_ULONG)).map(|_| ()) } in mul_word() 189 let r = ffi::BN_div_word(self.as_ptr(), w.into()); in div_word() 203 let r = ffi::BN_mod_word(self.as_ptr(), w.into()); in mod_word() 216 unsafe { cvt(ffi::BN_rand_range(rnd.as_ptr(), self.as_ptr())).map(|_| ()) } in rand_range() 223 unsafe { cvt(ffi::BN_pseudo_rand_range(rnd.as_ptr(), self.as_ptr())).map(|_| ()) } in pseudo_rand_range() 232 unsafe { cvt(ffi::BN_set_bit(self.as_ptr(), n.into())).map(|_| ()) } in set_bit() 241 unsafe { cvt(ffi::BN_clear_bit(self.as_ptr(), n.into())).map(|_| ()) } in clear_bit() [all …]
|
D | pkey_ctx.rs | 124 let ptr = cvt_p(ffi::EVP_PKEY_CTX_new(pkey.as_ptr(), ptr::null_mut()))?; in new() 151 cvt(ffi::EVP_PKEY_encrypt_init(self.as_ptr()))?; in encrypt_init() 162 cvt(ffi::EVP_PKEY_verify_init(self.as_ptr()))?; in verify_init() 173 cvt(ffi::EVP_PKEY_verify_recover_init(self.as_ptr()))?; in verify_recover_init() 189 self.as_ptr(), in encrypt() 192 from.as_ptr(), in encrypt() 225 self.as_ptr(), in verify() 226 sig.as_ptr(), in verify() 228 data.as_ptr(), in verify() 262 self.as_ptr(), in verify_recover() [all …]
|
D | md_ctx.rs | 133 self.as_ptr(), in digest_init() 134 digest.as_ptr(), in digest_init() 158 self.as_ptr(), in digest_sign_init() 160 digest.map_or(ptr::null(), |p| p.as_ptr()), in digest_sign_init() 162 pkey.as_ptr(), in digest_sign_init() 184 self.as_ptr(), in digest_verify_init() 186 digest.map_or(ptr::null(), |p| p.as_ptr()), in digest_verify_init() 188 pkey.as_ptr(), in digest_verify_init() 200 self.as_ptr(), in digest_update() 201 data.as_ptr() as *const _, in digest_update() [all …]
|
D | rsa.rs | 88 ffi::RSA_up_ref(self.as_ptr()); in to_owned() 89 Rsa::from_ptr(self.as_ptr()) in to_owned() 138 from.as_ptr(), in private_decrypt() 140 self.as_ptr(), in private_decrypt() 166 from.as_ptr(), in private_encrypt() 168 self.as_ptr(), in private_encrypt() 180 RSA_get0_key(self.as_ptr(), ptr::null_mut(), ptr::null_mut(), &mut d); in d() 190 RSA_get0_factors(self.as_ptr(), &mut p, ptr::null_mut()); in p() 200 RSA_get0_factors(self.as_ptr(), ptr::null_mut(), &mut q); in q() 210 RSA_get0_crt_params(self.as_ptr(), &mut dp, ptr::null_mut(), ptr::null_mut()); in dmp1() [all …]
|
D | macros.rs | 11 cvt_p($f(bio.as_ptr(), 14 passphrase.as_ptr() as *const _ as *mut _)) 27 cvt_p($f(bio.as_ptr(), 43 cvt($f(bio.as_ptr(), 44 self.as_ptr(), 63 cvt($f(bio.as_ptr(), 64 self.as_ptr(), 65 cipher.as_ptr(), 66 passphrase.as_ptr() as *const _ as *mut _, 82 cvt($f(bio.as_ptr(), self.as_ptr()))?; [all …]
|
D | pkcs7.rs | 84 cvt_p(ffi::SMIME_read_PKCS7(input_bio.as_ptr(), &mut bcont_bio)).map(Pkcs7)?; in from_smime() 111 certs.as_ptr(), in encrypt() 112 input_bio.as_ptr(), in encrypt() 113 cipher.as_ptr(), in encrypt() 140 signcert.as_ptr(), in sign() 141 pkey.as_ptr(), in sign() 142 certs.as_ptr(), in sign() 143 input_bio.as_ptr(), in sign() 159 output.as_ptr(), in to_smime() 160 self.as_ptr(), in to_smime() [all …]
|
D | cms.rs | 79 let pkey = pkey.as_ptr(); in decrypt() 80 let cert = cert.as_ptr(); in decrypt() 84 self.as_ptr(), in decrypt() 88 out.as_ptr(), in decrypt() 107 let pkey = pkey.as_ptr(); in decrypt_without_cert_check() 111 self.as_ptr(), in decrypt_without_cert_check() 115 out.as_ptr(), in decrypt_without_cert_check() 145 let cms = cvt_p(ffi::SMIME_read_CMS(bio.as_ptr(), ptr::null_mut()))?; in smime_read_cms() 183 let signcert = signcert.map_or(ptr::null_mut(), |p| p.as_ptr()); in sign() 184 let pkey = pkey.map_or(ptr::null_mut(), |p| p.as_ptr()); in sign() [all …]
|
D | cipher_ctx.rs | 173 self.as_ptr(), in cipher_init() 174 type_.map_or(ptr::null(), |p| p.as_ptr()), in cipher_init() 176 key.map_or(ptr::null(), |k| k.as_ptr()), in cipher_init() 177 iv.map_or(ptr::null(), |iv| iv.as_ptr()), in cipher_init() 227 self.as_ptr(), in seal_init() 228 type_.map_or(ptr::null(), |p| p.as_ptr()), in seal_init() 232 pub_keys.as_ptr() as *mut _, in seal_init() 273 self.as_ptr(), in open_init() 274 type_.map_or(ptr::null(), |p| p.as_ptr()), in open_init() 275 encrypted_key.as_ptr(), in open_init() [all …]
|
D | asn1.rs | 77 mem_bio.as_ptr(), in fmt() 78 self.as_ptr(), in fmt() 206 let other = compare.as_ptr(); in diff() 208 let err = unsafe { ffi::ASN1_TIME_diff(&mut days, &mut secs, self.as_ptr(), other) }; in diff() 287 let print_result = cvt(ffi::ASN1_TIME_print(mem_bio.as_ptr(), self.as_ptr())); in fmt() 347 cvt(ffi::ASN1_TIME_set_string(time.as_ptr(), s.as_ptr()))?; in from_str() 363 cvt(ffi::ASN1_TIME_set_string_X509(time.as_ptr(), s.as_ptr()))?; in from_str_x509() 443 let len = ffi::ASN1_STRING_to_UTF8(&mut ptr, self.as_ptr()); in as_utf8() 460 unsafe { slice::from_raw_parts(ASN1_STRING_get0_data(self.as_ptr()), self.len()) } in as_slice() 466 unsafe { ffi::ASN1_STRING_length(self.as_ptr()) as usize } in len() [all …]
|
D | ocsp.rs | 135 self.this_update.as_ptr(), in check_validity() 136 self.next_update.as_ptr(), in check_validity() 167 self.as_ptr(), in verify() 168 certs.as_ptr(), in verify() 169 store.as_ptr(), in verify() 187 self.as_ptr(), in find_status() 188 id.as_ptr(), in find_status() 230 digest.as_ptr(), in from_cert() 231 subject.as_ptr(), in from_cert() 232 issuer.as_ptr(), in from_cert() [all …]
|
D | dsa.rs | 76 ffi::DSA_up_ref(self.as_ptr()); in to_owned() 77 Dsa::from_ptr(self.as_ptr()) in to_owned() 107 DSA_get0_key(self.as_ptr(), &mut pub_key, ptr::null_mut()); in pub_key() 143 DSA_get0_key(self.as_ptr(), ptr::null_mut(), &mut priv_key); in priv_key() 156 unsafe { ffi::DSA_size(self.as_ptr()) as u32 } in size() 164 DSA_get0_pqg(self.as_ptr(), &mut p, ptr::null_mut(), ptr::null_mut()); in p() 174 DSA_get0_pqg(self.as_ptr(), ptr::null_mut(), &mut q, ptr::null_mut()); in q() 184 DSA_get0_pqg(self.as_ptr(), ptr::null_mut(), ptr::null_mut(), &mut g); in g() 200 cvt(DSA_set0_pqg(dsa.0, p.as_ptr(), q.as_ptr(), g.as_ptr()))?; in from_pqg() 261 cvt(DSA_set0_pqg(dsa.0, p.as_ptr(), q.as_ptr(), g.as_ptr()))?; in from_private_components() [all …]
|
D | pkey.rs | 151 EVP_PKEY_up_ref(self.as_ptr()); in to_owned() 152 PKey::from_ptr(self.as_ptr()) in to_owned() 162 let rsa = cvt_p(ffi::EVP_PKEY_get1_RSA(self.as_ptr()))?; in rsa() 171 let dsa = cvt_p(ffi::EVP_PKEY_get1_DSA(self.as_ptr()))?; in dsa() 180 let dh = cvt_p(ffi::EVP_PKEY_get1_DH(self.as_ptr()))?; in dh() 189 let ec_key = cvt_p(ffi::EVP_PKEY_get1_EC_KEY(self.as_ptr()))?; in ec_key() 197 unsafe { Id::from_raw(ffi::EVP_PKEY_id(self.as_ptr())) } in id() 203 unsafe { ffi::EVP_PKEY_size(self.as_ptr()) as usize } in size() 233 unsafe { ffi::EVP_PKEY_bits(self.as_ptr()) as u32 } in bits() 242 unsafe { ffi::EVP_PKEY_security_bits(self.as_ptr()) as u32 } in security_bits() [all …]
|
D | md.rs | 29 ffi::EVP_MD_free(self.as_ptr()); 44 fn as_ptr(&self) -> *mut Self::CType { 55 MdRef::from_ptr(self.as_ptr()) 64 MdRef::from_ptr_mut(self.as_ptr()) 108 ctx.map_or(ptr::null_mut(), ForeignTypeRef::as_ptr), in fetch() 109 algorithm.as_ptr(), in fetch() 110 properties.map_or(ptr::null_mut(), |s| s.as_ptr()), in fetch() 219 unsafe { ffi::EVP_MD_block_size(self.as_ptr()) as usize } in block_size() 226 unsafe { ffi::EVP_MD_size(self.as_ptr()) as usize } in size() 233 unsafe { Nid::from_raw(ffi::EVP_MD_type(self.as_ptr())) } in type_()
|
D | provider.rs | 32 ctx.map_or(ptr::null_mut(), ForeignTypeRef::as_ptr), in load() 33 name.as_ptr(), in load() 53 ctx.map_or(ptr::null_mut(), ForeignTypeRef::as_ptr), in try_load() 54 name.as_ptr(), in try_load() 71 ctx.map_or(ptr::null_mut(), ForeignTypeRef::as_ptr), in set_default_search_path() 72 path.as_ptr(), in set_default_search_path()
|
D | dh.rs | 48 cvt(ffi::DH_check(self.as_ptr(), &mut codes))?; in check_key() 70 prime_p.as_ptr(), in from_pqg() 71 prime_q.as_ref().map_or(ptr::null_mut(), |q| q.as_ptr()), in from_pqg() 72 generator.as_ptr(), in from_pqg() 83 cvt(DH_set0_key(dh_ptr, pub_key.as_ptr(), ptr::null_mut()))?; in set_public_key() 93 cvt(DH_set0_key(dh_ptr, ptr::null_mut(), priv_key.as_ptr()))?; in set_private_key() 106 cvt(DH_set0_key(dh_ptr, pub_key.as_ptr(), priv_key.as_ptr()))?; in set_key() 196 DH_get0_pqg(self.as_ptr(), &mut p, ptr::null_mut(), ptr::null_mut()); in prime_p() 206 DH_get0_pqg(self.as_ptr(), ptr::null_mut(), &mut q, ptr::null_mut()); in prime_q() 220 DH_get0_pqg(self.as_ptr(), ptr::null_mut(), ptr::null_mut(), &mut g); in generator() [all …]
|
D | pkcs5.rs | 45 salt.as_ptr() in bytes_to_key() 54 let cipher = cipher.as_ptr(); in bytes_to_key() 55 let digest = digest.as_ptr(); in bytes_to_key() 78 data.as_ptr(), in bytes_to_key() 101 pass.as_ptr() as *const _, in pbkdf2_hmac() 103 salt.as_ptr(), in pbkdf2_hmac() 106 hash.as_ptr(), in pbkdf2_hmac() 132 pass.as_ptr() as *const _, in scrypt() 134 salt.as_ptr() as *const _, in scrypt()
|
D | aes.rs | 102 key.as_ptr() as *const _, in new_encrypt() 126 key.as_ptr() as *const _, in new_decrypt() 172 in_.as_ptr() as *const _, in aes_ige() 208 .map_or(ptr::null(), |iv| iv.as_ptr() as *const _), 209 out.as_ptr() as *mut _, 210 in_.as_ptr() as *const _, 247 .map_or(ptr::null(), |iv| iv.as_ptr() as *const _), 248 out.as_ptr() as *mut _, 249 in_.as_ptr() as *const _,
|
/third_party/rust/crates/rust-openssl/openssl/src/ssl/ |
D | mod.rs | 129 let ptr = ffi::OPENSSL_cipher_name(s.as_ptr()); in cipher_name() 371 pub fn as_ptr(&self) -> *const ffi::SSL_METHOD { in as_ptr() method 692 server.as_ptr(), in select_next_proto() 694 client.as_ptr(), in select_next_proto() 714 let ctx = cvt_p(ffi::SSL_CTX_new(method.as_ptr()))?; in new() 730 pub fn as_ptr(&self) -> *mut ffi::SSL_CTX { in as_ptr() method 731 self.0.as_ptr() in as_ptr() 738 ffi::SSL_CTX_set_verify(self.as_ptr(), mode.bits as c_int, None); in set_verify() 755 ffi::SSL_CTX_set_verify(self.as_ptr(), mode.bits as c_int, Some(raw_verify::<F>)); in set_verify_callback() 779 ffi::SSL_CTX_set_tlsext_servername_arg(self.as_ptr(), arg); in set_servername_callback() [all …]
|
/third_party/rust/crates/rust-openssl/openssl/src/x509/ |
D | mod.rs | 97 let data = ffi::X509_STORE_CTX_get_ex_data(self.as_ptr(), index.as_raw()); in ex_data() 109 unsafe { X509VerifyResult::from_raw(ffi::X509_STORE_CTX_get_error(self.as_ptr())) } in error() 142 ffi::X509_STORE_CTX_cleanup(self.0.as_ptr()); in init() 149 self.as_ptr(), in init() 150 trust.as_ptr(), in init() 151 cert.as_ptr(), in init() 152 cert_chain.as_ptr(), in init() 168 unsafe { cvt_n(ffi::X509_verify_cert(self.as_ptr())).map(|n| n != 0) } in verify_cert() 175 ffi::X509_STORE_CTX_set_error(self.as_ptr(), result.as_raw()); in set_error() 184 let ptr = ffi::X509_STORE_CTX_get_current_cert(self.as_ptr()); in current_cert() [all …]
|
D | store.rs | 98 unsafe { cvt(ffi::X509_STORE_add_cert(self.as_ptr(), cert.as_ptr())).map(|_| ()) } in add_cert() 108 unsafe { cvt(ffi::X509_STORE_set_default_paths(self.as_ptr())).map(|_| ()) } in set_default_paths() 117 let lookup = unsafe { ffi::X509_STORE_add_lookup(self.as_ptr(), method.as_ptr()) }; in add_lookup() 125 unsafe { cvt(ffi::X509_STORE_set_flags(self.as_ptr(), flags.bits())).map(|_| ()) } in set_flags() 132 unsafe { cvt(ffi::X509_STORE_set_purpose(self.as_ptr(), purpose.as_raw())).map(|_| ()) } in set_purpose() 139 unsafe { cvt(ffi::X509_STORE_set1_param(self.as_ptr(), param.as_ptr())).map(|_| ()) } in set_param() 179 self.as_ptr(), in add_dir() 180 name.as_ptr(), in add_dir() 215 self.as_ptr(), in load_cert_file() 216 file.as_ptr(), in load_cert_file() [all …]
|
D | verify.rs | 90 ffi::X509_VERIFY_PARAM_set_hostflags(self.as_ptr(), hostflags.bits); in set_hostflags() 97 unsafe { cvt(ffi::X509_VERIFY_PARAM_set_flags(self.as_ptr(), flags.bits)).map(|_| ()) } in set_flags() 105 self.as_ptr(), in clear_flags() 115 let bits = unsafe { ffi::X509_VERIFY_PARAM_get_flags(self.as_ptr()) }; in flags() 126 self.as_ptr(), in set_host() 127 raw_host.as_ptr() as *const _, in set_host() 150 self.as_ptr(), in set_ip() 151 buf.as_ptr() as *const _, in set_ip() 161 unsafe { ffi::X509_VERIFY_PARAM_set_time(self.as_ptr(), time) } in set_time() 167 unsafe { ffi::X509_VERIFY_PARAM_set_depth(self.as_ptr(), depth) } in set_depth() [all …]
|
/third_party/rust/crates/rustix/src/backend/libc/fs/ |
D | dir.rs | 98 unsafe { c::rewinddir(self.0.as_ptr()) } in rewind() 104 let dirent_ptr = unsafe { libc_readdir(self.0.as_ptr()) }; in read() 126 name: CStr::from_ptr((*dirent_ptr).d_name.as_ptr()).to_owned(), in read() 137 fstat(unsafe { BorrowedFd::borrow_raw(c::dirfd(self.0.as_ptr())) }) in stat() 151 fstatfs(unsafe { BorrowedFd::borrow_raw(c::dirfd(self.0.as_ptr())) }) in statfs() 164 fstatvfs(unsafe { BorrowedFd::borrow_raw(c::dirfd(self.0.as_ptr())) }) in statvfs() 171 fchdir(unsafe { BorrowedFd::borrow_raw(c::dirfd(self.0.as_ptr())) }) in chdir() 327 let name_len = CStr::from_ptr(input.d_name.as_ptr()) in read_dirent() 345 unsafe { c::closedir(self.0.as_ptr()) }; in drop() 361 .field("fd", unsafe { &c::dirfd(self.0.as_ptr()) }) in fmt() [all …]
|
/third_party/rust/crates/nix/src/sys/ |
D | uio.rs | 22 libc::writev(fd, iov.as_ptr() as *const libc::iovec, iov.len() as c_int) in writev() 34 libc::readv(fd, iov.as_ptr() as *const libc::iovec, iov.len() as c_int) in readv() 56 iov.as_ptr() as *const libc::iovec, in pwritev() 86 iov.as_ptr() as *const libc::iovec, in preadv() 103 buf.as_ptr() as *const c_void, in pwrite() 189 iov_base: buf.as_ptr() as *mut c_void, in from_slice() 204 iov_base: buf.as_ptr() as *mut c_void, in from_mut_slice() 250 … local_iov.as_ptr() as *const libc::iovec, local_iov.len() as libc::c_ulong, 251 … remote_iov.as_ptr() as *const libc::iovec, remote_iov.len() as libc::c_ulong, 0) 285 … local_iov.as_ptr() as *const libc::iovec, local_iov.len() as libc::c_ulong, [all …]
|
/third_party/rust/crates/rustix/src/process/ |
D | uname.rs | 28 Self::to_cstr(self.0.sysname.as_ptr().cast()) in sysname() 38 Self::to_cstr(self.0.nodename.as_ptr().cast()) in nodename() 44 Self::to_cstr(self.0.release.as_ptr().cast()) in release() 50 Self::to_cstr(self.0.version.as_ptr().cast()) in version() 56 Self::to_cstr(self.0.machine.as_ptr().cast()) in machine() 63 Self::to_cstr(self.0.domainname.as_ptr().cast()) in domainname()
|