1<?php 2 3/** @generate-class-entries */ 4 5/** 6 * @var string 7 * @cvalue OPENSSL_VERSION_TEXT 8 */ 9const OPENSSL_VERSION_TEXT = UNKNOWN; 10/** 11 * @var int 12 * @cvalue OPENSSL_VERSION_NUMBER 13 */ 14const OPENSSL_VERSION_NUMBER = UNKNOWN; 15 16/** 17 * @var int 18 * @cvalue X509_PURPOSE_SSL_CLIENT 19 */ 20const X509_PURPOSE_SSL_CLIENT = UNKNOWN; 21/** 22 * @var int 23 * @cvalue X509_PURPOSE_SSL_SERVER 24 */ 25const X509_PURPOSE_SSL_SERVER = UNKNOWN; 26 27/** 28 * @var int 29 * @cvalue X509_PURPOSE_NS_SSL_SERVER 30 */ 31const X509_PURPOSE_NS_SSL_SERVER = UNKNOWN; 32/** 33 * @var int 34 * @cvalue X509_PURPOSE_SMIME_SIGN 35 */ 36const X509_PURPOSE_SMIME_SIGN = UNKNOWN; 37/** 38 * @var int 39 * @cvalue X509_PURPOSE_SMIME_ENCRYPT 40 */ 41const X509_PURPOSE_SMIME_ENCRYPT = UNKNOWN; 42/** 43 * @var int 44 * @cvalue X509_PURPOSE_CRL_SIGN 45 */ 46const X509_PURPOSE_CRL_SIGN = UNKNOWN; 47/** 48 * @var int 49 * @cvalue X509_PURPOSE_ANY 50 */ 51const X509_PURPOSE_ANY = UNKNOWN; 52/** 53 * @var int 54 * @cvalue X509_PURPOSE_OCSP_HELPER 55 */ 56const X509_PURPOSE_OCSP_HELPER = UNKNOWN; 57/** 58 * @var int 59 * @cvalue X509_PURPOSE_TIMESTAMP_SIGN 60 */ 61const X509_PURPOSE_TIMESTAMP_SIGN = UNKNOWN; 62 63/* digest algorithm constants */ 64 65/** 66 * @var int 67 * @cvalue OPENSSL_ALGO_SHA1 68 */ 69const OPENSSL_ALGO_SHA1 = UNKNOWN; 70/** 71 * @var int 72 * @cvalue OPENSSL_ALGO_MD5 73 */ 74const OPENSSL_ALGO_MD5 = UNKNOWN; 75#ifndef OPENSSL_NO_MD4 76/** 77 * @var int 78 * @cvalue OPENSSL_ALGO_MD4 79 */ 80const OPENSSL_ALGO_MD4 = UNKNOWN; 81#endif 82#ifndef OPENSSL_NO_MD2 83/** 84 * @var int 85 * @cvalue OPENSSL_ALGO_MD2 86 */ 87const OPENSSL_ALGO_MD2 = UNKNOWN; 88#endif 89#if PHP_OPENSSL_API_VERSION < 0x10100 90/** 91 * @var int 92 * @cvalue OPENSSL_ALGO_DSS1 93 */ 94const OPENSSL_ALGO_DSS1 = UNKNOWN; 95#endif 96 97/** 98 * @var int 99 * @cvalue OPENSSL_ALGO_SHA224 100 */ 101const OPENSSL_ALGO_SHA224 = UNKNOWN; 102/** 103 * @var int 104 * @cvalue OPENSSL_ALGO_SHA256 105 */ 106const OPENSSL_ALGO_SHA256 = UNKNOWN; 107/** 108 * @var int 109 * @cvalue OPENSSL_ALGO_SHA384 110 */ 111const OPENSSL_ALGO_SHA384 = UNKNOWN; 112/** 113 * @var int 114 * @cvalue OPENSSL_ALGO_SHA512 115 */ 116const OPENSSL_ALGO_SHA512 = UNKNOWN; 117#ifndef OPENSSL_NO_RMD160 118/** 119 * @var int 120 * @cvalue OPENSSL_ALGO_RMD160 121 */ 122const OPENSSL_ALGO_RMD160 = UNKNOWN; 123#endif 124 125/* flags for S/MIME */ 126 127/** 128 * @var int 129 * @cvalue PKCS7_DETACHED 130 */ 131const PKCS7_DETACHED = UNKNOWN; 132/** 133 * @var int 134 * @cvalue PKCS7_TEXT 135 */ 136const PKCS7_TEXT = UNKNOWN; 137/** 138 * @var int 139 * @cvalue PKCS7_NOINTERN 140 */ 141const PKCS7_NOINTERN = UNKNOWN; 142/** 143 * @var int 144 * @cvalue PKCS7_NOVERIFY 145 */ 146const PKCS7_NOVERIFY = UNKNOWN; 147/** 148 * @var int 149 * @cvalue PKCS7_NOCHAIN 150 */ 151const PKCS7_NOCHAIN = UNKNOWN; 152/** 153 * @var int 154 * @cvalue PKCS7_NOCERTS 155 */ 156const PKCS7_NOCERTS = UNKNOWN; 157/** 158 * @var int 159 * @cvalue PKCS7_NOATTR 160 */ 161const PKCS7_NOATTR = UNKNOWN; 162/** 163 * @var int 164 * @cvalue PKCS7_BINARY 165 */ 166const PKCS7_BINARY = UNKNOWN; 167/** 168 * @var int 169 * @cvalue PKCS7_NOSIGS 170 */ 171const PKCS7_NOSIGS = UNKNOWN; 172/** 173 * @var int 174 * @cvalue PKCS7_NOOLDMIMETYPE 175 */ 176const PKCS7_NOOLDMIMETYPE = UNKNOWN; 177 178/** 179 * @var int 180 * @cvalue CMS_DETACHED 181 */ 182const OPENSSL_CMS_DETACHED = UNKNOWN; 183/** 184 * @var int 185 * @cvalue CMS_TEXT 186 */ 187const OPENSSL_CMS_TEXT = UNKNOWN; 188/** 189 * @var int 190 * @cvalue CMS_NOINTERN 191 */ 192const OPENSSL_CMS_NOINTERN = UNKNOWN; 193/** 194 * @var int 195 * @cvalue CMS_NOVERIFY 196 */ 197const OPENSSL_CMS_NOVERIFY = UNKNOWN; 198/** 199 * @var int 200 * @cvalue CMS_NOCERTS 201 */ 202const OPENSSL_CMS_NOCERTS = UNKNOWN; 203/** 204 * @var int 205 * @cvalue CMS_NOATTR 206 */ 207const OPENSSL_CMS_NOATTR = UNKNOWN; 208/** 209 * @var int 210 * @cvalue CMS_BINARY 211 */ 212const OPENSSL_CMS_BINARY = UNKNOWN; 213/** 214 * @var int 215 * @cvalue CMS_NOSIGS 216 */ 217const OPENSSL_CMS_NOSIGS = UNKNOWN; 218/** 219 * @var int 220 * @cvalue CMS_NOOLDMIMETYPE 221 */ 222const OPENSSL_CMS_OLDMIMETYPE = UNKNOWN; 223 224/** 225 * @var int 226 * @cvalue RSA_PKCS1_PADDING 227 */ 228const OPENSSL_PKCS1_PADDING = UNKNOWN; 229#ifdef RSA_SSLV23_PADDING 230/** 231 * @var int 232 * @cvalue RSA_SSLV23_PADDING 233 */ 234const OPENSSL_SSLV23_PADDING = UNKNOWN; 235#endif 236 237/** 238 * @var int 239 * @cvalue RSA_NO_PADDING 240 */ 241const OPENSSL_NO_PADDING = UNKNOWN; 242/** 243 * @var int 244 * @cvalue RSA_PKCS1_OAEP_PADDING 245 */ 246const OPENSSL_PKCS1_OAEP_PADDING = UNKNOWN; 247 248/* Informational stream wrapper constants */ 249 250/** 251 * @var string 252 * @cvalue OPENSSL_DEFAULT_STREAM_CIPHERS 253 */ 254const OPENSSL_DEFAULT_STREAM_CIPHERS = UNKNOWN; 255 256/* Ciphers */ 257 258#ifndef OPENSSL_NO_RC2 259/** 260 * @var int 261 * @cvalue PHP_OPENSSL_CIPHER_RC2_40 262 */ 263const OPENSSL_CIPHER_RC2_40 = UNKNOWN; 264/** 265 * @var int 266 * @cvalue PHP_OPENSSL_CIPHER_RC2_128 267 */ 268const OPENSSL_CIPHER_RC2_128 = UNKNOWN; 269/** 270 * @var int 271 * @cvalue PHP_OPENSSL_CIPHER_RC2_64 272 */ 273const OPENSSL_CIPHER_RC2_64 = UNKNOWN; 274#endif 275 276#ifndef OPENSSL_NO_DES 277/** 278 * @var int 279 * @cvalue PHP_OPENSSL_CIPHER_DES 280 */ 281const OPENSSL_CIPHER_DES = UNKNOWN; 282/** 283 * @var int 284 * @cvalue PHP_OPENSSL_CIPHER_3DES 285 */ 286const OPENSSL_CIPHER_3DES = UNKNOWN; 287#endif 288 289#ifndef OPENSSL_NO_AES 290/** 291 * @var int 292 * @cvalue PHP_OPENSSL_CIPHER_AES_128_CBC 293 */ 294const OPENSSL_CIPHER_AES_128_CBC = UNKNOWN; 295/** 296 * @var int 297 * @cvalue PHP_OPENSSL_CIPHER_AES_192_CBC 298 */ 299const OPENSSL_CIPHER_AES_192_CBC = UNKNOWN; 300/** 301 * @var int 302 * @cvalue PHP_OPENSSL_CIPHER_AES_256_CBC 303 */ 304const OPENSSL_CIPHER_AES_256_CBC = UNKNOWN; 305#endif 306 307/* Values for key types */ 308 309/** 310 * @var int 311 * @cvalue OPENSSL_KEYTYPE_RSA 312 */ 313const OPENSSL_KEYTYPE_RSA = UNKNOWN; 314#ifndef OPENSSL_NO_DSA 315/** 316 * @var int 317 * @cvalue OPENSSL_KEYTYPE_DSA 318 */ 319const OPENSSL_KEYTYPE_DSA = UNKNOWN; 320#endif 321 322/** 323 * @var int 324 * @cvalue OPENSSL_KEYTYPE_DH 325 */ 326const OPENSSL_KEYTYPE_DH = UNKNOWN; 327#ifdef HAVE_EVP_PKEY_EC 328/** 329 * @var int 330 * @cvalue OPENSSL_KEYTYPE_EC 331 */ 332const OPENSSL_KEYTYPE_EC = UNKNOWN; 333#endif 334#if PHP_OPENSSL_API_VERSION >= 0x30000 335/** 336 * @var int 337 * @cvalue OPENSSL_KEYTYPE_X25519 338 */ 339const OPENSSL_KEYTYPE_X25519 = UNKNOWN; 340/** 341 * @var int 342 * @cvalue OPENSSL_KEYTYPE_ED25519 343 */ 344const OPENSSL_KEYTYPE_ED25519 = UNKNOWN; 345/** 346 * @var int 347 * @cvalue OPENSSL_KEYTYPE_X448 348 */ 349const OPENSSL_KEYTYPE_X448 = UNKNOWN; 350/** 351 * @var int 352 * @cvalue OPENSSL_KEYTYPE_ED448 353 */ 354const OPENSSL_KEYTYPE_ED448 = UNKNOWN; 355#endif 356 357/** 358 * @var int 359 * @cvalue OPENSSL_RAW_DATA 360 */ 361const OPENSSL_RAW_DATA = UNKNOWN; 362/** 363 * @var int 364 * @cvalue OPENSSL_ZERO_PADDING 365 */ 366const OPENSSL_ZERO_PADDING = UNKNOWN; 367/** 368 * @var int 369 * @cvalue OPENSSL_DONT_ZERO_PAD_KEY 370 */ 371const OPENSSL_DONT_ZERO_PAD_KEY = UNKNOWN; 372 373#ifndef OPENSSL_NO_TLSEXT 374/** @var int */ 375const OPENSSL_TLSEXT_SERVER_NAME = 1; 376#endif 377 378/* Register encodings */ 379 380/** 381 * @var int 382 * @cvalue ENCODING_DER 383 */ 384const OPENSSL_ENCODING_DER = UNKNOWN; 385/** 386 * @var int 387 * @cvalue ENCODING_SMIME 388 */ 389const OPENSSL_ENCODING_SMIME = UNKNOWN; 390/** 391 * @var int 392 * @cvalue ENCODING_PEM 393 */ 394const OPENSSL_ENCODING_PEM = UNKNOWN; 395 396 397/** 398 * @strict-properties 399 * @not-serializable 400 */ 401final class OpenSSLCertificate 402{ 403} 404 405/** 406 * @strict-properties 407 * @not-serializable 408 */ 409final class OpenSSLCertificateSigningRequest 410{ 411} 412 413/** 414 * @strict-properties 415 * @not-serializable 416 */ 417final class OpenSSLAsymmetricKey 418{ 419} 420 421function openssl_x509_export_to_file(OpenSSLCertificate|string $certificate, string $output_filename, bool $no_text = true): bool {} 422 423/** @param string $output */ 424function openssl_x509_export(OpenSSLCertificate|string $certificate, &$output, bool $no_text = true): bool {} 425 426function openssl_x509_fingerprint(OpenSSLCertificate|string $certificate, string $digest_algo = "sha1", bool $binary = false): string|false {} 427 428/** 429 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 430 */ 431function openssl_x509_check_private_key(OpenSSLCertificate|string $certificate, #[\SensitiveParameter] $private_key): bool {} 432 433/** @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $public_key */ 434function openssl_x509_verify(OpenSSLCertificate|string $certificate, $public_key): int {} 435 436/** 437 * @return array<string, int|string|array>|false 438 * @refcount 1 439 */ 440function openssl_x509_parse(OpenSSLCertificate|string $certificate, bool $short_names = true): array|false {} 441 442function openssl_x509_checkpurpose(OpenSSLCertificate|string $certificate, int $purpose, array $ca_info = [], ?string $untrusted_certificates_file = null): bool|int {} 443 444function openssl_x509_read(OpenSSLCertificate|string $certificate): OpenSSLCertificate|false {} 445 446#[\Deprecated(since: '8.0', message: 'as OpenSSLCertificate objects are freed automatically')] 447function openssl_x509_free(OpenSSLCertificate $certificate): void {} 448 449/** 450 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 451 */ 452function openssl_pkcs12_export_to_file(OpenSSLCertificate|string $certificate, string $output_filename, #[\SensitiveParameter] $private_key, #[\SensitiveParameter] string $passphrase, array $options = []): bool {} 453 454/** 455 * @param string $output 456 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 457 */ 458function openssl_pkcs12_export(OpenSSLCertificate|string $certificate, &$output, #[\SensitiveParameter] $private_key, #[\SensitiveParameter] string $passphrase, array $options = []): bool {} 459 460/** 461 * @param array $certificates 462 */ 463function openssl_pkcs12_read(string $pkcs12, &$certificates, #[\SensitiveParameter] string $passphrase): bool {} 464 465function openssl_csr_export_to_file(OpenSSLCertificateSigningRequest|string $csr, string $output_filename, bool $no_text = true): bool {} 466 467/** @param string $output */ 468function openssl_csr_export(OpenSSLCertificateSigningRequest|string $csr, &$output, bool $no_text = true): bool {} 469 470/** 471 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 472 */ 473function openssl_csr_sign(OpenSSLCertificateSigningRequest|string $csr, OpenSSLCertificate|string|null $ca_certificate, #[\SensitiveParameter] $private_key, int $days, ?array $options = null, int $serial = 0, ?string $serial_hex = null): OpenSSLCertificate|false {} 474 475/** 476 * @param OpenSSLAsymmetricKey|null $private_key 477 */ 478function openssl_csr_new(array $distinguished_names, #[\SensitiveParameter] &$private_key, ?array $options = null, ?array $extra_attributes = null): OpenSSLCertificateSigningRequest|bool {} 479 480/** 481 * @return array<string, string|array>|false 482 * @refcount 1 483 */ 484function openssl_csr_get_subject(OpenSSLCertificateSigningRequest|string $csr, bool $short_names = true): array|false {} 485 486function openssl_csr_get_public_key(OpenSSLCertificateSigningRequest|string $csr, bool $short_names = true): OpenSSLAsymmetricKey|false {} 487 488function openssl_pkey_new(?array $options = null): OpenSSLAsymmetricKey|false {} 489 490/** 491 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $key 492 */ 493function openssl_pkey_export_to_file(#[\SensitiveParameter] $key, string $output_filename, #[\SensitiveParameter] ?string $passphrase = null, ?array $options = null): bool {} 494 495/** 496 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $key 497 * @param string $output 498 */ 499function openssl_pkey_export(#[\SensitiveParameter] $key, &$output, #[\SensitiveParameter] ?string $passphrase = null, ?array $options = null): bool {} 500 501/** @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $public_key */ 502function openssl_pkey_get_public($public_key): OpenSSLAsymmetricKey|false {} 503 504/** 505 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $public_key 506 * @alias openssl_pkey_get_public 507 */ 508function openssl_get_publickey($public_key): OpenSSLAsymmetricKey|false {} 509 510#[\Deprecated(since: '8.0', message: 'as OpenSSLAsymmetricKey objects are freed automatically')] 511function openssl_pkey_free(OpenSSLAsymmetricKey $key): void {} 512 513/** 514 * @alias openssl_pkey_free 515 */ 516#[\Deprecated(since: '8.0', message: 'as OpenSSLAsymmetricKey objects are freed automatically')] 517function openssl_free_key(OpenSSLAsymmetricKey $key): void {} 518 519/** 520 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 521 */ 522function openssl_pkey_get_private(#[\SensitiveParameter] $private_key, #[\SensitiveParameter] ?string $passphrase = null): OpenSSLAsymmetricKey|false {} 523 524/** 525 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 526 * @alias openssl_pkey_get_private 527 */ 528function openssl_get_privatekey(#[\SensitiveParameter] $private_key, #[\SensitiveParameter] ?string $passphrase = null): OpenSSLAsymmetricKey|false {} 529 530/** 531 * @return array<string, int|string|array>|false 532 * @refcount 1 533 */ 534function openssl_pkey_get_details(OpenSSLAsymmetricKey $key): array|false {} 535 536function openssl_pbkdf2(#[\SensitiveParameter] string $password, string $salt, int $key_length, int $iterations, string $digest_algo = "sha1"): string|false {} 537 538function openssl_pkcs7_verify(string $input_filename, int $flags, ?string $signers_certificates_filename = null, array $ca_info = [], ?string $untrusted_certificates_filename = null, ?string $content = null, ?string $output_filename = null): bool|int {} 539 540/** @param OpenSSLCertificate|array|string $certificate */ 541function openssl_pkcs7_encrypt(string $input_filename, string $output_filename, $certificate, ?array $headers, int $flags = 0, int $cipher_algo = OPENSSL_CIPHER_AES_128_CBC): bool {} 542 543/** 544 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 545 */ 546function openssl_pkcs7_sign(string $input_filename, string $output_filename, OpenSSLCertificate|string $certificate, #[\SensitiveParameter] $private_key, ?array $headers, int $flags = PKCS7_DETACHED, ?string $untrusted_certificates_filename = null): bool {} 547 548/** 549 * @param OpenSSLCertificate|string $certificate 550 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string|null $private_key 551 */ 552function openssl_pkcs7_decrypt(string $input_filename, string $output_filename, #[\SensitiveParameter] $certificate, #[\SensitiveParameter] $private_key = null): bool {} 553 554/** @param array $certificates */ 555function openssl_pkcs7_read(string $data, &$certificates): bool {} 556 557function openssl_cms_verify(string $input_filename, int $flags = 0, ?string $certificates = null, array $ca_info = [], ?string $untrusted_certificates_filename = null, ?string $content = null, ?string $pk7 = null, ?string $sigfile = null, int $encoding = OPENSSL_ENCODING_SMIME): bool {} 558 559/** @param OpenSSLCertificate|array|string $certificate */ 560function openssl_cms_encrypt(string $input_filename, string $output_filename, $certificate, ?array $headers, int $flags = 0, int $encoding = OPENSSL_ENCODING_SMIME, int $cipher_algo = OPENSSL_CIPHER_AES_128_CBC): bool {} 561 562/** 563 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 564 */ 565function openssl_cms_sign(string $input_filename, string $output_filename, OpenSSLCertificate|string $certificate, #[\SensitiveParameter] $private_key, ?array $headers, int $flags = 0, int $encoding = OPENSSL_ENCODING_SMIME, ?string $untrusted_certificates_filename = null): bool {} 566 567/** 568 * @param OpenSSLCertificate|string $certificate 569 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string|null $private_key 570 */ 571function openssl_cms_decrypt(string $input_filename, string $output_filename, #[\SensitiveParameter] $certificate, #[\SensitiveParameter] $private_key = null, int $encoding = OPENSSL_ENCODING_SMIME): bool {} 572 573/** @param array $certificates */ 574function openssl_cms_read(string $input_filename, &$certificates): bool {} 575 576/** 577 * @param string $encrypted_data 578 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 579 */ 580function openssl_private_encrypt(#[\SensitiveParameter] string $data, &$encrypted_data, #[\SensitiveParameter] $private_key, int $padding = OPENSSL_PKCS1_PADDING): bool {} 581 582/** 583 * @param string $decrypted_data 584 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 585 */ 586function openssl_private_decrypt(string $data, #[\SensitiveParameter] &$decrypted_data, #[\SensitiveParameter] $private_key, int $padding = OPENSSL_PKCS1_PADDING): bool {} 587 588/** 589 * @param string $encrypted_data 590 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $public_key 591 */ 592function openssl_public_encrypt(#[\SensitiveParameter] string $data, &$encrypted_data, $public_key, int $padding = OPENSSL_PKCS1_PADDING): bool {} 593 594/** 595 * @param string $decrypted_data 596 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $public_key 597 */ 598function openssl_public_decrypt(string $data, #[\SensitiveParameter] &$decrypted_data, $public_key, int $padding = OPENSSL_PKCS1_PADDING): bool {} 599 600function openssl_error_string(): string|false {} 601 602/** 603 * @param string $signature 604 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 605 */ 606function openssl_sign(string $data, &$signature, #[\SensitiveParameter] $private_key, string|int $algorithm = OPENSSL_ALGO_SHA1): bool {} 607 608/** @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $public_key */ 609function openssl_verify(string $data, string $signature, $public_key, string|int $algorithm = OPENSSL_ALGO_SHA1): int|false {} 610 611/** 612 * @param string $sealed_data 613 * @param array $encrypted_keys 614 * @param string $iv 615 */ 616function openssl_seal(#[\SensitiveParameter] string $data, &$sealed_data, &$encrypted_keys, array $public_key, string $cipher_algo, &$iv = null): int|false {} 617 618/** 619 * @param string $output 620 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 621 */ 622function openssl_open(string $data, #[\SensitiveParameter] &$output, string $encrypted_key, #[\SensitiveParameter] $private_key, string $cipher_algo, ?string $iv = null): bool {} 623 624/** 625 * @return array<int, string> 626 * @refcount 1 627 */ 628function openssl_get_md_methods(bool $aliases = false): array {} 629 630/** 631 * @return array<int, string> 632 * @refcount 1 633 */ 634function openssl_get_cipher_methods(bool $aliases = false): array {} 635 636#ifdef HAVE_EVP_PKEY_EC 637/** 638 * @return array<int, string>|false 639 * @refcount 1 640 */ 641function openssl_get_curve_names(): array|false {} 642#endif 643 644function openssl_digest(string $data, string $digest_algo, bool $binary = false): string|false {} 645 646/** 647 * @param string $tag 648 */ 649function openssl_encrypt(#[\SensitiveParameter] string $data, string $cipher_algo, #[\SensitiveParameter] string $passphrase, int $options = 0, string $iv = "", &$tag = null, string $aad = "", int $tag_length = 16): string|false {} 650 651function openssl_decrypt(string $data, string $cipher_algo, #[\SensitiveParameter] string $passphrase, int $options = 0, string $iv = "", ?string $tag = null, string $aad = ""): string|false {} 652 653function openssl_cipher_iv_length(string $cipher_algo): int|false {} 654 655function openssl_cipher_key_length(string $cipher_algo): int|false {} 656 657function openssl_dh_compute_key(string $public_key, #[\SensitiveParameter] OpenSSLAsymmetricKey $private_key): string|false {} 658 659/** 660 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $public_key 661 * @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key 662 */ 663function openssl_pkey_derive($public_key, #[\SensitiveParameter] $private_key, int $key_length = 0): string|false {} 664 665/** @param bool $strong_result */ 666function openssl_random_pseudo_bytes(int $length, &$strong_result = null): string {} 667 668function openssl_spki_new(#[\SensitiveParameter] OpenSSLAsymmetricKey $private_key, string $challenge, int $digest_algo = OPENSSL_ALGO_MD5): string|false {} 669 670function openssl_spki_verify(string $spki): bool {} 671 672function openssl_spki_export(string $spki): string|false {} 673 674function openssl_spki_export_challenge(string $spki): string|false {} 675 676/** 677 * @return array<string, string> 678 * @refcount 1 679 */ 680function openssl_get_cert_locations(): array {} 681 682#if defined(HAVE_OPENSSL_ARGON2) 683function openssl_password_hash(string $algo, #[\SensitiveParameter] string $password, array $options = []): string {} 684function openssl_password_verify(string $algo, #[\SensitiveParameter] string $password, string $hash): bool {} 685#endif 686