
    C                         S r SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSK	J
r
  SSKJr  SS	KJr  SS
KJr  SS	KJr   " S S\R$                  5      rg)zDCommand to delete a Cloud CDN Signed URL key from a backend service.    )absolute_import)division)unicode_literals)base_classes)poller)waiter)base)flags)signed_url_flagsc                   4    \ rS rSrSr\S 5       rS rS rSr	g)DeleteSignedUrlKey   a  Delete Cloud CDN Signed URL key from a backend service.

*{command}* is used to delete an existing Cloud CDN Signed URL key from a
backend service.

Cloud CDN Signed URLs give you a way to serve responses from the
globally distributed CDN cache, even if the request needs to be
authorized.

Signed URLs are a mechanism to temporarily give a client access to a
private resource without requiring additional authorization. To achieve
this, the full request URL that should be allowed is hashed
and cryptographically signed. By using the signed URL you give it, that
one request will be considered authorized to receive the requested
content.

Generally, a signed URL can be used by anyone who has it. However, it
is usually only intended to be used by the client that was directly
given the URL. To mitigate this, they expire at a time chosen by the
issuer. To minimize the risk of a signed URL being shared, it is recommended
that the signed URL be set to expire as soon as possible.

A 128-bit secret key is used for signing the URLs.
c                 l    [         R                  R                  U 5        [        R                  " U SS9  g)z"Set up arguments for this command.T)requiredN)r
   GLOBAL_BACKEND_SERVICE_ARGAddArgumentr   AddCdnSignedUrlKeyName)parsers    =lib/surface/compute/backend_services/delete_signed_url_key.pyArgsDeleteSignedUrlKey.Args8   s(     
$$008++FTB    c                    [         R                  " U R                  5       5      nUR                  R                  nUR                  R
                  nUR                  n[        R                  R                  UUR                  [        R                  " UR                  5      S9nUR                  UR                  UR                  5       UR                   S9nUR#                  U5      nUR                  R%                  UR&                  SS9n	[(        R*                  " U5      n
[,        R.                  " XSR1                  UR                  5       5      5      $ )zDIssues the request to delete Signed URL key from the backend bucket.scope_lister)projectbackendServicekeyNamezcompute.globalOperations)
collectionz,Deleting Cloud CDN Signed URL key from [{0}])r   ComputeApiHolderReleaseTrackclientapitools_clientmessagesbackendServicesr
   r   ResolveAsResource	resourcescompute_flagsGetDefaultScopeLister/ComputeBackendServicesDeleteSignedUrlKeyRequestr   Namekey_namer   ParseselfLinkr   Pollerr   WaitForformat)selfargsholder
api_clientr$   servicebackend_service_refrequest	operationoperation_refoperation_pollers              r   RunDeleteSignedUrlKey.Run>   s-   **4+<+<+>?F..J}}%%H((G::LL"88G M I FF#++*//1 G G
 **73I$$**'A + CM }}W->>*HOO1668:; ;r   c                    [         R                  R                  UU R                  [        R
                  " U R                  5      S9nU R                  R                  UR                  5       UR                  U R                  S9nU/$ )zACreates and returns a BackendServices.DeleteSignedUrlKey request.r   )r   r   r   )r
   r   r&   r'   r(   r)   compute_clientr$   r*   r+   r,   r   )r2   r3   r7   r8   s       r   CreateRequests!DeleteSignedUrlKey.CreateRequestsW   s~    ::LL"889L9LM M O
 mmKK*//1 L G 9r    N)
__name__
__module____qualname____firstlineno____doc__staticmethodr   r<   r@   __static_attributes__rB   r   r   r   r      s'    2 C C
;2r   r   N)rG   
__future__r   r   r   googlecloudsdk.api_lib.computer   )googlecloudsdk.api_lib.compute.operationsr   googlecloudsdk.api_lib.utilr   googlecloudsdk.callioper	   "googlecloudsdk.command_lib.computer
   r(   r   3googlecloudsdk.command_lib.compute.backend_servicesUpdateCommandr   rB   r   r   <module>rR      s=    K &  ' 7 < . ( E ? ED++ Dr   