From: usa@... Date: 2015-12-08T02:51:56+00:00 Subject: [ruby-core:71928] [Ruby trunk - Bug #11760] Encoding is tainted unexpectedly by Marshal.load Issue #11760 has been updated by Usaku NAKAMURA. Backport changed from 2.0.0: REQUIRED, 2.1: REQUIRED, 2.2: REQUIRED to 2.0.0: REQUIRED, 2.1: DONE, 2.2: REQUIRED ruby_2_1 r52933 merged revision(s) 52856,52906. ---------------------------------------- Bug #11760: Encoding is tainted unexpectedly by Marshal.load https://bugs.ruby-lang.org/issues/11760#change-55333 * Author: Nobuyoshi Nakada * Status: Closed * Priority: Normal * Assignee: * ruby -v: r52850 * Backport: 2.0.0: REQUIRED, 2.1: DONE, 2.2: REQUIRED ---------------------------------------- By `Marshal.load`ing tainted source, `Encoding` object will be tainted. ## code to reproduce ~~~ruby e = Encoding::UTF_8 p e.tainted? p e == Marshal.load(Marshal.dump(e).taint) p e.tainted? ~~~ ## expected results `false`, `true`, and `false` ## actual results `false`, `true`, and `true` -- https://bugs.ruby-lang.org/