06-07-2020, 08:31 PM
Not knowing C or C++ but pretty good at matlab, I've managed to take the code shown earlier and created a matlab version so I can create the dictionaries for GVN589 and 599. It was a struggle dealing with some of the 128 bit operations and deciphering all the weird C code, but it now matches the outputs upto intmax.
PM if you want a copy of the code. Here's a teaser:
function psk=genpass589(x)
ATT_NVG5XX_PSK_LEN=13;
CHARSET = 'abcdefghijkmnpqrstuvwxyz23456789#%+=?';
y=x;
y=y+bitshift(y,31);
y=psk_rounding(y);
y=int128_product_shift(y); %128 bit integers
y=psk_rounding(y); %back to 64 bits
one=bitshift(y,-1);
two=one;
for i=0:5
key1=CHARSET(1+mod(two,37));
two=bin_divide(two);
key2=char(50+mod(two,8));
two=bin_divide(two);
psk(11-(i*2)+1)=key1;
psk(11-(i*2))=key2;
end
PM if you want a copy of the code. Here's a teaser:
function psk=genpass589(x)
ATT_NVG5XX_PSK_LEN=13;
CHARSET = 'abcdefghijkmnpqrstuvwxyz23456789#%+=?';
y=x;
y=y+bitshift(y,31);
y=psk_rounding(y);
y=int128_product_shift(y); %128 bit integers
y=psk_rounding(y); %back to 64 bits
one=bitshift(y,-1);
two=one;
for i=0:5
key1=CHARSET(1+mod(two,37));
two=bin_divide(two);
key2=char(50+mod(two,8));
two=bin_divide(two);
psk(11-(i*2)+1)=key1;
psk(11-(i*2))=key2;
end