Skip to content
This repository has been archived by the owner on Nov 1, 2023. It is now read-only.

Commit

Permalink
set the start too
Browse files Browse the repository at this point in the history
  • Loading branch information
chkeita committed Jul 1, 2022
1 parent 7d1b9a2 commit b27ff6e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/api-service/__app__/onefuzzlib/azure/containers.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ def add_container_sas_url(
if "sig" in query:
return container_url
else:
start, expiry = sas_time_window(duration)
account_name = parsed.netloc.split(".")[0]
account_key = get_storage_account_name_key_by_name(account_name)
sas_token = generate_container_sas(
Expand All @@ -128,7 +129,8 @@ def add_container_sas_url(
permission=ContainerSasPermissions(
read=True, write=True, delete=True, list=True
),
expiry=datetime.datetime.utcnow() + duration,
expiry=expiry,
start=start,
)
return f"{container_url}?{sas_token}"

Expand Down

0 comments on commit b27ff6e

Please sign in to comment.