539 509 | .use_fips(false)
|
540 510 | .build()
|
541 511 | .expect("invalid params");
|
542 512 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
543 513 | let endpoint = resolver.resolve_endpoint(¶ms);
|
544 514 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.dualstack.us-west-2.amazonaws.com/99_ab");
|
545 515 | assert_eq!(
|
546 516 | endpoint,
|
547 517 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
548 518 | .url("https://s3.dualstack.us-west-2.amazonaws.com/99_ab")
|
549 - | .property(
|
550 - | "authSchemes",
|
551 - | vec![{
|
552 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
553 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
554 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
555 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
556 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
557 - | out
|
558 - | }
|
559 - | .into()]
|
519 + | .auth_scheme(
|
520 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
521 + | .put("disableDoubleEncoding", true)
|
522 + | .put("signingName", "s3".to_string())
|
523 + | .put("signingRegion", "us-west-2".to_string())
|
560 524 | )
|
561 525 | .build()
|
562 526 | );
|
563 527 | }
|
564 528 |
|
565 529 | /// implicit path style bucket + dualstack
|
566 530 | #[test]
|
567 531 | fn test_24() {
|
568 532 | let params = crate::config::endpoint::Params::builder()
|
569 533 | .accelerate(false)
|
570 534 | .bucket("99_ab".to_string())
|
571 535 | .region("us-west-2".to_string())
|
572 536 | .use_dual_stack(true)
|
573 537 | .use_fips(false)
|
574 538 | .endpoint("http://abc.com".to_string())
|
575 539 | .build()
|
576 540 | .expect("invalid params");
|
577 541 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
578 542 | let endpoint = resolver.resolve_endpoint(¶ms);
|
579 543 | let error = endpoint
|
580 544 | .expect_err("expected error: Cannot set dual-stack in combination with a custom endpoint. [implicit path style bucket + dualstack]");
|
581 545 | assert_eq!(format!("{}", error), "Cannot set dual-stack in combination with a custom endpoint.")
|
582 546 | }
|
583 547 |
|
584 548 | /// don't allow URL injections in the bucket
|
585 549 | #[test]
|
586 550 | fn test_25() {
|
587 551 | let params = crate::config::endpoint::Params::builder()
|
588 552 | .bucket("example.com#".to_string())
|
589 553 | .region("us-west-2".to_string())
|
590 554 | .use_dual_stack(false)
|
591 555 | .use_fips(false)
|
592 556 | .accelerate(false)
|
593 557 | .build()
|
594 558 | .expect("invalid params");
|
595 559 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
596 560 | let endpoint = resolver.resolve_endpoint(¶ms);
|
597 561 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.us-west-2.amazonaws.com/example.com%23");
|
598 562 | assert_eq!(
|
599 563 | endpoint,
|
600 564 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
601 565 | .url("https://s3.us-west-2.amazonaws.com/example.com%23")
|
602 - | .property(
|
603 - | "authSchemes",
|
604 - | vec![{
|
605 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
606 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
607 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
608 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
609 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
610 - | out
|
611 - | }
|
612 - | .into()]
|
566 + | .auth_scheme(
|
567 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
568 + | .put("disableDoubleEncoding", true)
|
569 + | .put("signingName", "s3".to_string())
|
570 + | .put("signingRegion", "us-west-2".to_string())
|
613 571 | )
|
614 572 | .build()
|
615 573 | );
|
616 574 | }
|
617 575 |
|
618 576 | /// URI encode bucket names in the path
|
619 577 | #[test]
|
620 578 | fn test_26() {
|
621 579 | let params = crate::config::endpoint::Params::builder()
|
622 580 | .bucket("bucket name".to_string())
|
623 581 | .region("us-west-2".to_string())
|
624 582 | .use_dual_stack(false)
|
625 583 | .use_fips(false)
|
626 584 | .accelerate(false)
|
627 585 | .build()
|
628 586 | .expect("invalid params");
|
629 587 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
630 588 | let endpoint = resolver.resolve_endpoint(¶ms);
|
631 589 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.us-west-2.amazonaws.com/bucket%20name");
|
632 590 | assert_eq!(
|
633 591 | endpoint,
|
634 592 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
635 593 | .url("https://s3.us-west-2.amazonaws.com/bucket%20name")
|
636 - | .property(
|
637 - | "authSchemes",
|
638 - | vec![{
|
639 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
640 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
641 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
642 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
643 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
644 - | out
|
645 - | }
|
646 - | .into()]
|
594 + | .auth_scheme(
|
595 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
596 + | .put("disableDoubleEncoding", true)
|
597 + | .put("signingName", "s3".to_string())
|
598 + | .put("signingRegion", "us-west-2".to_string())
|
647 599 | )
|
648 600 | .build()
|
649 601 | );
|
650 602 | }
|
651 603 |
|
652 604 | /// scheme is respected
|
653 605 | #[test]
|
654 606 | fn test_27() {
|
655 607 | let params = crate::config::endpoint::Params::builder()
|
656 608 | .accelerate(false)
|
657 609 | .bucket("99_ab".to_string())
|
658 610 | .endpoint("http://control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com".to_string())
|
659 611 | .region("af-south-1".to_string())
|
660 612 | .use_dual_stack(false)
|
661 613 | .use_fips(false)
|
662 614 | .build()
|
663 615 | .expect("invalid params");
|
664 616 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
665 617 | let endpoint = resolver.resolve_endpoint(¶ms);
|
666 618 | let endpoint = endpoint.expect("Expected valid endpoint: http://control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com/99_ab");
|
667 619 | assert_eq!(
|
668 620 | endpoint,
|
669 621 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
670 622 | .url("http://control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com/99_ab")
|
671 - | .property(
|
672 - | "authSchemes",
|
673 - | vec![{
|
674 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
675 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
676 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
677 - | out.insert("signingRegion".to_string(), "af-south-1".to_string().into());
|
678 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
679 - | out
|
680 - | }
|
681 - | .into()]
|
623 + | .auth_scheme(
|
624 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
625 + | .put("disableDoubleEncoding", true)
|
626 + | .put("signingName", "s3".to_string())
|
627 + | .put("signingRegion", "af-south-1".to_string())
|
682 628 | )
|
683 629 | .build()
|
684 630 | );
|
685 631 | }
|
686 632 |
|
687 633 | /// scheme is respected (virtual addressing)
|
688 634 | #[test]
|
689 635 | fn test_28() {
|
690 636 | let params = crate::config::endpoint::Params::builder()
|
691 637 | .accelerate(false)
|
692 638 | .bucket("bucketname".to_string())
|
693 639 | .endpoint("http://control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com/foo".to_string())
|
694 640 | .region("af-south-1".to_string())
|
695 641 | .use_dual_stack(false)
|
696 642 | .use_fips(false)
|
697 643 | .build()
|
698 644 | .expect("invalid params");
|
699 645 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
700 646 | let endpoint = resolver.resolve_endpoint(¶ms);
|
701 647 | let endpoint = endpoint.expect("Expected valid endpoint: http://bucketname.control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com/foo");
|
702 648 | assert_eq!(
|
703 649 | endpoint,
|
704 650 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
705 651 | .url("http://bucketname.control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com/foo")
|
706 - | .property(
|
707 - | "authSchemes",
|
708 - | vec![{
|
709 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
710 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
711 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
712 - | out.insert("signingRegion".to_string(), "af-south-1".to_string().into());
|
713 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
714 - | out
|
715 - | }
|
716 - | .into()]
|
652 + | .auth_scheme(
|
653 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
654 + | .put("disableDoubleEncoding", true)
|
655 + | .put("signingName", "s3".to_string())
|
656 + | .put("signingRegion", "af-south-1".to_string())
|
717 657 | )
|
718 658 | .build()
|
719 659 | );
|
720 660 | }
|
721 661 |
|
722 662 | /// path style + implicit private link
|
723 663 | #[test]
|
724 664 | fn test_29() {
|
725 665 | let params = crate::config::endpoint::Params::builder()
|
726 666 | .accelerate(false)
|
727 667 | .bucket("99_ab".to_string())
|
728 668 | .endpoint("https://control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com".to_string())
|
729 669 | .region("af-south-1".to_string())
|
730 670 | .use_dual_stack(false)
|
731 671 | .use_fips(false)
|
732 672 | .build()
|
733 673 | .expect("invalid params");
|
734 674 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
735 675 | let endpoint = resolver.resolve_endpoint(¶ms);
|
736 676 | let endpoint = endpoint.expect("Expected valid endpoint: https://control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com/99_ab");
|
737 677 | assert_eq!(
|
738 678 | endpoint,
|
739 679 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
740 680 | .url("https://control.vpce-1a2b3c4d-5e6f.s3.us-west-2.vpce.amazonaws.com/99_ab")
|
741 - | .property(
|
742 - | "authSchemes",
|
743 - | vec![{
|
744 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
745 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
746 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
747 - | out.insert("signingRegion".to_string(), "af-south-1".to_string().into());
|
748 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
749 - | out
|
750 - | }
|
751 - | .into()]
|
681 + | .auth_scheme(
|
682 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
683 + | .put("disableDoubleEncoding", true)
|
684 + | .put("signingName", "s3".to_string())
|
685 + | .put("signingRegion", "af-south-1".to_string())
|
752 686 | )
|
753 687 | .build()
|
754 688 | );
|
755 689 | }
|
756 690 |
|
757 691 | /// invalid Endpoint override
|
758 692 | #[test]
|
759 693 | fn test_30() {
|
760 694 | let params = crate::config::endpoint::Params::builder()
|
761 695 | .accelerate(false)
|
762 696 | .bucket("bucketname".to_string())
|
763 697 | .endpoint("abcde://nota#url".to_string())
|
764 698 | .region("af-south-1".to_string())
|
765 699 | .use_dual_stack(false)
|
766 700 | .use_fips(false)
|
767 701 | .build()
|
768 702 | .expect("invalid params");
|
769 703 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
770 704 | let endpoint = resolver.resolve_endpoint(¶ms);
|
771 705 | let error = endpoint.expect_err("expected error: Custom endpoint `abcde://nota#url` was not a valid URI [invalid Endpoint override]");
|
772 706 | assert_eq!(format!("{}", error), "Custom endpoint `abcde://nota#url` was not a valid URI")
|
773 707 | }
|
774 708 |
|
775 709 | /// using an IPv4 address forces path style
|
776 710 | #[test]
|
777 711 | fn test_31() {
|
778 712 | let params = crate::config::endpoint::Params::builder()
|
779 713 | .accelerate(false)
|
780 714 | .bucket("bucketname".to_string())
|
781 715 | .endpoint("https://123.123.0.1".to_string())
|
782 716 | .region("af-south-1".to_string())
|
783 717 | .use_dual_stack(false)
|
784 718 | .use_fips(false)
|
785 719 | .build()
|
786 720 | .expect("invalid params");
|
787 721 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
788 722 | let endpoint = resolver.resolve_endpoint(¶ms);
|
789 723 | let endpoint = endpoint.expect("Expected valid endpoint: https://123.123.0.1/bucketname");
|
790 724 | assert_eq!(
|
791 725 | endpoint,
|
792 726 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
793 727 | .url("https://123.123.0.1/bucketname")
|
794 - | .property(
|
795 - | "authSchemes",
|
796 - | vec![{
|
797 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
798 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
799 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
800 - | out.insert("signingRegion".to_string(), "af-south-1".to_string().into());
|
801 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
802 - | out
|
803 - | }
|
804 - | .into()]
|
728 + | .auth_scheme(
|
729 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
730 + | .put("disableDoubleEncoding", true)
|
731 + | .put("signingName", "s3".to_string())
|
732 + | .put("signingRegion", "af-south-1".to_string())
|
805 733 | )
|
806 734 | .build()
|
807 735 | );
|
808 736 | }
|
809 737 |
|
810 738 | /// vanilla access point arn with region mismatch and UseArnRegion=false
|
811 739 | #[test]
|
812 740 | fn test_32() {
|
813 741 | let params = crate::config::endpoint::Params::builder()
|
814 742 | .accelerate(false)
|
815 743 | .bucket("arn:aws:s3:us-east-1:123456789012:accesspoint:myendpoint".to_string())
|
816 744 | .force_path_style(false)
|
817 745 | .use_arn_region(false)
|
818 746 | .region("us-west-2".to_string())
|
819 747 | .use_dual_stack(false)
|
820 748 | .use_fips(false)
|
821 749 | .build()
|
822 750 | .expect("invalid params");
|
823 751 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
824 752 | let endpoint = resolver.resolve_endpoint(¶ms);
|
825 753 | let error = endpoint.expect_err("expected error: Invalid configuration: region from ARN `us-east-1` does not match client region `us-west-2` and UseArnRegion is `false` [vanilla access point arn with region mismatch and UseArnRegion=false]");
|
826 754 | assert_eq!(
|
827 755 | format!("{}", error),
|
828 756 | "Invalid configuration: region from ARN `us-east-1` does not match client region `us-west-2` and UseArnRegion is `false`"
|
829 757 | )
|
830 758 | }
|
831 759 |
|
832 760 | /// vanilla access point arn with region mismatch and UseArnRegion unset
|
833 761 | #[test]
|
834 762 | fn test_33() {
|
835 763 | let params = crate::config::endpoint::Params::builder()
|
836 764 | .accelerate(false)
|
837 765 | .bucket("arn:aws:s3:us-west-2:123456789012:accesspoint:myendpoint".to_string())
|
838 766 | .force_path_style(false)
|
839 767 | .region("us-east-1".to_string())
|
840 768 | .use_dual_stack(false)
|
841 769 | .use_fips(false)
|
842 770 | .build()
|
843 771 | .expect("invalid params");
|
844 772 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
845 773 | let endpoint = resolver.resolve_endpoint(¶ms);
|
846 774 | let endpoint = endpoint.expect("Expected valid endpoint: https://myendpoint-123456789012.s3-accesspoint.us-west-2.amazonaws.com");
|
847 775 | assert_eq!(
|
848 776 | endpoint,
|
849 777 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
850 778 | .url("https://myendpoint-123456789012.s3-accesspoint.us-west-2.amazonaws.com")
|
851 - | .property(
|
852 - | "authSchemes",
|
853 - | vec![{
|
854 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
855 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
856 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
857 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
858 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
859 - | out
|
860 - | }
|
861 - | .into()]
|
779 + | .auth_scheme(
|
780 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
781 + | .put("disableDoubleEncoding", true)
|
782 + | .put("signingName", "s3".to_string())
|
783 + | .put("signingRegion", "us-west-2".to_string())
|
862 784 | )
|
863 785 | .build()
|
864 786 | );
|
865 787 | }
|
866 788 |
|
867 789 | /// vanilla access point arn with region mismatch and UseArnRegion=true
|
868 790 | #[test]
|
869 791 | fn test_34() {
|
870 792 | let params = crate::config::endpoint::Params::builder()
|
871 793 | .accelerate(false)
|
872 794 | .bucket("arn:aws:s3:us-west-2:123456789012:accesspoint:myendpoint".to_string())
|
873 795 | .force_path_style(false)
|
874 796 | .use_arn_region(true)
|
875 797 | .region("us-east-1".to_string())
|
876 798 | .use_dual_stack(false)
|
877 799 | .use_fips(false)
|
878 800 | .build()
|
879 801 | .expect("invalid params");
|
880 802 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
881 803 | let endpoint = resolver.resolve_endpoint(¶ms);
|
882 804 | let endpoint = endpoint.expect("Expected valid endpoint: https://myendpoint-123456789012.s3-accesspoint.us-west-2.amazonaws.com");
|
883 805 | assert_eq!(
|
884 806 | endpoint,
|
885 807 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
886 808 | .url("https://myendpoint-123456789012.s3-accesspoint.us-west-2.amazonaws.com")
|
887 - | .property(
|
888 - | "authSchemes",
|
889 - | vec![{
|
890 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
891 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
892 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
893 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
894 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
895 - | out
|
896 - | }
|
897 - | .into()]
|
809 + | .auth_scheme(
|
810 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
811 + | .put("disableDoubleEncoding", true)
|
812 + | .put("signingName", "s3".to_string())
|
813 + | .put("signingRegion", "us-west-2".to_string())
|
898 814 | )
|
899 815 | .build()
|
900 816 | );
|
901 817 | }
|
902 818 |
|
903 819 | /// subdomains are not allowed in virtual buckets
|
904 820 | #[test]
|
905 821 | fn test_35() {
|
906 822 | let params = crate::config::endpoint::Params::builder()
|
907 823 | .bucket("bucket.name".to_string())
|
908 824 | .region("us-east-1".to_string())
|
909 825 | .build()
|
910 826 | .expect("invalid params");
|
911 827 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
912 828 | let endpoint = resolver.resolve_endpoint(¶ms);
|
913 829 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.us-east-1.amazonaws.com/bucket.name");
|
914 830 | assert_eq!(
|
915 831 | endpoint,
|
916 832 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
917 833 | .url("https://s3.us-east-1.amazonaws.com/bucket.name")
|
918 - | .property(
|
919 - | "authSchemes",
|
920 - | vec![{
|
921 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
922 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
923 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
924 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
925 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
926 - | out
|
927 - | }
|
928 - | .into()]
|
834 + | .auth_scheme(
|
835 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
836 + | .put("disableDoubleEncoding", true)
|
837 + | .put("signingName", "s3".to_string())
|
838 + | .put("signingRegion", "us-east-1".to_string())
|
929 839 | )
|
930 840 | .build()
|
931 841 | );
|
932 842 | }
|
933 843 |
|
934 844 | /// bucket names with 3 characters are allowed in virtual buckets
|
935 845 | #[test]
|
936 846 | fn test_36() {
|
937 847 | let params = crate::config::endpoint::Params::builder()
|
938 848 | .bucket("aaa".to_string())
|
939 849 | .region("us-east-1".to_string())
|
940 850 | .build()
|
941 851 | .expect("invalid params");
|
942 852 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
943 853 | let endpoint = resolver.resolve_endpoint(¶ms);
|
944 854 | let endpoint = endpoint.expect("Expected valid endpoint: https://aaa.s3.us-east-1.amazonaws.com");
|
945 855 | assert_eq!(
|
946 856 | endpoint,
|
947 857 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
948 858 | .url("https://aaa.s3.us-east-1.amazonaws.com")
|
949 - | .property(
|
950 - | "authSchemes",
|
951 - | vec![{
|
952 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
953 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
954 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
955 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
956 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
957 - | out
|
958 - | }
|
959 - | .into()]
|
859 + | .auth_scheme(
|
860 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
861 + | .put("disableDoubleEncoding", true)
|
862 + | .put("signingName", "s3".to_string())
|
863 + | .put("signingRegion", "us-east-1".to_string())
|
960 864 | )
|
961 865 | .build()
|
962 866 | );
|
963 867 | }
|
964 868 |
|
965 869 | /// bucket names with fewer than 3 characters are not allowed in virtual host
|
966 870 | #[test]
|
967 871 | fn test_37() {
|
968 872 | let params = crate::config::endpoint::Params::builder()
|
969 873 | .bucket("aa".to_string())
|
970 874 | .region("us-east-1".to_string())
|
971 875 | .build()
|
972 876 | .expect("invalid params");
|
973 877 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
974 878 | let endpoint = resolver.resolve_endpoint(¶ms);
|
975 879 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.us-east-1.amazonaws.com/aa");
|
976 880 | assert_eq!(
|
977 881 | endpoint,
|
978 882 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
979 883 | .url("https://s3.us-east-1.amazonaws.com/aa")
|
980 - | .property(
|
981 - | "authSchemes",
|
982 - | vec![{
|
983 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
984 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
985 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
986 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
987 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
988 - | out
|
989 - | }
|
990 - | .into()]
|
884 + | .auth_scheme(
|
885 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
886 + | .put("disableDoubleEncoding", true)
|
887 + | .put("signingName", "s3".to_string())
|
888 + | .put("signingRegion", "us-east-1".to_string())
|
991 889 | )
|
992 890 | .build()
|
993 891 | );
|
994 892 | }
|
995 893 |
|
996 894 | /// bucket names with uppercase characters are not allowed in virtual host
|
997 895 | #[test]
|
998 896 | fn test_38() {
|
999 897 | let params = crate::config::endpoint::Params::builder()
|
1000 898 | .bucket("BucketName".to_string())
|
1001 899 | .region("us-east-1".to_string())
|
1002 900 | .build()
|
1003 901 | .expect("invalid params");
|
1004 902 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1005 903 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1006 904 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.us-east-1.amazonaws.com/BucketName");
|
1007 905 | assert_eq!(
|
1008 906 | endpoint,
|
1009 907 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1010 908 | .url("https://s3.us-east-1.amazonaws.com/BucketName")
|
1011 - | .property(
|
1012 - | "authSchemes",
|
1013 - | vec![{
|
1014 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1015 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1016 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1017 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1018 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1019 - | out
|
1020 - | }
|
1021 - | .into()]
|
909 + | .auth_scheme(
|
910 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
911 + | .put("disableDoubleEncoding", true)
|
912 + | .put("signingName", "s3".to_string())
|
913 + | .put("signingRegion", "us-east-1".to_string())
|
1022 914 | )
|
1023 915 | .build()
|
1024 916 | );
|
1025 917 | }
|
1026 918 |
|
1027 919 | /// subdomains are allowed in virtual buckets on http endpoints
|
1028 920 | #[test]
|
1029 921 | fn test_39() {
|
1030 922 | let params = crate::config::endpoint::Params::builder()
|
1031 923 | .bucket("bucket.name".to_string())
|
1032 924 | .region("us-east-1".to_string())
|
1033 925 | .endpoint("http://example.com".to_string())
|
1034 926 | .build()
|
1035 927 | .expect("invalid params");
|
1036 928 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1037 929 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1038 930 | let endpoint = endpoint.expect("Expected valid endpoint: http://bucket.name.example.com");
|
1039 931 | assert_eq!(
|
1040 932 | endpoint,
|
1041 933 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1042 934 | .url("http://bucket.name.example.com")
|
1043 - | .property(
|
1044 - | "authSchemes",
|
1045 - | vec![{
|
1046 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1047 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1048 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1049 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1050 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1051 - | out
|
1052 - | }
|
1053 - | .into()]
|
935 + | .auth_scheme(
|
936 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
937 + | .put("disableDoubleEncoding", true)
|
938 + | .put("signingName", "s3".to_string())
|
939 + | .put("signingRegion", "us-east-1".to_string())
|
1054 940 | )
|
1055 941 | .build()
|
1056 942 | );
|
1057 943 | }
|
1058 944 |
|
1059 945 | /// no region set
|
1060 946 | #[test]
|
1061 947 | fn test_40() {
|
1062 948 | let params = crate::config::endpoint::Params::builder()
|
1063 949 | .bucket("bucket-name".to_string())
|
1064 950 | .build()
|
1065 951 | .expect("invalid params");
|
1066 952 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1067 953 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1068 954 | let error = endpoint.expect_err("expected error: A region must be set when sending requests to S3. [no region set]");
|
1069 955 | assert_eq!(format!("{}", error), "A region must be set when sending requests to S3.")
|
1070 956 | }
|
1071 957 |
|
1072 958 | /// UseGlobalEndpoints=true, region=us-east-1 uses the global endpoint
|
1073 959 | #[test]
|
1074 960 | fn test_41() {
|
1075 961 | let params = crate::config::endpoint::Params::builder()
|
1076 962 | .region("us-east-1".to_string())
|
1077 963 | .use_global_endpoint(true)
|
1078 964 | .use_fips(false)
|
1079 965 | .use_dual_stack(false)
|
1080 966 | .accelerate(false)
|
1081 967 | .build()
|
1082 968 | .expect("invalid params");
|
1083 969 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1084 970 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1085 971 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.amazonaws.com");
|
1086 972 | assert_eq!(
|
1087 973 | endpoint,
|
1088 974 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1089 975 | .url("https://s3.amazonaws.com")
|
1090 - | .property(
|
1091 - | "authSchemes",
|
1092 - | vec![{
|
1093 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1094 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1095 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1096 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1097 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1098 - | out
|
1099 - | }
|
1100 - | .into()]
|
976 + | .auth_scheme(
|
977 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
978 + | .put("disableDoubleEncoding", true)
|
979 + | .put("signingName", "s3".to_string())
|
980 + | .put("signingRegion", "us-east-1".to_string())
|
1101 981 | )
|
1102 982 | .build()
|
1103 983 | );
|
1104 984 | }
|
1105 985 |
|
1106 986 | /// UseGlobalEndpoints=true, region=us-west-2 uses the regional endpoint
|
1107 987 | #[test]
|
1108 988 | fn test_42() {
|
1109 989 | let params = crate::config::endpoint::Params::builder()
|
1110 990 | .region("us-west-2".to_string())
|
1111 991 | .use_global_endpoint(true)
|
1112 992 | .use_fips(false)
|
1113 993 | .use_dual_stack(false)
|
1114 994 | .accelerate(false)
|
1115 995 | .build()
|
1116 996 | .expect("invalid params");
|
1117 997 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1118 998 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1119 999 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.us-west-2.amazonaws.com");
|
1120 1000 | assert_eq!(
|
1121 1001 | endpoint,
|
1122 1002 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1123 1003 | .url("https://s3.us-west-2.amazonaws.com")
|
1124 - | .property(
|
1125 - | "authSchemes",
|
1126 - | vec![{
|
1127 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1128 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1129 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1130 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
1131 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1132 - | out
|
1133 - | }
|
1134 - | .into()]
|
1004 + | .auth_scheme(
|
1005 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1006 + | .put("disableDoubleEncoding", true)
|
1007 + | .put("signingName", "s3".to_string())
|
1008 + | .put("signingRegion", "us-west-2".to_string())
|
1135 1009 | )
|
1136 1010 | .build()
|
1137 1011 | );
|
1138 1012 | }
|
1139 1013 |
|
1140 1014 | /// UseGlobalEndpoints=true, region=cn-north-1 uses the regional endpoint
|
1141 1015 | #[test]
|
1142 1016 | fn test_43() {
|
1143 1017 | let params = crate::config::endpoint::Params::builder()
|
1144 1018 | .region("cn-north-1".to_string())
|
1145 1019 | .use_global_endpoint(true)
|
1146 1020 | .use_fips(false)
|
1147 1021 | .use_dual_stack(false)
|
1148 1022 | .accelerate(false)
|
1149 1023 | .build()
|
1150 1024 | .expect("invalid params");
|
1151 1025 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1152 1026 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1153 1027 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.cn-north-1.amazonaws.com.cn");
|
1154 1028 | assert_eq!(
|
1155 1029 | endpoint,
|
1156 1030 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1157 1031 | .url("https://s3.cn-north-1.amazonaws.com.cn")
|
1158 - | .property(
|
1159 - | "authSchemes",
|
1160 - | vec![{
|
1161 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1162 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1163 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1164 - | out.insert("signingRegion".to_string(), "cn-north-1".to_string().into());
|
1165 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1166 - | out
|
1167 - | }
|
1168 - | .into()]
|
1032 + | .auth_scheme(
|
1033 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1034 + | .put("disableDoubleEncoding", true)
|
1035 + | .put("signingName", "s3".to_string())
|
1036 + | .put("signingRegion", "cn-north-1".to_string())
|
1169 1037 | )
|
1170 1038 | .build()
|
1171 1039 | );
|
1172 1040 | }
|
1173 1041 |
|
1174 1042 | /// UseGlobalEndpoints=true, region=us-east-1, fips=true uses the regional endpoint with fips
|
1175 1043 | #[test]
|
1176 1044 | fn test_44() {
|
1177 1045 | let params = crate::config::endpoint::Params::builder()
|
1178 1046 | .region("us-east-1".to_string())
|
1179 1047 | .use_global_endpoint(true)
|
1180 1048 | .use_fips(true)
|
1181 1049 | .use_dual_stack(false)
|
1182 1050 | .accelerate(false)
|
1183 1051 | .build()
|
1184 1052 | .expect("invalid params");
|
1185 1053 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1186 1054 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1187 1055 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3-fips.us-east-1.amazonaws.com");
|
1188 1056 | assert_eq!(
|
1189 1057 | endpoint,
|
1190 1058 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1191 1059 | .url("https://s3-fips.us-east-1.amazonaws.com")
|
1192 - | .property(
|
1193 - | "authSchemes",
|
1194 - | vec![{
|
1195 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1196 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1197 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1198 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1199 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1200 - | out
|
1201 - | }
|
1202 - | .into()]
|
1060 + | .auth_scheme(
|
1061 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1062 + | .put("disableDoubleEncoding", true)
|
1063 + | .put("signingName", "s3".to_string())
|
1064 + | .put("signingRegion", "us-east-1".to_string())
|
1203 1065 | )
|
1204 1066 | .build()
|
1205 1067 | );
|
1206 1068 | }
|
1207 1069 |
|
1208 1070 | /// UseGlobalEndpoints=true, region=us-east-1, dualstack=true uses the regional endpoint with dualstack
|
1209 1071 | #[test]
|
1210 1072 | fn test_45() {
|
1211 1073 | let params = crate::config::endpoint::Params::builder()
|
1212 1074 | .region("us-east-1".to_string())
|
1213 1075 | .use_global_endpoint(true)
|
1214 1076 | .use_fips(false)
|
1215 1077 | .use_dual_stack(true)
|
1216 1078 | .accelerate(false)
|
1217 1079 | .build()
|
1218 1080 | .expect("invalid params");
|
1219 1081 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1220 1082 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1221 1083 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.dualstack.us-east-1.amazonaws.com");
|
1222 1084 | assert_eq!(
|
1223 1085 | endpoint,
|
1224 1086 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1225 1087 | .url("https://s3.dualstack.us-east-1.amazonaws.com")
|
1226 - | .property(
|
1227 - | "authSchemes",
|
1228 - | vec![{
|
1229 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1230 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1231 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1232 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1233 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1234 - | out
|
1235 - | }
|
1236 - | .into()]
|
1088 + | .auth_scheme(
|
1089 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1090 + | .put("disableDoubleEncoding", true)
|
1091 + | .put("signingName", "s3".to_string())
|
1092 + | .put("signingRegion", "us-east-1".to_string())
|
1237 1093 | )
|
1238 1094 | .build()
|
1239 1095 | );
|
1240 1096 | }
|
1241 1097 |
|
1242 1098 | /// UseGlobalEndpoints=true, region=us-east-1, dualstack and fips uses the regional endpoint with fips/dualstack
|
1243 1099 | #[test]
|
1244 1100 | fn test_46() {
|
1245 1101 | let params = crate::config::endpoint::Params::builder()
|
1246 1102 | .region("us-east-1".to_string())
|
1247 1103 | .use_global_endpoint(true)
|
1248 1104 | .use_fips(true)
|
1249 1105 | .use_dual_stack(true)
|
1250 1106 | .accelerate(false)
|
1251 1107 | .build()
|
1252 1108 | .expect("invalid params");
|
1253 1109 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1254 1110 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1255 1111 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3-fips.dualstack.us-east-1.amazonaws.com");
|
1256 1112 | assert_eq!(
|
1257 1113 | endpoint,
|
1258 1114 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1259 1115 | .url("https://s3-fips.dualstack.us-east-1.amazonaws.com")
|
1260 - | .property(
|
1261 - | "authSchemes",
|
1262 - | vec![{
|
1263 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1264 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1265 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1266 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1267 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1268 - | out
|
1269 - | }
|
1270 - | .into()]
|
1116 + | .auth_scheme(
|
1117 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1118 + | .put("disableDoubleEncoding", true)
|
1119 + | .put("signingName", "s3".to_string())
|
1120 + | .put("signingRegion", "us-east-1".to_string())
|
1271 1121 | )
|
1272 1122 | .build()
|
1273 1123 | );
|
1274 1124 | }
|
1275 1125 |
|
1276 1126 | /// UseGlobalEndpoints=true, region=us-east-1 with custom endpoint, uses custom
|
1277 1127 | #[test]
|
1278 1128 | fn test_47() {
|
1279 1129 | let params = crate::config::endpoint::Params::builder()
|
1280 1130 | .region("us-east-1".to_string())
|
1281 1131 | .endpoint("https://example.com".to_string())
|
1282 1132 | .use_global_endpoint(true)
|
1283 1133 | .use_fips(false)
|
1284 1134 | .use_dual_stack(false)
|
1285 1135 | .accelerate(false)
|
1286 1136 | .build()
|
1287 1137 | .expect("invalid params");
|
1288 1138 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1289 1139 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1290 1140 | let endpoint = endpoint.expect("Expected valid endpoint: https://example.com");
|
1291 1141 | assert_eq!(
|
1292 1142 | endpoint,
|
1293 1143 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1294 1144 | .url("https://example.com")
|
1295 - | .property(
|
1296 - | "authSchemes",
|
1297 - | vec![{
|
1298 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1299 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1300 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1301 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1302 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1303 - | out
|
1304 - | }
|
1305 - | .into()]
|
1145 + | .auth_scheme(
|
1146 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1147 + | .put("disableDoubleEncoding", true)
|
1148 + | .put("signingName", "s3".to_string())
|
1149 + | .put("signingRegion", "us-east-1".to_string())
|
1306 1150 | )
|
1307 1151 | .build()
|
1308 1152 | );
|
1309 1153 | }
|
1310 1154 |
|
1311 1155 | /// UseGlobalEndpoints=true, region=us-west-2 with custom endpoint, uses custom
|
1312 1156 | #[test]
|
1313 1157 | fn test_48() {
|
1314 1158 | let params = crate::config::endpoint::Params::builder()
|
1315 1159 | .region("us-west-2".to_string())
|
1316 1160 | .endpoint("https://example.com".to_string())
|
1317 1161 | .use_global_endpoint(true)
|
1318 1162 | .use_fips(false)
|
1319 1163 | .use_dual_stack(false)
|
1320 1164 | .accelerate(false)
|
1321 1165 | .build()
|
1322 1166 | .expect("invalid params");
|
1323 1167 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1324 1168 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1325 1169 | let endpoint = endpoint.expect("Expected valid endpoint: https://example.com");
|
1326 1170 | assert_eq!(
|
1327 1171 | endpoint,
|
1328 1172 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1329 1173 | .url("https://example.com")
|
1330 - | .property(
|
1331 - | "authSchemes",
|
1332 - | vec![{
|
1333 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1334 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1335 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1336 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
1337 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1338 - | out
|
1339 - | }
|
1340 - | .into()]
|
1174 + | .auth_scheme(
|
1175 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1176 + | .put("disableDoubleEncoding", true)
|
1177 + | .put("signingName", "s3".to_string())
|
1178 + | .put("signingRegion", "us-west-2".to_string())
|
1341 1179 | )
|
1342 1180 | .build()
|
1343 1181 | );
|
1344 1182 | }
|
1345 1183 |
|
1346 1184 | /// UseGlobalEndpoints=true, region=us-east-1 with accelerate on non bucket case uses the global endpoint and ignores accelerate
|
1347 1185 | #[test]
|
1348 1186 | fn test_49() {
|
1349 1187 | let params = crate::config::endpoint::Params::builder()
|
1350 1188 | .region("us-east-1".to_string())
|
1351 1189 | .use_global_endpoint(true)
|
1352 1190 | .use_fips(false)
|
1353 1191 | .use_dual_stack(false)
|
1354 1192 | .accelerate(true)
|
1355 1193 | .build()
|
1356 1194 | .expect("invalid params");
|
1357 1195 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1358 1196 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1359 1197 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.amazonaws.com");
|
1360 1198 | assert_eq!(
|
1361 1199 | endpoint,
|
1362 1200 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1363 1201 | .url("https://s3.amazonaws.com")
|
1364 - | .property(
|
1365 - | "authSchemes",
|
1366 - | vec![{
|
1367 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1368 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1369 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1370 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1371 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1372 - | out
|
1373 - | }
|
1374 - | .into()]
|
1202 + | .auth_scheme(
|
1203 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1204 + | .put("disableDoubleEncoding", true)
|
1205 + | .put("signingName", "s3".to_string())
|
1206 + | .put("signingRegion", "us-east-1".to_string())
|
1375 1207 | )
|
1376 1208 | .build()
|
1377 1209 | );
|
1378 1210 | }
|
1379 1211 |
|
1380 1212 | /// aws-global region uses the global endpoint
|
1381 1213 | #[test]
|
1382 1214 | fn test_50() {
|
1383 1215 | let params = crate::config::endpoint::Params::builder()
|
1384 1216 | .region("aws-global".to_string())
|
1385 1217 | .use_fips(false)
|
1386 1218 | .use_dual_stack(false)
|
1387 1219 | .accelerate(false)
|
1388 1220 | .build()
|
1389 1221 | .expect("invalid params");
|
1390 1222 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1391 1223 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1392 1224 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.amazonaws.com");
|
1393 1225 | assert_eq!(
|
1394 1226 | endpoint,
|
1395 1227 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1396 1228 | .url("https://s3.amazonaws.com")
|
1397 - | .property(
|
1398 - | "authSchemes",
|
1399 - | vec![{
|
1400 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1401 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1402 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1403 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1404 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1405 - | out
|
1406 - | }
|
1407 - | .into()]
|
1229 + | .auth_scheme(
|
1230 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1231 + | .put("disableDoubleEncoding", true)
|
1232 + | .put("signingName", "s3".to_string())
|
1233 + | .put("signingRegion", "us-east-1".to_string())
|
1408 1234 | )
|
1409 1235 | .build()
|
1410 1236 | );
|
1411 1237 | }
|
1412 1238 |
|
1413 1239 | /// aws-global region with fips uses the regional endpoint
|
1414 1240 | #[test]
|
1415 1241 | fn test_51() {
|
1416 1242 | let params = crate::config::endpoint::Params::builder()
|
1417 1243 | .region("aws-global".to_string())
|
1418 1244 | .use_fips(true)
|
1419 1245 | .use_dual_stack(false)
|
1420 1246 | .accelerate(false)
|
1421 1247 | .build()
|
1422 1248 | .expect("invalid params");
|
1423 1249 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1424 1250 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1425 1251 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3-fips.us-east-1.amazonaws.com");
|
1426 1252 | assert_eq!(
|
1427 1253 | endpoint,
|
1428 1254 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1429 1255 | .url("https://s3-fips.us-east-1.amazonaws.com")
|
1430 - | .property(
|
1431 - | "authSchemes",
|
1432 - | vec![{
|
1433 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1434 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1435 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1436 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1437 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1438 - | out
|
1439 - | }
|
1440 - | .into()]
|
1256 + | .auth_scheme(
|
1257 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1258 + | .put("disableDoubleEncoding", true)
|
1259 + | .put("signingName", "s3".to_string())
|
1260 + | .put("signingRegion", "us-east-1".to_string())
|
1441 1261 | )
|
1442 1262 | .build()
|
1443 1263 | );
|
1444 1264 | }
|
1445 1265 |
|
1446 1266 | /// aws-global region with dualstack uses the regional endpoint
|
1447 1267 | #[test]
|
1448 1268 | fn test_52() {
|
1449 1269 | let params = crate::config::endpoint::Params::builder()
|
1450 1270 | .region("aws-global".to_string())
|
1451 1271 | .use_fips(false)
|
1452 1272 | .use_dual_stack(true)
|
1453 1273 | .accelerate(false)
|
1454 1274 | .build()
|
1455 1275 | .expect("invalid params");
|
1456 1276 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1457 1277 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1458 1278 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.dualstack.us-east-1.amazonaws.com");
|
1459 1279 | assert_eq!(
|
1460 1280 | endpoint,
|
1461 1281 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1462 1282 | .url("https://s3.dualstack.us-east-1.amazonaws.com")
|
1463 - | .property(
|
1464 - | "authSchemes",
|
1465 - | vec![{
|
1466 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1467 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1468 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1469 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1470 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1471 - | out
|
1472 - | }
|
1473 - | .into()]
|
1283 + | .auth_scheme(
|
1284 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1285 + | .put("disableDoubleEncoding", true)
|
1286 + | .put("signingName", "s3".to_string())
|
1287 + | .put("signingRegion", "us-east-1".to_string())
|
1474 1288 | )
|
1475 1289 | .build()
|
1476 1290 | );
|
1477 1291 | }
|
1478 1292 |
|
1479 1293 | /// aws-global region with fips and dualstack uses the regional endpoint
|
1480 1294 | #[test]
|
1481 1295 | fn test_53() {
|
1482 1296 | let params = crate::config::endpoint::Params::builder()
|
1483 1297 | .region("aws-global".to_string())
|
1484 1298 | .use_fips(true)
|
1485 1299 | .use_dual_stack(true)
|
1486 1300 | .accelerate(false)
|
1487 1301 | .build()
|
1488 1302 | .expect("invalid params");
|
1489 1303 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1490 1304 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1491 1305 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3-fips.dualstack.us-east-1.amazonaws.com");
|
1492 1306 | assert_eq!(
|
1493 1307 | endpoint,
|
1494 1308 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1495 1309 | .url("https://s3-fips.dualstack.us-east-1.amazonaws.com")
|
1496 - | .property(
|
1497 - | "authSchemes",
|
1498 - | vec![{
|
1499 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1500 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1501 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1502 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1503 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1504 - | out
|
1505 - | }
|
1506 - | .into()]
|
1310 + | .auth_scheme(
|
1311 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1312 + | .put("disableDoubleEncoding", true)
|
1313 + | .put("signingName", "s3".to_string())
|
1314 + | .put("signingRegion", "us-east-1".to_string())
|
1507 1315 | )
|
1508 1316 | .build()
|
1509 1317 | );
|
1510 1318 | }
|
1511 1319 |
|
1512 1320 | /// aws-global region with accelerate on non-bucket case, uses global endpoint and ignores accelerate
|
1513 1321 | #[test]
|
1514 1322 | fn test_54() {
|
1515 1323 | let params = crate::config::endpoint::Params::builder()
|
1516 1324 | .region("aws-global".to_string())
|
1517 1325 | .use_fips(false)
|
1518 1326 | .use_dual_stack(false)
|
1519 1327 | .accelerate(true)
|
1520 1328 | .build()
|
1521 1329 | .expect("invalid params");
|
1522 1330 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1523 1331 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1524 1332 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.amazonaws.com");
|
1525 1333 | assert_eq!(
|
1526 1334 | endpoint,
|
1527 1335 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1528 1336 | .url("https://s3.amazonaws.com")
|
1529 - | .property(
|
1530 - | "authSchemes",
|
1531 - | vec![{
|
1532 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1533 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1534 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1535 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1536 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1537 - | out
|
1538 - | }
|
1539 - | .into()]
|
1337 + | .auth_scheme(
|
1338 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1339 + | .put("disableDoubleEncoding", true)
|
1340 + | .put("signingName", "s3".to_string())
|
1341 + | .put("signingRegion", "us-east-1".to_string())
|
1540 1342 | )
|
1541 1343 | .build()
|
1542 1344 | );
|
1543 1345 | }
|
1544 1346 |
|
1545 1347 | /// aws-global region with custom endpoint, uses custom
|
1546 1348 | #[test]
|
1547 1349 | fn test_55() {
|
1548 1350 | let params = crate::config::endpoint::Params::builder()
|
1549 1351 | .region("aws-global".to_string())
|
1550 1352 | .endpoint("https://example.com".to_string())
|
1551 1353 | .use_global_endpoint(false)
|
1552 1354 | .use_fips(false)
|
1553 1355 | .use_dual_stack(false)
|
1554 1356 | .accelerate(false)
|
1555 1357 | .build()
|
1556 1358 | .expect("invalid params");
|
1557 1359 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1558 1360 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1559 1361 | let endpoint = endpoint.expect("Expected valid endpoint: https://example.com");
|
1560 1362 | assert_eq!(
|
1561 1363 | endpoint,
|
1562 1364 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1563 1365 | .url("https://example.com")
|
1564 - | .property(
|
1565 - | "authSchemes",
|
1566 - | vec![{
|
1567 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1568 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1569 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1570 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1571 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1572 - | out
|
1573 - | }
|
1574 - | .into()]
|
1366 + | .auth_scheme(
|
1367 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1368 + | .put("disableDoubleEncoding", true)
|
1369 + | .put("signingName", "s3".to_string())
|
1370 + | .put("signingRegion", "us-east-1".to_string())
|
1575 1371 | )
|
1576 1372 | .build()
|
1577 1373 | );
|
1578 1374 | }
|
1579 1375 |
|
1580 1376 | /// virtual addressing, aws-global region uses the global endpoint
|
1581 1377 | #[test]
|
1582 1378 | fn test_56() {
|
1583 1379 | let params = crate::config::endpoint::Params::builder()
|
1584 1380 | .region("aws-global".to_string())
|
1585 1381 | .bucket("bucket-name".to_string())
|
1586 1382 | .use_fips(false)
|
1587 1383 | .use_dual_stack(false)
|
1588 1384 | .accelerate(false)
|
1589 1385 | .build()
|
1590 1386 | .expect("invalid params");
|
1591 1387 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1592 1388 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1593 1389 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3.amazonaws.com");
|
1594 1390 | assert_eq!(
|
1595 1391 | endpoint,
|
1596 1392 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1597 1393 | .url("https://bucket-name.s3.amazonaws.com")
|
1598 - | .property(
|
1599 - | "authSchemes",
|
1600 - | vec![{
|
1601 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1602 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1603 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1604 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1605 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1606 - | out
|
1607 - | }
|
1608 - | .into()]
|
1394 + | .auth_scheme(
|
1395 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1396 + | .put("disableDoubleEncoding", true)
|
1397 + | .put("signingName", "s3".to_string())
|
1398 + | .put("signingRegion", "us-east-1".to_string())
|
1609 1399 | )
|
1610 1400 | .build()
|
1611 1401 | );
|
1612 1402 | }
|
1613 1403 |
|
1614 1404 | /// virtual addressing, aws-global region with Prefix, and Key uses the global endpoint. Prefix and Key parameters should not be used in endpoint evaluation.
|
1615 1405 | #[test]
|
1616 1406 | fn test_57() {
|
1617 1407 | let params = crate::config::endpoint::Params::builder()
|
1618 1408 | .region("aws-global".to_string())
|
1619 1409 | .bucket("bucket-name".to_string())
|
1620 1410 | .use_fips(false)
|
1621 1411 | .use_dual_stack(false)
|
1622 1412 | .accelerate(false)
|
1623 1413 | .prefix("prefix".to_string())
|
1624 1414 | .key("key".to_string())
|
1625 1415 | .build()
|
1626 1416 | .expect("invalid params");
|
1627 1417 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1628 1418 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1629 1419 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3.amazonaws.com");
|
1630 1420 | assert_eq!(
|
1631 1421 | endpoint,
|
1632 1422 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1633 1423 | .url("https://bucket-name.s3.amazonaws.com")
|
1634 - | .property(
|
1635 - | "authSchemes",
|
1636 - | vec![{
|
1637 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1638 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1639 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1640 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1641 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1642 - | out
|
1643 - | }
|
1644 - | .into()]
|
1424 + | .auth_scheme(
|
1425 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1426 + | .put("disableDoubleEncoding", true)
|
1427 + | .put("signingName", "s3".to_string())
|
1428 + | .put("signingRegion", "us-east-1".to_string())
|
1645 1429 | )
|
1646 1430 | .build()
|
1647 1431 | );
|
1648 1432 | }
|
1649 1433 |
|
1650 1434 | /// virtual addressing, aws-global region with Copy Source, and Key uses the global endpoint. Copy Source and Key parameters should not be used in endpoint evaluation.
|
1651 1435 | #[test]
|
1652 1436 | fn test_58() {
|
1653 1437 | let params = crate::config::endpoint::Params::builder()
|
1654 1438 | .region("aws-global".to_string())
|
1655 1439 | .bucket("bucket-name".to_string())
|
1656 1440 | .use_fips(false)
|
1657 1441 | .use_dual_stack(false)
|
1658 1442 | .accelerate(false)
|
1659 1443 | .copy_source("/copy/source".to_string())
|
1660 1444 | .key("key".to_string())
|
1661 1445 | .build()
|
1662 1446 | .expect("invalid params");
|
1663 1447 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1664 1448 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1665 1449 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3.amazonaws.com");
|
1666 1450 | assert_eq!(
|
1667 1451 | endpoint,
|
1668 1452 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1669 1453 | .url("https://bucket-name.s3.amazonaws.com")
|
1670 - | .property(
|
1671 - | "authSchemes",
|
1672 - | vec![{
|
1673 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1674 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1675 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1676 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1677 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1678 - | out
|
1679 - | }
|
1680 - | .into()]
|
1454 + | .auth_scheme(
|
1455 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1456 + | .put("disableDoubleEncoding", true)
|
1457 + | .put("signingName", "s3".to_string())
|
1458 + | .put("signingRegion", "us-east-1".to_string())
|
1681 1459 | )
|
1682 1460 | .build()
|
1683 1461 | );
|
1684 1462 | }
|
1685 1463 |
|
1686 1464 | /// virtual addressing, aws-global region with fips uses the regional fips endpoint
|
1687 1465 | #[test]
|
1688 1466 | fn test_59() {
|
1689 1467 | let params = crate::config::endpoint::Params::builder()
|
1690 1468 | .region("aws-global".to_string())
|
1691 1469 | .bucket("bucket-name".to_string())
|
1692 1470 | .use_fips(true)
|
1693 1471 | .use_dual_stack(false)
|
1694 1472 | .accelerate(false)
|
1695 1473 | .build()
|
1696 1474 | .expect("invalid params");
|
1697 1475 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1698 1476 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1699 1477 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3-fips.us-east-1.amazonaws.com");
|
1700 1478 | assert_eq!(
|
1701 1479 | endpoint,
|
1702 1480 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1703 1481 | .url("https://bucket-name.s3-fips.us-east-1.amazonaws.com")
|
1704 - | .property(
|
1705 - | "authSchemes",
|
1706 - | vec![{
|
1707 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1708 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1709 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1710 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1711 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1712 - | out
|
1713 - | }
|
1714 - | .into()]
|
1482 + | .auth_scheme(
|
1483 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1484 + | .put("disableDoubleEncoding", true)
|
1485 + | .put("signingName", "s3".to_string())
|
1486 + | .put("signingRegion", "us-east-1".to_string())
|
1715 1487 | )
|
1716 1488 | .build()
|
1717 1489 | );
|
1718 1490 | }
|
1719 1491 |
|
1720 1492 | /// virtual addressing, aws-global region with dualstack uses the regional dualstack endpoint
|
1721 1493 | #[test]
|
1722 1494 | fn test_60() {
|
1723 1495 | let params = crate::config::endpoint::Params::builder()
|
1724 1496 | .region("aws-global".to_string())
|
1725 1497 | .bucket("bucket-name".to_string())
|
1726 1498 | .use_fips(false)
|
1727 1499 | .use_dual_stack(true)
|
1728 1500 | .accelerate(false)
|
1729 1501 | .build()
|
1730 1502 | .expect("invalid params");
|
1731 1503 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1732 1504 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1733 1505 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3.dualstack.us-east-1.amazonaws.com");
|
1734 1506 | assert_eq!(
|
1735 1507 | endpoint,
|
1736 1508 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1737 1509 | .url("https://bucket-name.s3.dualstack.us-east-1.amazonaws.com")
|
1738 - | .property(
|
1739 - | "authSchemes",
|
1740 - | vec![{
|
1741 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1742 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1743 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1744 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1745 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1746 - | out
|
1747 - | }
|
1748 - | .into()]
|
1510 + | .auth_scheme(
|
1511 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1512 + | .put("disableDoubleEncoding", true)
|
1513 + | .put("signingName", "s3".to_string())
|
1514 + | .put("signingRegion", "us-east-1".to_string())
|
1749 1515 | )
|
1750 1516 | .build()
|
1751 1517 | );
|
1752 1518 | }
|
1753 1519 |
|
1754 1520 | /// virtual addressing, aws-global region with fips/dualstack uses the regional fips/dualstack endpoint
|
1755 1521 | #[test]
|
1756 1522 | fn test_61() {
|
1757 1523 | let params = crate::config::endpoint::Params::builder()
|
1758 1524 | .region("aws-global".to_string())
|
1759 1525 | .bucket("bucket-name".to_string())
|
1760 1526 | .use_fips(true)
|
1761 1527 | .use_dual_stack(true)
|
1762 1528 | .accelerate(false)
|
1763 1529 | .build()
|
1764 1530 | .expect("invalid params");
|
1765 1531 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1766 1532 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1767 1533 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3-fips.dualstack.us-east-1.amazonaws.com");
|
1768 1534 | assert_eq!(
|
1769 1535 | endpoint,
|
1770 1536 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1771 1537 | .url("https://bucket-name.s3-fips.dualstack.us-east-1.amazonaws.com")
|
1772 - | .property(
|
1773 - | "authSchemes",
|
1774 - | vec![{
|
1775 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1776 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1777 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1778 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1779 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1780 - | out
|
1781 - | }
|
1782 - | .into()]
|
1538 + | .auth_scheme(
|
1539 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1540 + | .put("disableDoubleEncoding", true)
|
1541 + | .put("signingName", "s3".to_string())
|
1542 + | .put("signingRegion", "us-east-1".to_string())
|
1783 1543 | )
|
1784 1544 | .build()
|
1785 1545 | );
|
1786 1546 | }
|
1787 1547 |
|
1788 1548 | /// virtual addressing, aws-global region with accelerate uses the global accelerate endpoint
|
1789 1549 | #[test]
|
1790 1550 | fn test_62() {
|
1791 1551 | let params = crate::config::endpoint::Params::builder()
|
1792 1552 | .region("aws-global".to_string())
|
1793 1553 | .bucket("bucket-name".to_string())
|
1794 1554 | .use_fips(false)
|
1795 1555 | .use_dual_stack(false)
|
1796 1556 | .accelerate(true)
|
1797 1557 | .build()
|
1798 1558 | .expect("invalid params");
|
1799 1559 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1800 1560 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1801 1561 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3-accelerate.amazonaws.com");
|
1802 1562 | assert_eq!(
|
1803 1563 | endpoint,
|
1804 1564 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1805 1565 | .url("https://bucket-name.s3-accelerate.amazonaws.com")
|
1806 - | .property(
|
1807 - | "authSchemes",
|
1808 - | vec![{
|
1809 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1810 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1811 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1812 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1813 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1814 - | out
|
1815 - | }
|
1816 - | .into()]
|
1566 + | .auth_scheme(
|
1567 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1568 + | .put("disableDoubleEncoding", true)
|
1569 + | .put("signingName", "s3".to_string())
|
1570 + | .put("signingRegion", "us-east-1".to_string())
|
1817 1571 | )
|
1818 1572 | .build()
|
1819 1573 | );
|
1820 1574 | }
|
1821 1575 |
|
1822 1576 | /// virtual addressing, aws-global region with custom endpoint
|
1823 1577 | #[test]
|
1824 1578 | fn test_63() {
|
1825 1579 | let params = crate::config::endpoint::Params::builder()
|
1826 1580 | .region("aws-global".to_string())
|
1827 1581 | .endpoint("https://example.com".to_string())
|
1828 1582 | .bucket("bucket-name".to_string())
|
1829 1583 | .use_fips(false)
|
1830 1584 | .use_dual_stack(false)
|
1831 1585 | .accelerate(false)
|
1832 1586 | .build()
|
1833 1587 | .expect("invalid params");
|
1834 1588 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1835 1589 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1836 1590 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.example.com");
|
1837 1591 | assert_eq!(
|
1838 1592 | endpoint,
|
1839 1593 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1840 1594 | .url("https://bucket-name.example.com")
|
1841 - | .property(
|
1842 - | "authSchemes",
|
1843 - | vec![{
|
1844 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1845 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1846 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1847 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1848 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1849 - | out
|
1850 - | }
|
1851 - | .into()]
|
1595 + | .auth_scheme(
|
1596 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1597 + | .put("disableDoubleEncoding", true)
|
1598 + | .put("signingName", "s3".to_string())
|
1599 + | .put("signingRegion", "us-east-1".to_string())
|
1852 1600 | )
|
1853 1601 | .build()
|
1854 1602 | );
|
1855 1603 | }
|
1856 1604 |
|
1857 1605 | /// virtual addressing, UseGlobalEndpoint and us-east-1 region uses the global endpoint
|
1858 1606 | #[test]
|
1859 1607 | fn test_64() {
|
1860 1608 | let params = crate::config::endpoint::Params::builder()
|
1861 1609 | .region("us-east-1".to_string())
|
1862 1610 | .use_global_endpoint(true)
|
1863 1611 | .bucket("bucket-name".to_string())
|
1864 1612 | .use_fips(false)
|
1865 1613 | .use_dual_stack(false)
|
1866 1614 | .accelerate(false)
|
1867 1615 | .build()
|
1868 1616 | .expect("invalid params");
|
1869 1617 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1870 1618 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1871 1619 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3.amazonaws.com");
|
1872 1620 | assert_eq!(
|
1873 1621 | endpoint,
|
1874 1622 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1875 1623 | .url("https://bucket-name.s3.amazonaws.com")
|
1876 - | .property(
|
1877 - | "authSchemes",
|
1878 - | vec![{
|
1879 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1880 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1881 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1882 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1883 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1884 - | out
|
1885 - | }
|
1886 - | .into()]
|
1624 + | .auth_scheme(
|
1625 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1626 + | .put("disableDoubleEncoding", true)
|
1627 + | .put("signingName", "s3".to_string())
|
1628 + | .put("signingRegion", "us-east-1".to_string())
|
1887 1629 | )
|
1888 1630 | .build()
|
1889 1631 | );
|
1890 1632 | }
|
1891 1633 |
|
1892 1634 | /// virtual addressing, UseGlobalEndpoint and us-west-2 region uses the regional endpoint
|
1893 1635 | #[test]
|
1894 1636 | fn test_65() {
|
1895 1637 | let params = crate::config::endpoint::Params::builder()
|
1896 1638 | .region("us-west-2".to_string())
|
1897 1639 | .use_global_endpoint(true)
|
1898 1640 | .bucket("bucket-name".to_string())
|
1899 1641 | .use_fips(false)
|
1900 1642 | .use_dual_stack(false)
|
1901 1643 | .accelerate(false)
|
1902 1644 | .build()
|
1903 1645 | .expect("invalid params");
|
1904 1646 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1905 1647 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1906 1648 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3.us-west-2.amazonaws.com");
|
1907 1649 | assert_eq!(
|
1908 1650 | endpoint,
|
1909 1651 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1910 1652 | .url("https://bucket-name.s3.us-west-2.amazonaws.com")
|
1911 - | .property(
|
1912 - | "authSchemes",
|
1913 - | vec![{
|
1914 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1915 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1916 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1917 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
1918 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1919 - | out
|
1920 - | }
|
1921 - | .into()]
|
1653 + | .auth_scheme(
|
1654 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1655 + | .put("disableDoubleEncoding", true)
|
1656 + | .put("signingName", "s3".to_string())
|
1657 + | .put("signingRegion", "us-west-2".to_string())
|
1922 1658 | )
|
1923 1659 | .build()
|
1924 1660 | );
|
1925 1661 | }
|
1926 1662 |
|
1927 1663 | /// virtual addressing, UseGlobalEndpoint and us-east-1 region and fips uses the regional fips endpoint
|
1928 1664 | #[test]
|
1929 1665 | fn test_66() {
|
1930 1666 | let params = crate::config::endpoint::Params::builder()
|
1931 1667 | .region("us-east-1".to_string())
|
1932 1668 | .use_global_endpoint(true)
|
1933 1669 | .bucket("bucket-name".to_string())
|
1934 1670 | .use_fips(true)
|
1935 1671 | .use_dual_stack(false)
|
1936 1672 | .accelerate(false)
|
1937 1673 | .build()
|
1938 1674 | .expect("invalid params");
|
1939 1675 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1940 1676 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1941 1677 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3-fips.us-east-1.amazonaws.com");
|
1942 1678 | assert_eq!(
|
1943 1679 | endpoint,
|
1944 1680 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1945 1681 | .url("https://bucket-name.s3-fips.us-east-1.amazonaws.com")
|
1946 - | .property(
|
1947 - | "authSchemes",
|
1948 - | vec![{
|
1949 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1950 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1951 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1952 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1953 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1954 - | out
|
1955 - | }
|
1956 - | .into()]
|
1682 + | .auth_scheme(
|
1683 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1684 + | .put("disableDoubleEncoding", true)
|
1685 + | .put("signingName", "s3".to_string())
|
1686 + | .put("signingRegion", "us-east-1".to_string())
|
1957 1687 | )
|
1958 1688 | .build()
|
1959 1689 | );
|
1960 1690 | }
|
1961 1691 |
|
1962 1692 | /// virtual addressing, UseGlobalEndpoint and us-east-1 region and dualstack uses the regional dualstack endpoint
|
1963 1693 | #[test]
|
1964 1694 | fn test_67() {
|
1965 1695 | let params = crate::config::endpoint::Params::builder()
|
1966 1696 | .region("us-east-1".to_string())
|
1967 1697 | .use_global_endpoint(true)
|
1968 1698 | .bucket("bucket-name".to_string())
|
1969 1699 | .use_fips(false)
|
1970 1700 | .use_dual_stack(true)
|
1971 1701 | .accelerate(false)
|
1972 1702 | .build()
|
1973 1703 | .expect("invalid params");
|
1974 1704 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
1975 1705 | let endpoint = resolver.resolve_endpoint(¶ms);
|
1976 1706 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3.dualstack.us-east-1.amazonaws.com");
|
1977 1707 | assert_eq!(
|
1978 1708 | endpoint,
|
1979 1709 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
1980 1710 | .url("https://bucket-name.s3.dualstack.us-east-1.amazonaws.com")
|
1981 - | .property(
|
1982 - | "authSchemes",
|
1983 - | vec![{
|
1984 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
1985 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
1986 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
1987 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
1988 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
1989 - | out
|
1990 - | }
|
1991 - | .into()]
|
1711 + | .auth_scheme(
|
1712 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1713 + | .put("disableDoubleEncoding", true)
|
1714 + | .put("signingName", "s3".to_string())
|
1715 + | .put("signingRegion", "us-east-1".to_string())
|
1992 1716 | )
|
1993 1717 | .build()
|
1994 1718 | );
|
1995 1719 | }
|
1996 1720 |
|
1997 1721 | /// virtual addressing, UseGlobalEndpoint and us-east-1 region and accelerate uses the global accelerate endpoint
|
1998 1722 | #[test]
|
1999 1723 | fn test_68() {
|
2000 1724 | let params = crate::config::endpoint::Params::builder()
|
2001 1725 | .region("us-east-1".to_string())
|
2002 1726 | .use_global_endpoint(true)
|
2003 1727 | .bucket("bucket-name".to_string())
|
2004 1728 | .use_fips(false)
|
2005 1729 | .use_dual_stack(false)
|
2006 1730 | .accelerate(true)
|
2007 1731 | .build()
|
2008 1732 | .expect("invalid params");
|
2009 1733 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2010 1734 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2011 1735 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.s3-accelerate.amazonaws.com");
|
2012 1736 | assert_eq!(
|
2013 1737 | endpoint,
|
2014 1738 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2015 1739 | .url("https://bucket-name.s3-accelerate.amazonaws.com")
|
2016 - | .property(
|
2017 - | "authSchemes",
|
2018 - | vec![{
|
2019 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2020 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2021 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2022 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2023 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2024 - | out
|
2025 - | }
|
2026 - | .into()]
|
1740 + | .auth_scheme(
|
1741 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1742 + | .put("disableDoubleEncoding", true)
|
1743 + | .put("signingName", "s3".to_string())
|
1744 + | .put("signingRegion", "us-east-1".to_string())
|
2027 1745 | )
|
2028 1746 | .build()
|
2029 1747 | );
|
2030 1748 | }
|
2031 1749 |
|
2032 1750 | /// virtual addressing, UseGlobalEndpoint and us-east-1 region with custom endpoint
|
2033 1751 | #[test]
|
2034 1752 | fn test_69() {
|
2035 1753 | let params = crate::config::endpoint::Params::builder()
|
2036 1754 | .region("us-east-1".to_string())
|
2037 1755 | .endpoint("https://example.com".to_string())
|
2038 1756 | .use_global_endpoint(true)
|
2039 1757 | .bucket("bucket-name".to_string())
|
2040 1758 | .use_fips(false)
|
2041 1759 | .use_dual_stack(false)
|
2042 1760 | .accelerate(false)
|
2043 1761 | .build()
|
2044 1762 | .expect("invalid params");
|
2045 1763 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2046 1764 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2047 1765 | let endpoint = endpoint.expect("Expected valid endpoint: https://bucket-name.example.com");
|
2048 1766 | assert_eq!(
|
2049 1767 | endpoint,
|
2050 1768 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2051 1769 | .url("https://bucket-name.example.com")
|
2052 - | .property(
|
2053 - | "authSchemes",
|
2054 - | vec![{
|
2055 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2056 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2057 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2058 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2059 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2060 - | out
|
2061 - | }
|
2062 - | .into()]
|
1770 + | .auth_scheme(
|
1771 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1772 + | .put("disableDoubleEncoding", true)
|
1773 + | .put("signingName", "s3".to_string())
|
1774 + | .put("signingRegion", "us-east-1".to_string())
|
2063 1775 | )
|
2064 1776 | .build()
|
2065 1777 | );
|
2066 1778 | }
|
2067 1779 |
|
2068 1780 | /// ForcePathStyle, aws-global region uses the global endpoint
|
2069 1781 | #[test]
|
2070 1782 | fn test_70() {
|
2071 1783 | let params = crate::config::endpoint::Params::builder()
|
2072 1784 | .region("aws-global".to_string())
|
2073 1785 | .bucket("bucket-name".to_string())
|
2074 1786 | .force_path_style(true)
|
2075 1787 | .use_fips(false)
|
2076 1788 | .use_dual_stack(false)
|
2077 1789 | .accelerate(false)
|
2078 1790 | .build()
|
2079 1791 | .expect("invalid params");
|
2080 1792 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2081 1793 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2082 1794 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.amazonaws.com/bucket-name");
|
2083 1795 | assert_eq!(
|
2084 1796 | endpoint,
|
2085 1797 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2086 1798 | .url("https://s3.amazonaws.com/bucket-name")
|
2087 - | .property(
|
2088 - | "authSchemes",
|
2089 - | vec![{
|
2090 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2091 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2092 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2093 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2094 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2095 - | out
|
2096 - | }
|
2097 - | .into()]
|
1799 + | .auth_scheme(
|
1800 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1801 + | .put("disableDoubleEncoding", true)
|
1802 + | .put("signingName", "s3".to_string())
|
1803 + | .put("signingRegion", "us-east-1".to_string())
|
2098 1804 | )
|
2099 1805 | .build()
|
2100 1806 | );
|
2101 1807 | }
|
2102 1808 |
|
2103 1809 | /// ForcePathStyle, aws-global region with fips is invalid
|
2104 1810 | #[test]
|
2105 1811 | fn test_71() {
|
2106 1812 | let params = crate::config::endpoint::Params::builder()
|
2107 1813 | .region("aws-global".to_string())
|
2108 1814 | .bucket("bucket-name".to_string())
|
2109 1815 | .force_path_style(true)
|
2110 1816 | .use_fips(true)
|
2111 1817 | .use_dual_stack(false)
|
2112 1818 | .accelerate(false)
|
2113 1819 | .build()
|
2114 1820 | .expect("invalid params");
|
2115 1821 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2116 1822 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2117 1823 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3-fips.us-east-1.amazonaws.com/bucket-name");
|
2118 1824 | assert_eq!(
|
2119 1825 | endpoint,
|
2120 1826 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2121 1827 | .url("https://s3-fips.us-east-1.amazonaws.com/bucket-name")
|
2122 - | .property(
|
2123 - | "authSchemes",
|
2124 - | vec![{
|
2125 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2126 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2127 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2128 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2129 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2130 - | out
|
2131 - | }
|
2132 - | .into()]
|
1828 + | .auth_scheme(
|
1829 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1830 + | .put("disableDoubleEncoding", true)
|
1831 + | .put("signingName", "s3".to_string())
|
1832 + | .put("signingRegion", "us-east-1".to_string())
|
2133 1833 | )
|
2134 1834 | .build()
|
2135 1835 | );
|
2136 1836 | }
|
2137 1837 |
|
2138 1838 | /// ForcePathStyle, aws-global region with dualstack uses regional dualstack endpoint
|
2139 1839 | #[test]
|
2140 1840 | fn test_72() {
|
2141 1841 | let params = crate::config::endpoint::Params::builder()
|
2142 1842 | .region("aws-global".to_string())
|
2143 1843 | .bucket("bucket-name".to_string())
|
2144 1844 | .force_path_style(true)
|
2145 1845 | .use_fips(false)
|
2146 1846 | .use_dual_stack(true)
|
2147 1847 | .accelerate(false)
|
2148 1848 | .build()
|
2149 1849 | .expect("invalid params");
|
2150 1850 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2151 1851 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2152 1852 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.dualstack.us-east-1.amazonaws.com/bucket-name");
|
2153 1853 | assert_eq!(
|
2154 1854 | endpoint,
|
2155 1855 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2156 1856 | .url("https://s3.dualstack.us-east-1.amazonaws.com/bucket-name")
|
2157 - | .property(
|
2158 - | "authSchemes",
|
2159 - | vec![{
|
2160 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2161 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2162 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2163 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2164 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2165 - | out
|
2166 - | }
|
2167 - | .into()]
|
1857 + | .auth_scheme(
|
1858 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1859 + | .put("disableDoubleEncoding", true)
|
1860 + | .put("signingName", "s3".to_string())
|
1861 + | .put("signingRegion", "us-east-1".to_string())
|
2168 1862 | )
|
2169 1863 | .build()
|
2170 1864 | );
|
2171 1865 | }
|
2172 1866 |
|
2173 1867 | /// ForcePathStyle, aws-global region custom endpoint uses the custom endpoint
|
2174 1868 | #[test]
|
2175 1869 | fn test_73() {
|
2176 1870 | let params = crate::config::endpoint::Params::builder()
|
2177 1871 | .region("aws-global".to_string())
|
2178 1872 | .endpoint("https://example.com".to_string())
|
2179 1873 | .bucket("bucket-name".to_string())
|
2180 1874 | .force_path_style(true)
|
2181 1875 | .use_fips(false)
|
2182 1876 | .use_dual_stack(false)
|
2183 1877 | .accelerate(false)
|
2184 1878 | .build()
|
2185 1879 | .expect("invalid params");
|
2186 1880 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2187 1881 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2188 1882 | let endpoint = endpoint.expect("Expected valid endpoint: https://example.com/bucket-name");
|
2189 1883 | assert_eq!(
|
2190 1884 | endpoint,
|
2191 1885 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2192 1886 | .url("https://example.com/bucket-name")
|
2193 - | .property(
|
2194 - | "authSchemes",
|
2195 - | vec![{
|
2196 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2197 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2198 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2199 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2200 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2201 - | out
|
2202 - | }
|
2203 - | .into()]
|
1887 + | .auth_scheme(
|
1888 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1889 + | .put("disableDoubleEncoding", true)
|
1890 + | .put("signingName", "s3".to_string())
|
1891 + | .put("signingRegion", "us-east-1".to_string())
|
2204 1892 | )
|
2205 1893 | .build()
|
2206 1894 | );
|
2207 1895 | }
|
2208 1896 |
|
2209 1897 | /// ForcePathStyle, UseGlobalEndpoint us-east-1 region uses the global endpoint
|
2210 1898 | #[test]
|
2211 1899 | fn test_74() {
|
2212 1900 | let params = crate::config::endpoint::Params::builder()
|
2213 1901 | .region("us-east-1".to_string())
|
2214 1902 | .bucket("bucket-name".to_string())
|
2215 1903 | .use_global_endpoint(true)
|
2216 1904 | .force_path_style(true)
|
2217 1905 | .use_fips(false)
|
2218 1906 | .use_dual_stack(false)
|
2219 1907 | .accelerate(false)
|
2220 1908 | .build()
|
2221 1909 | .expect("invalid params");
|
2222 1910 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2223 1911 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2224 1912 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.amazonaws.com/bucket-name");
|
2225 1913 | assert_eq!(
|
2226 1914 | endpoint,
|
2227 1915 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2228 1916 | .url("https://s3.amazonaws.com/bucket-name")
|
2229 - | .property(
|
2230 - | "authSchemes",
|
2231 - | vec![{
|
2232 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2233 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2234 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2235 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2236 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2237 - | out
|
2238 - | }
|
2239 - | .into()]
|
1917 + | .auth_scheme(
|
1918 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1919 + | .put("disableDoubleEncoding", true)
|
1920 + | .put("signingName", "s3".to_string())
|
1921 + | .put("signingRegion", "us-east-1".to_string())
|
2240 1922 | )
|
2241 1923 | .build()
|
2242 1924 | );
|
2243 1925 | }
|
2244 1926 |
|
2245 1927 | /// ForcePathStyle, UseGlobalEndpoint us-west-2 region uses the regional endpoint
|
2246 1928 | #[test]
|
2247 1929 | fn test_75() {
|
2248 1930 | let params = crate::config::endpoint::Params::builder()
|
2249 1931 | .region("us-west-2".to_string())
|
2250 1932 | .bucket("bucket-name".to_string())
|
2251 1933 | .use_global_endpoint(true)
|
2252 1934 | .force_path_style(true)
|
2253 1935 | .use_fips(false)
|
2254 1936 | .use_dual_stack(false)
|
2255 1937 | .accelerate(false)
|
2256 1938 | .build()
|
2257 1939 | .expect("invalid params");
|
2258 1940 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2259 1941 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2260 1942 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.us-west-2.amazonaws.com/bucket-name");
|
2261 1943 | assert_eq!(
|
2262 1944 | endpoint,
|
2263 1945 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2264 1946 | .url("https://s3.us-west-2.amazonaws.com/bucket-name")
|
2265 - | .property(
|
2266 - | "authSchemes",
|
2267 - | vec![{
|
2268 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2269 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2270 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2271 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
2272 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2273 - | out
|
2274 - | }
|
2275 - | .into()]
|
1947 + | .auth_scheme(
|
1948 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1949 + | .put("disableDoubleEncoding", true)
|
1950 + | .put("signingName", "s3".to_string())
|
1951 + | .put("signingRegion", "us-west-2".to_string())
|
2276 1952 | )
|
2277 1953 | .build()
|
2278 1954 | );
|
2279 1955 | }
|
2280 1956 |
|
2281 1957 | /// ForcePathStyle, UseGlobalEndpoint us-east-1 region, dualstack uses the regional dualstack endpoint
|
2282 1958 | #[test]
|
2283 1959 | fn test_76() {
|
2284 1960 | let params = crate::config::endpoint::Params::builder()
|
2285 1961 | .region("us-east-1".to_string())
|
2286 1962 | .bucket("bucket-name".to_string())
|
2287 1963 | .use_global_endpoint(true)
|
2288 1964 | .force_path_style(true)
|
2289 1965 | .use_fips(false)
|
2290 1966 | .use_dual_stack(true)
|
2291 1967 | .accelerate(false)
|
2292 1968 | .build()
|
2293 1969 | .expect("invalid params");
|
2294 1970 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2295 1971 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2296 1972 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3.dualstack.us-east-1.amazonaws.com/bucket-name");
|
2297 1973 | assert_eq!(
|
2298 1974 | endpoint,
|
2299 1975 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2300 1976 | .url("https://s3.dualstack.us-east-1.amazonaws.com/bucket-name")
|
2301 - | .property(
|
2302 - | "authSchemes",
|
2303 - | vec![{
|
2304 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2305 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2306 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2307 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2308 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2309 - | out
|
2310 - | }
|
2311 - | .into()]
|
1977 + | .auth_scheme(
|
1978 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
1979 + | .put("disableDoubleEncoding", true)
|
1980 + | .put("signingName", "s3".to_string())
|
1981 + | .put("signingRegion", "us-east-1".to_string())
|
2312 1982 | )
|
2313 1983 | .build()
|
2314 1984 | );
|
2315 1985 | }
|
2316 1986 |
|
2317 1987 | /// ForcePathStyle, UseGlobalEndpoint us-east-1 region custom endpoint uses the custom endpoint
|
2318 1988 | #[test]
|
2319 1989 | fn test_77() {
|
2320 1990 | let params = crate::config::endpoint::Params::builder()
|
2321 1991 | .region("us-east-1".to_string())
|
2322 1992 | .bucket("bucket-name".to_string())
|
2323 1993 | .endpoint("https://example.com".to_string())
|
2324 1994 | .use_global_endpoint(true)
|
2325 1995 | .force_path_style(true)
|
2326 1996 | .use_fips(false)
|
2327 1997 | .use_dual_stack(false)
|
2328 1998 | .accelerate(false)
|
2329 1999 | .build()
|
2330 2000 | .expect("invalid params");
|
2331 2001 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2332 2002 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2333 2003 | let endpoint = endpoint.expect("Expected valid endpoint: https://example.com/bucket-name");
|
2334 2004 | assert_eq!(
|
2335 2005 | endpoint,
|
2336 2006 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2337 2007 | .url("https://example.com/bucket-name")
|
2338 - | .property(
|
2339 - | "authSchemes",
|
2340 - | vec![{
|
2341 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2342 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2343 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2344 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2345 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2346 - | out
|
2347 - | }
|
2348 - | .into()]
|
2008 + | .auth_scheme(
|
2009 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
2010 + | .put("disableDoubleEncoding", true)
|
2011 + | .put("signingName", "s3".to_string())
|
2012 + | .put("signingRegion", "us-east-1".to_string())
|
2349 2013 | )
|
2350 2014 | .build()
|
2351 2015 | );
|
2352 2016 | }
|
2353 2017 |
|
2354 2018 | /// ARN with aws-global region and UseArnRegion uses the regional endpoint
|
2355 2019 | #[test]
|
2356 2020 | fn test_78() {
|
2357 2021 | let params = crate::config::endpoint::Params::builder()
|
2358 2022 | .region("aws-global".to_string())
|
2359 2023 | .use_arn_region(true)
|
2360 2024 | .use_fips(false)
|
2361 2025 | .use_dual_stack(false)
|
2362 2026 | .accelerate(false)
|
2363 2027 | .bucket("arn:aws:s3-outposts:us-east-1:123456789012:outpost/op-01234567890123456/accesspoint/reports".to_string())
|
2364 2028 | .build()
|
2365 2029 | .expect("invalid params");
|
2366 2030 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2367 2031 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2368 2032 | let endpoint =
|
2369 2033 | endpoint.expect("Expected valid endpoint: https://reports-123456789012.op-01234567890123456.s3-outposts.us-east-1.amazonaws.com");
|
2370 2034 | assert_eq!(
|
2371 2035 | endpoint,
|
2372 2036 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2373 2037 | .url("https://reports-123456789012.op-01234567890123456.s3-outposts.us-east-1.amazonaws.com")
|
2374 - | .property(
|
2375 - | "authSchemes",
|
2376 - | vec![
|
2377 - | {
|
2378 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2379 - | out.insert("name".to_string(), "sigv4a".to_string().into());
|
2380 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
2381 - | out.insert("signingRegionSet".to_string(), vec!["*".to_string().into()].into());
|
2382 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2383 - | out
|
2384 - | }
|
2385 - | .into(),
|
2386 - | {
|
2387 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2388 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2389 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
2390 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
2391 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2392 - | out
|
2393 - | }
|
2394 - | .into()
|
2395 - | ]
|
2038 + | .auth_scheme(
|
2039 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4a", 3)
|
2040 + | .put("disableDoubleEncoding", true)
|
2041 + | .put("signingName", "s3-outposts".to_string())
|
2042 + | .put("signingRegionSet", vec!["*".to_string().into()])
|
2043 + | )
|
2044 + | .auth_scheme(
|
2045 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
2046 + | .put("disableDoubleEncoding", true)
|
2047 + | .put("signingName", "s3-outposts".to_string())
|
2048 + | .put("signingRegion", "us-east-1".to_string())
|
2396 2049 | )
|
2397 2050 | .build()
|
2398 2051 | );
|
2399 2052 | }
|
2400 2053 |
|
2401 2054 | /// cross partition MRAP ARN is an error
|
2402 2055 | #[test]
|
2403 2056 | fn test_79() {
|
2404 2057 | let params = crate::config::endpoint::Params::builder()
|
2405 2058 | .bucket("arn:aws-cn:s3::123456789012:accesspoint:mfzwi23gnjvgw.mrap".to_string())
|
2406 2059 | .region("us-west-1".to_string())
|
2407 2060 | .build()
|
2408 2061 | .expect("invalid params");
|
2409 2062 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2410 2063 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2411 2064 | let error = endpoint.expect_err("expected error: Client was configured for partition `aws` but bucket referred to partition `aws-cn` [cross partition MRAP ARN is an error]");
|
2412 2065 | assert_eq!(
|
2413 2066 | format!("{}", error),
|
2414 2067 | "Client was configured for partition `aws` but bucket referred to partition `aws-cn`"
|
2415 2068 | )
|
2416 2069 | }
|
2417 2070 |
|
2418 2071 | /// Endpoint override, accesspoint with HTTP, port
|
2419 2072 | #[test]
|
2420 2073 | fn test_80() {
|
2421 2074 | let params = crate::config::endpoint::Params::builder()
|
2422 2075 | .endpoint("http://beta.example.com:1234".to_string())
|
2423 2076 | .region("us-west-2".to_string())
|
2424 2077 | .bucket("arn:aws:s3:us-west-2:123456789012:accesspoint:myendpoint".to_string())
|
2425 2078 | .build()
|
2426 2079 | .expect("invalid params");
|
2427 2080 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2428 2081 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2429 2082 | let endpoint = endpoint.expect("Expected valid endpoint: http://myendpoint-123456789012.beta.example.com:1234");
|
2430 2083 | assert_eq!(
|
2431 2084 | endpoint,
|
2432 2085 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2433 2086 | .url("http://myendpoint-123456789012.beta.example.com:1234")
|
2434 - | .property(
|
2435 - | "authSchemes",
|
2436 - | vec![{
|
2437 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2438 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2439 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2440 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
2441 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2442 - | out
|
2443 - | }
|
2444 - | .into()]
|
2087 + | .auth_scheme(
|
2088 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
2089 + | .put("disableDoubleEncoding", true)
|
2090 + | .put("signingName", "s3".to_string())
|
2091 + | .put("signingRegion", "us-west-2".to_string())
|
2445 2092 | )
|
2446 2093 | .build()
|
2447 2094 | );
|
2448 2095 | }
|
2449 2096 |
|
2450 2097 | /// Endpoint override, accesspoint with http, path, query, and port
|
2451 2098 | #[test]
|
2452 2099 | fn test_81() {
|
2453 2100 | let params = crate::config::endpoint::Params::builder()
|
2454 2101 | .region("us-west-2".to_string())
|
2455 2102 | .bucket("arn:aws:s3:us-west-2:123456789012:accesspoint:myendpoint".to_string())
|
2456 2103 | .endpoint("http://beta.example.com:1234/path".to_string())
|
2457 2104 | .use_fips(false)
|
2458 2105 | .use_dual_stack(false)
|
2459 2106 | .accelerate(false)
|
2460 2107 | .build()
|
2461 2108 | .expect("invalid params");
|
2462 2109 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
2463 2110 | let endpoint = resolver.resolve_endpoint(¶ms);
|
2464 2111 | let endpoint = endpoint.expect("Expected valid endpoint: http://myendpoint-123456789012.beta.example.com:1234/path");
|
2465 2112 | assert_eq!(
|
2466 2113 | endpoint,
|
2467 2114 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
2468 2115 | .url("http://myendpoint-123456789012.beta.example.com:1234/path")
|
2469 - | .property(
|
2470 - | "authSchemes",
|
2471 - | vec![{
|
2472 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
2473 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
2474 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
2475 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
2476 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
2477 - | out
|
2478 - | }
|
2479 - | .into()]
|
2116 + | .auth_scheme(
|
2117 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
2118 + | .put("disableDoubleEncoding", true)
|
2119 + | .put("signingName", "s3".to_string())
|
2120 + | .put("signingRegion", "us-west-2".to_string())
|
2480 2121 | )
|
2481 2122 | .build()
|
2482 2123 | );
|
2483 2124 | }
|
2484 2125 |
|
2485 2126 | /// non-bucket endpoint override with FIPS = error
|
2486 2127 | #[test]
|
2487 2128 | fn test_82() {
|
2488 2129 | let params = crate::config::endpoint::Params::builder()
|
2489 2130 | .region("us-west-2".to_string())
|
7713 6697 | .accelerate(false)
|
7714 6698 | .build()
|
7715 6699 | .expect("invalid params");
|
7716 6700 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
7717 6701 | let endpoint = resolver.resolve_endpoint(¶ms);
|
7718 6702 | let endpoint = endpoint.expect("Expected valid endpoint: http://10.0.1.12:433/bucketName");
|
7719 6703 | assert_eq!(
|
7720 6704 | endpoint,
|
7721 6705 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
7722 6706 | .url("http://10.0.1.12:433/bucketName")
|
7723 - | .property(
|
7724 - | "authSchemes",
|
7725 - | vec![{
|
7726 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
7727 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
7728 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
7729 - | out.insert("signingRegion".to_string(), "snow".to_string().into());
|
7730 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
7731 - | out
|
7732 - | }
|
7733 - | .into()]
|
6707 + | .auth_scheme(
|
6708 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
6709 + | .put("disableDoubleEncoding", true)
|
6710 + | .put("signingName", "s3".to_string())
|
6711 + | .put("signingRegion", "snow".to_string())
|
7734 6712 | )
|
7735 6713 | .build()
|
7736 6714 | );
|
7737 6715 | }
|
7738 6716 |
|
7739 6717 | /// S3 Snow without bucket
|
7740 6718 | #[test]
|
7741 6719 | fn test_272() {
|
7742 6720 | let params = crate::config::endpoint::Params::builder()
|
7743 6721 | .region("snow".to_string())
|
7744 6722 | .endpoint("https://10.0.1.12:433".to_string())
|
7745 6723 | .use_fips(false)
|
7746 6724 | .use_dual_stack(false)
|
7747 6725 | .accelerate(false)
|
7748 6726 | .build()
|
7749 6727 | .expect("invalid params");
|
7750 6728 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
7751 6729 | let endpoint = resolver.resolve_endpoint(¶ms);
|
7752 6730 | let endpoint = endpoint.expect("Expected valid endpoint: https://10.0.1.12:433");
|
7753 6731 | assert_eq!(
|
7754 6732 | endpoint,
|
7755 6733 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
7756 6734 | .url("https://10.0.1.12:433")
|
7757 - | .property(
|
7758 - | "authSchemes",
|
7759 - | vec![{
|
7760 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
7761 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
7762 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
7763 - | out.insert("signingRegion".to_string(), "snow".to_string().into());
|
7764 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
7765 - | out
|
7766 - | }
|
7767 - | .into()]
|
6735 + | .auth_scheme(
|
6736 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
6737 + | .put("disableDoubleEncoding", true)
|
6738 + | .put("signingName", "s3".to_string())
|
6739 + | .put("signingRegion", "snow".to_string())
|
7768 6740 | )
|
7769 6741 | .build()
|
7770 6742 | );
|
7771 6743 | }
|
7772 6744 |
|
7773 6745 | /// S3 Snow no port
|
7774 6746 | #[test]
|
7775 6747 | fn test_273() {
|
7776 6748 | let params = crate::config::endpoint::Params::builder()
|
7777 6749 | .region("snow".to_string())
|
7778 6750 | .bucket("bucketName".to_string())
|
7779 6751 | .endpoint("http://10.0.1.12".to_string())
|
7780 6752 | .use_fips(false)
|
7781 6753 | .use_dual_stack(false)
|
7782 6754 | .accelerate(false)
|
7783 6755 | .build()
|
7784 6756 | .expect("invalid params");
|
7785 6757 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
7786 6758 | let endpoint = resolver.resolve_endpoint(¶ms);
|
7787 6759 | let endpoint = endpoint.expect("Expected valid endpoint: http://10.0.1.12/bucketName");
|
7788 6760 | assert_eq!(
|
7789 6761 | endpoint,
|
7790 6762 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
7791 6763 | .url("http://10.0.1.12/bucketName")
|
7792 - | .property(
|
7793 - | "authSchemes",
|
7794 - | vec![{
|
7795 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
7796 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
7797 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
7798 - | out.insert("signingRegion".to_string(), "snow".to_string().into());
|
7799 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
7800 - | out
|
7801 - | }
|
7802 - | .into()]
|
6764 + | .auth_scheme(
|
6765 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
6766 + | .put("disableDoubleEncoding", true)
|
6767 + | .put("signingName", "s3".to_string())
|
6768 + | .put("signingRegion", "snow".to_string())
|
7803 6769 | )
|
7804 6770 | .build()
|
7805 6771 | );
|
7806 6772 | }
|
7807 6773 |
|
7808 6774 | /// S3 Snow dns endpoint
|
7809 6775 | #[test]
|
7810 6776 | fn test_274() {
|
7811 6777 | let params = crate::config::endpoint::Params::builder()
|
7812 6778 | .region("snow".to_string())
|
7813 6779 | .bucket("bucketName".to_string())
|
7814 6780 | .endpoint("https://amazonaws.com".to_string())
|
7815 6781 | .use_fips(false)
|
7816 6782 | .use_dual_stack(false)
|
7817 6783 | .accelerate(false)
|
7818 6784 | .build()
|
7819 6785 | .expect("invalid params");
|
7820 6786 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
7821 6787 | let endpoint = resolver.resolve_endpoint(¶ms);
|
7822 6788 | let endpoint = endpoint.expect("Expected valid endpoint: https://amazonaws.com/bucketName");
|
7823 6789 | assert_eq!(
|
7824 6790 | endpoint,
|
7825 6791 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
7826 6792 | .url("https://amazonaws.com/bucketName")
|
7827 - | .property(
|
7828 - | "authSchemes",
|
7829 - | vec![{
|
7830 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
7831 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
7832 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
7833 - | out.insert("signingRegion".to_string(), "snow".to_string().into());
|
7834 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
7835 - | out
|
7836 - | }
|
7837 - | .into()]
|
6793 + | .auth_scheme(
|
6794 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
6795 + | .put("disableDoubleEncoding", true)
|
6796 + | .put("signingName", "s3".to_string())
|
6797 + | .put("signingRegion", "snow".to_string())
|
7838 6798 | )
|
7839 6799 | .build()
|
7840 6800 | );
|
7841 6801 | }
|
7842 6802 |
|
7843 6803 | /// Data Plane with short zone name
|
7844 6804 | #[test]
|
7845 6805 | fn test_275() {
|
7846 6806 | let params = crate::config::endpoint::Params::builder()
|
7847 6807 | .region("us-east-1".to_string())
|
7848 6808 | .bucket("mybucket--abcd-ab1--x-s3".to_string())
|
7849 6809 | .use_fips(false)
|
7850 6810 | .use_dual_stack(false)
|
7851 6811 | .accelerate(false)
|
7852 6812 | .use_s3_express_control_endpoint(false)
|
7853 6813 | .build()
|
7854 6814 | .expect("invalid params");
|
7855 6815 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
7856 6816 | let endpoint = resolver.resolve_endpoint(¶ms);
|
7857 6817 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--abcd-ab1--x-s3.s3express-abcd-ab1.us-east-1.amazonaws.com");
|
7858 6818 | assert_eq!(
|
7859 6819 | endpoint,
|
7860 6820 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
7861 6821 | .url("https://mybucket--abcd-ab1--x-s3.s3express-abcd-ab1.us-east-1.amazonaws.com")
|
7862 - | .property(
|
7863 - | "authSchemes",
|
7864 - | vec![{
|
7865 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
7866 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
7867 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
7868 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
7869 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
7870 - | out
|
7871 - | }
|
7872 - | .into()]
|
6822 + | .auth_scheme(
|
6823 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
6824 + | .put("disableDoubleEncoding", true)
|
6825 + | .put("signingName", "s3express".to_string())
|
6826 + | .put("signingRegion", "us-east-1".to_string())
|
7873 6827 | )
|
7874 6828 | .property("backend", "S3Express".to_string())
|
7875 6829 | .build()
|
7876 6830 | );
|
7877 6831 | }
|
7878 6832 |
|
7879 6833 | /// Data Plane with short zone name china region
|
7880 6834 | #[test]
|
7881 6835 | fn test_276() {
|
7882 6836 | let params = crate::config::endpoint::Params::builder()
|
7883 6837 | .region("cn-north-1".to_string())
|
7884 6838 | .bucket("mybucket--abcd-ab1--x-s3".to_string())
|
7885 6839 | .use_fips(false)
|
7886 6840 | .use_dual_stack(false)
|
7887 6841 | .accelerate(false)
|
7888 6842 | .use_s3_express_control_endpoint(false)
|
7889 6843 | .build()
|
7890 6844 | .expect("invalid params");
|
7891 6845 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
7892 6846 | let endpoint = resolver.resolve_endpoint(¶ms);
|
7893 6847 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--abcd-ab1--x-s3.s3express-abcd-ab1.cn-north-1.amazonaws.com.cn");
|
7894 6848 | assert_eq!(
|
7895 6849 | endpoint,
|
7896 6850 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
7897 6851 | .url("https://mybucket--abcd-ab1--x-s3.s3express-abcd-ab1.cn-north-1.amazonaws.com.cn")
|
7898 - | .property(
|
7899 - | "authSchemes",
|
7900 - | vec![{
|
7901 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
7902 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
7903 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
7904 - | out.insert("signingRegion".to_string(), "cn-north-1".to_string().into());
|
7905 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
7906 - | out
|
7907 - | }
|
7908 - | .into()]
|
6852 + | .auth_scheme(
|
6853 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
6854 + | .put("disableDoubleEncoding", true)
|
6855 + | .put("signingName", "s3express".to_string())
|
6856 + | .put("signingRegion", "cn-north-1".to_string())
|
7909 6857 | )
|
7910 6858 | .property("backend", "S3Express".to_string())
|
7911 6859 | .build()
|
7912 6860 | );
|
7913 6861 | }
|
7914 6862 |
|
7915 6863 | /// Data Plane with short zone name with AP
|
7916 6864 | #[test]
|
7917 6865 | fn test_277() {
|
7918 6866 | let params = crate::config::endpoint::Params::builder()
|
7919 6867 | .region("us-east-1".to_string())
|
7920 6868 | .bucket("myaccesspoint--abcd-ab1--xa-s3".to_string())
|
7921 6869 | .use_fips(false)
|
7922 6870 | .use_dual_stack(false)
|
7923 6871 | .accelerate(false)
|
7924 6872 | .use_s3_express_control_endpoint(false)
|
7925 6873 | .build()
|
7926 6874 | .expect("invalid params");
|
7927 6875 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
7928 6876 | let endpoint = resolver.resolve_endpoint(¶ms);
|
7929 6877 | let endpoint = endpoint.expect("Expected valid endpoint: https://myaccesspoint--abcd-ab1--xa-s3.s3express-abcd-ab1.us-east-1.amazonaws.com");
|
7930 6878 | assert_eq!(
|
7931 6879 | endpoint,
|
7932 6880 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
7933 6881 | .url("https://myaccesspoint--abcd-ab1--xa-s3.s3express-abcd-ab1.us-east-1.amazonaws.com")
|
7934 - | .property(
|
7935 - | "authSchemes",
|
7936 - | vec![{
|
7937 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
7938 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
7939 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
7940 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
7941 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
7942 - | out
|
7943 - | }
|
7944 - | .into()]
|
6882 + | .auth_scheme(
|
6883 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
6884 + | .put("disableDoubleEncoding", true)
|
6885 + | .put("signingName", "s3express".to_string())
|
6886 + | .put("signingRegion", "us-east-1".to_string())
|
7945 6887 | )
|
7946 6888 | .property("backend", "S3Express".to_string())
|
7947 6889 | .build()
|
7948 6890 | );
|
7949 6891 | }
|
7950 6892 |
|
7951 6893 | /// Data Plane with short zone name with AP china region
|
7952 6894 | #[test]
|
7953 6895 | fn test_278() {
|
7954 6896 | let params = crate::config::endpoint::Params::builder()
|
7955 6897 | .region("cn-north-1".to_string())
|
7956 6898 | .bucket("myaccesspoint--abcd-ab1--xa-s3".to_string())
|
7957 6899 | .use_fips(false)
|
7958 6900 | .use_dual_stack(false)
|
7959 6901 | .accelerate(false)
|
7960 6902 | .use_s3_express_control_endpoint(false)
|
7961 6903 | .build()
|
7962 6904 | .expect("invalid params");
|
7963 6905 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
7964 6906 | let endpoint = resolver.resolve_endpoint(¶ms);
|
7965 6907 | let endpoint =
|
7966 6908 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--abcd-ab1--xa-s3.s3express-abcd-ab1.cn-north-1.amazonaws.com.cn");
|
7967 6909 | assert_eq!(
|
7968 6910 | endpoint,
|
7969 6911 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
7970 6912 | .url("https://myaccesspoint--abcd-ab1--xa-s3.s3express-abcd-ab1.cn-north-1.amazonaws.com.cn")
|
7971 - | .property(
|
7972 - | "authSchemes",
|
7973 - | vec![{
|
7974 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
7975 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
7976 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
7977 - | out.insert("signingRegion".to_string(), "cn-north-1".to_string().into());
|
7978 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
7979 - | out
|
7980 - | }
|
7981 - | .into()]
|
6913 + | .auth_scheme(
|
6914 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
6915 + | .put("disableDoubleEncoding", true)
|
6916 + | .put("signingName", "s3express".to_string())
|
6917 + | .put("signingRegion", "cn-north-1".to_string())
|
7982 6918 | )
|
7983 6919 | .property("backend", "S3Express".to_string())
|
7984 6920 | .build()
|
7985 6921 | );
|
7986 6922 | }
|
7987 6923 |
|
7988 6924 | /// Data Plane with short zone names (13 chars)
|
7989 6925 | #[test]
|
7990 6926 | fn test_279() {
|
7991 6927 | let params = crate::config::endpoint::Params::builder()
|
7992 6928 | .region("us-west-2".to_string())
|
7993 6929 | .bucket("mybucket--test-zone-ab1--x-s3".to_string())
|
7994 6930 | .use_fips(false)
|
7995 6931 | .use_dual_stack(false)
|
7996 6932 | .accelerate(false)
|
7997 6933 | .use_s3_express_control_endpoint(false)
|
7998 6934 | .build()
|
7999 6935 | .expect("invalid params");
|
8000 6936 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8001 6937 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8002 6938 | let endpoint =
|
8003 6939 | endpoint.expect("Expected valid endpoint: https://mybucket--test-zone-ab1--x-s3.s3express-test-zone-ab1.us-west-2.amazonaws.com");
|
8004 6940 | assert_eq!(
|
8005 6941 | endpoint,
|
8006 6942 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8007 6943 | .url("https://mybucket--test-zone-ab1--x-s3.s3express-test-zone-ab1.us-west-2.amazonaws.com")
|
8008 - | .property(
|
8009 - | "authSchemes",
|
8010 - | vec![{
|
8011 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8012 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8013 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8014 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8015 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8016 - | out
|
8017 - | }
|
8018 - | .into()]
|
6944 + | .auth_scheme(
|
6945 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
6946 + | .put("disableDoubleEncoding", true)
|
6947 + | .put("signingName", "s3express".to_string())
|
6948 + | .put("signingRegion", "us-west-2".to_string())
|
8019 6949 | )
|
8020 6950 | .property("backend", "S3Express".to_string())
|
8021 6951 | .build()
|
8022 6952 | );
|
8023 6953 | }
|
8024 6954 |
|
8025 6955 | /// Data Plane with short zone names (13 chars) with AP
|
8026 6956 | #[test]
|
8027 6957 | fn test_280() {
|
8028 6958 | let params = crate::config::endpoint::Params::builder()
|
8029 6959 | .region("us-west-2".to_string())
|
8030 6960 | .bucket("myaccesspoint--test-zone-ab1--xa-s3".to_string())
|
8031 6961 | .use_fips(false)
|
8032 6962 | .use_dual_stack(false)
|
8033 6963 | .accelerate(false)
|
8034 6964 | .use_s3_express_control_endpoint(false)
|
8035 6965 | .build()
|
8036 6966 | .expect("invalid params");
|
8037 6967 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8038 6968 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8039 6969 | let endpoint =
|
8040 6970 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test-zone-ab1--xa-s3.s3express-test-zone-ab1.us-west-2.amazonaws.com");
|
8041 6971 | assert_eq!(
|
8042 6972 | endpoint,
|
8043 6973 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8044 6974 | .url("https://myaccesspoint--test-zone-ab1--xa-s3.s3express-test-zone-ab1.us-west-2.amazonaws.com")
|
8045 - | .property(
|
8046 - | "authSchemes",
|
8047 - | vec![{
|
8048 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8049 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8050 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8051 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8052 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8053 - | out
|
8054 - | }
|
8055 - | .into()]
|
6975 + | .auth_scheme(
|
6976 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
6977 + | .put("disableDoubleEncoding", true)
|
6978 + | .put("signingName", "s3express".to_string())
|
6979 + | .put("signingRegion", "us-west-2".to_string())
|
8056 6980 | )
|
8057 6981 | .property("backend", "S3Express".to_string())
|
8058 6982 | .build()
|
8059 6983 | );
|
8060 6984 | }
|
8061 6985 |
|
8062 6986 | /// Data Plane with medium zone names (14 chars)
|
8063 6987 | #[test]
|
8064 6988 | fn test_281() {
|
8065 6989 | let params = crate::config::endpoint::Params::builder()
|
8066 6990 | .region("us-west-2".to_string())
|
8067 6991 | .bucket("mybucket--test1-zone-ab1--x-s3".to_string())
|
8068 6992 | .use_fips(false)
|
8069 6993 | .use_dual_stack(false)
|
8070 6994 | .accelerate(false)
|
8071 6995 | .use_s3_express_control_endpoint(false)
|
8072 6996 | .build()
|
8073 6997 | .expect("invalid params");
|
8074 6998 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8075 6999 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8076 7000 | let endpoint =
|
8077 7001 | endpoint.expect("Expected valid endpoint: https://mybucket--test1-zone-ab1--x-s3.s3express-test1-zone-ab1.us-west-2.amazonaws.com");
|
8078 7002 | assert_eq!(
|
8079 7003 | endpoint,
|
8080 7004 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8081 7005 | .url("https://mybucket--test1-zone-ab1--x-s3.s3express-test1-zone-ab1.us-west-2.amazonaws.com")
|
8082 - | .property(
|
8083 - | "authSchemes",
|
8084 - | vec![{
|
8085 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8086 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8087 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8088 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8089 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8090 - | out
|
8091 - | }
|
8092 - | .into()]
|
7006 + | .auth_scheme(
|
7007 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7008 + | .put("disableDoubleEncoding", true)
|
7009 + | .put("signingName", "s3express".to_string())
|
7010 + | .put("signingRegion", "us-west-2".to_string())
|
8093 7011 | )
|
8094 7012 | .property("backend", "S3Express".to_string())
|
8095 7013 | .build()
|
8096 7014 | );
|
8097 7015 | }
|
8098 7016 |
|
8099 7017 | /// Data Plane with medium zone names (14 chars) with AP
|
8100 7018 | #[test]
|
8101 7019 | fn test_282() {
|
8102 7020 | let params = crate::config::endpoint::Params::builder()
|
8103 7021 | .region("us-west-2".to_string())
|
8104 7022 | .bucket("myaccesspoint--test1-zone-ab1--xa-s3".to_string())
|
8105 7023 | .use_fips(false)
|
8106 7024 | .use_dual_stack(false)
|
8107 7025 | .accelerate(false)
|
8108 7026 | .use_s3_express_control_endpoint(false)
|
8109 7027 | .build()
|
8110 7028 | .expect("invalid params");
|
8111 7029 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8112 7030 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8113 7031 | let endpoint =
|
8114 7032 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-test1-zone-ab1.us-west-2.amazonaws.com");
|
8115 7033 | assert_eq!(
|
8116 7034 | endpoint,
|
8117 7035 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8118 7036 | .url("https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-test1-zone-ab1.us-west-2.amazonaws.com")
|
8119 - | .property(
|
8120 - | "authSchemes",
|
8121 - | vec![{
|
8122 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8123 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8124 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8125 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8126 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8127 - | out
|
8128 - | }
|
8129 - | .into()]
|
7037 + | .auth_scheme(
|
7038 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7039 + | .put("disableDoubleEncoding", true)
|
7040 + | .put("signingName", "s3express".to_string())
|
7041 + | .put("signingRegion", "us-west-2".to_string())
|
8130 7042 | )
|
8131 7043 | .property("backend", "S3Express".to_string())
|
8132 7044 | .build()
|
8133 7045 | );
|
8134 7046 | }
|
8135 7047 |
|
8136 7048 | /// Data Plane with long zone names (20 chars)
|
8137 7049 | #[test]
|
8138 7050 | fn test_283() {
|
8139 7051 | let params = crate::config::endpoint::Params::builder()
|
8140 7052 | .region("us-west-2".to_string())
|
8141 7053 | .bucket("mybucket--test1-long1-zone-ab1--x-s3".to_string())
|
8142 7054 | .use_fips(false)
|
8143 7055 | .use_dual_stack(false)
|
8144 7056 | .accelerate(false)
|
8145 7057 | .use_s3_express_control_endpoint(false)
|
8146 7058 | .build()
|
8147 7059 | .expect("invalid params");
|
8148 7060 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8149 7061 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8150 7062 | let endpoint = endpoint
|
8151 7063 | .expect("Expected valid endpoint: https://mybucket--test1-long1-zone-ab1--x-s3.s3express-test1-long1-zone-ab1.us-west-2.amazonaws.com");
|
8152 7064 | assert_eq!(
|
8153 7065 | endpoint,
|
8154 7066 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8155 7067 | .url("https://mybucket--test1-long1-zone-ab1--x-s3.s3express-test1-long1-zone-ab1.us-west-2.amazonaws.com")
|
8156 - | .property(
|
8157 - | "authSchemes",
|
8158 - | vec![{
|
8159 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8160 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8161 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8162 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8163 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8164 - | out
|
8165 - | }
|
8166 - | .into()]
|
7068 + | .auth_scheme(
|
7069 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7070 + | .put("disableDoubleEncoding", true)
|
7071 + | .put("signingName", "s3express".to_string())
|
7072 + | .put("signingRegion", "us-west-2".to_string())
|
8167 7073 | )
|
8168 7074 | .property("backend", "S3Express".to_string())
|
8169 7075 | .build()
|
8170 7076 | );
|
8171 7077 | }
|
8172 7078 |
|
8173 7079 | /// Data Plane with long zone names (20 chars)
|
8174 7080 | #[test]
|
8175 7081 | fn test_284() {
|
8176 7082 | let params = crate::config::endpoint::Params::builder()
|
8177 7083 | .region("us-west-2".to_string())
|
8178 7084 | .bucket("myaccesspoint--test1-long1-zone-ab1--xa-s3".to_string())
|
8179 7085 | .use_fips(false)
|
8180 7086 | .use_dual_stack(false)
|
8181 7087 | .accelerate(false)
|
8182 7088 | .use_s3_express_control_endpoint(false)
|
8183 7089 | .build()
|
8184 7090 | .expect("invalid params");
|
8185 7091 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8186 7092 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8187 7093 | let endpoint = endpoint.expect(
|
8188 7094 | "Expected valid endpoint: https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-test1-long1-zone-ab1.us-west-2.amazonaws.com",
|
8189 7095 | );
|
8190 7096 | assert_eq!(
|
8191 7097 | endpoint,
|
8192 7098 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8193 7099 | .url("https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-test1-long1-zone-ab1.us-west-2.amazonaws.com")
|
8194 - | .property(
|
8195 - | "authSchemes",
|
8196 - | vec![{
|
8197 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8198 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8199 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8200 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8201 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8202 - | out
|
8203 - | }
|
8204 - | .into()]
|
7100 + | .auth_scheme(
|
7101 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7102 + | .put("disableDoubleEncoding", true)
|
7103 + | .put("signingName", "s3express".to_string())
|
7104 + | .put("signingRegion", "us-west-2".to_string())
|
8205 7105 | )
|
8206 7106 | .property("backend", "S3Express".to_string())
|
8207 7107 | .build()
|
8208 7108 | );
|
8209 7109 | }
|
8210 7110 |
|
8211 7111 | /// Data Plane with short zone fips
|
8212 7112 | #[test]
|
8213 7113 | fn test_285() {
|
8214 7114 | let params = crate::config::endpoint::Params::builder()
|
8215 7115 | .region("us-east-1".to_string())
|
8216 7116 | .bucket("mybucket--test-ab1--x-s3".to_string())
|
8217 7117 | .use_fips(true)
|
8218 7118 | .use_dual_stack(false)
|
8219 7119 | .accelerate(false)
|
8220 7120 | .use_s3_express_control_endpoint(false)
|
8221 7121 | .build()
|
8222 7122 | .expect("invalid params");
|
8223 7123 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8224 7124 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8225 7125 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--test-ab1--x-s3.s3express-fips-test-ab1.us-east-1.amazonaws.com");
|
8226 7126 | assert_eq!(
|
8227 7127 | endpoint,
|
8228 7128 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8229 7129 | .url("https://mybucket--test-ab1--x-s3.s3express-fips-test-ab1.us-east-1.amazonaws.com")
|
8230 - | .property(
|
8231 - | "authSchemes",
|
8232 - | vec![{
|
8233 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8234 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8235 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8236 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
8237 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8238 - | out
|
8239 - | }
|
8240 - | .into()]
|
7130 + | .auth_scheme(
|
7131 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7132 + | .put("disableDoubleEncoding", true)
|
7133 + | .put("signingName", "s3express".to_string())
|
7134 + | .put("signingRegion", "us-east-1".to_string())
|
8241 7135 | )
|
8242 7136 | .property("backend", "S3Express".to_string())
|
8243 7137 | .build()
|
8244 7138 | );
|
8245 7139 | }
|
8246 7140 |
|
8247 7141 | /// Data Plane with short zone fips china region
|
8248 7142 | #[test]
|
8249 7143 | fn test_286() {
|
8250 7144 | let params = crate::config::endpoint::Params::builder()
|
8251 7145 | .region("cn-north-1".to_string())
|
8252 7146 | .bucket("mybucket--test-ab1--x-s3".to_string())
|
8253 7147 | .use_fips(true)
|
8254 7148 | .use_dual_stack(false)
|
8255 7149 | .accelerate(false)
|
8256 7150 | .use_s3_express_control_endpoint(false)
|
8257 7151 | .build()
|
8258 7152 | .expect("invalid params");
|
8259 7153 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8260 7154 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8261 7155 | let error = endpoint.expect_err("expected error: Partition does not support FIPS [Data Plane with short zone fips china region]");
|
8262 7156 | assert_eq!(format!("{}", error), "Partition does not support FIPS")
|
8263 7157 | }
|
8264 7158 |
|
8265 7159 | /// Data Plane with short zone fips with AP
|
8266 7160 | #[test]
|
8267 7161 | fn test_287() {
|
8268 7162 | let params = crate::config::endpoint::Params::builder()
|
8269 7163 | .region("us-east-1".to_string())
|
8270 7164 | .bucket("myaccesspoint--test-ab1--xa-s3".to_string())
|
8271 7165 | .use_fips(true)
|
8272 7166 | .use_dual_stack(false)
|
8273 7167 | .accelerate(false)
|
8274 7168 | .use_s3_express_control_endpoint(false)
|
8275 7169 | .build()
|
8276 7170 | .expect("invalid params");
|
8277 7171 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8278 7172 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8279 7173 | let endpoint =
|
8280 7174 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test-ab1--xa-s3.s3express-fips-test-ab1.us-east-1.amazonaws.com");
|
8281 7175 | assert_eq!(
|
8282 7176 | endpoint,
|
8283 7177 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8284 7178 | .url("https://myaccesspoint--test-ab1--xa-s3.s3express-fips-test-ab1.us-east-1.amazonaws.com")
|
8285 - | .property(
|
8286 - | "authSchemes",
|
8287 - | vec![{
|
8288 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8289 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8290 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8291 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
8292 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8293 - | out
|
8294 - | }
|
8295 - | .into()]
|
7179 + | .auth_scheme(
|
7180 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7181 + | .put("disableDoubleEncoding", true)
|
7182 + | .put("signingName", "s3express".to_string())
|
7183 + | .put("signingRegion", "us-east-1".to_string())
|
8296 7184 | )
|
8297 7185 | .property("backend", "S3Express".to_string())
|
8298 7186 | .build()
|
8299 7187 | );
|
8300 7188 | }
|
8301 7189 |
|
8302 7190 | /// Data Plane with short zone fips with AP china region
|
8303 7191 | #[test]
|
8304 7192 | fn test_288() {
|
8305 7193 | let params = crate::config::endpoint::Params::builder()
|
8306 7194 | .region("cn-north-1".to_string())
|
8307 7195 | .bucket("myaccesspoint--test-ab1--xa-s3".to_string())
|
8308 7196 | .use_fips(true)
|
8309 7197 | .use_dual_stack(false)
|
8310 7198 | .accelerate(false)
|
8311 7199 | .use_s3_express_control_endpoint(false)
|
8312 7200 | .build()
|
8313 7201 | .expect("invalid params");
|
8314 7202 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8315 7203 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8316 7204 | let error = endpoint.expect_err("expected error: Partition does not support FIPS [Data Plane with short zone fips with AP china region]");
|
8317 7205 | assert_eq!(format!("{}", error), "Partition does not support FIPS")
|
8318 7206 | }
|
8319 7207 |
|
8320 7208 | /// Data Plane with short zone (13 chars) fips
|
8321 7209 | #[test]
|
8322 7210 | fn test_289() {
|
8323 7211 | let params = crate::config::endpoint::Params::builder()
|
8324 7212 | .region("us-west-2".to_string())
|
8325 7213 | .bucket("mybucket--test-zone-ab1--x-s3".to_string())
|
8326 7214 | .use_fips(true)
|
8327 7215 | .use_dual_stack(false)
|
8328 7216 | .accelerate(false)
|
8329 7217 | .use_s3_express_control_endpoint(false)
|
8330 7218 | .build()
|
8331 7219 | .expect("invalid params");
|
8332 7220 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8333 7221 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8334 7222 | let endpoint =
|
8335 7223 | endpoint.expect("Expected valid endpoint: https://mybucket--test-zone-ab1--x-s3.s3express-fips-test-zone-ab1.us-west-2.amazonaws.com");
|
8336 7224 | assert_eq!(
|
8337 7225 | endpoint,
|
8338 7226 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8339 7227 | .url("https://mybucket--test-zone-ab1--x-s3.s3express-fips-test-zone-ab1.us-west-2.amazonaws.com")
|
8340 - | .property(
|
8341 - | "authSchemes",
|
8342 - | vec![{
|
8343 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8344 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8345 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8346 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8347 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8348 - | out
|
8349 - | }
|
8350 - | .into()]
|
7228 + | .auth_scheme(
|
7229 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7230 + | .put("disableDoubleEncoding", true)
|
7231 + | .put("signingName", "s3express".to_string())
|
7232 + | .put("signingRegion", "us-west-2".to_string())
|
8351 7233 | )
|
8352 7234 | .property("backend", "S3Express".to_string())
|
8353 7235 | .build()
|
8354 7236 | );
|
8355 7237 | }
|
8356 7238 |
|
8357 7239 | /// Data Plane with short zone (13 chars) fips with AP
|
8358 7240 | #[test]
|
8359 7241 | fn test_290() {
|
8360 7242 | let params = crate::config::endpoint::Params::builder()
|
8361 7243 | .region("us-west-2".to_string())
|
8362 7244 | .bucket("myaccesspoint--test-zone-ab1--xa-s3".to_string())
|
8363 7245 | .use_fips(true)
|
8364 7246 | .use_dual_stack(false)
|
8365 7247 | .accelerate(false)
|
8366 7248 | .use_s3_express_control_endpoint(false)
|
8367 7249 | .build()
|
8368 7250 | .expect("invalid params");
|
8369 7251 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8370 7252 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8371 7253 | let endpoint = endpoint
|
8372 7254 | .expect("Expected valid endpoint: https://myaccesspoint--test-zone-ab1--xa-s3.s3express-fips-test-zone-ab1.us-west-2.amazonaws.com");
|
8373 7255 | assert_eq!(
|
8374 7256 | endpoint,
|
8375 7257 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8376 7258 | .url("https://myaccesspoint--test-zone-ab1--xa-s3.s3express-fips-test-zone-ab1.us-west-2.amazonaws.com")
|
8377 - | .property(
|
8378 - | "authSchemes",
|
8379 - | vec![{
|
8380 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8381 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8382 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8383 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8384 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8385 - | out
|
8386 - | }
|
8387 - | .into()]
|
7259 + | .auth_scheme(
|
7260 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7261 + | .put("disableDoubleEncoding", true)
|
7262 + | .put("signingName", "s3express".to_string())
|
7263 + | .put("signingRegion", "us-west-2".to_string())
|
8388 7264 | )
|
8389 7265 | .property("backend", "S3Express".to_string())
|
8390 7266 | .build()
|
8391 7267 | );
|
8392 7268 | }
|
8393 7269 |
|
8394 7270 | /// Data Plane with medium zone (14 chars) fips
|
8395 7271 | #[test]
|
8396 7272 | fn test_291() {
|
8397 7273 | let params = crate::config::endpoint::Params::builder()
|
8398 7274 | .region("us-west-2".to_string())
|
8399 7275 | .bucket("mybucket--test1-zone-ab1--x-s3".to_string())
|
8400 7276 | .use_fips(true)
|
8401 7277 | .use_dual_stack(false)
|
8402 7278 | .accelerate(false)
|
8403 7279 | .use_s3_express_control_endpoint(false)
|
8404 7280 | .build()
|
8405 7281 | .expect("invalid params");
|
8406 7282 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8407 7283 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8408 7284 | let endpoint =
|
8409 7285 | endpoint.expect("Expected valid endpoint: https://mybucket--test1-zone-ab1--x-s3.s3express-fips-test1-zone-ab1.us-west-2.amazonaws.com");
|
8410 7286 | assert_eq!(
|
8411 7287 | endpoint,
|
8412 7288 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8413 7289 | .url("https://mybucket--test1-zone-ab1--x-s3.s3express-fips-test1-zone-ab1.us-west-2.amazonaws.com")
|
8414 - | .property(
|
8415 - | "authSchemes",
|
8416 - | vec![{
|
8417 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8418 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8419 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8420 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8421 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8422 - | out
|
8423 - | }
|
8424 - | .into()]
|
7290 + | .auth_scheme(
|
7291 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7292 + | .put("disableDoubleEncoding", true)
|
7293 + | .put("signingName", "s3express".to_string())
|
7294 + | .put("signingRegion", "us-west-2".to_string())
|
8425 7295 | )
|
8426 7296 | .property("backend", "S3Express".to_string())
|
8427 7297 | .build()
|
8428 7298 | );
|
8429 7299 | }
|
8430 7300 |
|
8431 7301 | /// Data Plane with medium zone (14 chars) fips with AP
|
8432 7302 | #[test]
|
8433 7303 | fn test_292() {
|
8434 7304 | let params = crate::config::endpoint::Params::builder()
|
8435 7305 | .region("us-west-2".to_string())
|
8436 7306 | .bucket("myaccesspoint--test1-zone-ab1--xa-s3".to_string())
|
8437 7307 | .use_fips(true)
|
8438 7308 | .use_dual_stack(false)
|
8439 7309 | .accelerate(false)
|
8440 7310 | .use_s3_express_control_endpoint(false)
|
8441 7311 | .build()
|
8442 7312 | .expect("invalid params");
|
8443 7313 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8444 7314 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8445 7315 | let endpoint = endpoint
|
8446 7316 | .expect("Expected valid endpoint: https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-fips-test1-zone-ab1.us-west-2.amazonaws.com");
|
8447 7317 | assert_eq!(
|
8448 7318 | endpoint,
|
8449 7319 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8450 7320 | .url("https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-fips-test1-zone-ab1.us-west-2.amazonaws.com")
|
8451 - | .property(
|
8452 - | "authSchemes",
|
8453 - | vec![{
|
8454 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8455 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8456 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8457 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8458 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8459 - | out
|
8460 - | }
|
8461 - | .into()]
|
7321 + | .auth_scheme(
|
7322 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7323 + | .put("disableDoubleEncoding", true)
|
7324 + | .put("signingName", "s3express".to_string())
|
7325 + | .put("signingRegion", "us-west-2".to_string())
|
8462 7326 | )
|
8463 7327 | .property("backend", "S3Express".to_string())
|
8464 7328 | .build()
|
8465 7329 | );
|
8466 7330 | }
|
8467 7331 |
|
8468 7332 | /// Data Plane with long zone (20 chars) fips
|
8469 7333 | #[test]
|
8470 7334 | fn test_293() {
|
8471 7335 | let params = crate::config::endpoint::Params::builder()
|
8472 7336 | .region("us-west-2".to_string())
|
8473 7337 | .bucket("mybucket--test1-long1-zone-ab1--x-s3".to_string())
|
8474 7338 | .use_fips(true)
|
8475 7339 | .use_dual_stack(false)
|
8476 7340 | .accelerate(false)
|
8477 7341 | .use_s3_express_control_endpoint(false)
|
8478 7342 | .build()
|
8479 7343 | .expect("invalid params");
|
8480 7344 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8481 7345 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8482 7346 | let endpoint = endpoint.expect(
|
8483 7347 | "Expected valid endpoint: https://mybucket--test1-long1-zone-ab1--x-s3.s3express-fips-test1-long1-zone-ab1.us-west-2.amazonaws.com",
|
8484 7348 | );
|
8485 7349 | assert_eq!(
|
8486 7350 | endpoint,
|
8487 7351 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8488 7352 | .url("https://mybucket--test1-long1-zone-ab1--x-s3.s3express-fips-test1-long1-zone-ab1.us-west-2.amazonaws.com")
|
8489 - | .property(
|
8490 - | "authSchemes",
|
8491 - | vec![{
|
8492 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8493 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8494 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8495 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8496 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8497 - | out
|
8498 - | }
|
8499 - | .into()]
|
7353 + | .auth_scheme(
|
7354 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7355 + | .put("disableDoubleEncoding", true)
|
7356 + | .put("signingName", "s3express".to_string())
|
7357 + | .put("signingRegion", "us-west-2".to_string())
|
8500 7358 | )
|
8501 7359 | .property("backend", "S3Express".to_string())
|
8502 7360 | .build()
|
8503 7361 | );
|
8504 7362 | }
|
8505 7363 |
|
8506 7364 | /// Data Plane with long zone (20 chars) fips with AP
|
8507 7365 | #[test]
|
8508 7366 | fn test_294() {
|
8509 7367 | let params = crate::config::endpoint::Params::builder()
|
8510 7368 | .region("us-west-2".to_string())
|
8511 7369 | .bucket("myaccesspoint--test1-long1-zone-ab1--xa-s3".to_string())
|
8512 7370 | .use_fips(true)
|
8513 7371 | .use_dual_stack(false)
|
8514 7372 | .accelerate(false)
|
8515 7373 | .use_s3_express_control_endpoint(false)
|
8516 7374 | .build()
|
8517 7375 | .expect("invalid params");
|
8518 7376 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8519 7377 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8520 7378 | let endpoint = endpoint.expect(
|
8521 7379 | "Expected valid endpoint: https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-fips-test1-long1-zone-ab1.us-west-2.amazonaws.com",
|
8522 7380 | );
|
8523 7381 | assert_eq!(
|
8524 7382 | endpoint,
|
8525 7383 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8526 7384 | .url("https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-fips-test1-long1-zone-ab1.us-west-2.amazonaws.com")
|
8527 - | .property(
|
8528 - | "authSchemes",
|
8529 - | vec![{
|
8530 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8531 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8532 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8533 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8534 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8535 - | out
|
8536 - | }
|
8537 - | .into()]
|
7385 + | .auth_scheme(
|
7386 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7387 + | .put("disableDoubleEncoding", true)
|
7388 + | .put("signingName", "s3express".to_string())
|
7389 + | .put("signingRegion", "us-west-2".to_string())
|
8538 7390 | )
|
8539 7391 | .property("backend", "S3Express".to_string())
|
8540 7392 | .build()
|
8541 7393 | );
|
8542 7394 | }
|
8543 7395 |
|
8544 7396 | /// Data Plane with long AZ
|
8545 7397 | #[test]
|
8546 7398 | fn test_295() {
|
8547 7399 | let params = crate::config::endpoint::Params::builder()
|
8548 7400 | .region("us-west-2".to_string())
|
8549 7401 | .bucket("mybucket--test1-az1--x-s3".to_string())
|
8550 7402 | .use_fips(false)
|
8551 7403 | .use_dual_stack(false)
|
8552 7404 | .accelerate(false)
|
8553 7405 | .use_s3_express_control_endpoint(false)
|
8554 7406 | .build()
|
8555 7407 | .expect("invalid params");
|
8556 7408 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8557 7409 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8558 7410 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--test1-az1--x-s3.s3express-test1-az1.us-west-2.amazonaws.com");
|
8559 7411 | assert_eq!(
|
8560 7412 | endpoint,
|
8561 7413 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8562 7414 | .url("https://mybucket--test1-az1--x-s3.s3express-test1-az1.us-west-2.amazonaws.com")
|
8563 - | .property(
|
8564 - | "authSchemes",
|
8565 - | vec![{
|
8566 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8567 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8568 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8569 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8570 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8571 - | out
|
8572 - | }
|
8573 - | .into()]
|
7415 + | .auth_scheme(
|
7416 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7417 + | .put("disableDoubleEncoding", true)
|
7418 + | .put("signingName", "s3express".to_string())
|
7419 + | .put("signingRegion", "us-west-2".to_string())
|
8574 7420 | )
|
8575 7421 | .property("backend", "S3Express".to_string())
|
8576 7422 | .build()
|
8577 7423 | );
|
8578 7424 | }
|
8579 7425 |
|
8580 7426 | /// Data Plane with long AZ with AP
|
8581 7427 | #[test]
|
8582 7428 | fn test_296() {
|
8583 7429 | let params = crate::config::endpoint::Params::builder()
|
8584 7430 | .region("us-west-2".to_string())
|
8585 7431 | .bucket("myaccesspoint--test1-az1--xa-s3".to_string())
|
8586 7432 | .use_fips(false)
|
8587 7433 | .use_dual_stack(false)
|
8588 7434 | .accelerate(false)
|
8589 7435 | .use_s3_express_control_endpoint(false)
|
8590 7436 | .build()
|
8591 7437 | .expect("invalid params");
|
8592 7438 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8593 7439 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8594 7440 | let endpoint =
|
8595 7441 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-az1--xa-s3.s3express-test1-az1.us-west-2.amazonaws.com");
|
8596 7442 | assert_eq!(
|
8597 7443 | endpoint,
|
8598 7444 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8599 7445 | .url("https://myaccesspoint--test1-az1--xa-s3.s3express-test1-az1.us-west-2.amazonaws.com")
|
8600 - | .property(
|
8601 - | "authSchemes",
|
8602 - | vec![{
|
8603 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8604 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8605 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8606 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8607 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8608 - | out
|
8609 - | }
|
8610 - | .into()]
|
7446 + | .auth_scheme(
|
7447 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7448 + | .put("disableDoubleEncoding", true)
|
7449 + | .put("signingName", "s3express".to_string())
|
7450 + | .put("signingRegion", "us-west-2".to_string())
|
8611 7451 | )
|
8612 7452 | .property("backend", "S3Express".to_string())
|
8613 7453 | .build()
|
8614 7454 | );
|
8615 7455 | }
|
8616 7456 |
|
8617 7457 | /// Data Plane with long AZ fips
|
8618 7458 | #[test]
|
8619 7459 | fn test_297() {
|
8620 7460 | let params = crate::config::endpoint::Params::builder()
|
8621 7461 | .region("us-west-2".to_string())
|
8622 7462 | .bucket("mybucket--test1-az1--x-s3".to_string())
|
8623 7463 | .use_fips(true)
|
8624 7464 | .use_dual_stack(false)
|
8625 7465 | .accelerate(false)
|
8626 7466 | .use_s3_express_control_endpoint(false)
|
8627 7467 | .build()
|
8628 7468 | .expect("invalid params");
|
8629 7469 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8630 7470 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8631 7471 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--test1-az1--x-s3.s3express-fips-test1-az1.us-west-2.amazonaws.com");
|
8632 7472 | assert_eq!(
|
8633 7473 | endpoint,
|
8634 7474 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8635 7475 | .url("https://mybucket--test1-az1--x-s3.s3express-fips-test1-az1.us-west-2.amazonaws.com")
|
8636 - | .property(
|
8637 - | "authSchemes",
|
8638 - | vec![{
|
8639 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8640 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8641 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8642 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8643 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8644 - | out
|
8645 - | }
|
8646 - | .into()]
|
7476 + | .auth_scheme(
|
7477 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7478 + | .put("disableDoubleEncoding", true)
|
7479 + | .put("signingName", "s3express".to_string())
|
7480 + | .put("signingRegion", "us-west-2".to_string())
|
8647 7481 | )
|
8648 7482 | .property("backend", "S3Express".to_string())
|
8649 7483 | .build()
|
8650 7484 | );
|
8651 7485 | }
|
8652 7486 |
|
8653 7487 | /// Data Plane with long AZ fips with AP
|
8654 7488 | #[test]
|
8655 7489 | fn test_298() {
|
8656 7490 | let params = crate::config::endpoint::Params::builder()
|
8657 7491 | .region("us-west-2".to_string())
|
8658 7492 | .bucket("myaccesspoint--test1-az1--xa-s3".to_string())
|
8659 7493 | .use_fips(true)
|
8660 7494 | .use_dual_stack(false)
|
8661 7495 | .accelerate(false)
|
8662 7496 | .use_s3_express_control_endpoint(false)
|
8663 7497 | .build()
|
8664 7498 | .expect("invalid params");
|
8665 7499 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8666 7500 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8667 7501 | let endpoint =
|
8668 7502 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-az1--xa-s3.s3express-fips-test1-az1.us-west-2.amazonaws.com");
|
8669 7503 | assert_eq!(
|
8670 7504 | endpoint,
|
8671 7505 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8672 7506 | .url("https://myaccesspoint--test1-az1--xa-s3.s3express-fips-test1-az1.us-west-2.amazonaws.com")
|
8673 - | .property(
|
8674 - | "authSchemes",
|
8675 - | vec![{
|
8676 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8677 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
8678 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8679 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8680 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8681 - | out
|
8682 - | }
|
8683 - | .into()]
|
7507 + | .auth_scheme(
|
7508 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
7509 + | .put("disableDoubleEncoding", true)
|
7510 + | .put("signingName", "s3express".to_string())
|
7511 + | .put("signingRegion", "us-west-2".to_string())
|
8684 7512 | )
|
8685 7513 | .property("backend", "S3Express".to_string())
|
8686 7514 | .build()
|
8687 7515 | );
|
8688 7516 | }
|
8689 7517 |
|
8690 7518 | /// Control plane with short AZ bucket
|
8691 7519 | #[test]
|
8692 7520 | fn test_299() {
|
8693 7521 | let params = crate::config::endpoint::Params::builder()
|
8694 7522 | .region("us-east-1".to_string())
|
8695 7523 | .bucket("mybucket--test-ab1--x-s3".to_string())
|
8696 7524 | .use_fips(false)
|
8697 7525 | .use_dual_stack(false)
|
8698 7526 | .accelerate(false)
|
8699 7527 | .use_s3_express_control_endpoint(true)
|
8700 7528 | .disable_s3_express_session_auth(false)
|
8701 7529 | .build()
|
8702 7530 | .expect("invalid params");
|
8703 7531 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8704 7532 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8705 7533 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3express-control.us-east-1.amazonaws.com/mybucket--test-ab1--x-s3");
|
8706 7534 | assert_eq!(
|
8707 7535 | endpoint,
|
8708 7536 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8709 7537 | .url("https://s3express-control.us-east-1.amazonaws.com/mybucket--test-ab1--x-s3")
|
8710 - | .property(
|
8711 - | "authSchemes",
|
8712 - | vec![{
|
8713 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8714 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
8715 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8716 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
8717 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8718 - | out
|
8719 - | }
|
8720 - | .into()]
|
7538 + | .auth_scheme(
|
7539 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7540 + | .put("disableDoubleEncoding", true)
|
7541 + | .put("signingName", "s3express".to_string())
|
7542 + | .put("signingRegion", "us-east-1".to_string())
|
8721 7543 | )
|
8722 7544 | .property("backend", "S3Express".to_string())
|
8723 7545 | .build()
|
8724 7546 | );
|
8725 7547 | }
|
8726 7548 |
|
8727 7549 | /// Control plane with short AZ bucket china region
|
8728 7550 | #[test]
|
8729 7551 | fn test_300() {
|
8730 7552 | let params = crate::config::endpoint::Params::builder()
|
8731 7553 | .region("cn-north-1".to_string())
|
8732 7554 | .bucket("mybucket--test-ab1--x-s3".to_string())
|
8733 7555 | .use_fips(false)
|
8734 7556 | .use_dual_stack(false)
|
8735 7557 | .accelerate(false)
|
8736 7558 | .use_s3_express_control_endpoint(true)
|
8737 7559 | .disable_s3_express_session_auth(false)
|
8738 7560 | .build()
|
8739 7561 | .expect("invalid params");
|
8740 7562 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8741 7563 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8742 7564 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3express-control.cn-north-1.amazonaws.com.cn/mybucket--test-ab1--x-s3");
|
8743 7565 | assert_eq!(
|
8744 7566 | endpoint,
|
8745 7567 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8746 7568 | .url("https://s3express-control.cn-north-1.amazonaws.com.cn/mybucket--test-ab1--x-s3")
|
8747 - | .property(
|
8748 - | "authSchemes",
|
8749 - | vec![{
|
8750 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8751 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
8752 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8753 - | out.insert("signingRegion".to_string(), "cn-north-1".to_string().into());
|
8754 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8755 - | out
|
8756 - | }
|
8757 - | .into()]
|
7569 + | .auth_scheme(
|
7570 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7571 + | .put("disableDoubleEncoding", true)
|
7572 + | .put("signingName", "s3express".to_string())
|
7573 + | .put("signingRegion", "cn-north-1".to_string())
|
8758 7574 | )
|
8759 7575 | .property("backend", "S3Express".to_string())
|
8760 7576 | .build()
|
8761 7577 | );
|
8762 7578 | }
|
8763 7579 |
|
8764 7580 | /// Control plane with short AZ bucket and fips
|
8765 7581 | #[test]
|
8766 7582 | fn test_301() {
|
8767 7583 | let params = crate::config::endpoint::Params::builder()
|
8768 7584 | .region("us-east-1".to_string())
|
8769 7585 | .bucket("mybucket--test-ab1--x-s3".to_string())
|
8770 7586 | .use_fips(true)
|
8771 7587 | .use_dual_stack(false)
|
8772 7588 | .accelerate(false)
|
8773 7589 | .use_s3_express_control_endpoint(true)
|
8774 7590 | .disable_s3_express_session_auth(false)
|
8775 7591 | .build()
|
8776 7592 | .expect("invalid params");
|
8777 7593 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8778 7594 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8779 7595 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3express-control-fips.us-east-1.amazonaws.com/mybucket--test-ab1--x-s3");
|
8780 7596 | assert_eq!(
|
8781 7597 | endpoint,
|
8782 7598 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8783 7599 | .url("https://s3express-control-fips.us-east-1.amazonaws.com/mybucket--test-ab1--x-s3")
|
8784 - | .property(
|
8785 - | "authSchemes",
|
8786 - | vec![{
|
8787 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8788 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
8789 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8790 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
8791 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8792 - | out
|
8793 - | }
|
8794 - | .into()]
|
7600 + | .auth_scheme(
|
7601 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7602 + | .put("disableDoubleEncoding", true)
|
7603 + | .put("signingName", "s3express".to_string())
|
7604 + | .put("signingRegion", "us-east-1".to_string())
|
8795 7605 | )
|
8796 7606 | .property("backend", "S3Express".to_string())
|
8797 7607 | .build()
|
8798 7608 | );
|
8799 7609 | }
|
8800 7610 |
|
8801 7611 | /// Control plane with short AZ bucket and fips china region
|
8802 7612 | #[test]
|
8803 7613 | fn test_302() {
|
8804 7614 | let params = crate::config::endpoint::Params::builder()
|
8805 7615 | .region("cn-north-1".to_string())
|
8806 7616 | .bucket("mybucket--test-ab1--x-s3".to_string())
|
8807 7617 | .use_fips(true)
|
8808 7618 | .use_dual_stack(false)
|
8809 7619 | .accelerate(false)
|
8810 7620 | .use_s3_express_control_endpoint(true)
|
8811 7621 | .disable_s3_express_session_auth(false)
|
8812 7622 | .build()
|
8813 7623 | .expect("invalid params");
|
8814 7624 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8815 7625 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8816 7626 | let error = endpoint.expect_err("expected error: Partition does not support FIPS [Control plane with short AZ bucket and fips china region]");
|
8817 7627 | assert_eq!(format!("{}", error), "Partition does not support FIPS")
|
8818 7628 | }
|
8819 7629 |
|
8820 7630 | /// Control plane without bucket
|
8821 7631 | #[test]
|
8822 7632 | fn test_303() {
|
8823 7633 | let params = crate::config::endpoint::Params::builder()
|
8824 7634 | .region("us-east-1".to_string())
|
8825 7635 | .use_fips(false)
|
8826 7636 | .use_dual_stack(false)
|
8827 7637 | .accelerate(false)
|
8828 7638 | .use_s3_express_control_endpoint(true)
|
8829 7639 | .disable_s3_express_session_auth(false)
|
8830 7640 | .build()
|
8831 7641 | .expect("invalid params");
|
8832 7642 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8833 7643 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8834 7644 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3express-control.us-east-1.amazonaws.com");
|
8835 7645 | assert_eq!(
|
8836 7646 | endpoint,
|
8837 7647 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8838 7648 | .url("https://s3express-control.us-east-1.amazonaws.com")
|
8839 - | .property(
|
8840 - | "authSchemes",
|
8841 - | vec![{
|
8842 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8843 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
8844 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8845 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
8846 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8847 - | out
|
8848 - | }
|
8849 - | .into()]
|
7649 + | .auth_scheme(
|
7650 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7651 + | .put("disableDoubleEncoding", true)
|
7652 + | .put("signingName", "s3express".to_string())
|
7653 + | .put("signingRegion", "us-east-1".to_string())
|
8850 7654 | )
|
8851 7655 | .property("backend", "S3Express".to_string())
|
8852 7656 | .build()
|
8853 7657 | );
|
8854 7658 | }
|
8855 7659 |
|
8856 7660 | /// Control plane without bucket and fips
|
8857 7661 | #[test]
|
8858 7662 | fn test_304() {
|
8859 7663 | let params = crate::config::endpoint::Params::builder()
|
8860 7664 | .region("us-east-1".to_string())
|
8861 7665 | .use_fips(true)
|
8862 7666 | .use_dual_stack(false)
|
8863 7667 | .accelerate(false)
|
8864 7668 | .use_s3_express_control_endpoint(true)
|
8865 7669 | .disable_s3_express_session_auth(false)
|
8866 7670 | .build()
|
8867 7671 | .expect("invalid params");
|
8868 7672 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8869 7673 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8870 7674 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3express-control-fips.us-east-1.amazonaws.com");
|
8871 7675 | assert_eq!(
|
8872 7676 | endpoint,
|
8873 7677 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8874 7678 | .url("https://s3express-control-fips.us-east-1.amazonaws.com")
|
8875 - | .property(
|
8876 - | "authSchemes",
|
8877 - | vec![{
|
8878 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8879 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
8880 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8881 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
8882 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8883 - | out
|
8884 - | }
|
8885 - | .into()]
|
7679 + | .auth_scheme(
|
7680 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7681 + | .put("disableDoubleEncoding", true)
|
7682 + | .put("signingName", "s3express".to_string())
|
7683 + | .put("signingRegion", "us-east-1".to_string())
|
8886 7684 | )
|
8887 7685 | .property("backend", "S3Express".to_string())
|
8888 7686 | .build()
|
8889 7687 | );
|
8890 7688 | }
|
8891 7689 |
|
8892 7690 | /// Data Plane sigv4 auth with short AZ
|
8893 7691 | #[test]
|
8894 7692 | fn test_305() {
|
8895 7693 | let params = crate::config::endpoint::Params::builder()
|
8896 7694 | .region("us-west-2".to_string())
|
8897 7695 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
8898 7696 | .use_fips(false)
|
8899 7697 | .use_dual_stack(false)
|
8900 7698 | .accelerate(false)
|
8901 7699 | .disable_s3_express_session_auth(true)
|
8902 7700 | .build()
|
8903 7701 | .expect("invalid params");
|
8904 7702 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8905 7703 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8906 7704 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az1--x-s3.s3express-usw2-az1.us-west-2.amazonaws.com");
|
8907 7705 | assert_eq!(
|
8908 7706 | endpoint,
|
8909 7707 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8910 7708 | .url("https://mybucket--usw2-az1--x-s3.s3express-usw2-az1.us-west-2.amazonaws.com")
|
8911 - | .property(
|
8912 - | "authSchemes",
|
8913 - | vec![{
|
8914 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8915 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
8916 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8917 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8918 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8919 - | out
|
8920 - | }
|
8921 - | .into()]
|
7709 + | .auth_scheme(
|
7710 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7711 + | .put("disableDoubleEncoding", true)
|
7712 + | .put("signingName", "s3express".to_string())
|
7713 + | .put("signingRegion", "us-west-2".to_string())
|
8922 7714 | )
|
8923 7715 | .property("backend", "S3Express".to_string())
|
8924 7716 | .build()
|
8925 7717 | );
|
8926 7718 | }
|
8927 7719 |
|
8928 7720 | /// Data Plane sigv4 auth with short AZ with AP
|
8929 7721 | #[test]
|
8930 7722 | fn test_306() {
|
8931 7723 | let params = crate::config::endpoint::Params::builder()
|
8932 7724 | .region("us-west-2".to_string())
|
8933 7725 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
8934 7726 | .use_fips(false)
|
8935 7727 | .use_dual_stack(false)
|
8936 7728 | .accelerate(false)
|
8937 7729 | .disable_s3_express_session_auth(true)
|
8938 7730 | .build()
|
8939 7731 | .expect("invalid params");
|
8940 7732 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8941 7733 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8942 7734 | let endpoint = endpoint.expect("Expected valid endpoint: https://myaccesspoint--usw2-az1--xa-s3.s3express-usw2-az1.us-west-2.amazonaws.com");
|
8943 7735 | assert_eq!(
|
8944 7736 | endpoint,
|
8945 7737 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8946 7738 | .url("https://myaccesspoint--usw2-az1--xa-s3.s3express-usw2-az1.us-west-2.amazonaws.com")
|
8947 - | .property(
|
8948 - | "authSchemes",
|
8949 - | vec![{
|
8950 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8951 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
8952 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8953 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8954 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8955 - | out
|
8956 - | }
|
8957 - | .into()]
|
7739 + | .auth_scheme(
|
7740 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7741 + | .put("disableDoubleEncoding", true)
|
7742 + | .put("signingName", "s3express".to_string())
|
7743 + | .put("signingRegion", "us-west-2".to_string())
|
8958 7744 | )
|
8959 7745 | .property("backend", "S3Express".to_string())
|
8960 7746 | .build()
|
8961 7747 | );
|
8962 7748 | }
|
8963 7749 |
|
8964 7750 | /// Data Plane sigv4 auth with short zone (13 chars)
|
8965 7751 | #[test]
|
8966 7752 | fn test_307() {
|
8967 7753 | let params = crate::config::endpoint::Params::builder()
|
8968 7754 | .region("us-west-2".to_string())
|
8969 7755 | .bucket("mybucket--test-zone-ab1--x-s3".to_string())
|
8970 7756 | .use_fips(false)
|
8971 7757 | .use_dual_stack(false)
|
8972 7758 | .accelerate(false)
|
8973 7759 | .disable_s3_express_session_auth(true)
|
8974 7760 | .build()
|
8975 7761 | .expect("invalid params");
|
8976 7762 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
8977 7763 | let endpoint = resolver.resolve_endpoint(¶ms);
|
8978 7764 | let endpoint =
|
8979 7765 | endpoint.expect("Expected valid endpoint: https://mybucket--test-zone-ab1--x-s3.s3express-test-zone-ab1.us-west-2.amazonaws.com");
|
8980 7766 | assert_eq!(
|
8981 7767 | endpoint,
|
8982 7768 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
8983 7769 | .url("https://mybucket--test-zone-ab1--x-s3.s3express-test-zone-ab1.us-west-2.amazonaws.com")
|
8984 - | .property(
|
8985 - | "authSchemes",
|
8986 - | vec![{
|
8987 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
8988 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
8989 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
8990 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
8991 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
8992 - | out
|
8993 - | }
|
8994 - | .into()]
|
7770 + | .auth_scheme(
|
7771 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7772 + | .put("disableDoubleEncoding", true)
|
7773 + | .put("signingName", "s3express".to_string())
|
7774 + | .put("signingRegion", "us-west-2".to_string())
|
8995 7775 | )
|
8996 7776 | .property("backend", "S3Express".to_string())
|
8997 7777 | .build()
|
8998 7778 | );
|
8999 7779 | }
|
9000 7780 |
|
9001 7781 | /// Data Plane sigv4 auth with short zone (13 chars) with AP
|
9002 7782 | #[test]
|
9003 7783 | fn test_308() {
|
9004 7784 | let params = crate::config::endpoint::Params::builder()
|
9005 7785 | .region("us-west-2".to_string())
|
9006 7786 | .bucket("myaccesspoint--test-zone-ab1--xa-s3".to_string())
|
9007 7787 | .use_fips(false)
|
9008 7788 | .use_dual_stack(false)
|
9009 7789 | .accelerate(false)
|
9010 7790 | .disable_s3_express_session_auth(true)
|
9011 7791 | .build()
|
9012 7792 | .expect("invalid params");
|
9013 7793 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9014 7794 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9015 7795 | let endpoint =
|
9016 7796 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test-zone-ab1--xa-s3.s3express-test-zone-ab1.us-west-2.amazonaws.com");
|
9017 7797 | assert_eq!(
|
9018 7798 | endpoint,
|
9019 7799 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9020 7800 | .url("https://myaccesspoint--test-zone-ab1--xa-s3.s3express-test-zone-ab1.us-west-2.amazonaws.com")
|
9021 - | .property(
|
9022 - | "authSchemes",
|
9023 - | vec![{
|
9024 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9025 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9026 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9027 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9028 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9029 - | out
|
9030 - | }
|
9031 - | .into()]
|
7801 + | .auth_scheme(
|
7802 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7803 + | .put("disableDoubleEncoding", true)
|
7804 + | .put("signingName", "s3express".to_string())
|
7805 + | .put("signingRegion", "us-west-2".to_string())
|
9032 7806 | )
|
9033 7807 | .property("backend", "S3Express".to_string())
|
9034 7808 | .build()
|
9035 7809 | );
|
9036 7810 | }
|
9037 7811 |
|
9038 7812 | /// Data Plane sigv4 auth with short AZ fips
|
9039 7813 | #[test]
|
9040 7814 | fn test_309() {
|
9041 7815 | let params = crate::config::endpoint::Params::builder()
|
9042 7816 | .region("us-west-2".to_string())
|
9043 7817 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
9044 7818 | .use_fips(true)
|
9045 7819 | .use_dual_stack(false)
|
9046 7820 | .accelerate(false)
|
9047 7821 | .disable_s3_express_session_auth(true)
|
9048 7822 | .build()
|
9049 7823 | .expect("invalid params");
|
9050 7824 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9051 7825 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9052 7826 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az1--x-s3.s3express-fips-usw2-az1.us-west-2.amazonaws.com");
|
9053 7827 | assert_eq!(
|
9054 7828 | endpoint,
|
9055 7829 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9056 7830 | .url("https://mybucket--usw2-az1--x-s3.s3express-fips-usw2-az1.us-west-2.amazonaws.com")
|
9057 - | .property(
|
9058 - | "authSchemes",
|
9059 - | vec![{
|
9060 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9061 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9062 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9063 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9064 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9065 - | out
|
9066 - | }
|
9067 - | .into()]
|
7831 + | .auth_scheme(
|
7832 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7833 + | .put("disableDoubleEncoding", true)
|
7834 + | .put("signingName", "s3express".to_string())
|
7835 + | .put("signingRegion", "us-west-2".to_string())
|
9068 7836 | )
|
9069 7837 | .property("backend", "S3Express".to_string())
|
9070 7838 | .build()
|
9071 7839 | );
|
9072 7840 | }
|
9073 7841 |
|
9074 7842 | /// Data Plane sigv4 auth with short AZ fips with AP
|
9075 7843 | #[test]
|
9076 7844 | fn test_310() {
|
9077 7845 | let params = crate::config::endpoint::Params::builder()
|
9078 7846 | .region("us-west-2".to_string())
|
9079 7847 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
9080 7848 | .use_fips(true)
|
9081 7849 | .use_dual_stack(false)
|
9082 7850 | .accelerate(false)
|
9083 7851 | .disable_s3_express_session_auth(true)
|
9084 7852 | .build()
|
9085 7853 | .expect("invalid params");
|
9086 7854 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9087 7855 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9088 7856 | let endpoint =
|
9089 7857 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--usw2-az1--xa-s3.s3express-fips-usw2-az1.us-west-2.amazonaws.com");
|
9090 7858 | assert_eq!(
|
9091 7859 | endpoint,
|
9092 7860 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9093 7861 | .url("https://myaccesspoint--usw2-az1--xa-s3.s3express-fips-usw2-az1.us-west-2.amazonaws.com")
|
9094 - | .property(
|
9095 - | "authSchemes",
|
9096 - | vec![{
|
9097 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9098 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9099 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9100 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9101 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9102 - | out
|
9103 - | }
|
9104 - | .into()]
|
7862 + | .auth_scheme(
|
7863 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7864 + | .put("disableDoubleEncoding", true)
|
7865 + | .put("signingName", "s3express".to_string())
|
7866 + | .put("signingRegion", "us-west-2".to_string())
|
9105 7867 | )
|
9106 7868 | .property("backend", "S3Express".to_string())
|
9107 7869 | .build()
|
9108 7870 | );
|
9109 7871 | }
|
9110 7872 |
|
9111 7873 | /// Data Plane sigv4 auth with short zone (13 chars) fips
|
9112 7874 | #[test]
|
9113 7875 | fn test_311() {
|
9114 7876 | let params = crate::config::endpoint::Params::builder()
|
9115 7877 | .region("us-west-2".to_string())
|
9116 7878 | .bucket("mybucket--test-zone-ab1--x-s3".to_string())
|
9117 7879 | .use_fips(true)
|
9118 7880 | .use_dual_stack(false)
|
9119 7881 | .accelerate(false)
|
9120 7882 | .disable_s3_express_session_auth(true)
|
9121 7883 | .build()
|
9122 7884 | .expect("invalid params");
|
9123 7885 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9124 7886 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9125 7887 | let endpoint =
|
9126 7888 | endpoint.expect("Expected valid endpoint: https://mybucket--test-zone-ab1--x-s3.s3express-fips-test-zone-ab1.us-west-2.amazonaws.com");
|
9127 7889 | assert_eq!(
|
9128 7890 | endpoint,
|
9129 7891 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9130 7892 | .url("https://mybucket--test-zone-ab1--x-s3.s3express-fips-test-zone-ab1.us-west-2.amazonaws.com")
|
9131 - | .property(
|
9132 - | "authSchemes",
|
9133 - | vec![{
|
9134 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9135 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9136 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9137 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9138 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9139 - | out
|
9140 - | }
|
9141 - | .into()]
|
7893 + | .auth_scheme(
|
7894 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7895 + | .put("disableDoubleEncoding", true)
|
7896 + | .put("signingName", "s3express".to_string())
|
7897 + | .put("signingRegion", "us-west-2".to_string())
|
9142 7898 | )
|
9143 7899 | .property("backend", "S3Express".to_string())
|
9144 7900 | .build()
|
9145 7901 | );
|
9146 7902 | }
|
9147 7903 |
|
9148 7904 | /// Data Plane sigv4 auth with short zone (13 chars) fips with AP
|
9149 7905 | #[test]
|
9150 7906 | fn test_312() {
|
9151 7907 | let params = crate::config::endpoint::Params::builder()
|
9152 7908 | .region("us-west-2".to_string())
|
9153 7909 | .bucket("myaccesspoint--test-zone-ab1--xa-s3".to_string())
|
9154 7910 | .use_fips(true)
|
9155 7911 | .use_dual_stack(false)
|
9156 7912 | .accelerate(false)
|
9157 7913 | .disable_s3_express_session_auth(true)
|
9158 7914 | .build()
|
9159 7915 | .expect("invalid params");
|
9160 7916 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9161 7917 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9162 7918 | let endpoint = endpoint
|
9163 7919 | .expect("Expected valid endpoint: https://myaccesspoint--test-zone-ab1--xa-s3.s3express-fips-test-zone-ab1.us-west-2.amazonaws.com");
|
9164 7920 | assert_eq!(
|
9165 7921 | endpoint,
|
9166 7922 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9167 7923 | .url("https://myaccesspoint--test-zone-ab1--xa-s3.s3express-fips-test-zone-ab1.us-west-2.amazonaws.com")
|
9168 - | .property(
|
9169 - | "authSchemes",
|
9170 - | vec![{
|
9171 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9172 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9173 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9174 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9175 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9176 - | out
|
9177 - | }
|
9178 - | .into()]
|
7924 + | .auth_scheme(
|
7925 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7926 + | .put("disableDoubleEncoding", true)
|
7927 + | .put("signingName", "s3express".to_string())
|
7928 + | .put("signingRegion", "us-west-2".to_string())
|
9179 7929 | )
|
9180 7930 | .property("backend", "S3Express".to_string())
|
9181 7931 | .build()
|
9182 7932 | );
|
9183 7933 | }
|
9184 7934 |
|
9185 7935 | /// Data Plane sigv4 auth with long AZ
|
9186 7936 | #[test]
|
9187 7937 | fn test_313() {
|
9188 7938 | let params = crate::config::endpoint::Params::builder()
|
9189 7939 | .region("us-west-2".to_string())
|
9190 7940 | .bucket("mybucket--test1-az1--x-s3".to_string())
|
9191 7941 | .use_fips(false)
|
9192 7942 | .use_dual_stack(false)
|
9193 7943 | .accelerate(false)
|
9194 7944 | .use_s3_express_control_endpoint(false)
|
9195 7945 | .disable_s3_express_session_auth(true)
|
9196 7946 | .build()
|
9197 7947 | .expect("invalid params");
|
9198 7948 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9199 7949 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9200 7950 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--test1-az1--x-s3.s3express-test1-az1.us-west-2.amazonaws.com");
|
9201 7951 | assert_eq!(
|
9202 7952 | endpoint,
|
9203 7953 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9204 7954 | .url("https://mybucket--test1-az1--x-s3.s3express-test1-az1.us-west-2.amazonaws.com")
|
9205 - | .property(
|
9206 - | "authSchemes",
|
9207 - | vec![{
|
9208 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9209 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9210 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9211 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9212 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9213 - | out
|
9214 - | }
|
9215 - | .into()]
|
7955 + | .auth_scheme(
|
7956 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7957 + | .put("disableDoubleEncoding", true)
|
7958 + | .put("signingName", "s3express".to_string())
|
7959 + | .put("signingRegion", "us-west-2".to_string())
|
9216 7960 | )
|
9217 7961 | .property("backend", "S3Express".to_string())
|
9218 7962 | .build()
|
9219 7963 | );
|
9220 7964 | }
|
9221 7965 |
|
9222 7966 | /// Data Plane sigv4 auth with long AZ with AP
|
9223 7967 | #[test]
|
9224 7968 | fn test_314() {
|
9225 7969 | let params = crate::config::endpoint::Params::builder()
|
9226 7970 | .region("us-west-2".to_string())
|
9227 7971 | .bucket("myaccesspoint--test1-az1--xa-s3".to_string())
|
9228 7972 | .use_fips(false)
|
9229 7973 | .use_dual_stack(false)
|
9230 7974 | .accelerate(false)
|
9231 7975 | .use_s3_express_control_endpoint(false)
|
9232 7976 | .disable_s3_express_session_auth(true)
|
9233 7977 | .build()
|
9234 7978 | .expect("invalid params");
|
9235 7979 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9236 7980 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9237 7981 | let endpoint =
|
9238 7982 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-az1--xa-s3.s3express-test1-az1.us-west-2.amazonaws.com");
|
9239 7983 | assert_eq!(
|
9240 7984 | endpoint,
|
9241 7985 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9242 7986 | .url("https://myaccesspoint--test1-az1--xa-s3.s3express-test1-az1.us-west-2.amazonaws.com")
|
9243 - | .property(
|
9244 - | "authSchemes",
|
9245 - | vec![{
|
9246 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9247 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9248 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9249 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9250 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9251 - | out
|
9252 - | }
|
9253 - | .into()]
|
7987 + | .auth_scheme(
|
7988 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
7989 + | .put("disableDoubleEncoding", true)
|
7990 + | .put("signingName", "s3express".to_string())
|
7991 + | .put("signingRegion", "us-west-2".to_string())
|
9254 7992 | )
|
9255 7993 | .property("backend", "S3Express".to_string())
|
9256 7994 | .build()
|
9257 7995 | );
|
9258 7996 | }
|
9259 7997 |
|
9260 7998 | /// Data Plane sigv4 auth with medium zone(14 chars)
|
9261 7999 | #[test]
|
9262 8000 | fn test_315() {
|
9263 8001 | let params = crate::config::endpoint::Params::builder()
|
9264 8002 | .region("us-west-2".to_string())
|
9265 8003 | .bucket("mybucket--test1-zone-ab1--x-s3".to_string())
|
9266 8004 | .use_fips(false)
|
9267 8005 | .use_dual_stack(false)
|
9268 8006 | .accelerate(false)
|
9269 8007 | .use_s3_express_control_endpoint(false)
|
9270 8008 | .disable_s3_express_session_auth(true)
|
9271 8009 | .build()
|
9272 8010 | .expect("invalid params");
|
9273 8011 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9274 8012 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9275 8013 | let endpoint =
|
9276 8014 | endpoint.expect("Expected valid endpoint: https://mybucket--test1-zone-ab1--x-s3.s3express-test1-zone-ab1.us-west-2.amazonaws.com");
|
9277 8015 | assert_eq!(
|
9278 8016 | endpoint,
|
9279 8017 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9280 8018 | .url("https://mybucket--test1-zone-ab1--x-s3.s3express-test1-zone-ab1.us-west-2.amazonaws.com")
|
9281 - | .property(
|
9282 - | "authSchemes",
|
9283 - | vec![{
|
9284 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9285 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9286 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9287 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9288 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9289 - | out
|
9290 - | }
|
9291 - | .into()]
|
8019 + | .auth_scheme(
|
8020 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8021 + | .put("disableDoubleEncoding", true)
|
8022 + | .put("signingName", "s3express".to_string())
|
8023 + | .put("signingRegion", "us-west-2".to_string())
|
9292 8024 | )
|
9293 8025 | .property("backend", "S3Express".to_string())
|
9294 8026 | .build()
|
9295 8027 | );
|
9296 8028 | }
|
9297 8029 |
|
9298 8030 | /// Data Plane sigv4 auth with medium zone(14 chars) with AP
|
9299 8031 | #[test]
|
9300 8032 | fn test_316() {
|
9301 8033 | let params = crate::config::endpoint::Params::builder()
|
9302 8034 | .region("us-west-2".to_string())
|
9303 8035 | .bucket("myaccesspoint--test1-zone-ab1--xa-s3".to_string())
|
9304 8036 | .use_fips(false)
|
9305 8037 | .use_dual_stack(false)
|
9306 8038 | .accelerate(false)
|
9307 8039 | .use_s3_express_control_endpoint(false)
|
9308 8040 | .disable_s3_express_session_auth(true)
|
9309 8041 | .build()
|
9310 8042 | .expect("invalid params");
|
9311 8043 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9312 8044 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9313 8045 | let endpoint =
|
9314 8046 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-test1-zone-ab1.us-west-2.amazonaws.com");
|
9315 8047 | assert_eq!(
|
9316 8048 | endpoint,
|
9317 8049 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9318 8050 | .url("https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-test1-zone-ab1.us-west-2.amazonaws.com")
|
9319 - | .property(
|
9320 - | "authSchemes",
|
9321 - | vec![{
|
9322 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9323 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9324 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9325 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9326 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9327 - | out
|
9328 - | }
|
9329 - | .into()]
|
8051 + | .auth_scheme(
|
8052 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8053 + | .put("disableDoubleEncoding", true)
|
8054 + | .put("signingName", "s3express".to_string())
|
8055 + | .put("signingRegion", "us-west-2".to_string())
|
9330 8056 | )
|
9331 8057 | .property("backend", "S3Express".to_string())
|
9332 8058 | .build()
|
9333 8059 | );
|
9334 8060 | }
|
9335 8061 |
|
9336 8062 | /// Data Plane sigv4 auth with long zone(20 chars)
|
9337 8063 | #[test]
|
9338 8064 | fn test_317() {
|
9339 8065 | let params = crate::config::endpoint::Params::builder()
|
9340 8066 | .region("us-west-2".to_string())
|
9341 8067 | .bucket("mybucket--test1-long1-zone-ab1--x-s3".to_string())
|
9342 8068 | .use_fips(false)
|
9343 8069 | .use_dual_stack(false)
|
9344 8070 | .accelerate(false)
|
9345 8071 | .use_s3_express_control_endpoint(false)
|
9346 8072 | .disable_s3_express_session_auth(true)
|
9347 8073 | .build()
|
9348 8074 | .expect("invalid params");
|
9349 8075 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9350 8076 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9351 8077 | let endpoint = endpoint
|
9352 8078 | .expect("Expected valid endpoint: https://mybucket--test1-long1-zone-ab1--x-s3.s3express-test1-long1-zone-ab1.us-west-2.amazonaws.com");
|
9353 8079 | assert_eq!(
|
9354 8080 | endpoint,
|
9355 8081 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9356 8082 | .url("https://mybucket--test1-long1-zone-ab1--x-s3.s3express-test1-long1-zone-ab1.us-west-2.amazonaws.com")
|
9357 - | .property(
|
9358 - | "authSchemes",
|
9359 - | vec![{
|
9360 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9361 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9362 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9363 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9364 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9365 - | out
|
9366 - | }
|
9367 - | .into()]
|
8083 + | .auth_scheme(
|
8084 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8085 + | .put("disableDoubleEncoding", true)
|
8086 + | .put("signingName", "s3express".to_string())
|
8087 + | .put("signingRegion", "us-west-2".to_string())
|
9368 8088 | )
|
9369 8089 | .property("backend", "S3Express".to_string())
|
9370 8090 | .build()
|
9371 8091 | );
|
9372 8092 | }
|
9373 8093 |
|
9374 8094 | /// Data Plane sigv4 auth with long zone(20 chars) with AP
|
9375 8095 | #[test]
|
9376 8096 | fn test_318() {
|
9377 8097 | let params = crate::config::endpoint::Params::builder()
|
9378 8098 | .region("us-west-2".to_string())
|
9379 8099 | .bucket("myaccesspoint--test1-long1-zone-ab1--xa-s3".to_string())
|
9380 8100 | .use_fips(false)
|
9381 8101 | .use_dual_stack(false)
|
9382 8102 | .accelerate(false)
|
9383 8103 | .use_s3_express_control_endpoint(false)
|
9384 8104 | .disable_s3_express_session_auth(true)
|
9385 8105 | .build()
|
9386 8106 | .expect("invalid params");
|
9387 8107 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9388 8108 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9389 8109 | let endpoint = endpoint.expect(
|
9390 8110 | "Expected valid endpoint: https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-test1-long1-zone-ab1.us-west-2.amazonaws.com",
|
9391 8111 | );
|
9392 8112 | assert_eq!(
|
9393 8113 | endpoint,
|
9394 8114 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9395 8115 | .url("https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-test1-long1-zone-ab1.us-west-2.amazonaws.com")
|
9396 - | .property(
|
9397 - | "authSchemes",
|
9398 - | vec![{
|
9399 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9400 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9401 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9402 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9403 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9404 - | out
|
9405 - | }
|
9406 - | .into()]
|
8116 + | .auth_scheme(
|
8117 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8118 + | .put("disableDoubleEncoding", true)
|
8119 + | .put("signingName", "s3express".to_string())
|
8120 + | .put("signingRegion", "us-west-2".to_string())
|
9407 8121 | )
|
9408 8122 | .property("backend", "S3Express".to_string())
|
9409 8123 | .build()
|
9410 8124 | );
|
9411 8125 | }
|
9412 8126 |
|
9413 8127 | /// Data Plane sigv4 auth with long AZ fips
|
9414 8128 | #[test]
|
9415 8129 | fn test_319() {
|
9416 8130 | let params = crate::config::endpoint::Params::builder()
|
9417 8131 | .region("us-west-2".to_string())
|
9418 8132 | .bucket("mybucket--test1-az1--x-s3".to_string())
|
9419 8133 | .use_fips(true)
|
9420 8134 | .use_dual_stack(false)
|
9421 8135 | .accelerate(false)
|
9422 8136 | .use_s3_express_control_endpoint(false)
|
9423 8137 | .disable_s3_express_session_auth(true)
|
9424 8138 | .build()
|
9425 8139 | .expect("invalid params");
|
9426 8140 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9427 8141 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9428 8142 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--test1-az1--x-s3.s3express-fips-test1-az1.us-west-2.amazonaws.com");
|
9429 8143 | assert_eq!(
|
9430 8144 | endpoint,
|
9431 8145 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9432 8146 | .url("https://mybucket--test1-az1--x-s3.s3express-fips-test1-az1.us-west-2.amazonaws.com")
|
9433 - | .property(
|
9434 - | "authSchemes",
|
9435 - | vec![{
|
9436 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9437 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9438 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9439 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9440 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9441 - | out
|
9442 - | }
|
9443 - | .into()]
|
8147 + | .auth_scheme(
|
8148 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8149 + | .put("disableDoubleEncoding", true)
|
8150 + | .put("signingName", "s3express".to_string())
|
8151 + | .put("signingRegion", "us-west-2".to_string())
|
9444 8152 | )
|
9445 8153 | .property("backend", "S3Express".to_string())
|
9446 8154 | .build()
|
9447 8155 | );
|
9448 8156 | }
|
9449 8157 |
|
9450 8158 | /// Data Plane sigv4 auth with long AZ fips with AP
|
9451 8159 | #[test]
|
9452 8160 | fn test_320() {
|
9453 8161 | let params = crate::config::endpoint::Params::builder()
|
9454 8162 | .region("us-west-2".to_string())
|
9455 8163 | .bucket("myaccesspoint--test1-az1--xa-s3".to_string())
|
9456 8164 | .use_fips(true)
|
9457 8165 | .use_dual_stack(false)
|
9458 8166 | .accelerate(false)
|
9459 8167 | .use_s3_express_control_endpoint(false)
|
9460 8168 | .disable_s3_express_session_auth(true)
|
9461 8169 | .build()
|
9462 8170 | .expect("invalid params");
|
9463 8171 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9464 8172 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9465 8173 | let endpoint =
|
9466 8174 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-az1--xa-s3.s3express-fips-test1-az1.us-west-2.amazonaws.com");
|
9467 8175 | assert_eq!(
|
9468 8176 | endpoint,
|
9469 8177 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9470 8178 | .url("https://myaccesspoint--test1-az1--xa-s3.s3express-fips-test1-az1.us-west-2.amazonaws.com")
|
9471 - | .property(
|
9472 - | "authSchemes",
|
9473 - | vec![{
|
9474 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9475 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9476 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9477 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9478 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9479 - | out
|
9480 - | }
|
9481 - | .into()]
|
8179 + | .auth_scheme(
|
8180 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8181 + | .put("disableDoubleEncoding", true)
|
8182 + | .put("signingName", "s3express".to_string())
|
8183 + | .put("signingRegion", "us-west-2".to_string())
|
9482 8184 | )
|
9483 8185 | .property("backend", "S3Express".to_string())
|
9484 8186 | .build()
|
9485 8187 | );
|
9486 8188 | }
|
9487 8189 |
|
9488 8190 | /// Data Plane sigv4 auth with medium zone (14 chars) fips
|
9489 8191 | #[test]
|
9490 8192 | fn test_321() {
|
9491 8193 | let params = crate::config::endpoint::Params::builder()
|
9492 8194 | .region("us-west-2".to_string())
|
9493 8195 | .bucket("mybucket--test1-zone-ab1--x-s3".to_string())
|
9494 8196 | .use_fips(true)
|
9495 8197 | .use_dual_stack(false)
|
9496 8198 | .accelerate(false)
|
9497 8199 | .use_s3_express_control_endpoint(false)
|
9498 8200 | .disable_s3_express_session_auth(true)
|
9499 8201 | .build()
|
9500 8202 | .expect("invalid params");
|
9501 8203 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9502 8204 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9503 8205 | let endpoint =
|
9504 8206 | endpoint.expect("Expected valid endpoint: https://mybucket--test1-zone-ab1--x-s3.s3express-fips-test1-zone-ab1.us-west-2.amazonaws.com");
|
9505 8207 | assert_eq!(
|
9506 8208 | endpoint,
|
9507 8209 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9508 8210 | .url("https://mybucket--test1-zone-ab1--x-s3.s3express-fips-test1-zone-ab1.us-west-2.amazonaws.com")
|
9509 - | .property(
|
9510 - | "authSchemes",
|
9511 - | vec![{
|
9512 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9513 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9514 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9515 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9516 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9517 - | out
|
9518 - | }
|
9519 - | .into()]
|
8211 + | .auth_scheme(
|
8212 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8213 + | .put("disableDoubleEncoding", true)
|
8214 + | .put("signingName", "s3express".to_string())
|
8215 + | .put("signingRegion", "us-west-2".to_string())
|
9520 8216 | )
|
9521 8217 | .property("backend", "S3Express".to_string())
|
9522 8218 | .build()
|
9523 8219 | );
|
9524 8220 | }
|
9525 8221 |
|
9526 8222 | /// Data Plane sigv4 auth with medium zone (14 chars) fips with AP
|
9527 8223 | #[test]
|
9528 8224 | fn test_322() {
|
9529 8225 | let params = crate::config::endpoint::Params::builder()
|
9530 8226 | .region("us-west-2".to_string())
|
9531 8227 | .bucket("myaccesspoint--test1-zone-ab1--xa-s3".to_string())
|
9532 8228 | .use_fips(true)
|
9533 8229 | .use_dual_stack(false)
|
9534 8230 | .accelerate(false)
|
9535 8231 | .use_s3_express_control_endpoint(false)
|
9536 8232 | .disable_s3_express_session_auth(true)
|
9537 8233 | .build()
|
9538 8234 | .expect("invalid params");
|
9539 8235 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9540 8236 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9541 8237 | let endpoint = endpoint
|
9542 8238 | .expect("Expected valid endpoint: https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-fips-test1-zone-ab1.us-west-2.amazonaws.com");
|
9543 8239 | assert_eq!(
|
9544 8240 | endpoint,
|
9545 8241 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9546 8242 | .url("https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-fips-test1-zone-ab1.us-west-2.amazonaws.com")
|
9547 - | .property(
|
9548 - | "authSchemes",
|
9549 - | vec![{
|
9550 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9551 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9552 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9553 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9554 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9555 - | out
|
9556 - | }
|
9557 - | .into()]
|
8243 + | .auth_scheme(
|
8244 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8245 + | .put("disableDoubleEncoding", true)
|
8246 + | .put("signingName", "s3express".to_string())
|
8247 + | .put("signingRegion", "us-west-2".to_string())
|
9558 8248 | )
|
9559 8249 | .property("backend", "S3Express".to_string())
|
9560 8250 | .build()
|
9561 8251 | );
|
9562 8252 | }
|
9563 8253 |
|
9564 8254 | /// Data Plane sigv4 auth with long zone (20 chars) fips
|
9565 8255 | #[test]
|
9566 8256 | fn test_323() {
|
9567 8257 | let params = crate::config::endpoint::Params::builder()
|
9568 8258 | .region("us-west-2".to_string())
|
9569 8259 | .bucket("mybucket--test1-long1-zone-ab1--x-s3".to_string())
|
9570 8260 | .use_fips(true)
|
9571 8261 | .use_dual_stack(false)
|
9572 8262 | .accelerate(false)
|
9573 8263 | .use_s3_express_control_endpoint(false)
|
9574 8264 | .disable_s3_express_session_auth(true)
|
9575 8265 | .build()
|
9576 8266 | .expect("invalid params");
|
9577 8267 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9578 8268 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9579 8269 | let endpoint = endpoint.expect(
|
9580 8270 | "Expected valid endpoint: https://mybucket--test1-long1-zone-ab1--x-s3.s3express-fips-test1-long1-zone-ab1.us-west-2.amazonaws.com",
|
9581 8271 | );
|
9582 8272 | assert_eq!(
|
9583 8273 | endpoint,
|
9584 8274 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9585 8275 | .url("https://mybucket--test1-long1-zone-ab1--x-s3.s3express-fips-test1-long1-zone-ab1.us-west-2.amazonaws.com")
|
9586 - | .property(
|
9587 - | "authSchemes",
|
9588 - | vec![{
|
9589 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9590 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9591 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9592 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9593 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9594 - | out
|
9595 - | }
|
9596 - | .into()]
|
8276 + | .auth_scheme(
|
8277 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8278 + | .put("disableDoubleEncoding", true)
|
8279 + | .put("signingName", "s3express".to_string())
|
8280 + | .put("signingRegion", "us-west-2".to_string())
|
9597 8281 | )
|
9598 8282 | .property("backend", "S3Express".to_string())
|
9599 8283 | .build()
|
9600 8284 | );
|
9601 8285 | }
|
9602 8286 |
|
9603 8287 | /// Data Plane sigv4 auth with long zone (20 chars) fips with AP
|
9604 8288 | #[test]
|
9605 8289 | fn test_324() {
|
9606 8290 | let params = crate::config::endpoint::Params::builder()
|
9607 8291 | .region("us-west-2".to_string())
|
9608 8292 | .bucket("myaccesspoint--test1-long1-zone-ab1--xa-s3".to_string())
|
9609 8293 | .use_fips(true)
|
9610 8294 | .use_dual_stack(false)
|
9611 8295 | .accelerate(false)
|
9612 8296 | .use_s3_express_control_endpoint(false)
|
9613 8297 | .disable_s3_express_session_auth(true)
|
9614 8298 | .build()
|
9615 8299 | .expect("invalid params");
|
9616 8300 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9617 8301 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9618 8302 | let endpoint = endpoint.expect(
|
9619 8303 | "Expected valid endpoint: https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-fips-test1-long1-zone-ab1.us-west-2.amazonaws.com",
|
9620 8304 | );
|
9621 8305 | assert_eq!(
|
9622 8306 | endpoint,
|
9623 8307 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9624 8308 | .url("https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-fips-test1-long1-zone-ab1.us-west-2.amazonaws.com")
|
9625 - | .property(
|
9626 - | "authSchemes",
|
9627 - | vec![{
|
9628 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9629 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9630 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9631 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9632 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9633 - | out
|
9634 - | }
|
9635 - | .into()]
|
8309 + | .auth_scheme(
|
8310 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8311 + | .put("disableDoubleEncoding", true)
|
8312 + | .put("signingName", "s3express".to_string())
|
8313 + | .put("signingRegion", "us-west-2".to_string())
|
9636 8314 | )
|
9637 8315 | .property("backend", "S3Express".to_string())
|
9638 8316 | .build()
|
9639 8317 | );
|
9640 8318 | }
|
9641 8319 |
|
9642 8320 | /// Control Plane host override
|
9643 8321 | #[test]
|
9644 8322 | fn test_325() {
|
9645 8323 | let params = crate::config::endpoint::Params::builder()
|
9646 8324 | .region("us-west-2".to_string())
|
9647 8325 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
9648 8326 | .use_fips(false)
|
9649 8327 | .use_dual_stack(false)
|
9650 8328 | .accelerate(false)
|
9651 8329 | .use_s3_express_control_endpoint(true)
|
9652 8330 | .disable_s3_express_session_auth(true)
|
9653 8331 | .endpoint("https://custom.com".to_string())
|
9654 8332 | .build()
|
9655 8333 | .expect("invalid params");
|
9656 8334 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9657 8335 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9658 8336 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az1--x-s3.custom.com");
|
9659 8337 | assert_eq!(
|
9660 8338 | endpoint,
|
9661 8339 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9662 8340 | .url("https://mybucket--usw2-az1--x-s3.custom.com")
|
9663 - | .property(
|
9664 - | "authSchemes",
|
9665 - | vec![{
|
9666 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9667 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9668 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9669 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9670 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9671 - | out
|
9672 - | }
|
9673 - | .into()]
|
8341 + | .auth_scheme(
|
8342 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8343 + | .put("disableDoubleEncoding", true)
|
8344 + | .put("signingName", "s3express".to_string())
|
8345 + | .put("signingRegion", "us-west-2".to_string())
|
9674 8346 | )
|
9675 8347 | .property("backend", "S3Express".to_string())
|
9676 8348 | .build()
|
9677 8349 | );
|
9678 8350 | }
|
9679 8351 |
|
9680 8352 | /// Control Plane host override with AP
|
9681 8353 | #[test]
|
9682 8354 | fn test_326() {
|
9683 8355 | let params = crate::config::endpoint::Params::builder()
|
9684 8356 | .region("us-west-2".to_string())
|
9685 8357 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
9686 8358 | .use_fips(false)
|
9687 8359 | .use_dual_stack(false)
|
9688 8360 | .accelerate(false)
|
9689 8361 | .use_s3_express_control_endpoint(true)
|
9690 8362 | .disable_s3_express_session_auth(true)
|
9691 8363 | .endpoint("https://custom.com".to_string())
|
9692 8364 | .build()
|
9693 8365 | .expect("invalid params");
|
9694 8366 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9695 8367 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9696 8368 | let endpoint = endpoint.expect("Expected valid endpoint: https://myaccesspoint--usw2-az1--xa-s3.custom.com");
|
9697 8369 | assert_eq!(
|
9698 8370 | endpoint,
|
9699 8371 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9700 8372 | .url("https://myaccesspoint--usw2-az1--xa-s3.custom.com")
|
9701 - | .property(
|
9702 - | "authSchemes",
|
9703 - | vec![{
|
9704 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9705 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9706 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9707 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9708 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9709 - | out
|
9710 - | }
|
9711 - | .into()]
|
8373 + | .auth_scheme(
|
8374 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8375 + | .put("disableDoubleEncoding", true)
|
8376 + | .put("signingName", "s3express".to_string())
|
8377 + | .put("signingRegion", "us-west-2".to_string())
|
9712 8378 | )
|
9713 8379 | .property("backend", "S3Express".to_string())
|
9714 8380 | .build()
|
9715 8381 | );
|
9716 8382 | }
|
9717 8383 |
|
9718 8384 | /// Control Plane host override no bucket
|
9719 8385 | #[test]
|
9720 8386 | fn test_327() {
|
9721 8387 | let params = crate::config::endpoint::Params::builder()
|
9722 8388 | .region("us-west-2".to_string())
|
9723 8389 | .use_fips(false)
|
9724 8390 | .use_dual_stack(false)
|
9725 8391 | .accelerate(false)
|
9726 8392 | .use_s3_express_control_endpoint(true)
|
9727 8393 | .disable_s3_express_session_auth(true)
|
9728 8394 | .endpoint("https://custom.com".to_string())
|
9729 8395 | .build()
|
9730 8396 | .expect("invalid params");
|
9731 8397 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9732 8398 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9733 8399 | let endpoint = endpoint.expect("Expected valid endpoint: https://custom.com");
|
9734 8400 | assert_eq!(
|
9735 8401 | endpoint,
|
9736 8402 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9737 8403 | .url("https://custom.com")
|
9738 - | .property(
|
9739 - | "authSchemes",
|
9740 - | vec![{
|
9741 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9742 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9743 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9744 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9745 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9746 - | out
|
9747 - | }
|
9748 - | .into()]
|
8404 + | .auth_scheme(
|
8405 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8406 + | .put("disableDoubleEncoding", true)
|
8407 + | .put("signingName", "s3express".to_string())
|
8408 + | .put("signingRegion", "us-west-2".to_string())
|
9749 8409 | )
|
9750 8410 | .property("backend", "S3Express".to_string())
|
9751 8411 | .build()
|
9752 8412 | );
|
9753 8413 | }
|
9754 8414 |
|
9755 8415 | /// Data plane host override non virtual session auth
|
9756 8416 | #[test]
|
9757 8417 | fn test_328() {
|
9758 8418 | let params = crate::config::endpoint::Params::builder()
|
9759 8419 | .region("us-west-2".to_string())
|
9760 8420 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
9761 8421 | .use_fips(false)
|
9762 8422 | .use_dual_stack(false)
|
9763 8423 | .accelerate(false)
|
9764 8424 | .endpoint("https://10.0.0.1".to_string())
|
9765 8425 | .build()
|
9766 8426 | .expect("invalid params");
|
9767 8427 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9768 8428 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9769 8429 | let endpoint = endpoint.expect("Expected valid endpoint: https://10.0.0.1/mybucket--usw2-az1--x-s3");
|
9770 8430 | assert_eq!(
|
9771 8431 | endpoint,
|
9772 8432 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9773 8433 | .url("https://10.0.0.1/mybucket--usw2-az1--x-s3")
|
9774 - | .property(
|
9775 - | "authSchemes",
|
9776 - | vec![{
|
9777 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9778 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
9779 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9780 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9781 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9782 - | out
|
9783 - | }
|
9784 - | .into()]
|
8434 + | .auth_scheme(
|
8435 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
8436 + | .put("disableDoubleEncoding", true)
|
8437 + | .put("signingName", "s3express".to_string())
|
8438 + | .put("signingRegion", "us-west-2".to_string())
|
9785 8439 | )
|
9786 8440 | .property("backend", "S3Express".to_string())
|
9787 8441 | .build()
|
9788 8442 | );
|
9789 8443 | }
|
9790 8444 |
|
9791 8445 | /// Data plane host override non virtual session auth with AP
|
9792 8446 | #[test]
|
9793 8447 | fn test_329() {
|
9794 8448 | let params = crate::config::endpoint::Params::builder()
|
9795 8449 | .region("us-west-2".to_string())
|
9796 8450 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
9797 8451 | .use_fips(false)
|
9798 8452 | .use_dual_stack(false)
|
9799 8453 | .accelerate(false)
|
9800 8454 | .endpoint("https://10.0.0.1".to_string())
|
9801 8455 | .build()
|
9802 8456 | .expect("invalid params");
|
9803 8457 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9804 8458 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9805 8459 | let endpoint = endpoint.expect("Expected valid endpoint: https://10.0.0.1/myaccesspoint--usw2-az1--xa-s3");
|
9806 8460 | assert_eq!(
|
9807 8461 | endpoint,
|
9808 8462 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9809 8463 | .url("https://10.0.0.1/myaccesspoint--usw2-az1--xa-s3")
|
9810 - | .property(
|
9811 - | "authSchemes",
|
9812 - | vec![{
|
9813 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9814 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
9815 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9816 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9817 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9818 - | out
|
9819 - | }
|
9820 - | .into()]
|
8464 + | .auth_scheme(
|
8465 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
8466 + | .put("disableDoubleEncoding", true)
|
8467 + | .put("signingName", "s3express".to_string())
|
8468 + | .put("signingRegion", "us-west-2".to_string())
|
9821 8469 | )
|
9822 8470 | .property("backend", "S3Express".to_string())
|
9823 8471 | .build()
|
9824 8472 | );
|
9825 8473 | }
|
9826 8474 |
|
9827 8475 | /// Control Plane host override ip
|
9828 8476 | #[test]
|
9829 8477 | fn test_330() {
|
9830 8478 | let params = crate::config::endpoint::Params::builder()
|
9831 8479 | .region("us-west-2".to_string())
|
9832 8480 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
9833 8481 | .use_fips(false)
|
9834 8482 | .use_dual_stack(false)
|
9835 8483 | .accelerate(false)
|
9836 8484 | .use_s3_express_control_endpoint(true)
|
9837 8485 | .disable_s3_express_session_auth(true)
|
9838 8486 | .endpoint("https://10.0.0.1".to_string())
|
9839 8487 | .build()
|
9840 8488 | .expect("invalid params");
|
9841 8489 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9842 8490 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9843 8491 | let endpoint = endpoint.expect("Expected valid endpoint: https://10.0.0.1/mybucket--usw2-az1--x-s3");
|
9844 8492 | assert_eq!(
|
9845 8493 | endpoint,
|
9846 8494 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9847 8495 | .url("https://10.0.0.1/mybucket--usw2-az1--x-s3")
|
9848 - | .property(
|
9849 - | "authSchemes",
|
9850 - | vec![{
|
9851 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9852 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9853 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9854 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9855 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9856 - | out
|
9857 - | }
|
9858 - | .into()]
|
8496 + | .auth_scheme(
|
8497 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8498 + | .put("disableDoubleEncoding", true)
|
8499 + | .put("signingName", "s3express".to_string())
|
8500 + | .put("signingRegion", "us-west-2".to_string())
|
9859 8501 | )
|
9860 8502 | .property("backend", "S3Express".to_string())
|
9861 8503 | .build()
|
9862 8504 | );
|
9863 8505 | }
|
9864 8506 |
|
9865 8507 | /// Control Plane host override ip with AP
|
9866 8508 | #[test]
|
9867 8509 | fn test_331() {
|
9868 8510 | let params = crate::config::endpoint::Params::builder()
|
9869 8511 | .region("us-west-2".to_string())
|
9870 8512 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
9871 8513 | .use_fips(false)
|
9872 8514 | .use_dual_stack(false)
|
9873 8515 | .accelerate(false)
|
9874 8516 | .use_s3_express_control_endpoint(true)
|
9875 8517 | .disable_s3_express_session_auth(true)
|
9876 8518 | .endpoint("https://10.0.0.1".to_string())
|
9877 8519 | .build()
|
9878 8520 | .expect("invalid params");
|
9879 8521 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9880 8522 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9881 8523 | let endpoint = endpoint.expect("Expected valid endpoint: https://10.0.0.1/myaccesspoint--usw2-az1--xa-s3");
|
9882 8524 | assert_eq!(
|
9883 8525 | endpoint,
|
9884 8526 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9885 8527 | .url("https://10.0.0.1/myaccesspoint--usw2-az1--xa-s3")
|
9886 - | .property(
|
9887 - | "authSchemes",
|
9888 - | vec![{
|
9889 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9890 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
9891 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9892 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9893 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9894 - | out
|
9895 - | }
|
9896 - | .into()]
|
8528 + | .auth_scheme(
|
8529 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8530 + | .put("disableDoubleEncoding", true)
|
8531 + | .put("signingName", "s3express".to_string())
|
8532 + | .put("signingRegion", "us-west-2".to_string())
|
9897 8533 | )
|
9898 8534 | .property("backend", "S3Express".to_string())
|
9899 8535 | .build()
|
9900 8536 | );
|
9901 8537 | }
|
9902 8538 |
|
9903 8539 | /// Data plane host override
|
9904 8540 | #[test]
|
9905 8541 | fn test_332() {
|
9906 8542 | let params = crate::config::endpoint::Params::builder()
|
9907 8543 | .region("us-west-2".to_string())
|
9908 8544 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
9909 8545 | .use_fips(false)
|
9910 8546 | .use_dual_stack(false)
|
9911 8547 | .accelerate(false)
|
9912 8548 | .endpoint("https://custom.com".to_string())
|
9913 8549 | .build()
|
9914 8550 | .expect("invalid params");
|
9915 8551 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9916 8552 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9917 8553 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az1--x-s3.custom.com");
|
9918 8554 | assert_eq!(
|
9919 8555 | endpoint,
|
9920 8556 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9921 8557 | .url("https://mybucket--usw2-az1--x-s3.custom.com")
|
9922 - | .property(
|
9923 - | "authSchemes",
|
9924 - | vec![{
|
9925 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9926 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
9927 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9928 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9929 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9930 - | out
|
9931 - | }
|
9932 - | .into()]
|
8558 + | .auth_scheme(
|
8559 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
8560 + | .put("disableDoubleEncoding", true)
|
8561 + | .put("signingName", "s3express".to_string())
|
8562 + | .put("signingRegion", "us-west-2".to_string())
|
9933 8563 | )
|
9934 8564 | .property("backend", "S3Express".to_string())
|
9935 8565 | .build()
|
9936 8566 | );
|
9937 8567 | }
|
9938 8568 |
|
9939 8569 | /// Data plane host override with AP
|
9940 8570 | #[test]
|
9941 8571 | fn test_333() {
|
9942 8572 | let params = crate::config::endpoint::Params::builder()
|
9943 8573 | .region("us-west-2".to_string())
|
9944 8574 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
9945 8575 | .use_fips(false)
|
9946 8576 | .use_dual_stack(false)
|
9947 8577 | .accelerate(false)
|
9948 8578 | .endpoint("https://custom.com".to_string())
|
9949 8579 | .build()
|
9950 8580 | .expect("invalid params");
|
9951 8581 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
9952 8582 | let endpoint = resolver.resolve_endpoint(¶ms);
|
9953 8583 | let endpoint = endpoint.expect("Expected valid endpoint: https://myaccesspoint--usw2-az1--xa-s3.custom.com");
|
9954 8584 | assert_eq!(
|
9955 8585 | endpoint,
|
9956 8586 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
9957 8587 | .url("https://myaccesspoint--usw2-az1--xa-s3.custom.com")
|
9958 - | .property(
|
9959 - | "authSchemes",
|
9960 - | vec![{
|
9961 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
9962 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
9963 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
9964 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
9965 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
9966 - | out
|
9967 - | }
|
9968 - | .into()]
|
8588 + | .auth_scheme(
|
8589 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
8590 + | .put("disableDoubleEncoding", true)
|
8591 + | .put("signingName", "s3express".to_string())
|
8592 + | .put("signingRegion", "us-west-2".to_string())
|
9969 8593 | )
|
9970 8594 | .property("backend", "S3Express".to_string())
|
9971 8595 | .build()
|
9972 8596 | );
|
9973 8597 | }
|
9974 8598 |
|
9975 8599 | /// bad format error
|
9976 8600 | #[test]
|
9977 8601 | fn test_334() {
|
9978 8602 | let params = crate::config::endpoint::Params::builder()
|
10211 8835 | .disable_s3_express_session_auth(false)
|
10212 8836 | .build()
|
10213 8837 | .expect("invalid params");
|
10214 8838 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10215 8839 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10216 8840 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3express-control.dualstack.us-east-1.amazonaws.com");
|
10217 8841 | assert_eq!(
|
10218 8842 | endpoint,
|
10219 8843 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10220 8844 | .url("https://s3express-control.dualstack.us-east-1.amazonaws.com")
|
10221 - | .property(
|
10222 - | "authSchemes",
|
10223 - | vec![{
|
10224 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10225 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10226 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10227 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
10228 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10229 - | out
|
10230 - | }
|
10231 - | .into()]
|
8845 + | .auth_scheme(
|
8846 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8847 + | .put("disableDoubleEncoding", true)
|
8848 + | .put("signingName", "s3express".to_string())
|
8849 + | .put("signingRegion", "us-east-1".to_string())
|
10232 8850 | )
|
10233 8851 | .property("backend", "S3Express".to_string())
|
10234 8852 | .build()
|
10235 8853 | );
|
10236 8854 | }
|
10237 8855 |
|
10238 8856 | /// Control plane without bucket, fips and dualstack
|
10239 8857 | #[test]
|
10240 8858 | fn test_347() {
|
10241 8859 | let params = crate::config::endpoint::Params::builder()
|
10242 8860 | .region("us-east-1".to_string())
|
10243 8861 | .use_fips(true)
|
10244 8862 | .use_dual_stack(true)
|
10245 8863 | .accelerate(false)
|
10246 8864 | .use_s3_express_control_endpoint(true)
|
10247 8865 | .disable_s3_express_session_auth(false)
|
10248 8866 | .build()
|
10249 8867 | .expect("invalid params");
|
10250 8868 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10251 8869 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10252 8870 | let endpoint = endpoint.expect("Expected valid endpoint: https://s3express-control-fips.dualstack.us-east-1.amazonaws.com");
|
10253 8871 | assert_eq!(
|
10254 8872 | endpoint,
|
10255 8873 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10256 8874 | .url("https://s3express-control-fips.dualstack.us-east-1.amazonaws.com")
|
10257 - | .property(
|
10258 - | "authSchemes",
|
10259 - | vec![{
|
10260 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10261 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10262 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10263 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
10264 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10265 - | out
|
10266 - | }
|
10267 - | .into()]
|
8875 + | .auth_scheme(
|
8876 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8877 + | .put("disableDoubleEncoding", true)
|
8878 + | .put("signingName", "s3express".to_string())
|
8879 + | .put("signingRegion", "us-east-1".to_string())
|
10268 8880 | )
|
10269 8881 | .property("backend", "S3Express".to_string())
|
10270 8882 | .build()
|
10271 8883 | );
|
10272 8884 | }
|
10273 8885 |
|
10274 8886 | /// Data Plane with short AZ and dualstack
|
10275 8887 | #[test]
|
10276 8888 | fn test_348() {
|
10277 8889 | let params = crate::config::endpoint::Params::builder()
|
10278 8890 | .region("us-west-2".to_string())
|
10279 8891 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
10280 8892 | .use_fips(false)
|
10281 8893 | .use_dual_stack(true)
|
10282 8894 | .accelerate(false)
|
10283 8895 | .use_s3_express_control_endpoint(false)
|
10284 8896 | .build()
|
10285 8897 | .expect("invalid params");
|
10286 8898 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10287 8899 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10288 8900 | let endpoint =
|
10289 8901 | endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az1--x-s3.s3express-usw2-az1.dualstack.us-west-2.amazonaws.com");
|
10290 8902 | assert_eq!(
|
10291 8903 | endpoint,
|
10292 8904 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10293 8905 | .url("https://mybucket--usw2-az1--x-s3.s3express-usw2-az1.dualstack.us-west-2.amazonaws.com")
|
10294 - | .property(
|
10295 - | "authSchemes",
|
10296 - | vec![{
|
10297 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10298 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10299 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10300 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10301 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10302 - | out
|
10303 - | }
|
10304 - | .into()]
|
8906 + | .auth_scheme(
|
8907 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
8908 + | .put("disableDoubleEncoding", true)
|
8909 + | .put("signingName", "s3express".to_string())
|
8910 + | .put("signingRegion", "us-west-2".to_string())
|
10305 8911 | )
|
10306 8912 | .property("backend", "S3Express".to_string())
|
10307 8913 | .build()
|
10308 8914 | );
|
10309 8915 | }
|
10310 8916 |
|
10311 8917 | /// Data Plane with short AZ and FIPS with dualstack
|
10312 8918 | #[test]
|
10313 8919 | fn test_349() {
|
10314 8920 | let params = crate::config::endpoint::Params::builder()
|
10315 8921 | .region("us-west-2".to_string())
|
10316 8922 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
10317 8923 | .use_fips(true)
|
10318 8924 | .use_dual_stack(true)
|
10319 8925 | .accelerate(false)
|
10320 8926 | .use_s3_express_control_endpoint(false)
|
10321 8927 | .build()
|
10322 8928 | .expect("invalid params");
|
10323 8929 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10324 8930 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10325 8931 | let endpoint =
|
10326 8932 | endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az1--x-s3.s3express-fips-usw2-az1.dualstack.us-west-2.amazonaws.com");
|
10327 8933 | assert_eq!(
|
10328 8934 | endpoint,
|
10329 8935 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10330 8936 | .url("https://mybucket--usw2-az1--x-s3.s3express-fips-usw2-az1.dualstack.us-west-2.amazonaws.com")
|
10331 - | .property(
|
10332 - | "authSchemes",
|
10333 - | vec![{
|
10334 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10335 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10336 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10337 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10338 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10339 - | out
|
10340 - | }
|
10341 - | .into()]
|
8937 + | .auth_scheme(
|
8938 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
8939 + | .put("disableDoubleEncoding", true)
|
8940 + | .put("signingName", "s3express".to_string())
|
8941 + | .put("signingRegion", "us-west-2".to_string())
|
10342 8942 | )
|
10343 8943 | .property("backend", "S3Express".to_string())
|
10344 8944 | .build()
|
10345 8945 | );
|
10346 8946 | }
|
10347 8947 |
|
10348 8948 | /// Data Plane sigv4 auth with short AZ and dualstack
|
10349 8949 | #[test]
|
10350 8950 | fn test_350() {
|
10351 8951 | let params = crate::config::endpoint::Params::builder()
|
10352 8952 | .region("us-west-2".to_string())
|
10353 8953 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
10354 8954 | .use_fips(false)
|
10355 8955 | .use_dual_stack(true)
|
10356 8956 | .accelerate(false)
|
10357 8957 | .disable_s3_express_session_auth(true)
|
10358 8958 | .build()
|
10359 8959 | .expect("invalid params");
|
10360 8960 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10361 8961 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10362 8962 | let endpoint =
|
10363 8963 | endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az1--x-s3.s3express-usw2-az1.dualstack.us-west-2.amazonaws.com");
|
10364 8964 | assert_eq!(
|
10365 8965 | endpoint,
|
10366 8966 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10367 8967 | .url("https://mybucket--usw2-az1--x-s3.s3express-usw2-az1.dualstack.us-west-2.amazonaws.com")
|
10368 - | .property(
|
10369 - | "authSchemes",
|
10370 - | vec![{
|
10371 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10372 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10373 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10374 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10375 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10376 - | out
|
10377 - | }
|
10378 - | .into()]
|
8968 + | .auth_scheme(
|
8969 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
8970 + | .put("disableDoubleEncoding", true)
|
8971 + | .put("signingName", "s3express".to_string())
|
8972 + | .put("signingRegion", "us-west-2".to_string())
|
10379 8973 | )
|
10380 8974 | .property("backend", "S3Express".to_string())
|
10381 8975 | .build()
|
10382 8976 | );
|
10383 8977 | }
|
10384 8978 |
|
10385 8979 | /// Data Plane sigv4 auth with short AZ and FIPS with dualstack
|
10386 8980 | #[test]
|
10387 8981 | fn test_351() {
|
10388 8982 | let params = crate::config::endpoint::Params::builder()
|
10389 8983 | .region("us-west-2".to_string())
|
10390 8984 | .bucket("mybucket--usw2-az1--x-s3".to_string())
|
10391 8985 | .use_fips(true)
|
10392 8986 | .use_dual_stack(true)
|
10393 8987 | .accelerate(false)
|
10394 8988 | .disable_s3_express_session_auth(true)
|
10395 8989 | .build()
|
10396 8990 | .expect("invalid params");
|
10397 8991 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10398 8992 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10399 8993 | let endpoint =
|
10400 8994 | endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az1--x-s3.s3express-fips-usw2-az1.dualstack.us-west-2.amazonaws.com");
|
10401 8995 | assert_eq!(
|
10402 8996 | endpoint,
|
10403 8997 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10404 8998 | .url("https://mybucket--usw2-az1--x-s3.s3express-fips-usw2-az1.dualstack.us-west-2.amazonaws.com")
|
10405 - | .property(
|
10406 - | "authSchemes",
|
10407 - | vec![{
|
10408 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10409 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10410 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10411 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10412 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10413 - | out
|
10414 - | }
|
10415 - | .into()]
|
8999 + | .auth_scheme(
|
9000 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9001 + | .put("disableDoubleEncoding", true)
|
9002 + | .put("signingName", "s3express".to_string())
|
9003 + | .put("signingRegion", "us-west-2".to_string())
|
10416 9004 | )
|
10417 9005 | .property("backend", "S3Express".to_string())
|
10418 9006 | .build()
|
10419 9007 | );
|
10420 9008 | }
|
10421 9009 |
|
10422 9010 | /// Data Plane with zone and dualstack
|
10423 9011 | #[test]
|
10424 9012 | fn test_352() {
|
10425 9013 | let params = crate::config::endpoint::Params::builder()
|
10426 9014 | .region("us-west-2".to_string())
|
10427 9015 | .bucket("mybucket--usw2-az12--x-s3".to_string())
|
10428 9016 | .use_fips(false)
|
10429 9017 | .use_dual_stack(true)
|
10430 9018 | .accelerate(false)
|
10431 9019 | .use_s3_express_control_endpoint(false)
|
10432 9020 | .build()
|
10433 9021 | .expect("invalid params");
|
10434 9022 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10435 9023 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10436 9024 | let endpoint =
|
10437 9025 | endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az12--x-s3.s3express-usw2-az12.dualstack.us-west-2.amazonaws.com");
|
10438 9026 | assert_eq!(
|
10439 9027 | endpoint,
|
10440 9028 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10441 9029 | .url("https://mybucket--usw2-az12--x-s3.s3express-usw2-az12.dualstack.us-west-2.amazonaws.com")
|
10442 - | .property(
|
10443 - | "authSchemes",
|
10444 - | vec![{
|
10445 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10446 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10447 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10448 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10449 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10450 - | out
|
10451 - | }
|
10452 - | .into()]
|
9030 + | .auth_scheme(
|
9031 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9032 + | .put("disableDoubleEncoding", true)
|
9033 + | .put("signingName", "s3express".to_string())
|
9034 + | .put("signingRegion", "us-west-2".to_string())
|
10453 9035 | )
|
10454 9036 | .property("backend", "S3Express".to_string())
|
10455 9037 | .build()
|
10456 9038 | );
|
10457 9039 | }
|
10458 9040 |
|
10459 9041 | /// Data Plane with zone and FIPS with dualstack
|
10460 9042 | #[test]
|
10461 9043 | fn test_353() {
|
10462 9044 | let params = crate::config::endpoint::Params::builder()
|
10463 9045 | .region("us-west-2".to_string())
|
10464 9046 | .bucket("mybucket--usw2-az12--x-s3".to_string())
|
10465 9047 | .use_fips(true)
|
10466 9048 | .use_dual_stack(true)
|
10467 9049 | .accelerate(false)
|
10468 9050 | .use_s3_express_control_endpoint(false)
|
10469 9051 | .build()
|
10470 9052 | .expect("invalid params");
|
10471 9053 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10472 9054 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10473 9055 | let endpoint =
|
10474 9056 | endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az12--x-s3.s3express-fips-usw2-az12.dualstack.us-west-2.amazonaws.com");
|
10475 9057 | assert_eq!(
|
10476 9058 | endpoint,
|
10477 9059 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10478 9060 | .url("https://mybucket--usw2-az12--x-s3.s3express-fips-usw2-az12.dualstack.us-west-2.amazonaws.com")
|
10479 - | .property(
|
10480 - | "authSchemes",
|
10481 - | vec![{
|
10482 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10483 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10484 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10485 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10486 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10487 - | out
|
10488 - | }
|
10489 - | .into()]
|
9061 + | .auth_scheme(
|
9062 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9063 + | .put("disableDoubleEncoding", true)
|
9064 + | .put("signingName", "s3express".to_string())
|
9065 + | .put("signingRegion", "us-west-2".to_string())
|
10490 9066 | )
|
10491 9067 | .property("backend", "S3Express".to_string())
|
10492 9068 | .build()
|
10493 9069 | );
|
10494 9070 | }
|
10495 9071 |
|
10496 9072 | /// Data Plane sigv4 auth with zone and dualstack
|
10497 9073 | #[test]
|
10498 9074 | fn test_354() {
|
10499 9075 | let params = crate::config::endpoint::Params::builder()
|
10500 9076 | .region("us-west-2".to_string())
|
10501 9077 | .bucket("mybucket--usw2-az12--x-s3".to_string())
|
10502 9078 | .use_fips(false)
|
10503 9079 | .use_dual_stack(true)
|
10504 9080 | .accelerate(false)
|
10505 9081 | .disable_s3_express_session_auth(true)
|
10506 9082 | .build()
|
10507 9083 | .expect("invalid params");
|
10508 9084 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10509 9085 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10510 9086 | let endpoint =
|
10511 9087 | endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az12--x-s3.s3express-usw2-az12.dualstack.us-west-2.amazonaws.com");
|
10512 9088 | assert_eq!(
|
10513 9089 | endpoint,
|
10514 9090 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10515 9091 | .url("https://mybucket--usw2-az12--x-s3.s3express-usw2-az12.dualstack.us-west-2.amazonaws.com")
|
10516 - | .property(
|
10517 - | "authSchemes",
|
10518 - | vec![{
|
10519 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10520 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10521 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10522 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10523 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10524 - | out
|
10525 - | }
|
10526 - | .into()]
|
9092 + | .auth_scheme(
|
9093 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9094 + | .put("disableDoubleEncoding", true)
|
9095 + | .put("signingName", "s3express".to_string())
|
9096 + | .put("signingRegion", "us-west-2".to_string())
|
10527 9097 | )
|
10528 9098 | .property("backend", "S3Express".to_string())
|
10529 9099 | .build()
|
10530 9100 | );
|
10531 9101 | }
|
10532 9102 |
|
10533 9103 | /// Data Plane sigv4 auth with 9-char zone and FIPS with dualstack
|
10534 9104 | #[test]
|
10535 9105 | fn test_355() {
|
10536 9106 | let params = crate::config::endpoint::Params::builder()
|
10537 9107 | .region("us-west-2".to_string())
|
10538 9108 | .bucket("mybucket--usw2-az12--x-s3".to_string())
|
10539 9109 | .use_fips(true)
|
10540 9110 | .use_dual_stack(true)
|
10541 9111 | .accelerate(false)
|
10542 9112 | .disable_s3_express_session_auth(true)
|
10543 9113 | .build()
|
10544 9114 | .expect("invalid params");
|
10545 9115 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10546 9116 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10547 9117 | let endpoint =
|
10548 9118 | endpoint.expect("Expected valid endpoint: https://mybucket--usw2-az12--x-s3.s3express-fips-usw2-az12.dualstack.us-west-2.amazonaws.com");
|
10549 9119 | assert_eq!(
|
10550 9120 | endpoint,
|
10551 9121 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10552 9122 | .url("https://mybucket--usw2-az12--x-s3.s3express-fips-usw2-az12.dualstack.us-west-2.amazonaws.com")
|
10553 - | .property(
|
10554 - | "authSchemes",
|
10555 - | vec![{
|
10556 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10557 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10558 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10559 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10560 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10561 - | out
|
10562 - | }
|
10563 - | .into()]
|
9123 + | .auth_scheme(
|
9124 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9125 + | .put("disableDoubleEncoding", true)
|
9126 + | .put("signingName", "s3express".to_string())
|
9127 + | .put("signingRegion", "us-west-2".to_string())
|
10564 9128 | )
|
10565 9129 | .property("backend", "S3Express".to_string())
|
10566 9130 | .build()
|
10567 9131 | );
|
10568 9132 | }
|
10569 9133 |
|
10570 9134 | /// Data Plane with 13-char zone and dualstack
|
10571 9135 | #[test]
|
10572 9136 | fn test_356() {
|
10573 9137 | let params = crate::config::endpoint::Params::builder()
|
10574 9138 | .region("us-west-2".to_string())
|
10575 9139 | .bucket("mybucket--test-zone-ab1--x-s3".to_string())
|
10576 9140 | .use_fips(false)
|
10577 9141 | .use_dual_stack(true)
|
10578 9142 | .accelerate(false)
|
10579 9143 | .use_s3_express_control_endpoint(false)
|
10580 9144 | .build()
|
10581 9145 | .expect("invalid params");
|
10582 9146 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10583 9147 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10584 9148 | let endpoint = endpoint
|
10585 9149 | .expect("Expected valid endpoint: https://mybucket--test-zone-ab1--x-s3.s3express-test-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
10586 9150 | assert_eq!(
|
10587 9151 | endpoint,
|
10588 9152 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10589 9153 | .url("https://mybucket--test-zone-ab1--x-s3.s3express-test-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10590 - | .property(
|
10591 - | "authSchemes",
|
10592 - | vec![{
|
10593 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10594 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10595 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10596 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10597 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10598 - | out
|
10599 - | }
|
10600 - | .into()]
|
9154 + | .auth_scheme(
|
9155 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9156 + | .put("disableDoubleEncoding", true)
|
9157 + | .put("signingName", "s3express".to_string())
|
9158 + | .put("signingRegion", "us-west-2".to_string())
|
10601 9159 | )
|
10602 9160 | .property("backend", "S3Express".to_string())
|
10603 9161 | .build()
|
10604 9162 | );
|
10605 9163 | }
|
10606 9164 |
|
10607 9165 | /// Data Plane with 13-char zone and FIPS with dualstack
|
10608 9166 | #[test]
|
10609 9167 | fn test_357() {
|
10610 9168 | let params = crate::config::endpoint::Params::builder()
|
10611 9169 | .region("us-west-2".to_string())
|
10612 9170 | .bucket("mybucket--test-zone-ab1--x-s3".to_string())
|
10613 9171 | .use_fips(true)
|
10614 9172 | .use_dual_stack(true)
|
10615 9173 | .accelerate(false)
|
10616 9174 | .use_s3_express_control_endpoint(false)
|
10617 9175 | .build()
|
10618 9176 | .expect("invalid params");
|
10619 9177 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10620 9178 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10621 9179 | let endpoint = endpoint
|
10622 9180 | .expect("Expected valid endpoint: https://mybucket--test-zone-ab1--x-s3.s3express-fips-test-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
10623 9181 | assert_eq!(
|
10624 9182 | endpoint,
|
10625 9183 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10626 9184 | .url("https://mybucket--test-zone-ab1--x-s3.s3express-fips-test-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10627 - | .property(
|
10628 - | "authSchemes",
|
10629 - | vec![{
|
10630 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10631 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10632 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10633 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10634 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10635 - | out
|
10636 - | }
|
10637 - | .into()]
|
9185 + | .auth_scheme(
|
9186 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9187 + | .put("disableDoubleEncoding", true)
|
9188 + | .put("signingName", "s3express".to_string())
|
9189 + | .put("signingRegion", "us-west-2".to_string())
|
10638 9190 | )
|
10639 9191 | .property("backend", "S3Express".to_string())
|
10640 9192 | .build()
|
10641 9193 | );
|
10642 9194 | }
|
10643 9195 |
|
10644 9196 | /// Data Plane sigv4 auth with 13-char zone and dualstack
|
10645 9197 | #[test]
|
10646 9198 | fn test_358() {
|
10647 9199 | let params = crate::config::endpoint::Params::builder()
|
10648 9200 | .region("us-west-2".to_string())
|
10649 9201 | .bucket("mybucket--test-zone-ab1--x-s3".to_string())
|
10650 9202 | .use_fips(false)
|
10651 9203 | .use_dual_stack(true)
|
10652 9204 | .accelerate(false)
|
10653 9205 | .disable_s3_express_session_auth(true)
|
10654 9206 | .build()
|
10655 9207 | .expect("invalid params");
|
10656 9208 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10657 9209 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10658 9210 | let endpoint = endpoint
|
10659 9211 | .expect("Expected valid endpoint: https://mybucket--test-zone-ab1--x-s3.s3express-test-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
10660 9212 | assert_eq!(
|
10661 9213 | endpoint,
|
10662 9214 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10663 9215 | .url("https://mybucket--test-zone-ab1--x-s3.s3express-test-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10664 - | .property(
|
10665 - | "authSchemes",
|
10666 - | vec![{
|
10667 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10668 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10669 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10670 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10671 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10672 - | out
|
10673 - | }
|
10674 - | .into()]
|
9216 + | .auth_scheme(
|
9217 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9218 + | .put("disableDoubleEncoding", true)
|
9219 + | .put("signingName", "s3express".to_string())
|
9220 + | .put("signingRegion", "us-west-2".to_string())
|
10675 9221 | )
|
10676 9222 | .property("backend", "S3Express".to_string())
|
10677 9223 | .build()
|
10678 9224 | );
|
10679 9225 | }
|
10680 9226 |
|
10681 9227 | /// Data Plane sigv4 auth with 13-char zone and FIPS with dualstack
|
10682 9228 | #[test]
|
10683 9229 | fn test_359() {
|
10684 9230 | let params = crate::config::endpoint::Params::builder()
|
10685 9231 | .region("us-west-2".to_string())
|
10686 9232 | .bucket("mybucket--test-zone-ab1--x-s3".to_string())
|
10687 9233 | .use_fips(true)
|
10688 9234 | .use_dual_stack(true)
|
10689 9235 | .accelerate(false)
|
10690 9236 | .disable_s3_express_session_auth(true)
|
10691 9237 | .build()
|
10692 9238 | .expect("invalid params");
|
10693 9239 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10694 9240 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10695 9241 | let endpoint = endpoint
|
10696 9242 | .expect("Expected valid endpoint: https://mybucket--test-zone-ab1--x-s3.s3express-fips-test-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
10697 9243 | assert_eq!(
|
10698 9244 | endpoint,
|
10699 9245 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10700 9246 | .url("https://mybucket--test-zone-ab1--x-s3.s3express-fips-test-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10701 - | .property(
|
10702 - | "authSchemes",
|
10703 - | vec![{
|
10704 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10705 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10706 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10707 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10708 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10709 - | out
|
10710 - | }
|
10711 - | .into()]
|
9247 + | .auth_scheme(
|
9248 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9249 + | .put("disableDoubleEncoding", true)
|
9250 + | .put("signingName", "s3express".to_string())
|
9251 + | .put("signingRegion", "us-west-2".to_string())
|
10712 9252 | )
|
10713 9253 | .property("backend", "S3Express".to_string())
|
10714 9254 | .build()
|
10715 9255 | );
|
10716 9256 | }
|
10717 9257 |
|
10718 9258 | /// Data Plane with 14-char zone and dualstack
|
10719 9259 | #[test]
|
10720 9260 | fn test_360() {
|
10721 9261 | let params = crate::config::endpoint::Params::builder()
|
10722 9262 | .region("us-west-2".to_string())
|
10723 9263 | .bucket("mybucket--test1-zone-ab1--x-s3".to_string())
|
10724 9264 | .use_fips(false)
|
10725 9265 | .use_dual_stack(true)
|
10726 9266 | .accelerate(false)
|
10727 9267 | .use_s3_express_control_endpoint(false)
|
10728 9268 | .build()
|
10729 9269 | .expect("invalid params");
|
10730 9270 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10731 9271 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10732 9272 | let endpoint = endpoint
|
10733 9273 | .expect("Expected valid endpoint: https://mybucket--test1-zone-ab1--x-s3.s3express-test1-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
10734 9274 | assert_eq!(
|
10735 9275 | endpoint,
|
10736 9276 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10737 9277 | .url("https://mybucket--test1-zone-ab1--x-s3.s3express-test1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10738 - | .property(
|
10739 - | "authSchemes",
|
10740 - | vec![{
|
10741 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10742 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10743 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10744 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10745 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10746 - | out
|
10747 - | }
|
10748 - | .into()]
|
9278 + | .auth_scheme(
|
9279 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9280 + | .put("disableDoubleEncoding", true)
|
9281 + | .put("signingName", "s3express".to_string())
|
9282 + | .put("signingRegion", "us-west-2".to_string())
|
10749 9283 | )
|
10750 9284 | .property("backend", "S3Express".to_string())
|
10751 9285 | .build()
|
10752 9286 | );
|
10753 9287 | }
|
10754 9288 |
|
10755 9289 | /// Data Plane with 14-char zone and FIPS with dualstack
|
10756 9290 | #[test]
|
10757 9291 | fn test_361() {
|
10758 9292 | let params = crate::config::endpoint::Params::builder()
|
10759 9293 | .region("us-west-2".to_string())
|
10760 9294 | .bucket("mybucket--test1-zone-ab1--x-s3".to_string())
|
10761 9295 | .use_fips(true)
|
10762 9296 | .use_dual_stack(true)
|
10763 9297 | .accelerate(false)
|
10764 9298 | .use_s3_express_control_endpoint(false)
|
10765 9299 | .build()
|
10766 9300 | .expect("invalid params");
|
10767 9301 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10768 9302 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10769 9303 | let endpoint = endpoint.expect(
|
10770 9304 | "Expected valid endpoint: https://mybucket--test1-zone-ab1--x-s3.s3express-fips-test1-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
10771 9305 | );
|
10772 9306 | assert_eq!(
|
10773 9307 | endpoint,
|
10774 9308 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10775 9309 | .url("https://mybucket--test1-zone-ab1--x-s3.s3express-fips-test1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10776 - | .property(
|
10777 - | "authSchemes",
|
10778 - | vec![{
|
10779 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10780 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10781 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10782 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10783 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10784 - | out
|
10785 - | }
|
10786 - | .into()]
|
9310 + | .auth_scheme(
|
9311 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9312 + | .put("disableDoubleEncoding", true)
|
9313 + | .put("signingName", "s3express".to_string())
|
9314 + | .put("signingRegion", "us-west-2".to_string())
|
10787 9315 | )
|
10788 9316 | .property("backend", "S3Express".to_string())
|
10789 9317 | .build()
|
10790 9318 | );
|
10791 9319 | }
|
10792 9320 |
|
10793 9321 | /// Data Plane sigv4 auth with 14-char zone and dualstack
|
10794 9322 | #[test]
|
10795 9323 | fn test_362() {
|
10796 9324 | let params = crate::config::endpoint::Params::builder()
|
10797 9325 | .region("us-west-2".to_string())
|
10798 9326 | .bucket("mybucket--test1-zone-ab1--x-s3".to_string())
|
10799 9327 | .use_fips(false)
|
10800 9328 | .use_dual_stack(true)
|
10801 9329 | .accelerate(false)
|
10802 9330 | .disable_s3_express_session_auth(true)
|
10803 9331 | .build()
|
10804 9332 | .expect("invalid params");
|
10805 9333 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10806 9334 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10807 9335 | let endpoint = endpoint
|
10808 9336 | .expect("Expected valid endpoint: https://mybucket--test1-zone-ab1--x-s3.s3express-test1-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
10809 9337 | assert_eq!(
|
10810 9338 | endpoint,
|
10811 9339 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10812 9340 | .url("https://mybucket--test1-zone-ab1--x-s3.s3express-test1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10813 - | .property(
|
10814 - | "authSchemes",
|
10815 - | vec![{
|
10816 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10817 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10818 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10819 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10820 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10821 - | out
|
10822 - | }
|
10823 - | .into()]
|
9341 + | .auth_scheme(
|
9342 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9343 + | .put("disableDoubleEncoding", true)
|
9344 + | .put("signingName", "s3express".to_string())
|
9345 + | .put("signingRegion", "us-west-2".to_string())
|
10824 9346 | )
|
10825 9347 | .property("backend", "S3Express".to_string())
|
10826 9348 | .build()
|
10827 9349 | );
|
10828 9350 | }
|
10829 9351 |
|
10830 9352 | /// Data Plane sigv4 auth with 14-char zone and FIPS with dualstack
|
10831 9353 | #[test]
|
10832 9354 | fn test_363() {
|
10833 9355 | let params = crate::config::endpoint::Params::builder()
|
10834 9356 | .region("us-west-2".to_string())
|
10835 9357 | .bucket("mybucket--test1-zone-ab1--x-s3".to_string())
|
10836 9358 | .use_fips(true)
|
10837 9359 | .use_dual_stack(true)
|
10838 9360 | .accelerate(false)
|
10839 9361 | .disable_s3_express_session_auth(true)
|
10840 9362 | .build()
|
10841 9363 | .expect("invalid params");
|
10842 9364 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10843 9365 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10844 9366 | let endpoint = endpoint.expect(
|
10845 9367 | "Expected valid endpoint: https://mybucket--test1-zone-ab1--x-s3.s3express-fips-test1-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
10846 9368 | );
|
10847 9369 | assert_eq!(
|
10848 9370 | endpoint,
|
10849 9371 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10850 9372 | .url("https://mybucket--test1-zone-ab1--x-s3.s3express-fips-test1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10851 - | .property(
|
10852 - | "authSchemes",
|
10853 - | vec![{
|
10854 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10855 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10856 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10857 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10858 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10859 - | out
|
10860 - | }
|
10861 - | .into()]
|
9373 + | .auth_scheme(
|
9374 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9375 + | .put("disableDoubleEncoding", true)
|
9376 + | .put("signingName", "s3express".to_string())
|
9377 + | .put("signingRegion", "us-west-2".to_string())
|
10862 9378 | )
|
10863 9379 | .property("backend", "S3Express".to_string())
|
10864 9380 | .build()
|
10865 9381 | );
|
10866 9382 | }
|
10867 9383 |
|
10868 9384 | /// Data Plane with long zone (20 cha) and dualstack
|
10869 9385 | #[test]
|
10870 9386 | fn test_364() {
|
10871 9387 | let params = crate::config::endpoint::Params::builder()
|
10872 9388 | .region("us-west-2".to_string())
|
10873 9389 | .bucket("mybucket--test1-long1-zone-ab1--x-s3".to_string())
|
10874 9390 | .use_fips(false)
|
10875 9391 | .use_dual_stack(true)
|
10876 9392 | .accelerate(false)
|
10877 9393 | .use_s3_express_control_endpoint(false)
|
10878 9394 | .build()
|
10879 9395 | .expect("invalid params");
|
10880 9396 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10881 9397 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10882 9398 | let endpoint = endpoint.expect(
|
10883 9399 | "Expected valid endpoint: https://mybucket--test1-long1-zone-ab1--x-s3.s3express-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
10884 9400 | );
|
10885 9401 | assert_eq!(
|
10886 9402 | endpoint,
|
10887 9403 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10888 9404 | .url("https://mybucket--test1-long1-zone-ab1--x-s3.s3express-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10889 - | .property(
|
10890 - | "authSchemes",
|
10891 - | vec![{
|
10892 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10893 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10894 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10895 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10896 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10897 - | out
|
10898 - | }
|
10899 - | .into()]
|
9405 + | .auth_scheme(
|
9406 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9407 + | .put("disableDoubleEncoding", true)
|
9408 + | .put("signingName", "s3express".to_string())
|
9409 + | .put("signingRegion", "us-west-2".to_string())
|
10900 9410 | )
|
10901 9411 | .property("backend", "S3Express".to_string())
|
10902 9412 | .build()
|
10903 9413 | );
|
10904 9414 | }
|
10905 9415 |
|
10906 9416 | /// Data Plane with long zone (20 char) and FIPS with dualstack
|
10907 9417 | #[test]
|
10908 9418 | fn test_365() {
|
10909 9419 | let params = crate::config::endpoint::Params::builder()
|
10910 9420 | .region("us-west-2".to_string())
|
10911 9421 | .bucket("mybucket--test1-long1-zone-ab1--x-s3".to_string())
|
10912 9422 | .use_fips(true)
|
10913 9423 | .use_dual_stack(true)
|
10914 9424 | .accelerate(false)
|
10915 9425 | .use_s3_express_control_endpoint(false)
|
10916 9426 | .build()
|
10917 9427 | .expect("invalid params");
|
10918 9428 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10919 9429 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10920 9430 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--test1-long1-zone-ab1--x-s3.s3express-fips-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
10921 9431 | assert_eq!(
|
10922 9432 | endpoint,
|
10923 9433 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10924 9434 | .url("https://mybucket--test1-long1-zone-ab1--x-s3.s3express-fips-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10925 - | .property(
|
10926 - | "authSchemes",
|
10927 - | vec![{
|
10928 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10929 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
10930 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10931 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10932 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10933 - | out
|
10934 - | }
|
10935 - | .into()]
|
9435 + | .auth_scheme(
|
9436 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9437 + | .put("disableDoubleEncoding", true)
|
9438 + | .put("signingName", "s3express".to_string())
|
9439 + | .put("signingRegion", "us-west-2".to_string())
|
10936 9440 | )
|
10937 9441 | .property("backend", "S3Express".to_string())
|
10938 9442 | .build()
|
10939 9443 | );
|
10940 9444 | }
|
10941 9445 |
|
10942 9446 | /// Data Plane sigv4 auth with long zone (20 char) and dualstack
|
10943 9447 | #[test]
|
10944 9448 | fn test_366() {
|
10945 9449 | let params = crate::config::endpoint::Params::builder()
|
10946 9450 | .region("us-west-2".to_string())
|
10947 9451 | .bucket("mybucket--test1-long1-zone-ab1--x-s3".to_string())
|
10948 9452 | .use_fips(false)
|
10949 9453 | .use_dual_stack(true)
|
10950 9454 | .accelerate(false)
|
10951 9455 | .disable_s3_express_session_auth(true)
|
10952 9456 | .build()
|
10953 9457 | .expect("invalid params");
|
10954 9458 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10955 9459 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10956 9460 | let endpoint = endpoint.expect(
|
10957 9461 | "Expected valid endpoint: https://mybucket--test1-long1-zone-ab1--x-s3.s3express-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
10958 9462 | );
|
10959 9463 | assert_eq!(
|
10960 9464 | endpoint,
|
10961 9465 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10962 9466 | .url("https://mybucket--test1-long1-zone-ab1--x-s3.s3express-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10963 - | .property(
|
10964 - | "authSchemes",
|
10965 - | vec![{
|
10966 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
10967 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
10968 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
10969 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
10970 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
10971 - | out
|
10972 - | }
|
10973 - | .into()]
|
9467 + | .auth_scheme(
|
9468 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9469 + | .put("disableDoubleEncoding", true)
|
9470 + | .put("signingName", "s3express".to_string())
|
9471 + | .put("signingRegion", "us-west-2".to_string())
|
10974 9472 | )
|
10975 9473 | .property("backend", "S3Express".to_string())
|
10976 9474 | .build()
|
10977 9475 | );
|
10978 9476 | }
|
10979 9477 |
|
10980 9478 | /// Data Plane sigv4 auth with long zone (20 char) and FIPS with dualstack
|
10981 9479 | #[test]
|
10982 9480 | fn test_367() {
|
10983 9481 | let params = crate::config::endpoint::Params::builder()
|
10984 9482 | .region("us-west-2".to_string())
|
10985 9483 | .bucket("mybucket--test1-long1-zone-ab1--x-s3".to_string())
|
10986 9484 | .use_fips(true)
|
10987 9485 | .use_dual_stack(true)
|
10988 9486 | .accelerate(false)
|
10989 9487 | .disable_s3_express_session_auth(true)
|
10990 9488 | .build()
|
10991 9489 | .expect("invalid params");
|
10992 9490 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
10993 9491 | let endpoint = resolver.resolve_endpoint(¶ms);
|
10994 9492 | let endpoint = endpoint.expect("Expected valid endpoint: https://mybucket--test1-long1-zone-ab1--x-s3.s3express-fips-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
10995 9493 | assert_eq!(
|
10996 9494 | endpoint,
|
10997 9495 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10998 9496 | .url("https://mybucket--test1-long1-zone-ab1--x-s3.s3express-fips-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
10999 - | .property(
|
11000 - | "authSchemes",
|
11001 - | vec![{
|
11002 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11003 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11004 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11005 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11006 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11007 - | out
|
11008 - | }
|
11009 - | .into()]
|
9497 + | .auth_scheme(
|
9498 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9499 + | .put("disableDoubleEncoding", true)
|
9500 + | .put("signingName", "s3express".to_string())
|
9501 + | .put("signingRegion", "us-west-2".to_string())
|
11010 9502 | )
|
11011 9503 | .property("backend", "S3Express".to_string())
|
11012 9504 | .build()
|
11013 9505 | );
|
11014 9506 | }
|
11015 9507 |
|
11016 9508 | /// Control plane and FIPS with dualstack
|
11017 9509 | #[test]
|
11018 9510 | fn test_368() {
|
11019 9511 | let params = crate::config::endpoint::Params::builder()
|
11020 9512 | .region("us-east-1".to_string())
|
11021 9513 | .bucket("mybucket--test-ab1--x-s3".to_string())
|
11022 9514 | .use_fips(true)
|
11023 9515 | .use_dual_stack(true)
|
11024 9516 | .accelerate(false)
|
11025 9517 | .use_s3_express_control_endpoint(true)
|
11026 9518 | .build()
|
11027 9519 | .expect("invalid params");
|
11028 9520 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11029 9521 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11030 9522 | let endpoint =
|
11031 9523 | endpoint.expect("Expected valid endpoint: https://s3express-control-fips.dualstack.us-east-1.amazonaws.com/mybucket--test-ab1--x-s3");
|
11032 9524 | assert_eq!(
|
11033 9525 | endpoint,
|
11034 9526 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11035 9527 | .url("https://s3express-control-fips.dualstack.us-east-1.amazonaws.com/mybucket--test-ab1--x-s3")
|
11036 - | .property(
|
11037 - | "authSchemes",
|
11038 - | vec![{
|
11039 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11040 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11041 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11042 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
11043 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11044 - | out
|
11045 - | }
|
11046 - | .into()]
|
9528 + | .auth_scheme(
|
9529 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9530 + | .put("disableDoubleEncoding", true)
|
9531 + | .put("signingName", "s3express".to_string())
|
9532 + | .put("signingRegion", "us-east-1".to_string())
|
11047 9533 | )
|
11048 9534 | .property("backend", "S3Express".to_string())
|
11049 9535 | .build()
|
11050 9536 | );
|
11051 9537 | }
|
11052 9538 |
|
11053 9539 | /// Data plane with zone and dualstack and AP
|
11054 9540 | #[test]
|
11055 9541 | fn test_369() {
|
11056 9542 | let params = crate::config::endpoint::Params::builder()
|
11057 9543 | .region("us-west-2".to_string())
|
11058 9544 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
11059 9545 | .use_fips(false)
|
11060 9546 | .use_dual_stack(true)
|
11061 9547 | .accelerate(false)
|
11062 9548 | .use_s3_express_control_endpoint(false)
|
11063 9549 | .build()
|
11064 9550 | .expect("invalid params");
|
11065 9551 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11066 9552 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11067 9553 | let endpoint =
|
11068 9554 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--usw2-az1--xa-s3.s3express-usw2-az1.dualstack.us-west-2.amazonaws.com");
|
11069 9555 | assert_eq!(
|
11070 9556 | endpoint,
|
11071 9557 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11072 9558 | .url("https://myaccesspoint--usw2-az1--xa-s3.s3express-usw2-az1.dualstack.us-west-2.amazonaws.com")
|
11073 - | .property(
|
11074 - | "authSchemes",
|
11075 - | vec![{
|
11076 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11077 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11078 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11079 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11080 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11081 - | out
|
11082 - | }
|
11083 - | .into()]
|
9559 + | .auth_scheme(
|
9560 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9561 + | .put("disableDoubleEncoding", true)
|
9562 + | .put("signingName", "s3express".to_string())
|
9563 + | .put("signingRegion", "us-west-2".to_string())
|
11084 9564 | )
|
11085 9565 | .property("backend", "S3Express".to_string())
|
11086 9566 | .build()
|
11087 9567 | );
|
11088 9568 | }
|
11089 9569 |
|
11090 9570 | /// Data plane with zone and FIPS with dualstack and AP
|
11091 9571 | #[test]
|
11092 9572 | fn test_370() {
|
11093 9573 | let params = crate::config::endpoint::Params::builder()
|
11094 9574 | .region("us-west-2".to_string())
|
11095 9575 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
11096 9576 | .use_fips(true)
|
11097 9577 | .use_dual_stack(true)
|
11098 9578 | .accelerate(false)
|
11099 9579 | .use_s3_express_control_endpoint(false)
|
11100 9580 | .build()
|
11101 9581 | .expect("invalid params");
|
11102 9582 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11103 9583 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11104 9584 | let endpoint = endpoint
|
11105 9585 | .expect("Expected valid endpoint: https://myaccesspoint--usw2-az1--xa-s3.s3express-fips-usw2-az1.dualstack.us-west-2.amazonaws.com");
|
11106 9586 | assert_eq!(
|
11107 9587 | endpoint,
|
11108 9588 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11109 9589 | .url("https://myaccesspoint--usw2-az1--xa-s3.s3express-fips-usw2-az1.dualstack.us-west-2.amazonaws.com")
|
11110 - | .property(
|
11111 - | "authSchemes",
|
11112 - | vec![{
|
11113 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11114 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11115 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11116 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11117 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11118 - | out
|
11119 - | }
|
11120 - | .into()]
|
9590 + | .auth_scheme(
|
9591 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9592 + | .put("disableDoubleEncoding", true)
|
9593 + | .put("signingName", "s3express".to_string())
|
9594 + | .put("signingRegion", "us-west-2".to_string())
|
11121 9595 | )
|
11122 9596 | .property("backend", "S3Express".to_string())
|
11123 9597 | .build()
|
11124 9598 | );
|
11125 9599 | }
|
11126 9600 |
|
11127 9601 | /// Data Plane sigv4 auth with zone and dualstack and AP
|
11128 9602 | #[test]
|
11129 9603 | fn test_371() {
|
11130 9604 | let params = crate::config::endpoint::Params::builder()
|
11131 9605 | .region("us-west-2".to_string())
|
11132 9606 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
11133 9607 | .use_fips(false)
|
11134 9608 | .use_dual_stack(true)
|
11135 9609 | .accelerate(false)
|
11136 9610 | .disable_s3_express_session_auth(true)
|
11137 9611 | .build()
|
11138 9612 | .expect("invalid params");
|
11139 9613 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11140 9614 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11141 9615 | let endpoint =
|
11142 9616 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--usw2-az1--xa-s3.s3express-usw2-az1.dualstack.us-west-2.amazonaws.com");
|
11143 9617 | assert_eq!(
|
11144 9618 | endpoint,
|
11145 9619 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11146 9620 | .url("https://myaccesspoint--usw2-az1--xa-s3.s3express-usw2-az1.dualstack.us-west-2.amazonaws.com")
|
11147 - | .property(
|
11148 - | "authSchemes",
|
11149 - | vec![{
|
11150 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11151 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11152 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11153 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11154 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11155 - | out
|
11156 - | }
|
11157 - | .into()]
|
9621 + | .auth_scheme(
|
9622 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9623 + | .put("disableDoubleEncoding", true)
|
9624 + | .put("signingName", "s3express".to_string())
|
9625 + | .put("signingRegion", "us-west-2".to_string())
|
11158 9626 | )
|
11159 9627 | .property("backend", "S3Express".to_string())
|
11160 9628 | .build()
|
11161 9629 | );
|
11162 9630 | }
|
11163 9631 |
|
11164 9632 | /// Data Plane AP sigv4 auth with zone and FIPS with dualstack
|
11165 9633 | #[test]
|
11166 9634 | fn test_372() {
|
11167 9635 | let params = crate::config::endpoint::Params::builder()
|
11168 9636 | .region("us-west-2".to_string())
|
11169 9637 | .bucket("myaccesspoint--usw2-az1--xa-s3".to_string())
|
11170 9638 | .use_fips(true)
|
11171 9639 | .use_dual_stack(true)
|
11172 9640 | .accelerate(false)
|
11173 9641 | .disable_s3_express_session_auth(true)
|
11174 9642 | .build()
|
11175 9643 | .expect("invalid params");
|
11176 9644 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11177 9645 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11178 9646 | let endpoint = endpoint
|
11179 9647 | .expect("Expected valid endpoint: https://myaccesspoint--usw2-az1--xa-s3.s3express-fips-usw2-az1.dualstack.us-west-2.amazonaws.com");
|
11180 9648 | assert_eq!(
|
11181 9649 | endpoint,
|
11182 9650 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11183 9651 | .url("https://myaccesspoint--usw2-az1--xa-s3.s3express-fips-usw2-az1.dualstack.us-west-2.amazonaws.com")
|
11184 - | .property(
|
11185 - | "authSchemes",
|
11186 - | vec![{
|
11187 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11188 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11189 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11190 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11191 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11192 - | out
|
11193 - | }
|
11194 - | .into()]
|
9652 + | .auth_scheme(
|
9653 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9654 + | .put("disableDoubleEncoding", true)
|
9655 + | .put("signingName", "s3express".to_string())
|
9656 + | .put("signingRegion", "us-west-2".to_string())
|
11195 9657 | )
|
11196 9658 | .property("backend", "S3Express".to_string())
|
11197 9659 | .build()
|
11198 9660 | );
|
11199 9661 | }
|
11200 9662 |
|
11201 9663 | /// Data Plane with zone (9 char) and AP with dualstack
|
11202 9664 | #[test]
|
11203 9665 | fn test_373() {
|
11204 9666 | let params = crate::config::endpoint::Params::builder()
|
11205 9667 | .region("us-west-2".to_string())
|
11206 9668 | .bucket("myaccesspoint--usw2-az12--xa-s3".to_string())
|
11207 9669 | .use_fips(false)
|
11208 9670 | .use_dual_stack(true)
|
11209 9671 | .accelerate(false)
|
11210 9672 | .use_s3_express_control_endpoint(false)
|
11211 9673 | .build()
|
11212 9674 | .expect("invalid params");
|
11213 9675 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11214 9676 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11215 9677 | let endpoint =
|
11216 9678 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--usw2-az12--xa-s3.s3express-usw2-az12.dualstack.us-west-2.amazonaws.com");
|
11217 9679 | assert_eq!(
|
11218 9680 | endpoint,
|
11219 9681 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11220 9682 | .url("https://myaccesspoint--usw2-az12--xa-s3.s3express-usw2-az12.dualstack.us-west-2.amazonaws.com")
|
11221 - | .property(
|
11222 - | "authSchemes",
|
11223 - | vec![{
|
11224 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11225 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11226 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11227 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11228 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11229 - | out
|
11230 - | }
|
11231 - | .into()]
|
9683 + | .auth_scheme(
|
9684 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9685 + | .put("disableDoubleEncoding", true)
|
9686 + | .put("signingName", "s3express".to_string())
|
9687 + | .put("signingRegion", "us-west-2".to_string())
|
11232 9688 | )
|
11233 9689 | .property("backend", "S3Express".to_string())
|
11234 9690 | .build()
|
11235 9691 | );
|
11236 9692 | }
|
11237 9693 |
|
11238 9694 | /// Data Plane with zone (9 char) and FIPS with AP and dualstack
|
11239 9695 | #[test]
|
11240 9696 | fn test_374() {
|
11241 9697 | let params = crate::config::endpoint::Params::builder()
|
11242 9698 | .region("us-west-2".to_string())
|
11243 9699 | .bucket("myaccesspoint--usw2-az12--xa-s3".to_string())
|
11244 9700 | .use_fips(true)
|
11245 9701 | .use_dual_stack(true)
|
11246 9702 | .accelerate(false)
|
11247 9703 | .use_s3_express_control_endpoint(false)
|
11248 9704 | .build()
|
11249 9705 | .expect("invalid params");
|
11250 9706 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11251 9707 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11252 9708 | let endpoint = endpoint
|
11253 9709 | .expect("Expected valid endpoint: https://myaccesspoint--usw2-az12--xa-s3.s3express-fips-usw2-az12.dualstack.us-west-2.amazonaws.com");
|
11254 9710 | assert_eq!(
|
11255 9711 | endpoint,
|
11256 9712 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11257 9713 | .url("https://myaccesspoint--usw2-az12--xa-s3.s3express-fips-usw2-az12.dualstack.us-west-2.amazonaws.com")
|
11258 - | .property(
|
11259 - | "authSchemes",
|
11260 - | vec![{
|
11261 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11262 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11263 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11264 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11265 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11266 - | out
|
11267 - | }
|
11268 - | .into()]
|
9714 + | .auth_scheme(
|
9715 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9716 + | .put("disableDoubleEncoding", true)
|
9717 + | .put("signingName", "s3express".to_string())
|
9718 + | .put("signingRegion", "us-west-2".to_string())
|
11269 9719 | )
|
11270 9720 | .property("backend", "S3Express".to_string())
|
11271 9721 | .build()
|
11272 9722 | );
|
11273 9723 | }
|
11274 9724 |
|
11275 9725 | /// Data Plane sigv4 auth with (9 char) zone and dualstack with AP
|
11276 9726 | #[test]
|
11277 9727 | fn test_375() {
|
11278 9728 | let params = crate::config::endpoint::Params::builder()
|
11279 9729 | .region("us-west-2".to_string())
|
11280 9730 | .bucket("myaccesspoint--usw2-az12--xa-s3".to_string())
|
11281 9731 | .use_fips(false)
|
11282 9732 | .use_dual_stack(true)
|
11283 9733 | .accelerate(false)
|
11284 9734 | .disable_s3_express_session_auth(true)
|
11285 9735 | .build()
|
11286 9736 | .expect("invalid params");
|
11287 9737 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11288 9738 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11289 9739 | let endpoint =
|
11290 9740 | endpoint.expect("Expected valid endpoint: https://myaccesspoint--usw2-az12--xa-s3.s3express-usw2-az12.dualstack.us-west-2.amazonaws.com");
|
11291 9741 | assert_eq!(
|
11292 9742 | endpoint,
|
11293 9743 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11294 9744 | .url("https://myaccesspoint--usw2-az12--xa-s3.s3express-usw2-az12.dualstack.us-west-2.amazonaws.com")
|
11295 - | .property(
|
11296 - | "authSchemes",
|
11297 - | vec![{
|
11298 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11299 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11300 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11301 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11302 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11303 - | out
|
11304 - | }
|
11305 - | .into()]
|
9745 + | .auth_scheme(
|
9746 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9747 + | .put("disableDoubleEncoding", true)
|
9748 + | .put("signingName", "s3express".to_string())
|
9749 + | .put("signingRegion", "us-west-2".to_string())
|
11306 9750 | )
|
11307 9751 | .property("backend", "S3Express".to_string())
|
11308 9752 | .build()
|
11309 9753 | );
|
11310 9754 | }
|
11311 9755 |
|
11312 9756 | /// Access Point sigv4 auth with (9 char) zone and FIPS with dualstack
|
11313 9757 | #[test]
|
11314 9758 | fn test_376() {
|
11315 9759 | let params = crate::config::endpoint::Params::builder()
|
11316 9760 | .region("us-west-2".to_string())
|
11317 9761 | .bucket("myaccesspoint--usw2-az12--xa-s3".to_string())
|
11318 9762 | .use_fips(true)
|
11319 9763 | .use_dual_stack(true)
|
11320 9764 | .accelerate(false)
|
11321 9765 | .disable_s3_express_session_auth(true)
|
11322 9766 | .build()
|
11323 9767 | .expect("invalid params");
|
11324 9768 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11325 9769 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11326 9770 | let endpoint = endpoint
|
11327 9771 | .expect("Expected valid endpoint: https://myaccesspoint--usw2-az12--xa-s3.s3express-fips-usw2-az12.dualstack.us-west-2.amazonaws.com");
|
11328 9772 | assert_eq!(
|
11329 9773 | endpoint,
|
11330 9774 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11331 9775 | .url("https://myaccesspoint--usw2-az12--xa-s3.s3express-fips-usw2-az12.dualstack.us-west-2.amazonaws.com")
|
11332 - | .property(
|
11333 - | "authSchemes",
|
11334 - | vec![{
|
11335 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11336 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11337 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11338 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11339 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11340 - | out
|
11341 - | }
|
11342 - | .into()]
|
9776 + | .auth_scheme(
|
9777 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9778 + | .put("disableDoubleEncoding", true)
|
9779 + | .put("signingName", "s3express".to_string())
|
9780 + | .put("signingRegion", "us-west-2".to_string())
|
11343 9781 | )
|
11344 9782 | .property("backend", "S3Express".to_string())
|
11345 9783 | .build()
|
11346 9784 | );
|
11347 9785 | }
|
11348 9786 |
|
11349 9787 | /// Data Plane with zone (13 char) and AP with dualstack
|
11350 9788 | #[test]
|
11351 9789 | fn test_377() {
|
11352 9790 | let params = crate::config::endpoint::Params::builder()
|
11353 9791 | .region("us-west-2".to_string())
|
11354 9792 | .bucket("myaccesspoint--test-zone-ab1--xa-s3".to_string())
|
11355 9793 | .use_fips(false)
|
11356 9794 | .use_dual_stack(true)
|
11357 9795 | .accelerate(false)
|
11358 9796 | .use_s3_express_control_endpoint(false)
|
11359 9797 | .build()
|
11360 9798 | .expect("invalid params");
|
11361 9799 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11362 9800 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11363 9801 | let endpoint = endpoint
|
11364 9802 | .expect("Expected valid endpoint: https://myaccesspoint--test-zone-ab1--xa-s3.s3express-test-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
11365 9803 | assert_eq!(
|
11366 9804 | endpoint,
|
11367 9805 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11368 9806 | .url("https://myaccesspoint--test-zone-ab1--xa-s3.s3express-test-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11369 - | .property(
|
11370 - | "authSchemes",
|
11371 - | vec![{
|
11372 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11373 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11374 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11375 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11376 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11377 - | out
|
11378 - | }
|
11379 - | .into()]
|
9807 + | .auth_scheme(
|
9808 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9809 + | .put("disableDoubleEncoding", true)
|
9810 + | .put("signingName", "s3express".to_string())
|
9811 + | .put("signingRegion", "us-west-2".to_string())
|
11380 9812 | )
|
11381 9813 | .property("backend", "S3Express".to_string())
|
11382 9814 | .build()
|
11383 9815 | );
|
11384 9816 | }
|
11385 9817 |
|
11386 9818 | /// Data Plane with zone (13 char) and AP with FIPS and dualstack
|
11387 9819 | #[test]
|
11388 9820 | fn test_378() {
|
11389 9821 | let params = crate::config::endpoint::Params::builder()
|
11390 9822 | .region("us-west-2".to_string())
|
11391 9823 | .bucket("myaccesspoint--test-zone-ab1--xa-s3".to_string())
|
11392 9824 | .use_fips(true)
|
11393 9825 | .use_dual_stack(true)
|
11394 9826 | .accelerate(false)
|
11395 9827 | .use_s3_express_control_endpoint(false)
|
11396 9828 | .build()
|
11397 9829 | .expect("invalid params");
|
11398 9830 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11399 9831 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11400 9832 | let endpoint = endpoint.expect(
|
11401 9833 | "Expected valid endpoint: https://myaccesspoint--test-zone-ab1--xa-s3.s3express-fips-test-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
11402 9834 | );
|
11403 9835 | assert_eq!(
|
11404 9836 | endpoint,
|
11405 9837 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11406 9838 | .url("https://myaccesspoint--test-zone-ab1--xa-s3.s3express-fips-test-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11407 - | .property(
|
11408 - | "authSchemes",
|
11409 - | vec![{
|
11410 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11411 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11412 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11413 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11414 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11415 - | out
|
11416 - | }
|
11417 - | .into()]
|
9839 + | .auth_scheme(
|
9840 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9841 + | .put("disableDoubleEncoding", true)
|
9842 + | .put("signingName", "s3express".to_string())
|
9843 + | .put("signingRegion", "us-west-2".to_string())
|
11418 9844 | )
|
11419 9845 | .property("backend", "S3Express".to_string())
|
11420 9846 | .build()
|
11421 9847 | );
|
11422 9848 | }
|
11423 9849 |
|
11424 9850 | /// Data Plane sigv4 auth with (13 char) zone with AP and dualstack
|
11425 9851 | #[test]
|
11426 9852 | fn test_379() {
|
11427 9853 | let params = crate::config::endpoint::Params::builder()
|
11428 9854 | .region("us-west-2".to_string())
|
11429 9855 | .bucket("myaccesspoint--test-zone-ab1--xa-s3".to_string())
|
11430 9856 | .use_fips(false)
|
11431 9857 | .use_dual_stack(true)
|
11432 9858 | .accelerate(false)
|
11433 9859 | .disable_s3_express_session_auth(true)
|
11434 9860 | .build()
|
11435 9861 | .expect("invalid params");
|
11436 9862 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11437 9863 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11438 9864 | let endpoint = endpoint
|
11439 9865 | .expect("Expected valid endpoint: https://myaccesspoint--test-zone-ab1--xa-s3.s3express-test-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
11440 9866 | assert_eq!(
|
11441 9867 | endpoint,
|
11442 9868 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11443 9869 | .url("https://myaccesspoint--test-zone-ab1--xa-s3.s3express-test-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11444 - | .property(
|
11445 - | "authSchemes",
|
11446 - | vec![{
|
11447 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11448 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11449 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11450 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11451 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11452 - | out
|
11453 - | }
|
11454 - | .into()]
|
9870 + | .auth_scheme(
|
9871 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9872 + | .put("disableDoubleEncoding", true)
|
9873 + | .put("signingName", "s3express".to_string())
|
9874 + | .put("signingRegion", "us-west-2".to_string())
|
11455 9875 | )
|
11456 9876 | .property("backend", "S3Express".to_string())
|
11457 9877 | .build()
|
11458 9878 | );
|
11459 9879 | }
|
11460 9880 |
|
11461 9881 | /// Data Plane sigv4 auth with (13 char) zone with AP and FIPS and dualstack
|
11462 9882 | #[test]
|
11463 9883 | fn test_380() {
|
11464 9884 | let params = crate::config::endpoint::Params::builder()
|
11465 9885 | .region("us-west-2".to_string())
|
11466 9886 | .bucket("myaccesspoint--test-zone-ab1--xa-s3".to_string())
|
11467 9887 | .use_fips(true)
|
11468 9888 | .use_dual_stack(true)
|
11469 9889 | .accelerate(false)
|
11470 9890 | .disable_s3_express_session_auth(true)
|
11471 9891 | .build()
|
11472 9892 | .expect("invalid params");
|
11473 9893 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11474 9894 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11475 9895 | let endpoint = endpoint.expect(
|
11476 9896 | "Expected valid endpoint: https://myaccesspoint--test-zone-ab1--xa-s3.s3express-fips-test-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
11477 9897 | );
|
11478 9898 | assert_eq!(
|
11479 9899 | endpoint,
|
11480 9900 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11481 9901 | .url("https://myaccesspoint--test-zone-ab1--xa-s3.s3express-fips-test-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11482 - | .property(
|
11483 - | "authSchemes",
|
11484 - | vec![{
|
11485 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11486 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11487 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11488 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11489 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11490 - | out
|
11491 - | }
|
11492 - | .into()]
|
9902 + | .auth_scheme(
|
9903 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
9904 + | .put("disableDoubleEncoding", true)
|
9905 + | .put("signingName", "s3express".to_string())
|
9906 + | .put("signingRegion", "us-west-2".to_string())
|
11493 9907 | )
|
11494 9908 | .property("backend", "S3Express".to_string())
|
11495 9909 | .build()
|
11496 9910 | );
|
11497 9911 | }
|
11498 9912 |
|
11499 9913 | /// Data Plane with (14 char) zone and AP with dualstack
|
11500 9914 | #[test]
|
11501 9915 | fn test_381() {
|
11502 9916 | let params = crate::config::endpoint::Params::builder()
|
11503 9917 | .region("us-west-2".to_string())
|
11504 9918 | .bucket("myaccesspoint--test1-zone-ab1--xa-s3".to_string())
|
11505 9919 | .use_fips(false)
|
11506 9920 | .use_dual_stack(true)
|
11507 9921 | .accelerate(false)
|
11508 9922 | .use_s3_express_control_endpoint(false)
|
11509 9923 | .build()
|
11510 9924 | .expect("invalid params");
|
11511 9925 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11512 9926 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11513 9927 | let endpoint = endpoint.expect(
|
11514 9928 | "Expected valid endpoint: https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-test1-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
11515 9929 | );
|
11516 9930 | assert_eq!(
|
11517 9931 | endpoint,
|
11518 9932 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11519 9933 | .url("https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-test1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11520 - | .property(
|
11521 - | "authSchemes",
|
11522 - | vec![{
|
11523 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11524 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11525 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11526 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11527 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11528 - | out
|
11529 - | }
|
11530 - | .into()]
|
9934 + | .auth_scheme(
|
9935 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9936 + | .put("disableDoubleEncoding", true)
|
9937 + | .put("signingName", "s3express".to_string())
|
9938 + | .put("signingRegion", "us-west-2".to_string())
|
11531 9939 | )
|
11532 9940 | .property("backend", "S3Express".to_string())
|
11533 9941 | .build()
|
11534 9942 | );
|
11535 9943 | }
|
11536 9944 |
|
11537 9945 | /// Data Plane with (14 char) zone and AP with FIPS and dualstack
|
11538 9946 | #[test]
|
11539 9947 | fn test_382() {
|
11540 9948 | let params = crate::config::endpoint::Params::builder()
|
11541 9949 | .region("us-west-2".to_string())
|
11542 9950 | .bucket("myaccesspoint--test1-zone-ab1--xa-s3".to_string())
|
11543 9951 | .use_fips(true)
|
11544 9952 | .use_dual_stack(true)
|
11545 9953 | .accelerate(false)
|
11546 9954 | .use_s3_express_control_endpoint(false)
|
11547 9955 | .build()
|
11548 9956 | .expect("invalid params");
|
11549 9957 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11550 9958 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11551 9959 | let endpoint = endpoint.expect(
|
11552 9960 | "Expected valid endpoint: https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-fips-test1-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
11553 9961 | );
|
11554 9962 | assert_eq!(
|
11555 9963 | endpoint,
|
11556 9964 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11557 9965 | .url("https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-fips-test1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11558 - | .property(
|
11559 - | "authSchemes",
|
11560 - | vec![{
|
11561 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11562 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11563 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11564 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11565 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11566 - | out
|
11567 - | }
|
11568 - | .into()]
|
9966 + | .auth_scheme(
|
9967 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
9968 + | .put("disableDoubleEncoding", true)
|
9969 + | .put("signingName", "s3express".to_string())
|
9970 + | .put("signingRegion", "us-west-2".to_string())
|
11569 9971 | )
|
11570 9972 | .property("backend", "S3Express".to_string())
|
11571 9973 | .build()
|
11572 9974 | );
|
11573 9975 | }
|
11574 9976 |
|
11575 9977 | /// Data Plane sigv4 auth with (14 char) zone and AP with dualstack
|
11576 9978 | #[test]
|
11577 9979 | fn test_383() {
|
11578 9980 | let params = crate::config::endpoint::Params::builder()
|
11579 9981 | .region("us-west-2".to_string())
|
11580 9982 | .bucket("myaccesspoint--test1-zone-ab1--xa-s3".to_string())
|
11581 9983 | .use_fips(false)
|
11582 9984 | .use_dual_stack(true)
|
11583 9985 | .accelerate(false)
|
11584 9986 | .disable_s3_express_session_auth(true)
|
11585 9987 | .build()
|
11586 9988 | .expect("invalid params");
|
11587 9989 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11588 9990 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11589 9991 | let endpoint = endpoint.expect(
|
11590 9992 | "Expected valid endpoint: https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-test1-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
11591 9993 | );
|
11592 9994 | assert_eq!(
|
11593 9995 | endpoint,
|
11594 9996 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11595 9997 | .url("https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-test1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11596 - | .property(
|
11597 - | "authSchemes",
|
11598 - | vec![{
|
11599 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11600 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11601 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11602 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11603 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11604 - | out
|
11605 - | }
|
11606 - | .into()]
|
9998 + | .auth_scheme(
|
9999 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
10000 + | .put("disableDoubleEncoding", true)
|
10001 + | .put("signingName", "s3express".to_string())
|
10002 + | .put("signingRegion", "us-west-2".to_string())
|
11607 10003 | )
|
11608 10004 | .property("backend", "S3Express".to_string())
|
11609 10005 | .build()
|
11610 10006 | );
|
11611 10007 | }
|
11612 10008 |
|
11613 10009 | /// Data Plane with (14 char) zone and AP with FIPS and dualstack
|
11614 10010 | #[test]
|
11615 10011 | fn test_384() {
|
11616 10012 | let params = crate::config::endpoint::Params::builder()
|
11617 10013 | .region("us-west-2".to_string())
|
11618 10014 | .bucket("myaccesspoint--test1-zone-ab1--xa-s3".to_string())
|
11619 10015 | .use_fips(true)
|
11620 10016 | .use_dual_stack(true)
|
11621 10017 | .accelerate(false)
|
11622 10018 | .disable_s3_express_session_auth(true)
|
11623 10019 | .build()
|
11624 10020 | .expect("invalid params");
|
11625 10021 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11626 10022 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11627 10023 | let endpoint = endpoint.expect(
|
11628 10024 | "Expected valid endpoint: https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-fips-test1-zone-ab1.dualstack.us-west-2.amazonaws.com",
|
11629 10025 | );
|
11630 10026 | assert_eq!(
|
11631 10027 | endpoint,
|
11632 10028 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11633 10029 | .url("https://myaccesspoint--test1-zone-ab1--xa-s3.s3express-fips-test1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11634 - | .property(
|
11635 - | "authSchemes",
|
11636 - | vec![{
|
11637 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11638 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11639 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11640 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11641 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11642 - | out
|
11643 - | }
|
11644 - | .into()]
|
10030 + | .auth_scheme(
|
10031 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
10032 + | .put("disableDoubleEncoding", true)
|
10033 + | .put("signingName", "s3express".to_string())
|
10034 + | .put("signingRegion", "us-west-2".to_string())
|
11645 10035 | )
|
11646 10036 | .property("backend", "S3Express".to_string())
|
11647 10037 | .build()
|
11648 10038 | );
|
11649 10039 | }
|
11650 10040 |
|
11651 10041 | /// Data Plane with (20 char) zone and AP with dualstack
|
11652 10042 | #[test]
|
11653 10043 | fn test_385() {
|
11654 10044 | let params = crate::config::endpoint::Params::builder()
|
11655 10045 | .region("us-west-2".to_string())
|
11656 10046 | .bucket("myaccesspoint--test1-long1-zone-ab1--xa-s3".to_string())
|
11657 10047 | .use_fips(false)
|
11658 10048 | .use_dual_stack(true)
|
11659 10049 | .accelerate(false)
|
11660 10050 | .use_s3_express_control_endpoint(false)
|
11661 10051 | .build()
|
11662 10052 | .expect("invalid params");
|
11663 10053 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11664 10054 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11665 10055 | let endpoint = endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
11666 10056 | assert_eq!(
|
11667 10057 | endpoint,
|
11668 10058 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11669 10059 | .url("https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11670 - | .property(
|
11671 - | "authSchemes",
|
11672 - | vec![{
|
11673 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11674 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11675 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11676 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11677 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11678 - | out
|
11679 - | }
|
11680 - | .into()]
|
10060 + | .auth_scheme(
|
10061 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
10062 + | .put("disableDoubleEncoding", true)
|
10063 + | .put("signingName", "s3express".to_string())
|
10064 + | .put("signingRegion", "us-west-2".to_string())
|
11681 10065 | )
|
11682 10066 | .property("backend", "S3Express".to_string())
|
11683 10067 | .build()
|
11684 10068 | );
|
11685 10069 | }
|
11686 10070 |
|
11687 10071 | /// Data Plane with (20 char) zone and AP with FIPS and dualstack
|
11688 10072 | #[test]
|
11689 10073 | fn test_386() {
|
11690 10074 | let params = crate::config::endpoint::Params::builder()
|
11691 10075 | .region("us-west-2".to_string())
|
11692 10076 | .bucket("myaccesspoint--test1-long1-zone-ab1--xa-s3".to_string())
|
11693 10077 | .use_fips(true)
|
11694 10078 | .use_dual_stack(true)
|
11695 10079 | .accelerate(false)
|
11696 10080 | .use_s3_express_control_endpoint(false)
|
11697 10081 | .build()
|
11698 10082 | .expect("invalid params");
|
11699 10083 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11700 10084 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11701 10085 | let endpoint = endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-fips-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
11702 10086 | assert_eq!(
|
11703 10087 | endpoint,
|
11704 10088 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11705 10089 | .url("https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-fips-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11706 - | .property(
|
11707 - | "authSchemes",
|
11708 - | vec![{
|
11709 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11710 - | out.insert("name".to_string(), "sigv4-s3express".to_string().into());
|
11711 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11712 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11713 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11714 - | out
|
11715 - | }
|
11716 - | .into()]
|
10090 + | .auth_scheme(
|
10091 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4-s3express", 3)
|
10092 + | .put("disableDoubleEncoding", true)
|
10093 + | .put("signingName", "s3express".to_string())
|
10094 + | .put("signingRegion", "us-west-2".to_string())
|
11717 10095 | )
|
11718 10096 | .property("backend", "S3Express".to_string())
|
11719 10097 | .build()
|
11720 10098 | );
|
11721 10099 | }
|
11722 10100 |
|
11723 10101 | /// Data plane AP with sigv4 and dualstack
|
11724 10102 | #[test]
|
11725 10103 | fn test_387() {
|
11726 10104 | let params = crate::config::endpoint::Params::builder()
|
11727 10105 | .region("us-west-2".to_string())
|
11728 10106 | .bucket("myaccesspoint--test1-long1-zone-ab1--xa-s3".to_string())
|
11729 10107 | .use_fips(false)
|
11730 10108 | .use_dual_stack(true)
|
11731 10109 | .accelerate(false)
|
11732 10110 | .disable_s3_express_session_auth(true)
|
11733 10111 | .build()
|
11734 10112 | .expect("invalid params");
|
11735 10113 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11736 10114 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11737 10115 | let endpoint = endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
11738 10116 | assert_eq!(
|
11739 10117 | endpoint,
|
11740 10118 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11741 10119 | .url("https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11742 - | .property(
|
11743 - | "authSchemes",
|
11744 - | vec![{
|
11745 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11746 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11747 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11748 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11749 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11750 - | out
|
11751 - | }
|
11752 - | .into()]
|
10120 + | .auth_scheme(
|
10121 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
10122 + | .put("disableDoubleEncoding", true)
|
10123 + | .put("signingName", "s3express".to_string())
|
10124 + | .put("signingRegion", "us-west-2".to_string())
|
11753 10125 | )
|
11754 10126 | .property("backend", "S3Express".to_string())
|
11755 10127 | .build()
|
11756 10128 | );
|
11757 10129 | }
|
11758 10130 |
|
11759 10131 | /// Data plane AP sigv4 with fips and dualstack
|
11760 10132 | #[test]
|
11761 10133 | fn test_388() {
|
11762 10134 | let params = crate::config::endpoint::Params::builder()
|
11763 10135 | .region("us-west-2".to_string())
|
11764 10136 | .bucket("myaccesspoint--test1-long1-zone-ab1--xa-s3".to_string())
|
11765 10137 | .use_fips(true)
|
11766 10138 | .use_dual_stack(true)
|
11767 10139 | .accelerate(false)
|
11768 10140 | .disable_s3_express_session_auth(true)
|
11769 10141 | .build()
|
11770 10142 | .expect("invalid params");
|
11771 10143 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11772 10144 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11773 10145 | let endpoint = endpoint.expect("Expected valid endpoint: https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-fips-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com");
|
11774 10146 | assert_eq!(
|
11775 10147 | endpoint,
|
11776 10148 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11777 10149 | .url("https://myaccesspoint--test1-long1-zone-ab1--xa-s3.s3express-fips-test1-long1-zone-ab1.dualstack.us-west-2.amazonaws.com")
|
11778 - | .property(
|
11779 - | "authSchemes",
|
11780 - | vec![{
|
11781 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11782 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11783 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11784 - | out.insert("signingRegion".to_string(), "us-west-2".to_string().into());
|
11785 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11786 - | out
|
11787 - | }
|
11788 - | .into()]
|
10150 + | .auth_scheme(
|
10151 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
10152 + | .put("disableDoubleEncoding", true)
|
10153 + | .put("signingName", "s3express".to_string())
|
10154 + | .put("signingRegion", "us-west-2".to_string())
|
11789 10155 | )
|
11790 10156 | .property("backend", "S3Express".to_string())
|
11791 10157 | .build()
|
11792 10158 | );
|
11793 10159 | }
|
11794 10160 |
|
11795 10161 | /// Control plane with dualstack and bucket
|
11796 10162 | #[test]
|
11797 10163 | fn test_389() {
|
11798 10164 | let params = crate::config::endpoint::Params::builder()
|
11799 10165 | .region("us-east-1".to_string())
|
11800 10166 | .bucket("mybucket--test-ab1--x-s3".to_string())
|
11801 10167 | .use_fips(false)
|
11802 10168 | .use_dual_stack(true)
|
11803 10169 | .accelerate(false)
|
11804 10170 | .use_s3_express_control_endpoint(true)
|
11805 10171 | .build()
|
11806 10172 | .expect("invalid params");
|
11807 10173 | let resolver = crate::config::endpoint::DefaultResolver::new();
|
11808 10174 | let endpoint = resolver.resolve_endpoint(¶ms);
|
11809 10175 | let endpoint =
|
11810 10176 | endpoint.expect("Expected valid endpoint: https://s3express-control.dualstack.us-east-1.amazonaws.com/mybucket--test-ab1--x-s3");
|
11811 10177 | assert_eq!(
|
11812 10178 | endpoint,
|
11813 10179 | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11814 10180 | .url("https://s3express-control.dualstack.us-east-1.amazonaws.com/mybucket--test-ab1--x-s3")
|
11815 - | .property(
|
11816 - | "authSchemes",
|
11817 - | vec![{
|
11818 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
11819 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
11820 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
11821 - | out.insert("signingRegion".to_string(), "us-east-1".to_string().into());
|
11822 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
11823 - | out
|
11824 - | }
|
11825 - | .into()]
|
10181 + | .auth_scheme(
|
10182 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4", 3)
|
10183 + | .put("disableDoubleEncoding", true)
|
10184 + | .put("signingName", "s3express".to_string())
|
10185 + | .put("signingRegion", "us-east-1".to_string())
|
11826 10186 | )
|
11827 10187 | .property("backend", "S3Express".to_string())
|
11828 10188 | .build()
|
11829 10189 | );
|
11830 10190 | }
|
11831 10191 | }
|
11832 10192 |
|
11833 10193 | /// Endpoint resolver trait specific to Amazon Simple Storage Service
|
11834 10194 | pub trait ResolveEndpoint: ::std::marker::Send + ::std::marker::Sync + ::std::fmt::Debug {
|
11835 10195 | /// Resolve an endpoint with the given parameters
|
11836 10196 | fn resolve_endpoint<'a>(&'a self, params: &'a crate::config::endpoint::Params) -> ::aws_smithy_runtime_api::client::endpoint::EndpointFuture<'a>;
|
11837 10197 |
|
11838 10198 | /// Convert this service-specific resolver into a `SharedEndpointResolver`
|
11839 10199 | ///
|
11840 10200 | /// The resulting resolver will downcast `EndpointResolverParams` into `crate::config::endpoint::Params`.
|
11841 10201 | fn into_shared_resolver(self) -> ::aws_smithy_runtime_api::client::endpoint::SharedEndpointResolver
|
11842 10202 | where
|
11843 10203 | Self: Sized + 'static,
|
11844 10204 | {
|
11845 10205 | ::aws_smithy_runtime_api::client::endpoint::SharedEndpointResolver::new(DowncastParams(self))
|
11846 10206 | }
|
11847 10207 | }
|
11848 10208 |
|
11849 10209 | #[derive(Debug)]
|
11850 10210 | struct DowncastParams<T>(T);
|
11851 10211 | impl<T> ::aws_smithy_runtime_api::client::endpoint::ResolveEndpoint for DowncastParams<T>
|
11852 10212 | where
|
11853 10213 | T: ResolveEndpoint,
|
11854 10214 | {
|
11855 10215 | fn resolve_endpoint<'a>(
|
11856 10216 | &'a self,
|
11857 10217 | params: &'a ::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams,
|
11858 10218 | ) -> ::aws_smithy_runtime_api::client::endpoint::EndpointFuture<'a> {
|
11859 10219 | let ep = match params.get::<crate::config::endpoint::Params>() {
|
11860 10220 | Some(params) => self.0.resolve_endpoint(params),
|
11861 10221 | None => ::aws_smithy_runtime_api::client::endpoint::EndpointFuture::ready(Err("params of expected type was not present".into())),
|
11862 10222 | };
|
11863 10223 | ep
|
11864 10224 | }
|
11865 10225 | }
|
11866 10226 |
|
11867 10227 | #[derive(Debug)]
|
11868 10228 | /// The default endpoint resolver.
|
11869 10229 | pub struct DefaultResolver {
|
11870 10230 | partition_resolver: &'static crate::endpoint_lib::partition::PartitionResolver,
|
10231 + | endpoint_cache: ::arc_swap::ArcSwap<::std::option::Option<(Params, ::aws_smithy_types::endpoint::Endpoint)>>,
|
11871 10232 | }
|
11872 10233 |
|
11873 10234 | impl Default for DefaultResolver {
|
11874 10235 | fn default() -> Self {
|
11875 10236 | Self::new()
|
11876 10237 | }
|
11877 10238 | }
|
11878 10239 |
|
11879 10240 | impl DefaultResolver {
|
11880 10241 | /// Create a new DefaultResolver
|
11881 10242 | pub fn new() -> Self {
|
11882 10243 | Self {
|
11883 10244 | partition_resolver: &crate::endpoint_lib::DEFAULT_PARTITION_RESOLVER,
|
10245 + | endpoint_cache: ::arc_swap::ArcSwap::from_pointee(None),
|
11884 10246 | }
|
11885 10247 | }
|
11886 10248 |
|
11887 - | #[allow(clippy::needless_borrow)]
|
11888 - | pub(crate) fn evaluate_fn(
|
11889 - | &self,
|
11890 - | ) -> impl for<'a> FnMut(&ConditionFn, &'a Params, &mut ConditionContext<'a>, &mut crate::endpoint_lib::diagnostic::DiagnosticCollector) -> bool + '_
|
11891 - | {
|
11892 - | move |cond, params, context, _diagnostic_collector| cond.evaluate(params, context, &self.partition_resolver, _diagnostic_collector)
|
11893 - | }
|
11894 - |
|
11895 - | fn resolve_endpoint<'a>(
|
11896 - | &'a self,
|
11897 - | params: &'a crate::config::endpoint::Params,
|
11898 - | ) -> ::std::result::Result<::aws_smithy_types::endpoint::Endpoint, ::aws_smithy_runtime_api::box_error::BoxError> {
|
11899 - | let mut diagnostic_collector = crate::endpoint_lib::diagnostic::DiagnosticCollector::new();
|
11900 - | let mut condition_context = ConditionContext::default();
|
11901 - | let result = crate::endpoint_lib::bdd_interpreter::evaluate_bdd(
|
11902 - | &NODES,
|
11903 - | &CONDITIONS,
|
11904 - | &RESULTS,
|
11905 - | 521,
|
11906 - | params,
|
11907 - | &mut condition_context,
|
11908 - | &mut diagnostic_collector,
|
11909 - | self.evaluate_fn(),
|
11910 - | );
|
11911 - |
|
11912 - | match result {
|
11913 - | ::std::option::Option::Some(endpoint) => match endpoint.to_endpoint(params, &condition_context) {
|
11914 - | Ok(ep) => Ok(ep),
|
11915 - | Err(err) => Err(Box::new(err)),
|
11916 - | },
|
11917 - | ::std::option::Option::None => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11918 - | "No endpoint rule matched",
|
11919 - | ))),
|
11920 - | }
|
11921 - | }
|
11922 - | }
|
11923 - |
|
11924 - | impl crate::config::endpoint::ResolveEndpoint for DefaultResolver {
|
11925 - | fn resolve_endpoint<'a>(&'a self, params: &'a crate::config::endpoint::Params) -> ::aws_smithy_runtime_api::client::endpoint::EndpointFuture<'a> {
|
11926 - | let result = self.resolve_endpoint(params);
|
11927 - |
|
11928 - | ::aws_smithy_runtime_api::client::endpoint::EndpointFuture::ready(result)
|
11929 - | }
|
11930 - | }
|
11931 - | #[derive(Debug)]
|
11932 - | pub(crate) enum ConditionFn {
|
11933 - | Cond0,
|
11934 - | Cond1,
|
11935 - | Cond2,
|
11936 - | Cond3,
|
11937 - | Cond4,
|
11938 - | Cond5,
|
11939 - | Cond6,
|
11940 - | Cond7,
|
11941 - | Cond8,
|
11942 - | Cond9,
|
11943 - | Cond10,
|
11944 - | Cond11,
|
11945 - | Cond12,
|
11946 - | Cond13,
|
11947 - | Cond14,
|
11948 - | Cond15,
|
11949 - | Cond16,
|
11950 - | Cond17,
|
11951 - | Cond18,
|
11952 - | Cond19,
|
11953 - | Cond20,
|
11954 - | Cond21,
|
11955 - | Cond22,
|
11956 - | Cond23,
|
11957 - | Cond24,
|
11958 - | Cond25,
|
11959 - | Cond26,
|
11960 - | Cond27,
|
11961 - | Cond28,
|
11962 - | Cond29,
|
11963 - | Cond30,
|
11964 - | Cond31,
|
11965 - | Cond32,
|
11966 - | Cond33,
|
11967 - | Cond34,
|
11968 - | Cond35,
|
11969 - | Cond36,
|
11970 - | Cond37,
|
11971 - | Cond38,
|
11972 - | Cond39,
|
11973 - | Cond40,
|
11974 - | Cond41,
|
11975 - | Cond42,
|
11976 - | Cond43,
|
11977 - | Cond44,
|
11978 - | Cond45,
|
11979 - | Cond46,
|
11980 - | Cond47,
|
11981 - | Cond48,
|
11982 - | Cond49,
|
11983 - | Cond50,
|
11984 - | Cond51,
|
11985 - | Cond52,
|
11986 - | Cond53,
|
11987 - | Cond54,
|
11988 - | Cond55,
|
11989 - | Cond56,
|
11990 - | Cond57,
|
11991 - | Cond58,
|
11992 - | Cond59,
|
11993 - | Cond60,
|
11994 - | Cond61,
|
11995 - | Cond62,
|
11996 - | Cond63,
|
11997 - | Cond64,
|
11998 - | Cond65,
|
11999 - | Cond66,
|
12000 - | Cond67,
|
12001 - | Cond68,
|
12002 - | Cond69,
|
12003 - | Cond70,
|
12004 - | Cond71,
|
12005 - | Cond72,
|
12006 - | Cond73,
|
12007 - | Cond74,
|
12008 - | Cond75,
|
12009 - | }
|
12010 - |
|
12011 - | impl ConditionFn {
|
12012 10249 | #[allow(
|
12013 10250 | unused_variables,
|
12014 10251 | unused_parens,
|
12015 10252 | clippy::double_parens,
|
12016 10253 | clippy::useless_conversion,
|
12017 10254 | clippy::bool_comparison,
|
12018 10255 | clippy::comparison_to_empty,
|
12019 10256 | clippy::needless_borrow,
|
12020 - | clippy::useless_asref
|
10257 + | clippy::useless_asref,
|
10258 + | clippy::redundant_closure_call
|
12021 10259 | )]
|
12022 - | fn evaluate<'a>(
|
12023 - | &self,
|
12024 - | params: &'a Params,
|
12025 - | context: &mut ConditionContext<'a>,
|
12026 - | partition_resolver: &'a crate::endpoint_lib::partition::PartitionResolver,
|
12027 - | _diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector,
|
12028 - | ) -> bool {
|
10260 + | fn resolve_endpoint<'a>(
|
10261 + | &'a self,
|
10262 + | params: &'a crate::config::endpoint::Params,
|
10263 + | ) -> ::std::result::Result<::aws_smithy_types::endpoint::Endpoint, ::aws_smithy_runtime_api::box_error::BoxError> {
|
10264 + | let mut _diagnostic_collector = crate::endpoint_lib::diagnostic::DiagnosticCollector::new();
|
10265 + | #[allow(unused_mut)]
|
10266 + | let mut context = ConditionContext::default();
|
10267 + |
|
12029 10268 | // Param bindings
|
12030 10269 | let bucket = ¶ms.bucket;
|
12031 10270 | let region = ¶ms.region;
|
12032 10271 | let use_fips = ¶ms.use_fips;
|
12033 10272 | let use_dual_stack = ¶ms.use_dual_stack;
|
12034 10273 | let endpoint = ¶ms.endpoint;
|
12035 10274 | let force_path_style = ¶ms.force_path_style;
|
12036 10275 | let accelerate = ¶ms.accelerate;
|
12037 10276 | let use_global_endpoint = ¶ms.use_global_endpoint;
|
12038 10277 | let use_object_lambda_endpoint = ¶ms.use_object_lambda_endpoint;
|
12039 10278 | let key = ¶ms.key;
|
12040 10279 | let prefix = ¶ms.prefix;
|
12041 10280 | let copy_source = ¶ms.copy_source;
|
12042 10281 | let disable_access_points = ¶ms.disable_access_points;
|
12043 10282 | let disable_multi_region_access_points = ¶ms.disable_multi_region_access_points;
|
12044 10283 | let use_arn_region = ¶ms.use_arn_region;
|
12045 10284 | let use_s3_express_control_endpoint = ¶ms.use_s3_express_control_endpoint;
|
12046 10285 | let disable_s3_express_session_auth = ¶ms.disable_s3_express_session_auth;
|
12047 10286 |
|
12048 - | // Non-Param references
|
12049 - | let effective_std_region = &mut context.effective_std_region;
|
12050 - | let partition_result = &mut context.partition_result;
|
12051 - | let url = &mut context.url;
|
12052 - | let access_point_suffix = &mut context.access_point_suffix;
|
12053 - | let region_prefix = &mut context.region_prefix;
|
12054 - | let hardware_type = &mut context.hardware_type;
|
12055 - | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12056 - | let s3_e_ds = &mut context.s3_e_ds;
|
12057 - | let s3_e_fips = &mut context.s3_e_fips;
|
12058 - | let s3_e_auth = &mut context.s3_e_auth;
|
12059 - | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12060 - | let bucket_arn = &mut context.bucket_arn;
|
12061 - | let effective_arn_region = &mut context.effective_arn_region;
|
12062 - | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12063 - | let arn_type = &mut context.arn_type;
|
12064 - | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12065 - | let bucket_partition = &mut context.bucket_partition;
|
12066 - | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12067 - | let outpost_type = &mut context.outpost_type;
|
12068 - | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12069 - | match self {
|
12070 - | Self::Cond0 => region.is_some(),
|
12071 - | Self::Cond1 => {
|
12072 - | *effective_std_region = Some(
|
12073 - | crate::endpoint_lib::ite::ite!(
|
12074 - | (region) == &mut Some(("aws-global".into())),
|
12075 - | "us-east-1".to_string(),
|
12076 - | region.clone().expect("Reference already confirmed Some")
|
12077 - | )
|
12078 - | .into(),
|
12079 - | );
|
12080 - | true
|
12081 - | }
|
12082 - | Self::Cond2 => (accelerate) == (&true),
|
12083 - | Self::Cond3 => (use_fips) == (&true),
|
12084 - | Self::Cond4 => endpoint.is_some(),
|
12085 - | Self::Cond5 => (use_dual_stack) == (&true),
|
12086 - | Self::Cond6 => bucket.is_some(),
|
12087 - | Self::Cond7 => {
|
12088 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12089 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12090 - | if let Some(param) = bucket { param } else { return false },
|
12091 - | 0,
|
12092 - | 6,
|
12093 - | true,
|
12094 - | _diagnostic_collector
|
12095 - | ) {
|
12096 - | inner
|
12097 - | } else {
|
12098 - | return false;
|
12099 - | },
|
12100 - | ""
|
12101 - | )) == ("--x-s3")
|
12102 - | }
|
12103 - | Self::Cond8 => {
|
12104 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12105 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12106 - | if let Some(param) = bucket { param } else { return false },
|
12107 - | 0,
|
12108 - | 7,
|
12109 - | true,
|
12110 - | _diagnostic_collector
|
12111 - | ) {
|
12112 - | inner
|
12113 - | } else {
|
12114 - | return false;
|
12115 - | },
|
12116 - | ""
|
12117 - | )) == ("--xa-s3")
|
12118 - | }
|
12119 - | Self::Cond9 => {
|
12120 - | *partition_result = partition_resolver
|
12121 - | .resolve_partition(if let Some(param) = region { param } else { return false }, _diagnostic_collector)
|
12122 - | .map(|inner| inner.into());
|
12123 - | partition_result.is_some()
|
12124 - | }
|
12125 - | Self::Cond10 => {
|
12126 - | *url =
|
12127 - | crate::endpoint_lib::parse_url::parse_url(if let Some(param) = endpoint { param } else { return false }, _diagnostic_collector)
|
12128 - | .map(|inner| inner.into());
|
12129 - | url.is_some()
|
12130 - | }
|
12131 - | Self::Cond11 => {
|
12132 - | *access_point_suffix = crate::endpoint_lib::substring::substring(
|
12133 - | if let Some(param) = bucket { param } else { return false },
|
12134 - | 0,
|
12135 - | 7,
|
12136 - | true,
|
12137 - | _diagnostic_collector,
|
12138 - | )
|
12139 - | .map(|inner| inner.into());
|
12140 - | access_point_suffix.is_some()
|
12141 - | }
|
12142 - | Self::Cond12 => (access_point_suffix) == &mut Some(("--op-s3".into())),
|
12143 - | Self::Cond13 => {
|
12144 - | *region_prefix = crate::endpoint_lib::substring::substring(
|
12145 - | if let Some(param) = bucket { param } else { return false },
|
12146 - | 8,
|
12147 - | 12,
|
12148 - | true,
|
12149 - | _diagnostic_collector,
|
12150 - | )
|
12151 - | .map(|inner| inner.into());
|
12152 - | region_prefix.is_some()
|
12153 - | }
|
12154 - | Self::Cond14 => {
|
12155 - | *hardware_type = crate::endpoint_lib::substring::substring(
|
12156 - | if let Some(param) = bucket { param } else { return false },
|
12157 - | 49,
|
12158 - | 50,
|
12159 - | true,
|
12160 - | _diagnostic_collector,
|
12161 - | )
|
12162 - | .map(|inner| inner.into());
|
12163 - | hardware_type.is_some()
|
12164 - | }
|
12165 - | Self::Cond15 => {
|
12166 - | *outpost_id_ssa_2 = crate::endpoint_lib::substring::substring(
|
12167 - | if let Some(param) = bucket { param } else { return false },
|
12168 - | 32,
|
12169 - | 49,
|
12170 - | true,
|
12171 - | _diagnostic_collector,
|
12172 - | )
|
12173 - | .map(|inner| inner.into());
|
12174 - | outpost_id_ssa_2.is_some()
|
12175 - | }
|
12176 - | Self::Cond16 => {
|
12177 - | (if let Some(inner) = partition_result {
|
12178 - | inner.name()
|
12179 - | } else {
|
12180 - | return false;
|
12181 - | }) == ("aws-cn")
|
12182 - | }
|
12183 - | Self::Cond17 => {
|
12184 - | *s3_e_ds = Some(crate::endpoint_lib::ite::ite!(use_dual_stack, ".dualstack".to_string(), "".to_string()).into());
|
12185 - | true
|
12186 - | }
|
12187 - | Self::Cond18 => {
|
12188 - | *s3_e_fips = Some(crate::endpoint_lib::ite::ite!(use_fips, "-fips".to_string(), "".to_string()).into());
|
12189 - | true
|
12190 - | }
|
12191 - | Self::Cond19 => (force_path_style) == (&true),
|
12192 - | Self::Cond20 => {
|
12193 - | *s3_e_auth = Some(
|
12194 - | crate::endpoint_lib::ite::ite!(
|
12195 - | crate::endpoint_lib::coalesce::coalesce!(*disable_s3_express_session_auth, false),
|
12196 - | "sigv4".to_string(),
|
12197 - | "sigv4-s3express".to_string()
|
12198 - | )
|
12199 - | .into(),
|
12200 - | );
|
12201 - | true
|
12202 - | }
|
12203 - | Self::Cond21 => crate::endpoint_lib::s3::is_virtual_hostable_s3_bucket(
|
12204 - | if let Some(param) = bucket { param } else { return false },
|
12205 - | false,
|
12206 - | _diagnostic_collector,
|
12207 - | ),
|
12208 - | Self::Cond22 => {
|
12209 - | *s3express_availability_zone_id = crate::endpoint_lib::split::split(
|
12210 - | if let Some(param) = bucket { param } else { return false },
|
12211 - | "--",
|
12212 - | 0,
|
12213 - | _diagnostic_collector,
|
12214 - | )
|
12215 - | .get(1)
|
12216 - | .cloned()
|
12217 - | .map(|inner| inner.into());
|
12218 - | s3express_availability_zone_id.is_some()
|
12219 - | }
|
12220 - | Self::Cond23 => crate::endpoint_lib::host::is_valid_host_label(
|
12221 - | if let Some(param) = outpost_id_ssa_2 { param } else { return false },
|
12222 - | false,
|
12223 - | _diagnostic_collector,
|
12224 - | ),
|
12225 - | Self::Cond24 => (crate::endpoint_lib::coalesce::coalesce!(*use_s3_express_control_endpoint, false)) == (true),
|
12226 - | Self::Cond25 => (region_prefix) == &mut Some(("beta".into())),
|
12227 - | Self::Cond26 => crate::endpoint_lib::s3::is_virtual_hostable_s3_bucket(
|
12228 - | if let Some(param) = bucket { param } else { return false },
|
12229 - | true,
|
12230 - | _diagnostic_collector,
|
12231 - | ),
|
12232 - | Self::Cond27 => {
|
12233 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12234 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12235 - | if let Some(param) = bucket { param } else { return false },
|
12236 - | 16,
|
12237 - | 18,
|
12238 - | true,
|
12239 - | _diagnostic_collector
|
12240 - | ) {
|
12241 - | inner
|
12242 - | } else {
|
12243 - | return false;
|
12244 - | },
|
12245 - | ""
|
12246 - | )) == ("--")
|
12247 - | }
|
12248 - | Self::Cond28 => {
|
12249 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12250 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12251 - | if let Some(param) = bucket { param } else { return false },
|
12252 - | 21,
|
12253 - | 23,
|
12254 - | true,
|
12255 - | _diagnostic_collector
|
12256 - | ) {
|
12257 - | inner
|
12258 - | } else {
|
12259 - | return false;
|
12260 - | },
|
12261 - | ""
|
12262 - | )) == ("--")
|
12263 - | }
|
12264 - | Self::Cond29 => (if let Some(inner) = url { inner.scheme() } else { return false }) == ("http"),
|
12265 - | Self::Cond30 => crate::endpoint_lib::host::is_valid_host_label(
|
12266 - | if let Some(param) = region { param } else { return false },
|
12267 - | false,
|
12268 - | _diagnostic_collector,
|
12269 - | ),
|
12270 - | Self::Cond31 => {
|
12271 - | *bucket_arn = crate::endpoint_lib::arn::parse_arn(if let Some(param) = bucket { param } else { return false }, _diagnostic_collector)
|
12272 - | .map(|inner| inner.into());
|
12273 - | bucket_arn.is_some()
|
12274 - | }
|
12275 - | Self::Cond32 => {
|
12276 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12277 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12278 - | if let Some(param) = bucket { param } else { return false },
|
12279 - | 27,
|
12280 - | 29,
|
12281 - | true,
|
12282 - | _diagnostic_collector
|
12283 - | ) {
|
12284 - | inner
|
12285 - | } else {
|
12286 - | return false;
|
12287 - | },
|
12288 - | ""
|
12289 - | )) == ("--")
|
12290 - | }
|
12291 - | Self::Cond33 => {
|
12292 - | *effective_arn_region = Some(
|
12293 - | crate::endpoint_lib::ite::ite!(
|
12294 - | crate::endpoint_lib::coalesce::coalesce!(*use_arn_region, true),
|
12295 - | if let Some(inner) = bucket_arn { inner.region() } else { return false }.to_string(),
|
12296 - | region.clone().expect("Reference already confirmed Some")
|
12297 - | )
|
12298 - | .into(),
|
12299 - | );
|
12300 - | true
|
12301 - | }
|
12302 - | Self::Cond34 => (if let Some(inner) = url { inner.is_ip() } else { return false }) == (true),
|
12303 - | Self::Cond35 => {
|
12304 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12305 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12306 - | if let Some(param) = bucket { param } else { return false },
|
12307 - | 0,
|
12308 - | 4,
|
12309 - | false,
|
12310 - | _diagnostic_collector
|
12311 - | ) {
|
12312 - | inner
|
12313 - | } else {
|
12314 - | return false;
|
12315 - | },
|
12316 - | ""
|
12317 - | )) == ("arn:")
|
12318 - | }
|
12319 - | Self::Cond36 => {
|
12320 - | *uri_encoded_bucket = Some(
|
12321 - | crate::endpoint_lib::uri_encode::uri_encode(if let Some(param) = bucket { param } else { return false }, _diagnostic_collector)
|
12322 - | .into(),
|
12323 - | );
|
12324 - | true
|
12325 - | }
|
12326 - | Self::Cond37 => (crate::endpoint_lib::coalesce::coalesce!(*use_object_lambda_endpoint, false)) == (true),
|
12327 - | Self::Cond38 => {
|
12328 - | *arn_type = if let Some(inner) = bucket_arn {
|
12329 - | inner.resource_id().first().cloned()
|
12330 - | } else {
|
12331 - | return false;
|
12332 - | }
|
12333 - | .map(|inner| inner.into());
|
12334 - | arn_type.is_some()
|
12335 - | }
|
12336 - | Self::Cond39 => (arn_type) == &mut Some(("".into())),
|
12337 - | Self::Cond40 => (arn_type) == &mut Some(("accesspoint".into())),
|
12338 - | Self::Cond41 => {
|
12339 - | *access_point_name_ssa_1 = if let Some(inner) = bucket_arn {
|
12340 - | inner.resource_id().get(1).cloned()
|
12341 - | } else {
|
12342 - | return false;
|
12343 - | }
|
12344 - | .map(|inner| inner.into());
|
12345 - | access_point_name_ssa_1.is_some()
|
12346 - | }
|
12347 - | Self::Cond42 => (access_point_name_ssa_1) == &mut Some(("".into())),
|
12348 - | Self::Cond43 => (if let Some(inner) = bucket_arn { inner.service() } else { return false }) == ("s3-object-lambda"),
|
12349 - | Self::Cond44 => crate::endpoint_lib::host::is_valid_host_label(
|
12350 - | if let Some(param) = region { param } else { return false },
|
12351 - | true,
|
12352 - | _diagnostic_collector,
|
12353 - | ),
|
12354 - | Self::Cond45 => (if let Some(inner) = bucket_arn { inner.region() } else { return false }) == (""),
|
12355 - | Self::Cond46 => (hardware_type) == &mut Some(("e".into())),
|
12356 - | Self::Cond47 => {
|
12357 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12358 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12359 - | if let Some(param) = bucket { param } else { return false },
|
12360 - | 26,
|
12361 - | 28,
|
12362 - | true,
|
12363 - | _diagnostic_collector
|
12364 - | ) {
|
12365 - | inner
|
12366 - | } else {
|
12367 - | return false;
|
12368 - | },
|
12369 - | ""
|
12370 - | )) == ("--")
|
12371 - | }
|
12372 - | Self::Cond48 => {
|
12373 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12374 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12375 - | if let Some(param) = bucket { param } else { return false },
|
12376 - | 19,
|
12377 - | 21,
|
12378 - | true,
|
12379 - | _diagnostic_collector
|
12380 - | ) {
|
12381 - | inner
|
12382 - | } else {
|
12383 - | return false;
|
12384 - | },
|
12385 - | ""
|
12386 - | )) == ("--")
|
12387 - | }
|
12388 - | Self::Cond49 => {
|
12389 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12390 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12391 - | if let Some(param) = bucket { param } else { return false },
|
12392 - | 14,
|
12393 - | 16,
|
12394 - | true,
|
12395 - | _diagnostic_collector
|
12396 - | ) {
|
12397 - | inner
|
12398 - | } else {
|
12399 - | return false;
|
12400 - | },
|
12401 - | ""
|
12402 - | )) == ("--")
|
12403 - | }
|
12404 - | Self::Cond50 => {
|
12405 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12406 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12407 - | if let Some(param) = bucket { param } else { return false },
|
12408 - | 20,
|
12409 - | 22,
|
12410 - | true,
|
12411 - | _diagnostic_collector
|
12412 - | ) {
|
12413 - | inner
|
12414 - | } else {
|
12415 - | return false;
|
12416 - | },
|
12417 - | ""
|
12418 - | )) == ("--")
|
12419 - | }
|
12420 - | Self::Cond51 => {
|
12421 - | (crate::endpoint_lib::coalesce::coalesce!(
|
12422 - | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12423 - | if let Some(param) = bucket { param } else { return false },
|
12424 - | 15,
|
12425 - | 17,
|
12426 - | true,
|
12427 - | _diagnostic_collector
|
12428 - | ) {
|
12429 - | inner
|
12430 - | } else {
|
12431 - | return false;
|
12432 - | },
|
12433 - | ""
|
12434 - | )) == ("--")
|
12435 - | }
|
12436 - | Self::Cond52 => (if let Some(inner) = bucket_arn { inner.service() } else { return false }) == ("s3-outposts"),
|
12437 - | Self::Cond53 => (crate::endpoint_lib::coalesce::coalesce!(*disable_access_points, false)) == (true),
|
12438 - | Self::Cond54 => {
|
12439 - | *bucket_partition = partition_resolver
|
12440 - | .resolve_partition(
|
12441 - | if let Some(param) = effective_arn_region { param } else { return false },
|
12442 - | _diagnostic_collector,
|
12443 - | )
|
12444 - | .map(|inner| inner.into());
|
12445 - | bucket_partition.is_some()
|
12446 - | }
|
12447 - | Self::Cond55 => (hardware_type) == &mut Some(("o".into())),
|
12448 - | Self::Cond56 => if let Some(inner) = bucket_arn {
|
12449 - | inner.resource_id().get(4).cloned()
|
12450 - | } else {
|
12451 - | return false;
|
12452 - | }
|
12453 - | .is_some(),
|
12454 - | Self::Cond57 => {
|
12455 - | *outpost_id_ssa_1 = if let Some(inner) = bucket_arn {
|
12456 - | inner.resource_id().get(1).cloned()
|
12457 - | } else {
|
12458 - | return false;
|
12459 - | }
|
12460 - | .map(|inner| inner.into());
|
12461 - | outpost_id_ssa_1.is_some()
|
12462 - | }
|
12463 - | Self::Cond58 => (crate::endpoint_lib::coalesce::coalesce!(*use_arn_region, true)) == (true),
|
12464 - | Self::Cond59 => (effective_arn_region) == &mut Some((if let Some(inner) = bucket_arn { inner.region() } else { return false }.into())),
|
12465 - | Self::Cond60 => (region) == &mut Some(("aws-global".into())),
|
12466 - | Self::Cond61 => (use_global_endpoint) == (&true),
|
12467 - | Self::Cond62 => (disable_multi_region_access_points) == (&true),
|
12468 - | Self::Cond63 => (region) == &mut Some(("us-east-1".into())),
|
12469 - | Self::Cond64 => crate::endpoint_lib::host::is_valid_host_label(
|
12470 - | if let Some(param) = outpost_id_ssa_1 { param } else { return false },
|
12471 - | false,
|
12472 - | _diagnostic_collector,
|
12473 - | ),
|
12474 - | Self::Cond65 => {
|
12475 - | *outpost_type = if let Some(inner) = bucket_arn {
|
12476 - | inner.resource_id().get(2).cloned()
|
12477 - | } else {
|
12478 - | return false;
|
12479 - | }
|
12480 - | .map(|inner| inner.into());
|
12481 - | outpost_type.is_some()
|
12482 - | }
|
12483 - | Self::Cond66 => {
|
12484 - | (if let Some(inner) = bucket_partition {
|
12485 - | inner.name()
|
12486 - | } else {
|
12487 - | return false;
|
12488 - | }) == (if let Some(inner) = partition_result {
|
12489 - | inner.name()
|
12490 - | } else {
|
12491 - | return false;
|
12492 - | })
|
12493 - | }
|
12494 - | Self::Cond67 => crate::endpoint_lib::host::is_valid_host_label(
|
12495 - | if let Some(param) = effective_arn_region { param } else { return false },
|
12496 - | true,
|
12497 - | _diagnostic_collector,
|
12498 - | ),
|
12499 - | Self::Cond68 => (if let Some(inner) = bucket_arn { inner.service() } else { return false }) == ("s3"),
|
12500 - | Self::Cond69 => {
|
12501 - | (if let Some(inner) = bucket_arn {
|
12502 - | inner.account_id()
|
12503 - | } else {
|
12504 - | return false;
|
12505 - | }) == ("")
|
12506 - | }
|
12507 - | Self::Cond70 => crate::endpoint_lib::host::is_valid_host_label(
|
12508 - | if let Some(inner) = bucket_arn {
|
12509 - | inner.account_id()
|
12510 - | } else {
|
12511 - | return false;
|
12512 - | },
|
12513 - | false,
|
12514 - | _diagnostic_collector,
|
12515 - | ),
|
12516 - | Self::Cond71 => crate::endpoint_lib::host::is_valid_host_label(
|
12517 - | if let Some(param) = access_point_name_ssa_1 {
|
12518 - | param
|
12519 - | } else {
|
12520 - | return false;
|
12521 - | },
|
12522 - | false,
|
12523 - | _diagnostic_collector,
|
12524 - | ),
|
12525 - | Self::Cond72 => {
|
12526 - | *access_point_name_ssa_2 = if let Some(inner) = bucket_arn {
|
12527 - | inner.resource_id().get(3).cloned()
|
12528 - | } else {
|
12529 - | return false;
|
12530 - | }
|
12531 - | .map(|inner| inner.into());
|
12532 - | access_point_name_ssa_2.is_some()
|
12533 - | }
|
12534 - | Self::Cond73 => crate::endpoint_lib::host::is_valid_host_label(
|
12535 - | if let Some(param) = access_point_name_ssa_1 {
|
12536 - | param
|
12537 - | } else {
|
12538 - | return false;
|
12539 - | },
|
12540 - | true,
|
12541 - | _diagnostic_collector,
|
12542 - | ),
|
12543 - | Self::Cond74 => {
|
12544 - | (if let Some(inner) = bucket_arn { inner.partition() } else { return false })
|
12545 - | == (if let Some(inner) = partition_result {
|
12546 - | inner.name()
|
12547 - | } else {
|
12548 - | return false;
|
12549 - | })
|
12550 - | }
|
12551 - | Self::Cond75 => (outpost_type) == &mut Some(("accesspoint".into())),
|
12552 - | }
|
12553 - | }
|
12554 - | }
|
12555 - |
|
12556 - | const CONDITIONS: [ConditionFn; 76] = [
|
12557 - | ConditionFn::Cond0,
|
12558 - | ConditionFn::Cond1,
|
12559 - | ConditionFn::Cond2,
|
12560 - | ConditionFn::Cond3,
|
12561 - | ConditionFn::Cond4,
|
12562 - | ConditionFn::Cond5,
|
12563 - | ConditionFn::Cond6,
|
12564 - | ConditionFn::Cond7,
|
12565 - | ConditionFn::Cond8,
|
12566 - | ConditionFn::Cond9,
|
12567 - | ConditionFn::Cond10,
|
12568 - | ConditionFn::Cond11,
|
12569 - | ConditionFn::Cond12,
|
12570 - | ConditionFn::Cond13,
|
12571 - | ConditionFn::Cond14,
|
12572 - | ConditionFn::Cond15,
|
12573 - | ConditionFn::Cond16,
|
12574 - | ConditionFn::Cond17,
|
12575 - | ConditionFn::Cond18,
|
12576 - | ConditionFn::Cond19,
|
12577 - | ConditionFn::Cond20,
|
12578 - | ConditionFn::Cond21,
|
12579 - | ConditionFn::Cond22,
|
12580 - | ConditionFn::Cond23,
|
12581 - | ConditionFn::Cond24,
|
12582 - | ConditionFn::Cond25,
|
12583 - | ConditionFn::Cond26,
|
12584 - | ConditionFn::Cond27,
|
12585 - | ConditionFn::Cond28,
|
12586 - | ConditionFn::Cond29,
|
12587 - | ConditionFn::Cond30,
|
12588 - | ConditionFn::Cond31,
|
12589 - | ConditionFn::Cond32,
|
12590 - | ConditionFn::Cond33,
|
12591 - | ConditionFn::Cond34,
|
12592 - | ConditionFn::Cond35,
|
12593 - | ConditionFn::Cond36,
|
12594 - | ConditionFn::Cond37,
|
12595 - | ConditionFn::Cond38,
|
12596 - | ConditionFn::Cond39,
|
12597 - | ConditionFn::Cond40,
|
12598 - | ConditionFn::Cond41,
|
12599 - | ConditionFn::Cond42,
|
12600 - | ConditionFn::Cond43,
|
12601 - | ConditionFn::Cond44,
|
12602 - | ConditionFn::Cond45,
|
12603 - | ConditionFn::Cond46,
|
12604 - | ConditionFn::Cond47,
|
12605 - | ConditionFn::Cond48,
|
12606 - | ConditionFn::Cond49,
|
12607 - | ConditionFn::Cond50,
|
12608 - | ConditionFn::Cond51,
|
12609 - | ConditionFn::Cond52,
|
12610 - | ConditionFn::Cond53,
|
12611 - | ConditionFn::Cond54,
|
12612 - | ConditionFn::Cond55,
|
12613 - | ConditionFn::Cond56,
|
12614 - | ConditionFn::Cond57,
|
12615 - | ConditionFn::Cond58,
|
12616 - | ConditionFn::Cond59,
|
12617 - | ConditionFn::Cond60,
|
12618 - | ConditionFn::Cond61,
|
12619 - | ConditionFn::Cond62,
|
12620 - | ConditionFn::Cond63,
|
12621 - | ConditionFn::Cond64,
|
12622 - | ConditionFn::Cond65,
|
12623 - | ConditionFn::Cond66,
|
12624 - | ConditionFn::Cond67,
|
12625 - | ConditionFn::Cond68,
|
12626 - | ConditionFn::Cond69,
|
12627 - | ConditionFn::Cond70,
|
12628 - | ConditionFn::Cond71,
|
12629 - | ConditionFn::Cond72,
|
12630 - | ConditionFn::Cond73,
|
12631 - | ConditionFn::Cond74,
|
12632 - | ConditionFn::Cond75,
|
12633 - | ];
|
12634 - | #[derive(Debug, Clone)]
|
12635 - | enum ResultEndpoint {
|
12636 - | Result0,
|
12637 - | Result1,
|
12638 - | Result2,
|
12639 - | Result3,
|
12640 - | Result4,
|
12641 - | Result5,
|
12642 - | Result6,
|
12643 - | Result7,
|
12644 - | Result8,
|
12645 - | Result9,
|
12646 - | Result10,
|
12647 - | Result11,
|
12648 - | Result12,
|
12649 - | Result13,
|
12650 - | Result14,
|
12651 - | Result15,
|
12652 - | Result16,
|
12653 - | Result17,
|
12654 - | Result18,
|
12655 - | Result19,
|
12656 - | Result20,
|
12657 - | Result21,
|
12658 - | Result22,
|
12659 - | Result23,
|
12660 - | Result24,
|
12661 - | Result25,
|
12662 - | Result26,
|
12663 - | Result27,
|
12664 - | Result28,
|
12665 - | Result29,
|
12666 - | Result30,
|
12667 - | Result31,
|
12668 - | Result32,
|
12669 - | Result33,
|
12670 - | Result34,
|
12671 - | Result35,
|
12672 - | Result36,
|
12673 - | Result37,
|
12674 - | Result38,
|
12675 - | Result39,
|
12676 - | Result40,
|
12677 - | Result41,
|
12678 - | Result42,
|
12679 - | Result43,
|
12680 - | Result44,
|
12681 - | Result45,
|
12682 - | Result46,
|
12683 - | Result47,
|
12684 - | Result48,
|
12685 - | Result49,
|
12686 - | Result50,
|
12687 - | Result51,
|
12688 - | Result52,
|
12689 - | Result53,
|
12690 - | Result54,
|
12691 - | Result55,
|
12692 - | Result56,
|
12693 - | Result57,
|
12694 - | Result58,
|
12695 - | Result59,
|
12696 - | Result60,
|
12697 - | Result61,
|
12698 - | Result62,
|
12699 - | Result63,
|
12700 - | Result64,
|
12701 - | Result65,
|
12702 - | Result66,
|
12703 - | Result67,
|
12704 - | Result68,
|
12705 - | Result69,
|
12706 - | Result70,
|
12707 - | Result71,
|
12708 - | Result72,
|
12709 - | Result73,
|
12710 - | Result74,
|
12711 - | Result75,
|
12712 - | Result76,
|
12713 - | Result77,
|
12714 - | Result78,
|
12715 - | Result79,
|
12716 - | Result80,
|
12717 - | Result81,
|
12718 - | Result82,
|
12719 - | Result83,
|
12720 - | Result84,
|
12721 - | Result85,
|
12722 - | Result86,
|
12723 - | Result87,
|
12724 - | Result88,
|
12725 - | Result89,
|
12726 - | Result90,
|
12727 - | Result91,
|
12728 - | Result92,
|
12729 - | Result93,
|
12730 - | Result94,
|
12731 - | Result95,
|
12732 - | Result96,
|
12733 - | }
|
12734 - |
|
12735 - | impl<'a> ResultEndpoint {
|
12736 - | #[allow(unused_variables, clippy::useless_asref)]
|
12737 - | fn to_endpoint(
|
12738 - | &self,
|
12739 - | params: &'a Params,
|
12740 - | context: &ConditionContext<'a>,
|
12741 - | ) -> ::std::result::Result<::aws_smithy_types::endpoint::Endpoint, ::aws_smithy_http::endpoint::ResolveEndpointError> {
|
12742 - | match self {
|
12743 - | Self::Result0 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message("No endpoint rule matched")),
|
12744 - | Self::Result1 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12745 - | "Accelerate cannot be used with FIPS".to_string(),
|
12746 - | )),
|
12747 - | Self::Result2 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12748 - | "Cannot set dual-stack in combination with a custom endpoint.".to_string(),
|
12749 - | )),
|
12750 - | Self::Result3 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12751 - | "A custom endpoint cannot be combined with FIPS".to_string(),
|
12752 - | )),
|
12753 - | Self::Result4 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12754 - | "A custom endpoint cannot be combined with S3 Accelerate".to_string(),
|
12755 - | )),
|
12756 - | Self::Result5 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12757 - | "Partition does not support FIPS".to_string(),
|
12758 - | )),
|
12759 - | Self::Result6 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12760 - | "S3Express does not support S3 Accelerate.".to_string(),
|
12761 - | )),
|
12762 - | Self::Result7 => {
|
12763 - | let effective_std_region = context
|
12764 - | .effective_std_region
|
12765 - | .as_ref()
|
12766 - | .map(|s| s.clone())
|
12767 - | .expect("Guaranteed to have a value by earlier checks.");
|
12768 - | let url = context
|
12769 - | .url
|
12770 - | .as_ref()
|
12771 - | .map(|s| s.clone())
|
12772 - | .expect("Guaranteed to have a value by earlier checks.");
|
12773 - | let s3_e_auth = context
|
12774 - | .s3_e_auth
|
12775 - | .as_ref()
|
12776 - | .map(|s| s.clone())
|
12777 - | .expect("Guaranteed to have a value by earlier checks.");
|
12778 - | let uri_encoded_bucket = context
|
12779 - | .uri_encoded_bucket
|
12780 - | .as_ref()
|
12781 - | .map(|s| s.clone())
|
12782 - | .expect("Guaranteed to have a value by earlier checks.");
|
12783 - | ::std::result::Result::Ok(
|
12784 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
12785 - | .url({
|
12786 - | let mut out = String::new();
|
12787 - | #[allow(clippy::needless_borrow)]
|
12788 - | out.push_str(&url.scheme());
|
12789 - | out.push_str("://");
|
12790 - | #[allow(clippy::needless_borrow)]
|
12791 - | out.push_str(&url.authority());
|
12792 - | out.push('/');
|
12793 - | #[allow(clippy::needless_borrow)]
|
12794 - | out.push_str(&uri_encoded_bucket.as_ref());
|
12795 - | #[allow(clippy::needless_borrow)]
|
12796 - | out.push_str(&url.path());
|
12797 - | out
|
12798 - | })
|
12799 - | .property("backend", "S3Express".to_string())
|
12800 - | .property(
|
12801 - | "authSchemes",
|
12802 - | vec![::aws_smithy_types::Document::from({
|
12803 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
12804 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
12805 - | out.insert("name".to_string(), s3_e_auth.to_owned().into());
|
12806 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
12807 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
12808 - | out
|
12809 - | })],
|
12810 - | )
|
12811 - | .build(),
|
12812 - | )
|
12813 - | }
|
12814 - | Self::Result8 => {
|
12815 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
12816 - | let effective_std_region = context
|
12817 - | .effective_std_region
|
12818 - | .as_ref()
|
12819 - | .map(|s| s.clone())
|
12820 - | .expect("Guaranteed to have a value by earlier checks.");
|
12821 - | let url = context
|
12822 - | .url
|
12823 - | .as_ref()
|
12824 - | .map(|s| s.clone())
|
12825 - | .expect("Guaranteed to have a value by earlier checks.");
|
12826 - | let s3_e_auth = context
|
12827 - | .s3_e_auth
|
12828 - | .as_ref()
|
12829 - | .map(|s| s.clone())
|
12830 - | .expect("Guaranteed to have a value by earlier checks.");
|
12831 - | ::std::result::Result::Ok(
|
12832 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
12833 - | .url({
|
12834 - | let mut out = String::new();
|
12835 - | #[allow(clippy::needless_borrow)]
|
12836 - | out.push_str(&url.scheme());
|
12837 - | out.push_str("://");
|
12838 - | #[allow(clippy::needless_borrow)]
|
12839 - | out.push_str(&bucket.as_ref());
|
12840 - | out.push('.');
|
12841 - | #[allow(clippy::needless_borrow)]
|
12842 - | out.push_str(&url.authority());
|
12843 - | #[allow(clippy::needless_borrow)]
|
12844 - | out.push_str(&url.path());
|
12845 - | out
|
12846 - | })
|
12847 - | .property("backend", "S3Express".to_string())
|
12848 - | .property(
|
12849 - | "authSchemes",
|
12850 - | vec![::aws_smithy_types::Document::from({
|
12851 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
12852 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
12853 - | out.insert("name".to_string(), s3_e_auth.to_owned().into());
|
12854 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
12855 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
12856 - | out
|
12857 - | })],
|
12858 - | )
|
12859 - | .build(),
|
12860 - | )
|
12861 - | }
|
12862 - | Self::Result9 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12863 - | "S3Express bucket name is not a valid virtual hostable name.".to_string(),
|
12864 - | )),
|
12865 - | Self::Result10 => {
|
12866 - | let effective_std_region = context
|
12867 - | .effective_std_region
|
12868 - | .as_ref()
|
12869 - | .map(|s| s.clone())
|
12870 - | .expect("Guaranteed to have a value by earlier checks.");
|
12871 - | let partition_result = context
|
12872 - | .partition_result
|
12873 - | .as_ref()
|
12874 - | .map(|s| s.clone())
|
12875 - | .expect("Guaranteed to have a value by earlier checks.");
|
12876 - | let s3_e_ds = context
|
12877 - | .s3_e_ds
|
12878 - | .as_ref()
|
12879 - | .map(|s| s.clone())
|
12880 - | .expect("Guaranteed to have a value by earlier checks.");
|
12881 - | let s3_e_fips = context
|
12882 - | .s3_e_fips
|
12883 - | .as_ref()
|
12884 - | .map(|s| s.clone())
|
12885 - | .expect("Guaranteed to have a value by earlier checks.");
|
12886 - | let uri_encoded_bucket = context
|
12887 - | .uri_encoded_bucket
|
12888 - | .as_ref()
|
12889 - | .map(|s| s.clone())
|
12890 - | .expect("Guaranteed to have a value by earlier checks.");
|
12891 - | ::std::result::Result::Ok(
|
12892 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
12893 - | .url({
|
12894 - | let mut out = String::new();
|
12895 - | out.push_str("https://s3express-control");
|
12896 - | #[allow(clippy::needless_borrow)]
|
12897 - | out.push_str(&s3_e_fips.as_ref());
|
12898 - | #[allow(clippy::needless_borrow)]
|
12899 - | out.push_str(&s3_e_ds.as_ref());
|
12900 - | out.push('.');
|
12901 - | #[allow(clippy::needless_borrow)]
|
12902 - | out.push_str(&effective_std_region.as_ref());
|
12903 - | out.push('.');
|
12904 - | #[allow(clippy::needless_borrow)]
|
12905 - | out.push_str(&partition_result.dns_suffix());
|
12906 - | out.push('/');
|
12907 - | #[allow(clippy::needless_borrow)]
|
12908 - | out.push_str(&uri_encoded_bucket.as_ref());
|
12909 - | out
|
12910 - | })
|
12911 - | .property("backend", "S3Express".to_string())
|
12912 - | .property(
|
12913 - | "authSchemes",
|
12914 - | vec![::aws_smithy_types::Document::from({
|
12915 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
12916 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
12917 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
12918 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
12919 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
12920 - | out
|
12921 - | })],
|
12922 - | )
|
12923 - | .build(),
|
12924 - | )
|
12925 - | }
|
12926 - | Self::Result11 => {
|
12927 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
12928 - | let effective_std_region = context
|
12929 - | .effective_std_region
|
12930 - | .as_ref()
|
12931 - | .map(|s| s.clone())
|
12932 - | .expect("Guaranteed to have a value by earlier checks.");
|
12933 - | let partition_result = context
|
12934 - | .partition_result
|
12935 - | .as_ref()
|
12936 - | .map(|s| s.clone())
|
12937 - | .expect("Guaranteed to have a value by earlier checks.");
|
12938 - | let s3_e_ds = context
|
12939 - | .s3_e_ds
|
12940 - | .as_ref()
|
12941 - | .map(|s| s.clone())
|
12942 - | .expect("Guaranteed to have a value by earlier checks.");
|
12943 - | let s3_e_fips = context
|
12944 - | .s3_e_fips
|
12945 - | .as_ref()
|
12946 - | .map(|s| s.clone())
|
12947 - | .expect("Guaranteed to have a value by earlier checks.");
|
12948 - | let s3_e_auth = context
|
12949 - | .s3_e_auth
|
12950 - | .as_ref()
|
12951 - | .map(|s| s.clone())
|
12952 - | .expect("Guaranteed to have a value by earlier checks.");
|
12953 - | let s3express_availability_zone_id = context
|
12954 - | .s3express_availability_zone_id
|
12955 - | .as_ref()
|
12956 - | .map(|s| s.clone())
|
12957 - | .expect("Guaranteed to have a value by earlier checks.");
|
12958 - | ::std::result::Result::Ok(
|
12959 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
12960 - | .url({
|
12961 - | let mut out = String::new();
|
12962 - | out.push_str("https://");
|
12963 - | #[allow(clippy::needless_borrow)]
|
12964 - | out.push_str(&bucket.as_ref());
|
12965 - | out.push_str(".s3express");
|
12966 - | #[allow(clippy::needless_borrow)]
|
12967 - | out.push_str(&s3_e_fips.as_ref());
|
12968 - | out.push('-');
|
12969 - | #[allow(clippy::needless_borrow)]
|
12970 - | out.push_str(&s3express_availability_zone_id.as_ref());
|
12971 - | #[allow(clippy::needless_borrow)]
|
12972 - | out.push_str(&s3_e_ds.as_ref());
|
12973 - | out.push('.');
|
12974 - | #[allow(clippy::needless_borrow)]
|
12975 - | out.push_str(&effective_std_region.as_ref());
|
12976 - | out.push('.');
|
12977 - | #[allow(clippy::needless_borrow)]
|
12978 - | out.push_str(&partition_result.dns_suffix());
|
12979 - | out
|
12980 - | })
|
12981 - | .property("backend", "S3Express".to_string())
|
12982 - | .property(
|
12983 - | "authSchemes",
|
12984 - | vec![::aws_smithy_types::Document::from({
|
12985 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
12986 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
12987 - | out.insert("name".to_string(), s3_e_auth.to_owned().into());
|
12988 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
12989 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
12990 - | out
|
12991 - | })],
|
12992 - | )
|
12993 - | .build(),
|
12994 - | )
|
12995 - | }
|
12996 - | Self::Result12 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12997 - | "Unrecognized S3Express bucket name format.".to_string(),
|
12998 - | )),
|
12999 - | Self::Result13 => {
|
13000 - | let effective_std_region = context
|
13001 - | .effective_std_region
|
13002 - | .as_ref()
|
13003 - | .map(|s| s.clone())
|
13004 - | .expect("Guaranteed to have a value by earlier checks.");
|
13005 - | let url = context
|
13006 - | .url
|
13007 - | .as_ref()
|
13008 - | .map(|s| s.clone())
|
13009 - | .expect("Guaranteed to have a value by earlier checks.");
|
13010 - | let s3_e_auth = context
|
13011 - | .s3_e_auth
|
13012 - | .as_ref()
|
13013 - | .map(|s| s.clone())
|
13014 - | .expect("Guaranteed to have a value by earlier checks.");
|
13015 - | ::std::result::Result::Ok(
|
13016 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13017 - | .url({
|
13018 - | let mut out = String::new();
|
13019 - | #[allow(clippy::needless_borrow)]
|
13020 - | out.push_str(&url.scheme());
|
13021 - | out.push_str("://");
|
13022 - | #[allow(clippy::needless_borrow)]
|
13023 - | out.push_str(&url.authority());
|
13024 - | #[allow(clippy::needless_borrow)]
|
13025 - | out.push_str(&url.path());
|
13026 - | out
|
13027 - | })
|
13028 - | .property("backend", "S3Express".to_string())
|
13029 - | .property(
|
13030 - | "authSchemes",
|
13031 - | vec![::aws_smithy_types::Document::from({
|
13032 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13033 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13034 - | out.insert("name".to_string(), s3_e_auth.to_owned().into());
|
13035 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
13036 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13037 - | out
|
13038 - | })],
|
13039 - | )
|
13040 - | .build(),
|
13041 - | )
|
13042 - | }
|
13043 - | Self::Result14 => {
|
13044 - | let effective_std_region = context
|
13045 - | .effective_std_region
|
13046 - | .as_ref()
|
13047 - | .map(|s| s.clone())
|
13048 - | .expect("Guaranteed to have a value by earlier checks.");
|
13049 - | let partition_result = context
|
13050 - | .partition_result
|
13051 - | .as_ref()
|
13052 - | .map(|s| s.clone())
|
13053 - | .expect("Guaranteed to have a value by earlier checks.");
|
13054 - | let s3_e_ds = context
|
13055 - | .s3_e_ds
|
13056 - | .as_ref()
|
13057 - | .map(|s| s.clone())
|
13058 - | .expect("Guaranteed to have a value by earlier checks.");
|
13059 - | let s3_e_fips = context
|
13060 - | .s3_e_fips
|
13061 - | .as_ref()
|
13062 - | .map(|s| s.clone())
|
13063 - | .expect("Guaranteed to have a value by earlier checks.");
|
13064 - | ::std::result::Result::Ok(
|
13065 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13066 - | .url({
|
13067 - | let mut out = String::new();
|
13068 - | out.push_str("https://s3express-control");
|
13069 - | #[allow(clippy::needless_borrow)]
|
13070 - | out.push_str(&s3_e_fips.as_ref());
|
13071 - | #[allow(clippy::needless_borrow)]
|
13072 - | out.push_str(&s3_e_ds.as_ref());
|
13073 - | out.push('.');
|
13074 - | #[allow(clippy::needless_borrow)]
|
13075 - | out.push_str(&effective_std_region.as_ref());
|
13076 - | out.push('.');
|
13077 - | #[allow(clippy::needless_borrow)]
|
13078 - | out.push_str(&partition_result.dns_suffix());
|
13079 - | out
|
13080 - | })
|
13081 - | .property("backend", "S3Express".to_string())
|
13082 - | .property(
|
13083 - | "authSchemes",
|
13084 - | vec![::aws_smithy_types::Document::from({
|
13085 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13086 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13087 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13088 - | out.insert("signingName".to_string(), "s3express".to_string().into());
|
13089 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13090 - | out
|
13091 - | })],
|
13092 - | )
|
13093 - | .build(),
|
13094 - | )
|
13095 - | }
|
13096 - | Self::Result15 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
13097 - | "Expected a endpoint to be specified but no endpoint was found".to_string(),
|
13098 - | )),
|
13099 - | Self::Result16 => {
|
13100 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13101 - | let effective_std_region = context
|
13102 - | .effective_std_region
|
13103 - | .as_ref()
|
13104 - | .map(|s| s.clone())
|
13105 - | .expect("Guaranteed to have a value by earlier checks.");
|
13106 - | let url = context
|
13107 - | .url
|
13108 - | .as_ref()
|
13109 - | .map(|s| s.clone())
|
13110 - | .expect("Guaranteed to have a value by earlier checks.");
|
13111 - | ::std::result::Result::Ok(
|
13112 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13113 - | .url({
|
13114 - | let mut out = String::new();
|
13115 - | out.push_str("https://");
|
13116 - | #[allow(clippy::needless_borrow)]
|
13117 - | out.push_str(&bucket.as_ref());
|
13118 - | out.push_str(".ec2.");
|
13119 - | #[allow(clippy::needless_borrow)]
|
13120 - | out.push_str(&url.authority());
|
13121 - | out
|
13122 - | })
|
13123 - | .property(
|
13124 - | "authSchemes",
|
13125 - | vec![
|
13126 - | ::aws_smithy_types::Document::from({
|
13127 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13128 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13129 - | out.insert("name".to_string(), "sigv4a".to_string().into());
|
13130 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
13131 - | out.insert(
|
13132 - | "signingRegionSet".to_string(),
|
13133 - | vec![::aws_smithy_types::Document::from("*".to_string())].into(),
|
13134 - | );
|
13135 - | out
|
13136 - | }),
|
13137 - | ::aws_smithy_types::Document::from({
|
13138 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13139 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13140 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13141 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
13142 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13143 - | out
|
13144 - | }),
|
13145 - | ],
|
13146 - | )
|
13147 - | .build(),
|
13148 - | )
|
13149 - | }
|
13150 - | Self::Result17 => {
|
13151 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13152 - | let effective_std_region = context
|
13153 - | .effective_std_region
|
13154 - | .as_ref()
|
13155 - | .map(|s| s.clone())
|
13156 - | .expect("Guaranteed to have a value by earlier checks.");
|
13157 - | let partition_result = context
|
13158 - | .partition_result
|
13159 - | .as_ref()
|
13160 - | .map(|s| s.clone())
|
13161 - | .expect("Guaranteed to have a value by earlier checks.");
|
13162 - | ::std::result::Result::Ok(
|
13163 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13164 - | .url({
|
13165 - | let mut out = String::new();
|
13166 - | out.push_str("https://");
|
13167 - | #[allow(clippy::needless_borrow)]
|
13168 - | out.push_str(&bucket.as_ref());
|
13169 - | out.push_str(".ec2.s3-outposts.");
|
13170 - | #[allow(clippy::needless_borrow)]
|
13171 - | out.push_str(&effective_std_region.as_ref());
|
13172 - | out.push('.');
|
13173 - | #[allow(clippy::needless_borrow)]
|
13174 - | out.push_str(&partition_result.dns_suffix());
|
13175 - | out
|
13176 - | })
|
13177 - | .property(
|
13178 - | "authSchemes",
|
13179 - | vec![
|
13180 - | ::aws_smithy_types::Document::from({
|
13181 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13182 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13183 - | out.insert("name".to_string(), "sigv4a".to_string().into());
|
13184 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
13185 - | out.insert(
|
13186 - | "signingRegionSet".to_string(),
|
13187 - | vec![::aws_smithy_types::Document::from("*".to_string())].into(),
|
13188 - | );
|
13189 - | out
|
13190 - | }),
|
13191 - | ::aws_smithy_types::Document::from({
|
13192 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13193 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13194 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13195 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
13196 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13197 - | out
|
13198 - | }),
|
13199 - | ],
|
13200 - | )
|
13201 - | .build(),
|
13202 - | )
|
13203 - | }
|
13204 - | Self::Result18 => {
|
13205 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13206 - | let effective_std_region = context
|
13207 - | .effective_std_region
|
13208 - | .as_ref()
|
13209 - | .map(|s| s.clone())
|
13210 - | .expect("Guaranteed to have a value by earlier checks.");
|
13211 - | let url = context
|
13212 - | .url
|
13213 - | .as_ref()
|
13214 - | .map(|s| s.clone())
|
13215 - | .expect("Guaranteed to have a value by earlier checks.");
|
13216 - | let outpost_id_ssa_2 = context
|
13217 - | .outpost_id_ssa_2
|
13218 - | .as_ref()
|
13219 - | .map(|s| s.clone())
|
13220 - | .expect("Guaranteed to have a value by earlier checks.");
|
13221 - | ::std::result::Result::Ok(
|
13222 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13223 - | .url({
|
13224 - | let mut out = String::new();
|
13225 - | out.push_str("https://");
|
13226 - | #[allow(clippy::needless_borrow)]
|
13227 - | out.push_str(&bucket.as_ref());
|
13228 - | out.push_str(".op-");
|
13229 - | #[allow(clippy::needless_borrow)]
|
13230 - | out.push_str(&outpost_id_ssa_2.as_ref());
|
13231 - | out.push('.');
|
13232 - | #[allow(clippy::needless_borrow)]
|
13233 - | out.push_str(&url.authority());
|
13234 - | out
|
13235 - | })
|
13236 - | .property(
|
13237 - | "authSchemes",
|
13238 - | vec![
|
13239 - | ::aws_smithy_types::Document::from({
|
13240 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13241 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13242 - | out.insert("name".to_string(), "sigv4a".to_string().into());
|
13243 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
13244 - | out.insert(
|
13245 - | "signingRegionSet".to_string(),
|
13246 - | vec![::aws_smithy_types::Document::from("*".to_string())].into(),
|
13247 - | );
|
13248 - | out
|
13249 - | }),
|
13250 - | ::aws_smithy_types::Document::from({
|
13251 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13252 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13253 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13254 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
13255 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13256 - | out
|
13257 - | }),
|
13258 - | ],
|
13259 - | )
|
13260 - | .build(),
|
13261 - | )
|
13262 - | }
|
13263 - | Self::Result19 => {
|
13264 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13265 - | let effective_std_region = context
|
13266 - | .effective_std_region
|
13267 - | .as_ref()
|
13268 - | .map(|s| s.clone())
|
13269 - | .expect("Guaranteed to have a value by earlier checks.");
|
13270 - | let partition_result = context
|
13271 - | .partition_result
|
13272 - | .as_ref()
|
13273 - | .map(|s| s.clone())
|
13274 - | .expect("Guaranteed to have a value by earlier checks.");
|
13275 - | let outpost_id_ssa_2 = context
|
13276 - | .outpost_id_ssa_2
|
13277 - | .as_ref()
|
13278 - | .map(|s| s.clone())
|
13279 - | .expect("Guaranteed to have a value by earlier checks.");
|
13280 - | ::std::result::Result::Ok(
|
13281 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13282 - | .url({
|
13283 - | let mut out = String::new();
|
13284 - | out.push_str("https://");
|
13285 - | #[allow(clippy::needless_borrow)]
|
13286 - | out.push_str(&bucket.as_ref());
|
13287 - | out.push_str(".op-");
|
13288 - | #[allow(clippy::needless_borrow)]
|
13289 - | out.push_str(&outpost_id_ssa_2.as_ref());
|
13290 - | out.push_str(".s3-outposts.");
|
13291 - | #[allow(clippy::needless_borrow)]
|
13292 - | out.push_str(&effective_std_region.as_ref());
|
13293 - | out.push('.');
|
13294 - | #[allow(clippy::needless_borrow)]
|
13295 - | out.push_str(&partition_result.dns_suffix());
|
13296 - | out
|
13297 - | })
|
13298 - | .property(
|
13299 - | "authSchemes",
|
13300 - | vec![
|
13301 - | ::aws_smithy_types::Document::from({
|
13302 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13303 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13304 - | out.insert("name".to_string(), "sigv4a".to_string().into());
|
13305 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
13306 - | out.insert(
|
13307 - | "signingRegionSet".to_string(),
|
13308 - | vec![::aws_smithy_types::Document::from("*".to_string())].into(),
|
13309 - | );
|
13310 - | out
|
13311 - | }),
|
13312 - | ::aws_smithy_types::Document::from({
|
13313 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13314 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13315 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13316 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
13317 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13318 - | out
|
13319 - | }),
|
13320 - | ],
|
13321 - | )
|
13322 - | .build(),
|
13323 - | )
|
13324 - | }
|
13325 - | Self::Result20 => {
|
13326 - | let hardware_type = context
|
13327 - | .hardware_type
|
13328 - | .as_ref()
|
13329 - | .map(|s| s.clone())
|
13330 - | .expect("Guaranteed to have a value by earlier checks.");
|
13331 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
13332 - | let mut out = String::new();
|
13333 - | out.push_str("Unrecognized hardware type: \"Expected hardware type o or e but got ");
|
13334 - | #[allow(clippy::needless_borrow)]
|
13335 - | out.push_str(&hardware_type.as_ref());
|
13336 - | out.push('"');
|
13337 - | out
|
13338 - | }))
|
13339 - | }
|
13340 - | Self::Result21 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
13341 - | "Invalid ARN: The outpost Id must only contain a-z, A-Z, 0-9 and `-`.".to_string(),
|
13342 - | )),
|
13343 - | Self::Result22 => {
|
13344 - | let endpoint = params.endpoint.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13345 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
13346 - | let mut out = String::new();
|
13347 - | out.push_str("Custom endpoint `");
|
13348 - | #[allow(clippy::needless_borrow)]
|
13349 - | out.push_str(&endpoint.as_ref());
|
13350 - | out.push_str("` was not a valid URI");
|
13351 - | out
|
13352 - | }))
|
13353 - | }
|
13354 - | Self::Result23 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
13355 - | "S3 Accelerate cannot be used in this region".to_string(),
|
13356 - | )),
|
13357 - | Self::Result24 => {
|
13358 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13359 - | let effective_std_region = context
|
13360 - | .effective_std_region
|
13361 - | .as_ref()
|
13362 - | .map(|s| s.clone())
|
13363 - | .expect("Guaranteed to have a value by earlier checks.");
|
13364 - | let partition_result = context
|
13365 - | .partition_result
|
13366 - | .as_ref()
|
13367 - | .map(|s| s.clone())
|
13368 - | .expect("Guaranteed to have a value by earlier checks.");
|
13369 - | ::std::result::Result::Ok(
|
13370 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13371 - | .url({
|
13372 - | let mut out = String::new();
|
13373 - | out.push_str("https://");
|
13374 - | #[allow(clippy::needless_borrow)]
|
13375 - | out.push_str(&bucket.as_ref());
|
13376 - | out.push_str(".s3-fips.dualstack.");
|
13377 - | #[allow(clippy::needless_borrow)]
|
13378 - | out.push_str(&effective_std_region.as_ref());
|
13379 - | out.push('.');
|
13380 - | #[allow(clippy::needless_borrow)]
|
13381 - | out.push_str(&partition_result.dns_suffix());
|
13382 - | out
|
13383 - | })
|
13384 - | .property(
|
13385 - | "authSchemes",
|
13386 - | vec![::aws_smithy_types::Document::from({
|
13387 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13388 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13389 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13390 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13391 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13392 - | out
|
13393 - | })],
|
13394 - | )
|
13395 - | .build(),
|
13396 - | )
|
13397 - | }
|
13398 - | Self::Result25 => {
|
13399 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13400 - | let effective_std_region = context
|
13401 - | .effective_std_region
|
13402 - | .as_ref()
|
13403 - | .map(|s| s.clone())
|
13404 - | .expect("Guaranteed to have a value by earlier checks.");
|
13405 - | let partition_result = context
|
13406 - | .partition_result
|
13407 - | .as_ref()
|
13408 - | .map(|s| s.clone())
|
13409 - | .expect("Guaranteed to have a value by earlier checks.");
|
13410 - | ::std::result::Result::Ok(
|
13411 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13412 - | .url({
|
13413 - | let mut out = String::new();
|
13414 - | out.push_str("https://");
|
13415 - | #[allow(clippy::needless_borrow)]
|
13416 - | out.push_str(&bucket.as_ref());
|
13417 - | out.push_str(".s3-fips.");
|
13418 - | #[allow(clippy::needless_borrow)]
|
13419 - | out.push_str(&effective_std_region.as_ref());
|
13420 - | out.push('.');
|
13421 - | #[allow(clippy::needless_borrow)]
|
13422 - | out.push_str(&partition_result.dns_suffix());
|
13423 - | out
|
13424 - | })
|
13425 - | .property(
|
13426 - | "authSchemes",
|
13427 - | vec![::aws_smithy_types::Document::from({
|
13428 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13429 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13430 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13431 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13432 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13433 - | out
|
13434 - | })],
|
13435 - | )
|
13436 - | .build(),
|
13437 - | )
|
13438 - | }
|
13439 - | Self::Result26 => {
|
13440 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13441 - | let effective_std_region = context
|
13442 - | .effective_std_region
|
13443 - | .as_ref()
|
13444 - | .map(|s| s.clone())
|
13445 - | .expect("Guaranteed to have a value by earlier checks.");
|
13446 - | let partition_result = context
|
13447 - | .partition_result
|
13448 - | .as_ref()
|
13449 - | .map(|s| s.clone())
|
13450 - | .expect("Guaranteed to have a value by earlier checks.");
|
13451 - | ::std::result::Result::Ok(
|
13452 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13453 - | .url({
|
13454 - | let mut out = String::new();
|
13455 - | out.push_str("https://");
|
13456 - | #[allow(clippy::needless_borrow)]
|
13457 - | out.push_str(&bucket.as_ref());
|
13458 - | out.push_str(".s3-accelerate.dualstack.");
|
13459 - | #[allow(clippy::needless_borrow)]
|
13460 - | out.push_str(&effective_std_region.as_ref());
|
13461 - | out.push('.');
|
13462 - | #[allow(clippy::needless_borrow)]
|
13463 - | out.push_str(&partition_result.dns_suffix());
|
13464 - | out
|
13465 - | })
|
13466 - | .property(
|
13467 - | "authSchemes",
|
13468 - | vec![::aws_smithy_types::Document::from({
|
13469 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13470 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13471 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13472 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13473 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13474 - | out
|
13475 - | })],
|
13476 - | )
|
13477 - | .build(),
|
13478 - | )
|
13479 - | }
|
13480 - | Self::Result27 => {
|
13481 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13482 - | let effective_std_region = context
|
13483 - | .effective_std_region
|
13484 - | .as_ref()
|
13485 - | .map(|s| s.clone())
|
13486 - | .expect("Guaranteed to have a value by earlier checks.");
|
13487 - | let partition_result = context
|
13488 - | .partition_result
|
13489 - | .as_ref()
|
13490 - | .map(|s| s.clone())
|
13491 - | .expect("Guaranteed to have a value by earlier checks.");
|
13492 - | ::std::result::Result::Ok(
|
13493 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13494 - | .url({
|
13495 - | let mut out = String::new();
|
13496 - | out.push_str("https://");
|
13497 - | #[allow(clippy::needless_borrow)]
|
13498 - | out.push_str(&bucket.as_ref());
|
13499 - | out.push_str(".s3-accelerate.dualstack.");
|
13500 - | #[allow(clippy::needless_borrow)]
|
13501 - | out.push_str(&partition_result.dns_suffix());
|
13502 - | out
|
13503 - | })
|
13504 - | .property(
|
13505 - | "authSchemes",
|
13506 - | vec![::aws_smithy_types::Document::from({
|
13507 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13508 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13509 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13510 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13511 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
13512 - | out
|
13513 - | })],
|
13514 - | )
|
13515 - | .build(),
|
13516 - | )
|
13517 - | }
|
13518 - | Self::Result28 => {
|
13519 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13520 - | let effective_std_region = context
|
13521 - | .effective_std_region
|
13522 - | .as_ref()
|
13523 - | .map(|s| s.clone())
|
13524 - | .expect("Guaranteed to have a value by earlier checks.");
|
13525 - | let partition_result = context
|
13526 - | .partition_result
|
13527 - | .as_ref()
|
13528 - | .map(|s| s.clone())
|
13529 - | .expect("Guaranteed to have a value by earlier checks.");
|
13530 - | ::std::result::Result::Ok(
|
13531 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13532 - | .url({
|
13533 - | let mut out = String::new();
|
13534 - | out.push_str("https://");
|
13535 - | #[allow(clippy::needless_borrow)]
|
13536 - | out.push_str(&bucket.as_ref());
|
13537 - | out.push_str(".s3.dualstack.");
|
13538 - | #[allow(clippy::needless_borrow)]
|
13539 - | out.push_str(&effective_std_region.as_ref());
|
13540 - | out.push('.');
|
13541 - | #[allow(clippy::needless_borrow)]
|
13542 - | out.push_str(&partition_result.dns_suffix());
|
13543 - | out
|
13544 - | })
|
13545 - | .property(
|
13546 - | "authSchemes",
|
13547 - | vec![::aws_smithy_types::Document::from({
|
13548 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13549 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13550 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13551 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13552 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
10287 + | let mut current_ref: i32 = 521;
|
10288 + | loop {
|
10289 + | match current_ref {
|
10290 + | ref_val if ref_val >= 100_000_000 => {
|
10291 + | return match (ref_val - 100_000_000) as usize {
|
10292 + | 0 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10293 + | "No endpoint rule matched",
|
10294 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10295 + | 1 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10296 + | "Accelerate cannot be used with FIPS".to_string(),
|
10297 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10298 + | 2 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10299 + | "Cannot set dual-stack in combination with a custom endpoint.".to_string(),
|
10300 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10301 + | 3 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10302 + | "A custom endpoint cannot be combined with FIPS".to_string(),
|
10303 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10304 + | 4 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10305 + | "A custom endpoint cannot be combined with S3 Accelerate".to_string(),
|
10306 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10307 + | 5 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10308 + | "Partition does not support FIPS".to_string(),
|
10309 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10310 + | 6 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10311 + | "S3Express does not support S3 Accelerate.".to_string(),
|
10312 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10313 + | 7 => {
|
10314 + | let effective_std_region = context
|
10315 + | .effective_std_region
|
10316 + | .as_ref()
|
10317 + | .expect("Guaranteed to have a value by earlier checks.");
|
10318 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10319 + | let s3_e_auth = context.s3_e_auth.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10320 + | let uri_encoded_bucket = context
|
10321 + | .uri_encoded_bucket
|
10322 + | .as_ref()
|
10323 + | .expect("Guaranteed to have a value by earlier checks.");
|
10324 + | ::std::result::Result::Ok(
|
10325 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10326 + | .url({
|
10327 + | let mut out = String::new();
|
10328 + | #[allow(clippy::needless_borrow)]
|
10329 + | out.push_str(&url.scheme());
|
10330 + | out.push_str("://");
|
10331 + | #[allow(clippy::needless_borrow)]
|
10332 + | out.push_str(&url.authority());
|
10333 + | out.push('/');
|
10334 + | #[allow(clippy::needless_borrow)]
|
10335 + | out.push_str(&uri_encoded_bucket.as_ref());
|
10336 + | #[allow(clippy::needless_borrow)]
|
10337 + | out.push_str(&url.path());
|
10338 + | out
|
10339 + | })
|
10340 + | .property("backend", "S3Express".to_string())
|
10341 + | .auth_scheme(
|
10342 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity(s3_e_auth.to_owned(), 3)
|
10343 + | .put("disableDoubleEncoding", true)
|
10344 + | .put("signingName", "s3express")
|
10345 + | .put("signingRegion", effective_std_region.as_ref()),
|
10346 + | )
|
10347 + | .build(),
|
10348 + | )
|
10349 + | }
|
10350 + | 8 => {
|
10351 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10352 + | let effective_std_region = context
|
10353 + | .effective_std_region
|
10354 + | .as_ref()
|
10355 + | .expect("Guaranteed to have a value by earlier checks.");
|
10356 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10357 + | let s3_e_auth = context.s3_e_auth.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10358 + | ::std::result::Result::Ok(
|
10359 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10360 + | .url({
|
10361 + | let mut out = String::new();
|
10362 + | #[allow(clippy::needless_borrow)]
|
10363 + | out.push_str(&url.scheme());
|
10364 + | out.push_str("://");
|
10365 + | #[allow(clippy::needless_borrow)]
|
10366 + | out.push_str(&bucket.as_ref());
|
10367 + | out.push('.');
|
10368 + | #[allow(clippy::needless_borrow)]
|
10369 + | out.push_str(&url.authority());
|
10370 + | #[allow(clippy::needless_borrow)]
|
10371 + | out.push_str(&url.path());
|
10372 + | out
|
10373 + | })
|
10374 + | .property("backend", "S3Express".to_string())
|
10375 + | .auth_scheme(
|
10376 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity(s3_e_auth.to_owned(), 3)
|
10377 + | .put("disableDoubleEncoding", true)
|
10378 + | .put("signingName", "s3express")
|
10379 + | .put("signingRegion", effective_std_region.as_ref()),
|
10380 + | )
|
10381 + | .build(),
|
10382 + | )
|
10383 + | }
|
10384 + | 9 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10385 + | "S3Express bucket name is not a valid virtual hostable name.".to_string(),
|
10386 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10387 + | 10 => {
|
10388 + | let effective_std_region = context
|
10389 + | .effective_std_region
|
10390 + | .as_ref()
|
10391 + | .expect("Guaranteed to have a value by earlier checks.");
|
10392 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10393 + | let s3_e_ds = context.s3_e_ds.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10394 + | let s3_e_fips = context.s3_e_fips.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10395 + | let uri_encoded_bucket = context
|
10396 + | .uri_encoded_bucket
|
10397 + | .as_ref()
|
10398 + | .expect("Guaranteed to have a value by earlier checks.");
|
10399 + | ::std::result::Result::Ok(
|
10400 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10401 + | .url({
|
10402 + | let mut out = String::new();
|
10403 + | out.push_str("https://s3express-control");
|
10404 + | #[allow(clippy::needless_borrow)]
|
10405 + | out.push_str(&s3_e_fips.as_ref());
|
10406 + | #[allow(clippy::needless_borrow)]
|
10407 + | out.push_str(&s3_e_ds.as_ref());
|
10408 + | out.push('.');
|
10409 + | #[allow(clippy::needless_borrow)]
|
10410 + | out.push_str(&effective_std_region.as_ref());
|
10411 + | out.push('.');
|
10412 + | #[allow(clippy::needless_borrow)]
|
10413 + | out.push_str(&partition_result.dns_suffix());
|
10414 + | out.push('/');
|
10415 + | #[allow(clippy::needless_borrow)]
|
10416 + | out.push_str(&uri_encoded_bucket.as_ref());
|
10417 + | out
|
10418 + | })
|
10419 + | .property("backend", "S3Express".to_string())
|
10420 + | .auth_scheme(
|
10421 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10422 + | .put("disableDoubleEncoding", true)
|
10423 + | .put("signingName", "s3express")
|
10424 + | .put("signingRegion", effective_std_region.as_ref()),
|
10425 + | )
|
10426 + | .build(),
|
10427 + | )
|
10428 + | }
|
10429 + | 11 => {
|
10430 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10431 + | let effective_std_region = context
|
10432 + | .effective_std_region
|
10433 + | .as_ref()
|
10434 + | .expect("Guaranteed to have a value by earlier checks.");
|
10435 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10436 + | let s3_e_ds = context.s3_e_ds.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10437 + | let s3_e_fips = context.s3_e_fips.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10438 + | let s3_e_auth = context.s3_e_auth.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10439 + | let s3express_availability_zone_id = context
|
10440 + | .s3express_availability_zone_id
|
10441 + | .as_ref()
|
10442 + | .expect("Guaranteed to have a value by earlier checks.");
|
10443 + | ::std::result::Result::Ok(
|
10444 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10445 + | .url({
|
10446 + | let mut out = String::new();
|
10447 + | out.push_str("https://");
|
10448 + | #[allow(clippy::needless_borrow)]
|
10449 + | out.push_str(&bucket.as_ref());
|
10450 + | out.push_str(".s3express");
|
10451 + | #[allow(clippy::needless_borrow)]
|
10452 + | out.push_str(&s3_e_fips.as_ref());
|
10453 + | out.push('-');
|
10454 + | #[allow(clippy::needless_borrow)]
|
10455 + | out.push_str(&s3express_availability_zone_id.as_ref());
|
10456 + | #[allow(clippy::needless_borrow)]
|
10457 + | out.push_str(&s3_e_ds.as_ref());
|
10458 + | out.push('.');
|
10459 + | #[allow(clippy::needless_borrow)]
|
10460 + | out.push_str(&effective_std_region.as_ref());
|
10461 + | out.push('.');
|
10462 + | #[allow(clippy::needless_borrow)]
|
10463 + | out.push_str(&partition_result.dns_suffix());
|
10464 + | out
|
10465 + | })
|
10466 + | .property("backend", "S3Express".to_string())
|
10467 + | .auth_scheme(
|
10468 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity(s3_e_auth.to_owned(), 3)
|
10469 + | .put("disableDoubleEncoding", true)
|
10470 + | .put("signingName", "s3express")
|
10471 + | .put("signingRegion", effective_std_region.as_ref()),
|
10472 + | )
|
10473 + | .build(),
|
10474 + | )
|
10475 + | }
|
10476 + | 12 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10477 + | "Unrecognized S3Express bucket name format.".to_string(),
|
10478 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10479 + | 13 => {
|
10480 + | let effective_std_region = context
|
10481 + | .effective_std_region
|
10482 + | .as_ref()
|
10483 + | .expect("Guaranteed to have a value by earlier checks.");
|
10484 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10485 + | let s3_e_auth = context.s3_e_auth.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10486 + | ::std::result::Result::Ok(
|
10487 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10488 + | .url({
|
10489 + | let mut out = String::new();
|
10490 + | #[allow(clippy::needless_borrow)]
|
10491 + | out.push_str(&url.scheme());
|
10492 + | out.push_str("://");
|
10493 + | #[allow(clippy::needless_borrow)]
|
10494 + | out.push_str(&url.authority());
|
10495 + | #[allow(clippy::needless_borrow)]
|
10496 + | out.push_str(&url.path());
|
10497 + | out
|
10498 + | })
|
10499 + | .property("backend", "S3Express".to_string())
|
10500 + | .auth_scheme(
|
10501 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity(s3_e_auth.to_owned(), 3)
|
10502 + | .put("disableDoubleEncoding", true)
|
10503 + | .put("signingName", "s3express")
|
10504 + | .put("signingRegion", effective_std_region.as_ref()),
|
10505 + | )
|
10506 + | .build(),
|
10507 + | )
|
10508 + | }
|
10509 + | 14 => {
|
10510 + | let effective_std_region = context
|
10511 + | .effective_std_region
|
10512 + | .as_ref()
|
10513 + | .expect("Guaranteed to have a value by earlier checks.");
|
10514 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10515 + | let s3_e_ds = context.s3_e_ds.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10516 + | let s3_e_fips = context.s3_e_fips.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10517 + | ::std::result::Result::Ok(
|
10518 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10519 + | .url({
|
10520 + | let mut out = String::new();
|
10521 + | out.push_str("https://s3express-control");
|
10522 + | #[allow(clippy::needless_borrow)]
|
10523 + | out.push_str(&s3_e_fips.as_ref());
|
10524 + | #[allow(clippy::needless_borrow)]
|
10525 + | out.push_str(&s3_e_ds.as_ref());
|
10526 + | out.push('.');
|
10527 + | #[allow(clippy::needless_borrow)]
|
10528 + | out.push_str(&effective_std_region.as_ref());
|
10529 + | out.push('.');
|
10530 + | #[allow(clippy::needless_borrow)]
|
10531 + | out.push_str(&partition_result.dns_suffix());
|
10532 + | out
|
10533 + | })
|
10534 + | .property("backend", "S3Express".to_string())
|
10535 + | .auth_scheme(
|
10536 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10537 + | .put("disableDoubleEncoding", true)
|
10538 + | .put("signingName", "s3express")
|
10539 + | .put("signingRegion", effective_std_region.as_ref()),
|
10540 + | )
|
10541 + | .build(),
|
10542 + | )
|
10543 + | }
|
10544 + | 15 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10545 + | "Expected a endpoint to be specified but no endpoint was found".to_string(),
|
10546 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10547 + | 16 => {
|
10548 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10549 + | let effective_std_region = context
|
10550 + | .effective_std_region
|
10551 + | .as_ref()
|
10552 + | .expect("Guaranteed to have a value by earlier checks.");
|
10553 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10554 + | ::std::result::Result::Ok(
|
10555 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10556 + | .url({
|
10557 + | let mut out = String::new();
|
10558 + | out.push_str("https://");
|
10559 + | #[allow(clippy::needless_borrow)]
|
10560 + | out.push_str(&bucket.as_ref());
|
10561 + | out.push_str(".ec2.");
|
10562 + | #[allow(clippy::needless_borrow)]
|
10563 + | out.push_str(&url.authority());
|
10564 + | out
|
10565 + | })
|
10566 + | .auth_scheme(
|
10567 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4a".to_string(), 3)
|
10568 + | .put("disableDoubleEncoding", true)
|
10569 + | .put("signingName", "s3-outposts")
|
10570 + | .put("signingRegionSet", vec![::aws_smithy_types::Document::from("*".to_string())]),
|
10571 + | )
|
10572 + | .auth_scheme(
|
10573 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10574 + | .put("disableDoubleEncoding", true)
|
10575 + | .put("signingName", "s3-outposts")
|
10576 + | .put("signingRegion", effective_std_region.as_ref()),
|
10577 + | )
|
10578 + | .build(),
|
10579 + | )
|
10580 + | }
|
10581 + | 17 => {
|
10582 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10583 + | let effective_std_region = context
|
10584 + | .effective_std_region
|
10585 + | .as_ref()
|
10586 + | .expect("Guaranteed to have a value by earlier checks.");
|
10587 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10588 + | ::std::result::Result::Ok(
|
10589 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10590 + | .url({
|
10591 + | let mut out = String::new();
|
10592 + | out.push_str("https://");
|
10593 + | #[allow(clippy::needless_borrow)]
|
10594 + | out.push_str(&bucket.as_ref());
|
10595 + | out.push_str(".ec2.s3-outposts.");
|
10596 + | #[allow(clippy::needless_borrow)]
|
10597 + | out.push_str(&effective_std_region.as_ref());
|
10598 + | out.push('.');
|
10599 + | #[allow(clippy::needless_borrow)]
|
10600 + | out.push_str(&partition_result.dns_suffix());
|
10601 + | out
|
10602 + | })
|
10603 + | .auth_scheme(
|
10604 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4a".to_string(), 3)
|
10605 + | .put("disableDoubleEncoding", true)
|
10606 + | .put("signingName", "s3-outposts")
|
10607 + | .put("signingRegionSet", vec![::aws_smithy_types::Document::from("*".to_string())]),
|
10608 + | )
|
10609 + | .auth_scheme(
|
10610 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10611 + | .put("disableDoubleEncoding", true)
|
10612 + | .put("signingName", "s3-outposts")
|
10613 + | .put("signingRegion", effective_std_region.as_ref()),
|
10614 + | )
|
10615 + | .build(),
|
10616 + | )
|
10617 + | }
|
10618 + | 18 => {
|
10619 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10620 + | let effective_std_region = context
|
10621 + | .effective_std_region
|
10622 + | .as_ref()
|
10623 + | .expect("Guaranteed to have a value by earlier checks.");
|
10624 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10625 + | let outpost_id_ssa_2 = context.outpost_id_ssa_2.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10626 + | ::std::result::Result::Ok(
|
10627 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10628 + | .url({
|
10629 + | let mut out = String::new();
|
10630 + | out.push_str("https://");
|
10631 + | #[allow(clippy::needless_borrow)]
|
10632 + | out.push_str(&bucket.as_ref());
|
10633 + | out.push_str(".op-");
|
10634 + | #[allow(clippy::needless_borrow)]
|
10635 + | out.push_str(&outpost_id_ssa_2.as_ref());
|
10636 + | out.push('.');
|
10637 + | #[allow(clippy::needless_borrow)]
|
10638 + | out.push_str(&url.authority());
|
10639 + | out
|
10640 + | })
|
10641 + | .auth_scheme(
|
10642 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4a".to_string(), 3)
|
10643 + | .put("disableDoubleEncoding", true)
|
10644 + | .put("signingName", "s3-outposts")
|
10645 + | .put("signingRegionSet", vec![::aws_smithy_types::Document::from("*".to_string())]),
|
10646 + | )
|
10647 + | .auth_scheme(
|
10648 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10649 + | .put("disableDoubleEncoding", true)
|
10650 + | .put("signingName", "s3-outposts")
|
10651 + | .put("signingRegion", effective_std_region.as_ref()),
|
10652 + | )
|
10653 + | .build(),
|
10654 + | )
|
10655 + | }
|
10656 + | 19 => {
|
10657 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10658 + | let effective_std_region = context
|
10659 + | .effective_std_region
|
10660 + | .as_ref()
|
10661 + | .expect("Guaranteed to have a value by earlier checks.");
|
10662 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10663 + | let outpost_id_ssa_2 = context.outpost_id_ssa_2.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10664 + | ::std::result::Result::Ok(
|
10665 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10666 + | .url({
|
10667 + | let mut out = String::new();
|
10668 + | out.push_str("https://");
|
10669 + | #[allow(clippy::needless_borrow)]
|
10670 + | out.push_str(&bucket.as_ref());
|
10671 + | out.push_str(".op-");
|
10672 + | #[allow(clippy::needless_borrow)]
|
10673 + | out.push_str(&outpost_id_ssa_2.as_ref());
|
10674 + | out.push_str(".s3-outposts.");
|
10675 + | #[allow(clippy::needless_borrow)]
|
10676 + | out.push_str(&effective_std_region.as_ref());
|
10677 + | out.push('.');
|
10678 + | #[allow(clippy::needless_borrow)]
|
10679 + | out.push_str(&partition_result.dns_suffix());
|
10680 + | out
|
10681 + | })
|
10682 + | .auth_scheme(
|
10683 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4a".to_string(), 3)
|
10684 + | .put("disableDoubleEncoding", true)
|
10685 + | .put("signingName", "s3-outposts")
|
10686 + | .put("signingRegionSet", vec![::aws_smithy_types::Document::from("*".to_string())]),
|
10687 + | )
|
10688 + | .auth_scheme(
|
10689 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10690 + | .put("disableDoubleEncoding", true)
|
10691 + | .put("signingName", "s3-outposts")
|
10692 + | .put("signingRegion", effective_std_region.as_ref()),
|
10693 + | )
|
10694 + | .build(),
|
10695 + | )
|
10696 + | }
|
10697 + | 20 => {
|
10698 + | let hardware_type = context.hardware_type.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10699 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
10700 + | let mut out = String::new();
|
10701 + | out.push_str("Unrecognized hardware type: \"Expected hardware type o or e but got ");
|
10702 + | #[allow(clippy::needless_borrow)]
|
10703 + | out.push_str(&hardware_type.as_ref());
|
10704 + | out.push('"');
|
13553 10705 | out
|
13554 - | })],
|
13555 - | )
|
13556 - | .build(),
|
13557 - | )
|
13558 - | }
|
13559 - | Self::Result29 => {
|
13560 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13561 - | let effective_std_region = context
|
13562 - | .effective_std_region
|
13563 - | .as_ref()
|
13564 - | .map(|s| s.clone())
|
13565 - | .expect("Guaranteed to have a value by earlier checks.");
|
13566 - | let url = context
|
13567 - | .url
|
13568 - | .as_ref()
|
13569 - | .map(|s| s.clone())
|
13570 - | .expect("Guaranteed to have a value by earlier checks.");
|
13571 - | ::std::result::Result::Ok(
|
13572 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13573 - | .url({
|
13574 - | let mut out = String::new();
|
13575 - | #[allow(clippy::needless_borrow)]
|
13576 - | out.push_str(&url.scheme());
|
13577 - | out.push_str("://");
|
13578 - | #[allow(clippy::needless_borrow)]
|
13579 - | out.push_str(&url.authority());
|
13580 - | #[allow(clippy::needless_borrow)]
|
13581 - | out.push_str(&url.normalized_path());
|
13582 - | #[allow(clippy::needless_borrow)]
|
13583 - | out.push_str(&bucket.as_ref());
|
13584 - | out
|
13585 - | })
|
13586 - | .property(
|
13587 - | "authSchemes",
|
13588 - | vec![::aws_smithy_types::Document::from({
|
13589 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13590 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13591 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13592 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13593 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
10706 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
10707 + | }
|
10708 + | 21 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10709 + | "Invalid ARN: The outpost Id must only contain a-z, A-Z, 0-9 and `-`.".to_string(),
|
10710 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10711 + | 22 => {
|
10712 + | let endpoint = params.endpoint.as_deref().unwrap_or_default();
|
10713 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
10714 + | let mut out = String::new();
|
10715 + | out.push_str("Custom endpoint `");
|
10716 + | #[allow(clippy::needless_borrow)]
|
10717 + | out.push_str(&endpoint.as_ref());
|
10718 + | out.push_str("` was not a valid URI");
|
13594 10719 | out
|
13595 - | })],
|
13596 - | )
|
13597 - | .build(),
|
13598 - | )
|
13599 - | }
|
13600 - | Self::Result30 => {
|
13601 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13602 - | let effective_std_region = context
|
13603 - | .effective_std_region
|
13604 - | .as_ref()
|
13605 - | .map(|s| s.clone())
|
13606 - | .expect("Guaranteed to have a value by earlier checks.");
|
13607 - | let url = context
|
13608 - | .url
|
13609 - | .as_ref()
|
13610 - | .map(|s| s.clone())
|
13611 - | .expect("Guaranteed to have a value by earlier checks.");
|
13612 - | ::std::result::Result::Ok(
|
13613 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13614 - | .url({
|
13615 - | let mut out = String::new();
|
13616 - | #[allow(clippy::needless_borrow)]
|
13617 - | out.push_str(&url.scheme());
|
13618 - | out.push_str("://");
|
13619 - | #[allow(clippy::needless_borrow)]
|
13620 - | out.push_str(&bucket.as_ref());
|
13621 - | out.push('.');
|
13622 - | #[allow(clippy::needless_borrow)]
|
13623 - | out.push_str(&url.authority());
|
13624 - | #[allow(clippy::needless_borrow)]
|
13625 - | out.push_str(&url.path());
|
13626 - | out
|
13627 - | })
|
13628 - | .property(
|
13629 - | "authSchemes",
|
13630 - | vec![::aws_smithy_types::Document::from({
|
13631 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13632 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13633 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13634 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13635 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
10720 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
10721 + | }
|
10722 + | 23 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
10723 + | "S3 Accelerate cannot be used in this region".to_string(),
|
10724 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
10725 + | 24 => {
|
10726 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10727 + | let effective_std_region = context
|
10728 + | .effective_std_region
|
10729 + | .as_ref()
|
10730 + | .expect("Guaranteed to have a value by earlier checks.");
|
10731 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10732 + | ::std::result::Result::Ok(
|
10733 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10734 + | .url({
|
10735 + | let mut out = String::new();
|
10736 + | out.push_str("https://");
|
10737 + | #[allow(clippy::needless_borrow)]
|
10738 + | out.push_str(&bucket.as_ref());
|
10739 + | out.push_str(".s3-fips.dualstack.");
|
10740 + | #[allow(clippy::needless_borrow)]
|
10741 + | out.push_str(&effective_std_region.as_ref());
|
10742 + | out.push('.');
|
10743 + | #[allow(clippy::needless_borrow)]
|
10744 + | out.push_str(&partition_result.dns_suffix());
|
10745 + | out
|
10746 + | })
|
10747 + | .auth_scheme(
|
10748 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10749 + | .put("disableDoubleEncoding", true)
|
10750 + | .put("signingName", "s3")
|
10751 + | .put("signingRegion", effective_std_region.as_ref()),
|
10752 + | )
|
10753 + | .build(),
|
10754 + | )
|
10755 + | }
|
10756 + | 25 => {
|
10757 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10758 + | let effective_std_region = context
|
10759 + | .effective_std_region
|
10760 + | .as_ref()
|
10761 + | .expect("Guaranteed to have a value by earlier checks.");
|
10762 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10763 + | ::std::result::Result::Ok(
|
10764 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10765 + | .url({
|
10766 + | let mut out = String::new();
|
10767 + | out.push_str("https://");
|
10768 + | #[allow(clippy::needless_borrow)]
|
10769 + | out.push_str(&bucket.as_ref());
|
10770 + | out.push_str(".s3-fips.");
|
10771 + | #[allow(clippy::needless_borrow)]
|
10772 + | out.push_str(&effective_std_region.as_ref());
|
10773 + | out.push('.');
|
10774 + | #[allow(clippy::needless_borrow)]
|
10775 + | out.push_str(&partition_result.dns_suffix());
|
10776 + | out
|
10777 + | })
|
10778 + | .auth_scheme(
|
10779 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10780 + | .put("disableDoubleEncoding", true)
|
10781 + | .put("signingName", "s3")
|
10782 + | .put("signingRegion", effective_std_region.as_ref()),
|
10783 + | )
|
10784 + | .build(),
|
10785 + | )
|
10786 + | }
|
10787 + | 26 => {
|
10788 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10789 + | let effective_std_region = context
|
10790 + | .effective_std_region
|
10791 + | .as_ref()
|
10792 + | .expect("Guaranteed to have a value by earlier checks.");
|
10793 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10794 + | ::std::result::Result::Ok(
|
10795 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10796 + | .url({
|
10797 + | let mut out = String::new();
|
10798 + | out.push_str("https://");
|
10799 + | #[allow(clippy::needless_borrow)]
|
10800 + | out.push_str(&bucket.as_ref());
|
10801 + | out.push_str(".s3-accelerate.dualstack.");
|
10802 + | #[allow(clippy::needless_borrow)]
|
10803 + | out.push_str(&effective_std_region.as_ref());
|
10804 + | out.push('.');
|
10805 + | #[allow(clippy::needless_borrow)]
|
10806 + | out.push_str(&partition_result.dns_suffix());
|
10807 + | out
|
10808 + | })
|
10809 + | .auth_scheme(
|
10810 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10811 + | .put("disableDoubleEncoding", true)
|
10812 + | .put("signingName", "s3")
|
10813 + | .put("signingRegion", effective_std_region.as_ref()),
|
10814 + | )
|
10815 + | .build(),
|
10816 + | )
|
10817 + | }
|
10818 + | 27 => {
|
10819 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10820 + | let effective_std_region = context
|
10821 + | .effective_std_region
|
10822 + | .as_ref()
|
10823 + | .expect("Guaranteed to have a value by earlier checks.");
|
10824 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10825 + | ::std::result::Result::Ok(
|
10826 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10827 + | .url({
|
10828 + | let mut out = String::new();
|
10829 + | out.push_str("https://");
|
10830 + | #[allow(clippy::needless_borrow)]
|
10831 + | out.push_str(&bucket.as_ref());
|
10832 + | out.push_str(".s3-accelerate.dualstack.");
|
10833 + | #[allow(clippy::needless_borrow)]
|
10834 + | out.push_str(&partition_result.dns_suffix());
|
10835 + | out
|
10836 + | })
|
10837 + | .auth_scheme(
|
10838 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10839 + | .put("disableDoubleEncoding", true)
|
10840 + | .put("signingName", "s3")
|
10841 + | .put("signingRegion", effective_std_region.as_ref()),
|
10842 + | )
|
10843 + | .build(),
|
10844 + | )
|
10845 + | }
|
10846 + | 28 => {
|
10847 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10848 + | let effective_std_region = context
|
10849 + | .effective_std_region
|
10850 + | .as_ref()
|
10851 + | .expect("Guaranteed to have a value by earlier checks.");
|
10852 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10853 + | ::std::result::Result::Ok(
|
10854 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10855 + | .url({
|
10856 + | let mut out = String::new();
|
10857 + | out.push_str("https://");
|
10858 + | #[allow(clippy::needless_borrow)]
|
10859 + | out.push_str(&bucket.as_ref());
|
10860 + | out.push_str(".s3.dualstack.");
|
10861 + | #[allow(clippy::needless_borrow)]
|
10862 + | out.push_str(&effective_std_region.as_ref());
|
10863 + | out.push('.');
|
10864 + | #[allow(clippy::needless_borrow)]
|
10865 + | out.push_str(&partition_result.dns_suffix());
|
10866 + | out
|
10867 + | })
|
10868 + | .auth_scheme(
|
10869 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10870 + | .put("disableDoubleEncoding", true)
|
10871 + | .put("signingName", "s3")
|
10872 + | .put("signingRegion", effective_std_region.as_ref()),
|
10873 + | )
|
10874 + | .build(),
|
10875 + | )
|
10876 + | }
|
10877 + | 29 => {
|
10878 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10879 + | let effective_std_region = context
|
10880 + | .effective_std_region
|
10881 + | .as_ref()
|
10882 + | .expect("Guaranteed to have a value by earlier checks.");
|
10883 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10884 + | ::std::result::Result::Ok(
|
10885 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10886 + | .url({
|
10887 + | let mut out = String::new();
|
10888 + | #[allow(clippy::needless_borrow)]
|
10889 + | out.push_str(&url.scheme());
|
10890 + | out.push_str("://");
|
10891 + | #[allow(clippy::needless_borrow)]
|
10892 + | out.push_str(&url.authority());
|
10893 + | #[allow(clippy::needless_borrow)]
|
10894 + | out.push_str(&url.normalized_path());
|
10895 + | #[allow(clippy::needless_borrow)]
|
10896 + | out.push_str(&bucket.as_ref());
|
10897 + | out
|
10898 + | })
|
10899 + | .auth_scheme(
|
10900 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10901 + | .put("disableDoubleEncoding", true)
|
10902 + | .put("signingName", "s3")
|
10903 + | .put("signingRegion", effective_std_region.as_ref()),
|
10904 + | )
|
10905 + | .build(),
|
10906 + | )
|
10907 + | }
|
10908 + | 30 => {
|
10909 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10910 + | let effective_std_region = context
|
10911 + | .effective_std_region
|
10912 + | .as_ref()
|
10913 + | .expect("Guaranteed to have a value by earlier checks.");
|
10914 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10915 + | ::std::result::Result::Ok(
|
10916 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10917 + | .url({
|
10918 + | let mut out = String::new();
|
10919 + | #[allow(clippy::needless_borrow)]
|
10920 + | out.push_str(&url.scheme());
|
10921 + | out.push_str("://");
|
10922 + | #[allow(clippy::needless_borrow)]
|
10923 + | out.push_str(&bucket.as_ref());
|
10924 + | out.push('.');
|
10925 + | #[allow(clippy::needless_borrow)]
|
10926 + | out.push_str(&url.authority());
|
10927 + | #[allow(clippy::needless_borrow)]
|
10928 + | out.push_str(&url.path());
|
10929 + | out
|
10930 + | })
|
10931 + | .auth_scheme(
|
10932 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10933 + | .put("disableDoubleEncoding", true)
|
10934 + | .put("signingName", "s3")
|
10935 + | .put("signingRegion", effective_std_region.as_ref()),
|
10936 + | )
|
10937 + | .build(),
|
10938 + | )
|
10939 + | }
|
10940 + | 31 => {
|
10941 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10942 + | let effective_std_region = context
|
10943 + | .effective_std_region
|
10944 + | .as_ref()
|
10945 + | .expect("Guaranteed to have a value by earlier checks.");
|
10946 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10947 + | ::std::result::Result::Ok(
|
10948 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10949 + | .url({
|
10950 + | let mut out = String::new();
|
10951 + | out.push_str("https://");
|
10952 + | #[allow(clippy::needless_borrow)]
|
10953 + | out.push_str(&bucket.as_ref());
|
10954 + | out.push_str(".s3-accelerate.");
|
10955 + | #[allow(clippy::needless_borrow)]
|
10956 + | out.push_str(&partition_result.dns_suffix());
|
10957 + | out
|
10958 + | })
|
10959 + | .auth_scheme(
|
10960 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10961 + | .put("disableDoubleEncoding", true)
|
10962 + | .put("signingName", "s3")
|
10963 + | .put("signingRegion", effective_std_region.as_ref()),
|
10964 + | )
|
10965 + | .build(),
|
10966 + | )
|
10967 + | }
|
10968 + | 32 => {
|
10969 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10970 + | let effective_std_region = context
|
10971 + | .effective_std_region
|
10972 + | .as_ref()
|
10973 + | .expect("Guaranteed to have a value by earlier checks.");
|
10974 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
10975 + | ::std::result::Result::Ok(
|
10976 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
10977 + | .url({
|
10978 + | let mut out = String::new();
|
10979 + | out.push_str("https://");
|
10980 + | #[allow(clippy::needless_borrow)]
|
10981 + | out.push_str(&bucket.as_ref());
|
10982 + | out.push_str(".s3.");
|
10983 + | #[allow(clippy::needless_borrow)]
|
10984 + | out.push_str(&partition_result.dns_suffix());
|
10985 + | out
|
10986 + | })
|
10987 + | .auth_scheme(
|
10988 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
10989 + | .put("disableDoubleEncoding", true)
|
10990 + | .put("signingName", "s3")
|
10991 + | .put("signingRegion", effective_std_region.as_ref()),
|
10992 + | )
|
10993 + | .build(),
|
10994 + | )
|
10995 + | }
|
10996 + | 33 => {
|
10997 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
10998 + | let effective_std_region = context
|
10999 + | .effective_std_region
|
11000 + | .as_ref()
|
11001 + | .expect("Guaranteed to have a value by earlier checks.");
|
11002 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11003 + | ::std::result::Result::Ok(
|
11004 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11005 + | .url({
|
11006 + | let mut out = String::new();
|
11007 + | out.push_str("https://");
|
11008 + | #[allow(clippy::needless_borrow)]
|
11009 + | out.push_str(&bucket.as_ref());
|
11010 + | out.push_str(".s3.");
|
11011 + | #[allow(clippy::needless_borrow)]
|
11012 + | out.push_str(&effective_std_region.as_ref());
|
11013 + | out.push('.');
|
11014 + | #[allow(clippy::needless_borrow)]
|
11015 + | out.push_str(&partition_result.dns_suffix());
|
11016 + | out
|
11017 + | })
|
11018 + | .auth_scheme(
|
11019 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11020 + | .put("disableDoubleEncoding", true)
|
11021 + | .put("signingName", "s3")
|
11022 + | .put("signingRegion", effective_std_region.as_ref()),
|
11023 + | )
|
11024 + | .build(),
|
11025 + | )
|
11026 + | }
|
11027 + | 34 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11028 + | "Invalid region: region was not a valid DNS name.".to_string(),
|
11029 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11030 + | 35 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11031 + | "S3 Object Lambda does not support Dual-stack".to_string(),
|
11032 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11033 + | 36 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11034 + | "S3 Object Lambda does not support S3 Accelerate".to_string(),
|
11035 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11036 + | 37 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11037 + | "Access points are not supported for this operation".to_string(),
|
11038 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11039 + | 38 => {
|
11040 + | let region = params.region.as_deref().unwrap_or_default();
|
11041 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11042 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11043 + | let mut out = String::new();
|
11044 + | out.push_str("Invalid configuration: region from ARN `");
|
11045 + | #[allow(clippy::needless_borrow)]
|
11046 + | out.push_str(&bucket_arn.region());
|
11047 + | out.push_str("` does not match client region `");
|
11048 + | #[allow(clippy::needless_borrow)]
|
11049 + | out.push_str(®ion.as_ref());
|
11050 + | out.push_str("` and UseArnRegion is `false`");
|
13636 11051 | out
|
13637 - | })],
|
13638 - | )
|
13639 - | .build(),
|
13640 - | )
|
13641 - | }
|
13642 - | Self::Result31 => {
|
13643 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13644 - | let effective_std_region = context
|
13645 - | .effective_std_region
|
13646 - | .as_ref()
|
13647 - | .map(|s| s.clone())
|
13648 - | .expect("Guaranteed to have a value by earlier checks.");
|
13649 - | let partition_result = context
|
13650 - | .partition_result
|
13651 - | .as_ref()
|
13652 - | .map(|s| s.clone())
|
13653 - | .expect("Guaranteed to have a value by earlier checks.");
|
13654 - | ::std::result::Result::Ok(
|
13655 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13656 - | .url({
|
13657 - | let mut out = String::new();
|
13658 - | out.push_str("https://");
|
13659 - | #[allow(clippy::needless_borrow)]
|
13660 - | out.push_str(&bucket.as_ref());
|
13661 - | out.push_str(".s3-accelerate.");
|
13662 - | #[allow(clippy::needless_borrow)]
|
13663 - | out.push_str(&partition_result.dns_suffix());
|
13664 - | out
|
13665 - | })
|
13666 - | .property(
|
13667 - | "authSchemes",
|
13668 - | vec![::aws_smithy_types::Document::from({
|
13669 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13670 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13671 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13672 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13673 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
11052 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11053 + | }
|
11054 + | 39 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11055 + | "Invalid ARN: Missing account id".to_string(),
|
11056 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11057 + | 40 => {
|
11058 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11059 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11060 + | let effective_arn_region = context
|
11061 + | .effective_arn_region
|
11062 + | .as_ref()
|
11063 + | .expect("Guaranteed to have a value by earlier checks.");
|
11064 + | let access_point_name_ssa_1 = context
|
11065 + | .access_point_name_ssa_1
|
11066 + | .as_ref()
|
11067 + | .expect("Guaranteed to have a value by earlier checks.");
|
11068 + | ::std::result::Result::Ok(
|
11069 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11070 + | .url({
|
11071 + | let mut out = String::new();
|
11072 + | #[allow(clippy::needless_borrow)]
|
11073 + | out.push_str(&url.scheme());
|
11074 + | out.push_str("://");
|
11075 + | #[allow(clippy::needless_borrow)]
|
11076 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11077 + | out.push('-');
|
11078 + | #[allow(clippy::needless_borrow)]
|
11079 + | out.push_str(&bucket_arn.account_id());
|
11080 + | out.push('.');
|
11081 + | #[allow(clippy::needless_borrow)]
|
11082 + | out.push_str(&url.authority());
|
11083 + | #[allow(clippy::needless_borrow)]
|
11084 + | out.push_str(&url.path());
|
11085 + | out
|
11086 + | })
|
11087 + | .auth_scheme(
|
11088 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11089 + | .put("disableDoubleEncoding", true)
|
11090 + | .put("signingName", "s3-object-lambda")
|
11091 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11092 + | )
|
11093 + | .build(),
|
11094 + | )
|
11095 + | }
|
11096 + | 41 => {
|
11097 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11098 + | let effective_arn_region = context
|
11099 + | .effective_arn_region
|
11100 + | .as_ref()
|
11101 + | .expect("Guaranteed to have a value by earlier checks.");
|
11102 + | let access_point_name_ssa_1 = context
|
11103 + | .access_point_name_ssa_1
|
11104 + | .as_ref()
|
11105 + | .expect("Guaranteed to have a value by earlier checks.");
|
11106 + | let bucket_partition = context.bucket_partition.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11107 + | ::std::result::Result::Ok(
|
11108 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11109 + | .url({
|
11110 + | let mut out = String::new();
|
11111 + | out.push_str("https://");
|
11112 + | #[allow(clippy::needless_borrow)]
|
11113 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11114 + | out.push('-');
|
11115 + | #[allow(clippy::needless_borrow)]
|
11116 + | out.push_str(&bucket_arn.account_id());
|
11117 + | out.push_str(".s3-object-lambda-fips.");
|
11118 + | #[allow(clippy::needless_borrow)]
|
11119 + | out.push_str(&effective_arn_region.as_ref());
|
11120 + | out.push('.');
|
11121 + | #[allow(clippy::needless_borrow)]
|
11122 + | out.push_str(&bucket_partition.dns_suffix());
|
11123 + | out
|
11124 + | })
|
11125 + | .auth_scheme(
|
11126 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11127 + | .put("disableDoubleEncoding", true)
|
11128 + | .put("signingName", "s3-object-lambda")
|
11129 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11130 + | )
|
11131 + | .build(),
|
11132 + | )
|
11133 + | }
|
11134 + | 42 => {
|
11135 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11136 + | let effective_arn_region = context
|
11137 + | .effective_arn_region
|
11138 + | .as_ref()
|
11139 + | .expect("Guaranteed to have a value by earlier checks.");
|
11140 + | let access_point_name_ssa_1 = context
|
11141 + | .access_point_name_ssa_1
|
11142 + | .as_ref()
|
11143 + | .expect("Guaranteed to have a value by earlier checks.");
|
11144 + | let bucket_partition = context.bucket_partition.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11145 + | ::std::result::Result::Ok(
|
11146 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11147 + | .url({
|
11148 + | let mut out = String::new();
|
11149 + | out.push_str("https://");
|
11150 + | #[allow(clippy::needless_borrow)]
|
11151 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11152 + | out.push('-');
|
11153 + | #[allow(clippy::needless_borrow)]
|
11154 + | out.push_str(&bucket_arn.account_id());
|
11155 + | out.push_str(".s3-object-lambda.");
|
11156 + | #[allow(clippy::needless_borrow)]
|
11157 + | out.push_str(&effective_arn_region.as_ref());
|
11158 + | out.push('.');
|
11159 + | #[allow(clippy::needless_borrow)]
|
11160 + | out.push_str(&bucket_partition.dns_suffix());
|
11161 + | out
|
11162 + | })
|
11163 + | .auth_scheme(
|
11164 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11165 + | .put("disableDoubleEncoding", true)
|
11166 + | .put("signingName", "s3-object-lambda")
|
11167 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11168 + | )
|
11169 + | .build(),
|
11170 + | )
|
11171 + | }
|
11172 + | 43 => {
|
11173 + | let access_point_name_ssa_1 = context
|
11174 + | .access_point_name_ssa_1
|
11175 + | .as_ref()
|
11176 + | .expect("Guaranteed to have a value by earlier checks.");
|
11177 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11178 + | let mut out = String::new();
|
11179 + | out.push_str("Invalid ARN: The access point name may only contain a-z, A-Z, 0-9 and `-`. Found: `");
|
11180 + | #[allow(clippy::needless_borrow)]
|
11181 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11182 + | out.push('`');
|
13674 11183 | out
|
13675 - | })],
|
13676 - | )
|
13677 - | .build(),
|
13678 - | )
|
13679 - | }
|
13680 - | Self::Result32 => {
|
13681 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13682 - | let effective_std_region = context
|
13683 - | .effective_std_region
|
13684 - | .as_ref()
|
13685 - | .map(|s| s.clone())
|
13686 - | .expect("Guaranteed to have a value by earlier checks.");
|
13687 - | let partition_result = context
|
13688 - | .partition_result
|
13689 - | .as_ref()
|
13690 - | .map(|s| s.clone())
|
13691 - | .expect("Guaranteed to have a value by earlier checks.");
|
13692 - | ::std::result::Result::Ok(
|
13693 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13694 - | .url({
|
13695 - | let mut out = String::new();
|
13696 - | out.push_str("https://");
|
13697 - | #[allow(clippy::needless_borrow)]
|
13698 - | out.push_str(&bucket.as_ref());
|
13699 - | out.push_str(".s3.");
|
13700 - | #[allow(clippy::needless_borrow)]
|
13701 - | out.push_str(&partition_result.dns_suffix());
|
13702 - | out
|
13703 - | })
|
13704 - | .property(
|
13705 - | "authSchemes",
|
13706 - | vec![::aws_smithy_types::Document::from({
|
13707 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13708 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13709 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13710 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13711 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
11184 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11185 + | }
|
11186 + | 44 => {
|
11187 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11188 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11189 + | let mut out = String::new();
|
11190 + | out.push_str("Invalid ARN: The account id may only contain a-z, A-Z, 0-9 and `-`. Found: `");
|
11191 + | #[allow(clippy::needless_borrow)]
|
11192 + | out.push_str(&bucket_arn.account_id());
|
11193 + | out.push('`');
|
13712 11194 | out
|
13713 - | })],
|
13714 - | )
|
13715 - | .build(),
|
13716 - | )
|
13717 - | }
|
13718 - | Self::Result33 => {
|
13719 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13720 - | let effective_std_region = context
|
13721 - | .effective_std_region
|
13722 - | .as_ref()
|
13723 - | .map(|s| s.clone())
|
13724 - | .expect("Guaranteed to have a value by earlier checks.");
|
13725 - | let partition_result = context
|
13726 - | .partition_result
|
13727 - | .as_ref()
|
13728 - | .map(|s| s.clone())
|
13729 - | .expect("Guaranteed to have a value by earlier checks.");
|
13730 - | ::std::result::Result::Ok(
|
13731 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13732 - | .url({
|
13733 - | let mut out = String::new();
|
13734 - | out.push_str("https://");
|
13735 - | #[allow(clippy::needless_borrow)]
|
13736 - | out.push_str(&bucket.as_ref());
|
13737 - | out.push_str(".s3.");
|
13738 - | #[allow(clippy::needless_borrow)]
|
13739 - | out.push_str(&effective_std_region.as_ref());
|
13740 - | out.push('.');
|
13741 - | #[allow(clippy::needless_borrow)]
|
13742 - | out.push_str(&partition_result.dns_suffix());
|
13743 - | out
|
13744 - | })
|
13745 - | .property(
|
13746 - | "authSchemes",
|
13747 - | vec![::aws_smithy_types::Document::from({
|
13748 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13749 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13750 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13751 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
13752 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
11195 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11196 + | }
|
11197 + | 45 => {
|
11198 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11199 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11200 + | let mut out = String::new();
|
11201 + | out.push_str("Invalid region in ARN: `");
|
11202 + | #[allow(clippy::needless_borrow)]
|
11203 + | out.push_str(&bucket_arn.region());
|
11204 + | out.push_str("` (invalid DNS name)");
|
13753 11205 | out
|
13754 - | })],
|
13755 - | )
|
13756 - | .build(),
|
13757 - | )
|
13758 - | }
|
13759 - | Self::Result34 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
13760 - | "Invalid region: region was not a valid DNS name.".to_string(),
|
13761 - | )),
|
13762 - | Self::Result35 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
13763 - | "S3 Object Lambda does not support Dual-stack".to_string(),
|
13764 - | )),
|
13765 - | Self::Result36 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
13766 - | "S3 Object Lambda does not support S3 Accelerate".to_string(),
|
13767 - | )),
|
13768 - | Self::Result37 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
13769 - | "Access points are not supported for this operation".to_string(),
|
13770 - | )),
|
13771 - | Self::Result38 => {
|
13772 - | let region = params.region.as_ref().map(|s| s.clone()).unwrap_or_default();
|
13773 - | let bucket_arn = context
|
13774 - | .bucket_arn
|
13775 - | .as_ref()
|
13776 - | .map(|s| s.clone())
|
13777 - | .expect("Guaranteed to have a value by earlier checks.");
|
13778 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
13779 - | let mut out = String::new();
|
13780 - | out.push_str("Invalid configuration: region from ARN `");
|
13781 - | #[allow(clippy::needless_borrow)]
|
13782 - | out.push_str(&bucket_arn.region());
|
13783 - | out.push_str("` does not match client region `");
|
13784 - | #[allow(clippy::needless_borrow)]
|
13785 - | out.push_str(®ion.as_ref());
|
13786 - | out.push_str("` and UseArnRegion is `false`");
|
13787 - | out
|
13788 - | }))
|
13789 - | }
|
13790 - | Self::Result39 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
13791 - | "Invalid ARN: Missing account id".to_string(),
|
13792 - | )),
|
13793 - | Self::Result40 => {
|
13794 - | let url = context
|
13795 - | .url
|
13796 - | .as_ref()
|
13797 - | .map(|s| s.clone())
|
13798 - | .expect("Guaranteed to have a value by earlier checks.");
|
13799 - | let bucket_arn = context
|
13800 - | .bucket_arn
|
13801 - | .as_ref()
|
13802 - | .map(|s| s.clone())
|
13803 - | .expect("Guaranteed to have a value by earlier checks.");
|
13804 - | let effective_arn_region = context
|
13805 - | .effective_arn_region
|
13806 - | .as_ref()
|
13807 - | .map(|s| s.clone())
|
13808 - | .expect("Guaranteed to have a value by earlier checks.");
|
13809 - | let access_point_name_ssa_1 = context
|
13810 - | .access_point_name_ssa_1
|
13811 - | .as_ref()
|
13812 - | .map(|s| s.clone())
|
13813 - | .expect("Guaranteed to have a value by earlier checks.");
|
13814 - | ::std::result::Result::Ok(
|
13815 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13816 - | .url({
|
13817 - | let mut out = String::new();
|
13818 - | #[allow(clippy::needless_borrow)]
|
13819 - | out.push_str(&url.scheme());
|
13820 - | out.push_str("://");
|
13821 - | #[allow(clippy::needless_borrow)]
|
13822 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
13823 - | out.push('-');
|
13824 - | #[allow(clippy::needless_borrow)]
|
13825 - | out.push_str(&bucket_arn.account_id());
|
13826 - | out.push('.');
|
13827 - | #[allow(clippy::needless_borrow)]
|
13828 - | out.push_str(&url.authority());
|
13829 - | #[allow(clippy::needless_borrow)]
|
13830 - | out.push_str(&url.path());
|
13831 - | out
|
13832 - | })
|
13833 - | .property(
|
13834 - | "authSchemes",
|
13835 - | vec![::aws_smithy_types::Document::from({
|
13836 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13837 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13838 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13839 - | out.insert("signingName".to_string(), "s3-object-lambda".to_string().into());
|
13840 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
11206 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11207 + | }
|
11208 + | 46 => {
|
11209 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
11210 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11211 + | let bucket_partition = context.bucket_partition.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11212 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11213 + | let mut out = String::new();
|
11214 + | out.push_str("Client was configured for partition `");
|
11215 + | #[allow(clippy::needless_borrow)]
|
11216 + | out.push_str(&partition_result.name());
|
11217 + | out.push_str("` but ARN (`");
|
11218 + | #[allow(clippy::needless_borrow)]
|
11219 + | out.push_str(&bucket.as_ref());
|
11220 + | out.push_str("`) has `");
|
11221 + | #[allow(clippy::needless_borrow)]
|
11222 + | out.push_str(&bucket_partition.name());
|
11223 + | out.push('`');
|
13841 11224 | out
|
13842 - | })],
|
13843 - | )
|
13844 - | .build(),
|
13845 - | )
|
13846 - | }
|
13847 - | Self::Result41 => {
|
13848 - | let bucket_arn = context
|
13849 - | .bucket_arn
|
13850 - | .as_ref()
|
13851 - | .map(|s| s.clone())
|
13852 - | .expect("Guaranteed to have a value by earlier checks.");
|
13853 - | let effective_arn_region = context
|
13854 - | .effective_arn_region
|
13855 - | .as_ref()
|
13856 - | .map(|s| s.clone())
|
13857 - | .expect("Guaranteed to have a value by earlier checks.");
|
13858 - | let access_point_name_ssa_1 = context
|
13859 - | .access_point_name_ssa_1
|
13860 - | .as_ref()
|
13861 - | .map(|s| s.clone())
|
13862 - | .expect("Guaranteed to have a value by earlier checks.");
|
13863 - | let bucket_partition = context
|
13864 - | .bucket_partition
|
13865 - | .as_ref()
|
13866 - | .map(|s| s.clone())
|
13867 - | .expect("Guaranteed to have a value by earlier checks.");
|
13868 - | ::std::result::Result::Ok(
|
13869 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13870 - | .url({
|
13871 - | let mut out = String::new();
|
13872 - | out.push_str("https://");
|
13873 - | #[allow(clippy::needless_borrow)]
|
13874 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
13875 - | out.push('-');
|
13876 - | #[allow(clippy::needless_borrow)]
|
13877 - | out.push_str(&bucket_arn.account_id());
|
13878 - | out.push_str(".s3-object-lambda-fips.");
|
13879 - | #[allow(clippy::needless_borrow)]
|
13880 - | out.push_str(&effective_arn_region.as_ref());
|
13881 - | out.push('.');
|
13882 - | #[allow(clippy::needless_borrow)]
|
13883 - | out.push_str(&bucket_partition.dns_suffix());
|
13884 - | out
|
13885 - | })
|
13886 - | .property(
|
13887 - | "authSchemes",
|
13888 - | vec![::aws_smithy_types::Document::from({
|
13889 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13890 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13891 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13892 - | out.insert("signingName".to_string(), "s3-object-lambda".to_string().into());
|
13893 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
11225 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11226 + | }
|
11227 + | 47 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11228 + | "Invalid ARN: The ARN may only contain a single resource component after `accesspoint`.".to_string(),
|
11229 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11230 + | 48 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11231 + | "Invalid ARN: bucket ARN is missing a region".to_string(),
|
11232 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11233 + | 49 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11234 + | "Invalid ARN: Expected a resource of the format `accesspoint:<accesspoint name>` but no name was provided".to_string(),
|
11235 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11236 + | 50 => {
|
11237 + | let arn_type = context.arn_type.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11238 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11239 + | let mut out = String::new();
|
11240 + | out.push_str("Invalid ARN: Object Lambda ARNs only support `accesspoint` arn types, but found: `");
|
11241 + | #[allow(clippy::needless_borrow)]
|
11242 + | out.push_str(&arn_type.as_ref());
|
11243 + | out.push('`');
|
13894 11244 | out
|
13895 - | })],
|
13896 - | )
|
13897 - | .build(),
|
13898 - | )
|
13899 - | }
|
13900 - | Self::Result42 => {
|
13901 - | let bucket_arn = context
|
13902 - | .bucket_arn
|
13903 - | .as_ref()
|
13904 - | .map(|s| s.clone())
|
13905 - | .expect("Guaranteed to have a value by earlier checks.");
|
13906 - | let effective_arn_region = context
|
13907 - | .effective_arn_region
|
13908 - | .as_ref()
|
13909 - | .map(|s| s.clone())
|
13910 - | .expect("Guaranteed to have a value by earlier checks.");
|
13911 - | let access_point_name_ssa_1 = context
|
13912 - | .access_point_name_ssa_1
|
13913 - | .as_ref()
|
13914 - | .map(|s| s.clone())
|
13915 - | .expect("Guaranteed to have a value by earlier checks.");
|
13916 - | let bucket_partition = context
|
13917 - | .bucket_partition
|
13918 - | .as_ref()
|
13919 - | .map(|s| s.clone())
|
13920 - | .expect("Guaranteed to have a value by earlier checks.");
|
13921 - | ::std::result::Result::Ok(
|
13922 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
13923 - | .url({
|
13924 - | let mut out = String::new();
|
13925 - | out.push_str("https://");
|
13926 - | #[allow(clippy::needless_borrow)]
|
13927 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
13928 - | out.push('-');
|
13929 - | #[allow(clippy::needless_borrow)]
|
13930 - | out.push_str(&bucket_arn.account_id());
|
13931 - | out.push_str(".s3-object-lambda.");
|
13932 - | #[allow(clippy::needless_borrow)]
|
13933 - | out.push_str(&effective_arn_region.as_ref());
|
13934 - | out.push('.');
|
13935 - | #[allow(clippy::needless_borrow)]
|
13936 - | out.push_str(&bucket_partition.dns_suffix());
|
13937 - | out
|
13938 - | })
|
13939 - | .property(
|
13940 - | "authSchemes",
|
13941 - | vec![::aws_smithy_types::Document::from({
|
13942 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
13943 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
13944 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
13945 - | out.insert("signingName".to_string(), "s3-object-lambda".to_string().into());
|
13946 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
11245 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11246 + | }
|
11247 + | 51 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11248 + | "Access Points do not support S3 Accelerate".to_string(),
|
11249 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11250 + | 52 => {
|
11251 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11252 + | let effective_arn_region = context
|
11253 + | .effective_arn_region
|
11254 + | .as_ref()
|
11255 + | .expect("Guaranteed to have a value by earlier checks.");
|
11256 + | let access_point_name_ssa_1 = context
|
11257 + | .access_point_name_ssa_1
|
11258 + | .as_ref()
|
11259 + | .expect("Guaranteed to have a value by earlier checks.");
|
11260 + | let bucket_partition = context.bucket_partition.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11261 + | ::std::result::Result::Ok(
|
11262 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11263 + | .url({
|
11264 + | let mut out = String::new();
|
11265 + | out.push_str("https://");
|
11266 + | #[allow(clippy::needless_borrow)]
|
11267 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11268 + | out.push('-');
|
11269 + | #[allow(clippy::needless_borrow)]
|
11270 + | out.push_str(&bucket_arn.account_id());
|
11271 + | out.push_str(".s3-accesspoint-fips.dualstack.");
|
11272 + | #[allow(clippy::needless_borrow)]
|
11273 + | out.push_str(&effective_arn_region.as_ref());
|
11274 + | out.push('.');
|
11275 + | #[allow(clippy::needless_borrow)]
|
11276 + | out.push_str(&bucket_partition.dns_suffix());
|
11277 + | out
|
11278 + | })
|
11279 + | .auth_scheme(
|
11280 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11281 + | .put("disableDoubleEncoding", true)
|
11282 + | .put("signingName", "s3")
|
11283 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11284 + | )
|
11285 + | .build(),
|
11286 + | )
|
11287 + | }
|
11288 + | 53 => {
|
11289 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11290 + | let effective_arn_region = context
|
11291 + | .effective_arn_region
|
11292 + | .as_ref()
|
11293 + | .expect("Guaranteed to have a value by earlier checks.");
|
11294 + | let access_point_name_ssa_1 = context
|
11295 + | .access_point_name_ssa_1
|
11296 + | .as_ref()
|
11297 + | .expect("Guaranteed to have a value by earlier checks.");
|
11298 + | let bucket_partition = context.bucket_partition.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11299 + | ::std::result::Result::Ok(
|
11300 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11301 + | .url({
|
11302 + | let mut out = String::new();
|
11303 + | out.push_str("https://");
|
11304 + | #[allow(clippy::needless_borrow)]
|
11305 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11306 + | out.push('-');
|
11307 + | #[allow(clippy::needless_borrow)]
|
11308 + | out.push_str(&bucket_arn.account_id());
|
11309 + | out.push_str(".s3-accesspoint-fips.");
|
11310 + | #[allow(clippy::needless_borrow)]
|
11311 + | out.push_str(&effective_arn_region.as_ref());
|
11312 + | out.push('.');
|
11313 + | #[allow(clippy::needless_borrow)]
|
11314 + | out.push_str(&bucket_partition.dns_suffix());
|
11315 + | out
|
11316 + | })
|
11317 + | .auth_scheme(
|
11318 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11319 + | .put("disableDoubleEncoding", true)
|
11320 + | .put("signingName", "s3")
|
11321 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11322 + | )
|
11323 + | .build(),
|
11324 + | )
|
11325 + | }
|
11326 + | 54 => {
|
11327 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11328 + | let effective_arn_region = context
|
11329 + | .effective_arn_region
|
11330 + | .as_ref()
|
11331 + | .expect("Guaranteed to have a value by earlier checks.");
|
11332 + | let access_point_name_ssa_1 = context
|
11333 + | .access_point_name_ssa_1
|
11334 + | .as_ref()
|
11335 + | .expect("Guaranteed to have a value by earlier checks.");
|
11336 + | let bucket_partition = context.bucket_partition.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11337 + | ::std::result::Result::Ok(
|
11338 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11339 + | .url({
|
11340 + | let mut out = String::new();
|
11341 + | out.push_str("https://");
|
11342 + | #[allow(clippy::needless_borrow)]
|
11343 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11344 + | out.push('-');
|
11345 + | #[allow(clippy::needless_borrow)]
|
11346 + | out.push_str(&bucket_arn.account_id());
|
11347 + | out.push_str(".s3-accesspoint.dualstack.");
|
11348 + | #[allow(clippy::needless_borrow)]
|
11349 + | out.push_str(&effective_arn_region.as_ref());
|
11350 + | out.push('.');
|
11351 + | #[allow(clippy::needless_borrow)]
|
11352 + | out.push_str(&bucket_partition.dns_suffix());
|
11353 + | out
|
11354 + | })
|
11355 + | .auth_scheme(
|
11356 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11357 + | .put("disableDoubleEncoding", true)
|
11358 + | .put("signingName", "s3")
|
11359 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11360 + | )
|
11361 + | .build(),
|
11362 + | )
|
11363 + | }
|
11364 + | 55 => {
|
11365 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11366 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11367 + | let effective_arn_region = context
|
11368 + | .effective_arn_region
|
11369 + | .as_ref()
|
11370 + | .expect("Guaranteed to have a value by earlier checks.");
|
11371 + | let access_point_name_ssa_1 = context
|
11372 + | .access_point_name_ssa_1
|
11373 + | .as_ref()
|
11374 + | .expect("Guaranteed to have a value by earlier checks.");
|
11375 + | ::std::result::Result::Ok(
|
11376 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11377 + | .url({
|
11378 + | let mut out = String::new();
|
11379 + | #[allow(clippy::needless_borrow)]
|
11380 + | out.push_str(&url.scheme());
|
11381 + | out.push_str("://");
|
11382 + | #[allow(clippy::needless_borrow)]
|
11383 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11384 + | out.push('-');
|
11385 + | #[allow(clippy::needless_borrow)]
|
11386 + | out.push_str(&bucket_arn.account_id());
|
11387 + | out.push('.');
|
11388 + | #[allow(clippy::needless_borrow)]
|
11389 + | out.push_str(&url.authority());
|
11390 + | #[allow(clippy::needless_borrow)]
|
11391 + | out.push_str(&url.path());
|
11392 + | out
|
11393 + | })
|
11394 + | .auth_scheme(
|
11395 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11396 + | .put("disableDoubleEncoding", true)
|
11397 + | .put("signingName", "s3")
|
11398 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11399 + | )
|
11400 + | .build(),
|
11401 + | )
|
11402 + | }
|
11403 + | 56 => {
|
11404 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11405 + | let effective_arn_region = context
|
11406 + | .effective_arn_region
|
11407 + | .as_ref()
|
11408 + | .expect("Guaranteed to have a value by earlier checks.");
|
11409 + | let access_point_name_ssa_1 = context
|
11410 + | .access_point_name_ssa_1
|
11411 + | .as_ref()
|
11412 + | .expect("Guaranteed to have a value by earlier checks.");
|
11413 + | let bucket_partition = context.bucket_partition.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11414 + | ::std::result::Result::Ok(
|
11415 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11416 + | .url({
|
11417 + | let mut out = String::new();
|
11418 + | out.push_str("https://");
|
11419 + | #[allow(clippy::needless_borrow)]
|
11420 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11421 + | out.push('-');
|
11422 + | #[allow(clippy::needless_borrow)]
|
11423 + | out.push_str(&bucket_arn.account_id());
|
11424 + | out.push_str(".s3-accesspoint.");
|
11425 + | #[allow(clippy::needless_borrow)]
|
11426 + | out.push_str(&effective_arn_region.as_ref());
|
11427 + | out.push('.');
|
11428 + | #[allow(clippy::needless_borrow)]
|
11429 + | out.push_str(&bucket_partition.dns_suffix());
|
11430 + | out
|
11431 + | })
|
11432 + | .auth_scheme(
|
11433 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11434 + | .put("disableDoubleEncoding", true)
|
11435 + | .put("signingName", "s3")
|
11436 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11437 + | )
|
11438 + | .build(),
|
11439 + | )
|
11440 + | }
|
11441 + | 57 => {
|
11442 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11443 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11444 + | let mut out = String::new();
|
11445 + | out.push_str("Invalid ARN: The ARN was not for the S3 service, found: ");
|
11446 + | #[allow(clippy::needless_borrow)]
|
11447 + | out.push_str(&bucket_arn.service());
|
13947 11448 | out
|
13948 - | })],
|
13949 - | )
|
13950 - | .build(),
|
13951 - | )
|
13952 - | }
|
13953 - | Self::Result43 => {
|
13954 - | let access_point_name_ssa_1 = context
|
13955 - | .access_point_name_ssa_1
|
13956 - | .as_ref()
|
13957 - | .map(|s| s.clone())
|
13958 - | .expect("Guaranteed to have a value by earlier checks.");
|
13959 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
13960 - | let mut out = String::new();
|
13961 - | out.push_str("Invalid ARN: The access point name may only contain a-z, A-Z, 0-9 and `-`. Found: `");
|
13962 - | #[allow(clippy::needless_borrow)]
|
13963 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
13964 - | out.push('`');
|
13965 - | out
|
13966 - | }))
|
13967 - | }
|
13968 - | Self::Result44 => {
|
13969 - | let bucket_arn = context
|
13970 - | .bucket_arn
|
13971 - | .as_ref()
|
13972 - | .map(|s| s.clone())
|
13973 - | .expect("Guaranteed to have a value by earlier checks.");
|
13974 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
13975 - | let mut out = String::new();
|
13976 - | out.push_str("Invalid ARN: The account id may only contain a-z, A-Z, 0-9 and `-`. Found: `");
|
13977 - | #[allow(clippy::needless_borrow)]
|
13978 - | out.push_str(&bucket_arn.account_id());
|
13979 - | out.push('`');
|
13980 - | out
|
13981 - | }))
|
13982 - | }
|
13983 - | Self::Result45 => {
|
13984 - | let bucket_arn = context
|
13985 - | .bucket_arn
|
13986 - | .as_ref()
|
13987 - | .map(|s| s.clone())
|
13988 - | .expect("Guaranteed to have a value by earlier checks.");
|
13989 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
13990 - | let mut out = String::new();
|
13991 - | out.push_str("Invalid region in ARN: `");
|
13992 - | #[allow(clippy::needless_borrow)]
|
13993 - | out.push_str(&bucket_arn.region());
|
13994 - | out.push_str("` (invalid DNS name)");
|
13995 - | out
|
13996 - | }))
|
13997 - | }
|
13998 - | Self::Result46 => {
|
13999 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
14000 - | let partition_result = context
|
14001 - | .partition_result
|
14002 - | .as_ref()
|
14003 - | .map(|s| s.clone())
|
14004 - | .expect("Guaranteed to have a value by earlier checks.");
|
14005 - | let bucket_partition = context
|
14006 - | .bucket_partition
|
14007 - | .as_ref()
|
14008 - | .map(|s| s.clone())
|
14009 - | .expect("Guaranteed to have a value by earlier checks.");
|
14010 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
14011 - | let mut out = String::new();
|
14012 - | out.push_str("Client was configured for partition `");
|
14013 - | #[allow(clippy::needless_borrow)]
|
14014 - | out.push_str(&partition_result.name());
|
14015 - | out.push_str("` but ARN (`");
|
14016 - | #[allow(clippy::needless_borrow)]
|
14017 - | out.push_str(&bucket.as_ref());
|
14018 - | out.push_str("`) has `");
|
14019 - | #[allow(clippy::needless_borrow)]
|
14020 - | out.push_str(&bucket_partition.name());
|
14021 - | out.push('`');
|
14022 - | out
|
14023 - | }))
|
14024 - | }
|
14025 - | Self::Result47 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14026 - | "Invalid ARN: The ARN may only contain a single resource component after `accesspoint`.".to_string(),
|
14027 - | )),
|
14028 - | Self::Result48 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14029 - | "Invalid ARN: bucket ARN is missing a region".to_string(),
|
14030 - | )),
|
14031 - | Self::Result49 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14032 - | "Invalid ARN: Expected a resource of the format `accesspoint:<accesspoint name>` but no name was provided".to_string(),
|
14033 - | )),
|
14034 - | Self::Result50 => {
|
14035 - | let arn_type = context
|
14036 - | .arn_type
|
14037 - | .as_ref()
|
14038 - | .map(|s| s.clone())
|
14039 - | .expect("Guaranteed to have a value by earlier checks.");
|
14040 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
14041 - | let mut out = String::new();
|
14042 - | out.push_str("Invalid ARN: Object Lambda ARNs only support `accesspoint` arn types, but found: `");
|
14043 - | #[allow(clippy::needless_borrow)]
|
14044 - | out.push_str(&arn_type.as_ref());
|
14045 - | out.push('`');
|
14046 - | out
|
14047 - | }))
|
14048 - | }
|
14049 - | Self::Result51 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14050 - | "Access Points do not support S3 Accelerate".to_string(),
|
14051 - | )),
|
14052 - | Self::Result52 => {
|
14053 - | let bucket_arn = context
|
14054 - | .bucket_arn
|
14055 - | .as_ref()
|
14056 - | .map(|s| s.clone())
|
14057 - | .expect("Guaranteed to have a value by earlier checks.");
|
14058 - | let effective_arn_region = context
|
14059 - | .effective_arn_region
|
14060 - | .as_ref()
|
14061 - | .map(|s| s.clone())
|
14062 - | .expect("Guaranteed to have a value by earlier checks.");
|
14063 - | let access_point_name_ssa_1 = context
|
14064 - | .access_point_name_ssa_1
|
14065 - | .as_ref()
|
14066 - | .map(|s| s.clone())
|
14067 - | .expect("Guaranteed to have a value by earlier checks.");
|
14068 - | let bucket_partition = context
|
14069 - | .bucket_partition
|
14070 - | .as_ref()
|
14071 - | .map(|s| s.clone())
|
14072 - | .expect("Guaranteed to have a value by earlier checks.");
|
14073 - | ::std::result::Result::Ok(
|
14074 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14075 - | .url({
|
14076 - | let mut out = String::new();
|
14077 - | out.push_str("https://");
|
14078 - | #[allow(clippy::needless_borrow)]
|
14079 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
14080 - | out.push('-');
|
14081 - | #[allow(clippy::needless_borrow)]
|
14082 - | out.push_str(&bucket_arn.account_id());
|
14083 - | out.push_str(".s3-accesspoint-fips.dualstack.");
|
14084 - | #[allow(clippy::needless_borrow)]
|
14085 - | out.push_str(&effective_arn_region.as_ref());
|
14086 - | out.push('.');
|
14087 - | #[allow(clippy::needless_borrow)]
|
14088 - | out.push_str(&bucket_partition.dns_suffix());
|
14089 - | out
|
14090 - | })
|
14091 - | .property(
|
14092 - | "authSchemes",
|
14093 - | vec![::aws_smithy_types::Document::from({
|
14094 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14095 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14096 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14097 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14098 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
11449 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11450 + | }
|
11451 + | 58 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11452 + | "S3 MRAP does not support dual-stack".to_string(),
|
11453 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11454 + | 59 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11455 + | "S3 MRAP does not support FIPS".to_string(),
|
11456 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11457 + | 60 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11458 + | "S3 MRAP does not support S3 Accelerate".to_string(),
|
11459 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11460 + | 61 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11461 + | "Invalid configuration: Multi-Region Access Point ARNs are disabled.".to_string(),
|
11462 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11463 + | 62 => {
|
11464 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11465 + | let access_point_name_ssa_1 = context
|
11466 + | .access_point_name_ssa_1
|
11467 + | .as_ref()
|
11468 + | .expect("Guaranteed to have a value by earlier checks.");
|
11469 + | ::std::result::Result::Ok(
|
11470 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11471 + | .url({
|
11472 + | let mut out = String::new();
|
11473 + | out.push_str("https://");
|
11474 + | #[allow(clippy::needless_borrow)]
|
11475 + | out.push_str(&access_point_name_ssa_1.as_ref());
|
11476 + | out.push_str(".accesspoint.s3-global.");
|
11477 + | #[allow(clippy::needless_borrow)]
|
11478 + | out.push_str(&partition_result.dns_suffix());
|
11479 + | out
|
11480 + | })
|
11481 + | .auth_scheme(
|
11482 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4a".to_string(), 3)
|
11483 + | .put("disableDoubleEncoding", true)
|
11484 + | .put("signingName", "s3")
|
11485 + | .put("signingRegionSet", vec![::aws_smithy_types::Document::from("*".to_string())]),
|
11486 + | )
|
11487 + | .build(),
|
11488 + | )
|
11489 + | }
|
11490 + | 63 => {
|
11491 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11492 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11493 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11494 + | let mut out = String::new();
|
11495 + | out.push_str("Client was configured for partition `");
|
11496 + | #[allow(clippy::needless_borrow)]
|
11497 + | out.push_str(&partition_result.name());
|
11498 + | out.push_str("` but bucket referred to partition `");
|
11499 + | #[allow(clippy::needless_borrow)]
|
11500 + | out.push_str(&bucket_arn.partition());
|
11501 + | out.push('`');
|
14099 11502 | out
|
14100 - | })],
|
14101 - | )
|
14102 - | .build(),
|
14103 - | )
|
14104 - | }
|
14105 - | Self::Result53 => {
|
14106 - | let bucket_arn = context
|
14107 - | .bucket_arn
|
14108 - | .as_ref()
|
14109 - | .map(|s| s.clone())
|
14110 - | .expect("Guaranteed to have a value by earlier checks.");
|
14111 - | let effective_arn_region = context
|
14112 - | .effective_arn_region
|
14113 - | .as_ref()
|
14114 - | .map(|s| s.clone())
|
14115 - | .expect("Guaranteed to have a value by earlier checks.");
|
14116 - | let access_point_name_ssa_1 = context
|
14117 - | .access_point_name_ssa_1
|
14118 - | .as_ref()
|
14119 - | .map(|s| s.clone())
|
14120 - | .expect("Guaranteed to have a value by earlier checks.");
|
14121 - | let bucket_partition = context
|
14122 - | .bucket_partition
|
14123 - | .as_ref()
|
14124 - | .map(|s| s.clone())
|
14125 - | .expect("Guaranteed to have a value by earlier checks.");
|
14126 - | ::std::result::Result::Ok(
|
14127 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14128 - | .url({
|
14129 - | let mut out = String::new();
|
14130 - | out.push_str("https://");
|
14131 - | #[allow(clippy::needless_borrow)]
|
14132 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
14133 - | out.push('-');
|
14134 - | #[allow(clippy::needless_borrow)]
|
14135 - | out.push_str(&bucket_arn.account_id());
|
14136 - | out.push_str(".s3-accesspoint-fips.");
|
14137 - | #[allow(clippy::needless_borrow)]
|
14138 - | out.push_str(&effective_arn_region.as_ref());
|
14139 - | out.push('.');
|
14140 - | #[allow(clippy::needless_borrow)]
|
14141 - | out.push_str(&bucket_partition.dns_suffix());
|
14142 - | out
|
14143 - | })
|
14144 - | .property(
|
14145 - | "authSchemes",
|
14146 - | vec![::aws_smithy_types::Document::from({
|
14147 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14148 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14149 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14150 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14151 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
11503 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11504 + | }
|
11505 + | 64 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11506 + | "Invalid Access Point Name".to_string(),
|
11507 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11508 + | 65 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11509 + | "S3 Outposts does not support Dual-stack".to_string(),
|
11510 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11511 + | 66 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11512 + | "S3 Outposts does not support FIPS".to_string(),
|
11513 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11514 + | 67 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11515 + | "S3 Outposts does not support S3 Accelerate".to_string(),
|
11516 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11517 + | 68 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11518 + | "Invalid Arn: Outpost Access Point ARN contains sub resources".to_string(),
|
11519 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11520 + | 69 => {
|
11521 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11522 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11523 + | let effective_arn_region = context
|
11524 + | .effective_arn_region
|
11525 + | .as_ref()
|
11526 + | .expect("Guaranteed to have a value by earlier checks.");
|
11527 + | let outpost_id_ssa_1 = context.outpost_id_ssa_1.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11528 + | let access_point_name_ssa_2 = context
|
11529 + | .access_point_name_ssa_2
|
11530 + | .as_ref()
|
11531 + | .expect("Guaranteed to have a value by earlier checks.");
|
11532 + | ::std::result::Result::Ok(
|
11533 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11534 + | .url({
|
11535 + | let mut out = String::new();
|
11536 + | out.push_str("https://");
|
11537 + | #[allow(clippy::needless_borrow)]
|
11538 + | out.push_str(&access_point_name_ssa_2.as_ref());
|
11539 + | out.push('-');
|
11540 + | #[allow(clippy::needless_borrow)]
|
11541 + | out.push_str(&bucket_arn.account_id());
|
11542 + | out.push('.');
|
11543 + | #[allow(clippy::needless_borrow)]
|
11544 + | out.push_str(&outpost_id_ssa_1.as_ref());
|
11545 + | out.push('.');
|
11546 + | #[allow(clippy::needless_borrow)]
|
11547 + | out.push_str(&url.authority());
|
11548 + | out
|
11549 + | })
|
11550 + | .auth_scheme(
|
11551 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4a".to_string(), 3)
|
11552 + | .put("disableDoubleEncoding", true)
|
11553 + | .put("signingName", "s3-outposts")
|
11554 + | .put("signingRegionSet", vec![::aws_smithy_types::Document::from("*".to_string())]),
|
11555 + | )
|
11556 + | .auth_scheme(
|
11557 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11558 + | .put("disableDoubleEncoding", true)
|
11559 + | .put("signingName", "s3-outposts")
|
11560 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11561 + | )
|
11562 + | .build(),
|
11563 + | )
|
11564 + | }
|
11565 + | 70 => {
|
11566 + | let bucket_arn = context.bucket_arn.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11567 + | let effective_arn_region = context
|
11568 + | .effective_arn_region
|
11569 + | .as_ref()
|
11570 + | .expect("Guaranteed to have a value by earlier checks.");
|
11571 + | let bucket_partition = context.bucket_partition.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11572 + | let outpost_id_ssa_1 = context.outpost_id_ssa_1.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11573 + | let access_point_name_ssa_2 = context
|
11574 + | .access_point_name_ssa_2
|
11575 + | .as_ref()
|
11576 + | .expect("Guaranteed to have a value by earlier checks.");
|
11577 + | ::std::result::Result::Ok(
|
11578 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11579 + | .url({
|
11580 + | let mut out = String::new();
|
11581 + | out.push_str("https://");
|
11582 + | #[allow(clippy::needless_borrow)]
|
11583 + | out.push_str(&access_point_name_ssa_2.as_ref());
|
11584 + | out.push('-');
|
11585 + | #[allow(clippy::needless_borrow)]
|
11586 + | out.push_str(&bucket_arn.account_id());
|
11587 + | out.push('.');
|
11588 + | #[allow(clippy::needless_borrow)]
|
11589 + | out.push_str(&outpost_id_ssa_1.as_ref());
|
11590 + | out.push_str(".s3-outposts.");
|
11591 + | #[allow(clippy::needless_borrow)]
|
11592 + | out.push_str(&effective_arn_region.as_ref());
|
11593 + | out.push('.');
|
11594 + | #[allow(clippy::needless_borrow)]
|
11595 + | out.push_str(&bucket_partition.dns_suffix());
|
11596 + | out
|
11597 + | })
|
11598 + | .auth_scheme(
|
11599 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4a".to_string(), 3)
|
11600 + | .put("disableDoubleEncoding", true)
|
11601 + | .put("signingName", "s3-outposts")
|
11602 + | .put("signingRegionSet", vec![::aws_smithy_types::Document::from("*".to_string())]),
|
11603 + | )
|
11604 + | .auth_scheme(
|
11605 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11606 + | .put("disableDoubleEncoding", true)
|
11607 + | .put("signingName", "s3-outposts")
|
11608 + | .put("signingRegion", effective_arn_region.as_ref()),
|
11609 + | )
|
11610 + | .build(),
|
11611 + | )
|
11612 + | }
|
11613 + | 71 => {
|
11614 + | let outpost_type = context.outpost_type.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11615 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11616 + | let mut out = String::new();
|
11617 + | out.push_str("Expected an outpost type `accesspoint`, found ");
|
11618 + | #[allow(clippy::needless_borrow)]
|
11619 + | out.push_str(&outpost_type.as_ref());
|
14152 11620 | out
|
14153 - | })],
|
14154 - | )
|
14155 - | .build(),
|
14156 - | )
|
14157 - | }
|
14158 - | Self::Result54 => {
|
14159 - | let bucket_arn = context
|
14160 - | .bucket_arn
|
14161 - | .as_ref()
|
14162 - | .map(|s| s.clone())
|
14163 - | .expect("Guaranteed to have a value by earlier checks.");
|
14164 - | let effective_arn_region = context
|
14165 - | .effective_arn_region
|
14166 - | .as_ref()
|
14167 - | .map(|s| s.clone())
|
14168 - | .expect("Guaranteed to have a value by earlier checks.");
|
14169 - | let access_point_name_ssa_1 = context
|
14170 - | .access_point_name_ssa_1
|
14171 - | .as_ref()
|
14172 - | .map(|s| s.clone())
|
14173 - | .expect("Guaranteed to have a value by earlier checks.");
|
14174 - | let bucket_partition = context
|
14175 - | .bucket_partition
|
14176 - | .as_ref()
|
14177 - | .map(|s| s.clone())
|
14178 - | .expect("Guaranteed to have a value by earlier checks.");
|
14179 - | ::std::result::Result::Ok(
|
14180 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14181 - | .url({
|
14182 - | let mut out = String::new();
|
14183 - | out.push_str("https://");
|
14184 - | #[allow(clippy::needless_borrow)]
|
14185 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
14186 - | out.push('-');
|
14187 - | #[allow(clippy::needless_borrow)]
|
14188 - | out.push_str(&bucket_arn.account_id());
|
14189 - | out.push_str(".s3-accesspoint.dualstack.");
|
14190 - | #[allow(clippy::needless_borrow)]
|
14191 - | out.push_str(&effective_arn_region.as_ref());
|
14192 - | out.push('.');
|
14193 - | #[allow(clippy::needless_borrow)]
|
14194 - | out.push_str(&bucket_partition.dns_suffix());
|
14195 - | out
|
14196 - | })
|
14197 - | .property(
|
14198 - | "authSchemes",
|
14199 - | vec![::aws_smithy_types::Document::from({
|
14200 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14201 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14202 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14203 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14204 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
11621 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11622 + | }
|
11623 + | 72 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11624 + | "Invalid ARN: expected an access point name".to_string(),
|
11625 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11626 + | 73 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11627 + | "Invalid ARN: Expected a 4-component resource".to_string(),
|
11628 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11629 + | 74 => {
|
11630 + | let outpost_id_ssa_1 = context.outpost_id_ssa_1.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11631 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11632 + | let mut out = String::new();
|
11633 + | out.push_str("Invalid ARN: The outpost Id may only contain a-z, A-Z, 0-9 and `-`. Found: `");
|
11634 + | #[allow(clippy::needless_borrow)]
|
11635 + | out.push_str(&outpost_id_ssa_1.as_ref());
|
11636 + | out.push('`');
|
14205 11637 | out
|
14206 - | })],
|
14207 - | )
|
14208 - | .build(),
|
14209 - | )
|
14210 - | }
|
14211 - | Self::Result55 => {
|
14212 - | let url = context
|
14213 - | .url
|
14214 - | .as_ref()
|
14215 - | .map(|s| s.clone())
|
14216 - | .expect("Guaranteed to have a value by earlier checks.");
|
14217 - | let bucket_arn = context
|
14218 - | .bucket_arn
|
14219 - | .as_ref()
|
14220 - | .map(|s| s.clone())
|
14221 - | .expect("Guaranteed to have a value by earlier checks.");
|
14222 - | let effective_arn_region = context
|
14223 - | .effective_arn_region
|
14224 - | .as_ref()
|
14225 - | .map(|s| s.clone())
|
14226 - | .expect("Guaranteed to have a value by earlier checks.");
|
14227 - | let access_point_name_ssa_1 = context
|
14228 - | .access_point_name_ssa_1
|
14229 - | .as_ref()
|
14230 - | .map(|s| s.clone())
|
14231 - | .expect("Guaranteed to have a value by earlier checks.");
|
14232 - | ::std::result::Result::Ok(
|
14233 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14234 - | .url({
|
14235 - | let mut out = String::new();
|
14236 - | #[allow(clippy::needless_borrow)]
|
14237 - | out.push_str(&url.scheme());
|
14238 - | out.push_str("://");
|
14239 - | #[allow(clippy::needless_borrow)]
|
14240 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
14241 - | out.push('-');
|
14242 - | #[allow(clippy::needless_borrow)]
|
14243 - | out.push_str(&bucket_arn.account_id());
|
14244 - | out.push('.');
|
14245 - | #[allow(clippy::needless_borrow)]
|
14246 - | out.push_str(&url.authority());
|
14247 - | #[allow(clippy::needless_borrow)]
|
14248 - | out.push_str(&url.path());
|
14249 - | out
|
14250 - | })
|
14251 - | .property(
|
14252 - | "authSchemes",
|
14253 - | vec![::aws_smithy_types::Document::from({
|
14254 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14255 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14256 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14257 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14258 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
11638 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11639 + | }
|
11640 + | 75 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11641 + | "Invalid ARN: The Outpost Id was not set".to_string(),
|
11642 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11643 + | 76 => {
|
11644 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
11645 + | let arn_type = context.arn_type.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11646 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11647 + | let mut out = String::new();
|
11648 + | out.push_str("Invalid ARN: Unrecognized format: ");
|
11649 + | #[allow(clippy::needless_borrow)]
|
11650 + | out.push_str(&bucket.as_ref());
|
11651 + | out.push_str(" (type: ");
|
11652 + | #[allow(clippy::needless_borrow)]
|
11653 + | out.push_str(&arn_type.as_ref());
|
11654 + | out.push(')');
|
14259 11655 | out
|
14260 - | })],
|
14261 - | )
|
14262 - | .build(),
|
14263 - | )
|
14264 - | }
|
14265 - | Self::Result56 => {
|
14266 - | let bucket_arn = context
|
14267 - | .bucket_arn
|
14268 - | .as_ref()
|
14269 - | .map(|s| s.clone())
|
14270 - | .expect("Guaranteed to have a value by earlier checks.");
|
14271 - | let effective_arn_region = context
|
14272 - | .effective_arn_region
|
14273 - | .as_ref()
|
14274 - | .map(|s| s.clone())
|
14275 - | .expect("Guaranteed to have a value by earlier checks.");
|
14276 - | let access_point_name_ssa_1 = context
|
14277 - | .access_point_name_ssa_1
|
14278 - | .as_ref()
|
14279 - | .map(|s| s.clone())
|
14280 - | .expect("Guaranteed to have a value by earlier checks.");
|
14281 - | let bucket_partition = context
|
14282 - | .bucket_partition
|
14283 - | .as_ref()
|
14284 - | .map(|s| s.clone())
|
14285 - | .expect("Guaranteed to have a value by earlier checks.");
|
14286 - | ::std::result::Result::Ok(
|
14287 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14288 - | .url({
|
14289 - | let mut out = String::new();
|
14290 - | out.push_str("https://");
|
14291 - | #[allow(clippy::needless_borrow)]
|
14292 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
14293 - | out.push('-');
|
14294 - | #[allow(clippy::needless_borrow)]
|
14295 - | out.push_str(&bucket_arn.account_id());
|
14296 - | out.push_str(".s3-accesspoint.");
|
14297 - | #[allow(clippy::needless_borrow)]
|
14298 - | out.push_str(&effective_arn_region.as_ref());
|
14299 - | out.push('.');
|
14300 - | #[allow(clippy::needless_borrow)]
|
14301 - | out.push_str(&bucket_partition.dns_suffix());
|
14302 - | out
|
14303 - | })
|
14304 - | .property(
|
14305 - | "authSchemes",
|
14306 - | vec![::aws_smithy_types::Document::from({
|
14307 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14308 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14309 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14310 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14311 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
11656 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11657 + | }
|
11658 + | 77 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11659 + | "Invalid ARN: No ARN type specified".to_string(),
|
11660 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11661 + | 78 => {
|
11662 + | let bucket = params.bucket.as_deref().unwrap_or_default();
|
11663 + | ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
11664 + | let mut out = String::new();
|
11665 + | out.push_str("Invalid ARN: `");
|
11666 + | #[allow(clippy::needless_borrow)]
|
11667 + | out.push_str(&bucket.as_ref());
|
11668 + | out.push_str("` was not a valid ARN");
|
14312 11669 | out
|
14313 - | })],
|
14314 - | )
|
14315 - | .build(),
|
14316 - | )
|
14317 - | }
|
14318 - | Self::Result57 => {
|
14319 - | let bucket_arn = context
|
14320 - | .bucket_arn
|
14321 - | .as_ref()
|
14322 - | .map(|s| s.clone())
|
14323 - | .expect("Guaranteed to have a value by earlier checks.");
|
14324 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
14325 - | let mut out = String::new();
|
14326 - | out.push_str("Invalid ARN: The ARN was not for the S3 service, found: ");
|
14327 - | #[allow(clippy::needless_borrow)]
|
14328 - | out.push_str(&bucket_arn.service());
|
14329 - | out
|
14330 - | }))
|
14331 - | }
|
14332 - | Self::Result58 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14333 - | "S3 MRAP does not support dual-stack".to_string(),
|
14334 - | )),
|
14335 - | Self::Result59 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14336 - | "S3 MRAP does not support FIPS".to_string(),
|
14337 - | )),
|
14338 - | Self::Result60 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14339 - | "S3 MRAP does not support S3 Accelerate".to_string(),
|
14340 - | )),
|
14341 - | Self::Result61 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14342 - | "Invalid configuration: Multi-Region Access Point ARNs are disabled.".to_string(),
|
14343 - | )),
|
14344 - | Self::Result62 => {
|
14345 - | let partition_result = context
|
14346 - | .partition_result
|
14347 - | .as_ref()
|
14348 - | .map(|s| s.clone())
|
14349 - | .expect("Guaranteed to have a value by earlier checks.");
|
14350 - | let access_point_name_ssa_1 = context
|
14351 - | .access_point_name_ssa_1
|
14352 - | .as_ref()
|
14353 - | .map(|s| s.clone())
|
14354 - | .expect("Guaranteed to have a value by earlier checks.");
|
14355 - | ::std::result::Result::Ok(
|
14356 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14357 - | .url({
|
14358 - | let mut out = String::new();
|
14359 - | out.push_str("https://");
|
14360 - | #[allow(clippy::needless_borrow)]
|
14361 - | out.push_str(&access_point_name_ssa_1.as_ref());
|
14362 - | out.push_str(".accesspoint.s3-global.");
|
14363 - | #[allow(clippy::needless_borrow)]
|
14364 - | out.push_str(&partition_result.dns_suffix());
|
14365 - | out
|
14366 - | })
|
14367 - | .property(
|
14368 - | "authSchemes",
|
14369 - | vec![::aws_smithy_types::Document::from({
|
14370 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14371 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14372 - | out.insert("name".to_string(), "sigv4a".to_string().into());
|
14373 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14374 - | out.insert(
|
14375 - | "signingRegionSet".to_string(),
|
14376 - | vec![::aws_smithy_types::Document::from("*".to_string())].into(),
|
11670 + | })) as ::aws_smithy_runtime_api::box_error::BoxError)
|
11671 + | }
|
11672 + | 79 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11673 + | "Path-style addressing cannot be used with ARN buckets".to_string(),
|
11674 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11675 + | 80 => {
|
11676 + | let effective_std_region = context
|
11677 + | .effective_std_region
|
11678 + | .as_ref()
|
11679 + | .expect("Guaranteed to have a value by earlier checks.");
|
11680 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11681 + | let uri_encoded_bucket = context
|
11682 + | .uri_encoded_bucket
|
11683 + | .as_ref()
|
11684 + | .expect("Guaranteed to have a value by earlier checks.");
|
11685 + | ::std::result::Result::Ok(
|
11686 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11687 + | .url({
|
11688 + | let mut out = String::new();
|
11689 + | out.push_str("https://s3-fips.dualstack.");
|
11690 + | #[allow(clippy::needless_borrow)]
|
11691 + | out.push_str(&effective_std_region.as_ref());
|
11692 + | out.push('.');
|
11693 + | #[allow(clippy::needless_borrow)]
|
11694 + | out.push_str(&partition_result.dns_suffix());
|
11695 + | out.push('/');
|
11696 + | #[allow(clippy::needless_borrow)]
|
11697 + | out.push_str(&uri_encoded_bucket.as_ref());
|
11698 + | out
|
11699 + | })
|
11700 + | .auth_scheme(
|
11701 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11702 + | .put("disableDoubleEncoding", true)
|
11703 + | .put("signingName", "s3")
|
11704 + | .put("signingRegion", effective_std_region.as_ref()),
|
11705 + | )
|
11706 + | .build(),
|
11707 + | )
|
11708 + | }
|
11709 + | 81 => {
|
11710 + | let effective_std_region = context
|
11711 + | .effective_std_region
|
11712 + | .as_ref()
|
11713 + | .expect("Guaranteed to have a value by earlier checks.");
|
11714 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11715 + | let uri_encoded_bucket = context
|
11716 + | .uri_encoded_bucket
|
11717 + | .as_ref()
|
11718 + | .expect("Guaranteed to have a value by earlier checks.");
|
11719 + | ::std::result::Result::Ok(
|
11720 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11721 + | .url({
|
11722 + | let mut out = String::new();
|
11723 + | out.push_str("https://s3-fips.");
|
11724 + | #[allow(clippy::needless_borrow)]
|
11725 + | out.push_str(&effective_std_region.as_ref());
|
11726 + | out.push('.');
|
11727 + | #[allow(clippy::needless_borrow)]
|
11728 + | out.push_str(&partition_result.dns_suffix());
|
11729 + | out.push('/');
|
11730 + | #[allow(clippy::needless_borrow)]
|
11731 + | out.push_str(&uri_encoded_bucket.as_ref());
|
11732 + | out
|
11733 + | })
|
11734 + | .auth_scheme(
|
11735 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11736 + | .put("disableDoubleEncoding", true)
|
11737 + | .put("signingName", "s3")
|
11738 + | .put("signingRegion", effective_std_region.as_ref()),
|
11739 + | )
|
11740 + | .build(),
|
11741 + | )
|
11742 + | }
|
11743 + | 82 => {
|
11744 + | let effective_std_region = context
|
11745 + | .effective_std_region
|
11746 + | .as_ref()
|
11747 + | .expect("Guaranteed to have a value by earlier checks.");
|
11748 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11749 + | let uri_encoded_bucket = context
|
11750 + | .uri_encoded_bucket
|
11751 + | .as_ref()
|
11752 + | .expect("Guaranteed to have a value by earlier checks.");
|
11753 + | ::std::result::Result::Ok(
|
11754 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11755 + | .url({
|
11756 + | let mut out = String::new();
|
11757 + | out.push_str("https://s3.dualstack.");
|
11758 + | #[allow(clippy::needless_borrow)]
|
11759 + | out.push_str(&effective_std_region.as_ref());
|
11760 + | out.push('.');
|
11761 + | #[allow(clippy::needless_borrow)]
|
11762 + | out.push_str(&partition_result.dns_suffix());
|
11763 + | out.push('/');
|
11764 + | #[allow(clippy::needless_borrow)]
|
11765 + | out.push_str(&uri_encoded_bucket.as_ref());
|
11766 + | out
|
11767 + | })
|
11768 + | .auth_scheme(
|
11769 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11770 + | .put("disableDoubleEncoding", true)
|
11771 + | .put("signingName", "s3")
|
11772 + | .put("signingRegion", effective_std_region.as_ref()),
|
11773 + | )
|
11774 + | .build(),
|
11775 + | )
|
11776 + | }
|
11777 + | 83 => {
|
11778 + | let effective_std_region = context
|
11779 + | .effective_std_region
|
11780 + | .as_ref()
|
11781 + | .expect("Guaranteed to have a value by earlier checks.");
|
11782 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11783 + | let uri_encoded_bucket = context
|
11784 + | .uri_encoded_bucket
|
11785 + | .as_ref()
|
11786 + | .expect("Guaranteed to have a value by earlier checks.");
|
11787 + | ::std::result::Result::Ok(
|
11788 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11789 + | .url({
|
11790 + | let mut out = String::new();
|
11791 + | #[allow(clippy::needless_borrow)]
|
11792 + | out.push_str(&url.scheme());
|
11793 + | out.push_str("://");
|
11794 + | #[allow(clippy::needless_borrow)]
|
11795 + | out.push_str(&url.authority());
|
11796 + | #[allow(clippy::needless_borrow)]
|
11797 + | out.push_str(&url.normalized_path());
|
11798 + | #[allow(clippy::needless_borrow)]
|
11799 + | out.push_str(&uri_encoded_bucket.as_ref());
|
11800 + | out
|
11801 + | })
|
11802 + | .auth_scheme(
|
11803 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11804 + | .put("disableDoubleEncoding", true)
|
11805 + | .put("signingName", "s3")
|
11806 + | .put("signingRegion", effective_std_region.as_ref()),
|
11807 + | )
|
11808 + | .build(),
|
11809 + | )
|
11810 + | }
|
11811 + | 84 => {
|
11812 + | let effective_std_region = context
|
11813 + | .effective_std_region
|
11814 + | .as_ref()
|
11815 + | .expect("Guaranteed to have a value by earlier checks.");
|
11816 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11817 + | let uri_encoded_bucket = context
|
11818 + | .uri_encoded_bucket
|
11819 + | .as_ref()
|
11820 + | .expect("Guaranteed to have a value by earlier checks.");
|
11821 + | ::std::result::Result::Ok(
|
11822 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11823 + | .url({
|
11824 + | let mut out = String::new();
|
11825 + | out.push_str("https://s3.");
|
11826 + | #[allow(clippy::needless_borrow)]
|
11827 + | out.push_str(&partition_result.dns_suffix());
|
11828 + | out.push('/');
|
11829 + | #[allow(clippy::needless_borrow)]
|
11830 + | out.push_str(&uri_encoded_bucket.as_ref());
|
11831 + | out
|
11832 + | })
|
11833 + | .auth_scheme(
|
11834 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11835 + | .put("disableDoubleEncoding", true)
|
11836 + | .put("signingName", "s3")
|
11837 + | .put("signingRegion", effective_std_region.as_ref()),
|
11838 + | )
|
11839 + | .build(),
|
11840 + | )
|
11841 + | }
|
11842 + | 85 => {
|
11843 + | let effective_std_region = context
|
11844 + | .effective_std_region
|
11845 + | .as_ref()
|
11846 + | .expect("Guaranteed to have a value by earlier checks.");
|
11847 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11848 + | let uri_encoded_bucket = context
|
11849 + | .uri_encoded_bucket
|
11850 + | .as_ref()
|
11851 + | .expect("Guaranteed to have a value by earlier checks.");
|
11852 + | ::std::result::Result::Ok(
|
11853 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11854 + | .url({
|
11855 + | let mut out = String::new();
|
11856 + | out.push_str("https://s3.");
|
11857 + | #[allow(clippy::needless_borrow)]
|
11858 + | out.push_str(&effective_std_region.as_ref());
|
11859 + | out.push('.');
|
11860 + | #[allow(clippy::needless_borrow)]
|
11861 + | out.push_str(&partition_result.dns_suffix());
|
11862 + | out.push('/');
|
11863 + | #[allow(clippy::needless_borrow)]
|
11864 + | out.push_str(&uri_encoded_bucket.as_ref());
|
11865 + | out
|
11866 + | })
|
11867 + | .auth_scheme(
|
11868 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11869 + | .put("disableDoubleEncoding", true)
|
11870 + | .put("signingName", "s3")
|
11871 + | .put("signingRegion", effective_std_region.as_ref()),
|
11872 + | )
|
11873 + | .build(),
|
11874 + | )
|
11875 + | }
|
11876 + | 86 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
11877 + | "Path-style addressing cannot be used with S3 Accelerate".to_string(),
|
11878 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
11879 + | 87 => {
|
11880 + | let effective_std_region = context
|
11881 + | .effective_std_region
|
11882 + | .as_ref()
|
11883 + | .expect("Guaranteed to have a value by earlier checks.");
|
11884 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11885 + | ::std::result::Result::Ok(
|
11886 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11887 + | .url({
|
11888 + | let mut out = String::new();
|
11889 + | #[allow(clippy::needless_borrow)]
|
11890 + | out.push_str(&url.scheme());
|
11891 + | out.push_str("://");
|
11892 + | #[allow(clippy::needless_borrow)]
|
11893 + | out.push_str(&url.authority());
|
11894 + | #[allow(clippy::needless_borrow)]
|
11895 + | out.push_str(&url.path());
|
11896 + | out
|
11897 + | })
|
11898 + | .auth_scheme(
|
11899 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11900 + | .put("disableDoubleEncoding", true)
|
11901 + | .put("signingName", "s3-object-lambda")
|
11902 + | .put("signingRegion", effective_std_region.as_ref()),
|
11903 + | )
|
11904 + | .build(),
|
11905 + | )
|
11906 + | }
|
11907 + | 88 => {
|
11908 + | let effective_std_region = context
|
11909 + | .effective_std_region
|
11910 + | .as_ref()
|
11911 + | .expect("Guaranteed to have a value by earlier checks.");
|
11912 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11913 + | ::std::result::Result::Ok(
|
11914 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11915 + | .url({
|
11916 + | let mut out = String::new();
|
11917 + | out.push_str("https://s3-object-lambda-fips.");
|
11918 + | #[allow(clippy::needless_borrow)]
|
11919 + | out.push_str(&effective_std_region.as_ref());
|
11920 + | out.push('.');
|
11921 + | #[allow(clippy::needless_borrow)]
|
11922 + | out.push_str(&partition_result.dns_suffix());
|
11923 + | out
|
11924 + | })
|
11925 + | .auth_scheme(
|
11926 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11927 + | .put("disableDoubleEncoding", true)
|
11928 + | .put("signingName", "s3-object-lambda")
|
11929 + | .put("signingRegion", effective_std_region.as_ref()),
|
11930 + | )
|
11931 + | .build(),
|
11932 + | )
|
11933 + | }
|
11934 + | 89 => {
|
11935 + | let effective_std_region = context
|
11936 + | .effective_std_region
|
11937 + | .as_ref()
|
11938 + | .expect("Guaranteed to have a value by earlier checks.");
|
11939 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11940 + | ::std::result::Result::Ok(
|
11941 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11942 + | .url({
|
11943 + | let mut out = String::new();
|
11944 + | out.push_str("https://s3-object-lambda.");
|
11945 + | #[allow(clippy::needless_borrow)]
|
11946 + | out.push_str(&effective_std_region.as_ref());
|
11947 + | out.push('.');
|
11948 + | #[allow(clippy::needless_borrow)]
|
11949 + | out.push_str(&partition_result.dns_suffix());
|
11950 + | out
|
11951 + | })
|
11952 + | .auth_scheme(
|
11953 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11954 + | .put("disableDoubleEncoding", true)
|
11955 + | .put("signingName", "s3-object-lambda")
|
11956 + | .put("signingRegion", effective_std_region.as_ref()),
|
11957 + | )
|
11958 + | .build(),
|
11959 + | )
|
11960 + | }
|
11961 + | 90 => {
|
11962 + | let effective_std_region = context
|
11963 + | .effective_std_region
|
11964 + | .as_ref()
|
11965 + | .expect("Guaranteed to have a value by earlier checks.");
|
11966 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11967 + | ::std::result::Result::Ok(
|
11968 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11969 + | .url({
|
11970 + | let mut out = String::new();
|
11971 + | out.push_str("https://s3-fips.dualstack.");
|
11972 + | #[allow(clippy::needless_borrow)]
|
11973 + | out.push_str(&effective_std_region.as_ref());
|
11974 + | out.push('.');
|
11975 + | #[allow(clippy::needless_borrow)]
|
11976 + | out.push_str(&partition_result.dns_suffix());
|
11977 + | out
|
11978 + | })
|
11979 + | .auth_scheme(
|
11980 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
11981 + | .put("disableDoubleEncoding", true)
|
11982 + | .put("signingName", "s3")
|
11983 + | .put("signingRegion", effective_std_region.as_ref()),
|
11984 + | )
|
11985 + | .build(),
|
11986 + | )
|
11987 + | }
|
11988 + | 91 => {
|
11989 + | let effective_std_region = context
|
11990 + | .effective_std_region
|
11991 + | .as_ref()
|
11992 + | .expect("Guaranteed to have a value by earlier checks.");
|
11993 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
11994 + | ::std::result::Result::Ok(
|
11995 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
11996 + | .url({
|
11997 + | let mut out = String::new();
|
11998 + | out.push_str("https://s3-fips.");
|
11999 + | #[allow(clippy::needless_borrow)]
|
12000 + | out.push_str(&effective_std_region.as_ref());
|
12001 + | out.push('.');
|
12002 + | #[allow(clippy::needless_borrow)]
|
12003 + | out.push_str(&partition_result.dns_suffix());
|
12004 + | out
|
12005 + | })
|
12006 + | .auth_scheme(
|
12007 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
12008 + | .put("disableDoubleEncoding", true)
|
12009 + | .put("signingName", "s3")
|
12010 + | .put("signingRegion", effective_std_region.as_ref()),
|
12011 + | )
|
12012 + | .build(),
|
12013 + | )
|
12014 + | }
|
12015 + | 92 => {
|
12016 + | let effective_std_region = context
|
12017 + | .effective_std_region
|
12018 + | .as_ref()
|
12019 + | .expect("Guaranteed to have a value by earlier checks.");
|
12020 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
12021 + | ::std::result::Result::Ok(
|
12022 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
12023 + | .url({
|
12024 + | let mut out = String::new();
|
12025 + | out.push_str("https://s3.dualstack.");
|
12026 + | #[allow(clippy::needless_borrow)]
|
12027 + | out.push_str(&effective_std_region.as_ref());
|
12028 + | out.push('.');
|
12029 + | #[allow(clippy::needless_borrow)]
|
12030 + | out.push_str(&partition_result.dns_suffix());
|
12031 + | out
|
12032 + | })
|
12033 + | .auth_scheme(
|
12034 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
12035 + | .put("disableDoubleEncoding", true)
|
12036 + | .put("signingName", "s3")
|
12037 + | .put("signingRegion", effective_std_region.as_ref()),
|
12038 + | )
|
12039 + | .build(),
|
12040 + | )
|
12041 + | }
|
12042 + | 93 => {
|
12043 + | let effective_std_region = context
|
12044 + | .effective_std_region
|
12045 + | .as_ref()
|
12046 + | .expect("Guaranteed to have a value by earlier checks.");
|
12047 + | let url = context.url.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
12048 + | ::std::result::Result::Ok(
|
12049 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
12050 + | .url({
|
12051 + | let mut out = String::new();
|
12052 + | #[allow(clippy::needless_borrow)]
|
12053 + | out.push_str(&url.scheme());
|
12054 + | out.push_str("://");
|
12055 + | #[allow(clippy::needless_borrow)]
|
12056 + | out.push_str(&url.authority());
|
12057 + | #[allow(clippy::needless_borrow)]
|
12058 + | out.push_str(&url.path());
|
12059 + | out
|
12060 + | })
|
12061 + | .auth_scheme(
|
12062 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
12063 + | .put("disableDoubleEncoding", true)
|
12064 + | .put("signingName", "s3")
|
12065 + | .put("signingRegion", effective_std_region.as_ref()),
|
12066 + | )
|
12067 + | .build(),
|
12068 + | )
|
12069 + | }
|
12070 + | 94 => {
|
12071 + | let effective_std_region = context
|
12072 + | .effective_std_region
|
12073 + | .as_ref()
|
12074 + | .expect("Guaranteed to have a value by earlier checks.");
|
12075 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
12076 + | ::std::result::Result::Ok(
|
12077 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
12078 + | .url({
|
12079 + | let mut out = String::new();
|
12080 + | out.push_str("https://s3.");
|
12081 + | #[allow(clippy::needless_borrow)]
|
12082 + | out.push_str(&partition_result.dns_suffix());
|
12083 + | out
|
12084 + | })
|
12085 + | .auth_scheme(
|
12086 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
12087 + | .put("disableDoubleEncoding", true)
|
12088 + | .put("signingName", "s3")
|
12089 + | .put("signingRegion", effective_std_region.as_ref()),
|
12090 + | )
|
12091 + | .build(),
|
12092 + | )
|
12093 + | }
|
12094 + | 95 => {
|
12095 + | let effective_std_region = context
|
12096 + | .effective_std_region
|
12097 + | .as_ref()
|
12098 + | .expect("Guaranteed to have a value by earlier checks.");
|
12099 + | let partition_result = context.partition_result.as_ref().expect("Guaranteed to have a value by earlier checks.");
|
12100 + | ::std::result::Result::Ok(
|
12101 + | ::aws_smithy_types::endpoint::Endpoint::builder()
|
12102 + | .url({
|
12103 + | let mut out = String::new();
|
12104 + | out.push_str("https://s3.");
|
12105 + | #[allow(clippy::needless_borrow)]
|
12106 + | out.push_str(&effective_std_region.as_ref());
|
12107 + | out.push('.');
|
12108 + | #[allow(clippy::needless_borrow)]
|
12109 + | out.push_str(&partition_result.dns_suffix());
|
12110 + | out
|
12111 + | })
|
12112 + | .auth_scheme(
|
12113 + | ::aws_smithy_types::endpoint::EndpointAuthScheme::with_capacity("sigv4".to_string(), 3)
|
12114 + | .put("disableDoubleEncoding", true)
|
12115 + | .put("signingName", "s3")
|
12116 + | .put("signingRegion", effective_std_region.as_ref()),
|
12117 + | )
|
12118 + | .build(),
|
12119 + | )
|
12120 + | }
|
12121 + | 96 => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12122 + | "A region must be set when sending requests to S3.".to_string(),
|
12123 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
12124 + | _ => ::std::result::Result::Err(Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
12125 + | "No endpoint rule matched",
|
12126 + | )) as ::aws_smithy_runtime_api::box_error::BoxError),
|
12127 + | };
|
12128 + | }
|
12129 + | 1 | -1 => {
|
12130 + | return ::std::result::Result::Err(
|
12131 + | Box::new(::aws_smithy_http::endpoint::ResolveEndpointError::message("No endpoint rule matched"))
|
12132 + | as ::aws_smithy_runtime_api::box_error::BoxError,
|
12133 + | )
|
12134 + | }
|
12135 + | ref_val => {
|
12136 + | let is_complement = ref_val < 0;
|
12137 + | let node = &NODES[(ref_val.unsigned_abs() as usize) - 1];
|
12138 + | let condition_result = match node.condition_index {
|
12139 + | 0 => region.is_some(),
|
12140 + | 1 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12141 + | let effective_std_region = &mut context.effective_std_region;
|
12142 + | let partition_result = &mut context.partition_result;
|
12143 + | let url = &mut context.url;
|
12144 + | let access_point_suffix = &mut context.access_point_suffix;
|
12145 + | let region_prefix = &mut context.region_prefix;
|
12146 + | let hardware_type = &mut context.hardware_type;
|
12147 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12148 + | let s3_e_ds = &mut context.s3_e_ds;
|
12149 + | let s3_e_fips = &mut context.s3_e_fips;
|
12150 + | let s3_e_auth = &mut context.s3_e_auth;
|
12151 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12152 + | let bucket_arn = &mut context.bucket_arn;
|
12153 + | let effective_arn_region = &mut context.effective_arn_region;
|
12154 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12155 + | let arn_type = &mut context.arn_type;
|
12156 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12157 + | let bucket_partition = &mut context.bucket_partition;
|
12158 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12159 + | let outpost_type = &mut context.outpost_type;
|
12160 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12161 + | let partition_resolver = &self.partition_resolver;
|
12162 + | {
|
12163 + | *effective_std_region = Some(
|
12164 + | crate::endpoint_lib::ite::ite!(
|
12165 + | (region) == &mut Some(("aws-global".into())),
|
12166 + | "us-east-1".to_string(),
|
12167 + | region.clone().expect("Reference already confirmed Some")
|
12168 + | )
|
12169 + | .into(),
|
14377 12170 | );
|
14378 - | out
|
14379 - | })],
|
14380 - | )
|
14381 - | .build(),
|
14382 - | )
|
14383 - | }
|
14384 - | Self::Result63 => {
|
14385 - | let partition_result = context
|
14386 - | .partition_result
|
14387 - | .as_ref()
|
14388 - | .map(|s| s.clone())
|
14389 - | .expect("Guaranteed to have a value by earlier checks.");
|
14390 - | let bucket_arn = context
|
14391 - | .bucket_arn
|
14392 - | .as_ref()
|
14393 - | .map(|s| s.clone())
|
14394 - | .expect("Guaranteed to have a value by earlier checks.");
|
14395 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
14396 - | let mut out = String::new();
|
14397 - | out.push_str("Client was configured for partition `");
|
14398 - | #[allow(clippy::needless_borrow)]
|
14399 - | out.push_str(&partition_result.name());
|
14400 - | out.push_str("` but bucket referred to partition `");
|
14401 - | #[allow(clippy::needless_borrow)]
|
14402 - | out.push_str(&bucket_arn.partition());
|
14403 - | out.push('`');
|
14404 - | out
|
14405 - | }))
|
14406 - | }
|
14407 - | Self::Result64 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14408 - | "Invalid Access Point Name".to_string(),
|
14409 - | )),
|
14410 - | Self::Result65 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14411 - | "S3 Outposts does not support Dual-stack".to_string(),
|
14412 - | )),
|
14413 - | Self::Result66 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14414 - | "S3 Outposts does not support FIPS".to_string(),
|
14415 - | )),
|
14416 - | Self::Result67 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14417 - | "S3 Outposts does not support S3 Accelerate".to_string(),
|
14418 - | )),
|
14419 - | Self::Result68 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14420 - | "Invalid Arn: Outpost Access Point ARN contains sub resources".to_string(),
|
14421 - | )),
|
14422 - | Self::Result69 => {
|
14423 - | let url = context
|
14424 - | .url
|
14425 - | .as_ref()
|
14426 - | .map(|s| s.clone())
|
14427 - | .expect("Guaranteed to have a value by earlier checks.");
|
14428 - | let bucket_arn = context
|
14429 - | .bucket_arn
|
14430 - | .as_ref()
|
14431 - | .map(|s| s.clone())
|
14432 - | .expect("Guaranteed to have a value by earlier checks.");
|
14433 - | let effective_arn_region = context
|
14434 - | .effective_arn_region
|
14435 - | .as_ref()
|
14436 - | .map(|s| s.clone())
|
14437 - | .expect("Guaranteed to have a value by earlier checks.");
|
14438 - | let outpost_id_ssa_1 = context
|
14439 - | .outpost_id_ssa_1
|
14440 - | .as_ref()
|
14441 - | .map(|s| s.clone())
|
14442 - | .expect("Guaranteed to have a value by earlier checks.");
|
14443 - | let access_point_name_ssa_2 = context
|
14444 - | .access_point_name_ssa_2
|
14445 - | .as_ref()
|
14446 - | .map(|s| s.clone())
|
14447 - | .expect("Guaranteed to have a value by earlier checks.");
|
14448 - | ::std::result::Result::Ok(
|
14449 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14450 - | .url({
|
14451 - | let mut out = String::new();
|
14452 - | out.push_str("https://");
|
14453 - | #[allow(clippy::needless_borrow)]
|
14454 - | out.push_str(&access_point_name_ssa_2.as_ref());
|
14455 - | out.push('-');
|
14456 - | #[allow(clippy::needless_borrow)]
|
14457 - | out.push_str(&bucket_arn.account_id());
|
14458 - | out.push('.');
|
14459 - | #[allow(clippy::needless_borrow)]
|
14460 - | out.push_str(&outpost_id_ssa_1.as_ref());
|
14461 - | out.push('.');
|
14462 - | #[allow(clippy::needless_borrow)]
|
14463 - | out.push_str(&url.authority());
|
14464 - | out
|
14465 - | })
|
14466 - | .property(
|
14467 - | "authSchemes",
|
14468 - | vec![
|
14469 - | ::aws_smithy_types::Document::from({
|
14470 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14471 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14472 - | out.insert("name".to_string(), "sigv4a".to_string().into());
|
14473 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
14474 - | out.insert(
|
14475 - | "signingRegionSet".to_string(),
|
14476 - | vec![::aws_smithy_types::Document::from("*".to_string())].into(),
|
14477 - | );
|
14478 - | out
|
14479 - | }),
|
14480 - | ::aws_smithy_types::Document::from({
|
14481 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14482 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14483 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14484 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
14485 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
14486 - | out
|
14487 - | }),
|
14488 - | ],
|
14489 - | )
|
14490 - | .build(),
|
14491 - | )
|
14492 - | }
|
14493 - | Self::Result70 => {
|
14494 - | let bucket_arn = context
|
14495 - | .bucket_arn
|
14496 - | .as_ref()
|
14497 - | .map(|s| s.clone())
|
14498 - | .expect("Guaranteed to have a value by earlier checks.");
|
14499 - | let effective_arn_region = context
|
14500 - | .effective_arn_region
|
14501 - | .as_ref()
|
14502 - | .map(|s| s.clone())
|
14503 - | .expect("Guaranteed to have a value by earlier checks.");
|
14504 - | let bucket_partition = context
|
14505 - | .bucket_partition
|
14506 - | .as_ref()
|
14507 - | .map(|s| s.clone())
|
14508 - | .expect("Guaranteed to have a value by earlier checks.");
|
14509 - | let outpost_id_ssa_1 = context
|
14510 - | .outpost_id_ssa_1
|
14511 - | .as_ref()
|
14512 - | .map(|s| s.clone())
|
14513 - | .expect("Guaranteed to have a value by earlier checks.");
|
14514 - | let access_point_name_ssa_2 = context
|
14515 - | .access_point_name_ssa_2
|
14516 - | .as_ref()
|
14517 - | .map(|s| s.clone())
|
14518 - | .expect("Guaranteed to have a value by earlier checks.");
|
14519 - | ::std::result::Result::Ok(
|
14520 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14521 - | .url({
|
14522 - | let mut out = String::new();
|
14523 - | out.push_str("https://");
|
14524 - | #[allow(clippy::needless_borrow)]
|
14525 - | out.push_str(&access_point_name_ssa_2.as_ref());
|
14526 - | out.push('-');
|
14527 - | #[allow(clippy::needless_borrow)]
|
14528 - | out.push_str(&bucket_arn.account_id());
|
14529 - | out.push('.');
|
14530 - | #[allow(clippy::needless_borrow)]
|
14531 - | out.push_str(&outpost_id_ssa_1.as_ref());
|
14532 - | out.push_str(".s3-outposts.");
|
14533 - | #[allow(clippy::needless_borrow)]
|
14534 - | out.push_str(&effective_arn_region.as_ref());
|
14535 - | out.push('.');
|
14536 - | #[allow(clippy::needless_borrow)]
|
14537 - | out.push_str(&bucket_partition.dns_suffix());
|
14538 - | out
|
14539 - | })
|
14540 - | .property(
|
14541 - | "authSchemes",
|
14542 - | vec![
|
14543 - | ::aws_smithy_types::Document::from({
|
14544 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14545 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14546 - | out.insert("name".to_string(), "sigv4a".to_string().into());
|
14547 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
14548 - | out.insert(
|
14549 - | "signingRegionSet".to_string(),
|
14550 - | vec![::aws_smithy_types::Document::from("*".to_string())].into(),
|
14551 - | );
|
14552 - | out
|
14553 - | }),
|
14554 - | ::aws_smithy_types::Document::from({
|
14555 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14556 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14557 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14558 - | out.insert("signingName".to_string(), "s3-outposts".to_string().into());
|
14559 - | out.insert("signingRegion".to_string(), effective_arn_region.to_owned().into());
|
14560 - | out
|
14561 - | }),
|
14562 - | ],
|
14563 - | )
|
14564 - | .build(),
|
14565 - | )
|
14566 - | }
|
14567 - | Self::Result71 => {
|
14568 - | let outpost_type = context
|
14569 - | .outpost_type
|
14570 - | .as_ref()
|
14571 - | .map(|s| s.clone())
|
14572 - | .expect("Guaranteed to have a value by earlier checks.");
|
14573 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
14574 - | let mut out = String::new();
|
14575 - | out.push_str("Expected an outpost type `accesspoint`, found ");
|
14576 - | #[allow(clippy::needless_borrow)]
|
14577 - | out.push_str(&outpost_type.as_ref());
|
14578 - | out
|
14579 - | }))
|
14580 - | }
|
14581 - | Self::Result72 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14582 - | "Invalid ARN: expected an access point name".to_string(),
|
14583 - | )),
|
14584 - | Self::Result73 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14585 - | "Invalid ARN: Expected a 4-component resource".to_string(),
|
14586 - | )),
|
14587 - | Self::Result74 => {
|
14588 - | let outpost_id_ssa_1 = context
|
14589 - | .outpost_id_ssa_1
|
14590 - | .as_ref()
|
14591 - | .map(|s| s.clone())
|
14592 - | .expect("Guaranteed to have a value by earlier checks.");
|
14593 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
14594 - | let mut out = String::new();
|
14595 - | out.push_str("Invalid ARN: The outpost Id may only contain a-z, A-Z, 0-9 and `-`. Found: `");
|
14596 - | #[allow(clippy::needless_borrow)]
|
14597 - | out.push_str(&outpost_id_ssa_1.as_ref());
|
14598 - | out.push('`');
|
14599 - | out
|
14600 - | }))
|
14601 - | }
|
14602 - | Self::Result75 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14603 - | "Invalid ARN: The Outpost Id was not set".to_string(),
|
14604 - | )),
|
14605 - | Self::Result76 => {
|
14606 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
14607 - | let arn_type = context
|
14608 - | .arn_type
|
14609 - | .as_ref()
|
14610 - | .map(|s| s.clone())
|
14611 - | .expect("Guaranteed to have a value by earlier checks.");
|
14612 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
14613 - | let mut out = String::new();
|
14614 - | out.push_str("Invalid ARN: Unrecognized format: ");
|
14615 - | #[allow(clippy::needless_borrow)]
|
14616 - | out.push_str(&bucket.as_ref());
|
14617 - | out.push_str(" (type: ");
|
14618 - | #[allow(clippy::needless_borrow)]
|
14619 - | out.push_str(&arn_type.as_ref());
|
14620 - | out.push(')');
|
14621 - | out
|
14622 - | }))
|
14623 - | }
|
14624 - | Self::Result77 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14625 - | "Invalid ARN: No ARN type specified".to_string(),
|
14626 - | )),
|
14627 - | Self::Result78 => {
|
14628 - | let bucket = params.bucket.as_ref().map(|s| s.clone()).unwrap_or_default();
|
14629 - | ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message({
|
14630 - | let mut out = String::new();
|
14631 - | out.push_str("Invalid ARN: `");
|
14632 - | #[allow(clippy::needless_borrow)]
|
14633 - | out.push_str(&bucket.as_ref());
|
14634 - | out.push_str("` was not a valid ARN");
|
14635 - | out
|
14636 - | }))
|
14637 - | }
|
14638 - | Self::Result79 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14639 - | "Path-style addressing cannot be used with ARN buckets".to_string(),
|
14640 - | )),
|
14641 - | Self::Result80 => {
|
14642 - | let effective_std_region = context
|
14643 - | .effective_std_region
|
14644 - | .as_ref()
|
14645 - | .map(|s| s.clone())
|
14646 - | .expect("Guaranteed to have a value by earlier checks.");
|
14647 - | let partition_result = context
|
14648 - | .partition_result
|
14649 - | .as_ref()
|
14650 - | .map(|s| s.clone())
|
14651 - | .expect("Guaranteed to have a value by earlier checks.");
|
14652 - | let uri_encoded_bucket = context
|
14653 - | .uri_encoded_bucket
|
14654 - | .as_ref()
|
14655 - | .map(|s| s.clone())
|
14656 - | .expect("Guaranteed to have a value by earlier checks.");
|
14657 - | ::std::result::Result::Ok(
|
14658 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14659 - | .url({
|
14660 - | let mut out = String::new();
|
14661 - | out.push_str("https://s3-fips.dualstack.");
|
14662 - | #[allow(clippy::needless_borrow)]
|
14663 - | out.push_str(&effective_std_region.as_ref());
|
14664 - | out.push('.');
|
14665 - | #[allow(clippy::needless_borrow)]
|
14666 - | out.push_str(&partition_result.dns_suffix());
|
14667 - | out.push('/');
|
14668 - | #[allow(clippy::needless_borrow)]
|
14669 - | out.push_str(&uri_encoded_bucket.as_ref());
|
14670 - | out
|
14671 - | })
|
14672 - | .property(
|
14673 - | "authSchemes",
|
14674 - | vec![::aws_smithy_types::Document::from({
|
14675 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14676 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14677 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14678 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14679 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
14680 - | out
|
14681 - | })],
|
14682 - | )
|
14683 - | .build(),
|
14684 - | )
|
14685 - | }
|
14686 - | Self::Result81 => {
|
14687 - | let effective_std_region = context
|
14688 - | .effective_std_region
|
14689 - | .as_ref()
|
14690 - | .map(|s| s.clone())
|
14691 - | .expect("Guaranteed to have a value by earlier checks.");
|
14692 - | let partition_result = context
|
14693 - | .partition_result
|
14694 - | .as_ref()
|
14695 - | .map(|s| s.clone())
|
14696 - | .expect("Guaranteed to have a value by earlier checks.");
|
14697 - | let uri_encoded_bucket = context
|
14698 - | .uri_encoded_bucket
|
14699 - | .as_ref()
|
14700 - | .map(|s| s.clone())
|
14701 - | .expect("Guaranteed to have a value by earlier checks.");
|
14702 - | ::std::result::Result::Ok(
|
14703 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14704 - | .url({
|
14705 - | let mut out = String::new();
|
14706 - | out.push_str("https://s3-fips.");
|
14707 - | #[allow(clippy::needless_borrow)]
|
14708 - | out.push_str(&effective_std_region.as_ref());
|
14709 - | out.push('.');
|
14710 - | #[allow(clippy::needless_borrow)]
|
14711 - | out.push_str(&partition_result.dns_suffix());
|
14712 - | out.push('/');
|
14713 - | #[allow(clippy::needless_borrow)]
|
14714 - | out.push_str(&uri_encoded_bucket.as_ref());
|
14715 - | out
|
14716 - | })
|
14717 - | .property(
|
14718 - | "authSchemes",
|
14719 - | vec![::aws_smithy_types::Document::from({
|
14720 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14721 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14722 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14723 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14724 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
14725 - | out
|
14726 - | })],
|
14727 - | )
|
14728 - | .build(),
|
14729 - | )
|
14730 - | }
|
14731 - | Self::Result82 => {
|
14732 - | let effective_std_region = context
|
14733 - | .effective_std_region
|
14734 - | .as_ref()
|
14735 - | .map(|s| s.clone())
|
14736 - | .expect("Guaranteed to have a value by earlier checks.");
|
14737 - | let partition_result = context
|
14738 - | .partition_result
|
14739 - | .as_ref()
|
14740 - | .map(|s| s.clone())
|
14741 - | .expect("Guaranteed to have a value by earlier checks.");
|
14742 - | let uri_encoded_bucket = context
|
14743 - | .uri_encoded_bucket
|
14744 - | .as_ref()
|
14745 - | .map(|s| s.clone())
|
14746 - | .expect("Guaranteed to have a value by earlier checks.");
|
14747 - | ::std::result::Result::Ok(
|
14748 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14749 - | .url({
|
14750 - | let mut out = String::new();
|
14751 - | out.push_str("https://s3.dualstack.");
|
14752 - | #[allow(clippy::needless_borrow)]
|
14753 - | out.push_str(&effective_std_region.as_ref());
|
14754 - | out.push('.');
|
14755 - | #[allow(clippy::needless_borrow)]
|
14756 - | out.push_str(&partition_result.dns_suffix());
|
14757 - | out.push('/');
|
14758 - | #[allow(clippy::needless_borrow)]
|
14759 - | out.push_str(&uri_encoded_bucket.as_ref());
|
14760 - | out
|
14761 - | })
|
14762 - | .property(
|
14763 - | "authSchemes",
|
14764 - | vec![::aws_smithy_types::Document::from({
|
14765 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14766 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14767 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14768 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14769 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
14770 - | out
|
14771 - | })],
|
14772 - | )
|
14773 - | .build(),
|
14774 - | )
|
14775 - | }
|
14776 - | Self::Result83 => {
|
14777 - | let effective_std_region = context
|
14778 - | .effective_std_region
|
14779 - | .as_ref()
|
14780 - | .map(|s| s.clone())
|
14781 - | .expect("Guaranteed to have a value by earlier checks.");
|
14782 - | let url = context
|
14783 - | .url
|
14784 - | .as_ref()
|
14785 - | .map(|s| s.clone())
|
14786 - | .expect("Guaranteed to have a value by earlier checks.");
|
14787 - | let uri_encoded_bucket = context
|
14788 - | .uri_encoded_bucket
|
14789 - | .as_ref()
|
14790 - | .map(|s| s.clone())
|
14791 - | .expect("Guaranteed to have a value by earlier checks.");
|
14792 - | ::std::result::Result::Ok(
|
14793 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14794 - | .url({
|
14795 - | let mut out = String::new();
|
14796 - | #[allow(clippy::needless_borrow)]
|
14797 - | out.push_str(&url.scheme());
|
14798 - | out.push_str("://");
|
14799 - | #[allow(clippy::needless_borrow)]
|
14800 - | out.push_str(&url.authority());
|
14801 - | #[allow(clippy::needless_borrow)]
|
14802 - | out.push_str(&url.normalized_path());
|
14803 - | #[allow(clippy::needless_borrow)]
|
14804 - | out.push_str(&uri_encoded_bucket.as_ref());
|
14805 - | out
|
14806 - | })
|
14807 - | .property(
|
14808 - | "authSchemes",
|
14809 - | vec![::aws_smithy_types::Document::from({
|
14810 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14811 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14812 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14813 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14814 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
14815 - | out
|
14816 - | })],
|
14817 - | )
|
14818 - | .build(),
|
14819 - | )
|
14820 - | }
|
14821 - | Self::Result84 => {
|
14822 - | let effective_std_region = context
|
14823 - | .effective_std_region
|
14824 - | .as_ref()
|
14825 - | .map(|s| s.clone())
|
14826 - | .expect("Guaranteed to have a value by earlier checks.");
|
14827 - | let partition_result = context
|
14828 - | .partition_result
|
14829 - | .as_ref()
|
14830 - | .map(|s| s.clone())
|
14831 - | .expect("Guaranteed to have a value by earlier checks.");
|
14832 - | let uri_encoded_bucket = context
|
14833 - | .uri_encoded_bucket
|
14834 - | .as_ref()
|
14835 - | .map(|s| s.clone())
|
14836 - | .expect("Guaranteed to have a value by earlier checks.");
|
14837 - | ::std::result::Result::Ok(
|
14838 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14839 - | .url({
|
14840 - | let mut out = String::new();
|
14841 - | out.push_str("https://s3.");
|
14842 - | #[allow(clippy::needless_borrow)]
|
14843 - | out.push_str(&partition_result.dns_suffix());
|
14844 - | out.push('/');
|
14845 - | #[allow(clippy::needless_borrow)]
|
14846 - | out.push_str(&uri_encoded_bucket.as_ref());
|
14847 - | out
|
14848 - | })
|
14849 - | .property(
|
14850 - | "authSchemes",
|
14851 - | vec![::aws_smithy_types::Document::from({
|
14852 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14853 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14854 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14855 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14856 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
14857 - | out
|
14858 - | })],
|
14859 - | )
|
14860 - | .build(),
|
14861 - | )
|
14862 - | }
|
14863 - | Self::Result85 => {
|
14864 - | let effective_std_region = context
|
14865 - | .effective_std_region
|
14866 - | .as_ref()
|
14867 - | .map(|s| s.clone())
|
14868 - | .expect("Guaranteed to have a value by earlier checks.");
|
14869 - | let partition_result = context
|
14870 - | .partition_result
|
14871 - | .as_ref()
|
14872 - | .map(|s| s.clone())
|
14873 - | .expect("Guaranteed to have a value by earlier checks.");
|
14874 - | let uri_encoded_bucket = context
|
14875 - | .uri_encoded_bucket
|
14876 - | .as_ref()
|
14877 - | .map(|s| s.clone())
|
14878 - | .expect("Guaranteed to have a value by earlier checks.");
|
14879 - | ::std::result::Result::Ok(
|
14880 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14881 - | .url({
|
14882 - | let mut out = String::new();
|
14883 - | out.push_str("https://s3.");
|
14884 - | #[allow(clippy::needless_borrow)]
|
14885 - | out.push_str(&effective_std_region.as_ref());
|
14886 - | out.push('.');
|
14887 - | #[allow(clippy::needless_borrow)]
|
14888 - | out.push_str(&partition_result.dns_suffix());
|
14889 - | out.push('/');
|
14890 - | #[allow(clippy::needless_borrow)]
|
14891 - | out.push_str(&uri_encoded_bucket.as_ref());
|
14892 - | out
|
14893 - | })
|
14894 - | .property(
|
14895 - | "authSchemes",
|
14896 - | vec![::aws_smithy_types::Document::from({
|
14897 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14898 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14899 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14900 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
14901 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
14902 - | out
|
14903 - | })],
|
14904 - | )
|
14905 - | .build(),
|
14906 - | )
|
14907 - | }
|
14908 - | Self::Result86 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
14909 - | "Path-style addressing cannot be used with S3 Accelerate".to_string(),
|
14910 - | )),
|
14911 - | Self::Result87 => {
|
14912 - | let effective_std_region = context
|
14913 - | .effective_std_region
|
14914 - | .as_ref()
|
14915 - | .map(|s| s.clone())
|
14916 - | .expect("Guaranteed to have a value by earlier checks.");
|
14917 - | let url = context
|
14918 - | .url
|
14919 - | .as_ref()
|
14920 - | .map(|s| s.clone())
|
14921 - | .expect("Guaranteed to have a value by earlier checks.");
|
14922 - | ::std::result::Result::Ok(
|
14923 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14924 - | .url({
|
14925 - | let mut out = String::new();
|
14926 - | #[allow(clippy::needless_borrow)]
|
14927 - | out.push_str(&url.scheme());
|
14928 - | out.push_str("://");
|
14929 - | #[allow(clippy::needless_borrow)]
|
14930 - | out.push_str(&url.authority());
|
14931 - | #[allow(clippy::needless_borrow)]
|
14932 - | out.push_str(&url.path());
|
14933 - | out
|
14934 - | })
|
14935 - | .property(
|
14936 - | "authSchemes",
|
14937 - | vec![::aws_smithy_types::Document::from({
|
14938 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14939 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14940 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14941 - | out.insert("signingName".to_string(), "s3-object-lambda".to_string().into());
|
14942 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
14943 - | out
|
14944 - | })],
|
14945 - | )
|
14946 - | .build(),
|
14947 - | )
|
14948 - | }
|
14949 - | Self::Result88 => {
|
14950 - | let effective_std_region = context
|
14951 - | .effective_std_region
|
14952 - | .as_ref()
|
14953 - | .map(|s| s.clone())
|
14954 - | .expect("Guaranteed to have a value by earlier checks.");
|
14955 - | let partition_result = context
|
14956 - | .partition_result
|
14957 - | .as_ref()
|
14958 - | .map(|s| s.clone())
|
14959 - | .expect("Guaranteed to have a value by earlier checks.");
|
14960 - | ::std::result::Result::Ok(
|
14961 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14962 - | .url({
|
14963 - | let mut out = String::new();
|
14964 - | out.push_str("https://s3-object-lambda-fips.");
|
14965 - | #[allow(clippy::needless_borrow)]
|
14966 - | out.push_str(&effective_std_region.as_ref());
|
14967 - | out.push('.');
|
14968 - | #[allow(clippy::needless_borrow)]
|
14969 - | out.push_str(&partition_result.dns_suffix());
|
14970 - | out
|
14971 - | })
|
14972 - | .property(
|
14973 - | "authSchemes",
|
14974 - | vec![::aws_smithy_types::Document::from({
|
14975 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
14976 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
14977 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
14978 - | out.insert("signingName".to_string(), "s3-object-lambda".to_string().into());
|
14979 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
14980 - | out
|
14981 - | })],
|
14982 - | )
|
14983 - | .build(),
|
14984 - | )
|
14985 - | }
|
14986 - | Self::Result89 => {
|
14987 - | let effective_std_region = context
|
14988 - | .effective_std_region
|
14989 - | .as_ref()
|
14990 - | .map(|s| s.clone())
|
14991 - | .expect("Guaranteed to have a value by earlier checks.");
|
14992 - | let partition_result = context
|
14993 - | .partition_result
|
14994 - | .as_ref()
|
14995 - | .map(|s| s.clone())
|
14996 - | .expect("Guaranteed to have a value by earlier checks.");
|
14997 - | ::std::result::Result::Ok(
|
14998 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
14999 - | .url({
|
15000 - | let mut out = String::new();
|
15001 - | out.push_str("https://s3-object-lambda.");
|
15002 - | #[allow(clippy::needless_borrow)]
|
15003 - | out.push_str(&effective_std_region.as_ref());
|
15004 - | out.push('.');
|
15005 - | #[allow(clippy::needless_borrow)]
|
15006 - | out.push_str(&partition_result.dns_suffix());
|
15007 - | out
|
15008 - | })
|
15009 - | .property(
|
15010 - | "authSchemes",
|
15011 - | vec![::aws_smithy_types::Document::from({
|
15012 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
15013 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
15014 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
15015 - | out.insert("signingName".to_string(), "s3-object-lambda".to_string().into());
|
15016 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
15017 - | out
|
15018 - | })],
|
15019 - | )
|
15020 - | .build(),
|
15021 - | )
|
15022 - | }
|
15023 - | Self::Result90 => {
|
15024 - | let effective_std_region = context
|
15025 - | .effective_std_region
|
15026 - | .as_ref()
|
15027 - | .map(|s| s.clone())
|
15028 - | .expect("Guaranteed to have a value by earlier checks.");
|
15029 - | let partition_result = context
|
15030 - | .partition_result
|
15031 - | .as_ref()
|
15032 - | .map(|s| s.clone())
|
15033 - | .expect("Guaranteed to have a value by earlier checks.");
|
15034 - | ::std::result::Result::Ok(
|
15035 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
15036 - | .url({
|
15037 - | let mut out = String::new();
|
15038 - | out.push_str("https://s3-fips.dualstack.");
|
15039 - | #[allow(clippy::needless_borrow)]
|
15040 - | out.push_str(&effective_std_region.as_ref());
|
15041 - | out.push('.');
|
15042 - | #[allow(clippy::needless_borrow)]
|
15043 - | out.push_str(&partition_result.dns_suffix());
|
15044 - | out
|
15045 - | })
|
15046 - | .property(
|
15047 - | "authSchemes",
|
15048 - | vec![::aws_smithy_types::Document::from({
|
15049 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
15050 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
15051 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
15052 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
15053 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
15054 - | out
|
15055 - | })],
|
15056 - | )
|
15057 - | .build(),
|
15058 - | )
|
15059 - | }
|
15060 - | Self::Result91 => {
|
15061 - | let effective_std_region = context
|
15062 - | .effective_std_region
|
15063 - | .as_ref()
|
15064 - | .map(|s| s.clone())
|
15065 - | .expect("Guaranteed to have a value by earlier checks.");
|
15066 - | let partition_result = context
|
15067 - | .partition_result
|
15068 - | .as_ref()
|
15069 - | .map(|s| s.clone())
|
15070 - | .expect("Guaranteed to have a value by earlier checks.");
|
15071 - | ::std::result::Result::Ok(
|
15072 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
15073 - | .url({
|
15074 - | let mut out = String::new();
|
15075 - | out.push_str("https://s3-fips.");
|
15076 - | #[allow(clippy::needless_borrow)]
|
15077 - | out.push_str(&effective_std_region.as_ref());
|
15078 - | out.push('.');
|
15079 - | #[allow(clippy::needless_borrow)]
|
15080 - | out.push_str(&partition_result.dns_suffix());
|
15081 - | out
|
15082 - | })
|
15083 - | .property(
|
15084 - | "authSchemes",
|
15085 - | vec![::aws_smithy_types::Document::from({
|
15086 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
15087 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
15088 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
15089 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
15090 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
15091 - | out
|
15092 - | })],
|
15093 - | )
|
15094 - | .build(),
|
15095 - | )
|
15096 - | }
|
15097 - | Self::Result92 => {
|
15098 - | let effective_std_region = context
|
15099 - | .effective_std_region
|
15100 - | .as_ref()
|
15101 - | .map(|s| s.clone())
|
15102 - | .expect("Guaranteed to have a value by earlier checks.");
|
15103 - | let partition_result = context
|
15104 - | .partition_result
|
15105 - | .as_ref()
|
15106 - | .map(|s| s.clone())
|
15107 - | .expect("Guaranteed to have a value by earlier checks.");
|
15108 - | ::std::result::Result::Ok(
|
15109 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
15110 - | .url({
|
15111 - | let mut out = String::new();
|
15112 - | out.push_str("https://s3.dualstack.");
|
15113 - | #[allow(clippy::needless_borrow)]
|
15114 - | out.push_str(&effective_std_region.as_ref());
|
15115 - | out.push('.');
|
15116 - | #[allow(clippy::needless_borrow)]
|
15117 - | out.push_str(&partition_result.dns_suffix());
|
15118 - | out
|
15119 - | })
|
15120 - | .property(
|
15121 - | "authSchemes",
|
15122 - | vec![::aws_smithy_types::Document::from({
|
15123 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
15124 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
15125 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
15126 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
15127 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
15128 - | out
|
15129 - | })],
|
15130 - | )
|
15131 - | .build(),
|
15132 - | )
|
15133 - | }
|
15134 - | Self::Result93 => {
|
15135 - | let effective_std_region = context
|
15136 - | .effective_std_region
|
15137 - | .as_ref()
|
15138 - | .map(|s| s.clone())
|
15139 - | .expect("Guaranteed to have a value by earlier checks.");
|
15140 - | let url = context
|
15141 - | .url
|
15142 - | .as_ref()
|
15143 - | .map(|s| s.clone())
|
15144 - | .expect("Guaranteed to have a value by earlier checks.");
|
15145 - | ::std::result::Result::Ok(
|
15146 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
15147 - | .url({
|
15148 - | let mut out = String::new();
|
15149 - | #[allow(clippy::needless_borrow)]
|
15150 - | out.push_str(&url.scheme());
|
15151 - | out.push_str("://");
|
15152 - | #[allow(clippy::needless_borrow)]
|
15153 - | out.push_str(&url.authority());
|
15154 - | #[allow(clippy::needless_borrow)]
|
15155 - | out.push_str(&url.path());
|
15156 - | out
|
15157 - | })
|
15158 - | .property(
|
15159 - | "authSchemes",
|
15160 - | vec![::aws_smithy_types::Document::from({
|
15161 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
15162 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
15163 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
15164 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
15165 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
15166 - | out
|
15167 - | })],
|
15168 - | )
|
15169 - | .build(),
|
15170 - | )
|
15171 - | }
|
15172 - | Self::Result94 => {
|
15173 - | let effective_std_region = context
|
15174 - | .effective_std_region
|
15175 - | .as_ref()
|
15176 - | .map(|s| s.clone())
|
15177 - | .expect("Guaranteed to have a value by earlier checks.");
|
15178 - | let partition_result = context
|
15179 - | .partition_result
|
15180 - | .as_ref()
|
15181 - | .map(|s| s.clone())
|
15182 - | .expect("Guaranteed to have a value by earlier checks.");
|
15183 - | ::std::result::Result::Ok(
|
15184 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
15185 - | .url({
|
15186 - | let mut out = String::new();
|
15187 - | out.push_str("https://s3.");
|
15188 - | #[allow(clippy::needless_borrow)]
|
15189 - | out.push_str(&partition_result.dns_suffix());
|
15190 - | out
|
15191 - | })
|
15192 - | .property(
|
15193 - | "authSchemes",
|
15194 - | vec![::aws_smithy_types::Document::from({
|
15195 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
15196 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
15197 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
15198 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
15199 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
15200 - | out
|
15201 - | })],
|
15202 - | )
|
15203 - | .build(),
|
15204 - | )
|
15205 - | }
|
15206 - | Self::Result95 => {
|
15207 - | let effective_std_region = context
|
15208 - | .effective_std_region
|
15209 - | .as_ref()
|
15210 - | .map(|s| s.clone())
|
15211 - | .expect("Guaranteed to have a value by earlier checks.");
|
15212 - | let partition_result = context
|
15213 - | .partition_result
|
15214 - | .as_ref()
|
15215 - | .map(|s| s.clone())
|
15216 - | .expect("Guaranteed to have a value by earlier checks.");
|
15217 - | ::std::result::Result::Ok(
|
15218 - | ::aws_smithy_types::endpoint::Endpoint::builder()
|
15219 - | .url({
|
15220 - | let mut out = String::new();
|
15221 - | out.push_str("https://s3.");
|
15222 - | #[allow(clippy::needless_borrow)]
|
15223 - | out.push_str(&effective_std_region.as_ref());
|
15224 - | out.push('.');
|
15225 - | #[allow(clippy::needless_borrow)]
|
15226 - | out.push_str(&partition_result.dns_suffix());
|
15227 - | out
|
15228 - | })
|
15229 - | .property(
|
15230 - | "authSchemes",
|
15231 - | vec![::aws_smithy_types::Document::from({
|
15232 - | let mut out = ::std::collections::HashMap::<String, ::aws_smithy_types::Document>::new();
|
15233 - | out.insert("disableDoubleEncoding".to_string(), true.into());
|
15234 - | out.insert("name".to_string(), "sigv4".to_string().into());
|
15235 - | out.insert("signingName".to_string(), "s3".to_string().into());
|
15236 - | out.insert("signingRegion".to_string(), effective_std_region.to_owned().into());
|
15237 - | out
|
15238 - | })],
|
15239 - | )
|
15240 - | .build(),
|
15241 - | )
|
12171 + | true
|
12172 + | }
|
12173 + | })(&mut _diagnostic_collector),
|
12174 + | 2 => (accelerate) == (&true),
|
12175 + | 3 => (use_fips) == (&true),
|
12176 + | 4 => endpoint.is_some(),
|
12177 + | 5 => (use_dual_stack) == (&true),
|
12178 + | 6 => bucket.is_some(),
|
12179 + | 7 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12180 + | let effective_std_region = &mut context.effective_std_region;
|
12181 + | let partition_result = &mut context.partition_result;
|
12182 + | let url = &mut context.url;
|
12183 + | let access_point_suffix = &mut context.access_point_suffix;
|
12184 + | let region_prefix = &mut context.region_prefix;
|
12185 + | let hardware_type = &mut context.hardware_type;
|
12186 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12187 + | let s3_e_ds = &mut context.s3_e_ds;
|
12188 + | let s3_e_fips = &mut context.s3_e_fips;
|
12189 + | let s3_e_auth = &mut context.s3_e_auth;
|
12190 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12191 + | let bucket_arn = &mut context.bucket_arn;
|
12192 + | let effective_arn_region = &mut context.effective_arn_region;
|
12193 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12194 + | let arn_type = &mut context.arn_type;
|
12195 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12196 + | let bucket_partition = &mut context.bucket_partition;
|
12197 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12198 + | let outpost_type = &mut context.outpost_type;
|
12199 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12200 + | let partition_resolver = &self.partition_resolver;
|
12201 + | (crate::endpoint_lib::coalesce::coalesce!(
|
12202 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12203 + | if let Some(param) = bucket { param } else { return false },
|
12204 + | 0,
|
12205 + | 6,
|
12206 + | true,
|
12207 + | _diagnostic_collector
|
12208 + | ) {
|
12209 + | inner
|
12210 + | } else {
|
12211 + | return false;
|
12212 + | },
|
12213 + | ""
|
12214 + | )) == ("--x-s3")
|
12215 + | })(&mut _diagnostic_collector),
|
12216 + | 8 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12217 + | let effective_std_region = &mut context.effective_std_region;
|
12218 + | let partition_result = &mut context.partition_result;
|
12219 + | let url = &mut context.url;
|
12220 + | let access_point_suffix = &mut context.access_point_suffix;
|
12221 + | let region_prefix = &mut context.region_prefix;
|
12222 + | let hardware_type = &mut context.hardware_type;
|
12223 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12224 + | let s3_e_ds = &mut context.s3_e_ds;
|
12225 + | let s3_e_fips = &mut context.s3_e_fips;
|
12226 + | let s3_e_auth = &mut context.s3_e_auth;
|
12227 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12228 + | let bucket_arn = &mut context.bucket_arn;
|
12229 + | let effective_arn_region = &mut context.effective_arn_region;
|
12230 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12231 + | let arn_type = &mut context.arn_type;
|
12232 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12233 + | let bucket_partition = &mut context.bucket_partition;
|
12234 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12235 + | let outpost_type = &mut context.outpost_type;
|
12236 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12237 + | let partition_resolver = &self.partition_resolver;
|
12238 + | (crate::endpoint_lib::coalesce::coalesce!(
|
12239 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12240 + | if let Some(param) = bucket { param } else { return false },
|
12241 + | 0,
|
12242 + | 7,
|
12243 + | true,
|
12244 + | _diagnostic_collector
|
12245 + | ) {
|
12246 + | inner
|
12247 + | } else {
|
12248 + | return false;
|
12249 + | },
|
12250 + | ""
|
12251 + | )) == ("--xa-s3")
|
12252 + | })(&mut _diagnostic_collector),
|
12253 + | 9 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12254 + | let effective_std_region = &mut context.effective_std_region;
|
12255 + | let partition_result = &mut context.partition_result;
|
12256 + | let url = &mut context.url;
|
12257 + | let access_point_suffix = &mut context.access_point_suffix;
|
12258 + | let region_prefix = &mut context.region_prefix;
|
12259 + | let hardware_type = &mut context.hardware_type;
|
12260 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12261 + | let s3_e_ds = &mut context.s3_e_ds;
|
12262 + | let s3_e_fips = &mut context.s3_e_fips;
|
12263 + | let s3_e_auth = &mut context.s3_e_auth;
|
12264 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12265 + | let bucket_arn = &mut context.bucket_arn;
|
12266 + | let effective_arn_region = &mut context.effective_arn_region;
|
12267 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12268 + | let arn_type = &mut context.arn_type;
|
12269 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12270 + | let bucket_partition = &mut context.bucket_partition;
|
12271 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12272 + | let outpost_type = &mut context.outpost_type;
|
12273 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12274 + | let partition_resolver = &self.partition_resolver;
|
12275 + | {
|
12276 + | *partition_result = partition_resolver
|
12277 + | .resolve_partition(if let Some(param) = region { param } else { return false }, _diagnostic_collector)
|
12278 + | .map(|inner| inner.into());
|
12279 + | partition_result.is_some()
|
12280 + | }
|
12281 + | })(&mut _diagnostic_collector),
|
12282 + | 10 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12283 + | let effective_std_region = &mut context.effective_std_region;
|
12284 + | let partition_result = &mut context.partition_result;
|
12285 + | let url = &mut context.url;
|
12286 + | let access_point_suffix = &mut context.access_point_suffix;
|
12287 + | let region_prefix = &mut context.region_prefix;
|
12288 + | let hardware_type = &mut context.hardware_type;
|
12289 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12290 + | let s3_e_ds = &mut context.s3_e_ds;
|
12291 + | let s3_e_fips = &mut context.s3_e_fips;
|
12292 + | let s3_e_auth = &mut context.s3_e_auth;
|
12293 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12294 + | let bucket_arn = &mut context.bucket_arn;
|
12295 + | let effective_arn_region = &mut context.effective_arn_region;
|
12296 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12297 + | let arn_type = &mut context.arn_type;
|
12298 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12299 + | let bucket_partition = &mut context.bucket_partition;
|
12300 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12301 + | let outpost_type = &mut context.outpost_type;
|
12302 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12303 + | let partition_resolver = &self.partition_resolver;
|
12304 + | {
|
12305 + | *url = crate::endpoint_lib::parse_url::parse_url(
|
12306 + | if let Some(param) = endpoint { param } else { return false },
|
12307 + | _diagnostic_collector,
|
12308 + | )
|
12309 + | .map(|inner| inner.into());
|
12310 + | url.is_some()
|
12311 + | }
|
12312 + | })(&mut _diagnostic_collector),
|
12313 + | 11 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12314 + | let effective_std_region = &mut context.effective_std_region;
|
12315 + | let partition_result = &mut context.partition_result;
|
12316 + | let url = &mut context.url;
|
12317 + | let access_point_suffix = &mut context.access_point_suffix;
|
12318 + | let region_prefix = &mut context.region_prefix;
|
12319 + | let hardware_type = &mut context.hardware_type;
|
12320 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12321 + | let s3_e_ds = &mut context.s3_e_ds;
|
12322 + | let s3_e_fips = &mut context.s3_e_fips;
|
12323 + | let s3_e_auth = &mut context.s3_e_auth;
|
12324 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12325 + | let bucket_arn = &mut context.bucket_arn;
|
12326 + | let effective_arn_region = &mut context.effective_arn_region;
|
12327 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12328 + | let arn_type = &mut context.arn_type;
|
12329 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12330 + | let bucket_partition = &mut context.bucket_partition;
|
12331 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12332 + | let outpost_type = &mut context.outpost_type;
|
12333 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12334 + | let partition_resolver = &self.partition_resolver;
|
12335 + | {
|
12336 + | *access_point_suffix = crate::endpoint_lib::substring::substring(
|
12337 + | if let Some(param) = bucket { param } else { return false },
|
12338 + | 0,
|
12339 + | 7,
|
12340 + | true,
|
12341 + | _diagnostic_collector,
|
12342 + | )
|
12343 + | .map(|inner| inner.into());
|
12344 + | access_point_suffix.is_some()
|
12345 + | }
|
12346 + | })(&mut _diagnostic_collector),
|
12347 + | 12 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12348 + | let effective_std_region = &mut context.effective_std_region;
|
12349 + | let partition_result = &mut context.partition_result;
|
12350 + | let url = &mut context.url;
|
12351 + | let access_point_suffix = &mut context.access_point_suffix;
|
12352 + | let region_prefix = &mut context.region_prefix;
|
12353 + | let hardware_type = &mut context.hardware_type;
|
12354 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12355 + | let s3_e_ds = &mut context.s3_e_ds;
|
12356 + | let s3_e_fips = &mut context.s3_e_fips;
|
12357 + | let s3_e_auth = &mut context.s3_e_auth;
|
12358 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12359 + | let bucket_arn = &mut context.bucket_arn;
|
12360 + | let effective_arn_region = &mut context.effective_arn_region;
|
12361 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12362 + | let arn_type = &mut context.arn_type;
|
12363 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12364 + | let bucket_partition = &mut context.bucket_partition;
|
12365 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12366 + | let outpost_type = &mut context.outpost_type;
|
12367 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12368 + | let partition_resolver = &self.partition_resolver;
|
12369 + | (access_point_suffix) == &mut Some(("--op-s3".into()))
|
12370 + | })(&mut _diagnostic_collector),
|
12371 + | 13 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12372 + | let effective_std_region = &mut context.effective_std_region;
|
12373 + | let partition_result = &mut context.partition_result;
|
12374 + | let url = &mut context.url;
|
12375 + | let access_point_suffix = &mut context.access_point_suffix;
|
12376 + | let region_prefix = &mut context.region_prefix;
|
12377 + | let hardware_type = &mut context.hardware_type;
|
12378 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12379 + | let s3_e_ds = &mut context.s3_e_ds;
|
12380 + | let s3_e_fips = &mut context.s3_e_fips;
|
12381 + | let s3_e_auth = &mut context.s3_e_auth;
|
12382 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12383 + | let bucket_arn = &mut context.bucket_arn;
|
12384 + | let effective_arn_region = &mut context.effective_arn_region;
|
12385 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12386 + | let arn_type = &mut context.arn_type;
|
12387 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12388 + | let bucket_partition = &mut context.bucket_partition;
|
12389 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12390 + | let outpost_type = &mut context.outpost_type;
|
12391 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12392 + | let partition_resolver = &self.partition_resolver;
|
12393 + | {
|
12394 + | *region_prefix = crate::endpoint_lib::substring::substring(
|
12395 + | if let Some(param) = bucket { param } else { return false },
|
12396 + | 8,
|
12397 + | 12,
|
12398 + | true,
|
12399 + | _diagnostic_collector,
|
12400 + | )
|
12401 + | .map(|inner| inner.into());
|
12402 + | region_prefix.is_some()
|
12403 + | }
|
12404 + | })(&mut _diagnostic_collector),
|
12405 + | 14 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12406 + | let effective_std_region = &mut context.effective_std_region;
|
12407 + | let partition_result = &mut context.partition_result;
|
12408 + | let url = &mut context.url;
|
12409 + | let access_point_suffix = &mut context.access_point_suffix;
|
12410 + | let region_prefix = &mut context.region_prefix;
|
12411 + | let hardware_type = &mut context.hardware_type;
|
12412 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12413 + | let s3_e_ds = &mut context.s3_e_ds;
|
12414 + | let s3_e_fips = &mut context.s3_e_fips;
|
12415 + | let s3_e_auth = &mut context.s3_e_auth;
|
12416 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12417 + | let bucket_arn = &mut context.bucket_arn;
|
12418 + | let effective_arn_region = &mut context.effective_arn_region;
|
12419 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12420 + | let arn_type = &mut context.arn_type;
|
12421 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12422 + | let bucket_partition = &mut context.bucket_partition;
|
12423 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12424 + | let outpost_type = &mut context.outpost_type;
|
12425 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12426 + | let partition_resolver = &self.partition_resolver;
|
12427 + | {
|
12428 + | *hardware_type = crate::endpoint_lib::substring::substring(
|
12429 + | if let Some(param) = bucket { param } else { return false },
|
12430 + | 49,
|
12431 + | 50,
|
12432 + | true,
|
12433 + | _diagnostic_collector,
|
12434 + | )
|
12435 + | .map(|inner| inner.into());
|
12436 + | hardware_type.is_some()
|
12437 + | }
|
12438 + | })(&mut _diagnostic_collector),
|
12439 + | 15 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12440 + | let effective_std_region = &mut context.effective_std_region;
|
12441 + | let partition_result = &mut context.partition_result;
|
12442 + | let url = &mut context.url;
|
12443 + | let access_point_suffix = &mut context.access_point_suffix;
|
12444 + | let region_prefix = &mut context.region_prefix;
|
12445 + | let hardware_type = &mut context.hardware_type;
|
12446 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12447 + | let s3_e_ds = &mut context.s3_e_ds;
|
12448 + | let s3_e_fips = &mut context.s3_e_fips;
|
12449 + | let s3_e_auth = &mut context.s3_e_auth;
|
12450 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12451 + | let bucket_arn = &mut context.bucket_arn;
|
12452 + | let effective_arn_region = &mut context.effective_arn_region;
|
12453 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12454 + | let arn_type = &mut context.arn_type;
|
12455 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12456 + | let bucket_partition = &mut context.bucket_partition;
|
12457 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12458 + | let outpost_type = &mut context.outpost_type;
|
12459 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12460 + | let partition_resolver = &self.partition_resolver;
|
12461 + | {
|
12462 + | *outpost_id_ssa_2 = crate::endpoint_lib::substring::substring(
|
12463 + | if let Some(param) = bucket { param } else { return false },
|
12464 + | 32,
|
12465 + | 49,
|
12466 + | true,
|
12467 + | _diagnostic_collector,
|
12468 + | )
|
12469 + | .map(|inner| inner.into());
|
12470 + | outpost_id_ssa_2.is_some()
|
12471 + | }
|
12472 + | })(&mut _diagnostic_collector),
|
12473 + | 16 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12474 + | let effective_std_region = &mut context.effective_std_region;
|
12475 + | let partition_result = &mut context.partition_result;
|
12476 + | let url = &mut context.url;
|
12477 + | let access_point_suffix = &mut context.access_point_suffix;
|
12478 + | let region_prefix = &mut context.region_prefix;
|
12479 + | let hardware_type = &mut context.hardware_type;
|
12480 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12481 + | let s3_e_ds = &mut context.s3_e_ds;
|
12482 + | let s3_e_fips = &mut context.s3_e_fips;
|
12483 + | let s3_e_auth = &mut context.s3_e_auth;
|
12484 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12485 + | let bucket_arn = &mut context.bucket_arn;
|
12486 + | let effective_arn_region = &mut context.effective_arn_region;
|
12487 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12488 + | let arn_type = &mut context.arn_type;
|
12489 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12490 + | let bucket_partition = &mut context.bucket_partition;
|
12491 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12492 + | let outpost_type = &mut context.outpost_type;
|
12493 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12494 + | let partition_resolver = &self.partition_resolver;
|
12495 + | (if let Some(inner) = partition_result {
|
12496 + | inner.name()
|
12497 + | } else {
|
12498 + | return false;
|
12499 + | }) == ("aws-cn")
|
12500 + | })(&mut _diagnostic_collector),
|
12501 + | 17 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12502 + | let effective_std_region = &mut context.effective_std_region;
|
12503 + | let partition_result = &mut context.partition_result;
|
12504 + | let url = &mut context.url;
|
12505 + | let access_point_suffix = &mut context.access_point_suffix;
|
12506 + | let region_prefix = &mut context.region_prefix;
|
12507 + | let hardware_type = &mut context.hardware_type;
|
12508 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12509 + | let s3_e_ds = &mut context.s3_e_ds;
|
12510 + | let s3_e_fips = &mut context.s3_e_fips;
|
12511 + | let s3_e_auth = &mut context.s3_e_auth;
|
12512 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12513 + | let bucket_arn = &mut context.bucket_arn;
|
12514 + | let effective_arn_region = &mut context.effective_arn_region;
|
12515 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12516 + | let arn_type = &mut context.arn_type;
|
12517 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12518 + | let bucket_partition = &mut context.bucket_partition;
|
12519 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12520 + | let outpost_type = &mut context.outpost_type;
|
12521 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12522 + | let partition_resolver = &self.partition_resolver;
|
12523 + | {
|
12524 + | *s3_e_ds = Some(crate::endpoint_lib::ite::ite!(use_dual_stack, ".dualstack".to_string(), "".to_string()).into());
|
12525 + | true
|
12526 + | }
|
12527 + | })(&mut _diagnostic_collector),
|
12528 + | 18 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12529 + | let effective_std_region = &mut context.effective_std_region;
|
12530 + | let partition_result = &mut context.partition_result;
|
12531 + | let url = &mut context.url;
|
12532 + | let access_point_suffix = &mut context.access_point_suffix;
|
12533 + | let region_prefix = &mut context.region_prefix;
|
12534 + | let hardware_type = &mut context.hardware_type;
|
12535 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12536 + | let s3_e_ds = &mut context.s3_e_ds;
|
12537 + | let s3_e_fips = &mut context.s3_e_fips;
|
12538 + | let s3_e_auth = &mut context.s3_e_auth;
|
12539 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12540 + | let bucket_arn = &mut context.bucket_arn;
|
12541 + | let effective_arn_region = &mut context.effective_arn_region;
|
12542 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12543 + | let arn_type = &mut context.arn_type;
|
12544 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12545 + | let bucket_partition = &mut context.bucket_partition;
|
12546 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12547 + | let outpost_type = &mut context.outpost_type;
|
12548 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12549 + | let partition_resolver = &self.partition_resolver;
|
12550 + | {
|
12551 + | *s3_e_fips = Some(crate::endpoint_lib::ite::ite!(use_fips, "-fips".to_string(), "".to_string()).into());
|
12552 + | true
|
12553 + | }
|
12554 + | })(&mut _diagnostic_collector),
|
12555 + | 19 => (force_path_style) == (&true),
|
12556 + | 20 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12557 + | let effective_std_region = &mut context.effective_std_region;
|
12558 + | let partition_result = &mut context.partition_result;
|
12559 + | let url = &mut context.url;
|
12560 + | let access_point_suffix = &mut context.access_point_suffix;
|
12561 + | let region_prefix = &mut context.region_prefix;
|
12562 + | let hardware_type = &mut context.hardware_type;
|
12563 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12564 + | let s3_e_ds = &mut context.s3_e_ds;
|
12565 + | let s3_e_fips = &mut context.s3_e_fips;
|
12566 + | let s3_e_auth = &mut context.s3_e_auth;
|
12567 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12568 + | let bucket_arn = &mut context.bucket_arn;
|
12569 + | let effective_arn_region = &mut context.effective_arn_region;
|
12570 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12571 + | let arn_type = &mut context.arn_type;
|
12572 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12573 + | let bucket_partition = &mut context.bucket_partition;
|
12574 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12575 + | let outpost_type = &mut context.outpost_type;
|
12576 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12577 + | let partition_resolver = &self.partition_resolver;
|
12578 + | {
|
12579 + | *s3_e_auth = Some(
|
12580 + | crate::endpoint_lib::ite::ite!(
|
12581 + | crate::endpoint_lib::coalesce::coalesce!(*disable_s3_express_session_auth, false),
|
12582 + | "sigv4".to_string(),
|
12583 + | "sigv4-s3express".to_string()
|
12584 + | )
|
12585 + | .into(),
|
12586 + | );
|
12587 + | true
|
12588 + | }
|
12589 + | })(&mut _diagnostic_collector),
|
12590 + | 21 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12591 + | let effective_std_region = &mut context.effective_std_region;
|
12592 + | let partition_result = &mut context.partition_result;
|
12593 + | let url = &mut context.url;
|
12594 + | let access_point_suffix = &mut context.access_point_suffix;
|
12595 + | let region_prefix = &mut context.region_prefix;
|
12596 + | let hardware_type = &mut context.hardware_type;
|
12597 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12598 + | let s3_e_ds = &mut context.s3_e_ds;
|
12599 + | let s3_e_fips = &mut context.s3_e_fips;
|
12600 + | let s3_e_auth = &mut context.s3_e_auth;
|
12601 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12602 + | let bucket_arn = &mut context.bucket_arn;
|
12603 + | let effective_arn_region = &mut context.effective_arn_region;
|
12604 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12605 + | let arn_type = &mut context.arn_type;
|
12606 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12607 + | let bucket_partition = &mut context.bucket_partition;
|
12608 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12609 + | let outpost_type = &mut context.outpost_type;
|
12610 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12611 + | let partition_resolver = &self.partition_resolver;
|
12612 + | crate::endpoint_lib::s3::is_virtual_hostable_s3_bucket(
|
12613 + | if let Some(param) = bucket { param } else { return false },
|
12614 + | false,
|
12615 + | _diagnostic_collector,
|
12616 + | )
|
12617 + | })(&mut _diagnostic_collector),
|
12618 + | 22 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12619 + | let effective_std_region = &mut context.effective_std_region;
|
12620 + | let partition_result = &mut context.partition_result;
|
12621 + | let url = &mut context.url;
|
12622 + | let access_point_suffix = &mut context.access_point_suffix;
|
12623 + | let region_prefix = &mut context.region_prefix;
|
12624 + | let hardware_type = &mut context.hardware_type;
|
12625 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12626 + | let s3_e_ds = &mut context.s3_e_ds;
|
12627 + | let s3_e_fips = &mut context.s3_e_fips;
|
12628 + | let s3_e_auth = &mut context.s3_e_auth;
|
12629 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12630 + | let bucket_arn = &mut context.bucket_arn;
|
12631 + | let effective_arn_region = &mut context.effective_arn_region;
|
12632 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12633 + | let arn_type = &mut context.arn_type;
|
12634 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12635 + | let bucket_partition = &mut context.bucket_partition;
|
12636 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12637 + | let outpost_type = &mut context.outpost_type;
|
12638 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12639 + | let partition_resolver = &self.partition_resolver;
|
12640 + | {
|
12641 + | *s3express_availability_zone_id = crate::endpoint_lib::split::split(
|
12642 + | if let Some(param) = bucket { param } else { return false },
|
12643 + | "--",
|
12644 + | 0,
|
12645 + | _diagnostic_collector,
|
12646 + | )
|
12647 + | .get(1)
|
12648 + | .cloned()
|
12649 + | .map(|inner| inner.into());
|
12650 + | s3express_availability_zone_id.is_some()
|
12651 + | }
|
12652 + | })(&mut _diagnostic_collector),
|
12653 + | 23 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12654 + | let effective_std_region = &mut context.effective_std_region;
|
12655 + | let partition_result = &mut context.partition_result;
|
12656 + | let url = &mut context.url;
|
12657 + | let access_point_suffix = &mut context.access_point_suffix;
|
12658 + | let region_prefix = &mut context.region_prefix;
|
12659 + | let hardware_type = &mut context.hardware_type;
|
12660 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12661 + | let s3_e_ds = &mut context.s3_e_ds;
|
12662 + | let s3_e_fips = &mut context.s3_e_fips;
|
12663 + | let s3_e_auth = &mut context.s3_e_auth;
|
12664 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12665 + | let bucket_arn = &mut context.bucket_arn;
|
12666 + | let effective_arn_region = &mut context.effective_arn_region;
|
12667 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12668 + | let arn_type = &mut context.arn_type;
|
12669 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12670 + | let bucket_partition = &mut context.bucket_partition;
|
12671 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12672 + | let outpost_type = &mut context.outpost_type;
|
12673 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12674 + | let partition_resolver = &self.partition_resolver;
|
12675 + | crate::endpoint_lib::host::is_valid_host_label(
|
12676 + | if let Some(param) = outpost_id_ssa_2 { param } else { return false },
|
12677 + | false,
|
12678 + | _diagnostic_collector,
|
12679 + | )
|
12680 + | })(&mut _diagnostic_collector),
|
12681 + | 24 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12682 + | let effective_std_region = &mut context.effective_std_region;
|
12683 + | let partition_result = &mut context.partition_result;
|
12684 + | let url = &mut context.url;
|
12685 + | let access_point_suffix = &mut context.access_point_suffix;
|
12686 + | let region_prefix = &mut context.region_prefix;
|
12687 + | let hardware_type = &mut context.hardware_type;
|
12688 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12689 + | let s3_e_ds = &mut context.s3_e_ds;
|
12690 + | let s3_e_fips = &mut context.s3_e_fips;
|
12691 + | let s3_e_auth = &mut context.s3_e_auth;
|
12692 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12693 + | let bucket_arn = &mut context.bucket_arn;
|
12694 + | let effective_arn_region = &mut context.effective_arn_region;
|
12695 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12696 + | let arn_type = &mut context.arn_type;
|
12697 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12698 + | let bucket_partition = &mut context.bucket_partition;
|
12699 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12700 + | let outpost_type = &mut context.outpost_type;
|
12701 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12702 + | let partition_resolver = &self.partition_resolver;
|
12703 + | (crate::endpoint_lib::coalesce::coalesce!(*use_s3_express_control_endpoint, false)) == (true)
|
12704 + | })(&mut _diagnostic_collector),
|
12705 + | 25 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12706 + | let effective_std_region = &mut context.effective_std_region;
|
12707 + | let partition_result = &mut context.partition_result;
|
12708 + | let url = &mut context.url;
|
12709 + | let access_point_suffix = &mut context.access_point_suffix;
|
12710 + | let region_prefix = &mut context.region_prefix;
|
12711 + | let hardware_type = &mut context.hardware_type;
|
12712 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12713 + | let s3_e_ds = &mut context.s3_e_ds;
|
12714 + | let s3_e_fips = &mut context.s3_e_fips;
|
12715 + | let s3_e_auth = &mut context.s3_e_auth;
|
12716 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12717 + | let bucket_arn = &mut context.bucket_arn;
|
12718 + | let effective_arn_region = &mut context.effective_arn_region;
|
12719 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12720 + | let arn_type = &mut context.arn_type;
|
12721 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12722 + | let bucket_partition = &mut context.bucket_partition;
|
12723 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12724 + | let outpost_type = &mut context.outpost_type;
|
12725 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12726 + | let partition_resolver = &self.partition_resolver;
|
12727 + | (region_prefix) == &mut Some(("beta".into()))
|
12728 + | })(&mut _diagnostic_collector),
|
12729 + | 26 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12730 + | let effective_std_region = &mut context.effective_std_region;
|
12731 + | let partition_result = &mut context.partition_result;
|
12732 + | let url = &mut context.url;
|
12733 + | let access_point_suffix = &mut context.access_point_suffix;
|
12734 + | let region_prefix = &mut context.region_prefix;
|
12735 + | let hardware_type = &mut context.hardware_type;
|
12736 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12737 + | let s3_e_ds = &mut context.s3_e_ds;
|
12738 + | let s3_e_fips = &mut context.s3_e_fips;
|
12739 + | let s3_e_auth = &mut context.s3_e_auth;
|
12740 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12741 + | let bucket_arn = &mut context.bucket_arn;
|
12742 + | let effective_arn_region = &mut context.effective_arn_region;
|
12743 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12744 + | let arn_type = &mut context.arn_type;
|
12745 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12746 + | let bucket_partition = &mut context.bucket_partition;
|
12747 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12748 + | let outpost_type = &mut context.outpost_type;
|
12749 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12750 + | let partition_resolver = &self.partition_resolver;
|
12751 + | crate::endpoint_lib::s3::is_virtual_hostable_s3_bucket(
|
12752 + | if let Some(param) = bucket { param } else { return false },
|
12753 + | true,
|
12754 + | _diagnostic_collector,
|
12755 + | )
|
12756 + | })(&mut _diagnostic_collector),
|
12757 + | 27 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12758 + | let effective_std_region = &mut context.effective_std_region;
|
12759 + | let partition_result = &mut context.partition_result;
|
12760 + | let url = &mut context.url;
|
12761 + | let access_point_suffix = &mut context.access_point_suffix;
|
12762 + | let region_prefix = &mut context.region_prefix;
|
12763 + | let hardware_type = &mut context.hardware_type;
|
12764 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12765 + | let s3_e_ds = &mut context.s3_e_ds;
|
12766 + | let s3_e_fips = &mut context.s3_e_fips;
|
12767 + | let s3_e_auth = &mut context.s3_e_auth;
|
12768 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12769 + | let bucket_arn = &mut context.bucket_arn;
|
12770 + | let effective_arn_region = &mut context.effective_arn_region;
|
12771 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12772 + | let arn_type = &mut context.arn_type;
|
12773 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12774 + | let bucket_partition = &mut context.bucket_partition;
|
12775 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12776 + | let outpost_type = &mut context.outpost_type;
|
12777 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12778 + | let partition_resolver = &self.partition_resolver;
|
12779 + | (crate::endpoint_lib::coalesce::coalesce!(
|
12780 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12781 + | if let Some(param) = bucket { param } else { return false },
|
12782 + | 16,
|
12783 + | 18,
|
12784 + | true,
|
12785 + | _diagnostic_collector
|
12786 + | ) {
|
12787 + | inner
|
12788 + | } else {
|
12789 + | return false;
|
12790 + | },
|
12791 + | ""
|
12792 + | )) == ("--")
|
12793 + | })(&mut _diagnostic_collector),
|
12794 + | 28 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12795 + | let effective_std_region = &mut context.effective_std_region;
|
12796 + | let partition_result = &mut context.partition_result;
|
12797 + | let url = &mut context.url;
|
12798 + | let access_point_suffix = &mut context.access_point_suffix;
|
12799 + | let region_prefix = &mut context.region_prefix;
|
12800 + | let hardware_type = &mut context.hardware_type;
|
12801 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12802 + | let s3_e_ds = &mut context.s3_e_ds;
|
12803 + | let s3_e_fips = &mut context.s3_e_fips;
|
12804 + | let s3_e_auth = &mut context.s3_e_auth;
|
12805 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12806 + | let bucket_arn = &mut context.bucket_arn;
|
12807 + | let effective_arn_region = &mut context.effective_arn_region;
|
12808 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12809 + | let arn_type = &mut context.arn_type;
|
12810 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12811 + | let bucket_partition = &mut context.bucket_partition;
|
12812 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12813 + | let outpost_type = &mut context.outpost_type;
|
12814 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12815 + | let partition_resolver = &self.partition_resolver;
|
12816 + | (crate::endpoint_lib::coalesce::coalesce!(
|
12817 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12818 + | if let Some(param) = bucket { param } else { return false },
|
12819 + | 21,
|
12820 + | 23,
|
12821 + | true,
|
12822 + | _diagnostic_collector
|
12823 + | ) {
|
12824 + | inner
|
12825 + | } else {
|
12826 + | return false;
|
12827 + | },
|
12828 + | ""
|
12829 + | )) == ("--")
|
12830 + | })(&mut _diagnostic_collector),
|
12831 + | 29 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12832 + | let effective_std_region = &mut context.effective_std_region;
|
12833 + | let partition_result = &mut context.partition_result;
|
12834 + | let url = &mut context.url;
|
12835 + | let access_point_suffix = &mut context.access_point_suffix;
|
12836 + | let region_prefix = &mut context.region_prefix;
|
12837 + | let hardware_type = &mut context.hardware_type;
|
12838 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12839 + | let s3_e_ds = &mut context.s3_e_ds;
|
12840 + | let s3_e_fips = &mut context.s3_e_fips;
|
12841 + | let s3_e_auth = &mut context.s3_e_auth;
|
12842 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12843 + | let bucket_arn = &mut context.bucket_arn;
|
12844 + | let effective_arn_region = &mut context.effective_arn_region;
|
12845 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12846 + | let arn_type = &mut context.arn_type;
|
12847 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12848 + | let bucket_partition = &mut context.bucket_partition;
|
12849 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12850 + | let outpost_type = &mut context.outpost_type;
|
12851 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12852 + | let partition_resolver = &self.partition_resolver;
|
12853 + | (if let Some(inner) = url { inner.scheme() } else { return false }) == ("http")
|
12854 + | })(&mut _diagnostic_collector),
|
12855 + | 30 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12856 + | let effective_std_region = &mut context.effective_std_region;
|
12857 + | let partition_result = &mut context.partition_result;
|
12858 + | let url = &mut context.url;
|
12859 + | let access_point_suffix = &mut context.access_point_suffix;
|
12860 + | let region_prefix = &mut context.region_prefix;
|
12861 + | let hardware_type = &mut context.hardware_type;
|
12862 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12863 + | let s3_e_ds = &mut context.s3_e_ds;
|
12864 + | let s3_e_fips = &mut context.s3_e_fips;
|
12865 + | let s3_e_auth = &mut context.s3_e_auth;
|
12866 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12867 + | let bucket_arn = &mut context.bucket_arn;
|
12868 + | let effective_arn_region = &mut context.effective_arn_region;
|
12869 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12870 + | let arn_type = &mut context.arn_type;
|
12871 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12872 + | let bucket_partition = &mut context.bucket_partition;
|
12873 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12874 + | let outpost_type = &mut context.outpost_type;
|
12875 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12876 + | let partition_resolver = &self.partition_resolver;
|
12877 + | crate::endpoint_lib::host::is_valid_host_label(
|
12878 + | if let Some(param) = region { param } else { return false },
|
12879 + | false,
|
12880 + | _diagnostic_collector,
|
12881 + | )
|
12882 + | })(&mut _diagnostic_collector),
|
12883 + | 31 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12884 + | let effective_std_region = &mut context.effective_std_region;
|
12885 + | let partition_result = &mut context.partition_result;
|
12886 + | let url = &mut context.url;
|
12887 + | let access_point_suffix = &mut context.access_point_suffix;
|
12888 + | let region_prefix = &mut context.region_prefix;
|
12889 + | let hardware_type = &mut context.hardware_type;
|
12890 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12891 + | let s3_e_ds = &mut context.s3_e_ds;
|
12892 + | let s3_e_fips = &mut context.s3_e_fips;
|
12893 + | let s3_e_auth = &mut context.s3_e_auth;
|
12894 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12895 + | let bucket_arn = &mut context.bucket_arn;
|
12896 + | let effective_arn_region = &mut context.effective_arn_region;
|
12897 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12898 + | let arn_type = &mut context.arn_type;
|
12899 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12900 + | let bucket_partition = &mut context.bucket_partition;
|
12901 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12902 + | let outpost_type = &mut context.outpost_type;
|
12903 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12904 + | let partition_resolver = &self.partition_resolver;
|
12905 + | {
|
12906 + | *bucket_arn = crate::endpoint_lib::arn::parse_arn(
|
12907 + | if let Some(param) = bucket { param } else { return false },
|
12908 + | _diagnostic_collector,
|
12909 + | )
|
12910 + | .map(|inner| inner.into());
|
12911 + | bucket_arn.is_some()
|
12912 + | }
|
12913 + | })(&mut _diagnostic_collector),
|
12914 + | 32 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12915 + | let effective_std_region = &mut context.effective_std_region;
|
12916 + | let partition_result = &mut context.partition_result;
|
12917 + | let url = &mut context.url;
|
12918 + | let access_point_suffix = &mut context.access_point_suffix;
|
12919 + | let region_prefix = &mut context.region_prefix;
|
12920 + | let hardware_type = &mut context.hardware_type;
|
12921 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12922 + | let s3_e_ds = &mut context.s3_e_ds;
|
12923 + | let s3_e_fips = &mut context.s3_e_fips;
|
12924 + | let s3_e_auth = &mut context.s3_e_auth;
|
12925 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12926 + | let bucket_arn = &mut context.bucket_arn;
|
12927 + | let effective_arn_region = &mut context.effective_arn_region;
|
12928 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12929 + | let arn_type = &mut context.arn_type;
|
12930 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12931 + | let bucket_partition = &mut context.bucket_partition;
|
12932 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12933 + | let outpost_type = &mut context.outpost_type;
|
12934 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12935 + | let partition_resolver = &self.partition_resolver;
|
12936 + | (crate::endpoint_lib::coalesce::coalesce!(
|
12937 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
12938 + | if let Some(param) = bucket { param } else { return false },
|
12939 + | 27,
|
12940 + | 29,
|
12941 + | true,
|
12942 + | _diagnostic_collector
|
12943 + | ) {
|
12944 + | inner
|
12945 + | } else {
|
12946 + | return false;
|
12947 + | },
|
12948 + | ""
|
12949 + | )) == ("--")
|
12950 + | })(&mut _diagnostic_collector),
|
12951 + | 33 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12952 + | let effective_std_region = &mut context.effective_std_region;
|
12953 + | let partition_result = &mut context.partition_result;
|
12954 + | let url = &mut context.url;
|
12955 + | let access_point_suffix = &mut context.access_point_suffix;
|
12956 + | let region_prefix = &mut context.region_prefix;
|
12957 + | let hardware_type = &mut context.hardware_type;
|
12958 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12959 + | let s3_e_ds = &mut context.s3_e_ds;
|
12960 + | let s3_e_fips = &mut context.s3_e_fips;
|
12961 + | let s3_e_auth = &mut context.s3_e_auth;
|
12962 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12963 + | let bucket_arn = &mut context.bucket_arn;
|
12964 + | let effective_arn_region = &mut context.effective_arn_region;
|
12965 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
12966 + | let arn_type = &mut context.arn_type;
|
12967 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
12968 + | let bucket_partition = &mut context.bucket_partition;
|
12969 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
12970 + | let outpost_type = &mut context.outpost_type;
|
12971 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
12972 + | let partition_resolver = &self.partition_resolver;
|
12973 + | {
|
12974 + | *effective_arn_region = Some(
|
12975 + | crate::endpoint_lib::ite::ite!(
|
12976 + | crate::endpoint_lib::coalesce::coalesce!(*use_arn_region, true),
|
12977 + | if let Some(inner) = bucket_arn { inner.region() } else { return false }.to_string(),
|
12978 + | region.clone().expect("Reference already confirmed Some")
|
12979 + | )
|
12980 + | .into(),
|
12981 + | );
|
12982 + | true
|
12983 + | }
|
12984 + | })(&mut _diagnostic_collector),
|
12985 + | 34 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
12986 + | let effective_std_region = &mut context.effective_std_region;
|
12987 + | let partition_result = &mut context.partition_result;
|
12988 + | let url = &mut context.url;
|
12989 + | let access_point_suffix = &mut context.access_point_suffix;
|
12990 + | let region_prefix = &mut context.region_prefix;
|
12991 + | let hardware_type = &mut context.hardware_type;
|
12992 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
12993 + | let s3_e_ds = &mut context.s3_e_ds;
|
12994 + | let s3_e_fips = &mut context.s3_e_fips;
|
12995 + | let s3_e_auth = &mut context.s3_e_auth;
|
12996 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
12997 + | let bucket_arn = &mut context.bucket_arn;
|
12998 + | let effective_arn_region = &mut context.effective_arn_region;
|
12999 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13000 + | let arn_type = &mut context.arn_type;
|
13001 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13002 + | let bucket_partition = &mut context.bucket_partition;
|
13003 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13004 + | let outpost_type = &mut context.outpost_type;
|
13005 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13006 + | let partition_resolver = &self.partition_resolver;
|
13007 + | (if let Some(inner) = url { inner.is_ip() } else { return false }) == (true)
|
13008 + | })(&mut _diagnostic_collector),
|
13009 + | 35 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13010 + | let effective_std_region = &mut context.effective_std_region;
|
13011 + | let partition_result = &mut context.partition_result;
|
13012 + | let url = &mut context.url;
|
13013 + | let access_point_suffix = &mut context.access_point_suffix;
|
13014 + | let region_prefix = &mut context.region_prefix;
|
13015 + | let hardware_type = &mut context.hardware_type;
|
13016 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13017 + | let s3_e_ds = &mut context.s3_e_ds;
|
13018 + | let s3_e_fips = &mut context.s3_e_fips;
|
13019 + | let s3_e_auth = &mut context.s3_e_auth;
|
13020 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13021 + | let bucket_arn = &mut context.bucket_arn;
|
13022 + | let effective_arn_region = &mut context.effective_arn_region;
|
13023 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13024 + | let arn_type = &mut context.arn_type;
|
13025 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13026 + | let bucket_partition = &mut context.bucket_partition;
|
13027 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13028 + | let outpost_type = &mut context.outpost_type;
|
13029 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13030 + | let partition_resolver = &self.partition_resolver;
|
13031 + | (crate::endpoint_lib::coalesce::coalesce!(
|
13032 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
13033 + | if let Some(param) = bucket { param } else { return false },
|
13034 + | 0,
|
13035 + | 4,
|
13036 + | false,
|
13037 + | _diagnostic_collector
|
13038 + | ) {
|
13039 + | inner
|
13040 + | } else {
|
13041 + | return false;
|
13042 + | },
|
13043 + | ""
|
13044 + | )) == ("arn:")
|
13045 + | })(&mut _diagnostic_collector),
|
13046 + | 36 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13047 + | let effective_std_region = &mut context.effective_std_region;
|
13048 + | let partition_result = &mut context.partition_result;
|
13049 + | let url = &mut context.url;
|
13050 + | let access_point_suffix = &mut context.access_point_suffix;
|
13051 + | let region_prefix = &mut context.region_prefix;
|
13052 + | let hardware_type = &mut context.hardware_type;
|
13053 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13054 + | let s3_e_ds = &mut context.s3_e_ds;
|
13055 + | let s3_e_fips = &mut context.s3_e_fips;
|
13056 + | let s3_e_auth = &mut context.s3_e_auth;
|
13057 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13058 + | let bucket_arn = &mut context.bucket_arn;
|
13059 + | let effective_arn_region = &mut context.effective_arn_region;
|
13060 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13061 + | let arn_type = &mut context.arn_type;
|
13062 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13063 + | let bucket_partition = &mut context.bucket_partition;
|
13064 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13065 + | let outpost_type = &mut context.outpost_type;
|
13066 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13067 + | let partition_resolver = &self.partition_resolver;
|
13068 + | {
|
13069 + | *uri_encoded_bucket = Some(
|
13070 + | crate::endpoint_lib::uri_encode::uri_encode(
|
13071 + | if let Some(param) = bucket { param } else { return false },
|
13072 + | _diagnostic_collector,
|
13073 + | )
|
13074 + | .into(),
|
13075 + | );
|
13076 + | true
|
13077 + | }
|
13078 + | })(&mut _diagnostic_collector),
|
13079 + | 37 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13080 + | let effective_std_region = &mut context.effective_std_region;
|
13081 + | let partition_result = &mut context.partition_result;
|
13082 + | let url = &mut context.url;
|
13083 + | let access_point_suffix = &mut context.access_point_suffix;
|
13084 + | let region_prefix = &mut context.region_prefix;
|
13085 + | let hardware_type = &mut context.hardware_type;
|
13086 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13087 + | let s3_e_ds = &mut context.s3_e_ds;
|
13088 + | let s3_e_fips = &mut context.s3_e_fips;
|
13089 + | let s3_e_auth = &mut context.s3_e_auth;
|
13090 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13091 + | let bucket_arn = &mut context.bucket_arn;
|
13092 + | let effective_arn_region = &mut context.effective_arn_region;
|
13093 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13094 + | let arn_type = &mut context.arn_type;
|
13095 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13096 + | let bucket_partition = &mut context.bucket_partition;
|
13097 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13098 + | let outpost_type = &mut context.outpost_type;
|
13099 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13100 + | let partition_resolver = &self.partition_resolver;
|
13101 + | (crate::endpoint_lib::coalesce::coalesce!(*use_object_lambda_endpoint, false)) == (true)
|
13102 + | })(&mut _diagnostic_collector),
|
13103 + | 38 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13104 + | let effective_std_region = &mut context.effective_std_region;
|
13105 + | let partition_result = &mut context.partition_result;
|
13106 + | let url = &mut context.url;
|
13107 + | let access_point_suffix = &mut context.access_point_suffix;
|
13108 + | let region_prefix = &mut context.region_prefix;
|
13109 + | let hardware_type = &mut context.hardware_type;
|
13110 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13111 + | let s3_e_ds = &mut context.s3_e_ds;
|
13112 + | let s3_e_fips = &mut context.s3_e_fips;
|
13113 + | let s3_e_auth = &mut context.s3_e_auth;
|
13114 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13115 + | let bucket_arn = &mut context.bucket_arn;
|
13116 + | let effective_arn_region = &mut context.effective_arn_region;
|
13117 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13118 + | let arn_type = &mut context.arn_type;
|
13119 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13120 + | let bucket_partition = &mut context.bucket_partition;
|
13121 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13122 + | let outpost_type = &mut context.outpost_type;
|
13123 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13124 + | let partition_resolver = &self.partition_resolver;
|
13125 + | {
|
13126 + | *arn_type = if let Some(inner) = bucket_arn {
|
13127 + | inner.resource_id().first().cloned()
|
13128 + | } else {
|
13129 + | return false;
|
13130 + | }
|
13131 + | .map(|inner| inner.into());
|
13132 + | arn_type.is_some()
|
13133 + | }
|
13134 + | })(&mut _diagnostic_collector),
|
13135 + | 39 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13136 + | let effective_std_region = &mut context.effective_std_region;
|
13137 + | let partition_result = &mut context.partition_result;
|
13138 + | let url = &mut context.url;
|
13139 + | let access_point_suffix = &mut context.access_point_suffix;
|
13140 + | let region_prefix = &mut context.region_prefix;
|
13141 + | let hardware_type = &mut context.hardware_type;
|
13142 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13143 + | let s3_e_ds = &mut context.s3_e_ds;
|
13144 + | let s3_e_fips = &mut context.s3_e_fips;
|
13145 + | let s3_e_auth = &mut context.s3_e_auth;
|
13146 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13147 + | let bucket_arn = &mut context.bucket_arn;
|
13148 + | let effective_arn_region = &mut context.effective_arn_region;
|
13149 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13150 + | let arn_type = &mut context.arn_type;
|
13151 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13152 + | let bucket_partition = &mut context.bucket_partition;
|
13153 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13154 + | let outpost_type = &mut context.outpost_type;
|
13155 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13156 + | let partition_resolver = &self.partition_resolver;
|
13157 + | (arn_type) == &mut Some(("".into()))
|
13158 + | })(&mut _diagnostic_collector),
|
13159 + | 40 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13160 + | let effective_std_region = &mut context.effective_std_region;
|
13161 + | let partition_result = &mut context.partition_result;
|
13162 + | let url = &mut context.url;
|
13163 + | let access_point_suffix = &mut context.access_point_suffix;
|
13164 + | let region_prefix = &mut context.region_prefix;
|
13165 + | let hardware_type = &mut context.hardware_type;
|
13166 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13167 + | let s3_e_ds = &mut context.s3_e_ds;
|
13168 + | let s3_e_fips = &mut context.s3_e_fips;
|
13169 + | let s3_e_auth = &mut context.s3_e_auth;
|
13170 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13171 + | let bucket_arn = &mut context.bucket_arn;
|
13172 + | let effective_arn_region = &mut context.effective_arn_region;
|
13173 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13174 + | let arn_type = &mut context.arn_type;
|
13175 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13176 + | let bucket_partition = &mut context.bucket_partition;
|
13177 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13178 + | let outpost_type = &mut context.outpost_type;
|
13179 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13180 + | let partition_resolver = &self.partition_resolver;
|
13181 + | (arn_type) == &mut Some(("accesspoint".into()))
|
13182 + | })(&mut _diagnostic_collector),
|
13183 + | 41 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13184 + | let effective_std_region = &mut context.effective_std_region;
|
13185 + | let partition_result = &mut context.partition_result;
|
13186 + | let url = &mut context.url;
|
13187 + | let access_point_suffix = &mut context.access_point_suffix;
|
13188 + | let region_prefix = &mut context.region_prefix;
|
13189 + | let hardware_type = &mut context.hardware_type;
|
13190 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13191 + | let s3_e_ds = &mut context.s3_e_ds;
|
13192 + | let s3_e_fips = &mut context.s3_e_fips;
|
13193 + | let s3_e_auth = &mut context.s3_e_auth;
|
13194 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13195 + | let bucket_arn = &mut context.bucket_arn;
|
13196 + | let effective_arn_region = &mut context.effective_arn_region;
|
13197 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13198 + | let arn_type = &mut context.arn_type;
|
13199 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13200 + | let bucket_partition = &mut context.bucket_partition;
|
13201 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13202 + | let outpost_type = &mut context.outpost_type;
|
13203 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13204 + | let partition_resolver = &self.partition_resolver;
|
13205 + | {
|
13206 + | *access_point_name_ssa_1 = if let Some(inner) = bucket_arn {
|
13207 + | inner.resource_id().get(1).cloned()
|
13208 + | } else {
|
13209 + | return false;
|
13210 + | }
|
13211 + | .map(|inner| inner.into());
|
13212 + | access_point_name_ssa_1.is_some()
|
13213 + | }
|
13214 + | })(&mut _diagnostic_collector),
|
13215 + | 42 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13216 + | let effective_std_region = &mut context.effective_std_region;
|
13217 + | let partition_result = &mut context.partition_result;
|
13218 + | let url = &mut context.url;
|
13219 + | let access_point_suffix = &mut context.access_point_suffix;
|
13220 + | let region_prefix = &mut context.region_prefix;
|
13221 + | let hardware_type = &mut context.hardware_type;
|
13222 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13223 + | let s3_e_ds = &mut context.s3_e_ds;
|
13224 + | let s3_e_fips = &mut context.s3_e_fips;
|
13225 + | let s3_e_auth = &mut context.s3_e_auth;
|
13226 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13227 + | let bucket_arn = &mut context.bucket_arn;
|
13228 + | let effective_arn_region = &mut context.effective_arn_region;
|
13229 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13230 + | let arn_type = &mut context.arn_type;
|
13231 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13232 + | let bucket_partition = &mut context.bucket_partition;
|
13233 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13234 + | let outpost_type = &mut context.outpost_type;
|
13235 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13236 + | let partition_resolver = &self.partition_resolver;
|
13237 + | (access_point_name_ssa_1) == &mut Some(("".into()))
|
13238 + | })(&mut _diagnostic_collector),
|
13239 + | 43 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13240 + | let effective_std_region = &mut context.effective_std_region;
|
13241 + | let partition_result = &mut context.partition_result;
|
13242 + | let url = &mut context.url;
|
13243 + | let access_point_suffix = &mut context.access_point_suffix;
|
13244 + | let region_prefix = &mut context.region_prefix;
|
13245 + | let hardware_type = &mut context.hardware_type;
|
13246 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13247 + | let s3_e_ds = &mut context.s3_e_ds;
|
13248 + | let s3_e_fips = &mut context.s3_e_fips;
|
13249 + | let s3_e_auth = &mut context.s3_e_auth;
|
13250 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13251 + | let bucket_arn = &mut context.bucket_arn;
|
13252 + | let effective_arn_region = &mut context.effective_arn_region;
|
13253 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13254 + | let arn_type = &mut context.arn_type;
|
13255 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13256 + | let bucket_partition = &mut context.bucket_partition;
|
13257 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13258 + | let outpost_type = &mut context.outpost_type;
|
13259 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13260 + | let partition_resolver = &self.partition_resolver;
|
13261 + | (if let Some(inner) = bucket_arn { inner.service() } else { return false }) == ("s3-object-lambda")
|
13262 + | })(&mut _diagnostic_collector),
|
13263 + | 44 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13264 + | let effective_std_region = &mut context.effective_std_region;
|
13265 + | let partition_result = &mut context.partition_result;
|
13266 + | let url = &mut context.url;
|
13267 + | let access_point_suffix = &mut context.access_point_suffix;
|
13268 + | let region_prefix = &mut context.region_prefix;
|
13269 + | let hardware_type = &mut context.hardware_type;
|
13270 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13271 + | let s3_e_ds = &mut context.s3_e_ds;
|
13272 + | let s3_e_fips = &mut context.s3_e_fips;
|
13273 + | let s3_e_auth = &mut context.s3_e_auth;
|
13274 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13275 + | let bucket_arn = &mut context.bucket_arn;
|
13276 + | let effective_arn_region = &mut context.effective_arn_region;
|
13277 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13278 + | let arn_type = &mut context.arn_type;
|
13279 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13280 + | let bucket_partition = &mut context.bucket_partition;
|
13281 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13282 + | let outpost_type = &mut context.outpost_type;
|
13283 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13284 + | let partition_resolver = &self.partition_resolver;
|
13285 + | crate::endpoint_lib::host::is_valid_host_label(
|
13286 + | if let Some(param) = region { param } else { return false },
|
13287 + | true,
|
13288 + | _diagnostic_collector,
|
13289 + | )
|
13290 + | })(&mut _diagnostic_collector),
|
13291 + | 45 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13292 + | let effective_std_region = &mut context.effective_std_region;
|
13293 + | let partition_result = &mut context.partition_result;
|
13294 + | let url = &mut context.url;
|
13295 + | let access_point_suffix = &mut context.access_point_suffix;
|
13296 + | let region_prefix = &mut context.region_prefix;
|
13297 + | let hardware_type = &mut context.hardware_type;
|
13298 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13299 + | let s3_e_ds = &mut context.s3_e_ds;
|
13300 + | let s3_e_fips = &mut context.s3_e_fips;
|
13301 + | let s3_e_auth = &mut context.s3_e_auth;
|
13302 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13303 + | let bucket_arn = &mut context.bucket_arn;
|
13304 + | let effective_arn_region = &mut context.effective_arn_region;
|
13305 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13306 + | let arn_type = &mut context.arn_type;
|
13307 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13308 + | let bucket_partition = &mut context.bucket_partition;
|
13309 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13310 + | let outpost_type = &mut context.outpost_type;
|
13311 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13312 + | let partition_resolver = &self.partition_resolver;
|
13313 + | (if let Some(inner) = bucket_arn { inner.region() } else { return false }) == ("")
|
13314 + | })(&mut _diagnostic_collector),
|
13315 + | 46 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13316 + | let effective_std_region = &mut context.effective_std_region;
|
13317 + | let partition_result = &mut context.partition_result;
|
13318 + | let url = &mut context.url;
|
13319 + | let access_point_suffix = &mut context.access_point_suffix;
|
13320 + | let region_prefix = &mut context.region_prefix;
|
13321 + | let hardware_type = &mut context.hardware_type;
|
13322 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13323 + | let s3_e_ds = &mut context.s3_e_ds;
|
13324 + | let s3_e_fips = &mut context.s3_e_fips;
|
13325 + | let s3_e_auth = &mut context.s3_e_auth;
|
13326 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13327 + | let bucket_arn = &mut context.bucket_arn;
|
13328 + | let effective_arn_region = &mut context.effective_arn_region;
|
13329 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13330 + | let arn_type = &mut context.arn_type;
|
13331 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13332 + | let bucket_partition = &mut context.bucket_partition;
|
13333 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13334 + | let outpost_type = &mut context.outpost_type;
|
13335 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13336 + | let partition_resolver = &self.partition_resolver;
|
13337 + | (hardware_type) == &mut Some(("e".into()))
|
13338 + | })(&mut _diagnostic_collector),
|
13339 + | 47 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13340 + | let effective_std_region = &mut context.effective_std_region;
|
13341 + | let partition_result = &mut context.partition_result;
|
13342 + | let url = &mut context.url;
|
13343 + | let access_point_suffix = &mut context.access_point_suffix;
|
13344 + | let region_prefix = &mut context.region_prefix;
|
13345 + | let hardware_type = &mut context.hardware_type;
|
13346 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13347 + | let s3_e_ds = &mut context.s3_e_ds;
|
13348 + | let s3_e_fips = &mut context.s3_e_fips;
|
13349 + | let s3_e_auth = &mut context.s3_e_auth;
|
13350 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13351 + | let bucket_arn = &mut context.bucket_arn;
|
13352 + | let effective_arn_region = &mut context.effective_arn_region;
|
13353 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13354 + | let arn_type = &mut context.arn_type;
|
13355 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13356 + | let bucket_partition = &mut context.bucket_partition;
|
13357 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13358 + | let outpost_type = &mut context.outpost_type;
|
13359 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13360 + | let partition_resolver = &self.partition_resolver;
|
13361 + | (crate::endpoint_lib::coalesce::coalesce!(
|
13362 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
13363 + | if let Some(param) = bucket { param } else { return false },
|
13364 + | 26,
|
13365 + | 28,
|
13366 + | true,
|
13367 + | _diagnostic_collector
|
13368 + | ) {
|
13369 + | inner
|
13370 + | } else {
|
13371 + | return false;
|
13372 + | },
|
13373 + | ""
|
13374 + | )) == ("--")
|
13375 + | })(&mut _diagnostic_collector),
|
13376 + | 48 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13377 + | let effective_std_region = &mut context.effective_std_region;
|
13378 + | let partition_result = &mut context.partition_result;
|
13379 + | let url = &mut context.url;
|
13380 + | let access_point_suffix = &mut context.access_point_suffix;
|
13381 + | let region_prefix = &mut context.region_prefix;
|
13382 + | let hardware_type = &mut context.hardware_type;
|
13383 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13384 + | let s3_e_ds = &mut context.s3_e_ds;
|
13385 + | let s3_e_fips = &mut context.s3_e_fips;
|
13386 + | let s3_e_auth = &mut context.s3_e_auth;
|
13387 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13388 + | let bucket_arn = &mut context.bucket_arn;
|
13389 + | let effective_arn_region = &mut context.effective_arn_region;
|
13390 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13391 + | let arn_type = &mut context.arn_type;
|
13392 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13393 + | let bucket_partition = &mut context.bucket_partition;
|
13394 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13395 + | let outpost_type = &mut context.outpost_type;
|
13396 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13397 + | let partition_resolver = &self.partition_resolver;
|
13398 + | (crate::endpoint_lib::coalesce::coalesce!(
|
13399 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
13400 + | if let Some(param) = bucket { param } else { return false },
|
13401 + | 19,
|
13402 + | 21,
|
13403 + | true,
|
13404 + | _diagnostic_collector
|
13405 + | ) {
|
13406 + | inner
|
13407 + | } else {
|
13408 + | return false;
|
13409 + | },
|
13410 + | ""
|
13411 + | )) == ("--")
|
13412 + | })(&mut _diagnostic_collector),
|
13413 + | 49 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13414 + | let effective_std_region = &mut context.effective_std_region;
|
13415 + | let partition_result = &mut context.partition_result;
|
13416 + | let url = &mut context.url;
|
13417 + | let access_point_suffix = &mut context.access_point_suffix;
|
13418 + | let region_prefix = &mut context.region_prefix;
|
13419 + | let hardware_type = &mut context.hardware_type;
|
13420 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13421 + | let s3_e_ds = &mut context.s3_e_ds;
|
13422 + | let s3_e_fips = &mut context.s3_e_fips;
|
13423 + | let s3_e_auth = &mut context.s3_e_auth;
|
13424 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13425 + | let bucket_arn = &mut context.bucket_arn;
|
13426 + | let effective_arn_region = &mut context.effective_arn_region;
|
13427 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13428 + | let arn_type = &mut context.arn_type;
|
13429 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13430 + | let bucket_partition = &mut context.bucket_partition;
|
13431 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13432 + | let outpost_type = &mut context.outpost_type;
|
13433 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13434 + | let partition_resolver = &self.partition_resolver;
|
13435 + | (crate::endpoint_lib::coalesce::coalesce!(
|
13436 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
13437 + | if let Some(param) = bucket { param } else { return false },
|
13438 + | 14,
|
13439 + | 16,
|
13440 + | true,
|
13441 + | _diagnostic_collector
|
13442 + | ) {
|
13443 + | inner
|
13444 + | } else {
|
13445 + | return false;
|
13446 + | },
|
13447 + | ""
|
13448 + | )) == ("--")
|
13449 + | })(&mut _diagnostic_collector),
|
13450 + | 50 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13451 + | let effective_std_region = &mut context.effective_std_region;
|
13452 + | let partition_result = &mut context.partition_result;
|
13453 + | let url = &mut context.url;
|
13454 + | let access_point_suffix = &mut context.access_point_suffix;
|
13455 + | let region_prefix = &mut context.region_prefix;
|
13456 + | let hardware_type = &mut context.hardware_type;
|
13457 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13458 + | let s3_e_ds = &mut context.s3_e_ds;
|
13459 + | let s3_e_fips = &mut context.s3_e_fips;
|
13460 + | let s3_e_auth = &mut context.s3_e_auth;
|
13461 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13462 + | let bucket_arn = &mut context.bucket_arn;
|
13463 + | let effective_arn_region = &mut context.effective_arn_region;
|
13464 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13465 + | let arn_type = &mut context.arn_type;
|
13466 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13467 + | let bucket_partition = &mut context.bucket_partition;
|
13468 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13469 + | let outpost_type = &mut context.outpost_type;
|
13470 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13471 + | let partition_resolver = &self.partition_resolver;
|
13472 + | (crate::endpoint_lib::coalesce::coalesce!(
|
13473 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
13474 + | if let Some(param) = bucket { param } else { return false },
|
13475 + | 20,
|
13476 + | 22,
|
13477 + | true,
|
13478 + | _diagnostic_collector
|
13479 + | ) {
|
13480 + | inner
|
13481 + | } else {
|
13482 + | return false;
|
13483 + | },
|
13484 + | ""
|
13485 + | )) == ("--")
|
13486 + | })(&mut _diagnostic_collector),
|
13487 + | 51 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13488 + | let effective_std_region = &mut context.effective_std_region;
|
13489 + | let partition_result = &mut context.partition_result;
|
13490 + | let url = &mut context.url;
|
13491 + | let access_point_suffix = &mut context.access_point_suffix;
|
13492 + | let region_prefix = &mut context.region_prefix;
|
13493 + | let hardware_type = &mut context.hardware_type;
|
13494 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13495 + | let s3_e_ds = &mut context.s3_e_ds;
|
13496 + | let s3_e_fips = &mut context.s3_e_fips;
|
13497 + | let s3_e_auth = &mut context.s3_e_auth;
|
13498 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13499 + | let bucket_arn = &mut context.bucket_arn;
|
13500 + | let effective_arn_region = &mut context.effective_arn_region;
|
13501 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13502 + | let arn_type = &mut context.arn_type;
|
13503 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13504 + | let bucket_partition = &mut context.bucket_partition;
|
13505 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13506 + | let outpost_type = &mut context.outpost_type;
|
13507 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13508 + | let partition_resolver = &self.partition_resolver;
|
13509 + | (crate::endpoint_lib::coalesce::coalesce!(
|
13510 + | if let Some(inner) = crate::endpoint_lib::substring::substring(
|
13511 + | if let Some(param) = bucket { param } else { return false },
|
13512 + | 15,
|
13513 + | 17,
|
13514 + | true,
|
13515 + | _diagnostic_collector
|
13516 + | ) {
|
13517 + | inner
|
13518 + | } else {
|
13519 + | return false;
|
13520 + | },
|
13521 + | ""
|
13522 + | )) == ("--")
|
13523 + | })(&mut _diagnostic_collector),
|
13524 + | 52 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13525 + | let effective_std_region = &mut context.effective_std_region;
|
13526 + | let partition_result = &mut context.partition_result;
|
13527 + | let url = &mut context.url;
|
13528 + | let access_point_suffix = &mut context.access_point_suffix;
|
13529 + | let region_prefix = &mut context.region_prefix;
|
13530 + | let hardware_type = &mut context.hardware_type;
|
13531 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13532 + | let s3_e_ds = &mut context.s3_e_ds;
|
13533 + | let s3_e_fips = &mut context.s3_e_fips;
|
13534 + | let s3_e_auth = &mut context.s3_e_auth;
|
13535 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13536 + | let bucket_arn = &mut context.bucket_arn;
|
13537 + | let effective_arn_region = &mut context.effective_arn_region;
|
13538 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13539 + | let arn_type = &mut context.arn_type;
|
13540 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13541 + | let bucket_partition = &mut context.bucket_partition;
|
13542 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13543 + | let outpost_type = &mut context.outpost_type;
|
13544 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13545 + | let partition_resolver = &self.partition_resolver;
|
13546 + | (if let Some(inner) = bucket_arn { inner.service() } else { return false }) == ("s3-outposts")
|
13547 + | })(&mut _diagnostic_collector),
|
13548 + | 53 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13549 + | let effective_std_region = &mut context.effective_std_region;
|
13550 + | let partition_result = &mut context.partition_result;
|
13551 + | let url = &mut context.url;
|
13552 + | let access_point_suffix = &mut context.access_point_suffix;
|
13553 + | let region_prefix = &mut context.region_prefix;
|
13554 + | let hardware_type = &mut context.hardware_type;
|
13555 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13556 + | let s3_e_ds = &mut context.s3_e_ds;
|
13557 + | let s3_e_fips = &mut context.s3_e_fips;
|
13558 + | let s3_e_auth = &mut context.s3_e_auth;
|
13559 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13560 + | let bucket_arn = &mut context.bucket_arn;
|
13561 + | let effective_arn_region = &mut context.effective_arn_region;
|
13562 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13563 + | let arn_type = &mut context.arn_type;
|
13564 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13565 + | let bucket_partition = &mut context.bucket_partition;
|
13566 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13567 + | let outpost_type = &mut context.outpost_type;
|
13568 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13569 + | let partition_resolver = &self.partition_resolver;
|
13570 + | (crate::endpoint_lib::coalesce::coalesce!(*disable_access_points, false)) == (true)
|
13571 + | })(&mut _diagnostic_collector),
|
13572 + | 54 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13573 + | let effective_std_region = &mut context.effective_std_region;
|
13574 + | let partition_result = &mut context.partition_result;
|
13575 + | let url = &mut context.url;
|
13576 + | let access_point_suffix = &mut context.access_point_suffix;
|
13577 + | let region_prefix = &mut context.region_prefix;
|
13578 + | let hardware_type = &mut context.hardware_type;
|
13579 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13580 + | let s3_e_ds = &mut context.s3_e_ds;
|
13581 + | let s3_e_fips = &mut context.s3_e_fips;
|
13582 + | let s3_e_auth = &mut context.s3_e_auth;
|
13583 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13584 + | let bucket_arn = &mut context.bucket_arn;
|
13585 + | let effective_arn_region = &mut context.effective_arn_region;
|
13586 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13587 + | let arn_type = &mut context.arn_type;
|
13588 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13589 + | let bucket_partition = &mut context.bucket_partition;
|
13590 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13591 + | let outpost_type = &mut context.outpost_type;
|
13592 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13593 + | let partition_resolver = &self.partition_resolver;
|
13594 + | {
|
13595 + | *bucket_partition = partition_resolver
|
13596 + | .resolve_partition(
|
13597 + | if let Some(param) = effective_arn_region { param } else { return false },
|
13598 + | _diagnostic_collector,
|
13599 + | )
|
13600 + | .map(|inner| inner.into());
|
13601 + | bucket_partition.is_some()
|
13602 + | }
|
13603 + | })(&mut _diagnostic_collector),
|
13604 + | 55 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13605 + | let effective_std_region = &mut context.effective_std_region;
|
13606 + | let partition_result = &mut context.partition_result;
|
13607 + | let url = &mut context.url;
|
13608 + | let access_point_suffix = &mut context.access_point_suffix;
|
13609 + | let region_prefix = &mut context.region_prefix;
|
13610 + | let hardware_type = &mut context.hardware_type;
|
13611 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13612 + | let s3_e_ds = &mut context.s3_e_ds;
|
13613 + | let s3_e_fips = &mut context.s3_e_fips;
|
13614 + | let s3_e_auth = &mut context.s3_e_auth;
|
13615 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13616 + | let bucket_arn = &mut context.bucket_arn;
|
13617 + | let effective_arn_region = &mut context.effective_arn_region;
|
13618 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13619 + | let arn_type = &mut context.arn_type;
|
13620 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13621 + | let bucket_partition = &mut context.bucket_partition;
|
13622 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13623 + | let outpost_type = &mut context.outpost_type;
|
13624 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13625 + | let partition_resolver = &self.partition_resolver;
|
13626 + | (hardware_type) == &mut Some(("o".into()))
|
13627 + | })(&mut _diagnostic_collector),
|
13628 + | 56 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13629 + | let effective_std_region = &mut context.effective_std_region;
|
13630 + | let partition_result = &mut context.partition_result;
|
13631 + | let url = &mut context.url;
|
13632 + | let access_point_suffix = &mut context.access_point_suffix;
|
13633 + | let region_prefix = &mut context.region_prefix;
|
13634 + | let hardware_type = &mut context.hardware_type;
|
13635 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13636 + | let s3_e_ds = &mut context.s3_e_ds;
|
13637 + | let s3_e_fips = &mut context.s3_e_fips;
|
13638 + | let s3_e_auth = &mut context.s3_e_auth;
|
13639 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13640 + | let bucket_arn = &mut context.bucket_arn;
|
13641 + | let effective_arn_region = &mut context.effective_arn_region;
|
13642 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13643 + | let arn_type = &mut context.arn_type;
|
13644 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13645 + | let bucket_partition = &mut context.bucket_partition;
|
13646 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13647 + | let outpost_type = &mut context.outpost_type;
|
13648 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13649 + | let partition_resolver = &self.partition_resolver;
|
13650 + | if let Some(inner) = bucket_arn {
|
13651 + | inner.resource_id().get(4).cloned()
|
13652 + | } else {
|
13653 + | return false;
|
13654 + | }
|
13655 + | .is_some()
|
13656 + | })(&mut _diagnostic_collector),
|
13657 + | 57 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13658 + | let effective_std_region = &mut context.effective_std_region;
|
13659 + | let partition_result = &mut context.partition_result;
|
13660 + | let url = &mut context.url;
|
13661 + | let access_point_suffix = &mut context.access_point_suffix;
|
13662 + | let region_prefix = &mut context.region_prefix;
|
13663 + | let hardware_type = &mut context.hardware_type;
|
13664 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13665 + | let s3_e_ds = &mut context.s3_e_ds;
|
13666 + | let s3_e_fips = &mut context.s3_e_fips;
|
13667 + | let s3_e_auth = &mut context.s3_e_auth;
|
13668 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13669 + | let bucket_arn = &mut context.bucket_arn;
|
13670 + | let effective_arn_region = &mut context.effective_arn_region;
|
13671 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13672 + | let arn_type = &mut context.arn_type;
|
13673 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13674 + | let bucket_partition = &mut context.bucket_partition;
|
13675 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13676 + | let outpost_type = &mut context.outpost_type;
|
13677 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13678 + | let partition_resolver = &self.partition_resolver;
|
13679 + | {
|
13680 + | *outpost_id_ssa_1 = if let Some(inner) = bucket_arn {
|
13681 + | inner.resource_id().get(1).cloned()
|
13682 + | } else {
|
13683 + | return false;
|
13684 + | }
|
13685 + | .map(|inner| inner.into());
|
13686 + | outpost_id_ssa_1.is_some()
|
13687 + | }
|
13688 + | })(&mut _diagnostic_collector),
|
13689 + | 58 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13690 + | let effective_std_region = &mut context.effective_std_region;
|
13691 + | let partition_result = &mut context.partition_result;
|
13692 + | let url = &mut context.url;
|
13693 + | let access_point_suffix = &mut context.access_point_suffix;
|
13694 + | let region_prefix = &mut context.region_prefix;
|
13695 + | let hardware_type = &mut context.hardware_type;
|
13696 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13697 + | let s3_e_ds = &mut context.s3_e_ds;
|
13698 + | let s3_e_fips = &mut context.s3_e_fips;
|
13699 + | let s3_e_auth = &mut context.s3_e_auth;
|
13700 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13701 + | let bucket_arn = &mut context.bucket_arn;
|
13702 + | let effective_arn_region = &mut context.effective_arn_region;
|
13703 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13704 + | let arn_type = &mut context.arn_type;
|
13705 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13706 + | let bucket_partition = &mut context.bucket_partition;
|
13707 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13708 + | let outpost_type = &mut context.outpost_type;
|
13709 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13710 + | let partition_resolver = &self.partition_resolver;
|
13711 + | (crate::endpoint_lib::coalesce::coalesce!(*use_arn_region, true)) == (true)
|
13712 + | })(&mut _diagnostic_collector),
|
13713 + | 59 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13714 + | let effective_std_region = &mut context.effective_std_region;
|
13715 + | let partition_result = &mut context.partition_result;
|
13716 + | let url = &mut context.url;
|
13717 + | let access_point_suffix = &mut context.access_point_suffix;
|
13718 + | let region_prefix = &mut context.region_prefix;
|
13719 + | let hardware_type = &mut context.hardware_type;
|
13720 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13721 + | let s3_e_ds = &mut context.s3_e_ds;
|
13722 + | let s3_e_fips = &mut context.s3_e_fips;
|
13723 + | let s3_e_auth = &mut context.s3_e_auth;
|
13724 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13725 + | let bucket_arn = &mut context.bucket_arn;
|
13726 + | let effective_arn_region = &mut context.effective_arn_region;
|
13727 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13728 + | let arn_type = &mut context.arn_type;
|
13729 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13730 + | let bucket_partition = &mut context.bucket_partition;
|
13731 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13732 + | let outpost_type = &mut context.outpost_type;
|
13733 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13734 + | let partition_resolver = &self.partition_resolver;
|
13735 + | (effective_arn_region) == &mut Some((if let Some(inner) = bucket_arn { inner.region() } else { return false }.into()))
|
13736 + | })(&mut _diagnostic_collector),
|
13737 + | 60 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13738 + | let effective_std_region = &mut context.effective_std_region;
|
13739 + | let partition_result = &mut context.partition_result;
|
13740 + | let url = &mut context.url;
|
13741 + | let access_point_suffix = &mut context.access_point_suffix;
|
13742 + | let region_prefix = &mut context.region_prefix;
|
13743 + | let hardware_type = &mut context.hardware_type;
|
13744 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13745 + | let s3_e_ds = &mut context.s3_e_ds;
|
13746 + | let s3_e_fips = &mut context.s3_e_fips;
|
13747 + | let s3_e_auth = &mut context.s3_e_auth;
|
13748 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13749 + | let bucket_arn = &mut context.bucket_arn;
|
13750 + | let effective_arn_region = &mut context.effective_arn_region;
|
13751 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13752 + | let arn_type = &mut context.arn_type;
|
13753 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13754 + | let bucket_partition = &mut context.bucket_partition;
|
13755 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13756 + | let outpost_type = &mut context.outpost_type;
|
13757 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13758 + | let partition_resolver = &self.partition_resolver;
|
13759 + | (region) == &mut Some(("aws-global".into()))
|
13760 + | })(&mut _diagnostic_collector),
|
13761 + | 61 => (use_global_endpoint) == (&true),
|
13762 + | 62 => (disable_multi_region_access_points) == (&true),
|
13763 + | 63 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13764 + | let effective_std_region = &mut context.effective_std_region;
|
13765 + | let partition_result = &mut context.partition_result;
|
13766 + | let url = &mut context.url;
|
13767 + | let access_point_suffix = &mut context.access_point_suffix;
|
13768 + | let region_prefix = &mut context.region_prefix;
|
13769 + | let hardware_type = &mut context.hardware_type;
|
13770 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13771 + | let s3_e_ds = &mut context.s3_e_ds;
|
13772 + | let s3_e_fips = &mut context.s3_e_fips;
|
13773 + | let s3_e_auth = &mut context.s3_e_auth;
|
13774 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13775 + | let bucket_arn = &mut context.bucket_arn;
|
13776 + | let effective_arn_region = &mut context.effective_arn_region;
|
13777 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13778 + | let arn_type = &mut context.arn_type;
|
13779 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13780 + | let bucket_partition = &mut context.bucket_partition;
|
13781 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13782 + | let outpost_type = &mut context.outpost_type;
|
13783 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13784 + | let partition_resolver = &self.partition_resolver;
|
13785 + | (region) == &mut Some(("us-east-1".into()))
|
13786 + | })(&mut _diagnostic_collector),
|
13787 + | 64 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13788 + | let effective_std_region = &mut context.effective_std_region;
|
13789 + | let partition_result = &mut context.partition_result;
|
13790 + | let url = &mut context.url;
|
13791 + | let access_point_suffix = &mut context.access_point_suffix;
|
13792 + | let region_prefix = &mut context.region_prefix;
|
13793 + | let hardware_type = &mut context.hardware_type;
|
13794 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13795 + | let s3_e_ds = &mut context.s3_e_ds;
|
13796 + | let s3_e_fips = &mut context.s3_e_fips;
|
13797 + | let s3_e_auth = &mut context.s3_e_auth;
|
13798 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13799 + | let bucket_arn = &mut context.bucket_arn;
|
13800 + | let effective_arn_region = &mut context.effective_arn_region;
|
13801 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13802 + | let arn_type = &mut context.arn_type;
|
13803 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13804 + | let bucket_partition = &mut context.bucket_partition;
|
13805 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13806 + | let outpost_type = &mut context.outpost_type;
|
13807 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13808 + | let partition_resolver = &self.partition_resolver;
|
13809 + | crate::endpoint_lib::host::is_valid_host_label(
|
13810 + | if let Some(param) = outpost_id_ssa_1 { param } else { return false },
|
13811 + | false,
|
13812 + | _diagnostic_collector,
|
13813 + | )
|
13814 + | })(&mut _diagnostic_collector),
|
13815 + | 65 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13816 + | let effective_std_region = &mut context.effective_std_region;
|
13817 + | let partition_result = &mut context.partition_result;
|
13818 + | let url = &mut context.url;
|
13819 + | let access_point_suffix = &mut context.access_point_suffix;
|
13820 + | let region_prefix = &mut context.region_prefix;
|
13821 + | let hardware_type = &mut context.hardware_type;
|
13822 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13823 + | let s3_e_ds = &mut context.s3_e_ds;
|
13824 + | let s3_e_fips = &mut context.s3_e_fips;
|
13825 + | let s3_e_auth = &mut context.s3_e_auth;
|
13826 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13827 + | let bucket_arn = &mut context.bucket_arn;
|
13828 + | let effective_arn_region = &mut context.effective_arn_region;
|
13829 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13830 + | let arn_type = &mut context.arn_type;
|
13831 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13832 + | let bucket_partition = &mut context.bucket_partition;
|
13833 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13834 + | let outpost_type = &mut context.outpost_type;
|
13835 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13836 + | let partition_resolver = &self.partition_resolver;
|
13837 + | {
|
13838 + | *outpost_type = if let Some(inner) = bucket_arn {
|
13839 + | inner.resource_id().get(2).cloned()
|
13840 + | } else {
|
13841 + | return false;
|
13842 + | }
|
13843 + | .map(|inner| inner.into());
|
13844 + | outpost_type.is_some()
|
13845 + | }
|
13846 + | })(&mut _diagnostic_collector),
|
13847 + | 66 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13848 + | let effective_std_region = &mut context.effective_std_region;
|
13849 + | let partition_result = &mut context.partition_result;
|
13850 + | let url = &mut context.url;
|
13851 + | let access_point_suffix = &mut context.access_point_suffix;
|
13852 + | let region_prefix = &mut context.region_prefix;
|
13853 + | let hardware_type = &mut context.hardware_type;
|
13854 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13855 + | let s3_e_ds = &mut context.s3_e_ds;
|
13856 + | let s3_e_fips = &mut context.s3_e_fips;
|
13857 + | let s3_e_auth = &mut context.s3_e_auth;
|
13858 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13859 + | let bucket_arn = &mut context.bucket_arn;
|
13860 + | let effective_arn_region = &mut context.effective_arn_region;
|
13861 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13862 + | let arn_type = &mut context.arn_type;
|
13863 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13864 + | let bucket_partition = &mut context.bucket_partition;
|
13865 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13866 + | let outpost_type = &mut context.outpost_type;
|
13867 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13868 + | let partition_resolver = &self.partition_resolver;
|
13869 + | (if let Some(inner) = bucket_partition {
|
13870 + | inner.name()
|
13871 + | } else {
|
13872 + | return false;
|
13873 + | }) == (if let Some(inner) = partition_result {
|
13874 + | inner.name()
|
13875 + | } else {
|
13876 + | return false;
|
13877 + | })
|
13878 + | })(&mut _diagnostic_collector),
|
13879 + | 67 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13880 + | let effective_std_region = &mut context.effective_std_region;
|
13881 + | let partition_result = &mut context.partition_result;
|
13882 + | let url = &mut context.url;
|
13883 + | let access_point_suffix = &mut context.access_point_suffix;
|
13884 + | let region_prefix = &mut context.region_prefix;
|
13885 + | let hardware_type = &mut context.hardware_type;
|
13886 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13887 + | let s3_e_ds = &mut context.s3_e_ds;
|
13888 + | let s3_e_fips = &mut context.s3_e_fips;
|
13889 + | let s3_e_auth = &mut context.s3_e_auth;
|
13890 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13891 + | let bucket_arn = &mut context.bucket_arn;
|
13892 + | let effective_arn_region = &mut context.effective_arn_region;
|
13893 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13894 + | let arn_type = &mut context.arn_type;
|
13895 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13896 + | let bucket_partition = &mut context.bucket_partition;
|
13897 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13898 + | let outpost_type = &mut context.outpost_type;
|
13899 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13900 + | let partition_resolver = &self.partition_resolver;
|
13901 + | crate::endpoint_lib::host::is_valid_host_label(
|
13902 + | if let Some(param) = effective_arn_region { param } else { return false },
|
13903 + | true,
|
13904 + | _diagnostic_collector,
|
13905 + | )
|
13906 + | })(&mut _diagnostic_collector),
|
13907 + | 68 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13908 + | let effective_std_region = &mut context.effective_std_region;
|
13909 + | let partition_result = &mut context.partition_result;
|
13910 + | let url = &mut context.url;
|
13911 + | let access_point_suffix = &mut context.access_point_suffix;
|
13912 + | let region_prefix = &mut context.region_prefix;
|
13913 + | let hardware_type = &mut context.hardware_type;
|
13914 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13915 + | let s3_e_ds = &mut context.s3_e_ds;
|
13916 + | let s3_e_fips = &mut context.s3_e_fips;
|
13917 + | let s3_e_auth = &mut context.s3_e_auth;
|
13918 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13919 + | let bucket_arn = &mut context.bucket_arn;
|
13920 + | let effective_arn_region = &mut context.effective_arn_region;
|
13921 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13922 + | let arn_type = &mut context.arn_type;
|
13923 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13924 + | let bucket_partition = &mut context.bucket_partition;
|
13925 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13926 + | let outpost_type = &mut context.outpost_type;
|
13927 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13928 + | let partition_resolver = &self.partition_resolver;
|
13929 + | (if let Some(inner) = bucket_arn { inner.service() } else { return false }) == ("s3")
|
13930 + | })(&mut _diagnostic_collector),
|
13931 + | 69 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13932 + | let effective_std_region = &mut context.effective_std_region;
|
13933 + | let partition_result = &mut context.partition_result;
|
13934 + | let url = &mut context.url;
|
13935 + | let access_point_suffix = &mut context.access_point_suffix;
|
13936 + | let region_prefix = &mut context.region_prefix;
|
13937 + | let hardware_type = &mut context.hardware_type;
|
13938 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13939 + | let s3_e_ds = &mut context.s3_e_ds;
|
13940 + | let s3_e_fips = &mut context.s3_e_fips;
|
13941 + | let s3_e_auth = &mut context.s3_e_auth;
|
13942 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13943 + | let bucket_arn = &mut context.bucket_arn;
|
13944 + | let effective_arn_region = &mut context.effective_arn_region;
|
13945 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13946 + | let arn_type = &mut context.arn_type;
|
13947 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13948 + | let bucket_partition = &mut context.bucket_partition;
|
13949 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13950 + | let outpost_type = &mut context.outpost_type;
|
13951 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13952 + | let partition_resolver = &self.partition_resolver;
|
13953 + | (if let Some(inner) = bucket_arn {
|
13954 + | inner.account_id()
|
13955 + | } else {
|
13956 + | return false;
|
13957 + | }) == ("")
|
13958 + | })(&mut _diagnostic_collector),
|
13959 + | 70 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13960 + | let effective_std_region = &mut context.effective_std_region;
|
13961 + | let partition_result = &mut context.partition_result;
|
13962 + | let url = &mut context.url;
|
13963 + | let access_point_suffix = &mut context.access_point_suffix;
|
13964 + | let region_prefix = &mut context.region_prefix;
|
13965 + | let hardware_type = &mut context.hardware_type;
|
13966 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13967 + | let s3_e_ds = &mut context.s3_e_ds;
|
13968 + | let s3_e_fips = &mut context.s3_e_fips;
|
13969 + | let s3_e_auth = &mut context.s3_e_auth;
|
13970 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
13971 + | let bucket_arn = &mut context.bucket_arn;
|
13972 + | let effective_arn_region = &mut context.effective_arn_region;
|
13973 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
13974 + | let arn_type = &mut context.arn_type;
|
13975 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
13976 + | let bucket_partition = &mut context.bucket_partition;
|
13977 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
13978 + | let outpost_type = &mut context.outpost_type;
|
13979 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
13980 + | let partition_resolver = &self.partition_resolver;
|
13981 + | crate::endpoint_lib::host::is_valid_host_label(
|
13982 + | if let Some(inner) = bucket_arn {
|
13983 + | inner.account_id()
|
13984 + | } else {
|
13985 + | return false;
|
13986 + | },
|
13987 + | false,
|
13988 + | _diagnostic_collector,
|
13989 + | )
|
13990 + | })(&mut _diagnostic_collector),
|
13991 + | 71 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
13992 + | let effective_std_region = &mut context.effective_std_region;
|
13993 + | let partition_result = &mut context.partition_result;
|
13994 + | let url = &mut context.url;
|
13995 + | let access_point_suffix = &mut context.access_point_suffix;
|
13996 + | let region_prefix = &mut context.region_prefix;
|
13997 + | let hardware_type = &mut context.hardware_type;
|
13998 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
13999 + | let s3_e_ds = &mut context.s3_e_ds;
|
14000 + | let s3_e_fips = &mut context.s3_e_fips;
|
14001 + | let s3_e_auth = &mut context.s3_e_auth;
|
14002 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
14003 + | let bucket_arn = &mut context.bucket_arn;
|
14004 + | let effective_arn_region = &mut context.effective_arn_region;
|
14005 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
14006 + | let arn_type = &mut context.arn_type;
|
14007 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
14008 + | let bucket_partition = &mut context.bucket_partition;
|
14009 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
14010 + | let outpost_type = &mut context.outpost_type;
|
14011 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
14012 + | let partition_resolver = &self.partition_resolver;
|
14013 + | crate::endpoint_lib::host::is_valid_host_label(
|
14014 + | if let Some(param) = access_point_name_ssa_1 {
|
14015 + | param
|
14016 + | } else {
|
14017 + | return false;
|
14018 + | },
|
14019 + | false,
|
14020 + | _diagnostic_collector,
|
14021 + | )
|
14022 + | })(&mut _diagnostic_collector),
|
14023 + | 72 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
14024 + | let effective_std_region = &mut context.effective_std_region;
|
14025 + | let partition_result = &mut context.partition_result;
|
14026 + | let url = &mut context.url;
|
14027 + | let access_point_suffix = &mut context.access_point_suffix;
|
14028 + | let region_prefix = &mut context.region_prefix;
|
14029 + | let hardware_type = &mut context.hardware_type;
|
14030 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
14031 + | let s3_e_ds = &mut context.s3_e_ds;
|
14032 + | let s3_e_fips = &mut context.s3_e_fips;
|
14033 + | let s3_e_auth = &mut context.s3_e_auth;
|
14034 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
14035 + | let bucket_arn = &mut context.bucket_arn;
|
14036 + | let effective_arn_region = &mut context.effective_arn_region;
|
14037 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
14038 + | let arn_type = &mut context.arn_type;
|
14039 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
14040 + | let bucket_partition = &mut context.bucket_partition;
|
14041 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
14042 + | let outpost_type = &mut context.outpost_type;
|
14043 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
14044 + | let partition_resolver = &self.partition_resolver;
|
14045 + | {
|
14046 + | *access_point_name_ssa_2 = if let Some(inner) = bucket_arn {
|
14047 + | inner.resource_id().get(3).cloned()
|
14048 + | } else {
|
14049 + | return false;
|
14050 + | }
|
14051 + | .map(|inner| inner.into());
|
14052 + | access_point_name_ssa_2.is_some()
|
14053 + | }
|
14054 + | })(&mut _diagnostic_collector),
|
14055 + | 73 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
14056 + | let effective_std_region = &mut context.effective_std_region;
|
14057 + | let partition_result = &mut context.partition_result;
|
14058 + | let url = &mut context.url;
|
14059 + | let access_point_suffix = &mut context.access_point_suffix;
|
14060 + | let region_prefix = &mut context.region_prefix;
|
14061 + | let hardware_type = &mut context.hardware_type;
|
14062 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
14063 + | let s3_e_ds = &mut context.s3_e_ds;
|
14064 + | let s3_e_fips = &mut context.s3_e_fips;
|
14065 + | let s3_e_auth = &mut context.s3_e_auth;
|
14066 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
14067 + | let bucket_arn = &mut context.bucket_arn;
|
14068 + | let effective_arn_region = &mut context.effective_arn_region;
|
14069 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
14070 + | let arn_type = &mut context.arn_type;
|
14071 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
14072 + | let bucket_partition = &mut context.bucket_partition;
|
14073 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
14074 + | let outpost_type = &mut context.outpost_type;
|
14075 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
14076 + | let partition_resolver = &self.partition_resolver;
|
14077 + | crate::endpoint_lib::host::is_valid_host_label(
|
14078 + | if let Some(param) = access_point_name_ssa_1 {
|
14079 + | param
|
14080 + | } else {
|
14081 + | return false;
|
14082 + | },
|
14083 + | true,
|
14084 + | _diagnostic_collector,
|
14085 + | )
|
14086 + | })(&mut _diagnostic_collector),
|
14087 + | 74 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
14088 + | let effective_std_region = &mut context.effective_std_region;
|
14089 + | let partition_result = &mut context.partition_result;
|
14090 + | let url = &mut context.url;
|
14091 + | let access_point_suffix = &mut context.access_point_suffix;
|
14092 + | let region_prefix = &mut context.region_prefix;
|
14093 + | let hardware_type = &mut context.hardware_type;
|
14094 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
14095 + | let s3_e_ds = &mut context.s3_e_ds;
|
14096 + | let s3_e_fips = &mut context.s3_e_fips;
|
14097 + | let s3_e_auth = &mut context.s3_e_auth;
|
14098 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
14099 + | let bucket_arn = &mut context.bucket_arn;
|
14100 + | let effective_arn_region = &mut context.effective_arn_region;
|
14101 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
14102 + | let arn_type = &mut context.arn_type;
|
14103 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
14104 + | let bucket_partition = &mut context.bucket_partition;
|
14105 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
14106 + | let outpost_type = &mut context.outpost_type;
|
14107 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
14108 + | let partition_resolver = &self.partition_resolver;
|
14109 + | (if let Some(inner) = bucket_arn { inner.partition() } else { return false })
|
14110 + | == (if let Some(inner) = partition_result {
|
14111 + | inner.name()
|
14112 + | } else {
|
14113 + | return false;
|
14114 + | })
|
14115 + | })(&mut _diagnostic_collector),
|
14116 + | 75 => (|_diagnostic_collector: &mut crate::endpoint_lib::diagnostic::DiagnosticCollector| -> bool {
|
14117 + | let effective_std_region = &mut context.effective_std_region;
|
14118 + | let partition_result = &mut context.partition_result;
|
14119 + | let url = &mut context.url;
|
14120 + | let access_point_suffix = &mut context.access_point_suffix;
|
14121 + | let region_prefix = &mut context.region_prefix;
|
14122 + | let hardware_type = &mut context.hardware_type;
|
14123 + | let outpost_id_ssa_2 = &mut context.outpost_id_ssa_2;
|
14124 + | let s3_e_ds = &mut context.s3_e_ds;
|
14125 + | let s3_e_fips = &mut context.s3_e_fips;
|
14126 + | let s3_e_auth = &mut context.s3_e_auth;
|
14127 + | let s3express_availability_zone_id = &mut context.s3express_availability_zone_id;
|
14128 + | let bucket_arn = &mut context.bucket_arn;
|
14129 + | let effective_arn_region = &mut context.effective_arn_region;
|
14130 + | let uri_encoded_bucket = &mut context.uri_encoded_bucket;
|
14131 + | let arn_type = &mut context.arn_type;
|
14132 + | let access_point_name_ssa_1 = &mut context.access_point_name_ssa_1;
|
14133 + | let bucket_partition = &mut context.bucket_partition;
|
14134 + | let outpost_id_ssa_1 = &mut context.outpost_id_ssa_1;
|
14135 + | let outpost_type = &mut context.outpost_type;
|
14136 + | let access_point_name_ssa_2 = &mut context.access_point_name_ssa_2;
|
14137 + | let partition_resolver = &self.partition_resolver;
|
14138 + | (outpost_type) == &mut Some(("accesspoint".into()))
|
14139 + | })(&mut _diagnostic_collector),
|
14140 + | _ => unreachable!("Invalid condition index"),
|
14141 + | };
|
14142 + | current_ref = if is_complement ^ condition_result { node.high_ref } else { node.low_ref };
|
14143 + | }
|
15242 14144 | }
|
15243 - | Self::Result96 => ::std::result::Result::Err(::aws_smithy_http::endpoint::ResolveEndpointError::message(
|
15244 - | "A region must be set when sending requests to S3.".to_string(),
|
15245 - | )),
|
15246 14145 | }
|
15247 14146 | }
|
15248 14147 | }
|
15249 14148 |
|
15250 - | const RESULTS: [ResultEndpoint; 97] = [
|
15251 - | ResultEndpoint::Result0,
|
15252 - | ResultEndpoint::Result1,
|
15253 - | ResultEndpoint::Result2,
|
15254 - | ResultEndpoint::Result3,
|
15255 - | ResultEndpoint::Result4,
|
15256 - | ResultEndpoint::Result5,
|
15257 - | ResultEndpoint::Result6,
|
15258 - | ResultEndpoint::Result7,
|
15259 - | ResultEndpoint::Result8,
|
15260 - | ResultEndpoint::Result9,
|
15261 - | ResultEndpoint::Result10,
|
15262 - | ResultEndpoint::Result11,
|
15263 - | ResultEndpoint::Result12,
|
15264 - | ResultEndpoint::Result13,
|
15265 - | ResultEndpoint::Result14,
|
15266 - | ResultEndpoint::Result15,
|
15267 - | ResultEndpoint::Result16,
|
15268 - | ResultEndpoint::Result17,
|
15269 - | ResultEndpoint::Result18,
|
15270 - | ResultEndpoint::Result19,
|
15271 - | ResultEndpoint::Result20,
|
15272 - | ResultEndpoint::Result21,
|
15273 - | ResultEndpoint::Result22,
|
15274 - | ResultEndpoint::Result23,
|
15275 - | ResultEndpoint::Result24,
|
15276 - | ResultEndpoint::Result25,
|
15277 - | ResultEndpoint::Result26,
|
15278 - | ResultEndpoint::Result27,
|
15279 - | ResultEndpoint::Result28,
|
15280 - | ResultEndpoint::Result29,
|
15281 - | ResultEndpoint::Result30,
|
15282 - | ResultEndpoint::Result31,
|
15283 - | ResultEndpoint::Result32,
|
15284 - | ResultEndpoint::Result33,
|
15285 - | ResultEndpoint::Result34,
|
15286 - | ResultEndpoint::Result35,
|
15287 - | ResultEndpoint::Result36,
|
15288 - | ResultEndpoint::Result37,
|
15289 - | ResultEndpoint::Result38,
|
15290 - | ResultEndpoint::Result39,
|
15291 - | ResultEndpoint::Result40,
|
15292 - | ResultEndpoint::Result41,
|
15293 - | ResultEndpoint::Result42,
|
15294 - | ResultEndpoint::Result43,
|
15295 - | ResultEndpoint::Result44,
|
15296 - | ResultEndpoint::Result45,
|
15297 - | ResultEndpoint::Result46,
|
15298 - | ResultEndpoint::Result47,
|
15299 - | ResultEndpoint::Result48,
|
15300 - | ResultEndpoint::Result49,
|
15301 - | ResultEndpoint::Result50,
|
15302 - | ResultEndpoint::Result51,
|
15303 - | ResultEndpoint::Result52,
|
15304 - | ResultEndpoint::Result53,
|
15305 - | ResultEndpoint::Result54,
|
15306 - | ResultEndpoint::Result55,
|
15307 - | ResultEndpoint::Result56,
|
15308 - | ResultEndpoint::Result57,
|
15309 - | ResultEndpoint::Result58,
|
15310 - | ResultEndpoint::Result59,
|
15311 - | ResultEndpoint::Result60,
|
15312 - | ResultEndpoint::Result61,
|
15313 - | ResultEndpoint::Result62,
|
15314 - | ResultEndpoint::Result63,
|
15315 - | ResultEndpoint::Result64,
|
15316 - | ResultEndpoint::Result65,
|
15317 - | ResultEndpoint::Result66,
|
15318 - | ResultEndpoint::Result67,
|
15319 - | ResultEndpoint::Result68,
|
15320 - | ResultEndpoint::Result69,
|
15321 - | ResultEndpoint::Result70,
|
15322 - | ResultEndpoint::Result71,
|
15323 - | ResultEndpoint::Result72,
|
15324 - | ResultEndpoint::Result73,
|
15325 - | ResultEndpoint::Result74,
|
15326 - | ResultEndpoint::Result75,
|
15327 - | ResultEndpoint::Result76,
|
15328 - | ResultEndpoint::Result77,
|
15329 - | ResultEndpoint::Result78,
|
15330 - | ResultEndpoint::Result79,
|
15331 - | ResultEndpoint::Result80,
|
15332 - | ResultEndpoint::Result81,
|
15333 - | ResultEndpoint::Result82,
|
15334 - | ResultEndpoint::Result83,
|
15335 - | ResultEndpoint::Result84,
|
15336 - | ResultEndpoint::Result85,
|
15337 - | ResultEndpoint::Result86,
|
15338 - | ResultEndpoint::Result87,
|
15339 - | ResultEndpoint::Result88,
|
15340 - | ResultEndpoint::Result89,
|
15341 - | ResultEndpoint::Result90,
|
15342 - | ResultEndpoint::Result91,
|
15343 - | ResultEndpoint::Result92,
|
15344 - | ResultEndpoint::Result93,
|
15345 - | ResultEndpoint::Result94,
|
15346 - | ResultEndpoint::Result95,
|
15347 - | ResultEndpoint::Result96,
|
15348 - | ];
|
14149 + | impl crate::config::endpoint::ResolveEndpoint for DefaultResolver {
|
14150 + | fn resolve_endpoint<'a>(&'a self, params: &'a crate::config::endpoint::Params) -> ::aws_smithy_runtime_api::client::endpoint::EndpointFuture<'a> {
|
14151 + | // Check single-entry cache (lock-free read via ArcSwap)
|
14152 + | let cached = self.endpoint_cache.load();
|
14153 + | if let Some((cached_params, cached_endpoint)) = cached.as_ref() {
|
14154 + | if cached_params == params {
|
14155 + | return ::aws_smithy_runtime_api::client::endpoint::EndpointFuture::ready(::std::result::Result::Ok(cached_endpoint.clone()));
|
14156 + | }
|
14157 + | }
|
14158 + | drop(cached);
|
14159 + | let result = self.resolve_endpoint(params);
|
14160 + | if let ::std::result::Result::Ok(ref endpoint) = result {
|
14161 + | self.endpoint_cache.store(::std::sync::Arc::new(Some((params.clone(), endpoint.clone()))));
|
14162 + | }
|
14163 + | ::aws_smithy_runtime_api::client::endpoint::EndpointFuture::ready(result)
|
14164 + | }
|
14165 + | }
|
15349 14166 | const NODES: [crate::endpoint_lib::bdd_interpreter::BddNode; 521] = [
|
15350 14167 | crate::endpoint_lib::bdd_interpreter::BddNode {
|
15351 14168 | condition_index: -1,
|
15352 14169 | high_ref: 1,
|
15353 14170 | low_ref: -1,
|
15354 14171 | },
|
15355 14172 | crate::endpoint_lib::bdd_interpreter::BddNode {
|
15356 14173 | condition_index: 5,
|
15357 14174 | high_ref: 100000002,
|
15358 14175 | low_ref: 100000004,
|