gavincarr / mod_auth_tkt

Lightweight single-signon authentication module for Apache
Other
37 stars 22 forks source link

cookie breaks with UID with email #21

Open elfeto opened 8 years ago

elfeto commented 8 years ago

Hi,

I am using python here, whenever I create the cookie with the userid (UID) with the email it breaks, it works fine with other strings but with the @ it replaces it with %40 and makes the cookie invalid.

Is there a workaround or something?

This is my python code: from paste.auth import auth_tkt ticket = auth_tkt.AuthTicket('TOP SECRET!', userid='felipe.torres.cs@gmail.com', ip='0.0.0.0', user_data="felipe.torres.cs@gmail.com") print ticket.cookie()

Error log: TKT valid_ticket: (parsed) uid 'felipe.torres.cs%40gmail.com', tokens '', user_data 'test', ts '1474047351', ... mod_auth_tkt.c(820): TKT ticket_digest: using secret 'TOP SECRET!', ip '0.0.0.0', ... TKT valid_ticket: ticket hash (current secret) is invalid, and no old secret set - digest 'ae4f4372680e13a00481301', ticket 'e302f8654678876567876767dc2d77felipe.torres.cs%40gmail.com!test', referer: ...