-
Notifications
You must be signed in to change notification settings - Fork 458
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[cisco_duo] Fix auth CEL cursor handling (#11456)
In the auth CEL program, the error `type conversion error from 'string' to 'int'` seems to have been happening because of `cursor.last_published` being set to a value of the form `1532951895000,af0ba235-0b33-23c8-bc23-a31aa0231de8`, which can't be parsed as an int. Now `cursor.last_published` is replaced with `cursor.last_timestamp_ms`, which is taken from the last result, and so will be available if the last page of sequence has results but no value in `response.metadata.next_offset`. Also, the date is no longer shared across requests, the request building is simplified, and redundant overrides of state are removed. Related documentation: https://duo.com/docs/adminapi#authentication-logs
- Loading branch information
1 parent
389e6c2
commit 19bd853
Showing
4 changed files
with
76 additions
and
108 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -35,7 +35,7 @@ rules: | |
], | ||
"metadata": { | ||
"next_offset": ["1666714065305","5bf1a860-fe39-49e3-be29-217659663a74"], | ||
"total_objects": 5 | ||
"total_objects": 4 | ||
}}, | ||
"stat":"OK"} | ||
- path: /admin/v2/logs/authentication | ||
|
@@ -50,7 +50,7 @@ rules: | |
], | ||
"metadata": { | ||
"next_offset": ["1666714065306","5bf1a860-fe39-49e3-be29-217659663a74"], | ||
"total_objects": 5 | ||
"total_objects": 3 | ||
}}, | ||
"stat":"OK"} | ||
- path: /admin/v2/logs/authentication | ||
|
@@ -65,7 +65,7 @@ rules: | |
{"access_device":{"browser":"Chrome","browser_version":"67.0.3396.99","flash_version":"uninstalled","hostname":null,"ip":"89.160.20.156","is_encryption_enabled":true,"is_firewall_enabled":true,"is_password_set":true,"java_version":"uninstalled","location":{"city":"Ann Arbor","country":"United States","state":"Michigan"},"os":"Mac OS X","os_version":"10.14.1","security_agents":[]},"alias":"","application":{"key":"DIY231J8BR23QK4UKBY8","name":"Microsoft Azure Active Directory"},"auth_device":{"ip":"192.168.225.254","location":{"city":"Ann Arbor","country":"United States","state":"Michigan"},"name":"My iPhone X (734-555-2342)"},"email":"[email protected]","event_type":"authentication","factor":"duo_push","isotimestamp":"2020-02-13T18:56:20.351346+00:00","ood_software":null,"reason":"user_approved","result":"success","timestamp":1581620180,"trusted_endpoint_status":"not trusted","txid":"340a23e3-23f3-23c1-87dc-1491a23dfdbe","user":{"groups":["Duo Users","CorpHQ Users"],"key":"DU3KC77WJ06Y5HIV7XKQ","name":"[email protected]"}} | ||
], | ||
"metadata": { | ||
"total_objects": 5 | ||
"total_objects": 2 | ||
}}, | ||
"stat":"OK"} | ||
- path: /admin/v1/logs/offline_enrollment | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters