Thank you @Hardikgiri Goswami for your quick reply of course i have searched about how to set cookie in python using werkzeug lib as follow ( set_cookie(key, value='', max_age=None, expires=None, path='/', domain=None,secure=None, httponly=False) )
ref: http://werkzeug.pocoo.org/docs/0.9/wrappers/
and for more info about werkzeug you can see this link http://werkzeug.pocoo.org/docs/0.9/
what i have done is:
response.set_cookie('sid', session.sid, max_age=2*3600, expires=int(time.time())+2*3600, httponly=True)
and this works fine.
What i want to know exactly which way is the best for setting cookie parameters specially in OPENERP like what i did using http.py file or using NGINX reverse proxy like the answer mentioned by @rrehbein in this link http://serverfault.com/questions/278319/how-to-rewrite-the-domain-part-of-set-cookie-in-a-nginx-reverse-proxy.
To know more and more about cookies review this very helpful links:
http://pymotw.com/2/Cookie/
https://webapp-improved.appspot.com/guide/response.html
http://pydoc.net/Python/wheezy.http/0.1.260/wheezy.http.cookie/
http://werkzeug.pocoo.org/docs/0.9/wrappers/