VisaElectron card type validation in UtilValidate.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

VisaElectron card type validation in UtilValidate.java

rajsaini
Hi,

While integrating the payment gateway I found and issue with Visa
Electron card validation. On line 1153 in UtilValidte.java Visa Electron
cards, number is validated as:

    if ((cc.length() == 16) && (first6digs.equals("417500")))

Whereas the testing cards I have (also my real Visa Electron card) do
not have their first 6 digits as "417500". Has any one one else been to
similar situation? Any idea what should be the right CC number pattern?

Thanks,

Raj




Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

Scott Gray
Hi Raj

Wikipedia says it's these:
417500,4917,4913,4508,4844
http://en.wikipedia.org/wiki/Credit_card_numbers

Regards
Scott

2008/5/30 Raj Saini <[hidden email]>:

> Hi,
>
> While integrating the payment gateway I found and issue with Visa Electron
> card validation. On line 1153 in UtilValidte.java Visa Electron cards,
> number is validated as:
>
>   if ((cc.length() == 16) && (first6digs.equals("417500")))
>
> Whereas the testing cards I have (also my real Visa Electron card) do not
> have their first 6 digits as "417500". Has any one one else been to similar
> situation? Any idea what should be the right CC number pattern?
>
> Thanks,
>
> Raj
>
>
>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

rajsaini
Hi Scot,

Thanks for the info. Current validation only support cards starting with
417550. Should we not change the validation to support other variations?

Thanks,

Raj
Scott Gray wrote:

> Hi Raj
>
> Wikipedia says it's these:
> 417500,4917,4913,4508,4844
> http://en.wikipedia.org/wiki/Credit_card_numbers
>
> Regards
> Scott
>
> 2008/5/30 Raj Saini <[hidden email]>:
>
>  
>> Hi,
>>
>> While integrating the payment gateway I found and issue with Visa Electron
>> card validation. On line 1153 in UtilValidte.java Visa Electron cards,
>> number is validated as:
>>
>>   if ((cc.length() == 16) && (first6digs.equals("417500")))
>>
>> Whereas the testing cards I have (also my real Visa Electron card) do not
>> have their first 6 digits as "417500". Has any one one else been to similar
>> situation? Any idea what should be the right CC number pattern?
>>
>> Thanks,
>>
>> Raj
>>
>>
>>
>>
>>
>>    
>
>  

Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

Scott Gray
Sounds good to me so I'll do you a deal, you provide the patch and I'll
commit it :-)

Regards
Scott

2008/5/30 Raj Saini <[hidden email]>:

> Hi Scot,
>
> Thanks for the info. Current validation only support cards starting with
> 417550. Should we not change the validation to support other variations?
>
> Thanks,
>
> Raj
>
> Scott Gray wrote:
>
>> Hi Raj
>>
>> Wikipedia says it's these:
>> 417500,4917,4913,4508,4844
>> http://en.wikipedia.org/wiki/Credit_card_numbers
>>
>> Regards
>> Scott
>>
>> 2008/5/30 Raj Saini <[hidden email]>:
>>
>>
>>
>>> Hi,
>>>
>>> While integrating the payment gateway I found and issue with Visa
>>> Electron
>>> card validation. On line 1153 in UtilValidte.java Visa Electron cards,
>>> number is validated as:
>>>
>>>  if ((cc.length() == 16) && (first6digs.equals("417500")))
>>>
>>> Whereas the testing cards I have (also my real Visa Electron card) do not
>>> have their first 6 digits as "417500". Has any one one else been to
>>> similar
>>> situation? Any idea what should be the right CC number pattern?
>>>
>>> Thanks,
>>>
>>> Raj
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>
>>
>>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

rajsaini
Thanks Scott, I will do this.

Raj
Scott Gray wrote:

