Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 49ccd9487eafaadb1b8d76d728f3cac552e06590
Ticket: 3033307fffffffffffffffffffffffffffffffff
binary decode base64 breaks with trailing spaces
User & Date: a_kovalenko on 2010-07-23 00:54:42
Changes

  1. assignee changed to: "dkf"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    binary decode base64 "[binary encode base64 u]" => u, as expected
    binary decode base64 "[binary encode base64 u] " => empty 
    
    Trailing space characters cause inner loop to run 4 times in "post-data-end" branch, increasing "cut" value each time, with 3 output bytes only. Thus the last byte of previous data is thrown away incorrectly.
    
    Patch attached.
    
    The code is still too liberal, accepting illegal base64. It would be better to borrow a correct, well-tested implementation from somewhere else.
    
  4. foundin changed to: "obsolete: 8.6b1.1"
  5. is_private changed to: "0"
  6. priority changed to: "5 Medium"
  7. resolution changed to: "None"
  8. status changed to: "Open"
  9. submitter changed to: "a_kovalenko"
  10. subsystem changed to: "16. Commands A-H"
  11. title changed to: "binary decode base64 breaks with trailing spaces"
  12. type changed to: "Bug"