114 Commits

Author SHA1 Message Date
kenjis
7e8ff9d0e9
Merge remote-tracking branch 'upstream/develop' into 4.3 2022-10-30 22:34:25 +09:00
John Paul E. Balandan, CPA
72412cf77a
Trim whitespace in preserveGlobalState 2022-10-30 18:52:50 +08:00
John Paul E. Balandan, CPA
862f8832d5
Group runInSeparateProcess and preserveGlobalState 2022-10-30 18:50:07 +08:00
kenjis
763a5d94df
Merge remote-tracking branch 'upstream/develop' into 4.3 2022-10-20 16:47:58 +09:00
kenjis
811c4a7306
fix: bug that esc() accepts invalid context '0' 2022-10-20 10:55:18 +09:00
kenjis
57ab3de4f8
feat: add request() and response() 2022-09-10 17:54:16 +09:00
MGatner
c9eb3d511c
Merge branch 'develop' into 4.3 2022-09-04 23:49:32 +00:00
John Paul E. Balandan, CPA
eb440742eb
Apply formatting fixes 2022-09-03 19:44:54 +08:00
kenjis
f6c254a24e
feat: you can set locale manually to route_to() 2022-08-29 11:09:10 +09:00
kenjis
ca9f78786f
test: fix sessionSavePath values 2022-07-02 18:16:24 +09:00
kenjis
765c6cd1cb
test: add test for lang() error on CLI 2022-06-30 17:39:33 +09:00
kenjis
310697094d
test: refactor tests 2022-06-30 17:34:55 +09:00
kenjis
e49c0bd41f
refactor: run rector and fix types 2022-06-28 09:11:12 +09:00
kenjis
f211714cfd
test: replace public with private 2022-06-28 07:08:19 +09:00
kenjis
917597d574
refactor: run rector 2022-06-27 18:24:58 +09:00
kenjis
fbd632d0bb
Merge pull request #6058 from paulbalandan/slash-item
Fix `slash_item()` erroring when property fetched does not exist on `Config\App`
2022-06-03 05:58:41 +09:00
John Paul E. Balandan, CPA
42563c2c82
Finish fix 2022-06-02 11:23:27 +08:00
kenjis
d777cee7eb
refactor: remove CodeIgniter\Services
It seems it is not needed.
2022-05-31 11:29:05 +09:00
Alexandr Toropov
43beea215e fix: unit test 2022-05-28 23:17:47 +03:00
kenjis
deb9f3d2c7
test: add @group SeparateProcess 2022-05-05 22:01:03 +09:00
Abdul Malik Ikhsan
f8ed66d524
re-run rector 0.12.22 locally 2022-04-29 00:07:19 +07:00
Abdul Malik Ikhsan
0176bb4224
exclude native classes 2022-03-21 01:40:53 +07:00
Abdul Malik Ikhsan
4f97aac344
[Rector] Clean up skip config and re-run Rector 2022-03-19 23:30:10 +07:00
kenjis
cae9f89410
test: update Kint CSP tests 2022-02-05 13:55:03 +09:00
kenjis
b416ddbb28
refactor: use Kint 4.1 CSP nonce functionality 2022-02-05 13:23:57 +09:00
kenjis
5a845e63f9
test: improve slow test 2022-01-12 21:27:11 +09:00
kenjis
1184046f67
test: use more specific assert method 2022-01-12 09:15:54 +09:00
kenjis
4b8b118daa
test: remove unneeded $this->resetFactories()
It is called in CIUnitTestCase::setUp() via $setUpMethods.
2022-01-12 09:15:53 +09:00
kenjis
9ece590bd3
refactor: use Services::contentsecuritypolicy() 2022-01-12 09:15:52 +09:00
kenjis
bc52fad667
refactor: use csp_script_nonce() and csp_script_nonce() in Kint 2022-01-12 09:15:51 +09:00
kenjis
7a75b89b8b
feat: add csp_style_nonce() and csp_script_nonce() 2022-01-12 09:15:51 +09:00
MGatner
ce95ed5765
Merge pull request from GHSA-w6jr-wj64-mc9x
fix: Deserialization of Untrusted Data in old()
2022-01-03 18:51:05 -05:00
kenjis
9c379088e8
test: add tests for Kint with CSP 2021-12-27 11:37:44 +09:00
kenjis
78e4b27a16
test: add test for serialize data 2021-12-09 10:08:46 +09:00
kenjis
7c69140b65
docs: remove out-of-dated comment 2021-12-09 10:08:46 +09:00
kenjis
18138fa4c7
fix: remove unserialize() in old()
I can't think of any use cases.
2021-12-09 10:08:46 +09:00
kenjis
fd72e192cb
test: fix setUp() 2021-12-08 10:12:38 +09:00
John Paul E. Balandan, CPA
ee2b89481b
Fix wrong helper path resolution 2021-10-27 11:57:21 +08:00
kenjis
26e0025df9
Fix CSRF filter does not work when set it to only post
* refactor: case the existence of config files with if statements

