Jul-19-2024, 05:09 PM
Jul-22-2024, 11:29 AM
ie when i run the software and in console i get the ip address of the pc accessing the web server
127.0.0.1 - - [21/Jul/2024 20:40:11] "POST /password HTTP/1.1" 200 -obviously im accessing the web server from the same host but i do get different ips when i try to access the webserver from another LAN pc
Jul-22-2024, 12:01 PM
worked it out
@app.route('/password', methods=['GET', 'POST']) def password(): ip_addr = request.remote_addr form = PasswordForm() if request.method == 'POST' and form.validate():
logger.warning(f'{ip_addr} {form.un.data} your current password is wrong, please click back and try again')and in log file i get this
2024-07-22-12-55-27 | WARNING | 127.0.0.1 robert.wild your current password is wrong, please click back and try again