From 28c3074c0594dbe997063004d29b167e0d74fa1a Mon Sep 17 00:00:00 2001 From: nivesh Date: Wed, 10 Nov 2021 16:11:39 +0530 Subject: [PATCH 01/35] create reversed patches --- Dockerfile.selfhost | 19 ++++++++++ .../003-contact-search-removal.patch | 16 ++++++++ ...04-contact-search-controller-removal.patch | 23 ++++++++++++ .../005-autocomplete-user-leak-core.patch | 36 ++++++++++++++++++ ...05-autocomplete-user-leak-custom-app.patch | 12 ++++++ .../010-disable-app-store-upgrade.patch | 15 ++++++++ reversed-patches/011-privacy-settings.patch | 37 +++++++++++++++++++ .../012-remove-user-status-widget.patch | 12 ++++++ 8 files changed, 170 insertions(+) create mode 100644 Dockerfile.selfhost create mode 100644 reversed-patches/003-contact-search-removal.patch create mode 100644 reversed-patches/004-contact-search-controller-removal.patch create mode 100644 reversed-patches/005-autocomplete-user-leak-core.patch create mode 100644 reversed-patches/005-autocomplete-user-leak-custom-app.patch create mode 100644 reversed-patches/010-disable-app-store-upgrade.patch create mode 100644 reversed-patches/011-privacy-settings.patch create mode 100644 reversed-patches/012-remove-user-status-widget.patch diff --git a/Dockerfile.selfhost b/Dockerfile.selfhost new file mode 100644 index 00000000..8a997672 --- /dev/null +++ b/Dockerfile.selfhost @@ -0,0 +1,19 @@ +FROM registry.gitlab.e.foundation/e/infra/ecloud/nextcloud:selfhost-privacy +ARG TMP_PATCH_DIR="/tmp/build_patches" +ARG BASE_DIR="/usr/src/nextcloud" + +COPY ./reversed-patches ${TMP_PATCH_DIR}/ + +RUN ls -la ${TMP_PATCH_DIR} + + +RUN patch -u ${BASE_DIR}/core/templates/layout.user.php -i ${TMP_PATCH_DIR}/003-contact-search-removal.patch +RUN patch -u ${BASE_DIR}/core/Controller/ContactsMenuController.php -i ${TMP_PATCH_DIR}/004-contact-search-controller-removal.patch +RUN cd ${BASE_DIR} && patch --merge ${TMP_PATCH_DIR}/005-autocomplete-user-leak-core.patch +RUN cd ${BASE_DIR}/custom_apps && patch --merge ${TMP_PATCH_DIR}/005-autocomplete-user-leak-custom-app.patch + +RUN patch -u ${BASE_DIR}/lib/private/Updater.php -i ${TMP_PATCH_DIR}/010-disable-app-store-upgrade.patch + +RUN cd ${BASE_DIR} && patch --merge ${TMP_PATCH_DIR}/011-privacy-settings.patch +RUN cd ${BASE_DIR} && patch -u ${BASE_DIR}/apps/dashboard/lib/Controller/DashboardController.php -i ${TMP_PATCH_DIR}/012-remove-user-status-widget.patch +RUN rm -rf ${TMP_PATCH_DIR} diff --git a/reversed-patches/003-contact-search-removal.patch b/reversed-patches/003-contact-search-removal.patch new file mode 100644 index 00000000..6c011d39 --- /dev/null +++ b/reversed-patches/003-contact-search-removal.patch @@ -0,0 +1,16 @@ +--- layout.user.php-new 2021-06-22 14:07:45.938569109 +0530 ++++ layout.user.php 2021-06-22 14:06:34.786843164 +0530 +@@ -103,6 +103,14 @@ +
+ ++
++ ++ ++
+
+