You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
`serve`[finds the service method](#findServiceMethod).
52
52
53
-
When found, `serve` finds the [AuthorizeExpression](#findAuthorizeExpression) and the [AuthorizeKey](#findAuthorizeKeys) annotations (if defined on the method).
53
+
When found, `serve` finds the [@AuthorizeExpression](#findAuthorizeExpression) and the [@AuthorizeKey](#findAuthorizeKeys) annotations (if defined on the method and the parameters).
54
54
55
-
For the authorization expression and the authorization resource(s) found, `serve`[finds the principal](IdentityUtils.md#findPrincipalId) and [authorizeByRequest](#authorizeByRequest).
55
+
Only when there are an authorize expression and keys found, `serve`[finds the principal](IdentityUtils.md#findPrincipalId) and [authorizeByRequest](#authorizeByRequest).
56
56
57
-
Otherwise, `serve` prints out the following WARN message to the logs:
57
+
Otherwise, `serve` prints out one of the WARN messages to the logs and passes the request on to the target (_delegate_) service (as if no authorization were even attempted).
58
58
59
-
```text
60
-
Couldn't unwrap service.
61
-
```
59
+
??? note "WARN Messages"
60
+
`serve` prints out one of the following WARN messages to the logs:
Learn more in the [Java Language Specification]({{ java.spec }}/jls-8.html#jls-8.4.3.2).
98
109
99
-
`findAuthorizeKeys`...FIXME
110
+
`findAuthorizeKeys` finds [@AuthorizeKey](AuthorizeKey.md) annotations on the given `Method` ([Java]({{ java.api }}/java/lang/reflect/Method.html#getAnnotation(java.lang.Class))). If found, `findAuthorizeKeys` adds a locator with the following:
111
+
112
+
Source | Securable
113
+
-|-
114
+
`SYSTEM` | The `value`<br>of the [@AuthorizeKey](AuthorizeKey.md) annotation
115
+
116
+
`findAuthorizeKeys` finds [@AuthorizeKey](AuthorizeKey.md) annotations (incl. [@AuthorizeKeys](AuthorizeKeys.md)) on the method's parameters.
117
+
118
+
??? note "WARN Log Message"
119
+
In case `findAuthorizeKeys` finds both [@AuthorizeKey](AuthorizeKey.md) and [@AuthorizeKeys](AuthorizeKeys.md) annotations, `findAuthorizeKeys` prints out the following WARN message to the logs:
120
+
121
+
```text
122
+
Both AuthorizeKey and AuthorizeKeys present
123
+
```
124
+
125
+
`findAuthorizeKeys` collects the `AuthorizeKey`s.
126
+
127
+
For keys with the key specified, `findAuthorizeKeys` adds a locator with the following:
128
+
129
+
Source | Securable | Key
130
+
-|-|-
131
+
`PAYLOAD` | The `value`<br>of the [@AuthorizeKey](AuthorizeKey.md) annotation | The `key`<br>of the [@AuthorizeKey](AuthorizeKey.md) annotation
132
+
133
+
Otherwise, `findAuthorizeKeys` finds parameters with `@Param` annotation. If found, `findAuthorizeKeys` adds a locator with the following:
134
+
135
+
Source | Securable | Key
136
+
-|-|-
137
+
`PARAM` | The `value`<br>of the [@AuthorizeKey](AuthorizeKey.md) annotation | The `value`<br>of the `@Param` annotation
138
+
139
+
??? note "WARN Log Message"
140
+
In case `findAuthorizeKeys` finds no `@Param` annotation on the parameter, `findAuthorizeKeys` prints out the following WARN message to the logs:
0 commit comments