create_ip_set
¶
create_ip_set(
detector_id: DetectorId,
*,
config_overrides: Optional[GuardDutyClientConfig] = None,
name: Optional[Name] = None,
format: Optional[IpSetFormat] = None,
location: Optional[Location] = None,
activate: Optional[Boolean] = None,
client_token: Optional[ClientToken] = None,
tags: Optional[TagMap] = None,
expected_bucket_owner: Optional[AccountId] = None,
) -> CreateIPSetResponse
Creates a new IPSet, which is called a trusted IP list in the console user interface. An IPSet is a list of IP addresses that are trusted for secure communication with Amazon Web Services infrastructure and applications. GuardDuty doesn't generate findings for IP addresses that are included in IPSets. Only users from the administrator account can use this operation.
Parameters:
-
detector_id(DetectorId) –The unique ID of the detector of the GuardDuty account for which you want to create an IPSet.
To find the
detectorIdin the current Region, see the Settings page in the GuardDuty console, or run the ListDetectors API. -
name(Optional[Name], default:None) –The user-friendly name to identify the IPSet.
Allowed characters are alphanumeric, whitespace, dash (-), and underscores (_).
-
format(Optional[IpSetFormat], default:None) –The format of the file that contains the IPSet.
-
location(Optional[Location], default:None) –The URI of the file that contains the IPSet.
-
activate(Optional[Boolean], default:None) –A Boolean value that indicates whether GuardDuty is to start using the uploaded IPSet.
-
client_token(Optional[ClientToken], default:None) –The idempotency token for the create request.
-
tags(Optional[TagMap], default:None) –The tags to be added to a new IP set resource.
-
expected_bucket_owner(Optional[AccountId], default:None) –The Amazon Web Services account ID that owns the Amazon S3 bucket specified in the location parameter.
Raises:
-
AccessDeniedException–An access denied exception object.
-
BadRequestException–A bad request exception object.
-
InternalServerErrorException–An internal server error exception object.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_guardduty/_services/guard_duty.py
929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 | |