Thanks for your help, Grumpy Old Man,
1) I'm trying to send every header I'm sending to this webpage using my browser, but it just doesn't work.
The hidden variable named "javax.faces.ViewState" regenerates it's value each time I make request , so In essence I need to call curl_exec 2 times with the same cURL resource , 1st time to get this value, 2nd - to send form data, right ? This seems like possible to achieve, even I don't really clearly understand what does javax.faces.ViewState means..
But... There is another catch: This webpage sends a COOKIE and I am unable to save it. Why ? I don't have a clue, maybe it's the same origin policy ?
curl_setopt($login_curl, CURLOPT_COOKIEFILE, 'cookie.txt');
curl_setopt($login_curl, CURLOPT_COOKIEJAR, 'cookie.txt');
3) I have legal access only to the administration panel, not the source code.
p.s This website runs on SSL if if does really matter. I do have curl_setopt($login_curl, CURLOPT_SSL_VERIFYPEER, FALSE); line in my code