• Home
  • Raw
  • Download

Lines Matching refs:pb

329     PKCS12_BUILDER *pb = new_pkcs12_builder("1cert.p12");  in test_single_cert_no_attrs()  local
332 start_pkcs12(pb); in test_single_cert_no_attrs()
334 start_contentinfo(pb); in test_single_cert_no_attrs()
336 add_certbag(pb, CERT1, sizeof(CERT1), NULL); in test_single_cert_no_attrs()
338 end_contentinfo(pb); in test_single_cert_no_attrs()
340 end_pkcs12(pb); in test_single_cert_no_attrs()
343 start_check_pkcs12(pb); in test_single_cert_no_attrs()
345 start_check_contentinfo(pb); in test_single_cert_no_attrs()
347 check_certbag(pb, CERT1, sizeof(CERT1), NULL); in test_single_cert_no_attrs()
349 end_check_contentinfo(pb); in test_single_cert_no_attrs()
351 end_check_pkcs12(pb); in test_single_cert_no_attrs()
353 return end_pkcs12_builder(pb); in test_single_cert_no_attrs()
359 PKCS12_BUILDER *pb; in test_single_key() local
363 pb = new_pkcs12_builder(fname); in test_single_key()
366 start_pkcs12(pb); in test_single_key()
368 start_contentinfo(pb); in test_single_key()
370 add_keybag(pb, KEY1, sizeof(KEY1), NULL, enc); in test_single_key()
372 end_contentinfo(pb); in test_single_key()
374 end_pkcs12(pb); in test_single_key()
377 start_check_pkcs12(pb); in test_single_key()
379 start_check_contentinfo(pb); in test_single_key()
381 check_keybag(pb, KEY1, sizeof(KEY1), NULL, enc); in test_single_key()
383 end_check_contentinfo(pb); in test_single_key()
385 end_check_pkcs12(pb); in test_single_key()
387 return end_pkcs12_builder(pb); in test_single_key()
428 PKCS12_BUILDER *pb = new_pkcs12_builder("1keyattrs.p12"); in test_single_key_with_attrs() local
431 start_pkcs12(pb); in test_single_key_with_attrs()
433 start_contentinfo(pb); in test_single_key_with_attrs()
435 add_keybag(pb, KEY1, sizeof(KEY1), ATTRS1, &enc_default); in test_single_key_with_attrs()
437 end_contentinfo(pb); in test_single_key_with_attrs()
439 end_pkcs12(pb); in test_single_key_with_attrs()
442 start_check_pkcs12(pb); in test_single_key_with_attrs()
444 start_check_contentinfo(pb); in test_single_key_with_attrs()
446 check_keybag(pb, KEY1, sizeof(KEY1), ATTRS1, &enc_default); in test_single_key_with_attrs()
448 end_check_contentinfo(pb); in test_single_key_with_attrs()
450 end_check_pkcs12(pb); in test_single_key_with_attrs()
452 return end_pkcs12_builder(pb); in test_single_key_with_attrs()
458 PKCS12_BUILDER *pb; in test_single_cert_mac() local
462 pb = new_pkcs12_builder(fname); in test_single_cert_mac()
465 start_pkcs12(pb); in test_single_cert_mac()
467 start_contentinfo(pb); in test_single_cert_mac()
469 add_certbag(pb, CERT1, sizeof(CERT1), NULL); in test_single_cert_mac()
471 end_contentinfo(pb); in test_single_cert_mac()
473 end_pkcs12_with_mac(pb, mac); in test_single_cert_mac()
476 start_check_pkcs12_with_mac(pb, mac); in test_single_cert_mac()
478 start_check_contentinfo(pb); in test_single_cert_mac()
480 check_certbag(pb, CERT1, sizeof(CERT1), NULL); in test_single_cert_mac()
482 end_check_contentinfo(pb); in test_single_cert_mac()
484 end_check_pkcs12(pb); in test_single_cert_mac()
486 return end_pkcs12_builder(pb); in test_single_cert_mac()
524 PKCS12_BUILDER *pb = new_pkcs12_builder("1cert1key.p12"); in test_cert_key_with_attrs_and_mac() local
527 start_pkcs12(pb); in test_cert_key_with_attrs_and_mac()
529 start_contentinfo(pb); in test_cert_key_with_attrs_and_mac()
531 add_certbag(pb, CERT1, sizeof(CERT1), ATTRS1); in test_cert_key_with_attrs_and_mac()
532 add_keybag(pb, KEY1, sizeof(KEY1), ATTRS1, &enc_default); in test_cert_key_with_attrs_and_mac()
534 end_contentinfo(pb); in test_cert_key_with_attrs_and_mac()
536 end_pkcs12_with_mac(pb, &mac_default); in test_cert_key_with_attrs_and_mac()
539 start_check_pkcs12_with_mac(pb, &mac_default); in test_cert_key_with_attrs_and_mac()
541 start_check_contentinfo(pb); in test_cert_key_with_attrs_and_mac()
543 check_certbag(pb, CERT1, sizeof(CERT1), ATTRS1); in test_cert_key_with_attrs_and_mac()
544 check_keybag(pb, KEY1, sizeof(KEY1), ATTRS1, &enc_default); in test_cert_key_with_attrs_and_mac()
546 end_check_contentinfo(pb); in test_cert_key_with_attrs_and_mac()
548 end_check_pkcs12(pb); in test_cert_key_with_attrs_and_mac()
550 return end_pkcs12_builder(pb); in test_cert_key_with_attrs_and_mac()
555 PKCS12_BUILDER *pb = new_pkcs12_builder("1cert1key_enc.p12"); in test_cert_key_encrypted_content() local
558 start_pkcs12(pb); in test_cert_key_encrypted_content()
560 start_contentinfo(pb); in test_cert_key_encrypted_content()
562 add_certbag(pb, CERT1, sizeof(CERT1), ATTRS1); in test_cert_key_encrypted_content()
563 add_keybag(pb, KEY1, sizeof(KEY1), ATTRS1, &enc_default); in test_cert_key_encrypted_content()
565 end_contentinfo_encrypted(pb, &enc_default); in test_cert_key_encrypted_content()
567 end_pkcs12_with_mac(pb, &mac_default); in test_cert_key_encrypted_content()
570 start_check_pkcs12_with_mac(pb, &mac_default); in test_cert_key_encrypted_content()
572 start_check_contentinfo_encrypted(pb, &enc_default); in test_cert_key_encrypted_content()
574 check_certbag(pb, CERT1, sizeof(CERT1), ATTRS1); in test_cert_key_encrypted_content()
575 check_keybag(pb, KEY1, sizeof(KEY1), ATTRS1, &enc_default); in test_cert_key_encrypted_content()
577 end_check_contentinfo(pb); in test_cert_key_encrypted_content()
579 end_check_pkcs12(pb); in test_cert_key_encrypted_content()
581 return end_pkcs12_builder(pb); in test_cert_key_encrypted_content()
586 PKCS12_BUILDER *pb = new_pkcs12_builder("1secret.p12"); in test_single_secret_encrypted_content() local
590 start_pkcs12(pb); in test_single_secret_encrypted_content()
592 start_contentinfo(pb); in test_single_secret_encrypted_content()
594 add_secretbag(pb, custom_nid, "VerySecretMessage", ATTRS1); in test_single_secret_encrypted_content()
596 end_contentinfo_encrypted(pb, &enc_default); in test_single_secret_encrypted_content()
598 end_pkcs12_with_mac(pb, &mac_default); in test_single_secret_encrypted_content()
601 start_check_pkcs12_with_mac(pb, &mac_default); in test_single_secret_encrypted_content()
603 start_check_contentinfo_encrypted(pb, &enc_default); in test_single_secret_encrypted_content()
605 check_secretbag(pb, custom_nid, "VerySecretMessage", ATTRS1); in test_single_secret_encrypted_content()
607 end_check_contentinfo(pb); in test_single_secret_encrypted_content()
609 end_check_pkcs12(pb); in test_single_secret_encrypted_content()
611 return end_pkcs12_builder(pb); in test_single_secret_encrypted_content()
618 PKCS12_BUILDER *pb; in test_single_secret() local
621 pb = new_pkcs12_builder(fname); in test_single_secret()
625 start_pkcs12(pb); in test_single_secret()
627 start_contentinfo(pb); in test_single_secret()
629 add_secretbag(pb, custom_nid, "VerySecretMessage", ATTRS1); in test_single_secret()
631 end_contentinfo_encrypted(pb, enc); in test_single_secret()
633 end_pkcs12_with_mac(pb, &mac_default); in test_single_secret()
636 start_check_pkcs12_with_mac(pb, &mac_default); in test_single_secret()
638 start_check_contentinfo_encrypted(pb, enc); in test_single_secret()
640 check_secretbag(pb, custom_nid, "VerySecretMessage", ATTRS1); in test_single_secret()
642 end_check_contentinfo(pb); in test_single_secret()
644 end_check_pkcs12(pb); in test_single_secret()
646 return end_pkcs12_builder(pb); in test_single_secret()
665 PKCS12_BUILDER *pb = new_pkcs12_builder("multi_contents.p12"); in test_multiple_contents() local
669 start_pkcs12(pb); in test_multiple_contents()
671 start_contentinfo(pb); in test_multiple_contents()
673 add_certbag(pb, CERT1, sizeof(CERT1), ATTRS1); in test_multiple_contents()
674 add_certbag(pb, CERT2, sizeof(CERT2), ATTRS2); in test_multiple_contents()
675 add_keybag(pb, KEY1, sizeof(KEY1), ATTRS1, &enc_default); in test_multiple_contents()
676 add_keybag(pb, KEY2, sizeof(KEY2), ATTRS2, &enc_default); in test_multiple_contents()
678 end_contentinfo(pb); in test_multiple_contents()
680 start_contentinfo(pb); in test_multiple_contents()
682 add_secretbag(pb, custom_nid, "VeryVerySecretMessage", ATTRS1); in test_multiple_contents()
684 end_contentinfo_encrypted(pb, &enc_default); in test_multiple_contents()
686 end_pkcs12_with_mac(pb, &mac_default); in test_multiple_contents()
689 start_check_pkcs12_with_mac(pb, &mac_default); in test_multiple_contents()
691 start_check_contentinfo(pb); in test_multiple_contents()
693 check_certbag(pb, CERT1, sizeof(CERT1), ATTRS1); in test_multiple_contents()
694 check_certbag(pb, CERT2, sizeof(CERT2), ATTRS2); in test_multiple_contents()
695 check_keybag(pb, KEY1, sizeof(KEY1), ATTRS1, &enc_default); in test_multiple_contents()
696 check_keybag(pb, KEY2, sizeof(KEY2), ATTRS2, &enc_default); in test_multiple_contents()
698 end_check_contentinfo(pb); in test_multiple_contents()
700 start_check_contentinfo_encrypted(pb, &enc_default); in test_multiple_contents()
702 check_secretbag(pb, custom_nid, "VeryVerySecretMessage", ATTRS1); in test_multiple_contents()
704 end_check_contentinfo(pb); in test_multiple_contents()
706 end_check_pkcs12(pb); in test_multiple_contents()
708 return end_pkcs12_builder(pb); in test_multiple_contents()