gberde | Posts: 19

Auth phone number format validation rules

0 votes

We are trying to add validation rules in our consuming application. Could you please share what are the validation rules ( Max length, format) on the phone number that we use for authentication (please see the screenshot attached) ? 

 


Attachments
gberde | Posts: 19

Reply to: Auth phone number format validation rules

0 votes

This is the block of "Clone" payload I am referring to - 

"auth": { "scheme": "SMS", "challenges": [ { "question": "1NNNNNNNNN" } ] }


Duo_Liang | Posts: 3776

Reply to: Auth phone number format validation rules

0 votes

Hi gberde,

 

Thanks for your post!

There are many third party libraries out there which can tell if a phone number is too long, or whether the length fits the country code, for example libphonenumber from Google. 

In terms of formatting, even if there are space, dash, brackets in your input JSON, e.g. "+1 (514) 333-8888", OneSpan Sign system will reformat your string and convert it to "+15143338888". If you use the libphonenumber I shared above, it should be able to output E164 format regardless of the input format.

 

Duo

 


Hello! Looks like you're enjoying the discussion, but haven't signed up for an account.

When you create an account, we remember exactly what you've read, so you always come right back where you left off