Autologin & integration third party module

(bronco) #1

Hello guys,

at first I like piwik so much! So I had a great Idea to integrate Piwik in my new linkpartnertool. com <- commercial ad if the tool works style_emoticons/<#EMO_DIR#>/biggrin.gif

Okay my problems are: Autologin and I think it is a cookie problem. I used the code snippets to integrate login via url to piwik. The other solution in php (which i had preffered but it doesn’t worked). I always get the answer wrong password and loginname. The login and passkey md5 is right. So after Login in superuser mode. The simple login via url work. I had no Idea where the problem is. I must integrate piwik in several cases. Insert and add user and websites. Updates also and last but not least the autologin from my tool. I really read a lot at google but I found didn’t found answers to my questions.

Have some a idea how to use php to interakt with the piwik gateway?


(bronco) #2

hello again,

I solved the problem with the autologin. so at first I builded my own programm. at the account creating i got the nessesary login informations of the user. I added the data to my database and the database of piwik. the problem was that i didn’t exactly know how piwik creates the passwords and the aut token.

piwik creates login md5 hashes this way;
login : login
password : md5(password)
auth_token: md5(login.md5(password)) <- this was the problem.

if you create your passwords for autologin via url do it this way!! it is also possible too use the piwik api to add a user!!!

I hope it helps someone

(Matthieu Aubry) #3

to get the token_auth you should call the API UsersManager.getTokenAuth(Login, Md5Password)

it would be better than hacking it yourself (in case implementation changes)

(bronco) #4

yes i think its the best to write a bridge. thx for your help