> Sounds good to me so I'll do you a deal, you provide the patch and I'll
> commit it :-)
>
> Regards
> Scott
>
> 2008/5/30 Raj Saini <[hidden email]>:
>
>  
>> Hi Scot,
>>
>> Thanks for the info. Current validation only support cards starting with
>> 417550. Should we not change the validation to support other variations?
>>
>> Thanks,
>>
>> Raj
>>
>> Scott Gray wrote:
>>
>>    
>>> Hi Raj
>>>
>>> Wikipedia says it's these:
>>> 417500,4917,4913,4508,4844
>>> http://en.wikipedia.org/wiki/Credit_card_numbers
>>>
>>> Regards
>>> Scott
>>>
>>> 2008/5/30 Raj Saini <[hidden email]>:
>>>
>>>
>>>
>>>      
>>>> Hi,
>>>>
>>>> While integrating the payment gateway I found and issue with Visa
>>>> Electron
>>>> card validation. On line 1153 in UtilValidte.java Visa Electron cards,
>>>> number is validated as:
>>>>
>>>>  if ((cc.length() == 16) && (first6digs.equals("417500")))
>>>>
>>>> Whereas the testing cards I have (also my real Visa Electron card) do not
>>>> have their first 6 digits as "417500". Has any one one else been to
>>>> similar
>>>> situation? Any idea what should be the right CC number pattern?
>>>>
>>>> Thanks,
>>>>
>>>> Raj
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>        
>>>
>>>      
>>    
>
>  

Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

Jacques Le Roux
Administrator
In reply to this post by rajsaini
Hi Raj,

Yes I will do soon (IIRC I wrote the line below)

Thanks

Jacques

From: "Raj Saini" <[hidden email]>

> Hi Scot,
>
> Thanks for the info. Current validation only support cards starting with
> 417550. Should we not change the validation to support other variations?
>
> Thanks,
>
> Raj
> Scott Gray wrote:
>> Hi Raj
>>
>> Wikipedia says it's these:
>> 417500,4917,4913,4508,4844
>> http://en.wikipedia.org/wiki/Credit_card_numbers
>>
>> Regards
>> Scott
>>
>> 2008/5/30 Raj Saini <[hidden email]>:
>>
>>  
>>> Hi,
>>>
>>> While integrating the payment gateway I found and issue with Visa Electron
>>> card validation. On line 1153 in UtilValidte.java Visa Electron cards,
>>> number is validated as:
>>>
>>>   if ((cc.length() == 16) && (first6digs.equals("417500")))
>>>
>>> Whereas the testing cards I have (also my real Visa Electron card) do not
>>> have their first 6 digits as "417500". Has any one one else been to similar
>>> situation? Any idea what should be the right CC number pattern?
>>>
>>> Thanks,
>>>
>>> Raj
>>>
>>>
>>>
>>>
>>>
>>>    
>>
>>  
>
Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

Jacques Le Roux
Administrator
In reply to this post by rajsaini
OK, so forget me :o)

Jacques

From: "Raj Saini" <[hidden email]>

> Thanks Scott, I will do this.
>
> Raj
> Scott Gray wrote:
>> Sounds good to me so I'll do you a deal, you provide the patch and I'll
>> commit it :-)
>>
>> Regards
>> Scott
>>
>> 2008/5/30 Raj Saini <[hidden email]>:
>>
>>  
>>> Hi Scot,
>>>
>>> Thanks for the info. Current validation only support cards starting with
>>> 417550. Should we not change the validation to support other variations?
>>>
>>> Thanks,
>>>
>>> Raj
>>>
>>> Scott Gray wrote:
>>>
>>>    
>>>> Hi Raj
>>>>
>>>> Wikipedia says it's these:
>>>> 417500,4917,4913,4508,4844
>>>> http://en.wikipedia.org/wiki/Credit_card_numbers
>>>>
>>>> Regards
>>>> Scott
>>>>
>>>> 2008/5/30 Raj Saini <[hidden email]>:
>>>>
>>>>
>>>>
>>>>      
>>>>> Hi,
>>>>>
>>>>> While integrating the payment gateway I found and issue with Visa
>>>>> Electron
>>>>> card validation. On line 1153 in UtilValidte.java Visa Electron cards,
>>>>> number is validated as:
>>>>>
>>>>>  if ((cc.length() == 16) && (first6digs.equals("417500")))
>>>>>
>>>>> Whereas the testing cards I have (also my real Visa Electron card) do not
>>>>> have their first 6 digits as "417500". Has any one one else been to
>>>>> similar
>>>>> situation? Any idea what should be the right CC number pattern?
>>>>>
>>>>> Thanks,
>>>>>
>>>>> Raj
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>        
>>>>
>>>>      
>>>    
>>
>>  
>
Reply | Threaded
Open this post in threaded view
|

