Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Re: Weird error with Cryprt::Blowfish and Crypt::DES

by gaal (Parson)
on Oct 20, 2004 at 18:15 UTC ( #400942=note: print w/replies, xml ) Need Help??

in reply to Weird error with Cryprt::Blowfish and Crypt::DES

Try adding a debug print in c, closer to where the croak happens?

CODE: { input = (char *) SvPV(ST(0), input_len); printf("handling %d bytes\n", input_len); if (input_len != 8) croak("input must be 8 bytes long");

Replies are listed 'Best First'.
Re^2: Weird error with Cryprt::Blowfish and Crypt::DES
by Beechbone (Friar) on Oct 21, 2004 at 10:40 UTC
    Ok, got a result. input_len is 12. At least it was 12 in the single test run we managed to complete before lunch. Next thing I'll try is:
    if (input_len != 8) { printf("blowfish_crypt(): handling %d bytes\n", input_len) +; printf("Bytes: "); for (i = 0; i < input_len; i++) { unsigned char a = (unsigned char) *(input + i); printf("%d ", a); } printf("\n"); croak("input must be 8 bytes long"); }
    But again I have to wait. Seems I'm the only person around who's not at lunch right now...

    PS: I know that my C code is ugly, but at least it works. ;-)

    Search, Ask, Know
Re^2: Weird error with Cryprt::Blowfish and Crypt::DES
by Beechbone (Friar) on Oct 20, 2004 at 18:33 UTC
    Not yet, (thanks for the syntax, my C is very weak ;)), we need someone with access to the compiler machine first...

    Hopefully tomorrow we can try it.


    We already know that input_len is not 8 bytes, so the exact value is not that important. Does anyone have C code to dump the complete SV? That would be much more useful, I'd say...

    Search, Ask, Know

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://400942]
[TCLion]: I am breaking down the line and putting the date in the correct order during output
[TCLion]: at least that's the plan
[1nickt]: Corion this looks good, from the pod: "there are 9000+ variations that are detected correctly in the test files (see t/data/* for most of them). If you can think of any that I do not cover, please let me know."
[TCLion]: some moron put the date like this : Mon Feb 20 09:31:30 2017
[Corion]: 1nickt: Yes, the module sounds promising indeed
[1nickt]: "putting the date in correct order" how?
[Corion]: TCLion: Whee ;)
[TCLion]: need to put like this : 2017-02-20 09:30:53
[1nickt]: That's why I asked if you are using DateTime. It has a large number of supporting modules (the author likes the term 'eco-system') so if you are already creating a DateTime obj from your dates, this module would read in the mnoron-formatted 1s seamlessly
[TCLion]: when I put the date together it looks like : 2017-Feb-24 (month is the problem)

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (14)
As of 2017-03-23 14:53 GMT
Find Nodes?
    Voting Booth?
    Should Pluto Get Its Planethood Back?

    Results (288 votes). Check out past polls.