fix: improve root user password check logic in ServerSecurity#2149
fix: improve root user password check logic in ServerSecurity#2149ExtReMLapin wants to merge 2 commits into
Conversation
| } | ||
|
|
||
| if (users.isEmpty() || (users.containsKey("root") && users.get("root").getPassword() == null)) | ||
| if (users.isEmpty() || !users.containsKey("root") || (users.containsKey("root") && users.get("root").getPassword() == null)) |
There was a problem hiding this comment.
I mean we could even remove users.isEmpty()
|
Forgot to run the CI tests oopsie woopsie |
|
hi, so, AFAIU, in this way when I restart arcade passing a new rootPassword, the previous one will be overwritten. |
Only if the user root has been removed manually editing the jsonl users file, unlike this PR where just passing as arg on boot changes it If it sounds safer to you feel free to edit the PR to add this check. However I feel like if the attacker already got
I fear the changes from this PR doesn't introduce any security exploit. All it does is allowing to set root password if it's not set. |
|
Before merging, I need some hints on how to tests this.
Is it right? |
|
moreover, how is this related to #2059 ? |
|
This can be related but more like an alternative proposed here #2058 (comment)
As you said
|
|
@robfrank What's the status of this issue? |
|
I'm coming back to this. I don't think it is good. Suppose to provide users/groups configuration without the root user: with this PR it is not possible anymore. At the first start a new root user if created. @lvca WDYT? |
|
I agree, if somebody decides to remove the root user, it shouldn't be created automatically at the next restart, unless root is internally needed for some reason, but I can't think of anything right now. |
|
Closing this PR not merging it. The user must be able to remove "root" as user. |
…[skip ci] Bumps [https://github.com/pycqa/isort](https://github.com/pycqa/isort) from 7.0.0 to 8.0.1. Release notes *Sourced from [https://github.com/pycqa/isort's releases](https://github.com/pycqa/isort/releases).* > 8.0.0 > ----- > > Changes > ------- > > * Update CHANGELOG for version 8.0.0 ([#2460](https://redirect.github.com/pycqa/isort/issues/2460)) [`@DanielNoord`](https://github.com/DanielNoord) > * Fix edge case of `__future__` import. ([#2458](https://redirect.github.com/pycqa/isort/issues/2458)) [`@skv0zsneg`](https://github.com/skv0zsneg) > * Fix the Plone profile to be compatible with black ([#2457](https://redirect.github.com/pycqa/isort/issues/2457)) [`@ale-rt`](https://github.com/ale-rt) > * typo fix ([#2450](https://redirect.github.com/pycqa/isort/issues/2450)) [`@jsta`](https://github.com/jsta) > * Remove the `setuptools` plugin ([#2427](https://redirect.github.com/pycqa/isort/issues/2427)) [`@DanielNoord`](https://github.com/DanielNoord) > * Turn some warnings into errors in test suite ([#2449](https://redirect.github.com/pycqa/isort/issues/2449)) [`@DanielNoord`](https://github.com/DanielNoord) > * chore: replace black with ruff in clean.sh ([#2448](https://redirect.github.com/pycqa/isort/issues/2448)) [`@joao-faria-dev`](https://github.com/joao-faria-dev) > * feat!: remove old finders flag and legacy finder logic ([#2446](https://redirect.github.com/pycqa/isort/issues/2446)) [`@joao-faria-dev`](https://github.com/joao-faria-dev) > * Fix whitespace insensitive check triggering on tabs ([#2437](https://redirect.github.com/pycqa/isort/issues/2437)) [`@robsdedude`](https://github.com/robsdedude) > * Fix line separator detection not considering form feed as white space ([#2436](https://redirect.github.com/pycqa/isort/issues/2436)) [`@robsdedude`](https://github.com/robsdedude) > * Fix [#1964](https://redirect.github.com/pycqa/isort/issues/1964): `lines_before_import` sometimes ignored ([#1965](https://redirect.github.com/pycqa/isort/issues/1965)) [`@robsdedude`](https://github.com/robsdedude) > * Remove reference to 3.9 in README ([#2434](https://redirect.github.com/pycqa/isort/issues/2434)) [`@DanielNoord`](https://github.com/DanielNoord) > > 🚀 Features > ----------------- > > * Ensure `multiprocessing.Pool` is always closed and joined ([#2442](https://redirect.github.com/pycqa/isort/issues/2442)) [`@DanielNoord`](https://github.com/DanielNoord) > > :construction\_worker: Continuous Integration > --------------------------------------------- > > * Simplify CI by putting similar steps into a single action file ([#2444](https://redirect.github.com/pycqa/isort/issues/2444)) [`@DanielNoord`](https://github.com/DanielNoord) > > 📦 Dependencies > ---------------------- > > * Bump actions/checkout from 5 to 6 in the github-actions group ([#2451](https://redirect.github.com/pycqa/isort/issues/2451)) @[dependabot[bot]](https://github.com/apps/dependabot) > * Bump astral-sh/setup-uv from 6 to 7 in the github-actions group ([#2441](https://redirect.github.com/pycqa/isort/issues/2441)) @[dependabot[bot]](https://github.com/apps/dependabot) Changelog *Sourced from [https://github.com/pycqa/isort's changelog](https://github.com/PyCQA/isort/blob/main/CHANGELOG.md).* > Changelog > ========= > > NOTE: isort follows the [semver](https://semver.org/) versioning standard. > Find out more about isort's release policy [here](https://pycqa.github.io/isort/docs/major_releases/release_policy). > > Releases > -------- > > ### Unreleased > > ### 8.0.0 February 19 2026 > > * Removed `--old-finders` and `--magic-placement` flags and `old_finders` configuration option. The legacy finder logic that relied on environment introspection has been removed ([#2445](https://redirect.github.com/pycqa/isort/issues/2445)) [`@joao-faria-dev`](https://github.com/joao-faria-dev) > * Update the `plone` profile to not clash with `black` ([#2456](https://redirect.github.com/pycqa/isort/issues/2456)) [`@ale-rt`](https://github.com/ale-rt) > > ### 6.1.0 October 1 2025 > > * Add python 3.14 classifier and badge ([#2409](https://redirect.github.com/pycqa/isort/issues/2409)) [`@staticdev`](https://github.com/staticdev) > * Drop use of non-standard pkg\_resources API ([#2405](https://redirect.github.com/pycqa/isort/issues/2405)) [`@dvarrazzo`](https://github.com/dvarrazzo) > > ### 6.0.1 Febuary 26 2025 > > * Add OSError handling in find\_imports\_in\_file ([#2331](https://redirect.github.com/pycqa/isort/issues/2331)) [`@kobarity`](https://github.com/kobarity) > > ### 6.0.0 January 27 2025 > > * Remove support for Python 3.8 ([#2327](https://redirect.github.com/pycqa/isort/issues/2327)) [`@DanielNoord`](https://github.com/DanielNoord) > * Python 3.13 support ([#2306](https://redirect.github.com/pycqa/isort/issues/2306)) [`@mayty`](https://github.com/mayty) > * Speed up exists\_case\_sensitive calls ([#2264](https://redirect.github.com/pycqa/isort/issues/2264)) [`@correctmost`](https://github.com/correctmost) > * Ensure that split\_on\_trailing\_comma works with as imports ([#2340](https://redirect.github.com/pycqa/isort/issues/2340)) [`@DanielNoord`](https://github.com/DanielNoord) > * Black profile: enable magic comma ([#2236](https://redirect.github.com/pycqa/isort/issues/2236)) [`@MrMino`](https://github.com/MrMino) > * Update line\_length and single\_line\_exclusions in google profile ([#2149](https://redirect.github.com/pycqa/isort/issues/2149)) [`@jagapiou`](https://github.com/jagapiou) > * Allow --diff to be used with --jobs ([#2302](https://redirect.github.com/pycqa/isort/issues/2302)) [`@mnakama`](https://github.com/mnakama) > * Fix wemake profile to have correct character limit ([#2241](https://redirect.github.com/pycqa/isort/issues/2241)) [`@sobolevn`](https://github.com/sobolevn) > * Fix sort\_reexports code mangling ([#2283](https://redirect.github.com/pycqa/isort/issues/2283)) [`@Helveg`](https://github.com/Helveg) > * Fix correct group by package tokenization ([#2136](https://redirect.github.com/pycqa/isort/issues/2136)) [`@glasnt`](https://github.com/glasnt) > > ### 5.13.2 December 13 2023 > > * Apply the bracket fix from issue [#471](https://redirect.github.com/pycqa/isort/issues/471) only for use\_parentheses=True ([#2184](https://redirect.github.com/pycqa/isort/issues/2184)) [`@bp72`](https://github.com/bp72) > * Confine pre-commit to stages ([#2213](https://redirect.github.com/pycqa/isort/issues/2213)) [`@davidculley`](https://github.com/davidculley) > * Fixed colors extras ([#2212](https://redirect.github.com/pycqa/isort/issues/2212)) [`@staticdev`](https://github.com/staticdev) > > ### 5.13.1 December 11 2023 > > * Fixed integration tests ([#2208](https://redirect.github.com/pycqa/isort/issues/2208)) [`@bp72`](https://github.com/bp72) > * Fixed normalizing imports from more than one level of parent modules (issue/2152) ([#2191](https://redirect.github.com/pycqa/isort/issues/2191)) [`@bp72`](https://github.com/bp72) > * Remove optional dependencies without extras ([#2207](https://redirect.github.com/pycqa/isort/issues/2207)) [`@staticdev`](https://github.com/staticdev) > > ### 5.13.0 December 9 2023 ... (truncated) Commits * [`a333737`](PyCQA/isort@a333737) Merge pull request [#2463](https://redirect.github.com/pycqa/isort/issues/2463) from FinlayTheBerry/issue/2461 * [`878ba7e`](PyCQA/isort@878ba7e) Added compression to stdlibs for Python 3.14 in isort/stdlibs/py314.py * [`b5f06a7`](PyCQA/isort@b5f06a7) Merge pull request [#2459](https://redirect.github.com/pycqa/isort/issues/2459) from Fridayai700/fix-unindented-comment-corruption * [`3459bde`](PyCQA/isort@3459bde) Merge pull request [#2460](https://redirect.github.com/pycqa/isort/issues/2460) from PyCQA/DanielNoord-patch-1 * [`6e70bb6`](PyCQA/isort@6e70bb6) Update CHANGELOG for version 8.0.0 * [`fd2514b`](PyCQA/isort@fd2514b) Fix unindented comments being corrupted in indented blocks * [`b0f2dab`](PyCQA/isort@b0f2dab) Merge pull request [#2458](https://redirect.github.com/pycqa/isort/issues/2458) from skv0zsneg/issue/1882 * [`313797b`](PyCQA/isort@313797b) Fix lint. * [`7d3a6f5`](PyCQA/isort@7d3a6f5) Add ignore for cyclomatic complexity check. * [`6b9f895`](PyCQA/isort@6b9f895) Remove debug prints. * Additional commits viewable in [compare view](PyCQA/isort@7.0.0...8.0.1) [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- Dependabot commands and options You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
as proposed there : #2058 (comment)
Issue is that is we have at least one user registered it will not try to recreate root because the current contition doesn't allow it
this pr fixes it
Thanks to Tom Krawczyk for helping us find this bug.