Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-azure-storage-queue for 
openSUSE:Factory checked in at 2026-11-02 16:40:18
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-azure-storage-queue (Old)
 and      /work/SRC/openSUSE:Factory/.python-azure-storage-queue.new.1255 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-azure-storage-queue"

Mon Nov  2 16:40:18 2026 rev:35 rq:1394443 version:12.18.1

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/python-azure-storage-queue/python-azure-storage-queue.changes
    2026-10-01 16:49:50.831083383 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-azure-storage-queue.new.1255/python-azure-storage-queue.changes
  2026-11-02 16:41:14.682439757 +0100
@@ -1,0 +2,8 @@
+Mon Nov  2 09:19:23 UTC 2026 - John Paul Adrian Glaubitz 
<[email protected]>
+
+- New upstream release
+  + Version 12.18.1
+  + For detailed information about changes see the
+    CHANGELOG.md file provided with this package
+
+-------------------------------------------------------------------

Old:
----
  azure_storage_queue-12.18.0.tar.gz

New:
----
  azure_storage_queue-12.18.1.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-azure-storage-queue.spec ++++++
--- /var/tmp/diff_new_pack.cp8xCU/_old  2026-11-02 16:41:15.423470804 +0100
+++ /var/tmp/diff_new_pack.cp8xCU/_new  2026-11-02 16:41:15.425470888 +0100
@@ -18,7 +18,7 @@
 
 %{?sle15_python_module_pythons}
 Name:           python-azure-storage-queue
-Version:        12.18.0
+Version:        12.18.1
 Release:        0
 Summary:        Microsoft Azure Storage Queue Client Library for Python
 License:        MIT

++++++ azure_storage_queue-12.18.0.tar.gz -> azure_storage_queue-12.18.1.tar.gz 
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/azure_storage_queue-12.18.0/CHANGELOG.md 
new/azure_storage_queue-12.18.1/CHANGELOG.md
--- old/azure_storage_queue-12.18.0/CHANGELOG.md        2026-09-30 
20:46:34.000000000 +0200
+++ new/azure_storage_queue-12.18.1/CHANGELOG.md        2026-10-29 
21:11:09.233893400 +0100
@@ -1,5 +1,11 @@
 # Release History
 
+## 12.18.1 (2026-10-20)
+
+### Bugs Fixed
+- Fixed UTC conversion of timezone-aware datetimes in `generate_account_sas`, 
`generate_queue_sas`, and `QueueServiceClient.get_user_delegation_key` (sync 
and async). Datetimes without timezone information continue to be treated as 
UTC.
+- Fixed an issue where certain headers were not being properly redacted when 
DEBUG logging was enabled.
+
 ## 12.18.0 (2026-09-30)
 
 This version and all future versions will require Python 3.10+. Python 3.9 is 
no longer supported.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/azure_storage_queue-12.18.0/PKG-INFO 
new/azure_storage_queue-12.18.1/PKG-INFO
--- old/azure_storage_queue-12.18.0/PKG-INFO    2026-09-30 21:12:37.047183300 
+0200
+++ new/azure_storage_queue-12.18.1/PKG-INFO    2026-10-29 21:36:00.077017000 
+0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.4
 Name: azure-storage-queue
-Version: 12.18.0
+Version: 12.18.1
 Summary: Microsoft Corporation Azure Storage Queue Client Library for Python
 Author-email: Microsoft Corporation <[email protected]>
 License-Expression: MIT
@@ -432,6 +432,12 @@
 
 # Release History
 
+## 12.18.1 (2026-10-20)
+
+### Bugs Fixed
+- Fixed UTC conversion of timezone-aware datetimes in `generate_account_sas`, 
`generate_queue_sas`, and `QueueServiceClient.get_user_delegation_key` (sync 
and async). Datetimes without timezone information continue to be treated as 
UTC.
+- Fixed an issue where certain headers were not being properly redacted when 
DEBUG logging was enabled.
+
 ## 12.18.0 (2026-09-30)
 
 This version and all future versions will require Python 3.10+. Python 3.9 is 
no longer supported.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure_storage_queue-12.18.0/azure/storage/queue/_shared/parser.py 
new/azure_storage_queue-12.18.1/azure/storage/queue/_shared/parser.py
--- old/azure_storage_queue-12.18.0/azure/storage/queue/_shared/parser.py       
2026-09-30 20:46:34.000000000 +0200
+++ new/azure_storage_queue-12.18.1/azure/storage/queue/_shared/parser.py       
2026-10-29 21:11:09.238058800 +0100
@@ -4,8 +4,8 @@
 # license information.
 # --------------------------------------------------------------------------
 
