Let's have a news website with the possibility of registration of users
If the user is registered, he displays one of the content; if not, then the otherHow do I tell the script which I'm developing (currently in Python and PHP) that the username and password from this news site, give me the html data for a registered user?
I understand that when you sign in on the website have the cookies and session to check. Let's say I can replace the headers by copying them from Chrome Debugger, but because these headers will change? And it will do it work?
Example of giving for one site Request Headers below when entering via GET to the page. It turns out if the cookies run out, then every time I need to go to the site manually, copy the new value and paste it into the script?
Cookie:PHPSESSID=sgjjv462jhc8o7jbqna6u7u1vs7; example-mo_ename=cad7d6de252ee31018d968134dcd2518f78ff; example-mo_type_auth=employer
User-Agent:Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36
PHPSESSID sgjjv46jhc8do7jbqn6u7u1vs7 N/A N/A N/A 38
example-mo_ename cad7d6de25ee31034718df96813dcd2518f78ff N/A N/A N/A 53
Response -- the html page