custom ecommerce application

Eric DE MAULDE
In reply to this post by rajsaini
Hi,

I have read the FAQ "What is considered the best practice in creating a
custom web application with OFBiz ?"
I havn't very well understood the 3rd paragraph : which approach is linked
to "customizing an application" and "custom application" ?

My target : work with some custom ecommerce applications up-to-date
Are custom and up-to-date compatible ?

In both approachs, I start from scratch (I delete entity-resource in
applications/ecommerce/ofbiz-component.xml)

1st approach : I copy (with SVK) "applications/ecommerce" to
"specialpurpose/myFurnitureEcommerce"
                       I modify the files mentionned in the FAQ and I do
another changes
                       I pull (with SVK) from "applications/ecommerce" to
"specialpurpose/myFurnitureEcommerce" one or two times a month in order that
my application is up-to-date

2nd approach : Where can I copy the 5 files ? (just the files in the same
tree in "specialpurpose/...")
                        How can I manage the differences between two custom
ecommerce applications ?

Could you advice me ?
Could you detail the 3rd paragraph ?

Thanks

Eric

Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

rajsaini
In reply to this post by Scott Gray
I doubt Wikipedia information is complete. I have a  Visa Electron
(debit) card and its first four digits are 4027. Should I also include
this in validation?

Thanks,

Raj

Scott Gray wrote:

> Sounds good to me so I'll do you a deal, you provide the patch and I'll
> commit it :-)
>
> Regards
> Scott
>
> 2008/5/30 Raj Saini <[hidden email]>:
>
>  
>> Hi Scot,
>>
>> Thanks for the info. Current validation only support cards starting with
>> 417550. Should we not change the validation to support other variations?
>>
>> Thanks,
>>
>> Raj
>>
>> Scott Gray wrote:
>>
>>    
>>> Hi Raj
>>>
>>> Wikipedia says it's these:
>>> 417500,4917,4913,4508,4844
>>> http://en.wikipedia.org/wiki/Credit_card_numbers
>>>
>>> Regards
>>> Scott
>>>
>>> 2008/5/30 Raj Saini <[hidden email]>:
>>>
>>>
>>>
>>>      
>>>> Hi,
>>>>
>>>> While integrating the payment gateway I found and issue with Visa
>>>> Electron
>>>> card validation. On line 1153 in UtilValidte.java Visa Electron cards,
>>>> number is validated as:
>>>>
>>>>  if ((cc.length() == 16) && (first6digs.equals("417500")))
>>>>
>>>> Whereas the testing cards I have (also my real Visa Electron card) do not
>>>> have their first 6 digits as "417500". Has any one one else been to
>>>> similar
>>>> situation? Any idea what should be the right CC number pattern?
>>>>
>>>> Thanks,
>>>>
>>>> Raj
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>        
>>>
>>>      
>>    
>
>  

Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

Jacques Le Roux
Administrator
Yes, I think so. But maybe we could ask directly to Visa (in case there are more of them); or have a look into their site ?

Jacques

From: "Raj Saini" <[hidden email]>