-from datetime import datetime, timezone
-from typing import Optional
+from datetime import date, datetime, timezone
+from typing import Optional, Union
 
 EPOCH_AS_FILETIME = 116444736000000000  # January 1, 1970 as MS filetime
 HUNDREDS_OF_NANOSECONDS = 10000000
@@ -19,7 +19,9 @@
 DEVSTORE_ACCOUNT_KEY = 
"Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw=="
 
 
-def _to_utc_datetime(value: datetime) -> str:
+def _to_utc_datetime(value: Union[date, datetime]) -> str:
+    if isinstance(value, datetime) and value.utcoffset() is not None:
+        value = value.astimezone(timezone.utc)
     return value.strftime("%Y-%m-%dT%H:%M:%SZ")
 
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure_storage_queue-12.18.0/azure/storage/queue/_shared/policies.py 
new/azure_storage_queue-12.18.1/azure/storage/queue/_shared/policies.py
--- old/azure_storage_queue-12.18.0/azure/storage/queue/_shared/policies.py     
2026-09-30 20:46:34.000000000 +0200
+++ new/azure_storage_queue-12.18.1/azure/storage/queue/_shared/policies.py     
2026-10-29 21:11:09.238058800 +0100
@@ -16,7 +16,9 @@
     parse_qsl,
     urlencode,
     urlparse,
+    urlsplit,
     urlunparse,
+    urlunsplit,
 )
 from wsgiref.handlers import format_date_time
 
@@ -61,6 +63,38 @@
 SM_HEADER = "x-ms-structured-body"
 SM_HEADER_V1_CRC64 = "XSM/1.0; properties=crc64"
 SM_LENGTH_HEADER = "x-ms-structured-content-length"
+_LOG_REDACTED = "*****"
+_LOG_REDACTED_HEADERS = frozenset(
+    {
+        "authorization",
+        "x-ms-authorization-auxiliary",
+        "x-ms-copy-source-authorization",
+        "x-ms-encryption-key",
+        "x-ms-source-encryption-key",
+    }
+)
+_LOG_SAS_URL_HEADERS = frozenset(
+    {
+        "x-ms-copy-source",
+        "x-ms-file-rename-source",
+        "x-ms-rename-source",
+    }
+)
+
+
+def _remove_sas_from_url(value: str) -> str:
+    scheme, netloc, path, query, fragment = urlsplit(value)
+    pairs = parse_qsl(query, keep_blank_values=True)
+    query = urlencode([(k, _LOG_REDACTED if k.lower() == "sig" else v) for k, 
v in pairs])
+    return urlunsplit((scheme, netloc, path, query, fragment))
+
+
+def _redact_header_for_log(name: str, value: Any) -> Any:
+    if name.lower() in _LOG_REDACTED_HEADERS:
+        return _LOG_REDACTED
+    if name.lower() in _LOG_SAS_URL_HEADERS or "sig=" in str(value).lower():
+        return _remove_sas_from_url(str(value))
+    return value
 
 
 def encode_base64(data: Union[bytes, str]) -> str:
@@ -263,27 +297,7 @@
                 _LOGGER.debug("Request method: %r", http_request.method)
                 _LOGGER.debug("Request headers:")
                 for header, value in http_request.headers.items():
-                    if header.lower() == "authorization":
-                        value = "*****"
-                    elif header.lower() == "x-ms-copy-source" and "sig" in 
value:
-                        # take the url apart and scrub away the signed 
signature
-                        scheme, netloc, path, params, query, fragment = 
urlparse(value)
-                        parsed_qs = dict(parse_qsl(query))
-                        parsed_qs["sig"] = "*****"
-
-                        # the SAS needs to be put back together
-                        value = urlunparse(
-                            (
-                                scheme,
-                                netloc,
-                                path,
-                                params,
-                                urlencode(parsed_qs),
-                                fragment,
-                            )
-                        )
-
-                    _LOGGER.debug("    %r: %r", header, value)
+                    _LOGGER.debug("    %r: %r", header, 
_redact_header_for_log(header, value))
                 _LOGGER.debug("Request body:")
 
                 if logging_body:
