Finds the authority item that answers req. An item matches when action, resource and unit are equal strings (no
unit conversion) and the object agrees: the request names none, the item names none, or both name the same one.
no match: AUTHORITY_MISSING;
every match is past its valid_until: AUTHORITY_EXPIRED, with the item that expired last;
otherwise the unexpired match with the largest limit decides, and the request is accepted when its amount does
not exceed that limit (equal is accepted). Over the limit: AUTHORITY_LIMIT_EXCEEDED, with that item so that the
limit can be shown. An amount that is negative or not a number is over every limit.
Finds the authority item that answers
req. An item matches when action, resource and unit are equal strings (no unit conversion) and the object agrees: the request names none, the item names none, or both name the same one.valid_until: AUTHORITY_EXPIRED, with the item that expired last;