@@ -37,8 +37,8 @@ typedef int (*StringValidatorFunction)(const char *value, char **err_msg);
3737
3838/** @brief Access Control List entry containing authorization and resource */
3939typedef struct Acl_s {
40- const char * authz ; /**< Authorization type (e.g., "read", "write") */
41- const char * resource ; /**< Resource path or pattern */
40+ const char * authz ; /**< Authorization type (e.g., "read", "write") */
41+ const char * resource ; /**< Resource path or pattern */
4242} Acl ;
4343
4444/**
@@ -61,9 +61,9 @@ typedef enum _profile {
6161
6262/**
6363 * @brief Create a cryptographic key for signing tokens
64- *
64+ *
6565 * @param key_id Identifier for the key (used in 'kid' header)
66- * @param algorithm Signing algorithm (e.g., "ES256", "RS256")
66+ * @param algorithm Signing algorithm (e.g., "ES256", "RS256")
6767 * @param public_contents PEM-encoded public key
6868 * @param private_contents PEM-encoded private key
6969 * @param err_msg Output parameter for error messages (caller must free)
@@ -75,29 +75,29 @@ SciTokenKey scitoken_key_create(const char *key_id, const char *algorithm,
7575
7676/**
7777 * @brief Destroy a key object and free associated memory
78- *
78+ *
7979 * @param private_key Key handle to destroy
8080 */
8181void scitoken_key_destroy (SciTokenKey private_key );
8282
8383/**
8484 * @brief Create a new SciToken
85- *
85+ *
8686 * @param private_key Key to use for signing, or NULL for unsigned token
8787 * @return SciToken handle on success, NULL on failure
8888 */
8989SciToken scitoken_create (SciTokenKey private_key );
9090
9191/**
9292 * @brief Destroy a token object and free associated memory
93- *
93+ *
9494 * @param token Token handle to destroy
9595 */
9696void scitoken_destroy (SciToken token );
9797
9898/**
9999 * @brief Set a string claim in the token
100- *
100+ *
101101 * @param token Token to modify
102102 * @param key Claim name (e.g., "iss", "aud", "scope")
103103 * @param value Claim value
@@ -109,7 +109,7 @@ int scitoken_set_claim_string(SciToken token, const char *key,
109109
110110/**
111111 * @brief Get a string claim from the token
112- *
112+ *
113113 * @param token Token to query
114114 * @param key Claim name to retrieve
115115 * @param value Output parameter for claim value (caller must free)
@@ -143,7 +143,7 @@ int scitoken_set_claim_string_list(const SciToken token, const char *key,
143143
144144/**
145145 * @brief Get the expiration time of the token
146- *
146+ *
147147 * @param token Token to query
148148 * @param value Output parameter for expiration time (Unix timestamp)
149149 * @param err_msg Output parameter for error messages (caller must free)
@@ -154,18 +154,18 @@ int scitoken_get_expiration(const SciToken token, long long *value,
154154
155155/**
156156 * @brief Set the lifetime of the token in seconds
157- *
157+ *
158158 * @param token Token to modify
159159 * @param lifetime Lifetime in seconds from creation
160160 */
161161void scitoken_set_lifetime (SciToken token , int lifetime );
162162
163163/**
164164 * @brief Serialize the token to a JWT string
165- *
165+ *
166166 * @param token Token to serialize
167167 * @param value Output parameter for JWT string (caller must free)
168- * @param err_msg Output parameter for error messages (caller must free)
168+ * @param err_msg Output parameter for error messages (caller must free)
169169 * @return 0 on success, non-zero on failure
170170 */
171171int scitoken_serialize (const SciToken token , char * * value , char * * err_msg );
@@ -182,10 +182,11 @@ void scitoken_set_deserialize_profile(SciToken token, SciTokenProfile profile);
182182
183183/**
184184 * @brief Deserialize a JWT string into a SciToken
185- *
185+ *
186186 * @param value JWT string to parse
187187 * @param token Output parameter for created token (caller must destroy)
188- * @param allowed_issuers NULL-terminated array of allowed issuer URLs, or NULL for any
188+ * @param allowed_issuers NULL-terminated array of allowed issuer URLs, or NULL
189+ * for any
189190 * @param err_msg Output parameter for error messages (caller must free)
190191 * @return 0 on success, non-zero on failure
191192 */
@@ -230,7 +231,7 @@ int scitoken_deserialize_v2(const char *value, SciToken token,
230231
231232/**
232233 * @brief Store a public EC key for token verification
233- *
234+ *
234235 * @param issuer Issuer URL that will use this key
235236 * @param keyid Key identifier
236237 * @param value PEM-encoded public key
@@ -242,7 +243,7 @@ int scitoken_store_public_ec_key(const char *issuer, const char *keyid,
242243
243244/**
244245 * @brief Create a new token validator
245- *
246+ *
246247 * @return Validator handle on success, NULL on failure
247248 */
248249Validator validator_create ();
@@ -267,7 +268,7 @@ int validator_add_critical_claims(Validator validator, const char **claims,
267268
268269/**
269270 * @brief Validate a SciToken using the configured validator
270- *
271+ *
271272 * @param validator Validator to use
272273 * @param scitoken Token to validate
273274 * @param err_msg Output parameter for error messages (caller must free)
@@ -277,14 +278,14 @@ int validator_validate(Validator validator, SciToken scitoken, char **err_msg);
277278
278279/**
279280 * @brief Destroy a validator object and free associated memory
280- *
281+ *
281282 * @param validator Validator handle to destroy
282283 */
283284void validator_destroy (Validator validator );
284285
285286/**
286287 * @brief Create a new token enforcer
287- *
288+ *
288289 * @param issuer Required issuer URL for tokens
289290 * @param audience NULL-terminated array of acceptable audience values
290291 * @param err_msg Output parameter for error messages (caller must free)
@@ -295,7 +296,7 @@ Enforcer enforcer_create(const char *issuer, const char **audience,
295296
296297/**
297298 * @brief Destroy an enforcer object and free associated memory
298- *
299+ *
299300 * @param enforcer Enforcer handle to destroy
300301 */
301302void enforcer_destroy (Enforcer enforcer );
@@ -315,10 +316,11 @@ int enforcer_set_time(Enforcer enf, time_t now, char **err_msg);
315316
316317/**
317318 * @brief Generate Access Control Lists from a token
318- *
319+ *
319320 * @param enf Enforcer to use
320321 * @param scitokens Token to process
321- * @param acls Output parameter for ACL array (caller must free with enforcer_acl_free)
322+ * @param acls Output parameter for ACL array (caller must free with
323+ * enforcer_acl_free)
322324 * @param err_msg Output parameter for error messages (caller must free)
323325 * @return 0 on success, non-zero on failure
324326 */
@@ -336,14 +338,14 @@ int enforcer_generate_acls_continue(const Enforcer enf, SciTokenStatus *status,
336338
337339/**
338340 * @brief Free an array of ACLs returned by enforcer_generate_acls
339- *
341+ *
340342 * @param acls ACL array to free
341343 */
342344void enforcer_acl_free (Acl * acls );
343345
344346/**
345347 * @brief Test if a token grants access for a specific ACL
346- *
348+ *
347349 * @param enf Enforcer to use
348350 * @param sci Token to test
349351 * @param acl ACL to test against
0 commit comments