How to get in a decorator function in Flask the IP address and port of the client that sent the request ?
from flask import Flask, request, jsonify
from functools import wraps
app = Flask(__name__)
def check_auth(f):
    @wraps(f)
    def decorated_function(*args, **kwargs):
        print(request)
        ###  Here I need the IP address and port of the client
        return f(*args, **kwargs)
    return decorated_function
@app.route('/test', methods=['POST'])
@check_auth
def hello():
    json = request.json
    json['nm'] = 'new name2'
    jsonStr = jsonify(json)
    return jsonStr
 
     
    