mirror of
https://github.com/github/codeql.git
synced 2026-04-25 00:35:20 +02:00
Create UnSafeComparisonOfSensitiveInfo.py
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: UTF-8 -*-
|
||||
"""
|
||||
@Desc :timing attack against sensitive info
|
||||
"""
|
||||
|
||||
from flask import Flask
|
||||
from flask import request
|
||||
|
||||
@app.route('/bad')
|
||||
def check_credentials(password):
|
||||
return password == "token"
|
||||
|
||||
if __name__ == '__main__':
|
||||
app.debug = True
|
||||
app.run()
|
||||
Reference in New Issue
Block a user