{
  "schema": 1,
  "sqlstate": "01007",
  "condition_name": "privilege_not_granted",
  "sources": [
    {
      "id": "src.errcodes.18.6",
      "kind": "upstream_source",
      "source_role": "condition_definition",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/utils/errcodes.txt",
      "sha256": "6e8de346643ba84aa3c9c6a73360acfc7b2dfb89162c06c08ce9bf5bcd5bbcba",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/utils/errcodes.txt",
      "lines": "88"
    },
    {
      "id": "src.aclchk.18.6",
      "kind": "upstream_source",
      "source_role": "acl_warning_paths",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/catalog/aclchk.c",
      "sha256": "9700258318959b47c42edb423418fb511dd3a008023e732f601eecf4c80868f8",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/catalog/aclchk.c#L318-L382",
      "lines": "318-382"
    },
    {
      "id": "src.calls.REL_18_6",
      "kind": "local_artifact",
      "source_role": "source_call_scan",
      "sha256": "9ee8a0e81d8f0825c5c1ae45583439859a26e602bdd4ce2f2a62aa278867ccbf"
    }
  ],
  "claims": [
    {
      "id": "identity",
      "statement": "01007 is privilege_not_granted in SQLSTATE Class 01.",
      "sources": [
        "src.errcodes.18.6"
      ],
      "method": "Read the fixed errcodes definition row and macro."
    },
    {
      "id": "source-path",
      "statement": "A fixed PostgreSQL 18.6 source path uses this SQLSTATE at the stated severity and operation.",
      "sources": [
        "src.aclchk.18.6"
      ],
      "method": "Read the fixed source context around the SQLSTATE macro.",
      "limits": "This confirms a source path and current wording; it is not a runtime observation of every installation."
    },
    {
      "id": "acl-effective-grantor",
      "statement": "The fixed aclchk.c function computes this_privileges as the requested privilege set intersected with the effective grantor's available grant options. The GRANT none branch warns when that mask is zero; the partial branch warns when !all_privs and the mask differs from the request. This warning branch does not inspect the grantee's old ACL; the resulting ACL must be checked separately.",
      "sources": [
        "src.aclchk.18.6"
      ],
      "method": "Read restrict_and_check_grant() and its fixed {op} report branches around aclchk.c lines 318-382.",
      "limits": "This is a source-level warning condition; it does not claim a natural runtime or prescribe a universal role/ACL setup."
    }
  ],
  "messages": [
    {
      "id": "acl-grant-column-none",
      "severity": "WARNING",
      "primary_template": "no privileges were granted for column \"%s\" of relation \"%s\"",
      "sources": [
        "src.aclchk.18.6"
      ],
      "path": "src.aclchk.18.6",
      "sqlstate": "01007",
      "source_ids": [
        "src.aclchk.18.6"
      ]
    },
    {
      "id": "acl-grant-object-none",
      "severity": "WARNING",
      "primary_template": "no privileges were granted for \"%s\"",
      "sources": [
        "src.aclchk.18.6"
      ],
      "path": "src.aclchk.18.6",
      "sqlstate": "01007",
      "source_ids": [
        "src.aclchk.18.6"
      ]
    },
    {
      "id": "acl-grant-column-partial",
      "severity": "WARNING",
      "primary_template": "not all privileges were granted for column \"%s\" of relation \"%s\"",
      "sources": [
        "src.aclchk.18.6"
      ],
      "path": "src.aclchk.18.6",
      "sqlstate": "01007",
      "source_ids": [
        "src.aclchk.18.6"
      ]
    },
    {
      "id": "acl-grant-object-partial",
      "severity": "WARNING",
      "primary_template": "not all privileges were granted for \"%s\"",
      "sources": [
        "src.aclchk.18.6"
      ],
      "path": "src.aclchk.18.6",
      "sqlstate": "01007",
      "source_ids": [
        "src.aclchk.18.6"
      ]
    }
  ],
  "usage_evidence": [
    {
      "scope": "fixed-source-path",
      "status": "source_path_confirmed",
      "evidence_ids": [
        "identity",
        "source-path",
        "acl-effective-grantor"
      ]
    },
    {
      "scope": "natural-runtime",
      "status": "unknown",
      "evidence_ids": [
        "source-path"
      ]
    }
  ],
  "runtime": []
}