>I doubt Wikipedia information is complete. I have a  Visa Electron
> (debit) card and its first four digits are 4027. Should I also include
> this in validation?
>
> Thanks,
>
> Raj
>
> Scott Gray wrote:
>> Sounds good to me so I'll do you a deal, you provide the patch and I'll
>> commit it :-)
>>
>> Regards
>> Scott
>>
>> 2008/5/30 Raj Saini <[hidden email]>:
>>
>>  
>>> Hi Scot,
>>>
>>> Thanks for the info. Current validation only support cards starting with
>>> 417550. Should we not change the validation to support other variations?
>>>
>>> Thanks,
>>>
>>> Raj
>>>
>>> Scott Gray wrote:
>>>
>>>    
>>>> Hi Raj
>>>>
>>>> Wikipedia says it's these:
>>>> 417500,4917,4913,4508,4844
>>>> http://en.wikipedia.org/wiki/Credit_card_numbers
>>>>
>>>> Regards
>>>> Scott
>>>>
>>>> 2008/5/30 Raj Saini <[hidden email]>:
>>>>
>>>>
>>>>
>>>>      
>>>>> Hi,
>>>>>
>>>>> While integrating the payment gateway I found and issue with Visa
>>>>> Electron
>>>>> card validation. On line 1153 in UtilValidte.java Visa Electron cards,
>>>>> number is validated as:
>>>>>
>>>>>  if ((cc.length() == 16) && (first6digs.equals("417500")))
>>>>>
>>>>> Whereas the testing cards I have (also my real Visa Electron card) do not
>>>>> have their first 6 digits as "417500". Has any one one else been to
>>>>> similar
>>>>> situation? Any idea what should be the right CC number pattern?
>>>>>
>>>>> Thanks,
>>>>>
>>>>> Raj
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>        
>>>>
>>>>      
>>>    
>>
>>  
>
Reply | Threaded
Open this post in threaded view
|

Re: VisaElectron card type validation in UtilValidate.java

rajsaini
Hi Jacques,

I tried on Visa Electron site. Did not find any thing.

I think I will create an issue and provide the patch for the know number
patterns. If we find more known supported numbers we can add them later.

Thanks,

Raj

Jacques Le Roux wrote:

> Yes, I think so. But maybe we could ask directly to Visa (in case
> there are more of them); or have a look into their site ?
>
> Jacques
>
> From: "Raj Saini" <[hidden email]>
>> I doubt Wikipedia information is complete. I have a  Visa Electron
>> (debit) card and its first four digits are 4027. Should I also
>> include this in validation?
>>
>> Thanks,
>>
>> Raj
>>
>> Scott Gray wrote:
>>> Sounds good to me so I'll do you a deal, you provide the patch and I'll
>>> commit it :-)
>>>
>>> Regards
>>> Scott
>>>
>>> 2008/5/30 Raj Saini <[hidden email]>:
>>>
>>>  
>>>> Hi Scot,
>>>>
>>>> Thanks for the info. Current validation only support cards starting
>>>> with
>>>> 417550. Should we not change the validation to support other
>>>> variations?
>>>>
>>>> Thanks,
>>>>
>>>> Raj
>>>>
>>>> Scott Gray wrote:
>>>>
>>>>    
>>>>> Hi Raj
>>>>>
>>>>> Wikipedia says it's these:
>>>>> 417500,4917,4913,4508,4844
>>>>> http://en.wikipedia.org/wiki/Credit_card_numbers
>>>>>
>>>>> Regards
>>>>> Scott
>>>>>
>>>>> 2008/5/30 Raj Saini <[hidden email]>:
>>>>>
>>>>>
>>>>>
>>>>>      
>>>>>> Hi,
>>>>>>
>>>>>> While integrating the payment gateway I found and issue with Visa
>>>>>> Electron
>>>>>> card validation. On line 1153 in UtilValidte.java Visa Electron
>>>>>> cards,
>>>>>> number is validated as:
>>>>>>
>>>>>>  if ((cc.length() == 16) && (first6digs.equals("417500")))
>>>>>>
>>>>>> Whereas the testing cards I have (also my real Visa Electron
>>>>>> card) do not
>>>>>> have their first 6 digits as "417500". Has any one one else been to
>>>>>> similar
>>>>>> situation? Any idea what should be the right CC number pattern?
>>>>>>
>>>>>> Thanks,
>>>>>>
>>>>>> Raj
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>        
>>>>>
>>>>>      
>>>>    
>>>
>>>  
>>
>

