Jump to content
Vodia PBX forum
Carlos Montemayor

Coma as an invalid character

Recommended Posts

Hi,

 

I just experienced a problem because I inadvertently used a coma within the name of a user. This provoked a major error during a billing process while reading a CSV. Since by definition a CSV uses a coma to separate fields, a coma should not be used within anything that can come up in a field of a file that can be obtained as an CSV, otherwise, one more field than expected is going to appear (the one created by the coma within a name). So, the improvement would be that the pbx would not allow the use of a coma in any parameter that can be a field of a file that can be obtained as an CSV fie. "invalid character" or something like that should kick back while attempting to save something that has a coma in such a box.

 

Regards

Share this post


Link to post
Share on other sites

Well. My particular error came with the name of a customer. As an example, imagine that my customer was SIEMENS AG, and that by mistake I entered: Siemens, AG (with a coma between the name and the business type (the Aktiengesellschaft, but abbreviated). The name, which was meant to be only one field, became two (one for Siemens and another one for the AG). Once this happened to me, I believe that I will never use a coma as part of a name, but I figured it could be helpful it were not allowed.

Share this post


Link to post
Share on other sites

Of course you can use a comma in the "display name" part of a SIP header, and also in other places. However I agree, there are lots of devices and services out there which have a problem processing it. For example, if you encode it correctly, CSV files can handle it properly but i many cases the names are just concatenated with commas, and then the CSV breaks.

 

If you want to have more fun, try the following names:

  • Martin "M" Meyer
  • <script>alert("hello");</script>

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×