From 972f579a9841aaac917eb0d498fab22114167b1c Mon Sep 17 00:00:00 2001 From: kenjis Date: Tue, 4 Jan 2022 16:11:09 +0900 Subject: [PATCH 01/16] Merge pull request #5532 from kenjis/update-CHANGELOG-416 docs: add Security advisory in CHANGELOG.md --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index c2ea5e536da0..4d333c153241 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ [Full Changelog](https://github.com/codeigniter4/CodeIgniter4/compare/v4.1.5...v4.1.6) +**SECURITY** + +* *Deserialization of Untrusted Data* found in the ``old()`` function was fixed. See the [Security advisory](https://github.com/codeigniter4/CodeIgniter4/security/advisories/GHSA-w6jr-wj64-mc9x) for more information. + **Breaking Changes** * fix: Incorrect type `BaseBuilder::$tableName` by @kenjis in https://github.com/codeigniter4/CodeIgniter4/pull/5378 From e1f40c5e8de2481243fb3d623eb2882dacc72eab Mon Sep 17 00:00:00 2001 From: MGatner Date: Tue, 4 Jan 2022 10:17:50 -0500 Subject: [PATCH 02/16] Merge pull request #5537 from kenjis/fix-ug-changelog-416 docs: minor addition to changelogs/v4.1.6.rst and upgrade_416.rst --- user_guide_src/source/changelogs/v4.1.6.rst | 2 ++ user_guide_src/source/installation/upgrade_416.rst | 2 ++ 2 files changed, 4 insertions(+) diff --git a/user_guide_src/source/changelogs/v4.1.6.rst b/user_guide_src/source/changelogs/v4.1.6.rst index 5068d92a99f3..6993add513f9 100644 --- a/user_guide_src/source/changelogs/v4.1.6.rst +++ b/user_guide_src/source/changelogs/v4.1.6.rst @@ -65,3 +65,5 @@ And the following methods are deprecated: Bugs Fixed ********** + +See the repo's `CHANGELOG.md `_ for a complete list of bugs fixed. diff --git a/user_guide_src/source/installation/upgrade_416.rst b/user_guide_src/source/installation/upgrade_416.rst index 9fd585821740..f81dacf8ec79 100644 --- a/user_guide_src/source/installation/upgrade_416.rst +++ b/user_guide_src/source/installation/upgrade_416.rst @@ -17,6 +17,8 @@ Due to a bug fix, the Validation now might change the validation results when yo Breaking Enhancements ********************* +none. + Project Files ************* From 803442218be44f7daf61b22ec438e1e95cf0d4e9 Mon Sep 17 00:00:00 2001 From: kenjis Date: Wed, 5 Jan 2022 10:25:02 +0900 Subject: [PATCH 03/16] Merge pull request #5527 from paulbalandan/kint-4.1.1 Update modified Kint files in `ThirdParty` --- .../ThirdParty/Kint/Renderer/CliRenderer.php | 29 +++++++++++++++++-- .../ThirdParty/Kint/Renderer/RichRenderer.php | 15 ++++++++-- 2 files changed, 39 insertions(+), 5 deletions(-) diff --git a/system/ThirdParty/Kint/Renderer/CliRenderer.php b/system/ThirdParty/Kint/Renderer/CliRenderer.php index f86671ff1cf3..12b18d036b62 100644 --- a/system/ThirdParty/Kint/Renderer/CliRenderer.php +++ b/system/ThirdParty/Kint/Renderer/CliRenderer.php @@ -59,6 +59,15 @@ class CliRenderer extends TextRenderer */ public static $min_terminal_width = 40; + /** + * Which stream to check for VT100 support on windows. + * + * null uses STDOUT if it's defined + * + * @var null|resource + */ + public static $windows_stream = null; + protected static $terminal_width = null; protected $windows_output = false; @@ -69,8 +78,22 @@ public function __construct() { parent::__construct(); - if (!self::$force_utf8) { - $this->windows_output = KINT_WIN; + if (!self::$force_utf8 && KINT_WIN) { + if (!KINT_PHP72) { + $this->windows_output = true; + } else { + $stream = self::$windows_stream; + + if (!$stream && \defined('STDOUT')) { + $stream = STDOUT; + } + + if (!$stream) { + $this->windows_output = true; + } else { + $this->windows_output = !\sapi_windows_vt100_support($stream); + } + } } if (!self::$terminal_width) { @@ -153,7 +176,7 @@ protected function utf8ToWindows($string) { return \str_replace( ['┌', '═', '┐', '│', '└', '─', '┘'], - ["\xda", "\xdc", "\xbf", "\xb3", "\xc0", "\xc4", "\xd9"], + [' ', '=', ' ', '|', ' ', '-', ' '], $string ); } diff --git a/system/ThirdParty/Kint/Renderer/RichRenderer.php b/system/ThirdParty/Kint/Renderer/RichRenderer.php index 94b7f98ab71f..46a8827ded56 100644 --- a/system/ThirdParty/Kint/Renderer/RichRenderer.php +++ b/system/ThirdParty/Kint/Renderer/RichRenderer.php @@ -133,6 +133,9 @@ class RichRenderer extends Renderer public static $always_pre_render = false; + public static $js_nonce = null; + public static $css_nonce = null; + protected $plugin_objs = []; protected $expand = false; protected $force_pre_render = false; @@ -389,10 +392,18 @@ public function preRender() switch ($type) { case 'script': - $output .= ''; + $output .= '