Pan Number Right Most Digits/ ISO-0 Pin Block Format

712 views
Skip to first unread message

7Sigma

unread,
Dec 20, 2006, 12:35:19 AM12/20/06
to jPOS Users
hi,
The ISO-0 PIn Block format , specifies that the PAN number used for
generating the PIN-Block Format are the right most 12 digits from the
exisitng passed PAN string.

Lets say an example
PAN Number is "111222333444555"
In the java code EncryptedPin.java the method extractAccountNumberPart
will generate the output as : -
122233344455

but i think the output should be 222333444555
Please guide me if i went wrong !
I have made a modification in the existing method as described below
accountNumberPart = accountNumber.substring(accountNumber.length() -
12,accountNumber.length());
which was actually
accountNumberPart = accountNumber.substring(accountNumber.length() -
13,accountNumber.length()-1);

please guide me in this regard
thanks

Mohit

Alwyn Schoeman

unread,
Dec 20, 2006, 1:13:41 AM12/20/06
to jpos-...@googlegroups.com
Aren't a PAN 12 digits by definition?
--
Alwyn Schoeman

Alwyn Schoeman

unread,
Dec 20, 2006, 1:14:08 AM12/20/06
to jpos-...@googlegroups.com
Sorry, too early in the morning :) I see mine is 16
--
Alwyn Schoeman

7Sigma

unread,
Dec 20, 2006, 1:36:39 AM12/20/06
to jPOS Users
hi,
many standards do define PAN as 12 digit number, but as far as i know
it isn't a rule of format follwed everywhere in the world.For this very
reason we have LLVAR pattern followed in the specification defination
for data field number 2 (PAN) in most of the ISO 8583 based variants.In
Amex the max length that can be assigned is 19. usually the first four
digit in the credit card provides information related to the CARD
Scheme provider.

Mark Salter

unread,
Dec 20, 2006, 1:53:09 AM12/20/06
to jpos-...@googlegroups.com
7Sigma wrote:
>
> hi,
> The ISO-0 PIn Block format , specifies that the PAN number used for
> generating the PIN-Block Format are the right most 12 digits from the
> exisitng passed PAN string.
Hopefully the specification says you should use the last 12 digits
*excluding* the check digit (the last number), or words to that effect.

>
> Lets say an example
> PAN Number is "111222333444555"
> In the java code EncryptedPin.java the method extractAccountNumberPart
> will generate the output as : -
> 122233344455

I think that is correct?

>
> but i think the output should be 222333444555
> Please guide me if i went wrong !

Was there originally a problem that caused you to examine this code?

With your amendments in place did you successfully exchange PIN blocks
with another system?

--
Mark

7Sigma

unread,
Dec 20, 2006, 2:17:24 AM12/20/06
to jPOS Users
thanks Mark, Ya after making those minor changes i was able to exchange
PIN Blocks.
I think i need to study this right most truncation and relation with
check digits in more details though the changes i made gave the desired
result in present case. The last number as you mentioned is the check
digit so it should be excluded.
i will let you know my observations if there is actually a change
required.
thanks
Mohit

7Sigma

unread,
Dec 20, 2006, 2:30:00 AM12/20/06
to jPOS Users
hi,
well i think the problem actually came cause of the specifications of
the ISO-0 Pin block format which doesn't say specify the relationship
with exclusion of the check digit where else many of the pin blocks
specifications do specify it .
thanks
mohit

Reply all
Reply to author
Forward
0 new messages