Skip to content

Commit

Permalink
Return error when creating token with if.ll
Browse files Browse the repository at this point in the history
  • Loading branch information
FrankZRS committed Feb 23, 2024
1 parent c065fa2 commit 62455b5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions api/oc_knx_sec.c
Original file line number Diff line number Diff line change
Expand Up @@ -670,6 +670,11 @@ oc_core_auth_at_post_handler(oc_request_t *request,
char *if_str = oc_string_array_get_item(str_array, i);
oc_interface_mask_t if_mask =
oc_ri_get_interface_mask(if_str, strlen(if_str));
if (if_mask == OC_IF_LI) {
PRINT(" if.ll is not a valid access scope!\n");
oc_send_response_no_format(request, OC_STATUS_BAD_REQUEST);
return;
}
interfaces = interfaces + if_mask;
}
g_at_entries[index].scope = interfaces;
Expand Down

0 comments on commit 62455b5

Please sign in to comment.