[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M79N1DAJ6J29MQH2JYX9ZBPR":3,"skill-same:01M79N1DAJ6J29MQH2JYX9ZBPR":43},{"skillNo":4,"name":5,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":20,"frontMatter":21,"refName":22,"commitSha":23,"skillDirectory":24,"forksCount":13,"repositoryHtmlUrl":25,"repositoryHomepageUrl":6,"ownerHtmlUrl":26,"ownerBlogUrl":6,"ownerDescription":27,"updatedAt":28,"install":29,"resources":42},"01M79N1DAJ6J29MQH2JYX9ZBPR","authorization-testing-automation-cheat-sheet",null,"JunMystery\u002FAgent-Guidance","JunMystery","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F161468934?v=4","01M79MTMV8F0BY8NK1A92RA8A0","Jun","01M79MTMWCFBKPHN5B25E6V20B",0,"MIT","https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance\u002Fblob\u002Fmain\u002Fskills\u002Fauthorization-testing-automation-cheat-sheet\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"# Authorization Testing Automation Cheat Sheet\n\n## Introduction\n\n**When you are implementing protection measures for an application, one of the most important parts of the process is defining and implementing the application's authorizations.** Despite all of the checks and security audits conducted during the creation phase, most of the problems with authorizations occur because features are added\u002Fmodified in updated releases without determining their effect on the application's authorizations (usually because of cost or time issue reasons).\n\nTo deal with this problem, we recommend that developers automate the evaluation of the authorizations and perform a test when a new release is created. This ensures that the team knows if changes to the application will conflict with an authorization's definition and\u002For implementation.\n\n## Context\n\nAn authorization usually contains two elements (also named dimensions): The **Feature** and the **Logical Role** that accesses it. Sometimes a third dimension named **Data** is added in order to define access that includes a filtering at business data level.\n\nGenerally, the two dimensions of each authorization should be listed in a spreadsheet that is called an **authorization matrix**. When authorizations are tested, the logical roles are sometimes called a **Point Of View**.\n\n## Objective\n\nThis cheat sheet is designed to help you generate your own approaches to automating authorization tests in an authorization matrix. Since developers will need to design their own approach to automating authorization tests, **this cheat sheet will show a possible approach to automating authorization tests for one possible implementation of an application that exposes REST Services.**\n\n## Proposition\n\n### Preparing to automate the authorization matrix\n\nBefore we start to automate a test of the authorization matrix, we will need to do the following:\n\n1. **Formalize the authorization matrix in a pivot format file, which will allow you to:**\n    1. Easily process the matrix by a program.\n    2. Allow a human to read and update when you need to follow up on the authorization combinations.\n    3. Set up a hierarchy of the authorizations, which will allow you to easily create different combinations.\n    4. Create the maximum possible of independence from the technology and design used to implement the applications.\n\n2. **Create a set of integration tests that fully use the authorization matrix pivot file as an input source, which will allow you to evaluate the different combinations with the following advantages:**\n    1. The minimum possible of maintenance when the authorization matrix pivot file is updated.\n    2. A clear indication, in case of failed test, of the source authorization combination that does not respect the authorization matrix.\n\n### Create the authorization matrix pivot file\n\n**In this example, we use an XML format to formalize the authorization matrix.**\n\nThis XML structure has three main sections (or nodes):\n\n- Node **roles**: Describes the possible logical roles used in the system, provides a list of the roles, and explains the different roles (authorization level).\n- Node **services**: Provides a list of the available services exposed by the system, provides a description of those services, and defines the associated logical role(s) that can call them.\n- Node **services-testing**: Provides a test payload for each service if the service uses input data other than the one coming from URL or path.\n\n**This sample demonstrates how an authorization could be defined with XML**:\n\n> Placeholders (values between {}) are used to mark location where test value must be placed by the integration tests if needed\n\n``` xml\n  \u003C?xml version=\"1.0\" encoding=\"UTF-8\"?>\n  \u003C!--\n      This file materializes the authorization matrix for the different\n      services exposed by the system:\n\n      The tests will use this as a input source for the different test cases by:\n      1) Defining legitimate access and the correct implementation\n      2) Identifying illegitimate access (authorization definition issue\n      on service implementation)\n\n      The \"name\" attribute is used to uniquely identify a SERVICE or a ROLE.\n  -->\n  \u003Cauthorization-matrix>\n\n      \u003C!-- Describe the possible logical roles used in the system, is used here to\n      provide a list+explanation\n      of the different roles (authorization level) -->\n      \u003Croles>\n          \u003Crole name=\"ANONYMOUS\"\n          description=\"Indicate that no authorization is needed\"\u002F>\n          \u003Crole name=\"BASIC\"\n          description=\"Role affecting a standard user (lowest access right just above anonymous)\"\u002F>\n          \u003Crole name=\"ADMIN\"\n          description=\"Role affecting an administrator user (highest access right)\"\u002F>\n      \u003C\u002Froles>\n\n      \u003C!-- List and describe the available services exposed by the system and the associated\n      logical role(s) that can call them -->\n      \u003Cservices>\n          \u003Cservice name=\"ReadSingleMessage\" uri=\"\u002F{messageId}\" http-method=\"GET\"\n          http-response-code-for-access-allowed=\"200\" http-response-code-for-access-denied=\"403\">\n              \u003Crole name=\"ANONYMOUS\"\u002F>\n              \u003Crole name=\"BASIC\"\u002F>\n              \u003Crole name=\"ADMIN\"\u002F>\n          \u003C\u002Fservice>\n          \u003Cservice name=\"ReadAllMessages\" uri=\"\u002F\" http-method=\"GET\"\n          http-response-code-for-access-allowed=\"200\" http-response-code-for-access-denied=\"403\">\n              \u003Crole name=\"ANONYMOUS\"\u002F>\n              \u003Crole name=\"BASIC\"\u002F>\n              \u003Crole name=\"ADMIN\"\u002F>\n          \u003C\u002Fservice>\n          \u003Cservice name=\"CreateMessage\" uri=\"\u002F\" http-method=\"PUT\"\n          http-response-code-for-access-allowed=\"200\" http-response-code-for-access-denied=\"403\">\n              \u003Crole name=\"BASIC\"\u002F>\n              \u003Crole name=\"ADMIN\"\u002F>\n          \u003C\u002Fservice>\n          \u003Cservice name=\"DeleteMessage\" uri=\"\u002F{messageId}\" http-method=\"DELETE\"\n          http-response-code-for-access-allowed=\"200\" http-response-code-for-access-denied=\"403\">\n              \u003Crole name=\"ADMIN\"\u002F>\n          \u003C\u002Fservice>\n      \u003C\u002Fservices>\n\n      \u003C!-- Provide a test payload for each service if needed -->\n      \u003Cservices-testing>\n          \u003Cservice name=\"ReadSingleMessage\">\n              \u003Cpayload\u002F>\n          \u003C\u002Fservice>\n          \u003Cservice name=\"ReadAllMessages\">\n              \u003Cpayload\u002F>\n          \u003C\u002Fservice>\n          \u003Cservice name=\"CreateMessage\">\n              \u003Cpayload content-type=\"application\u002Fjson\">\n                  {\"content\":\"test\"}\n              \u003C\u002Fpayload>\n          \u003C\u002Fservice>\n          \u003Cservice name=\"DeleteMessage\">\n              \u003Cpayload\u002F>\n          \u003C\u002Fservice>\n      \u003C\u002Fservices-testing>\n\n  \u003C\u002Fauthorization-matrix>\n```\n\n### Implementing an integration test\n\n**To create an integration test, you should use a maximum of factorized code and one test case by Point Of View (POV) so the verifications can be profiled by access level (logical role). This will facilitate the rendering\u002Fidentification of the errors.**\n\nIn this integration test, we have implemented parsing, object mapping and access to the authorization matrix by marshalling XML into a Java object and unmarshalling the object back into XML These features are used to implement the tests (JAXB here) and limit the code to the developer in charge of performing the tests.\n\n**Here is a sample implementation of an integration test case class:**\n\n``` java\n  import org.owasp.pocauthztesting.enumeration.SecurityRole;\n  import org.owasp.pocauthztesting.service.AuthService;\n  import org.owasp.pocauthztesting.vo.AuthorizationMatrix;\n  import org.apache.http.client.methods.CloseableHttpResponse;\n  import org.apache.http.client.methods.HttpDelete;\n  import org.apache.http.client.methods.HttpGet;\n  import org.apache.http.client.methods.HttpPut;\n  import org.apache.http.client.methods.HttpRequestBase;\n  import org.apache.http.entity.StringEntity;\n  import org.apache.http.impl.client.CloseableHttpClient;\n  import org.apache.http.impl.client.HttpClients;\n  import org.junit.Assert;\n  import org.junit.BeforeClass;\n  import org.junit.Test;\n  import org.xml.sax.InputSource;\n  import javax.xml.bind.JAXBContext;\n  import javax.xml.parsers.SAXParserFactory;\n  import javax.xml.transform.Source;\n  import javax.xml.transform.sax.SAXSource;\n  import java.io.File;\n  import java.io.FileInputStream;\n  import java.util.ArrayList;\n  import java.util.List;\n  import java.util.Optional;\n\n  \u002F**\n   * Integration test cases validate the correct implementation of the authorization matrix.\n   * They create a test case by logical role that will test access on all services exposed by the system.\n   * This implementation focuses on readability\n   *\u002F\n  public class AuthorizationMatrixIT {\n\n      \u002F**\n       * Object representation of the authorization matrix\n       *\u002F\n      private static AuthorizationMatrix AUTHZ_MATRIX;\n\n      private static final String BASE_URL = \"http:\u002F\u002Flocalhost:8080\";\n\n\n      \u002F**\n       * Load the authorization matrix in objects tree\n       *\n       * @throws Exception If any error occurs\n       *\u002F\n      @BeforeClass\n      public static void globalInit() throws Exception {\n          try (FileInputStream fis = new FileInputStream(new File(\"authorization-matrix.xml\"))) {\n              SAXParserFactory spf = SAXParserFactory.newInstance();\n              spf.setFeature(\"http:\u002F\u002Fxml.org\u002Fsax\u002Ffeatures\u002Fexternal-general-entities\", false);\n              spf.setFeature(\"http:\u002F\u002Fxml.org\u002Fsax\u002Ffeatures\u002Fexternal-parameter-entities\", false);\n              spf.setFeature(\"http:\u002F\u002Fapache.org\u002Fxml\u002Ffeatures\u002Fnonvalidating\u002Fload-external-dtd\", false);\n              Source xmlSource = new SAXSource(spf.newSAXParser().getXMLReader(), new InputSource(fis));\n              JAXBContext jc = JAXBContext.newInstance(AuthorizationMatrix.class);\n              AUTHZ_MATRIX = (AuthorizationMatrix) jc.createUnmarshaller().unmarshal(xmlSource);\n          }\n      }\n\n      \u002F**\n       * Test access to the services from a anonymous user.\n       *\n       * @throws Exception\n       *\u002F\n      @Test\n      public void testAccessUsingAnonymousUserPointOfView() throws Exception {\n          \u002F\u002FRun the tests - No access token here\n          List\u003CString> errors = executeTestWithPointOfView(SecurityRole.ANONYMOUS, null);\n          \u002F\u002FVerify the test results\n          Assert.assertEquals(\"Access issues detected using the ANONYMOUS USER point of view:\\n\" + formatErrorsList(errors), 0, errors.size());\n      }\n\n      \u002F**\n       * Test access to the services from a basic user.\n       *\n       * @throws Exception\n       *\u002F\n      @Test\n      public void testAccessUsingBasicUserPointOfView() throws Exception {\n          \u002F\u002FGet access token representing the authorization for the associated point of view\n          String accessToken = generateTestCaseAccessToken(\"basic\", SecurityRole.BASIC);\n          \u002F\u002FRun the tests\n          List\u003CString> errors = executeTestWithPointOfView(SecurityRole.BASIC, accessToken);\n          \u002F\u002FVerify the test results\n          Assert.assertEquals(\"Access issues detected using the BASIC USER point of view:\\n \" + formatErrorsList(errors), 0, errors.size());\n      }\n\n      \u002F**\n       * Test access to the services from a user with administrator access.\n       *\n       * @throws Exception\n       *\u002F\n      @Test\n      public void testAccessUsingAdministratorUserPointOfView() throws Exception {\n          \u002F\u002FGet access token representing the authorization for the associated point of view\n          String accessToken = generateTestCaseAccessToken(\"admin\", SecurityRole.ADMIN);\n          \u002F\u002FRun the tests\n          List\u003CString> errors = executeTestWithPointOfView(SecurityRole.ADMIN, accessToken);\n          \u002F\u002FVerify the test results\n          Assert.assertEquals(\"Access issues detected using the ADMIN USER point of view:\\n\" + formatErrorsList(errors), 0, errors.size());\n      }\n\n      \u002F**\n       * Evaluate the access to all service using the specified point of view (POV).\n       *\n       * @param pointOfView Point of view to use\n       * @param accessToken Access token that is linked to the point of view in terms of authorization.\n       * @return List of errors detected\n       * @throws Exception If any error occurs\n       *\u002F\n      private List\u003CString> executeTestWithPointOfView(SecurityRole pointOfView, String accessToken) throws Exception {\n          List\u003CString> errors = new ArrayList\u003C>();\n          String errorMessageTplForUnexpectedReturnCode = \"The service '%s' when called with POV '%s' return a response code %s that is not the expected one in allowed or denied case.\";\n          String errorMessageTplForIncorrectReturnCode = \"The service '%s' when called with POV '%s' return a response code %s that is not the expected one (%s expected).\";\n          String fatalErrorMessageTpl = \"The service '%s' when called with POV %s meet the error: %s\";\n\n          \u002F\u002FGet the list of services to call\n          List\u003CAuthorizationMatrix.Services.Service> services = AUTHZ_MATRIX.getServices().getService();\n\n          \u002F\u002FGet the list of services test payload to use\n          List\u003CAuthorizationMatrix.ServicesTesting.Service> servicesTestPayload = AUTHZ_MATRIX.getServicesTesting().getService();\n\n          \u002F\u002FCall all services sequentially (no special focus on performance here)\n          services.forEach(service -> {\n              \u002F\u002FGet the service test payload for the current service\n              String payload = null;\n              String payloadContentType = null;\n              Optional\u003CAuthorizationMatrix.ServicesTesting.Service> serviceTesting = servicesTestPayload.stream().filter(srvPld -> srvPld.getName().equals(service.getName())).findFirst();\n              if (serviceTesting.isPresent()) {\n                  payload = serviceTesting.get().getPayload().getValue();\n                  payloadContentType = serviceTesting.get().getPayload().getContentType();\n              }\n              \u002F\u002FCall the service and verify if the response is consistent\n              try {\n                  \u002F\u002FCall the service\n                  int serviceResponseCode = callService(service.getUri(), payload, payloadContentType, service.getHttpMethod(), accessToken);\n                  \u002F\u002FCheck if the role represented by the specified point of view is defined for the current service\n                  Optional\u003CAuthorizationMatrix.Services.Service.Role> role = service.getRole().stream().filter(r -> r.getName().equals(pointOfView.name())).findFirst();\n                  boolean accessIsGrantedInAuthorizationMatrix = role.isPresent();\n                  \u002F\u002FVerify behavior consistency according to the response code returned and the authorization configured in the matrix\n                  if (serviceResponseCode == service.getHttpResponseCodeForAccessAllowed()) {\n                      \u002F\u002FRoles is not in the list of role allowed to access to the service so it's an error\n                      if (!accessIsGrantedInAuthorizationMatrix) {\n                          errors.add(String.format(errorMessageTplForIncorrectReturnCode, service.getName(), pointOfView.name(), serviceResponseCode,\n                           service.getHttpResponseCodeForAccessDenied()));\n                      }\n                  } else if (serviceResponseCode == service.getHttpResponseCodeForAccessDenied()) {\n                      \u002F\u002FRoles is in the list of role allowed to access to the service so it's an error\n                      if (accessIsGrantedInAuthorizationMatrix) {\n                          errors.add(String.format(errorMessageTplForIncorrectReturnCode, service.getName(), pointOfView.name(), serviceResponseCode,\n                           service.getHttpResponseCodeForAccessAllowed()));\n                      }\n                  } else {\n                      errors.add(String.format(errorMessageTplForUnexpectedReturnCode, service.getName(), pointOfView.name(), serviceResponseCode));\n                  }\n              } catch (Exception e) {\n                  errors.add(String.format(fatalErrorMessageTpl, service.getName(), pointOfView.name(), e.getMessage()));\n              }\n\n\n          });\n\n          return errors;\n      }\n\n      \u002F**\n       * Call a service with a specific payload and return the HTTP response code that was received.\n       * This step was delegated in order to made the test cases more easy to maintain.\n       *\n       * @param uri                URI of the target service\n       * @param payloadContentType Content type of the payload to send\n       * @param payload            Payload to send\n       * @param httpMethod         HTTP method to use\n       * @param accessToken        Access token to specify to represent the identity of the caller\n       * @return The HTTP response code received\n       * @throws Exception If any error occurs\n       *\u002F\n      private int callService(String uri, String payload, String payloadContentType, String httpMethod, String accessToken) throws Exception {\n          int rc;\n\n          \u002F\u002FBuild the request - Use Apache HTTP Client in order to be more flexible in the combination.\n          HttpRequestBase request;\n          String url = (BASE_URL + uri).replaceAll(\"\\\\{messageId\\\\}\", \"1\");\n          switch (httpMethod) {\n              case \"GET\":\n                  request = new HttpGet(url);\n                  break;\n              case \"DELETE\":\n                  request = new HttpDelete(url);\n                  break;\n              case \"PUT\":\n                  request = new HttpPut(url);\n                  if (payload != null) {\n                      request.setHeader(\"Content-Type\", payloadContentType);\n                      ((HttpPut) request).setEntity(new StringEntity(payload.trim()));\n                  }\n                  break;\n              default:\n                  throw new UnsupportedOperationException(httpMethod + \" not supported !\");\n          }\n          request.setHeader(\"Authorization\", (accessToken != null) ? accessToken : \"\");\n\n\n          \u002F\u002FSend the request and get the HTTP response code.\n          try (CloseableHttpClient httpClient = HttpClients.createDefault()) {\n              try (CloseableHttpResponse httpResponse = httpClient.execute(request)) {\n                  \u002F\u002FDon't care here about the response content...\n                  rc = httpResponse.getStatusLine().getStatusCode();\n              }\n          }\n\n          return rc;\n      }\n\n      \u002F**\n       * Generate a JWT token for the specified user and role.\n       *\n       * @param login User login\n       * @param role  Authorization logical role\n       * @return The JWT token\n       * @throws Exception If any error occurs during the creation\n       *\u002F\n      private String generateTestCaseAccessToken(String login, SecurityRole role) throws Exception {\n          return new AuthService().issueAccessToken(login, role);\n      }\n\n\n      \u002F**\n       * Format a list of errors to a printable string.\n       *\n       * @param errors Error list\n       * @return Printable string\n       *\u002F\n      private String formatErrorsList(List\u003CString> errors) {\n          StringBuilder buffer = new StringBuilder();\n          errors.forEach(e -> buffer.append(e).append(\"\\n\"));\n          return buffer.toString();\n      }\n  }\n```\n\nIf an authorization issue is detected (or issues are detected), the output is the following:\n\n```java\ntestAccessUsingAnonymousUserPointOfView(org.owasp.pocauthztesting.AuthorizationMatrixIT)\nTime elapsed: 1.009 s  ### FAILURE\njava.lang.AssertionError:\nAccess issues detected using the ANONYMOUS USER point of view:\n    The service 'DeleteMessage' when called with POV 'ANONYMOUS' return\n    a response code 200 that is not the expected one (403 expected).\n\n    The service 'CreateMessage' when called with POV 'ANONYMOUS' return\n    a response code 200 that is not the expected one (403 expected).\n\ntestAccessUsingBasicUserPointOfView(org.owasp.pocauthztesting.AuthorizationMatrixIT)\nTime elapsed: 0.05 s  ### FAILURE!\njava.lang.AssertionError:\nAccess issues detected using the BASIC USER point of view:\n    The service 'DeleteMessage' when called with POV 'BASIC' return\n    a response code 200 that is not the expected one (403 expected).\n```\n\n## Rendering the authorization matrix for an audit \u002F review\n\nEven if the authorization matrix is stored in a human-readable format (XML), you might want to show an on-the-fly rendered representation of the XML file to spot potential inconsistencies and facilitate the review, audit and discussion about the authorization matrix.\n\n\u003C!-- textlint-disable -->\nTo achieve this task, you could use the following XSL stylesheet:\n\u003C!-- textlint-enable -->\n\n``` xslt\n\u003C?xml version=\"1.0\" encoding=\"UTF-8\"?>\n\u003Cxsl:stylesheet xmlns:xsl=\"http:\u002F\u002Fwww.w3.org\u002F1999\u002FXSL\u002FTransform\" version=\"1.0\">\n  \u003Cxsl:template match=\"\u002F\">\n    \u003Chtml>\n      \u003Chead>\n        \u003Ctitle>Authorization Matrix\u003C\u002Ftitle>\n        \u003Clink rel=\"stylesheet\"\n        href=\"https:\u002F\u002Fmaxcdn.bootstrapcdn.com\u002Fbootstrap\u002F4.0.0-alpha.6\u002Fcss\u002Fbootstrap.min.css\"\n        integrity=\"sha384-rwoIResjU2yc3z8GV\u002FNPeZWAv56rSmLldC3R\u002FAZzGRnGxQQKnKkoFVhFQhNUwEyJ\"\n        crossorigin=\"anonymous\" \u002F>\n      \u003C\u002Fhead>\n      \u003Cbody>\n        \u003Ch3>Roles\u003C\u002Fh3>\n        \u003Cul>\n          \u003Cxsl:for-each select=\"authorization-matrix\u002Froles\u002Frole\">\n            \u003Cxsl:choose>\n              \u003Cxsl:when test=\"@name = 'ADMIN'\">\n                \u003Cdiv class=\"alert alert-warning\" role=\"alert\">\n                  \u003Cstrong>\n                    \u003Cxsl:value-of select=\"@name\" \u002F>\n                  \u003C\u002Fstrong>\n                  :\n                  \u003Cxsl:value-of select=\"@description\" \u002F>\n                \u003C\u002Fdiv>\n              \u003C\u002Fxsl:when>\n              \u003Cxsl:when test=\"@name = 'BASIC'\">\n                \u003Cdiv class=\"alert alert-info\" role=\"alert\">\n                  \u003Cstrong>\n                    \u003Cxsl:value-of select=\"@name\" \u002F>\n                  \u003C\u002Fstrong>\n                  :\n                  \u003Cxsl:value-of select=\"@description\" \u002F>\n                \u003C\u002Fdiv>\n              \u003C\u002Fxsl:when>\n              \u003Cxsl:otherwise>\n                \u003Cdiv class=\"alert alert-danger\" role=\"alert\">\n                  \u003Cstrong>\n                    \u003Cxsl:value-of select=\"@name\" \u002F>\n                  \u003C\u002Fstrong>\n                  :\n                  \u003Cxsl:value-of select=\"@description\" \u002F>\n                \u003C\u002Fdiv>\n              \u003C\u002Fxsl:otherwise>\n            \u003C\u002Fxsl:choose>\n          \u003C\u002Fxsl:for-each>\n        \u003C\u002Ful>\n        \u003Ch3>Authorizations\u003C\u002Fh3>\n        \u003Ctable class=\"table table-hover table-sm\">\n          \u003Cthead class=\"thead-inverse\">\n            \u003Ctr>\n              \u003Cth>Service\u003C\u002Fth>\n              \u003Cth>URI\u003C\u002Fth>\n              \u003Cth>Method\u003C\u002Fth>\n              \u003Cth>Role\u003C\u002Fth>\n            \u003C\u002Ftr>\n          \u003C\u002Fthead>\n          \u003Ctbody>\n            \u003Cxsl:for-each select=\"authorization-matrix\u002Fservices\u002Fservice\">\n              \u003Cxsl:variable name=\"service-name\" select=\"@name\" \u002F>\n              \u003Cxsl:variable name=\"service-uri\" select=\"@uri\" \u002F>\n              \u003Cxsl:variable name=\"service-method\" select=\"@http-method\" \u002F>\n              \u003Cxsl:for-each select=\"role\">\n                \u003Ctr>\n                  \u003Ctd scope=\"row\">\n                    \u003Cxsl:value-of select=\"$service-name\" \u002F>\n                  \u003C\u002Ftd>\n                  \u003Ctd>\n                    \u003Cxsl:value-of select=\"$service-uri\" \u002F>\n                  \u003C\u002Ftd>\n                  \u003Ctd>\n                    \u003Cxsl:value-of select=\"$service-method\" \u002F>\n                  \u003C\u002Ftd>\n                  \u003Ctd>\n                    \u003Cxsl:variable name=\"service-role-name\" select=\"@name\" \u002F>\n                    \u003Cxsl:choose>\n                      \u003Cxsl:when test=\"@name = 'ADMIN'\">\n                        \u003Cdiv class=\"alert alert-warning\" role=\"alert\">\n                          \u003Cxsl:value-of select=\"@name\" \u002F>\n                        \u003C\u002Fdiv>\n                      \u003C\u002Fxsl:when>\n                      \u003Cxsl:when test=\"@name = 'BASIC'\">\n                        \u003Cdiv class=\"alert alert-info\" role=\"alert\">\n                          \u003Cxsl:value-of select=\"@name\" \u002F>\n                        \u003C\u002Fdiv>\n                      \u003C\u002Fxsl:when>\n                      \u003Cxsl:otherwise>\n                        \u003Cdiv class=\"alert alert-danger\" role=\"alert\">\n                          \u003Cxsl:value-of select=\"@name\" \u002F>\n                        \u003C\u002Fdiv>\n                      \u003C\u002Fxsl:otherwise>\n                    \u003C\u002Fxsl:choose>\n                  \u003C\u002Ftd>\n                \u003C\u002Ftr>\n              \u003C\u002Fxsl:for-each>\n            \u003C\u002Fxsl:for-each>\n          \u003C\u002Ftbody>\n        \u003C\u002Ftable>\n      \u003C\u002Fbody>\n    \u003C\u002Fhtml>\n  \u003C\u002Fxsl:template>\n\u003C\u002Fxsl:stylesheet>\n```\n\nExample of the rendering:\n\n![RenderingExample](..\u002Fassets\u002FAuthorization_Testing_Automation_AutomationRendering.png)\n\n## Sources of the prototype\n\n[GitHub repository](https:\u002F\u002Fgithub.com\u002Frighettod\u002Fpoc-authz-testing)\n\n## References\n\n- [Authorization matrix testing prototype](https:\u002F\u002Fgithub.com\u002Frighettod\u002Fpoc-authz-testing)\n- [OWASP SAMM: Security Testing](https:\u002F\u002Fowaspsamm.org\u002Fmodel\u002Fverification\u002Fsecurity-testing\u002F)\n",{},"main","5d0a87185c0e172c3901e2a6e5916b6d544b8b94","skills\u002Fauthorization-testing-automation-cheat-sheet","https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance","https:\u002F\u002Fgithub.com\u002FJunMystery","AI is the typist, I am the architect. Building efficient, secure, and user-centric products through disciplined AI prompt engineering.","2026-11-13 17:41:25",{"source":7,"skillName":5,"commands":30,"prompt":40,"zipAvailable":41},[31,34,37],{"tool":32,"command":33},"npx","npx skills add JunMystery\u002FAgent-Guidance --skill authorization-testing-automation-cheat-sheet",{"tool":35,"command":36},"bunx","bunx skills add JunMystery\u002FAgent-Guidance --skill authorization-testing-automation-cheat-sheet",{"tool":38,"command":39},"pnpm","pnpm dlx skills add JunMystery\u002FAgent-Guidance --skill authorization-testing-automation-cheat-sheet","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance\u002Fblob\u002Fmain\u002Fskills\u002Fauthorization-testing-automation-cheat-sheet\u002FSKILL.md",true,[],[44,50,56,62,68,74],{"skillNo":45,"name":46,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":47,"categories":48,"keywords":49,"publishedAt":18},"01M79QR1E309VJ6CTQKB32AWWA","zero-trust-architecture-cheat-sheet","https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance\u002Fblob\u002Fmain\u002Fskills\u002Fzero-trust-architecture-cheat-sheet\u002FSKILL.md",[],[],{"skillNo":51,"name":52,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":53,"categories":54,"keywords":55,"publishedAt":18},"01M79QQV7GHYR02DYGN41S23WN","xss-filter-evasion-cheat-sheet","https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance\u002Fblob\u002Fmain\u002Fskills\u002Fxss-filter-evasion-cheat-sheet\u002FSKILL.md",[],[],{"skillNo":57,"name":58,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":59,"categories":60,"keywords":61,"publishedAt":18},"01M79QQNSN7YB8XB61FFSCS3WH","xs-leaks-cheat-sheet","https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance\u002Fblob\u002Fmain\u002Fskills\u002Fxs-leaks-cheat-sheet\u002FSKILL.md",[],[],{"skillNo":63,"name":64,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":65,"categories":66,"keywords":67,"publishedAt":18},"01M79QQHZZJKFDY9132G5A65C2","xpath-injection-prevention-cheat-sheet","https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance\u002Fblob\u002Fmain\u002Fskills\u002Fxpath-injection-prevention-cheat-sheet\u002FSKILL.md",[],[],{"skillNo":69,"name":70,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":18},"01M79QQB9ZSD3DJG8658EHQXR1","xml-security-cheat-sheet","https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance\u002Fblob\u002Fmain\u002Fskills\u002Fxml-security-cheat-sheet\u002FSKILL.md",[],[],{"skillNo":75,"name":76,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":77,"categories":78,"keywords":79,"publishedAt":18},"01M79QQ60WKV7PFMXWT9CW8PM6","xml-external-entity-prevention-cheat-sheet","https:\u002F\u002Fgithub.com\u002FJunMystery\u002FAgent-Guidance\u002Fblob\u002Fmain\u002Fskills\u002Fxml-external-entity-prevention-cheat-sheet\u002FSKILL.md",[],[]]