mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-07 00:20:20 +07:00
Added mg_send_file() to python binding
This commit is contained in:
@@ -39,6 +39,9 @@ def EventHandler(event, conn, info):
|
||||
'<input type="submit"/>'
|
||||
'</form>')
|
||||
return True
|
||||
elif event == mongoose.NEW_REQUEST and info.uri == '/secret':
|
||||
conn.send_file('/etc/passwd')
|
||||
return True
|
||||
else:
|
||||
return False
|
||||
|
||||
|
||||
Reference in New Issue
Block a user