Support A2Billing :

provided by Star2Billing S.L.

Support A2Billing :
It is currently Tue Apr 23, 2024 1:01 pm
Hosted Voice Broadcast


All times are UTC




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: minus (or hyphen) sign in email
PostPosted: Thu Apr 24, 2008 2:35 pm 
Offline

Joined: Thu Jan 31, 2008 4:41 pm
Posts: 5
One of my users was trying to signup with minus sign in email address ([email protected]). A2billing (or PHP?) stripped off the minus sign. That is, [email protected] became [email protected] and a2billing sent email to [email protected]. Please help me, how can I preserve special characters in email address.


Last edited by ziansw on Thu Apr 24, 2008 5:14 pm, edited 2 times in total.

Top
 Profile  
 
 Post subject:
PostPosted: Thu Apr 24, 2008 4:27 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
I can confirm this is a problem, but I've not had any luck yet finding where the hypens are being stripped out. Clues gratefully accepted. :wall:


Top
 Profile  
 
 Post subject:
PostPosted: Thu Apr 24, 2008 9:09 pm 
Offline

Joined: Thu Oct 19, 2006 9:56 am
Posts: 300
Location: Athens, Greece
It is the getpost_ifset() calling sanitize()...

That was one of the major changes from v1.3 to v200.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Apr 24, 2008 10:08 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
D'uh! Thanks for that xrg. I couldn't see the wood for the trees. Of course, it's removing SQL comments for safety.

ziansw, this isn't easily fixed. A workaround would be to use your SQL client to manually correct that user's email address in the cc_card table, and hope that you don't get many other users with two consecutive hyphens.

And look forward to the release of v200 at some point. Are you excited? I am. :laugh:


Top
 Profile  
 
 Post subject: minus sign in email -- Solved
PostPosted: Mon Apr 28, 2008 4:38 pm 
Offline

Joined: Thu Jan 31, 2008 4:41 pm
Posts: 5
xrg wrote:
It is the getpost_ifset() calling sanitize()...

That was one of the major changes from v1.3 to v200.



Yes, it was in sanitize() function (in lib/Misc.php). Thanks for your help.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 28, 2008 5:08 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
Please be aware that if you've changed sanitize() to accept '--' as a valid string, you've opened yourself to SQL injection attacks; it's possible you may wake up one day to find someone dropped all your tables, or worse.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 29, 2008 10:56 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
It's not often you see SQL injection related comedy, so I couldn't resist sharing this here.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 
Voice Broadcast System


All times are UTC


Who is online

Users browsing this forum: No registered users and 10 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group