in reply to Re^3: line by line Encryption fun with Crypt::CBC and Rijndael? File Ownership issues? (code)
in thread line by line Encryption fun with Crypt::CBC and Rijndael? File Ownership issues?
The call to SUB read_uint32 works fine the first time and the value of $to_read = 4 in SUB read_bytes. Inside SUB read_bytes in the while ($to_read) loop, the value of $buf = 'Rand' (the first 4 characters in my encrypted file).
Once SUB read_unit32 returns control to SUB read_str, the value of $length is set at some large number. I get an error during the call: read_bytes($fh, $length).
It attempts to read $length the first time around, so say length = 825373492 was passed to read_bytes. Then, to_read = 825373492 The first iteration through the while loop decrements $to_read as below: WHILE to_read = 825370130
However, in the next iteration I get the error.13:05:54 ERROR ***** 13:05:54 Unexpected end of file
Could you please help or guide me in the right direction? I apologize if my elaborating the problem in this way causes problems. I wasn't sure on how else to do it. Thanks, Sam
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: line by line Encryption fun with Crypt::CBC and Rijndael? File Ownership issues? (code)
by ikegami (Patriarch) on Jul 25, 2008 at 02:38 UTC | |
by samip (Novice) on Jul 25, 2008 at 17:07 UTC | |
by ikegami (Patriarch) on Jul 26, 2008 at 13:25 UTC | |
by samip (Novice) on Jul 31, 2008 at 14:57 UTC | |
by ikegami (Patriarch) on Jul 31, 2008 at 20:30 UTC | |
|