Reply | Threaded
Open this post in threaded view
|

Re: custom ecommerce application

BJ Freeman
In reply to this post by Eric DE MAULDE
the trunk version has a clone example that would be customizing not custom.


Eric DE MAULDE sent the following on 5/30/2008 3:08 AM:

> Hi,
>
> I have read the FAQ "What is considered the best practice in creating a
> custom web application with OFBiz ?"
> I havn't very well understood the 3rd paragraph : which approach is
> linked to "customizing an application" and "custom application" ?
>
> My target : work with some custom ecommerce applications up-to-date
> Are custom and up-to-date compatible ?
>
> In both approachs, I start from scratch (I delete entity-resource in
> applications/ecommerce/ofbiz-component.xml)
>
> 1st approach : I copy (with SVK) "applications/ecommerce" to
> "specialpurpose/myFurnitureEcommerce"
>                       I modify the files mentionned in the FAQ and I do
> another changes
>                       I pull (with SVK) from "applications/ecommerce" to
> "specialpurpose/myFurnitureEcommerce" one or two times a month in order
> that my application is up-to-date
>
> 2nd approach : Where can I copy the 5 files ? (just the files in the
> same tree in "specialpurpose/...")
>                        How can I manage the differences between two
> custom ecommerce applications ?
>
> Could you advice me ?
> Could you detail the 3rd paragraph ?
>
> Thanks
>
> Eric
>
>
>

Reply | Threaded
Open this post in threaded view
|

Re: custom ecommerce application

Eric DE MAULDE
I just found my respomse in tne previous FAQ point
2nd approach : After copying the 5 files
"then by simply copying/creating the files that need to be changed ...
controller.xml"

I read too the Widget article
Now I believe I can develop/use some different custom ecommerce applications



> the trunk version has a clone example that would be customizing not
> custom.
>
>
> Eric DE MAULDE sent the following on 5/30/2008 3:08 AM:
>> Hi,
>>
>> I have read the FAQ "What is considered the best practice in creating a
>> custom web application with OFBiz ?"
>> I havn't very well understood the 3rd paragraph : which approach is
>> linked to "customizing an application" and "custom application" ?
>>
>> My target : work with some custom ecommerce applications up-to-date
>> Are custom and up-to-date compatible ?
>>
>> In both approachs, I start from scratch (I delete entity-resource in
>> applications/ecommerce/ofbiz-component.xml)
>>
>> 1st approach : I copy (with SVK) "applications/ecommerce" to
>> "specialpurpose/myFurnitureEcommerce"
>>                       I modify the files mentionned in the FAQ and I do
>> another changes
>>                       I pull (with SVK) from "applications/ecommerce" to
>> "specialpurpose/myFurnitureEcommerce" one or two times a month in order
>> that my application is up-to-date
>>
>> 2nd approach : Where can I copy the 5 files ? (just the files in the
>> same tree in "specialpurpose/...")
>>                        How can I manage the differences between two
>> custom ecommerce applications ?
>>
>> Could you advice me ?
>> Could you detail the 3rd paragraph ?
>>
>> Thanks
>>
>> Eric
>>
>>
>>
>
>
>
>
> --
> No virus found in this incoming message.
> Checked by AVG.
> Version: 7.5.524 / Virus Database: 269.24.3/1472 - Release Date:
> 29/05/2008 07:27
>
>