-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
prevent the Logger from writing sensitive values #143
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
name: Integration | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- '.github/workflows/integration.yml' | ||
- 'appinfo/**' | ||
- 'lib/**' | ||
- 'tests/**' | ||
|
||
push: | ||
branches: | ||
- master | ||
- stable* | ||
|
||
env: | ||
APP_NAME: sharepoint | ||
|
||
jobs: | ||
sqlite: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
# do not stop on another job's failure | ||
fail-fast: false | ||
matrix: | ||
php-versions: ['7.4', '8.0', '8.1'] | ||
databases: ['sqlite'] | ||
server-versions: ['master'] | ||
|
||
name: integration-php${{ matrix.php-versions }}-${{ matrix.databases }} | ||
|
||
steps: | ||
- name: Checkout server | ||
uses: actions/checkout@v2 | ||
with: | ||
repository: nextcloud/server | ||
ref: ${{ matrix.server-versions }} | ||
|
||
- name: Checkout submodules | ||
shell: bash | ||
run: | | ||
auth_header="$(git config --local --get http.https://github.com/.extraheader)" | ||
git submodule sync --recursive | ||
git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1 | ||
- name: Checkout app | ||
uses: actions/checkout@v2 | ||
with: | ||
path: apps/${{ env.APP_NAME }} | ||
|
||
- name: Set up php ${{ matrix.php-versions }} | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: ${{ matrix.php-versions }} | ||
extensions: mbstring, iconv, fileinfo, intl, sqlite, pdo_sqlite | ||
ini-values: zend.exception_ignore_args=Off | ||
coverage: none | ||
|
||
- name: Install app dependencies | ||
working-directory: apps/${{ env.APP_NAME }} | ||
run: composer i | ||
|
||
- name: Install test dependencies | ||
working-directory: apps/${{ env.APP_NAME }}/tests/Integration | ||
run: composer i | ||
|
||
- name: Set up Nextcloud | ||
env: | ||
DB_PORT: 4444 | ||
run: | | ||
mkdir data | ||
./occ maintenance:install --verbose --database=${{ matrix.databases }} --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin | ||
php -f index.php | ||
./occ app:enable files_external | ||
./occ app:enable --force ${{ env.APP_NAME }} | ||
php -S localhost:8080 & | ||
- name: Integration | ||
working-directory: apps/${{ env.APP_NAME }}/tests/Integration | ||
run: bash run.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
composer.phar | ||
/vendor/ | ||
vendor/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"config": { | ||
"platform": { | ||
"php": "7.4" | ||
} | ||
}, | ||
"require-dev": { | ||
"behat/behat": "^3.11", | ||
"jarnaiz/behat-junit-formatter": "^1.3", | ||
"guzzlehttp/guzzle": "^7.4" | ||
} | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seeing both paths being in the same namespace, does it make sense to allow giving class names only or even namespaces only?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both might be too broad in other cases.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well that's why I meant "Allow", but yeah then let's keep it like this.
I just fear the moment they change an internal method name or something and it logs again
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Absolutely. But that can happen to namespaces as well as class names (also happened in this lib in the past).
The only sustainable solution will arrive with PHP 8.2's sensitive parameter support.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nickvergessen added an integrattion test that should act as safeguard nevertheless