{
  "schema_version": "1.1.0",
  "record_type": "citation-evidence-pack",
  "pack_id": "azure-sas-token-debugger",
  "title": "Azure SAS single-upload and block-upload examples",
  "description": "Compare create-only and write permissions for single uploads and block uploads using request version 2023-11-03.",
  "scope": "These examples check permissions for a new blob with request version 2023-11-03. The placeholder signatures grant no access. From request version 2026-04-06, Put Block and Put Block List can also create a new block blob with c permission; overwrites still require w.",
  "canonical_url": "https://encrypt-online.com/evidence/azure-sas-token-debugger.json",
  "tool": {
    "id": "azure-sas-token-debugger",
    "name": "Azure Storage SAS Debugger",
    "path": "/tools/azure-sas-token-debugger",
    "canonical_url": "https://encrypt-online.com/tools/azure-sas-token-debugger"
  },
  "implementation": {
    "version": "source-sha256:114f009c87415384",
    "aggregate_sha256": "114f009c87415384654ab0047243966a0da5b2759d18f5892c9da8f7a88f542b",
    "sources": [
      {
        "path": "lib/azure-sas-core.mjs",
        "sha256": "625dc1079a3aaa48387f5fcb4a86c08a141aad2ca881fd416fe0a2a43ce69e85"
      },
      {
        "path": "data/azure-citation-evidence.mjs",
        "sha256": "f63d508caf1daf4dadd40500821ad560ca8a7c221d5af274bbf1c644fd5455e4"
      },
      {
        "path": "scripts/azure-citation-evidence-adapters.mjs",
        "sha256": "71636408282eba9f886cfe8ad63bccf0e8db7c46357f10e57a35cc463abe8c71"
      }
    ]
  },
  "verification": {
    "last_verified": "2026-10-20",
    "command": "npm run check:citation-evidence",
    "environments": [
      "Node.js release check with Web Crypto",
      "Chromium desktop 1440x900 evidence presentation"
    ]
  },
  "standards": [
    {
      "name": "Microsoft Put Blob reference",
      "section": "Authorization: creating a new block blob with c or w",
      "url": "https://learn.microsoft.com/en-us/rest/api/storageservices/put-blob#authorization"
    },
    {
      "name": "Microsoft Put Block reference",
      "section": "Authorization: create permission from request version 2026-04-06",
      "url": "https://learn.microsoft.com/en-us/rest/api/storageservices/put-block#authorization"
    },
    {
      "name": "Microsoft Put Block List reference",
      "section": "Authorization: create and overwrite permissions",
      "url": "https://learn.microsoft.com/en-us/rest/api/storageservices/put-block-list#authorization"
    },
    {
      "name": "Azure Storage versioning",
      "section": "SAS signed version and REST protocol version",
      "url": "https://learn.microsoft.com/en-us/rest/api/storageservices/versioning-for-the-azure-storage-services#authorize-requests-by-using-a-shared-access-signature"
    }
  ],
  "cases": [
    {
      "case_id": "AZURE-SAS-SINGLE-CREATE-001",
      "classification": "valid",
      "symptom": "A create-only SAS has the permission needed for a single Put Blob that creates a new block blob.",
      "safe_input": {
        "input": "https://storage.example.invalid/uploads/example.txt?sv=2023-11-03&sr=b&sp=c&st=2026-10-20T11%3A00%3A00Z&se=2026-10-20T13%3A00%3A00Z&spr=https&sig=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA%3D",
        "operation": "create",
        "requestVersion": "2023-11-03",
        "blobState": "new",
        "now": 1792497600000
      },
      "expected_output": {
        "sas_type": "service",
        "permissions": "c",
        "operation": "create",
        "operation_status": "success",
        "blocking_findings": [],
        "signature_checked": false
      },
      "failure_code": null,
      "expected_outcome": "The c permission covers creating a new block blob in one Put Blob. A live upload still needs a valid SAS signature and Azure authorization.",
      "fixture_sha256": "d24f5dd22f6efa26a626cfcdfa7882d80962bb2d53a123c208fe5e21f5cd246b",
      "example": {
        "title": "Create-only permission for a single upload",
        "steps": [
          "Paste the SAS URL into the debugger.",
          "Choose Create a blob (single upload).",
          "Under Request details and reference time, set the reference time to 2026-10-20 12:00:00 UTC.",
          "Select Inspect SAS and open Selected operation to see the permission check."
        ],
        "values": [
          {
            "label": "SAS URL",
            "value": "https://storage.example.invalid/uploads/example.txt?sv=2023-11-03&sr=b&sp=c&st=2026-10-20T11%3A00%3A00Z&se=2026-10-20T13%3A00%3A00Z&spr=https&sig=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA%3D"
          },
          {
            "label": "Request version",
            "value": "2023-11-03"
          },
          {
            "label": "Permission letters",
            "value": "c"
          },
          {
            "label": "Operation permission check",
            "value": "success"
          }
        ]
      }
    },
    {
      "case_id": "AZURE-SAS-BLOCK-CREATE-ONLY-002",
      "classification": "mismatch",
      "symptom": "The same create-only SAS lacks w for Put Block and Put Block List with request version 2023-11-03.",
      "safe_input": {
        "input": "https://storage.example.invalid/uploads/example.txt?sv=2023-11-03&sr=b&sp=c&st=2026-10-20T11%3A00%3A00Z&se=2026-10-20T13%3A00%3A00Z&spr=https&sig=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA%3D",
        "operation": "blocks",
        "requestVersion": "2023-11-03",
        "blobState": "new",
        "now": 1792497600000
      },
      "expected_output": {
        "sas_type": "service",
        "permissions": "c",
        "operation": "blocks",
        "operation_status": "error",
        "blocking_findings": [
          "operation"
        ],
        "signature_checked": false
      },
      "failure_code": "SAS_OPERATION_MISMATCH",
      "expected_outcome": "Request version 2023-11-03 needs w to stage and commit blocks. Generate a new SAS with write permission for that upload.",
      "fixture_sha256": "26fc0a72c3bc20ba331d30e321fb0144ca069e84106473e51ffdd6f5867f638c",
      "example": {
        "title": "Create-only permission fails for older block requests",
        "steps": [
          "Paste the SAS URL and choose Upload blocks (SDK or large file).",
          "Under Request details and reference time, enter block request version 2023-11-03 and choose Create a new blob.",
          "Set the reference time to 2026-10-20 12:00:00 UTC.",
          "Select Inspect SAS. The result identifies the missing w permission."
        ],
        "values": [
          {
            "label": "SAS URL",
            "value": "https://storage.example.invalid/uploads/example.txt?sv=2023-11-03&sr=b&sp=c&st=2026-10-20T11%3A00%3A00Z&se=2026-10-20T13%3A00%3A00Z&spr=https&sig=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA%3D"
          },
          {
            "label": "Request version",
            "value": "2023-11-03"
          },
          {
            "label": "Permission letters",
            "value": "c"
          },
          {
            "label": "Operation permission check",
            "value": "error"
          }
        ]
      }
    },
    {
      "case_id": "AZURE-SAS-BLOCK-WRITE-003",
      "classification": "valid",
      "symptom": "A SAS containing c and w covers the block-upload permission requirement for request version 2023-11-03.",
      "safe_input": {
        "input": "https://storage.example.invalid/uploads/example.txt?sv=2023-11-03&sr=b&sp=cw&st=2026-10-20T11%3A00%3A00Z&se=2026-10-20T13%3A00%3A00Z&spr=https&sig=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA%3D",
        "operation": "blocks",
        "requestVersion": "2023-11-03",
        "blobState": "new",
        "now": 1792497600000
      },
      "expected_output": {
        "sas_type": "service",
        "permissions": "cw",
        "operation": "blocks",
        "operation_status": "success",
        "blocking_findings": [],
        "signature_checked": false
      },
      "failure_code": null,
      "expected_outcome": "The w permission covers staging and committing blocks. Generate a replacement SAS for real use; editing sp in an existing signed URL invalidates its signature.",
      "fixture_sha256": "5c9e51f728f9058a5c98f478c18589ac4c52bfd182bd63eba2f58d8faf5b4d4f",
      "example": {
        "title": "Write permission covers the block upload",
        "steps": [
          "Paste this separate example SAS URL and choose Upload blocks (SDK or large file).",
          "Under Request details and reference time, enter block request version 2023-11-03 and choose Create a new blob.",
          "Set the reference time to 2026-10-20 12:00:00 UTC.",
          "Select Inspect SAS and open Selected operation to see the permission check."
        ],
        "values": [
          {
            "label": "SAS URL",
            "value": "https://storage.example.invalid/uploads/example.txt?sv=2023-11-03&sr=b&sp=cw&st=2026-10-20T11%3A00%3A00Z&se=2026-10-20T13%3A00%3A00Z&spr=https&sig=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA%3D"
          },
          {
            "label": "Request version",
            "value": "2023-11-03"
          },
          {
            "label": "Permission letters",
            "value": "cw"
          },
          {
            "label": "Operation permission check",
            "value": "success"
          }
        ]
      }
    }
  ]
}