To make it easier to know which parts to delete in the future.

* docs: fix PHPDoc explanation

* fix: bug that CSRF cookie is not sent just by calling csrf_hash()

When the CSRF filter was set to POST method, it did not work.

* refactor: replace deprecated method getHeader()

* refactor: extract method

* refactor: extract method

* refactor: extract method

* refactor: use $this->hash instead of $_COOKIE

* test: fix the timing for setting superglobals

* test: fix Cannot modify header information

ErrorException: Cannot modify header information - headers already sent by ...

* style: vendor/bin/rector process

* refactor: ensure instance

It becomes clear that it is `SecurityConfig`.

Co-authored-by: Abdul Malik Ikhsan <samsonasik@gmail.com>

* refactor: ensure instance

It becomes clear that it is `CookieConfig`.

Co-authored-by: Abdul Malik Ikhsan <samsonasik@gmail.com>

* refactor: when $cookie is null, Cookie::setDefaults($cookie) does nothing

* refactor: extract method

* fix: make private extracted methods

* fix: make private added property

* fix: fallback to the local properties

Takes care when a user removes properties in config classes.

* refactor: use $request instead of $_POST

Co-authored-by: Abdul Malik Ikhsan <samsonasik@gmail.com>
2021-10-16 23:11:01 +08:00
John Paul E. Balandan, CPA
b7ec33cd56
Remove superfluous phpdoc tags (#4941) 2021-07-24 19:30:51 +08:00
John Paul E. Balandan, CPA
0ee2b2f922
Add file-level headers 2021-07-19 23:04:56 +08:00
John Paul E. Balandan, CPA
308d0bed2d
Enable explicit_indirect_variable (#4881) 2021-06-28 22:10:44 +08:00
John Paul E. Balandan, CPA
2d11584a0e
Strive for stricter assertions 2021-06-27 00:49:59 +08:00
John Paul E. Balandan, CPA
04874954ee
Simplify mocks used 2021-06-25 22:45:13 +08:00
John Paul E. Balandan, CPA
224f347996
Normalize tests to use dedicated PHPUnit assertions 2021-06-25 22:34:50 +08:00
John Paul E. Balandan, CPA
7e4e56c72a
Test classes should be marked as final and internal 2021-06-25 22:27:37 +08:00
Abdul Malik Ikhsan
398b329cd7
[Rector] Apply Rector: RemoveUnusedVariableAssignRector 2021-06-24 16:02:52 +07:00
John Paul E. Balandan, CPA
1b0fa3507c
All instances created with new keyword must be followed by braces. 2021-06-19 01:31:47 +08:00
John Paul E. Balandan, CPA
57f5cd8bef
Enable method_chaining_indentation fixer 2021-06-17 21:35:32 +08:00
John Paul E. Balandan, CPA
a0dca3d5ba
Enable method_argument_space fixer 2021-06-17 21:24:27 +08:00