@@ -306,7 +320,7 @@
                 _LOGGER.debug("Response status: %r", 
response.http_response.status_code)
                 _LOGGER.debug("Response headers:")
                 for res_header, value in 
response.http_response.headers.items():
-                    _LOGGER.debug("    %r: %r", res_header, value)
+                    _LOGGER.debug("    %r: %r", res_header, 
_redact_header_for_log(res_header, value))
 
                 # We don't want to log binary data if the response is a file.
                 _LOGGER.debug("Response content:")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure_storage_queue-12.18.0/azure/storage/queue/_version.py 
new/azure_storage_queue-12.18.1/azure/storage/queue/_version.py
--- old/azure_storage_queue-12.18.0/azure/storage/queue/_version.py     
2026-09-30 20:46:34.000000000 +0200
+++ new/azure_storage_queue-12.18.1/azure/storage/queue/_version.py     
2026-10-29 21:11:09.238058800 +0100
@@ -6,4 +6,4 @@
 # Changes may cause incorrect behavior and will be lost if the code is 
regenerated.
 # --------------------------------------------------------------------------
 
-VERSION = "12.18.0"
+VERSION = "12.18.1"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure_storage_queue-12.18.0/azure_storage_queue.egg-info/PKG-INFO 
new/azure_storage_queue-12.18.1/azure_storage_queue.egg-info/PKG-INFO
--- old/azure_storage_queue-12.18.0/azure_storage_queue.egg-info/PKG-INFO       
2026-09-30 21:12:36.000000000 +0200
+++ new/azure_storage_queue-12.18.1/azure_storage_queue.egg-info/PKG-INFO       
2026-10-29 21:35:59.977016000 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.4
 Name: azure-storage-queue
-Version: 12.18.0
+Version: 12.18.1
 Summary: Microsoft Corporation Azure Storage Queue Client Library for Python
 Author-email: Microsoft Corporation <[email protected]>
 License-Expression: MIT
@@ -432,6 +432,12 @@
 
 # Release History
 
+## 12.18.1 (2026-10-20)
+
+### Bugs Fixed
+- Fixed UTC conversion of timezone-aware datetimes in `generate_account_sas`, 
`generate_queue_sas`, and `QueueServiceClient.get_user_delegation_key` (sync 
and async). Datetimes without timezone information continue to be treated as 
UTC.
+- Fixed an issue where certain headers were not being properly redacted when 
DEBUG logging was enabled.
+
 ## 12.18.0 (2026-09-30)
 
 This version and all future versions will require Python 3.10+. Python 3.9 is 
no longer supported.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure_storage_queue-12.18.0/azure_storage_queue.egg-info/SOURCES.txt 
new/azure_storage_queue-12.18.1/azure_storage_queue.egg-info/SOURCES.txt
--- old/azure_storage_queue-12.18.0/azure_storage_queue.egg-info/SOURCES.txt    
2026-09-30 21:12:36.000000000 +0200
+++ new/azure_storage_queue-12.18.1/azure_storage_queue.egg-info/SOURCES.txt    
2026-10-29 21:35:59.998525000 +0100
@@ -94,6 +94,7 @@
 tests/test_queue_service_properties_async.py
 tests/test_queue_service_stats.py
 tests/test_queue_service_stats_async.py
+tests/test_sas.py
 tests/settings/__init__.py
 tests/settings/settings_fake.py
 tests/settings/testcase.py
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/azure_storage_queue-12.18.0/tests/test_queue_client.py 
new/azure_storage_queue-12.18.1/tests/test_queue_client.py
--- old/azure_storage_queue-12.18.0/tests/test_queue_client.py  2026-09-30 
20:46:34.000000000 +0200
+++ new/azure_storage_queue-12.18.1/tests/test_queue_client.py  2026-10-29 
21:11:09.240705000 +0100
@@ -12,9 +12,11 @@
 import pytest
 
 from devtools_testutils import recorded_by_proxy
-from devtools_testutils.storage import StorageRecordedTestCase
+from devtools_testutils.storage import LogCaptured, StorageRecordedTestCase
 from settings.testcase import QueuePreparer
 
+from azure.core.pipeline import PipelineContext, PipelineRequest
+from azure.core.pipeline.transport import HttpRequest  # pylint: 
disable=non-abstract-transport-import
 from azure.storage.queue import (
     AccountSasPermissions,
     generate_account_sas,
@@ -28,6 +30,7 @@
     DEVSTORE_ACCOUNT_KEY,
     DEVSTORE_ACCOUNT_NAME,
 )
