на днях наткнулся на свой код авторизации в твиттере, тут он есть, ну и решил доделать всётаки :)
в авторизации кое чего изменилось, добавилось одно поле - authenticity_token, его добавил, но не авторизируется никак, в прошлый раз всё проходило.
<?php
$url = 'http://twitter.com/';
$urlTo = 'https://twitter.com/sessions';
session_start();
$_session['username_or_email'] = 'Auto_gues';
$_session['password'] = 'curlphpcool';
$return_to_ssl = 'true';
$scribe_log = '["{\"event_name\":\"web:front:login_callout:form::login_click\",\"noob_level\":null,\"internal_referer\":null,\"user_id\":0,\"page\":\"front\",\"_category_\":\"client_event\",\"ts\":1347962894014}"]';
$redirect_after_login = '';
$authenticity_token = 'тут id взятый с формы в html';
$html = curl_exec($ch);
$post = 'session[username_or_email]=' . $_session['username_or_email'] . '&session[password]=' . $_session['password'] . '&return_to_ssl=' . $return_to_ssl . '&scribe_log=' . $scribe_log . '&redirect_after_login=' . $redirect_after_login . '&authenticity_token=' . $authenticity_token;
curl_setopt($ch, CURLOPT_URL, $urlTo);
curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 5.1; rv:10.0.2) Gecko/20100101 Firefox/10.0.2');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_COOKIEJAR, 'z:\home\twifoll.ru\www\cookie.txt');
curl_setopt($ch, CURLOPT_COOKIEFILE, 'z:\home\twifoll.ru\www\cookie.txt');
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $post);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
echo $html = curl_exec($ch);
curl_close($ch);
?>