Drop PHP 7.4 on mastertags/v26.0.0beta1
@@ -7,7 +7,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: checkers | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
commands: | |||
- ./autotest-checkers.sh | |||
secrets: [ github_token ] | |||
@@ -30,12 +30,12 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: litmus-v1 | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php8.0:latest | |||
commands: | |||
- bash tests/travis/install.sh sqlite | |||
- bash apps/dav/tests/travis/litmus-v1/script.sh | |||
- name: litmus-v2 | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php8.0:latest | |||
commands: | |||
- bash tests/travis/install.sh sqlite | |||
- bash apps/dav/tests/travis/litmus-v2/script.sh | |||
@@ -58,7 +58,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: caldavtester-new-endpoint | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php8.0:latest | |||
commands: | |||
- bash tests/travis/install.sh sqlite | |||
- bash apps/dav/tests/travis/caldav/install.sh | |||
@@ -82,7 +82,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: caldavtester-old-endpoint | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php8.0:latest | |||
commands: | |||
- bash tests/travis/install.sh sqlite | |||
- bash apps/dav/tests/travis/caldav/install.sh | |||
@@ -106,7 +106,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: carddavtester-new-endpoint | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php8.0:latest | |||
commands: | |||
- bash tests/travis/install.sh sqlite | |||
- bash apps/dav/tests/travis/carddav/install.sh | |||
@@ -130,7 +130,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: carddavtester-old-endpoint | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-litmus-php8.0:latest | |||
commands: | |||
- bash tests/travis/install.sh sqlite | |||
- bash apps/dav/tests/travis/carddav/install.sh | |||
@@ -153,8 +153,8 @@ steps: | |||
image: ghcr.io/nextcloud/continuous-integration-alpine-git:latest | |||
commands: | |||
- git submodule update --init | |||
- name: sqlite-php7.4-samba-native | |||
image: ghcr.io/nextcloud/continuous-integration-samba-native-php7.4:latest | |||
- name: sqlite-php8.0-samba-native | |||
image: ghcr.io/nextcloud/continuous-integration-samba-native-php8.0:latest | |||
commands: | |||
- smbd -D -FS & | |||
- ./autotest-external.sh sqlite smb-linux | |||
@@ -164,8 +164,8 @@ steps: | |||
- sh -c "if [ '$DRONE_BUILD_EVENT' = 'pull_request' ]; then bash codecov.sh -B $DRONE_BRANCH -C $DRONE_COMMIT -P $DRONE_PULL_REQUEST -t 117641e2-a9e8-4b7b-984b-ae872d9b05f5 -f tests/autotest-external-clover-sqlite-smb-linux.xml; fi" | |||
- sh -c "if [ '$DRONE_BUILD_EVENT' != 'pull_request' ]; then bash codecov.sh -B $DRONE_BRANCH -C $DRONE_COMMIT -t 117641e2-a9e8-4b7b-984b-ae872d9b05f5 -f tests/autotest-external-clover-sqlite-smb-linux.xml; fi" | |||
# Temporarily disabled because it times out for unknown reasons 98% of the time | |||
#- name: sqlite-php7.4-samba-non-native | |||
# image: ghcr.io/nextcloud/continuous-integration-samba-non-native-php7.4:latest | |||
#- name: sqlite-php8.0-samba-non-native | |||
# image: ghcr.io/nextcloud/continuous-integration-samba-non-native-php8.0:latest | |||
# commands: | |||
# - smbd -D -FS & | |||
# - ./autotest-external.sh sqlite smb-linux | |||
@@ -185,15 +185,15 @@ trigger: | |||
--- | |||
kind: pipeline | |||
name: sqlite-php7.4-webdav-apache | |||
name: sqlite-php8.0-webdav-apache | |||
steps: | |||
- name: submodules | |||
image: ghcr.io/nextcloud/continuous-integration-alpine-git:latest | |||
commands: | |||
- git submodule update --init | |||
- name: sqlite-php7.4-webdav-apache | |||
image: ghcr.io/nextcloud/continuous-integration-webdav-apache-php7.4:latest | |||
- name: sqlite-php8.0-webdav-apache | |||
image: ghcr.io/nextcloud/continuous-integration-webdav-apache-php8.0:latest | |||
commands: | |||
- apache2ctl start | |||
- ./autotest-external.sh sqlite webdav-apachedrone | |||
@@ -224,11 +224,6 @@ steps: | |||
image: ghcr.io/nextcloud/continuous-integration-alpine-git:latest | |||
commands: | |||
- git submodule update --init | |||
- name: nodb-php7.4 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
commands: | |||
- bash tests/drone-run-php-tests.sh || exit 0 | |||
- NOCOVERAGE=true TEST_SELECTION=NODB ./autotest.sh sqlite | |||
- name: nodb-php8.0 | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
commands: | |||
@@ -256,11 +251,6 @@ steps: | |||
image: ghcr.io/nextcloud/continuous-integration-alpine-git:latest | |||
commands: | |||
- git submodule update --init | |||
- name: sqlite-php7.4 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
commands: | |||
- bash tests/drone-run-php-tests.sh || exit 0 | |||
- NOCOVERAGE=true TEST_SELECTION=DB ./autotest.sh sqlite | |||
- name: sqlite-php8.0 | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
commands: | |||
@@ -281,15 +271,15 @@ trigger: | |||
--- | |||
kind: pipeline | |||
name: mariadb10.2-php7.4 | |||
name: mariadb10.2-php8.0 | |||
steps: | |||
- name: submodules | |||
image: ghcr.io/nextcloud/continuous-integration-alpine-git:latest | |||
commands: | |||
- git submodule update --init | |||
- name: mariadb10.2-php7.4 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
- name: mariadb10.2-php8.0 | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-php-tests.sh || exit 0 | |||
- NOCOVERAGE=true TEST_SELECTION=DB ./autotest.sh mariadb | |||
@@ -395,15 +385,15 @@ trigger: | |||
--- | |||
kind: pipeline | |||
name: mysql8.0-php7.4 | |||
name: mysql8.0-php8.0 | |||
steps: | |||
- name: submodules | |||
image: ghcr.io/nextcloud/continuous-integration-alpine-git:latest | |||
commands: | |||
- git submodule update --init | |||
- name: mysql-php7.4 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
- name: mysql-php8.0 | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-php-tests.sh || exit 0 | |||
- NOCOVERAGE=true TEST_SELECTION=DB ./autotest.sh mysql | |||
@@ -434,15 +424,15 @@ trigger: | |||
--- | |||
kind: pipeline | |||
name: postgres10-php7.4 | |||
name: postgres10-php8.0 | |||
steps: | |||
- name: submodules | |||
image: ghcr.io/nextcloud/continuous-integration-alpine-git:latest | |||
commands: | |||
- git submodule update --init | |||
- name: postgres-php7.4 | |||
image: ghcr.io/nextcloud/continuous-integration-php7.4:php7.4-3 | |||
- name: postgres-php8.0 | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-php-tests.sh || exit 0 | |||
- sleep 10 # gives the database enough time to initialize | |||
@@ -470,15 +460,15 @@ trigger: | |||
--- | |||
kind: pipeline | |||
name: postgres11-php7.4 | |||
name: postgres11-php8.0 | |||
steps: | |||
- name: submodules | |||
image: ghcr.io/nextcloud/continuous-integration-alpine-git:latest | |||
commands: | |||
- git submodule update --init | |||
- name: postgres-php7.4 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
- name: postgres-php8.0 | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-php-tests.sh || exit 0 | |||
- sleep 10 # gives the database enough time to initialize | |||
@@ -586,7 +576,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-capabilities_features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -611,7 +601,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-collaboration_features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -636,7 +626,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-federation_features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin | |||
@@ -661,7 +651,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-auth | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -686,7 +676,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-avatar | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -711,7 +701,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-maintenance-mode | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -736,7 +726,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-ratelimiting | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -771,7 +761,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-carddav | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -796,7 +786,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-dav-v2 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -821,7 +811,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-ocs-v1 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -846,7 +836,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-checksums-v1 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -871,7 +861,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-external-storage | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -896,7 +886,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-provisioning-v1 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -921,7 +911,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-tags | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -946,7 +936,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-caldav | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -971,7 +961,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-comments | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -996,7 +986,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-comments-search | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1021,7 +1011,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-contacts-menu | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1046,7 +1036,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-favorites | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1071,7 +1061,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-provisioning-v2 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1096,7 +1086,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-webdav-related | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1121,7 +1111,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-sharees-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1146,7 +1136,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-sharees-v2-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1171,7 +1161,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-sharing-v1 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1196,7 +1186,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-sharing-v1-part2 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1221,7 +1211,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-sharing-v1-part3 | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1252,7 +1242,7 @@ steps: | |||
# build them. | |||
- git clone --depth 1 https://github.com/nextcloud/spreed apps/spreed | |||
- name: integration-sharing-v1-video-verification | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1277,7 +1267,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-setup-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- cd build/integration | |||
@@ -1301,7 +1291,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-filesdrop-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1326,7 +1316,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-transfer-ownership-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1351,7 +1341,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-ldap-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1376,7 +1366,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-ldap-openldap-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1417,7 +1407,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-ldap-openldap-uid-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1459,7 +1449,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-ldap-openldap-numerical-id-features | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1500,7 +1490,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-trashbin | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1525,7 +1515,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-remote-api | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1550,7 +1540,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: integration-download | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php8.0:latest | |||
commands: | |||
- bash tests/drone-run-integration-tests.sh || exit 0 | |||
- ./occ maintenance:install --admin-pass=admin --data-dir=/dev/shm/nc_int | |||
@@ -1575,7 +1565,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-access-levels | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-access-levels --selenium-server selenium:4444 allow-git-repository-modifications features/access-levels.feature | |||
@@ -1605,7 +1595,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-app-files | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-app-files --selenium-server selenium:4444 allow-git-repository-modifications features/app-files.feature | |||
@@ -1635,7 +1625,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-app-files-sharing | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-app-files-sharing --selenium-server selenium:4444 allow-git-repository-modifications features/app-files-sharing.feature | |||
@@ -1665,7 +1655,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-app-files-sharing-link | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-app-files-sharing-link --selenium-server selenium:4444 allow-git-repository-modifications features/app-files-sharing-link.feature | |||
@@ -1695,7 +1685,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-app-files-tags | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-app-files-tags --selenium-server selenium:4444 allow-git-repository-modifications features/app-files-tags.feature | |||
@@ -1725,7 +1715,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-header | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-header --selenium-server selenium:4444 allow-git-repository-modifications features/header.feature | |||
@@ -1755,7 +1745,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-login | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-login --selenium-server selenium:4444 allow-git-repository-modifications features/login.feature | |||
@@ -1785,7 +1775,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-users | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-users --selenium-server selenium:4444 allow-git-repository-modifications features/users.feature | |||
@@ -1815,7 +1805,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: acceptance-apps | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-acceptance-php8.0:latest | |||
commands: | |||
- tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-apps --selenium-server selenium:4444 allow-git-repository-modifications features/apps.feature | |||
@@ -1845,7 +1835,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: nodb-codecov | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
environment: | |||
CODECOV_TOKEN: | |||
from_secret: CODECOV_TOKEN | |||
@@ -1877,7 +1867,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: db-codecov | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
environment: | |||
CODECOV_TOKEN: | |||
from_secret: CODECOV_TOKEN | |||
@@ -1918,7 +1908,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: object-store | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
environment: | |||
OBJECT_STORE: s3 | |||
CODECOV_TOKEN: | |||
@@ -1948,7 +1938,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: object-store | |||
image: ghcr.io/nextcloud/continuous-integration-integration-php7.4:latest | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0:latest | |||
environment: | |||
OBJECT_STORE: azure | |||
CODECOV_TOKEN: | |||
@@ -1984,7 +1974,7 @@ steps: | |||
commands: | |||
- git submodule update --init | |||
- name: memcache-memcached | |||
image: ghcr.io/nextcloud/continuous-integration-php7.4-memcached:latest | |||
image: ghcr.io/nextcloud/continuous-integration-php8.0-memcached:latest | |||
commands: | |||
- phpenmod xdebug | |||
- service memcached restart |
@@ -1,71 +0,0 @@ | |||
name: Psalm | |||
on: | |||
pull_request: | |||
push: | |||
branches: | |||
- master | |||
- stable* | |||
jobs: | |||
generate-report: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
- name: Set up php | |||
uses: shivammathur/setup-php@v2 | |||
with: | |||
php-version: '8.0' | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
env: | |||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |||
- name: Composer install | |||
run: composer i | |||
- name: Psalm | |||
# Make sure we pass and still upload the report | |||
continue-on-error: true | |||
run: composer run psalm -- --monochrome --no-progress --output-format=github --report=psalm.sarif | |||
- name: Upload report to GitHub | |||
if: always() | |||
uses: github/codeql-action/upload-sarif@v2 | |||
with: | |||
sarif_file: psalm.sarif | |||
generate-security-report: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- name: Checkout | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
- name: Set up php | |||
uses: shivammathur/setup-php@v2 | |||
with: | |||
php-version: '8.0' | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
- name: Composer install | |||
run: composer i | |||
- name: Psalm | |||
# Make sure we pass and still upload the report | |||
continue-on-error: true | |||
run: composer run psalm -- --monochrome --no-progress --output-format=github --taint-analysis --report=psalm.sarif | |||
- name: Upload report to GitHub | |||
if: always() | |||
uses: github/codeql-action/upload-sarif@v2 | |||
with: | |||
sarif_file: psalm.sarif |
@@ -14,12 +14,7 @@ jobs: | |||
smb-kerberos-tests: | |||
runs-on: ubuntu-latest | |||
strategy: | |||
fail-fast: false | |||
matrix: | |||
php-versions: ['8.0', '8.1'] | |||
name: php${{ matrix.php-versions }}-${{ matrix.ftpd }} | |||
name: kerberos | |||
steps: | |||
- name: Checkout server | |||
@@ -58,21 +53,12 @@ jobs: | |||
chmod 0777 cookies | |||
DC_IP=$(docker inspect dc --format '{{.NetworkSettings.IPAddress}}') | |||
echo "SAML login" | |||
docker run --rm --name client -v $PWD/cookies:/cookies -v /tmp/shared:/shared --dns $DC_IP --hostname client.domain.test icewind1991/samba-krb-test-client \ | |||
curl -c /cookies/jar -s --negotiate -u testuser@DOMAIN.TEST: --delegation always http://httpd.domain.test/index.php/apps/user_saml/saml/login | |||
curl -c /cookies/jar --negotiate -u testuser@DOMAIN.TEST: --delegation always http://httpd.domain.test/index.php/apps/user_saml/saml/login | |||
echo "Check we are logged in" | |||
CONTENT=$(docker run --rm --name client -v $PWD/cookies:/cookies -v /tmp/shared:/shared --dns $DC_IP --hostname client.domain.test icewind1991/samba-krb-test-client \ | |||
curl -b /cookies/jar -s --negotiate -u testuser@DOMAIN.TEST: --delegation always http://httpd.domain.test/remote.php/webdav/smb/test.txt) | |||
echo $CONTENT | |||
CONTENT=$(echo $CONTENT | tr -d '[:space:]') | |||
[[ $CONTENT == "testfile" ]] | |||
smb-kerberos-summary: | |||
runs-on: ubuntu-latest | |||
needs: smb-kerberos-tests | |||
if: always() | |||
steps: | |||
- name: Summary status | |||
run: if ${{ needs.smb-kerberos-tests.result != 'success' }}; then exit 1; fi |
@@ -26,14 +26,45 @@ jobs: | |||
run: composer i | |||
- name: Psalm | |||
run: composer run psalm -- --monochrome --no-progress --output-format=github --update-baseline || ( git diff -- . ':!lib/composer' && exit 1 ) | |||
run: composer run psalm -- --monochrome --no-progress --output-format=github --update-baseline --report=results.sarif | |||
- name: Check diff | |||
- name: Show potential changes in Psalm baseline | |||
if: always() | |||
run: git diff -- . ':!lib/composer' | |||
- name: Show potential changes in Psalm baseline | |||
run: | | |||
bash -c "[[ ! \"`git status --porcelain build/psalm-baseline.xml`\" ]] || ( echo 'Uncommited changes in Psalm baseline' && git status && git diff build/psalm-baseline.xml)" | |||
- name: Upload Analysis results to GitHub | |||
if: always() | |||
uses: github/codeql-action/upload-sarif@v2 | |||
with: | |||
sarif_file: results.sarif | |||
static-code-analysis-security: | |||
runs-on: ubuntu-latest | |||
steps: | |||
- name: Checkout code | |||
uses: actions/checkout@v3 | |||
with: | |||
submodules: true | |||
- name: Set up php | |||
uses: shivammathur/setup-php@master | |||
with: | |||
php-version: '8.0' | |||
extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip | |||
coverage: none | |||
- name: Composer install | |||
run: composer i | |||
- name: Psalm taint analysis | |||
run: composer run psalm -- --monochrome --no-progress --output-format=github --report=results.sarif --taint-analysis | |||
- name: Upload Security Analysis results to GitHub | |||
if: always() | |||
uses: github/codeql-action/upload-sarif@v2 | |||
with: | |||
sarif_file: results.sarif | |||
static-code-analysis-ocp: | |||
runs-on: ubuntu-latest | |||
@@ -57,11 +88,8 @@ jobs: | |||
run: composer i | |||
- name: Psalm | |||
run: composer run psalm -- -c psalm-ocp.xml --monochrome --no-progress --output-format=github --update-baseline || ( git diff -- . ':!lib/composer' && exit 1 ) | |||
- name: Check diff | |||
run: git diff -- . ':!lib/composer' | |||
run: composer run psalm -- -c psalm-ocp.xml --monochrome --no-progress --output-format=github --update-baseline | |||
- name: Show potential changes in Psalm baseline | |||
run: | | |||
bash -c "[[ ! \"`git status --porcelain build/psalm-baseline-ocp.xml`\" ]] || ( echo 'Uncommited changes in Psalm baseline' && git status && git diff build/psalm-baseline.xml)" | |||
if: always() | |||
run: git diff -- . ':!lib/composer' |
@@ -1 +1 @@ | |||
Subproject commit 299e51ccbb82251452de18d52a9b4b7e8207eb82 | |||
Subproject commit 1d53ed4d3282427854fca7ee6ecbb945304272db |
@@ -316,8 +316,8 @@ class Crypt { | |||
throw new \InvalidArgumentException( | |||
sprintf( | |||
'Unsupported cipher (%s) defined.', | |||
$cipher | |||
'Unsupported cipher (%s) defined.', | |||
$cipher | |||
) | |||
); | |||
} | |||
@@ -470,8 +470,7 @@ class Crypt { | |||
*/ | |||
protected function isValidPrivateKey($plainKey) { | |||
$res = openssl_get_privatekey($plainKey); | |||
// TODO: remove resource check one php7.4 is not longer supported | |||
if (is_resource($res) || (is_object($res) && get_class($res) === 'OpenSSLAsymmetricKey')) { | |||
if (is_object($res) && get_class($res) === 'OpenSSLAsymmetricKey') { | |||
$sslInfo = openssl_pkey_get_details($res); | |||
if (isset($sslInfo['key'])) { | |||
return true; |
@@ -1,4 +1,7 @@ | |||
<?php | |||
declare(strict_types=1); | |||
/** | |||
* @copyright Copyright (c) 2016 Robin Appelman <robin@icewind.nl> | |||
* | |||
@@ -108,9 +111,9 @@ class Notify extends Base { | |||
if ($input->getOption('user')) { | |||
return (string)$input->getOption('user'); | |||
} elseif (isset($_ENV['NOTIFY_USER'])) { | |||
return (string)$_ENV['NOTIFY_USER']; | |||
return $_ENV['NOTIFY_USER']; | |||
} elseif (isset($_SERVER['NOTIFY_USER'])) { | |||
return (string)$_SERVER['NOTIFY_USER']; | |||
return $_SERVER['NOTIFY_USER']; | |||
} else { | |||
return null; | |||
} | |||
@@ -120,9 +123,9 @@ class Notify extends Base { | |||
if ($input->getOption('password')) { | |||
return (string)$input->getOption('password'); | |||
} elseif (isset($_ENV['NOTIFY_PASSWORD'])) { | |||
return (string)$_ENV['NOTIFY_PASSWORD']; | |||
return $_ENV['NOTIFY_PASSWORD']; | |||
} elseif (isset($_SERVER['NOTIFY_PASSWORD'])) { | |||
return (string)$_SERVER['NOTIFY_PASSWORD']; | |||
return $_SERVER['NOTIFY_PASSWORD']; | |||
} else { | |||
return null; | |||
} |
@@ -122,7 +122,7 @@ class SmbTest extends \Test\Files\Storage\Storage { | |||
]; | |||
foreach ($expected as $expectedChange) { | |||
$this->assertContains($expectedChange, $changes, 'Actual changes are:' . PHP_EOL . print_r($expected, true), false, false); // dont check object identity | |||
$this->assertTrue(in_array($expectedChange, $changes), 'Actual changes are:' . PHP_EOL . print_r($changes, true) . PHP_EOL . 'Expected to find: ' . PHP_EOL . print_r($expectedChange, true)); | |||
} | |||
} | |||
@@ -722,7 +722,7 @@ Raw output | |||
$recommendedPHPModules[] = 'sysvsem'; | |||
} | |||
if (!defined('PASSWORD_ARGON2I') && PHP_VERSION_ID >= 70400) { | |||
if (!defined('PASSWORD_ARGON2I')) { | |||
// Installing php-sodium on >=php7.4 will provide PASSWORD_ARGON2I | |||
// on previous version argon2 wasn't part of the "standard" extension | |||
// and RedHat disabled it so even installing php-sodium won't provide argon2i |
@@ -621,7 +621,7 @@ trait Sharing { | |||
return; | |||
} | |||
if (!array_key_exists($field, $returnedShare)) { | |||
if (!property_exists($returnedShare, $field)) { | |||
Assert::fail("$field was not found in response"); | |||
} | |||
@@ -2007,7 +2007,7 @@ | |||
</RedundantCondition> | |||
</file> | |||
<file src="lib/private/Authentication/Token/PublicKeyToken.php"> | |||
<UndefinedMethod occurrences="16"> | |||
<UndefinedMagicMethod occurrences="16"> | |||
<code>parent::getExpires()</code> | |||
<code>parent::getLastCheck()</code> | |||
<code>parent::getLoginName()</code> | |||
@@ -2024,7 +2024,7 @@ | |||
<code>parent::setScope(json_encode($scope))</code> | |||
<code>parent::setToken($token)</code> | |||
<code>parent::setType(IToken::WIPE_TOKEN)</code> | |||
</UndefinedMethod> | |||
</UndefinedMagicMethod> | |||
</file> | |||
<file src="lib/private/Authentication/TwoFactorAuth/Db/ProviderUserAssignmentDao.php"> | |||
<InvalidReturnStatement occurrences="1"/> |
@@ -4,7 +4,7 @@ | |||
"optimize-autoloader": true, | |||
"sort-packages": true, | |||
"platform": { | |||
"php": "7.4" | |||
"php": "8.0" | |||
}, | |||
"allow-plugins": { | |||
"bamarni/composer-bin-plugin": true | |||
@@ -22,6 +22,7 @@ | |||
} | |||
}, | |||
"require": { | |||
"php": "^8.0", | |||
"ext-json": "*", | |||
"ext-libxml": "*", | |||
"ext-mbstring": "*", |
@@ -4,7 +4,7 @@ | |||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", | |||
"This file is @generated automatically" | |||
], | |||
"content-hash": "8333c8a239fe5ccec285dfbccc17cca4", | |||
"content-hash": "c30ab0b39c073da15c133396d55da957", | |||
"packages": [], | |||
"packages-dev": [ | |||
{ | |||
@@ -71,6 +71,7 @@ | |||
"prefer-stable": false, | |||
"prefer-lowest": false, | |||
"platform": { | |||
"php": "^8.0", | |||
"ext-json": "*", | |||
"ext-libxml": "*", | |||
"ext-mbstring": "*", | |||
@@ -81,7 +82,7 @@ | |||
}, | |||
"platform-dev": [], | |||
"platform-overrides": { | |||
"php": "7.4" | |||
"php": "8.0" | |||
}, | |||
"plugin-api-version": "2.3.0" | |||
} |
@@ -42,6 +42,8 @@ use Symfony\Component\Console\Input\InputOption; | |||
use Symfony\Component\Console\Output\OutputInterface; | |||
use Symfony\Component\Console\Question\ConfirmationQuestion; | |||
use function pcntl_signal; | |||
class Repair extends Command { | |||
protected IConfig $config; | |||
private IRootFolder $rootFolder; |
@@ -28,7 +28,7 @@ class InstalledVersions | |||
{ | |||
/** | |||
* @var mixed[]|null | |||
* @psalm-var array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}|array{}|null | |||
* @psalm-var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}|array{}|null | |||
*/ | |||
private static $installed; | |||
@@ -39,7 +39,7 @@ class InstalledVersions | |||
/** | |||
* @var array[] | |||
* @psalm-var array<string, array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}> | |||
* @psalm-var array<string, array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}> | |||
*/ | |||
private static $installedByVendor = array(); | |||
@@ -243,7 +243,7 @@ class InstalledVersions | |||
/** | |||
* @return array | |||
* @psalm-return array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string} | |||
* @psalm-return array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool} | |||
*/ | |||
public static function getRootPackage() | |||
{ | |||
@@ -257,7 +257,7 @@ class InstalledVersions | |||
* | |||
* @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect. | |||
* @return array[] | |||
* @psalm-return array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>} | |||
* @psalm-return array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} | |||
*/ | |||
public static function getRawData() | |||
{ | |||
@@ -280,7 +280,7 @@ class InstalledVersions | |||
* Returns the raw data of all installed.php which are currently loaded for custom implementations | |||
* | |||
* @return array[] | |||
* @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}> | |||
* @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}> | |||
*/ | |||
public static function getAllRawData() | |||
{ | |||
@@ -303,7 +303,7 @@ class InstalledVersions | |||
* @param array[] $data A vendor/composer/installed.php data set | |||
* @return void | |||
* | |||
* @psalm-param array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>} $data | |||
* @psalm-param array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $data | |||
*/ | |||
public static function reload($data) | |||
{ | |||
@@ -313,7 +313,7 @@ class InstalledVersions | |||
/** | |||
* @return array[] | |||
* @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}> | |||
* @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}> | |||
*/ | |||
private static function getInstalled() | |||
{ |
@@ -37,13 +37,13 @@ abstract class BaseResponse extends Response { | |||
/** @var string */ | |||
protected $format; | |||
/** @var string */ | |||
/** @var ?string */ | |||
protected $statusMessage; | |||
/** @var int */ | |||
/** @var ?int */ | |||
protected $itemsCount; | |||
/** @var int */ | |||
/** @var ?int */ | |||
protected $itemsPerPage; | |||
/** | |||
@@ -92,7 +92,7 @@ abstract class BaseResponse extends Response { | |||
} | |||
/** | |||
* @param string[] $meta | |||
* @param array<string,string|int> $meta | |||
* @return string | |||
*/ | |||
protected function renderResult(array $meta): string { | |||
@@ -125,12 +125,15 @@ abstract class BaseResponse extends Response { | |||
return $writer->outputMemory(true); | |||
} | |||
/** | |||
* @param array $array | |||
* @param \XMLWriter $writer | |||
*/ | |||
protected function toXML(array $array, \XMLWriter $writer) { | |||
protected function toXML(array $array, \XMLWriter $writer): void { | |||
foreach ($array as $k => $v) { | |||
if ($k === '@attributes' && is_array($v)) { | |||
foreach ($v as $k2 => $v2) { | |||
$writer->writeAttribute($k2, $v2); | |||
} | |||
continue; | |||
} | |||
if (\is_string($k) && strpos($k, '@') === 0) { | |||
$writer->writeAttribute(substr($k, 1), $v); | |||
continue; |
@@ -28,7 +28,6 @@ use OCP\AppFramework\Http; | |||
use OCP\AppFramework\OCSController; | |||
class V1Response extends BaseResponse { | |||
/** | |||
* The V1 endpoint has very limited http status codes basically everything | |||
* is status 200 except 401 | |||
@@ -69,12 +68,11 @@ class V1Response extends BaseResponse { | |||
$meta = [ | |||
'status' => $this->getOCSStatus() === 100 ? 'ok' : 'failure', | |||
'statuscode' => $this->getOCSStatus(), | |||
'message' => $this->getOCSStatus() === 100 ? 'OK' : $this->statusMessage, | |||
'message' => $this->getOCSStatus() === 100 ? 'OK' : $this->statusMessage ?? '', | |||
'totalitems' => (string)($this->itemsCount ?? ''), | |||
'itemsperpage' => (string)($this->itemsPerPage ?? ''), | |||
]; | |||
$meta['totalitems'] = $this->itemsCount !== null ? (string)$this->itemsCount : ''; | |||
$meta['itemsperpage'] = $this->itemsPerPage !== null ? (string)$this->itemsPerPage: ''; | |||
return $this->renderResult($meta); | |||
} | |||
} |
@@ -27,7 +27,6 @@ use OCP\AppFramework\Http; | |||
use OCP\AppFramework\OCSController; | |||
class V2Response extends BaseResponse { | |||
/** | |||
* The V2 endpoint just passes on status codes. | |||
* Of course we have to map the OCS specific codes to proper HTTP status codes | |||
@@ -61,7 +60,7 @@ class V2Response extends BaseResponse { | |||
$meta = [ | |||
'status' => $status >= 200 && $status < 300 ? 'ok' : 'failure', | |||
'statuscode' => $this->getOCSStatus(), | |||
'message' => $status >= 200 && $status < 300 ? 'OK' : $this->statusMessage, | |||
'message' => $status >= 200 && $status < 300 ? 'OK' : $this->statusMessage ?? '', | |||
]; | |||
if ($this->itemsCount !== null) { |
@@ -101,7 +101,7 @@ class OC_API { | |||
public static function requestedFormat(): string { | |||
$formats = ['json', 'xml']; | |||
$format = (isset($_GET['format']) && in_array($_GET['format'], $formats)) ? $_GET['format'] : 'xml'; | |||
$format = (isset($_GET['format']) && is_string($_GET['format']) && in_array($_GET['format'], $formats)) ? $_GET['format'] : 'xml'; | |||
return $format; | |||
} | |||
@@ -29,25 +29,27 @@ use function lcfirst; | |||
use function substr; | |||
/** | |||
* @method integer getId() | |||
* @method void setId(integer $id) | |||
* @method int getId() | |||
* @method void setId(int $id) | |||
* @since 7.0.0 | |||
* @psalm-consistent-constructor | |||
*/ | |||
abstract class Entity { | |||
/** | |||
* @var int | |||
*/ | |||
public $id; | |||
private $_updatedFields = []; | |||
private $_fieldTypes = ['id' => 'integer']; | |||
private array $_updatedFields = []; | |||
private array $_fieldTypes = ['id' => 'integer']; | |||
/** | |||
* Simple alternative constructor for building entities from a request | |||
* @param array $params the array which was obtained via $this->params('key') | |||
* in the controller | |||
* @return Entity | |||
* @since 7.0.0 | |||
*/ | |||
public static function fromParams(array $params) { | |||
public static function fromParams(array $params): static { | |||
$instance = new static(); | |||
foreach ($params as $key => $value) { | |||
@@ -64,7 +66,7 @@ abstract class Entity { | |||
* @param array $row the row to map onto the entity | |||
* @since 7.0.0 | |||
*/ | |||
public static function fromRow(array $row) { | |||
public static function fromRow(array $row): static { | |||
$instance = new static(); | |||
foreach ($row as $key => $value) { | |||
@@ -100,7 +102,7 @@ abstract class Entity { | |||
* Generic setter for properties | |||
* @since 7.0.0 | |||
*/ | |||
protected function setter($name, $args) { | |||
protected function setter(string $name, array $args): void { | |||
// setters should only work for existing attributes | |||
if (property_exists($this, $name)) { | |||
if ($this->$name === $args[0]) { | |||
@@ -142,7 +144,7 @@ abstract class Entity { | |||
* Generic getter for properties | |||
* @since 7.0.0 | |||
*/ | |||
protected function getter($name) { | |||
protected function getter(string $name): mixed { | |||
// getters should only work for existing attributes | |||
if (property_exists($this, $name)) { | |||
return $this->$name; | |||
@@ -160,7 +162,7 @@ abstract class Entity { | |||
* getter method | |||
* @since 7.0.0 | |||
*/ | |||
public function __call($methodName, $args) { | |||
public function __call(string $methodName, array $args) { | |||
if (strpos($methodName, 'set') === 0) { | |||
$this->setter(lcfirst(substr($methodName, 3)), $args); | |||
} elseif (strpos($methodName, 'get') === 0) { | |||
@@ -191,7 +193,7 @@ abstract class Entity { | |||
* @param string $attribute the name of the attribute | |||
* @since 7.0.0 | |||
*/ | |||
protected function markFieldUpdated($attribute) { | |||
protected function markFieldUpdated(string $attribute): void { | |||
$this->_updatedFields[$attribute] = true; | |||
} | |||
@@ -25,10 +25,10 @@ declare(strict_types=1); | |||
* along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
* | |||
*/ | |||
// Show warning if a PHP version below 7.4 is used, | |||
if (PHP_VERSION_ID < 70400) { | |||
// Show warning if a PHP version below 8.0 is used, | |||
if (PHP_VERSION_ID < 80000) { | |||
http_response_code(500); | |||
echo 'This version of Nextcloud requires at least PHP 7.4<br/>'; | |||
echo 'This version of Nextcloud requires at least PHP 8.0<br/>'; | |||
echo 'You are currently running ' . PHP_VERSION . '. Please update your PHP version.'; | |||
exit(1); | |||
} |
@@ -13,6 +13,7 @@ | |||
"application/font-sfnt": "image", | |||
"application/font-woff": "image", | |||
"application/gpx+xml": "location", | |||
"application/gzip": "package/x-generic", | |||
"application/illustrator": "image", | |||
"application/javascript": "text/code", | |||
"application/json": "text/code", | |||
@@ -80,7 +81,7 @@ | |||
"application/x-fictionbook+xml": "text", | |||
"application/x-font": "image", | |||
"application/x-gimp": "image", | |||
"application/x-gzip": "package/x-generic", | |||
"application/x-gzip": "application/gzip", | |||
"application/x-iwork-keynote-sffkey": "x-office/presentation", | |||
"application/x-iwork-numbers-sffnumbers": "x-office/spreadsheet", | |||
"application/x-iwork-pages-sffpages": "x-office/document", | |||
@@ -115,4 +116,3 @@ | |||
"application/vnd.openxmlformats-officedocument.wordprocessingml.document.oform": "x-office/form", | |||
"application/vnd.openxmlformats-officedocument.wordprocessingml.document.docxf": "x-office/form-template" | |||
} | |||
@@ -65,8 +65,8 @@ | |||
"fodt": ["application/vnd.oasis.opendocument.text-flat-xml"], | |||
"gif": ["image/gif"], | |||
"gpx": ["application/gpx+xml"], | |||
"gz": ["application/x-gzip"], | |||
"gzip": ["application/x-gzip"], | |||
"gz": ["application/gzip"], | |||
"gzip": ["application/gzip"], | |||
"h": ["text/x-h"], | |||
"heic": ["image/heic"], | |||
"heif": ["image/heif"], |
@@ -13,6 +13,7 @@ OC.MimeTypeList={ | |||
"application/font-sfnt": "image", | |||
"application/font-woff": "image", | |||
"application/gpx+xml": "location", | |||
"application/gzip": "package/x-generic", | |||
"application/illustrator": "image", | |||
"application/javascript": "text/code", | |||
"application/json": "text/code", | |||
@@ -80,7 +81,7 @@ OC.MimeTypeList={ | |||
"application/x-fictionbook+xml": "text", | |||
"application/x-font": "image", | |||
"application/x-gimp": "image", | |||
"application/x-gzip": "package/x-generic", | |||
"application/x-gzip": "application/gzip", | |||
"application/x-iwork-keynote-sffkey": "x-office/presentation", | |||
"application/x-iwork-numbers-sffnumbers": "x-office/spreadsheet", | |||
"application/x-iwork-pages-sffpages": "x-office/document", |
@@ -1,7 +1,7 @@ | |||
{ | |||
"hashes": { | |||
"core\/js\/mimetypelist.js": "b04161ccafa1fae9ce92393f9e293e70523a7cfde1ffd71ef980a287048fde559d2fd24575652220a821e61ca398b87caab96d533e210c7ee7f48a7cdfcf9bb7" | |||
"core\/js\/mimetypelist.js": "e47768d024b1b8cc4a24c91892e9b4a4489c713f9aa8b251e6a300a954d3105d56ae2214519c62ef0d621102cac91eb009c863f7b9368e9f463a4f102a1ad91b" | |||
}, | |||
"signature": "sxNvTR6Y7xfMGFHsHTSYUtBHRtnWb+1ELf4zdgulFv\/4emGrmG2l+oZc+alHIMeBCgWHSrEDmgbtuJ0V6NJCD+yeoGhOJbkqXd9+oFtkIr1ciheg\/AnLnUdSFjmUwsyilVK2VRXIUYsYpRf1gLx0yHoJeif+dZMiNIbgsw3DJn8yNQjwOEFny2ofotV1j79SdSWRvW0PAIaiOMoA0mHyRb95hVL79mHHREpOpfmXStGegXqiHz49ppDrvwG1I3PyjHXl\/2hef5Xn0uzcjk4r5ruVSJB\/dy5pS\/KuxnlrhdwBKl3Lhb0bc5ptwToACIQuWiClr\/lIyqlzdaEWCTYiR8sagvTxS1TzcTgj0gTV3ZCwg+xhMWmkoQ7KBjA9gifgiF\/ADGx+HjgvDH+vZkY1wmima1n3n9muTi+kRmT10zUgtKEAWFCfHH3LoqozSwAqwrLFlU2FYzashK98ip78R6\/+QC23UlqGNDa1i+URWJ8ltksayw047NfhL2isvsfPMLSGeVuqRpg0ht7A4EBKBO2y5cHpEdkHlEbaO7KoV40YKEkYHO5w+EuY\/jmqkENNq\/WRJT4jgzFFdlS3DOUnaHma+oPBas8MTA9PdCb9LDaGYzUyJp+ObBfDxUWGSSRCbYnKAdpqlD+OZMTlpf628LXN64SccN4qkL8AtCZ7Gwk=", | |||
"signature": "r24gCYJNRAR7PoX9jEWOkx7ErNucehmdbskGQJIhLPdUbFyBoQw4wgFPlrf8j4GDkchEbpcq0Kf1Bp\/JRuV47TVj+rrmqgX\/LqQKgbENxws8rZy9EXoG9slb7LnMhpueRQdnT94KvU7ntbwSXE4BM0tbE51\/rHtAvtnUbkDiZuv\/d6dRjRVbJ5\/Br+DIPveMJSgRBD+gNwktXTWQ6wEHFBynuqASZFNFypZ4OJyM4KXhlYWpl5Bx5pqAXpWroyOVIu1GB83EAf5vwjc9fHH8Envu13WGDZB5MIQc+h22r\/4j\/scugfL3RbDZie3JSq3ADV+TmsBra9gYsLdE0zde8AQRlb1cugldzKNpjcguyjZ8PP\/8mCg8cBSesRF9Qo2RN\/MWiaB+JPjusY76uNfXhfG7pQ06SCkU5S1\/AxdIGi5VfGGi08lVJWEIZzmOuXzvbx1hacAxSOmDIq2j3j8JirMobGURzn+zDjl94qZ9Y2AG5SIgdGBfKmBQRmbiPGO1sGfjFFVPotlFvFxZlKl8cMkLK2gmXIzyxe8OkfL66LSinfxiDQDuAeFLX7IMtkIDreQHhWFatFj1G\/3TjLwxaRzm+dk9L70f0DSkhg603zdQQvR7dQ9VOnGwlFlnMpDYRMc\/pLWEYn7vp2A1wQFrb5CEU+C84ll8oKeNrhfEyBM=", | |||
"certificate": "-----BEGIN CERTIFICATE-----\r\nMIIEvjCCAqagAwIBAgIUc\/0FxYrsgSs9rDxp03EJmbjN0NwwDQYJKoZIhvcNAQEF\r\nBQAwIzEhMB8GA1UECgwYb3duQ2xvdWQgQ29kZSBTaWduaW5nIENBMB4XDTE1MTEw\r\nMzIxMDMzM1oXDTE2MTEwMzIxMDMzM1owDzENMAsGA1UEAwwEY29yZTCCAiIwDQYJ\r\nKoZIhvcNAQEBBQADggIPADCCAgoCggIBALb6EgHpkAqZbO5vRO8XSh7G7XGWHw5s\r\niOf4RwPXR6SE9bWZEm\/b72SfWk\/\/J6AbrD8WiOzBuT\/ODy6k5T1arEdHO+Pux0W1\r\nMxYJJI4kH74KKgMpC0SB0Rt+8WrMqV1r3hhJ46df6Xr\/xolP3oD+eLbShPcblhdS\r\nVtkZEkoev8Sh6L2wDCeHDyPxzvj1w2dTdGVO9Kztn0xIlyfEBakqvBWtcxyi3Ln0\r\nklnxlMx3tPDUE4kqvpia9qNiB1AN2PV93eNr5\/2riAzIssMFSCarWCx0AKYb54+d\r\nxLpcYFyqPJ0ydBCkF78DD45RCZet6PNYkdzgbqlUWEGGomkuDoJbBg4wzgzO0D77\r\nH87KFhYW8tKFFvF1V3AHl\/sFQ9tDHaxM9Y0pZ2jPp\/ccdiqnmdkBxBDqsiRvHvVB\r\nCn6qpb4vWGFC7vHOBfYspmEL1zLlKXZv3ezMZEZw7O9ZvUP3VO\/wAtd2vUW8UFiq\r\ns2v1QnNLN6jNh51obcwmrBvWhJy9vQIdtIjQbDxqWTHh1zUSrw9wrlklCBZ\/zrM0\r\ni8nfCFwTxWRxp3H9KoECzO\/zS5R5KIS7s3\/wq\/w9T2Ie4rcecgXwDizwnn0C\/aKc\r\nbDIjujpL1s9HO05pcD\/V3wKcPZ1izymBkmMyIbL52iRVN5FTVHeZdXPpFuq+CTQJ\r\nQ238lC+A\/KOVAgMBAAEwDQYJKoZIhvcNAQEFBQADggIBAGoKTnh8RfJV4sQItVC2\r\nAvfJagkrIqZ3iiQTUBQGTKBsTnAqE1H7QgUSV9vSd+8rgvHkyZsRjmtyR1e3A6Ji\r\noNCXUbExC\/0iCPUqdHZIVb+Lc\/vWuv4ByFMybGPydgtLoEUX2ZrKFWmcgZFDUSRd\r\n9Uj26vtUhCC4bU4jgu6hIrR9IuxOBLQUxGTRZyAcXvj7obqRAEZwFAKQgFpfpqTb\r\nH+kjcbZSaAlLVSF7vBc1syyI8RGYbqpwvtREqJtl5IEIwe6huEqJ3zPnlP2th\/55\r\ncf3Fovj6JJgbb9XFxrdnsOsDOu\/tpnaRWlvv5ib4+SzG5wWFT5UUEo4Wg2STQiiX\r\nuVSRQxK1LE1yg84bs3NZk9FSQh4B8vZVuRr5FaJsZZkwlFlhRO\/\/+TJtXRbyNgsf\r\noMRZGi8DLGU2SGEAHcRH\/QZHq\/XDUWVzdxrSBYcy7GSpT7UDVzGv1rEJUrn5veP1\r\n0KmauAqtiIaYRm4f6YBsn0INcZxzIPZ0p8qFtVZBPeHhvQtvOt0iXI\/XUxEWOa2F\r\nK2EqhErgMK\/N07U1JJJay5tYZRtvkGq46oP\/5kQG8hYST0MDK6VihJoPpvCmAm4E\r\npEYKQ96x6A4EH9Y9mZlYozH\/eqmxPbTK8n89\/p7Ydun4rI+B2iiLnY8REWWy6+UQ\r\nV204fGUkJqW5CrKy3P3XvY9X\r\n-----END CERTIFICATE-----" | |||
} |
@@ -71,7 +71,7 @@ class DetectionTest extends \Test\TestCase { | |||
public function dataDetectContent(): array { | |||
return [ | |||
['/', 'httpd/unix-directory'], | |||
// ['/data.tar.gz', 'application/x-gzip'], TODO: fix as it fails hard on php7.4 now | |||
['/data.tar.gz', 'application/gzip'], | |||
['/data.zip', 'application/zip'], | |||
['/testimage.mp3', 'audio/mpeg'], | |||
['/testimage.png', 'image/png'], | |||
@@ -91,7 +91,7 @@ class DetectionTest extends \Test\TestCase { | |||
public function dataDetect(): array { | |||
return [ | |||
['/', 'httpd/unix-directory'], | |||
['/data.tar.gz', 'application/x-gzip'], | |||
['/data.tar.gz', 'application/gzip'], | |||
['/data.zip', 'application/zip'], | |||
['/testimagelarge.svg', 'image/svg+xml'], | |||
['/testimage.png', 'image/png'], |
@@ -1,10 +1,10 @@ | |||
{ | |||
"require": { | |||
"vimeo/psalm": "^4.18" | |||
"vimeo/psalm": "^4.30" | |||
}, | |||
"config": { | |||
"platform": { | |||
"php": "7.4" | |||
"php": "8.0" | |||
}, | |||
"allow-plugins": { | |||
"composer/package-versions-deprecated": true |