+from azure.storage.queue._shared.policies import StorageLoggingPolicy
 
 
 # 
------------------------------------------------------------------------------
@@ -806,6 +809,40 @@
         acl = queue_client.get_queue_access_policy()
         assert acl is not None
 
+    def _log_request(self, headers):
+        request = HttpRequest("PUT", 
"https://account.queue.core.windows.net/c/b";, headers=headers)
+        with LogCaptured(self) as log_captured:
+            
StorageLoggingPolicy(logging_enable=True).on_request(PipelineRequest(request, 
PipelineContext(None)))
+            return log_captured.getvalue()
+
+    def test_secret_headers_are_redacted(self):
+        for header in (
+            "Authorization",
+            "x-ms-encryption-key",
+            "x-ms-source-encryption-key",
+            "x-ms-copy-source-authorization",
+        ):
+            log_as_str = self._log_request({header: "value"})
+            assert header in log_as_str
+            assert "value" not in log_as_str
+
+    def test_source_url_sas_is_scrubbed(self):
+        for header in ("x-ms-copy-source", "x-ms-file-rename-source", 
"x-ms-rename-source"):
+            log_as_str = self._log_request({header: 
"https://src.queue.core.windows.net/c/b?sv=2025-01-05&sig=value"})
+            assert "value" not in log_as_str
+            assert "src.queue.core.windows.net" in log_as_str
+
+    def test_diagnostic_headers_remain_visible(self):
+        log_as_str = self._log_request(
+            {
+                "x-ms-encryption-key-sha256": "value",
+                "x-ms-encryption-algorithm": "AES256",
+                "x-ms-client-request-id": "req-id-123",
+            }
+        )
+        for value in ("value", "AES256", "req-id-123"):
+            assert log_as_str.count(value) == 1
+
 
 # 
------------------------------------------------------------------------------
 if __name__ == "__main__":
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/azure_storage_queue-12.18.0/tests/test_sas.py 
new/azure_storage_queue-12.18.1/tests/test_sas.py
--- old/azure_storage_queue-12.18.0/tests/test_sas.py   1970-01-01 
01:00:00.000000000 +0100
+++ new/azure_storage_queue-12.18.1/tests/test_sas.py   2026-10-29 
21:11:09.240893600 +0100
@@ -0,0 +1,43 @@
+# -------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for
+# license information.
+# --------------------------------------------------------------------------
+
+from base64 import b64encode
+from datetime import date, datetime, timedelta, timezone
+from urllib.parse import parse_qs
+
+import pytest
+
+from azure.storage.queue import generate_queue_sas
+
+
[email protected](
+    "expiry, expected",
+    [
+        (datetime(2026, 10, 13, 12, 34, 56), "2026-10-13T12:34:56Z"),
+        (datetime(2026, 10, 13, 12, 34, 56, tzinfo=timezone.utc), 
"2026-10-13T12:34:56Z"),
+        (
+            datetime(2026, 10, 13, 12, 34, 56, 
tzinfo=timezone(timedelta(hours=5, minutes=30))),
+            "2026-10-13T07:04:56Z",
+        ),
+        (
+            datetime(2026, 10, 13, 12, 34, 56, 
tzinfo=timezone(timedelta(hours=-7))),
+            "2026-10-13T19:34:56Z",
+        ),
+        (datetime(2026, 1, 1, 1, tzinfo=timezone(timedelta(hours=2))), 
"2025-12-31T23:00:00Z"),
+        (datetime(2026, 12, 31, 23, tzinfo=timezone(timedelta(hours=-2))), 
"2027-01-01T01:00:00Z"),
+        (datetime(2026, 10, 13, 12, 34, 56, 123456, tzinfo=timezone.utc), 
"2026-10-13T12:34:56Z"),
+        (date(2026, 10, 13), "2026-10-13T00:00:00Z"),
+    ],
+)
+def test_generate_queue_sas_expiry(expiry, expected):
+    sas = generate_queue_sas(
+        account_name="account",
+        queue_name="queue",
+        account_key=b64encode(b"fake-account-key").decode("ascii"),
+        permission="r",
+        expiry=expiry,
+    )
+    assert parse_qs(sas)["se"] == [expected]

Reply via email to