2021-01-10 23:20:14 +00:00
|
|
|
id: generic-tokens
|
2020-05-24 03:57:26 +00:00
|
|
|
|
|
|
|
info:
|
2021-01-10 23:20:14 +00:00
|
|
|
name: Generic Tokens
|
2021-06-09 12:20:56 +00:00
|
|
|
author: nadino,geeknik
|
2021-01-10 23:20:14 +00:00
|
|
|
severity: info
|
2021-04-13 13:48:02 +00:00
|
|
|
tags: exposure,token
|
2021-03-11 16:17:26 +00:00
|
|
|
|
2020-05-24 03:57:26 +00:00
|
|
|
requests:
|
|
|
|
- method: GET
|
|
|
|
path:
|
2020-05-25 11:52:12 +00:00
|
|
|
- '{{BaseURL}}'
|
2021-04-08 15:45:49 +00:00
|
|
|
|
2020-07-11 05:50:35 +00:00
|
|
|
matchers-condition: and
|
2020-05-24 03:57:26 +00:00
|
|
|
matchers:
|
|
|
|
- type: dsl
|
|
|
|
dsl:
|
2020-05-25 11:52:12 +00:00
|
|
|
- regex("TOKEN[\\-|_|A-Z0-9]*(\'|\")?(:|=)(\'|\")?[\\-|_|A-Z0-9]{10}",replace(toupper(body),"",""))
|
|
|
|
- regex("API[\\-|_|A-Z0-9]*(\'|\")?(:|=)(\'|\")?[\\-|_|A-Z0-9]{10}",replace(toupper(body),"",""))
|
|
|
|
- regex("KEY[\\-|_|A-Z0-9]*(\'|\")?(:|=)(\'|\")?[\\-|_|A-Z0-9]{10}",replace(toupper(body),"",""))
|
|
|
|
- regex("SECRET[\\-|_|A-Z0-9]*(\'|\")?(:|=)(\'|\")?[\\-|_|A-Z0-9]{10}",replace(toupper(body),"",""))
|
|
|
|
- regex("AUTHORIZATION[\\-|_|A-Z0-9]*(\'|\")?(:|=)(\'|\")?[\\-|_|A-Z0-9]{10}",replace(toupper(body),"",""))
|
|
|
|
- regex("PASSWORD[\\-|_|A-Z0-9]*(\'|\")?(:|=)(\'|\")?[\\-|_|A-Z0-9]{10}",replace(toupper(body),"",""))
|
2021-04-08 15:45:49 +00:00
|
|
|
|
|
|
|
- type: regex
|
|
|
|
part: body
|
|
|
|
regex:
|
2021-08-12 14:53:33 +00:00
|
|
|
- '(?i)key(sinternal|up|down|press|boardnavigation|words?|board|ebrow|board_fill|_retry_interval|_fetched|_expiresat|board_shortcuts|s_close|s_previous|s_next|s_zoom|s_play_pause)'
|
|
|
|
- '(?i)password(lessauth|requirementsashtmllist|emailnotfoundmessage|label|errormessage|message|_checkemail_title|_newfield_retype|_text_new|login_submit|_has_expired_title|_has_expired_text|_error|_hint|_strength)'
|
2021-08-17 16:52:31 +00:00
|
|
|
- '(?i)(!native)|(.*keybindings)'
|
2021-08-12 14:53:33 +00:00
|
|
|
- '(?i)(layout|a)key'
|
2021-09-02 15:36:46 +00:00
|
|
|
- '(?i)token_expires_in'
|
2021-06-01 18:22:05 +00:00
|
|
|
condition: or
|
2021-04-08 15:45:49 +00:00
|
|
|
negative: true
|
|
|
|
|
2020-05-24 03:57:26 +00:00
|
|
|
extractors:
|
|
|
|
- type: regex
|
|
|
|
part: body
|
|
|
|
regex:
|
2020-05-25 11:52:12 +00:00
|
|
|
- (T|t)(O|o)(K|k)(E|e)(N|n)[\-|_|A-Za-z0-9]*(\''|")?( )*(:|=)+()*(\''|")?[ 0-9A-Za-z\-_]+(\''|")?
|
|
|
|
- (A|a)(P|p)(Ii)[\-|_|A-Za-z0-9]*(\''|")?( )*(:|=)( )*(\''|")?[0-9A-Za-z\-_]+(\''|")?
|
|
|
|
- (K|k)(E|e)(Y|y)[\-|_|A-Za-z0-9]*(\''|")?( )*(:|=)( )*(\''|")?[0-9A-Za-z\-_]+(\''|")?
|
|
|
|
- (S|s)(E|e)(C|c)(R|r)(E|e)(T|t)[\-|_|A-Za-z0-9]*(\''|")?( )*(:|=)()*(\''|")?[ 0-9A-Za-z\-_]+(\''|")?
|
|
|
|
- (A|a)(U|u)(T|t)(H|h)(O|o)(R|r)(I|i)(Z|z)(A|a)(T|t)(I|i)(O|o)(N|n)[\-|_|A-Za-z0-9]*(\''|")?()*(:|=)( )*(\''|")?[ 0-9A-Za-z\-_]+(\''|")?
|
|
|
|
- (P|p)(A|a)(S|s)(S|s)(W|w)(O|o)(R|r)(D|d)[\-|_|A-Za-z0-9]*(\''|")?()*(:|=)( )*(\''|")?[ 0-9A-Za-z\-_]+(\''|")?
|