diff --git a/README.md b/README.md index 10a0f05..afa6279 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,7 @@ site.yml Antora playbook (local content only) package.json antora + asciidoctor + pagefind toolchain antora-extensions/ comp-version, latest/next-alias, sitemap-cleanup, global-attributes loader asciidoc-extensions/ tabs, remote-include +extension-tests/ node --test suite (`npm test`); build first, several tests skip without public/ global-attributes.yml site-wide AsciiDoc attributes (local) ui/supplemental/ branding + Pagefind modal search on the stock UI ui/supplemental/js/vendor/ gitignored; synced from node_modules by scripts/sync-vendor-assets.js @@ -121,11 +122,11 @@ is truly version-independent belongs in a shared partial or a Delete the folder: ```sh -rm -r content/server/10.15 +rm -r content/server/VERSION ``` That is the whole content change — `site.yml` needs no edit, because it globs. -Three bits of bookkeeping remain: +Four bits of bookkeeping remain: 1. Update the hand-maintained `latest-*` / `previous-*` / `current-*` attributes in `global-attributes.yml` if the removed version appeared in them. The @@ -133,13 +134,18 @@ Three bits of bookkeeping remain: derives its target from the newest non-prerelease version, `next-alias.js` from the `prerelease` flag). 2. **Server only:** drop the segment from `PUBLISHED_VERSIONS` in - `ui/supplemental/js/go-redirect.js`; `test/go-redirect.test.js` fails the build - if that list drifts from the published `public/server/*` trees. Only real - version numbers are maintained there — `latest` and `next` are permanent - entries, because they are generated redirect trees rather than versions. Legacy - `go.php?to=` links for the removed version then fall back to `latest`, which is - the intended safety net. -3. Accept that the version's URLs now 404 — nothing redirects a retired version + `ui/supplemental/js/go-redirect.js` **and** from the version loop in + `extension-tests/go-redirect.test.js` — two independent hand-maintained lists, + and the suite fails on either one alone. It also fails if `PUBLISHED_VERSIONS` + drifts from the published `public/server/*` trees. Only real version numbers + are maintained there — `latest` and `next` are permanent entries, because they + are generated redirect trees rather than versions. Legacy `go.php?to=` links + for the removed version then fall back to `latest`, which is the intended + safety net. +3. Drop the version's row from `sync/manifest.yml` and from the table below. Both + record which upstream branch each folder came from, so a row for a folder that + no longer exists is misleading rather than historical. +4. Accept that the version's URLs now 404 — nothing redirects a retired version tree. Drop a version only when its inbound links are acceptable casualties, or add redirects deliberately. @@ -148,7 +154,7 @@ Three bits of bookkeeping remain: | Product | Versions (folder) | Notes | |---------|-------------------|-------| | main | — | ROOT landing component (versionless) | -| server | 11.0, 10.16, 10.15 | no 11.0 branch upstream yet; master is the 11.0 line and is `latest` | +| server | 11.0, 10.16 | no 11.0 branch upstream yet; master is the 11.0 line and is `latest` | | ocis | 8.3 (dev), 8.2, 8.1, 8.0, 7.3 | master→8.3 (prerelease); 8.2 branch is `latest` | | webui | — | single rolling component (versionless) | | desktop | 7.2 (dev), 7.1, 6.0, 5.3 | master→7.2 (prerelease); 7.1 branch is `latest` | @@ -165,7 +171,13 @@ Three bits of bookkeeping remain: > `latest-*`/`previous-*` attributes in `global-attributes.yml`, and bump the > version segments of the affected links in `ui/supplemental/llms.txt` (those URLs > are pinned deliberately, because `/latest/` is a `noindex` redirect stub). -> `test/static-files.test.js` fails the build while any of the three disagree. +> `extension-tests/static-files.test.js` cross-checks the `latest-*-version` +> attributes against the content tree and `llms.txt`, and fails the build while +> those three disagree. It checks **only** `latest-*-version`: nothing in the suite +> verifies `previous-*-version`, `current-server-version` or +> `latest-server-download-version`, so a stale one of those renders site-wide with +> a green build. (`previous-android-version` equalling `latest-android-version` +> today suggests this has already happened once.) > > Dropping `prerelease` also moves `//next/` on to the newly opened dev > line by itself — `next-alias.js` reads the flag, so there is nothing to bump. @@ -173,9 +185,12 @@ Three bits of bookkeeping remain: > Then open the next dev line by copying the released folder to its new number and > re-adding the two keys. **Server only:** that copy publishes a new > `public/server//` tree, so add the segment to `PUBLISHED_VERSIONS` in -> `ui/supplemental/js/go-redirect.js` in the same commit — `test/go-redirect.test.js` -> fails while that list and the published trees disagree, in both directions (the -> mirror of step 2 under [Dropping a version](#dropping-a-version)). +> `ui/supplemental/js/go-redirect.js` in the same commit — +> `extension-tests/go-redirect.test.js` fails while that list and the published +> trees disagree, in either direction (the mirror of step 2 under +> [Dropping a version](#dropping-a-version)). Add it to the version loop in that +> test file as well: unlike a removal, an *addition* the loop does not cover fails +> nothing, so the new segment would silently never be exercised. > > The branch references in the Notes column above are **historical**: they record > which upstream `owncloud/docs-*` branch each folder was last imported from diff --git a/content/server/10.15/antora.yml b/content/server/10.15/antora.yml deleted file mode 100644 index e0f960f..0000000 --- a/content/server/10.15/antora.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: server -title: ownCloud Server -version: '10.15' -start_page: ROOT:index.adoc -nav: -- modules/ROOT/partials/nav.adoc - -asciidoc: - attributes: - latest-server-version: {page-component-version} # do not change, this is the value of the version key - previous-server-version: {page-component-version} # do not change, this is the value of the version key - latest-server-download-version: {page-component-version} # do not change, this is the value of the version key - current-server-version: {page-component-version} # do not change, this is the value of the version key - minimum-php-version: '7.4' - minimum-php-printed: '7.4.0' - minimum-php-version-short-code: '74' - recommended-php-version: '7.4' - recommended-php-version-short-code: '74' - supported-php-versions: '7.4' - format: 'html' # this attribute is a necessary legacy diff --git a/content/server/10.15/modules/ROOT/attachments/.gitkeep b/content/server/10.15/modules/ROOT/attachments/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/content/server/10.15/modules/ROOT/examples/.gitkeep b/content/server/10.15/modules/ROOT/examples/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/content/server/10.15/modules/ROOT/images/.gitkeep b/content/server/10.15/modules/ROOT/images/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/content/server/10.15/modules/ROOT/pages/.gitkeep b/content/server/10.15/modules/ROOT/pages/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/content/server/10.15/modules/ROOT/pages/index.adoc b/content/server/10.15/modules/ROOT/pages/index.adoc deleted file mode 100644 index 520de7e..0000000 --- a/content/server/10.15/modules/ROOT/pages/index.adoc +++ /dev/null @@ -1,3 +0,0 @@ -= Introduction to ownCloud Classic - -Welcome to the ownCloud Classic documentation. These documents provide an xref:admin_manual:index.adoc[admin guide] with information for installation, configuration and administrative tasks as well as documentation for xref:developer_manual:index.adoc[developers]. An xref:classic_ui:index.adoc[ownCloud User Manual] for the server is provided in the web documentation. diff --git a/content/server/10.15/modules/ROOT/partials/nav.adoc b/content/server/10.15/modules/ROOT/partials/nav.adoc deleted file mode 100644 index 9cb4cb1..0000000 --- a/content/server/10.15/modules/ROOT/partials/nav.adoc +++ /dev/null @@ -1,4 +0,0 @@ -* xref:index.adoc[Introduction] -include::admin_manual:partial$nav.adoc[] -include::developer_manual:partial$nav.adoc[] -include::classic_ui:partial$nav.adoc[] diff --git a/content/server/10.15/modules/admin_manual/attachments/.gitkeep b/content/server/10.15/modules/admin_manual/attachments/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/content/server/10.15/modules/admin_manual/attachments/configuration/user/oidc/OAuth-code-flow-sequence-diagram.png b/content/server/10.15/modules/admin_manual/attachments/configuration/user/oidc/OAuth-code-flow-sequence-diagram.png deleted file mode 100644 index b4fa966..0000000 Binary files a/content/server/10.15/modules/admin_manual/attachments/configuration/user/oidc/OAuth-code-flow-sequence-diagram.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/bootstrap.sh b/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/bootstrap.sh deleted file mode 100644 index 6d2187f..0000000 --- a/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/bootstrap.sh +++ /dev/null @@ -1,113 +0,0 @@ -#!/bin/bash -# -# originates from: -# https://git.samba.org/?p=samba.git;a=blob_plain;f=bootstrap/generated-dists/ubuntu1804/bootstrap.sh;hb=master -# -# This file is generated by 'bootstrap/template.py --render' -# See also bootstrap/config.py -# - -set -xueo pipefail - -export DEBIAN_FRONTEND=noninteractive -apt-get -y update - -apt-get -y install \ - acl \ - apt-utils \ - attr \ - autoconf \ - bind9utils \ - binutils \ - bison \ - build-essential \ - ccache \ - chrpath \ - curl \ - debhelper \ - dnsutils \ - docbook-xml \ - docbook-xsl \ - flex \ - gcc \ - gdb \ - git \ - glusterfs-common \ - gzip \ - heimdal-multidev \ - hostname \ - htop \ - krb5-config \ - krb5-kdc \ - krb5-user \ - language-pack-en \ - lcov \ - libacl1-dev \ - libarchive-dev \ - libattr1-dev \ - libavahi-common-dev \ - libblkid-dev \ - libbsd-dev \ - libcap-dev \ - libcephfs-dev \ - libcups2-dev \ - libdbus-1-dev \ - libglib2.0-dev \ - libgnutls28-dev \ - libgpgme11-dev \ - libicu-dev \ - libjansson-dev \ - libjs-jquery \ - libjson-perl \ - libkrb5-dev \ - libldap2-dev \ - liblmdb-dev \ - libncurses5-dev \ - libpam0g-dev \ - libparse-yapp-perl \ - libpcap-dev \ - libpopt-dev \ - libreadline-dev \ - libsystemd-dev \ - libtasn1-bin \ - libtasn1-dev \ - libunwind-dev \ - lmdb-utils \ - locales \ - lsb-release \ - make \ - mawk \ - mingw-w64 \ - patch \ - perl \ - perl-modules \ - pkg-config \ - procps \ - psmisc \ - python3 \ - python3-cryptography \ - python3-dbg \ - python3-dev \ - python3-dnspython \ - python3-gpg \ - python3-iso8601 \ - python3-markdown \ - python3-matplotlib \ - python3-pexpect \ - python3-pyasn1 \ - python3-setproctitle \ - rng-tools \ - rsync \ - sed \ - sudo \ - tar \ - tree \ - uuid-dev \ - wget \ - xfslibs-dev \ - xsltproc \ - zlib1g-dev - -apt-get -y autoremove -apt-get -y autoclean -apt-get -y clean diff --git a/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/compile_samba.sh b/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/compile_samba.sh deleted file mode 100644 index d73d66f..0000000 --- a/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/compile_samba.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/bash -./configure \ - --prefix=/usr \ - --enable-fhs \ - --sysconfdir=/etc \ - --localstatedir=/var \ - --with-privatedir=/var/lib/samba/private \ - --with-smbpasswd-file=/etc/samba/smbpasswd \ - --with-piddir=/var/run/samba \ - --with-pammodulesdir=/lib/x86_64-linux-gnu/security \ - --libdir=/usr/lib/x86_64-linux-gnu \ - --with-modulesdir=/usr/lib/x86_64-linux-gnu/samba \ - --datadir=/usr/share \ - --with-lockdir=/var/run/samba \ - --with-statedir=/var/lib/samba \ - --with-cachedir=/var/cache/samba \ - --with-socketpath=/var/run/ctdb/ctdbd.socket \ - --with-logdir=/var/log/ctdb \ - --systemd-install-services \ - --without-ad-dc diff --git a/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/install_samba.sh b/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/install_samba.sh deleted file mode 100644 index 3768dcb..0000000 --- a/content/server/10.15/modules/admin_manual/attachments/installation/manual_installation/install_samba.sh +++ /dev/null @@ -1,64 +0,0 @@ -#!/bin/bash - -set -o pipefail - -GREEN='\033[0;32m' -NC='\033[0m' # No Color - -s="smbclient.ini" -content="extension=smbclient.so" -v=$(php -r "echo PHP_VERSION;" | grep --only-matching --perl-regexp "7.\d+") -file="/etc/php/${v}/mods-available/${s}" - -echo -echo -e "${GREEN}dismod and pecl/apt smbclient uninstall${NC}" -echo - -if [[ -f "$FILE" ]]; then - phpdismod smbclient - echo '' | pecl uninstall smbclient - apt purge smbclient - apt autoremove -fi - -echo -echo -e "${GREEN}bootstrap${NC}" -echo - -../bootstrap.sh - -echo -echo -e "${GREEN}compile${NC}" -echo - -../compile_samba.sh - -echo -echo -e "${GREEN}make${NC}" -echo - -"$(make -j 4)" - -echo -echo -e "${GREEN}install${NC}" -echo - -"$(make install -j 4)" - -echo -echo -e "${GREEN}install pecl smbclient${NC}" -echo - -"$(pecl channel-update pecl.php.net)" -echo '' | pecl install smbclient - -echo -echo -e "${GREEN}phpenmod${NC}" -echo - -if [[ ! -f "$FILE" ]]; then - echo "$content" > "$file" - echo "Created ${file}" -fi - -phpenmod smbclient diff --git a/content/server/10.15/modules/admin_manual/examples/configuration/ldap/Multi-AD.slapd.conf b/content/server/10.15/modules/admin_manual/examples/configuration/ldap/Multi-AD.slapd.conf deleted file mode 100644 index 6e74ff2..0000000 --- a/content/server/10.15/modules/admin_manual/examples/configuration/ldap/Multi-AD.slapd.conf +++ /dev/null @@ -1,152 +0,0 @@ -# This an example of a config file: - -# See slapd.conf(5) - -# Global Directives: - -# Schema and objectClass definitions -include /etc/ldap/schema/core.schema -include /etc/ldap/schema/cosine.schema -include /etc/ldap/schema/nis.schema -include /etc/ldap/schema/inetorgperson.schema -include /etc/ldap/schema/misc.schema - -# Where the pid file is put. The init.d script -# will not stop the server if you change this. -pidfile /var/run/slapd/slapd.pid - -# List of arguments that were passed to the server -argsfile /var/run/slapd/slapd.args - -# Read slapd.conf(5) for possible values -# Change loglevel to "any" if you want to see everything. -loglevel none - -# Where the dynamically loaded modules are stored -modulepath /usr/lib/ldap - -# Here are the recommended modules: - -# module for meta-database -moduleload back_meta.la - -# module for the target ldap-server -moduleload back_ldap.la - -# module for your local database -moduleload back_hdb.la - -# module for rewriting attributes -moduleload rwm - -# caching module -moduleload pcache.la - -# module to enable memberof in ldap -moduleload memberof.la - -# The maximum number of entries that is returned for a search operation -sizelimit 500 - -# The tool-threads parameter sets the actual amount of cpu's that is used -# for indexing. -tool-threads 1 - -# If you want to save time and don't want to list all the refferals, set "yes" -norefs yes - -# Same as above -chase-referrals no - -# See slapd-meta - -# database type, for multiple ADS "meta" is required -database meta - -# now we create a local ldap tree -# in our tree we put the multiple ADS on different branches -# we need a suffix, an admin, and a password -suffix "dc=owncloud,dc=com" -rootdn "cn=Administrator,cn=Users,dc=example,dc=com" -rootpw "Password" - -# now we specify our ADs -# First-AD -# uri ://[]/ -uri "ldap://first.ad.com:389/ -cn=users,dc=first,dc=example,dc=com" - -# here we need to set the virtual name to the real name -# the virtual name is a branch in our new created ldap tree -# suffixmassage -suffixmassage "cn=users,dc=first,dc=example,dc=com" "cn=users,dc=first,dc=ad,dc=com" - -# authentication parameters -idassert-bind bindmethod=simple - binddn="cn=user01,cn=users,dc=first,dc=owncloud,dc=com" -credentials="Password01" - -# Second-AD -uri "ldaps://second.ad.com:636/cn=users,dc=second,dc=example,dc=com" -suffixmassage "cn=users,dc=second,dc=example,dc=com" "cn=users,dc=second,dc=ad,dc=com" -idassert-bind bindmethod=simple - binddn="cn=user02,cn=users,dc=second,dc=owncloud,dc=com" - credentials="Password02" - -# Now we start initialising the modules -# First the rewrite module -overlay rwm - -# Now we rewrite the attributes -rwm-map attribute uid sAMAccountName -rwm-map attribute dn distinguishedName - -# Next one is optional, if you want memberof, for the groups, -# you have to load it. -overlay memberof - -# Now we load the caching module -overlay pcache - -# The directive enables proxy caching -# See slapo-pcache - -# pcache -# Parameters: -# -# for cached entries. -# when reached - cache replacement is invoked -# = pcacheAttrset -# limit to the number of entries returned -# Consistency check time to wait -pcache hdb 100000 3 1000 100 - -# pcachePersist { TRUE | FALSE } -# Write cached results into the database -# Results remain in database after restart -pcachePersist TRUE - -# Where the database files are physically stored for database #1 -directory "/var/lib/ldap" - -# Caching templates for general search - -# pcacheAttrset -# First set the index number -# Then set the attribute to cache -pcacheAttrset 0 1.1 - -# pcacheTemplate -# First define the query sting to cache -# Then reference the Attrset -# Last set the time-to-live -pcacheTemplate (&(|(objectClass=))) 0 3600 -pcacheTemplate (objectClass=*) 0 3600 - -# User Name Field (Advanced Tab) -pcacheAttrset 1 displayname -pcacheTemplate (objectClass=*) 1 3600 - -# Group Field -pcacheAttrset 2 memberOf -pcacheTemplate (objectClass=*) 2 3600 diff --git a/content/server/10.15/modules/admin_manual/examples/configuration/ldap/single.slapd.conf b/content/server/10.15/modules/admin_manual/examples/configuration/ldap/single.slapd.conf deleted file mode 100644 index 6b16a08..0000000 --- a/content/server/10.15/modules/admin_manual/examples/configuration/ldap/single.slapd.conf +++ /dev/null @@ -1,283 +0,0 @@ -# This an example of a config file: - -# See slapd.conf(5) - -# Global Directives: - -# Schema and objectClass definitions -include /etc/ldap/schema/core.schema -include /etc/ldap/schema/cosine.schema -include /etc/ldap/schema/nis.schema -include /etc/ldap/schema/inetorgperson.schema - -# Where the pid file is put. The init.d script -# will not stop the server if you change this. -pidfile /var/run/slapd/slapd.pid - -# List of arguments that were passed to the server -argsfile /var/run/slapd/slapd.args - -# Read slapd.conf(5) for possible values -# Change loglevel to "any" if you want to see everything. -loglevel none - -# Where the dynamically loaded modules are stored -modulepath /usr/lib/ldap - -# Here are the recommended modules: - -# module for the target ldap-server -moduleload back_ldap.la - -# module for your local database -moduleload back_hdb.la - -# module for rewriting attributes -moduleload rwm - -# caching module -moduleload pcache.la - -# module to enable memberof in LDAP -moduleload memberof.la - -# The maximum number of entries that is returned for a search operation -sizelimit 500 - -# The tool-threads parameter sets the actual amount of cpu's that is used -# for indexing. -tool-threads 1 - -# Type of backend, for example "ldap" -backend ldap - -# Type of database -database ldap - -# If you only have read access, set this to "yes" -readonly yes - -# Set which protocol to use, we suggest "3" -protocol-version 3 - -# remember bind credentials -rebind-as-user - -# If you want to save time and don't want to list all the refferals, set to "yes" -norefs yes - -# Same as above -chase-referrals no - -# Specify the URL of your ldap server and the port. -# For unencrypted access use the port 389, for encrypted 636 -# If you have to use 636, you will also probably have to import -# the certificate of your target server. restart your webserver after you do. -uri "ldap://192.168.178.2:389" - -# The base of your directory in database, for example "dc=ldap01,dc=com" -suffix "dc=ldap01,dc=com" - -# rootdn directive for specifying a superuser on the database. -# If you don't have access to the admin user, use the one you have. -rootdn "cn=admin,dc=ldap01,dc=com" - -# Now we start initialising the modules -# First the rewrite module -overlay rwm - -# Now we rewrite the attributes -rwm-map attribute uid sAMAccountName -rwm-map attribute dn distinguishedName - -# Next one is optional, if you want memberof, for the groups, -# you have to load it. -overlay memberof - -# Now we load the caching module -overlay pcache - -# The directive enables proxy caching -# See slapo-pcache - -# pcache -# Parameters: -# -# for cached entries. -# when reached - cache replacement is invoked -# = pcacheAttrset -# limit to the number of entries returned -# Consistency check time to wait -pcache hdb 100000 3 1000 100 - -# pcachePersist { TRUE | FALSE } -# Write cached results into the database -# Results remain in database after restart -pcachePersist TRUE - -# Where the database file are physically stored for database #1 -directory "/var/lib/ldap" - -# Caching templates for general search - -# pcacheAttrset -# First set the index number -# Then set the attribute to cache -pcacheAttrset 0 1.1 - -# pcacheTemplate -# First define the querry sting to cache -# Then reference the Attrset -# Last set the time-to-live -pcacheTemplate (&(|(objectClass=))) 0 3600 -pcacheTemplate (objectClass=*) 0 3600 - -# User Name Field (Advanced Tab) -pcacheAttrset 1 displayname -pcacheTemplate (objectClass=*) 1 3600 - -# Group Field -pcacheAttrset 2 memberOf -pcacheTemplate (objectClass=*) 2 3600 - - -# This an example of a config file: - -# See slapd.conf(5) - -# Global Directives: - -# Schema and objectClass definitions -include /etc/ldap/schema/core.schema -include /etc/ldap/schema/cosine.schema -include /etc/ldap/schema/nis.schema -include /etc/ldap/schema/inetorgperson.schema - -# Where the pid file is put. The init.d script -# will not stop the server if you change this. -pidfile /var/run/slapd/slapd.pid - -# List of arguments that were passed to the server -argsfile /var/run/slapd/slapd.args - -# Read slapd.conf(5) for possible values -# Change loglevel to "any" if you want to see everything. -loglevel none - -# Where the dynamically loaded modules are stored -modulepath /usr/lib/ldap - -# Here are the recommended modules: - -# module for the target ldap-server -moduleload back_ldap.la - -# module for your local database -moduleload back_hdb.la - -# module for rewriting attributes -moduleload rwm - -# caching module -moduleload pcache.la - -# module to enable memberof in LDAP -moduleload memberof.la - - -# The maximum number of entries that is returned for a search operation -sizelimit 500 - -# The tool-threads parameter sets the actual amount of cpu's that is used -# for indexing. -tool-threads 1 - -# Type of backend, for example "ldap" -backend ldap - -# If you only have read access, set this to "yes" -readonly yes - -# Set which protocol to use, we suggest "3" -protocol-version 3 - -# remember bind credentials -rebind-as-user - -# If you want to save time and don't want to list all the refferals, set to "yes" -norefs yes - -# Same as above -chase-referrals no - -# Specify the URL of your ldap server and the port. -# For unencrypted access use the port 389, for encrypted 636 -# If you have to use 636, you will also probably have to import -# the certificate of your target server. -# Restart your webserver after you do. -uri "ldap://192.168.178.2:389" - -# The base of your directory in database, for example "dc=ldap01,dc=com" -suffix "dc=ldap01,dc=com" - -# rootdn directive for specifying a superuser on the database. -# If you don't have access to the admin user, use the one you have. -rootdn "cn=admin,dc=ldap01,dc=com" - -# Now we start initialising the modules -# First the rewrite module -overlay rwm - -# Now we rewrite the attributes -rwm-map attribute uid sAMAccountName -rwm-map attribute dn distinguishedName - -# Next one is optional, if you want memberof, for the groups, -# you have to load it. -overlay memberof - -# Now we load the caching module -overlay pcache - -# The directive enables proxy caching -# See slapd-pcache - -# pcache -# Parameters: -# -# for cached entries. -# when reached - cache replacement is invoked -# = pcacheAttrset -# limit to the number of entries returned -# Consistency check time to wait -pcache hdb 100000 3 1000 100 - -# pcachePersist { TRUE | FALSE } -# Write cached results into the database -# Results remain in database after restart -pcachePersist TRUE - -# Where the database file are physically stored for database #1 -directory "/var/lib/ldap" - -# Caching templates for general search - -# pcacheAttrset -# First set the index number -# Then set the attribute to cache -pcacheAttrset 0 1.1 - -# pcacheTemplate -# First define the query string to cache -# Then reference the Attrset -# Last set the time-to-live -pcacheTemplate (&(|(objectClass=))) 0 3600 -pcacheTemplate (objectClass=*) 0 3600 - -# User Name Field (Advanced Tab) -pcacheAttrset 1 displayname -pcacheTemplate (objectClass=*) 1 3600 - -# Group Field -pcacheAttrset 2 memberOf -pcacheTemplate (objectClass=*) 2 3600 diff --git a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/group_filter.ldif b/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/group_filter.ldif deleted file mode 100644 index 18810a3..0000000 --- a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/group_filter.ldif +++ /dev/null @@ -1,5 +0,0 @@ -(& - (objectClass=inetOrgPerson) - (memberOf=cn=owncloudusers,ou=groups,dc=example,dc=com) -) - diff --git a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/multi_group_search.ldif b/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/multi_group_search.ldif deleted file mode 100644 index 588849a..0000000 --- a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/multi_group_search.ldif +++ /dev/null @@ -1,7 +0,0 @@ -(& - (objectClass=user) - (| - (memberOf:1.2.840.113556.1.4.1941:=CN=,CN=Users,DC=example,DC=com) - (memberOf:1.2.840.113556.1.4.1941:=CN=,CN=Users,DC=example,DC=com) - ) -) diff --git a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/only_username.ldif b/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/only_username.ldif deleted file mode 100644 index f30c920..0000000 --- a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/only_username.ldif +++ /dev/null @@ -1,6 +0,0 @@ -(& - (objectClass=inetOrgPerson) - (memberOf=cn=owncloudusers,ou=groups,dc=example,dc=com) - (uid=%uid) -) - diff --git a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/single_group_search.ldif b/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/single_group_search.ldif deleted file mode 100644 index 164ca84..0000000 --- a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/single_group_search.ldif +++ /dev/null @@ -1,4 +0,0 @@ -(& - (objectClass=user) - (memberof:1.2.840.113556.1.4.1941:=CN=,DC=example,DC=com) -) diff --git a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/username_email.ldif b/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/username_email.ldif deleted file mode 100644 index b53be77..0000000 --- a/content/server/10.15/modules/admin_manual/examples/configuration/user/user_auth_ldap/username_email.ldif +++ /dev/null @@ -1,7 +0,0 @@ -( - (& - (objectClass=inetOrgPerson) - (memberOf=cn=owncloudusers,ou=groups,dc=example,dc=com) - (|(uid=%uid)(mail=%uid)) - ) -) diff --git a/content/server/10.15/modules/admin_manual/examples/enterprise/user_management/shibboleth/apache-2.4-configuration.conf b/content/server/10.15/modules/admin_manual/examples/enterprise/user_management/shibboleth/apache-2.4-configuration.conf deleted file mode 100644 index 19e85b1..0000000 --- a/content/server/10.15/modules/admin_manual/examples/enterprise/user_management/shibboleth/apache-2.4-configuration.conf +++ /dev/null @@ -1,41 +0,0 @@ -# Load the Shibboleth module. -LoadModule mod-shib /usr/lib64/shibboleth/mod_shib_24.so - -# Ensure handler will be accessible - - AuthType None - Require all granted - - -# always fill env with shib variable for logout url - - AuthType shibboleth - ShibRequestSetting requireSession false - Require shibboleth - - -# authenticate only on the login page - - # force internal users to use the IdP - - AuthType shibboleth - ShibRequestSetting requireSession true - require valid-user - - # allow basic auth for e.g. guest accounts - - AuthType shibboleth - ShibRequestSetting requireSession false - require shibboleth - - - -# shib session for css, js and woff not needed -# -# WARNING!!!: The following lines could potentially override other location statements -# made in other Apache config-files depending on include-order. -# Please double-check your Apache config by consulting the Apache debug-log. - - AuthType None - Require all granted - diff --git a/content/server/10.15/modules/admin_manual/examples/enterprise/user_management/shibboleth/other-login-mechanisms-vhost.conf b/content/server/10.15/modules/admin_manual/examples/enterprise/user_management/shibboleth/other-login-mechanisms-vhost.conf deleted file mode 100644 index c1299eb..0000000 --- a/content/server/10.15/modules/admin_manual/examples/enterprise/user_management/shibboleth/other-login-mechanisms-vhost.conf +++ /dev/null @@ -1,31 +0,0 @@ - - DocumentRoot /var/www/owncloud - ServerName https://www.myowncloud.com - ServerAlias myowncloud.com - - - Options FollowSymlinks MultiViews - AllowOverride All - Order Allow,Deny - Allow from All - - - - AuthType shibboleth - ShibRequestSetting requireSession false - Require shibboleth - - - # Path for shibboleth - Alias "/index.php/login-shib" "/var/www/owncloud/index.php/login" - - AuthType shibboleth - ShibRequestSetting requireSession 1 - ShibRequestSetting REMOTE_ADDR X-Forwarded-For - require valid-user - - - RewriteEngine On - RewriteCond %{HTTP_HOST} !myowncloud.com$ [NC] - RewriteRule ^(.*)$ https://myowncloud.com/$1 [L,R=301] - diff --git a/content/server/10.15/modules/admin_manual/examples/installation/custom-app-directory-configuration.php b/content/server/10.15/modules/admin_manual/examples/installation/custom-app-directory-configuration.php deleted file mode 100644 index 3c93d5d..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/custom-app-directory-configuration.php +++ /dev/null @@ -1,16 +0,0 @@ - [ - [ - 'path' => OC::$SERVERROOT.'/apps', - 'url' => '/apps', - 'writable' => false, - ], - [ - 'path' => OC::$SERVERROOT.'/apps-external', - 'url' => '/apps-external', - 'writable' => true, - ], - ], - // remainder of the configuration -]; diff --git a/content/server/10.15/modules/admin_manual/examples/installation/deployment_recommendations/set_session_path.sh b/content/server/10.15/modules/admin_manual/examples/installation/deployment_recommendations/set_session_path.sh deleted file mode 100644 index eadf030..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/deployment_recommendations/set_session_path.sh +++ /dev/null @@ -1,9 +0,0 @@ -# Retrieve the session save path setting (default or explicit value) for PHP {recommended-php-version} -# Please change the file path to match your server configuration -session_path=$(\ - awk 'match($0, /^;?session.save_path = "(.*)"/, a) { print a[1] }' \ - /etc/php/{recommended-php-version}/**/php.ini \ - | uniq ) - -# Set the session save path in /etc/fstab -echo "tmpfs $session_path tmpfs defaults,noatime,mode=1777 0 0" >> /etc/fstab diff --git a/content/server/10.15/modules/admin_manual/examples/installation/docker/docker-compose.yml b/content/server/10.15/modules/admin_manual/examples/installation/docker/docker-compose.yml deleted file mode 100644 index 908a1cf..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/docker/docker-compose.yml +++ /dev/null @@ -1,72 +0,0 @@ -version: "3" - -volumes: - files: - driver: local - mysql: - driver: local - redis: - driver: local - -services: - owncloud: - image: owncloud/server:${OWNCLOUD_VERSION} - container_name: owncloud_server - restart: always - ports: - - ${HTTP_PORT}:8080 - depends_on: - - mariadb - - redis - environment: - - OWNCLOUD_DOMAIN=${OWNCLOUD_DOMAIN} - - OWNCLOUD_TRUSTED_DOMAINS=${OWNCLOUD_TRUSTED_DOMAINS} - - OWNCLOUD_DB_TYPE=mysql - - OWNCLOUD_DB_NAME=owncloud - - OWNCLOUD_DB_USERNAME=owncloud - - OWNCLOUD_DB_PASSWORD=owncloud - - OWNCLOUD_DB_HOST=mariadb - - OWNCLOUD_ADMIN_USERNAME=${ADMIN_USERNAME} - - OWNCLOUD_ADMIN_PASSWORD=${ADMIN_PASSWORD} - - OWNCLOUD_MYSQL_UTF8MB4=true - - OWNCLOUD_REDIS_ENABLED=true - - OWNCLOUD_REDIS_HOST=redis - healthcheck: - test: ["CMD", "/usr/bin/healthcheck"] - interval: 30s - timeout: 10s - retries: 5 - volumes: - - files:/mnt/data - - mariadb: - image: mariadb:10.11 # minimum required ownCloud version is 10.9 - container_name: owncloud_mariadb - restart: always - environment: - - MYSQL_ROOT_PASSWORD=owncloud - - MYSQL_USER=owncloud - - MYSQL_PASSWORD=owncloud - - MYSQL_DATABASE=owncloud - - MARIADB_AUTO_UPGRADE=1 - command: ["--max-allowed-packet=128M", "--innodb-log-file-size=64M"] - healthcheck: - test: ["CMD", "mysqladmin", "ping", "-u", "root", "--password=owncloud"] - interval: 10s - timeout: 5s - retries: 5 - volumes: - - mysql:/var/lib/mysql - - redis: - image: redis:6 - container_name: owncloud_redis - restart: always - command: ["--databases", "1"] - healthcheck: - test: ["CMD", "redis-cli", "ping"] - interval: 10s - timeout: 5s - retries: 5 - volumes: - - redis:/data diff --git a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/cli.ini b/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/cli.ini deleted file mode 100644 index f04ec33..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/cli.ini +++ /dev/null @@ -1,5 +0,0 @@ -rsa-key-size = 4096 -email = -agree-tos = True -authenticator = webroot -# post-hook = service apache2 reload diff --git a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/delete.sh b/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/delete.sh deleted file mode 100644 index 58ea2dc..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/delete.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/bash - -LE_PATH="/usr/bin" -LE_CB="certbot" - -## -## Retrieve and print a list of the installed Let's Encrypt SSL certificates. -## -function get_certificate_names() -{ - "$LE_PATH/$LE_CB" certificates | grep -iE "certificate name" | awk -F: '{gsub(/\s+/, "", $2); printf("- %s\n", $2)}' -} - -echo "Available Certificates:" - -get_certificate_names -echo - -read -p "Which certificate do you want to delete: " -r -e answer -if [ -n "$answer" ]; then - "$LE_PATH/$LE_CB" delete --cert-name "$answer" -fi - diff --git a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/list.sh b/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/list.sh deleted file mode 100644 index 6876c93..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/list.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -LE_PATH="/usr/bin" -LE_CB="certbot" - -"$LE_PATH/$LE_CB" certificates - diff --git a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/renew-cron.sh b/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/renew-cron.sh deleted file mode 100644 index da5fd05..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/renew-cron.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/bash - -LE_PATH="/usr/bin" -LE_CB="certbot" - -"$LE_PATH/$LE_CB" renew --no-self-upgrade --noninteractive diff --git a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/renew.sh b/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/renew.sh deleted file mode 100644 index b01ec4d..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/renew.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -LE_PATH="/usr/bin" -LE_CB="certbot" - -"$LE_PATH/$LE_CB" renew - diff --git a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/your-domain-name.sh b/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/your-domain-name.sh deleted file mode 100644 index 7d01402..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/lets_encrypt/your-domain-name.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash -# export makes the variable available for all subprocesses - -LE_PATH="/usr/bin" -LE_CB="certbot" - -# Assumes that example.com www.example.com and subdomain.example.com are the domains -# that you want a certificate for -export DOMAINS="-d example.com -d www.example.com -d subdomain.example.com" - -"$LE_PATH/$LE_CB" certonly --config /etc/letsencrypt/cli.ini "$DOMAINS" # --dry-run diff --git a/content/server/10.15/modules/admin_manual/examples/installation/manual_installation/instance.sh b/content/server/10.15/modules/admin_manual/examples/installation/manual_installation/instance.sh deleted file mode 100644 index 4a75f84..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/manual_installation/instance.sh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/bash -# Script Version 2022.06.23 - -# This script prepares the parameters for owncloud_prep.sh -# Handy if you have more instances to maintain where the process stays the same with different parameters -# The processing script is expected in the same directory of this script. - -# To setup this script for your environment, adopt the following variables to your needs: -# -# ocname the name of your directory containing the owncloud files -# ocroot the path to ocname, usually /var/www (no trailing slash) -# linkroot the path to your source directory for linking data and apps-external (no trailing slash) -# htuser the webserver user -# htgroup the webserver group -# rootuser the root user - -ocname='owncloud' -ocroot='/var/www' - -linkroot='/mnt/owncloud_data' - -htuser='www-data' -htgroup='www-data' -rootuser='root' - -if [ "$(id -u)" != 0 ]; then - printf "\nThis script should be run as root user to allow filesystem modifications\nExiting\n\n" -fi - -printf "\nConsider backing up the database before you continue when upgrading!\n\n" - -# Resolve the absolute path this script is located and expects the called script to be there too -DIR="$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")" - -$DIR/owncloud_prep.sh "$ocname" "$ocroot" "$linkroot" "$htuser" "$htgroup" "$rootuser" - diff --git a/content/server/10.15/modules/admin_manual/examples/installation/manual_installation/owncloud_prep.sh b/content/server/10.15/modules/admin_manual/examples/installation/manual_installation/owncloud_prep.sh deleted file mode 100644 index bf4abcf..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/manual_installation/owncloud_prep.sh +++ /dev/null @@ -1,303 +0,0 @@ -#!/bin/bash -# Script Version 2023.01.25 - -# To set up this script for your environment, hand over the following variables according your needs: -# -# ocname the name of your directory containing the owncloud files -# ocroot the path to ocname, usually /var/www (no trailing slash) -# linkroot the path to your source directory for linking data and apps-external (no trailing slash) -# htuser the webserver user -# htgroup the webserver group -# rootuser the root user - -# Short description for parameters used in find -# -# -L ... Follow symbolic links. Needed in case if links are used or present -# -path ... The path to process -# -prune ... If the file is a directory, do not descend into it (used to exclude directories) -# -o ... OR (to add more parameters) -# -type ... File is of type [d ... directory, f ... file] -# -print0 ... Print the full file name on the standard output, followed by a null character -# xargs -0 ... Reads items from the standard input, input items are terminated by a null character - - -ocname=$1 -ocroot=$2 -ocpath=$ocroot/$ocname -ocdata=$ocroot/$ocname/'data' -ocapps_external=$ocpath/'apps-external' -oldocpath=$ocroot/$ocname'_'$(date +%F-%H.%M.%S) - -linkroot=$3 -linkdata=$linkroot/'data' -linkapps_external=$linkroot/'apps-external' - -htuser=$4 -htgroup=$5 -rootuser=$6 - -arguments=6 - -filmod="0640" -dirmod="0750" -htamod="0640" - -# Because the data directory can be huge or on external storage, an automatic chmod/chown can take a while. -# Therefore this directory can be treated differently. -# If you have already created an external "data" and "apps-external" directory which you want to link, -# set the paths above accordingly. This script can link and set the proper rights and permissions -# depending what you enter when running the script. - -# When the instance is setup either post a fresh install or after an upgrade, run this script again but -# only for securing ".htaccess files". This sets the appropriate ownership and permission for them. - -# In case you upgrade an existing installation, your original directory will be renamed including a timestamp - - -if [ "$#" -ne "$arguments" ]; then - printf "\nThis script needs $arguments arguments, $# given.\n\n" -fi - -printf "\nFollowing parameters used\n\n" -printf "ocname: $ocname\nocroot: $ocroot\nlinkroot: $linkroot\nhtuser: $htuser\nhtgroup: $htgroup\nrootuser: $rootuser\n" - -function get_tar { - read -p "Please specify the tar file to extract with full path: " -r -e tarFile - if [ ! -f "$tarFile" ]; then - echo "tar file to extract not found. Exiting." - echo - exit - fi -} - -echo - -read -p "Do you want to secure your .htaccess files post installing/upgrade (y/N)? " -r -e answer -(echo "$answer" | grep -iq "^y") && do_secure="y" || do_secure="n" - -if [ "$do_secure" = "y" ]; then - printf "\nSecuring .htaccess files with chmod/chown\n" - if [ -f ${ocpath}/.htaccess ]; then - chmod $htamod ${ocpath}/.htaccess - chown ${rootuser}:${htgroup} ${ocpath}/.htaccess - fi - if [ -f ${ocdata}/.htaccess ];then - chmod $htamod ${ocdata}/.htaccess - chown ${rootuser}:${htgroup} ${ocdata}/.htaccess - fi - printf "\nDone\n\n" - exit -fi - - -read -p "Do you want to install a new instance (y/N)? " -r -e answer -(echo "$answer" | grep -iq "^y") && do_new="y" || do_new="n" - - -if [ "$do_new" = "n" ]; then - read -p "Do you want to upgrade an existing installation (y/N)? " -r -e answer - (echo "$answer" | grep -iq "^y") && do_upgrade="y" || do_upgrade="n" -fi - -read -p "Use links for data and apps-external directories (Y/n)? " -r -e answer -(echo "$answer" | grep -iq "^n") && uselinks="n" || uselinks="y" - -if [ "$uselinks" = "y" ]; then - read -p "Do you want to chmod/chown these links (y/N)? " -r -e answer - (echo "$answer" | grep -iq "^y") && chmdir="y" || chmdir="n" -fi - -# check if upgrading an existing installation -if [ "$do_upgrade" = "y" ]; then - read -p "Is the instance in maintenance mode? (y/N)? " -r -e answer - (echo "$answer" | grep -iq "^y") && mmode="y" || mmode="n" - if [ "$mmode" = "n" ]; then - echo "Please enable maintenance mode first: sudo -u$htuser ./occ maintenance:mode --on" - echo - exit - fi - get_tar - # rename the source for backup reasons - if [ -d ${ocpath} ]; then - mv $ocpath $oldocpath - fi -fi - -# get the tar file for new installs -if [ "$do_new" = "y" ]; then - get_tar -fi - -# in case of upgrade or new, extract the source -if [ "$do_upgrade" = "y" ] || [ "$do_new" = "y" ]; then - mkdir -p $ocpath - tar xvf "$tarFile" -C $ocpath --strip-components=1 - - if [ $? != 0 ]; then - echo - echo "tar extract failed, please check !" - echo - # rename back in case of tar errors - if [ "$do_upgrade" = "y" ] && [ -d ${oldocpath} ]; then - rm -r $ocpath - mv $oldocpath $ocpath - fi - exit - fi -fi - -# create / link missing directories -printf "\nCreating or linking possible missing directories \n" -mkdir -p $ocpath/updater -# check if directory creation is possible and create if ok -if [ "$uselinks" = "n" ]; then - if [ -L ${ocdata} ]; then - echo "Symlink for $ocdata found but mkdir requested. Exiting." - echo - exit - else - echo "mkdir $ocdata" - echo - mkdir -p $ocdata - fi - if [ -L ${ocapps_external} ]; then - echo "Symlink for $ocapps_external found but mkdir requested. Exiting." - echo - exit - else - printf "mkdir $ocapps_external \n" - mkdir -p $ocapps_external - fi -else - if [ -d ${ocdata} ] && [ ! -L $ocdata ]; then - echo "Directory for $ocdata found but link requested. Exiting." - echo - exit - else - printf "ln $ocdata --> $linkdata\n" - mkdir -p $linkdata - ln -sfn $linkdata $ocdata - fi - if [ -d ${ocapps_external} ] && [ ! -L $ocapps_external ]; then - echo "Directory for $ocapps_external found but link requested. Exiting." - echo - exit - else - printf "ln $ocapps_external --> $linkapps_external\n" - mkdir -p $linkapps_external - ln -sfn $linkapps_external $ocapps_external - fi -fi - -# copy existing *config.php and all .json files which are required for the new webUI -if [ "$do_upgrade" = "y" ]; then - # check if at minimum a config.php file is present - # note that you can have more than one config.php representing different settings - if [ -f ${oldocpath}/config/config.php ]; then - printf "\nCopy existing *config.php and *.json files \n" - # using find to omit messages if no files found - find ${oldocpath}/config/ -name \*config.php -exec cp {} ${ocpath}/config/ \; - find ${oldocpath}/config/ -name \*.json -exec cp {} ${ocpath}/config/ \; - else - printf "Skip to copy old config.php, file not found: ${oldocpath}/config/config.php \n" - fi -fi - -printf "\nchmod files and directories excluding data and apps-external directory\n" - -# check if there are files to chmod/chown available. If not, exiting. -# chmod -if [ ! "$(find $ocpath -maxdepth 1 -type f)" ]; then - echo "Something is wrong. There are no files to chmod. Exiting." - exit -fi - -find -L ${ocpath} -path ${ocdata} -prune -o -path ${ocapps_external} -prune -o -type f -print0 | xargs -0 chmod $filmod -find -L ${ocpath} -path ${ocdata} -prune -o -path ${ocapps_external} -prune -o -type d -print0 | xargs -0 chmod $dirmod - -# no error messages on empty directories -if [ "$chmdir" = "n" ] && [ "$uselinks" = "n" ]; then - - printf "chmod data and apps-external directory (mkdir) \n" - - if [ -n "$(ls -A $ocdata)" ]; then - find ${ocdata}/ -type f -print0 | xargs -0 chmod $filemod - fi - find ${ocdata}/ -type d -print0 | xargs -0 chmod $dirmod - if [ -n "$(ls -A $ocapps_external)" ]; then - find ${ocapps_external}/ -type f -print0 | xargs -0 chmod $filemod - fi - find ${ocapps_external}/ -type d -print0 | xargs -0 chmod $dirmod -fi - -if [ "$chmdir" = "y" ] && [ "$uselinks" = "y" ]; then - - printf "chmod data and apps-external directory (linked) \n" - - if [ -n "$(ls -A $ocdata)" ]; then - find -L ${ocdata}/ -type f -print0 | xargs -0 chmod $filmod - fi - find -L ${ocdata}/ -type d -print0 | xargs -0 chmod $dirmod - if [ -n "$(ls -A $ocapps_external)" ]; then - find -L ${ocapps_external}/ -type f -print0 | xargs -0 chmod $filmod - fi - find -L ${ocapps_external}/ -type d -print0 | xargs -0 chmod $dirmod -fi - -#chown -printf "chown files and directories excluding data and apps-external directory \n" - -find -L $ocpath -path ${ocdata} -prune -o -path ${ocapps_external} -prune -o -type d -print0 | xargs -0 chown ${rootuser}:${htgroup} -find -L $ocpath -path ${ocdata} -prune -o -path ${ocapps_external} -prune -o -type f -print0 | xargs -0 chown ${rootuser}:${htgroup} - -# do only if directories are present -if [ -d ${ocpath}/apps/ ]; then - printf "chown apps directory \n" - chown -R ${htuser}:${htgroup} ${ocpath}/apps/ -fi -if [ -d ${ocpath}/config/ ]; then - printf "chown config directory \n" - chown -R ${htuser}:${htgroup} ${ocpath}/config/ -fi -if [ -d ${ocpath}/updater/ ]; then - printf "chown updater directory \n" - chown -R ${htuser}:${htgroup} ${ocpath}/updater -fi - -if [ "$chmdir" = "n" ] && [ "$uselinks" = "n" ]; then - printf "chown data and apps-external directories (mkdir) \n" - chown -R ${htuser}:${htgroup} ${ocapps_external}/ - chown -R ${htuser}:${htgroup} ${ocdata}/ -fi -if [ "$chmdir" = "y" ] && [ "$uselinks" = "y" ]; then - printf "chown data and apps-external directories (linked) \n" - chown -R ${htuser}:${htgroup} ${ocapps_external}/ - chown -R ${htuser}:${htgroup} ${ocdata}/ -fi - -printf "\nchmod occ command to make it executable \n" -if [ -f ${ocpath}/occ ]; then - chmod +x ${ocpath}/occ -fi - - -# tell to remove the old instance, do upgrade and end maintenance mode etc. -printf "\nSUCCESS\n\n" -if [ "$do_upgrade" = "y" ]; then - if [ "$uselinks" = "n" ]; then - echo "Please migrate (move/copy) your data/ and apps-external/ directory manually back to the original location BEFORE running the upgrade command!" - echo - fi - echo "Please change to your upgraded ownCloud directory: cd $ocroot/$ocname" - echo "Please manually run: sudo -u $htuser ./occ maintenance:mode --off" - echo "Please manually run: sudo -u $htuser ./occ upgrade" - echo "Copy any changes manually added in .user.ini and .htaccess from the backup directory" - echo "Please manually remove the directory of the old instance: $oldocpath" - echo "When successfully done, re-run this script to secure your .htaccess files" - echo -fi - -if [ "$do_new" = "y" ]; then - echo "Open your browser, configure your instance and rerun this script to secure your .htaccess files" - echo -fi diff --git a/content/server/10.15/modules/admin_manual/examples/installation/webservers/apache/log-entry.json b/content/server/10.15/modules/admin_manual/examples/installation/webservers/apache/log-entry.json deleted file mode 100755 index db9051a..0000000 --- a/content/server/10.15/modules/admin_manual/examples/installation/webservers/apache/log-entry.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "reqId": "XDyankIou@F-GwxW82dx7QAAAAo", - "level": 3, - "time": "2019-01-14T14:20:14+00:00", - "remoteAddr": "127.0.0.1", - "user": "--", - "app": "PHP", - "method": "GET", - "url": "\/index.php\/apps\/files\/?dir=\/Documents&fileid=26", - "message": "..." -} diff --git a/content/server/10.15/modules/admin_manual/images/apps/2fa/2fa-exclude-groups.png b/content/server/10.15/modules/admin_manual/images/apps/2fa/2fa-exclude-groups.png deleted file mode 100644 index 623fab9..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/2fa/2fa-exclude-groups.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/2fa/2fa-init-qr.png b/content/server/10.15/modules/admin_manual/images/apps/2fa/2fa-init-qr.png deleted file mode 100644 index 8913ccf..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/2fa/2fa-init-qr.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/files_lifecycle/file-lifecycle-events.png b/content/server/10.15/modules/admin_manual/images/apps/files_lifecycle/file-lifecycle-events.png deleted file mode 100644 index cf1b54d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/files_lifecycle/file-lifecycle-events.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_enable.png b/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_enable.png deleted file mode 100644 index bb44dde..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_enable.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_group_admins_only.png b/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_group_admins_only.png deleted file mode 100644 index 7475eb6..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_group_admins_only.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_groups_only.png b/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_groups_only.png deleted file mode 100644 index e14f6cb..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_groups_only.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_oc_admins_only.png b/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_oc_admins_only.png deleted file mode 100644 index f9a42fb..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonate_oc_admins_only.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonating-a-user.png b/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonating-a-user.png deleted file mode 100644 index ef9ca9a..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/impersonate/impersonating-a-user.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/impersonate/picking-a-user-to-impersonate.png b/content/server/10.15/modules/admin_manual/images/apps/impersonate/picking-a-user-to-impersonate.png deleted file mode 100644 index 156f061..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/impersonate/picking-a-user-to-impersonate.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/connector_setup.png b/content/server/10.15/modules/admin_manual/images/apps/search_elastic/connector_setup.png deleted file mode 100644 index a4019e8..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/connector_setup.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_api_key_auth.png b/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_api_key_auth.png deleted file mode 100644 index f023b0d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_api_key_auth.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_auth_items.png b/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_auth_items.png deleted file mode 100644 index 378adcf..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_auth_items.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_no_auth.png b/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_no_auth.png deleted file mode 100644 index 28ef414..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_no_auth.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_u_p_auth.png b/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_u_p_auth.png deleted file mode 100644 index def0961..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/search_elastic_u_p_auth.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/warning_could_not_setup_indexes_connection_failure.png b/content/server/10.15/modules/admin_manual/images/apps/search_elastic/warning_could_not_setup_indexes_connection_failure.png deleted file mode 100644 index 9155417..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/warning_could_not_setup_indexes_connection_failure.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/warning_could_not_setup_indexes_unknown_key.png b/content/server/10.15/modules/admin_manual/images/apps/search_elastic/warning_could_not_setup_indexes_unknown_key.png deleted file mode 100644 index 88e3c32..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/search_elastic/warning_could_not_setup_indexes_unknown_key.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-connection-settings.png b/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-connection-settings.png deleted file mode 100644 index 7830157..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-connection-settings.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-directory-settings.png b/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-directory-settings.png deleted file mode 100644 index 2f97367..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-directory-settings.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-special-attributes.png b/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-special-attributes.png deleted file mode 100644 index ec8f6a0..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/advanced-tab-special-attributes.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/expert-tab.png b/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/expert-tab.png deleted file mode 100644 index 3fa59d8..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/expert-tab.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/groups-tab.png b/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/groups-tab.png deleted file mode 100644 index ee50fdb..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/groups-tab.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/login-attributes-tab.png b/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/login-attributes-tab.png deleted file mode 100644 index 92442dd..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/login-attributes-tab.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/server-tab.png b/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/server-tab.png deleted file mode 100644 index da8b67b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/server-tab.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/users-tab.png b/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/users-tab.png deleted file mode 100644 index ebdbb3b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/apps/user_ldap/ldap-wizard/users-tab.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/browser-address-bars.png b/content/server/10.15/modules/admin_manual/images/configuration/files/browser-address-bars.png deleted file mode 100644 index 356d186..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/browser-address-bars.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption10.png b/content/server/10.15/modules/admin_manual/images/configuration/files/encryption10.png deleted file mode 100644 index ab9aff8..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption10.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption12.png b/content/server/10.15/modules/admin_manual/images/configuration/files/encryption12.png deleted file mode 100644 index a186dca..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption12.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption7.png b/content/server/10.15/modules/admin_manual/images/configuration/files/encryption7.png deleted file mode 100644 index af999ff..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption7.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption8.png b/content/server/10.15/modules/admin_manual/images/configuration/files/encryption8.png deleted file mode 100644 index 9790038..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption8.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption9.png b/content/server/10.15/modules/admin_manual/images/configuration/files/encryption9.png deleted file mode 100644 index eb5912d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/encryption9.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/amazons3.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/amazons3.png deleted file mode 100644 index 1a24a50..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/amazons3.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/applicable.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/applicable.png deleted file mode 100644 index 9bbed9b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/applicable.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/auth_mechanism.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/auth_mechanism.png deleted file mode 100644 index d7c6b9c..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/auth_mechanism.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/auth_rsa.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/auth_rsa.png deleted file mode 100644 index daa1641..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/auth_rsa.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox-oc.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox-oc.png deleted file mode 100644 index b653386..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox-oc.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/app-configuration.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/app-configuration.png deleted file mode 100644 index b74d26f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/app-configuration.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/dropbox-apps-folders.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/dropbox-apps-folders.png deleted file mode 100644 index 5f576df..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/dropbox-apps-folders.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/dropbox-share-available.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/dropbox-share-available.png deleted file mode 100644 index acc2f35..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/dropbox-share-available.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/successful-connection-to-dropbox.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/successful-connection-to-dropbox.png deleted file mode 100644 index 5e109e9..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/dropbox/successful-connection-to-dropbox.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/enable-app.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/enable-app.png deleted file mode 100644 index 358b71b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/enable-app.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/external_storage_types.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/external_storage_types.png deleted file mode 100644 index 880d7f8..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/external_storage_types.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/ftp.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/ftp.png deleted file mode 100644 index b5f2502..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/ftp.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/ftp_storage_support.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/ftp_storage_support.png deleted file mode 100644 index c21ec58..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/ftp_storage_support.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/001.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/001.png deleted file mode 100644 index bc60ca1..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/001.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/002.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/002.png deleted file mode 100644 index 6f497b7..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/002.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/003.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/003.png deleted file mode 100644 index 842c477..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/003.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/004.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/004.png deleted file mode 100644 index e40ad65..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/004.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/005.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/005.png deleted file mode 100644 index dadfd96..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/005.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/006.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/006.png deleted file mode 100644 index 2b8e5de..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/006.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/007.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/007.png deleted file mode 100644 index fe641aa..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/007.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/008.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/008.png deleted file mode 100644 index 7a0f02c..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/008.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/009.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/009.png deleted file mode 100644 index e348352..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/009.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/010.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/010.png deleted file mode 100644 index 710d451..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/010.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/011.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/011.png deleted file mode 100644 index ae9d444..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/011.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/012.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/012.png deleted file mode 100644 index d0368a1..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/012.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/013.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/013.png deleted file mode 100644 index 0bb6512..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/013.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/014.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/014.png deleted file mode 100644 index 6691f28..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/014.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/015.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/015.png deleted file mode 100644 index 5b6685c..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/015.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/016.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/016.png deleted file mode 100644 index ac8304d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/016.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/017.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/017.png deleted file mode 100644 index c70ae6e..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/017.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/018.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/018.png deleted file mode 100644 index 1481f80..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/018.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/019.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/019.png deleted file mode 100644 index 97b320d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/019.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/020.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/020.png deleted file mode 100644 index b0056e5..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/020.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/021.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/021.png deleted file mode 100644 index 7e69d1d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/021.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/022.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/022.png deleted file mode 100644 index 66aeeaa..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/022.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/023.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/023.png deleted file mode 100644 index eeb3690..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/google_drive/023.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/local.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/local.png deleted file mode 100644 index 65044d6..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/local.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/mount_options.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/mount_options.png deleted file mode 100644 index 5be13f2..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/mount_options.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/smb.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/smb.png deleted file mode 100644 index 2287010..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/smb.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/user_mounts.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/user_mounts.png deleted file mode 100644 index 9eaac65..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/user_mounts.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/webdav.png b/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/webdav.png deleted file mode 100644 index e0e945d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/external_storage/webdav.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/federation-2.png b/content/server/10.15/modules/admin_manual/images/configuration/files/federation-2.png deleted file mode 100644 index 7c9dfcb..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/federation-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/federation-3.png b/content/server/10.15/modules/admin_manual/images/configuration/files/federation-3.png deleted file mode 100644 index a9ace38..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/federation-3.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/files_versions/files-versions.png b/content/server/10.15/modules/admin_manual/images/configuration/files/files_versions/files-versions.png deleted file mode 100644 index e523828..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/files_versions/files-versions.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/files_versions/version-metadata.png b/content/server/10.15/modules/admin_manual/images/configuration/files/files_versions/version-metadata.png deleted file mode 100644 index d166fd6..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/files_versions/version-metadata.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-details.png b/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-details.png deleted file mode 100644 index 1719816..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-details.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-hint.png b/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-hint.png deleted file mode 100644 index e8e0417..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-hint.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-symbol.png b/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-symbol.png deleted file mode 100644 index cfde1fb..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-symbol.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-unlock-symbol.png b/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-unlock-symbol.png deleted file mode 100644 index 63d1b76..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/file-locked-unlock-symbol.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/lock-file-not-visible.png b/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/lock-file-not-visible.png deleted file mode 100644 index e22e397..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/lock-file-not-visible.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/lock-file-visible.png b/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/lock-file-visible.png deleted file mode 100644 index c8ee3d9..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/lock-file-visible.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/manual-file-locking-with-lock-breaker.png b/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/manual-file-locking-with-lock-breaker.png deleted file mode 100644 index bba385c..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/manual_file_locking/manual-file-locking-with-lock-breaker.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing-files-settings.png b/content/server/10.15/modules/admin_manual/images/configuration/files/sharing-files-settings.png deleted file mode 100644 index cb0836e..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing-files-settings.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/blacklisting-groups.png b/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/blacklisting-groups.png deleted file mode 100644 index cc705b4..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/blacklisting-groups.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/choose-public-mail-notification-language.png b/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/choose-public-mail-notification-language.png deleted file mode 100644 index f73ce8f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/choose-public-mail-notification-language.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/federated-cloud-sharing/scan-cronjob.png b/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/federated-cloud-sharing/scan-cronjob.png deleted file mode 100644 index d77ae17..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/federated-cloud-sharing/scan-cronjob.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/sharing-files-via-social-media.png b/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/sharing-files-via-social-media.png deleted file mode 100644 index e559ad0..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/sharing/sharing-files-via-social-media.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/files/trashbin-1.png b/content/server/10.15/modules/admin_manual/images/configuration/files/trashbin-1.png deleted file mode 100644 index 88f08b4..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/files/trashbin-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/add-a-tab-ms-teams.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/add-a-tab-ms-teams.png deleted file mode 100644 index dedfc23..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/add-a-tab-ms-teams.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/add-website-ms-teams.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/add-website-ms-teams.png deleted file mode 100644 index cd8a8d9..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/add-website-ms-teams.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/app-description-msteamsgen.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/app-description-msteamsgen.png deleted file mode 100644 index 5d70f50..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/app-description-msteamsgen.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/app-name-msteamsgen.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/app-name-msteamsgen.png deleted file mode 100644 index bf4d877..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/app-name-msteamsgen.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/define-app-version-msteamsgen.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/define-app-version-msteamsgen.png deleted file mode 100644 index 59cf621..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/define-app-version-msteamsgen.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/download-zip-msteamsgen.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/download-zip-msteamsgen.png deleted file mode 100644 index 80d9a88..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/download-zip-msteamsgen.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/enter-app-id-msteamsgen.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/enter-app-id-msteamsgen.png deleted file mode 100644 index 8da113f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/enter-app-id-msteamsgen.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/name-and-url-ms-teams.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/name-and-url-ms-teams.png deleted file mode 100644 index bf58a66..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/name-and-url-ms-teams.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/owncloud-url-msteamsgen.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/owncloud-url-msteamsgen.png deleted file mode 100644 index f13f577..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/owncloud-url-msteamsgen.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/set-accent-color-msteamsgen.png b/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/set-accent-color-msteamsgen.png deleted file mode 100644 index 85c32f4..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/integration/ms-teams/set-accent-color-msteamsgen.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/mimetypes/json-alias-after.png b/content/server/10.15/modules/admin_manual/images/configuration/mimetypes/json-alias-after.png deleted file mode 100644 index 5086e3d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/mimetypes/json-alias-after.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/mimetypes/json-alias-before.png b/content/server/10.15/modules/admin_manual/images/configuration/mimetypes/json-alias-before.png deleted file mode 100644 index 559e61f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/mimetypes/json-alias-before.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/email-configuration/smtp-config-php.png b/content/server/10.15/modules/admin_manual/images/configuration/server/email-configuration/smtp-config-php.png deleted file mode 100644 index db7bb59..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/email-configuration/smtp-config-php.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/email-configuration/smtp-config-smtp.png b/content/server/10.15/modules/admin_manual/images/configuration/server/email-configuration/smtp-config-smtp.png deleted file mode 100644 index 748e5d9..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/email-configuration/smtp-config-smtp.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert-1.png b/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert-1.png deleted file mode 100644 index 9f76d03..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert-2.png b/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert-2.png deleted file mode 100644 index aa3fc47..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert/import-ssl-root-certificates-admin.png b/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert/import-ssl-root-certificates-admin.png deleted file mode 100644 index ceb9b8d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/import-ssl-cert/import-ssl-root-certificates-admin.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/legal-settings/login-form-with-legal-settings-links.png b/content/server/10.15/modules/admin_manual/images/configuration/server/legal-settings/login-form-with-legal-settings-links.png deleted file mode 100644 index 2fbc916..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/legal-settings/login-form-with-legal-settings-links.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/owncloud-webui-legal-urls-configuration.png b/content/server/10.15/modules/admin_manual/images/configuration/server/owncloud-webui-legal-urls-configuration.png deleted file mode 100644 index 83e4973..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/owncloud-webui-legal-urls-configuration.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/password-policy/password-policy-configuration-web-ui.png b/content/server/10.15/modules/admin_manual/images/configuration/server/password-policy/password-policy-configuration-web-ui.png deleted file mode 100755 index e6da3f4..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/password-policy/password-policy-configuration-web-ui.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/security/brute-force-protection.png b/content/server/10.15/modules/admin_manual/images/configuration/server/security/brute-force-protection.png deleted file mode 100644 index b64b626..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/security/brute-force-protection.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/security/oauth2-workflow-diagram.png b/content/server/10.15/modules/admin_manual/images/configuration/server/security/oauth2-workflow-diagram.png deleted file mode 100644 index 4d59696..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/security/oauth2-workflow-diagram.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/security/oauth2_configuration.png b/content/server/10.15/modules/admin_manual/images/configuration/server/security/oauth2_configuration.png deleted file mode 100644 index b12c31e..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/security/oauth2_configuration.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/security/password-policy-app.png b/content/server/10.15/modules/admin_manual/images/configuration/server/security/password-policy-app.png deleted file mode 100644 index 1c36777..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/security/password-policy-app.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/ui-configuration/upload-progress-bar.png b/content/server/10.15/modules/admin_manual/images/configuration/server/ui-configuration/upload-progress-bar.png deleted file mode 100644 index 16e1480..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/ui-configuration/upload-progress-bar.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-configuration-rules.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-configuration-rules.png deleted file mode 100644 index 2491591..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-configuration-rules.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-host-connection-problem.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-host-connection-problem.png deleted file mode 100644 index b5903fe..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-host-connection-problem.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-misconfiguration-problem.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-misconfiguration-problem.png deleted file mode 100644 index c2f488f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-misconfiguration-problem.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-socket-connection-problem.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-socket-connection-problem.png deleted file mode 100644 index 8a75fb8..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/anti-virus-message-socket-connection-problem.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/antivirus-app.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/antivirus-app.png deleted file mode 100644 index 3490b29..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/antivirus-app.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/antivirus-logging.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/antivirus-logging.png deleted file mode 100644 index ca547f5..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/antivirus-logging.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/av_modes.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/av_modes.png deleted file mode 100644 index 70d4899..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/av_modes.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_daemon_socket.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_daemon_socket.png deleted file mode 100644 index fec3645..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_daemon_socket.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_daemon_tcp.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_daemon_tcp.png deleted file mode 100644 index 6772299..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_daemon_tcp.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_executable.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_executable.png deleted file mode 100644 index 2645d5b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/clamav_executable.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/icap_clamav.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/icap_clamav.png deleted file mode 100644 index f97bcdb..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/icap_clamav.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/icap_mcafee.png b/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/icap_mcafee.png deleted file mode 100644 index f381dca..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/server/virus-scanner-support/icap_mcafee.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/custom_groups/custom_groups.png b/content/server/10.15/modules/admin_manual/images/configuration/user/custom_groups/custom_groups.png deleted file mode 100644 index 7db51df..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/custom_groups/custom_groups.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/custom_groups/user_settings_custom_groups.png b/content/server/10.15/modules/admin_manual/images/configuration/user/custom_groups/user_settings_custom_groups.png deleted file mode 100644 index 11d4e4f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/custom_groups/user_settings_custom_groups.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/delete-user-confirmation.png b/content/server/10.15/modules/admin_manual/images/configuration/user/delete-user-confirmation.png deleted file mode 100644 index 5006382..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/delete-user-confirmation.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/guest_app/guest_app_settings.png b/content/server/10.15/modules/admin_manual/images/configuration/user/guest_app/guest_app_settings.png deleted file mode 100644 index 6039a5e..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/guest_app/guest_app_settings.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/admin-consent-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/admin-consent-ms-azure-ad.png deleted file mode 100644 index 86f4300..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/admin-consent-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/app-id-uri-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/app-id-uri-ms-azure-ad.png deleted file mode 100644 index 152ef62..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/app-id-uri-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/graph-permission-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/graph-permission-ms-azure-ad.png deleted file mode 100644 index 8ed53b3..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/graph-permission-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/login-with-ms-azure.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/login-with-ms-azure.png deleted file mode 100644 index bdb0fc8..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/login-with-ms-azure.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/ms-azure-manifest.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/ms-azure-manifest.png deleted file mode 100644 index f1e4043..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/ms-azure-manifest.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/new-registration-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/new-registration-ms-azure-ad.png deleted file mode 100644 index 10c0dd5..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/new-registration-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/overview-screen-ms-azure.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/overview-screen-ms-azure.png deleted file mode 100644 index 7aff353..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/overview-screen-ms-azure.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/portal-tenant-id-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/portal-tenant-id-ms-azure-ad.png deleted file mode 100644 index 70416c2..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/portal-tenant-id-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/provide-required-information-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/provide-required-information-ms-azure-ad.png deleted file mode 100644 index 765788f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/provide-required-information-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/scope-consent-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/scope-consent-ms-azure-ad.png deleted file mode 100644 index a871181..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/scope-consent-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/select-manag-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/select-manag-azure-ad.png deleted file mode 100644 index ba73696..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/select-manag-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-claims-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-claims-ms-azure-ad.png deleted file mode 100644 index dadb1fa..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-claims-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-client-secret-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-client-secret-ms-azure-ad.png deleted file mode 100644 index ea841b9..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-client-secret-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-redirect-url-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-redirect-url-ms-azure-ad.png deleted file mode 100644 index 6d1932e..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-redirect-url-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-web-application-ms-azure-ad.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-web-application-ms-azure-ad.png deleted file mode 100644 index f04b7f0..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/ms-azure-ad/setup-web-application-ms-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-oidc-configuration.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-oidc-configuration.png deleted file mode 100644 index f597e79..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-oidc-configuration.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-oidc-sso.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-oidc-sso.png deleted file mode 100644 index 831f125..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-oidc-sso.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-select-application.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-select-application.png deleted file mode 100644 index 9980e1c..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-select-application.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-select-openid-app.png b/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-select-openid-app.png deleted file mode 100644 index 7270455..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/oidc/onelogin/onelogin-select-openid-app.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/user-page.png b/content/server/10.15/modules/admin_manual/images/configuration/user/user-page.png deleted file mode 100644 index 6356869..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/user-page.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-gear.png b/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-gear.png deleted file mode 100644 index 72e28cb..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-gear.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-group-tab.png b/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-group-tab.png deleted file mode 100644 index dcbfe5c..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-group-tab.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-new-password.png b/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-new-password.png deleted file mode 100644 index d445c56..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-new-password.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-new-user.png b/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-new-user.png deleted file mode 100644 index d07312b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page-new-user.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page.png b/content/server/10.15/modules/admin_manual/images/configuration/user/users-page.png deleted file mode 100644 index 328f146..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/configuration/user/users-page.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/docker/owncloud-ui-login.png b/content/server/10.15/modules/admin_manual/images/docker/owncloud-ui-login.png deleted file mode 100644 index 1aec8a2..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/docker/owncloud-ui-login.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/enterprise-only-auth/authentication-backends.png b/content/server/10.15/modules/admin_manual/images/enterprise/authentication/enterprise-only-auth/authentication-backends.png deleted file mode 100644 index 6f409e9..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/enterprise-only-auth/authentication-backends.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/enterprise-only-auth/global-credentials.png b/content/server/10.15/modules/admin_manual/images/enterprise/authentication/enterprise-only-auth/global-credentials.png deleted file mode 100644 index a6964a6..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/enterprise-only-auth/global-credentials.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-login-screenshot.png b/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-login-screenshot.png deleted file mode 100644 index 979e86f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-login-screenshot.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-principle.drawio.svg b/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-principle.drawio.svg deleted file mode 100644 index 4d98138..0000000 --- a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-principle.drawio.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - -
Once per User Login Session
Once per User Lo...
1
1
2
2
3
3
  ownCloud requests  
  on behalf of the user  
ownCloud requests...
ownCloud Server
ownCloud Server
Once per
Sevice Session
Once per...
Request Ticket-Granting Ticket
Request Ticket-Granting Tick...
TGT +  Session Key
TGT +  Session Key
Request Ticket + Auth
Request Ticket + Auth
Ticket +  Session Key
Ticket +  Session Key
Request Service + Auth
Request Service + Auth
Server Authentication
Server Authentication
File Server
File Server
Client
Client
Once per Type of Service
Once per Type...
Kerberos Key Distribution Center
Kerberos Key Distribution Center
Authentication Server
AS
Authentication Server...
Ticket Granting Server
TGS
Ticket Granting Serve...
user/group/service/computer
database
user/group...
Windows/Samba Domain Controller
Windows/Samba Domain Controller
User
User
keytab
File
keytab...
Domain Member
Domain Member
Text is not SVG - cannot display
\ No newline at end of file diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-win-principal.png b/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-win-principal.png deleted file mode 100644 index bd6e215..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/authentication/kerberos/kerberos-win-principal.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/classification/document_classification.png b/content/server/10.15/modules/admin_manual/images/enterprise/classification/document_classification.png deleted file mode 100644 index ca2bc07..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/classification/document_classification.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/collaboration/access-denied.png b/content/server/10.15/modules/admin_manual/images/enterprise/collaboration/access-denied.png deleted file mode 100644 index e254112..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/collaboration/access-denied.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-1.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-1.png deleted file mode 100644 index 94d63de..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-2.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-2.png deleted file mode 100644 index 1849f1b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-3.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-3.png deleted file mode 100644 index 26d1fb6..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-3.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-diagram.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-diagram.png deleted file mode 100644 index c882bcf..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/ldap-home-connector/ldap-home-connector-diagram.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-1.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-1.png deleted file mode 100644 index 9a67f78..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-2.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-2.png deleted file mode 100644 index 7cbd5aa..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-3.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-3.png deleted file mode 100644 index dbfaac8..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-3.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-4.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-4.png deleted file mode 100644 index 9e9455d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/sharepoint/sharepoint-4.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/acl-permissions-manager.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/acl-permissions-manager.png deleted file mode 100644 index 154995f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/acl-permissions-manager.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/activity_file_change_notification.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/activity_file_change_notification.png deleted file mode 100644 index eb97e12..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/activity_file_change_notification.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_add_storage.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_add_storage.png deleted file mode 100644 index d4e0366..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_add_storage.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_fields.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_fields.png deleted file mode 100644 index 15a4cb7..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_fields.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_login_possibilities.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_login_possibilities.png deleted file mode 100644 index cccb4bc..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_login_possibilities.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_regain_mount_access.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_regain_mount_access.png deleted file mode 100644 index d67ce9b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/cwnd_regain_mount_access.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-available-for.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-available-for.png deleted file mode 100644 index cbec112..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-available-for.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-config-key.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-config-key.png deleted file mode 100644 index 678f445..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-config-key.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-gear-icon.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-gear-icon.png deleted file mode 100644 index 527141a..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-gear-icon.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-kerberos-1.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-kerberos-1.png deleted file mode 100644 index ab80fc4..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-kerberos-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-kerberos-2.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-kerberos-2.png deleted file mode 100644 index 476e2b0..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-kerberos-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-ldap-exposed-user-attributes.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-ldap-exposed-user-attributes.png deleted file mode 100644 index 10b38b3..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-ldap-exposed-user-attributes.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-username-pwd.png b/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-username-pwd.png deleted file mode 100644 index 8d66d26..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/external_storage/windows_network_drive/wnd-username-pwd.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/update_workflow.png b/content/server/10.15/modules/admin_manual/images/enterprise/file_management/update_workflow.png deleted file mode 100644 index 6bd241d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/update_workflow.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-1.png b/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-1.png deleted file mode 100644 index a327dd1..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-2.png b/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-2.png deleted file mode 100644 index 18d5b2b..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-3.png b/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-3.png deleted file mode 100644 index cb18dc3..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-3.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-4.png b/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-4.png deleted file mode 100644 index 15a55a9..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-4.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-5.png b/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-5.png deleted file mode 100644 index c8c57f6..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/file_management/workflow-5.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-1.png b/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-1.png deleted file mode 100644 index badd3e0..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-2.png b/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-2.png deleted file mode 100644 index b6e7760..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-3.png b/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-3.png deleted file mode 100644 index 5e1e440..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/firewall/firewall-3.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/logging/admin_auditing.png b/content/server/10.15/modules/admin_manual/images/enterprise/logging/admin_auditing.png deleted file mode 100644 index 9cb9a4e..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/logging/admin_auditing.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/reporting/metrics/metrics-system.png b/content/server/10.15/modules/admin_manual/images/enterprise/reporting/metrics/metrics-system.png deleted file mode 100644 index 78116bc..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/reporting/metrics/metrics-system.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/enterprise/reporting/metrics/metrics-user.png b/content/server/10.15/modules/admin_manual/images/enterprise/reporting/metrics/metrics-user.png deleted file mode 100644 index 4c39772..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/enterprise/reporting/metrics/metrics-user.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/external-sites-1.png b/content/server/10.15/modules/admin_manual/images/external-sites-1.png deleted file mode 100644 index 7ff0fa2..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/external-sites-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/external-sites-2.png b/content/server/10.15/modules/admin_manual/images/external-sites-2.png deleted file mode 100644 index 78544a4..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/external-sites-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/external-sites-3.png b/content/server/10.15/modules/admin_manual/images/external-sites-3.png deleted file mode 100644 index 42a5884..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/external-sites-3.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/external-sites-4.png b/content/server/10.15/modules/admin_manual/images/external-sites-4.png deleted file mode 100644 index a8f64a3..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/external-sites-4.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/external-sites-5.png b/content/server/10.15/modules/admin_manual/images/external-sites-5.png deleted file mode 100644 index 67dedcf..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/external-sites-5.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/deprecs-1.png b/content/server/10.15/modules/admin_manual/images/installation/deprecs-1.png deleted file mode 100644 index c52b347..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/deprecs-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/deprecs-2.png b/content/server/10.15/modules/admin_manual/images/installation/deprecs-2.png deleted file mode 100644 index 6456437..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/deprecs-2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/deprecs-3.png b/content/server/10.15/modules/admin_manual/images/installation/deprecs-3.png deleted file mode 100644 index fb69d42..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/deprecs-3.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/install-wizard-a.jpg b/content/server/10.15/modules/admin_manual/images/installation/install-wizard-a.jpg deleted file mode 100644 index b1d217e..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/install-wizard-a.jpg and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/install-wizard-a1.jpg b/content/server/10.15/modules/admin_manual/images/installation/install-wizard-a1.jpg deleted file mode 100644 index 6f50ccb..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/install-wizard-a1.jpg and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/manual_installation/phpmyadmin_v4.9.5deb2.png b/content/server/10.15/modules/admin_manual/images/installation/manual_installation/phpmyadmin_v4.9.5deb2.png deleted file mode 100644 index 6b6477a..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/manual_installation/phpmyadmin_v4.9.5deb2.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/manual_installation/phpmyadmin_v5.2.0.png b/content/server/10.15/modules/admin_manual/images/installation/manual_installation/phpmyadmin_v5.2.0.png deleted file mode 100644 index b5bb627..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/manual_installation/phpmyadmin_v5.2.0.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/ssllabs.png b/content/server/10.15/modules/admin_manual/images/installation/ssllabs.png deleted file mode 100644 index decdcb3..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/ssllabs.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/top_menu_showing_market_app.png b/content/server/10.15/modules/admin_manual/images/installation/top_menu_showing_market_app.png deleted file mode 100644 index 5417267..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/top_menu_showing_market_app.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/installation/webservers/apache/mod_unique_id/phpinfo.png b/content/server/10.15/modules/admin_manual/images/installation/webservers/apache/mod_unique_id/phpinfo.png deleted file mode 100644 index 89e91bc..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/installation/webservers/apache/mod_unique_id/phpinfo.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/issues/code-integrity-admin.png b/content/server/10.15/modules/admin_manual/images/issues/code-integrity-admin.png deleted file mode 100644 index 5af80b8..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/issues/code-integrity-admin.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/issues/code-integrity-notification.png b/content/server/10.15/modules/admin_manual/images/issues/code-integrity-notification.png deleted file mode 100644 index 4001bf1..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/issues/code-integrity-notification.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/ldap-fetched-avatar.png b/content/server/10.15/modules/admin_manual/images/ldap-fetched-avatar.png deleted file mode 100644 index 15a3f58..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/ldap-fetched-avatar.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-api-settings.png b/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-api-settings.png deleted file mode 100644 index 8f40ed3..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-api-settings.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-migration.drawio.svg b/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-migration.drawio.svg deleted file mode 100644 index d4db0b5..0000000 --- a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-migration.drawio.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - -
Database
Database
Local Users and Groups
Local Users a...
LDAP
LDAP
Kerberos (Enterprise)
Kerberos (Enterprise)
Database
Database
Enterprise Subscription
Enterprise...
Storage Mounts
Storage Mounts
Home
Home
WND
smb variant
WND...
Share Point
Share Po...
...
...
Google Drive
Google D...
DropBox
DropBox
SFTP
SFTP
...
...
SMB
SMB
Kiteworks Enterprise Connect
Kiteworks...
Home
Home
Storage Mounts
Storage Mounts
Google Drive
Google D...
DropBox
DropBox
SFTP
SFTP
SMB
SMB
Share Point
Share Po...
...
...
Migration
Mig...
Private Content Network
Private Content Network
Local Users and Groups
Local Users a...
LDAP
LDAP
Kerberos (Enterprise)
Kerberos (Enterprise)
Text is not SVG - cannot display
\ No newline at end of file diff --git a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-new-satellite.png b/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-new-satellite.png deleted file mode 100644 index fe3d475..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-new-satellite.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-satellite.png b/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-satellite.png deleted file mode 100644 index 4315e6d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-satellite.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-system-load-cpu.png b/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-system-load-cpu.png deleted file mode 100644 index b4c32b7..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-system-load-cpu.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-system-load-dataio.png b/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-system-load-dataio.png deleted file mode 100644 index 99fd493..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-system-load-dataio.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-users-collaboration.png b/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-users-collaboration.png deleted file mode 100644 index f8de46d..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/maintenance/migrate_kiteworks/kiteworks-users-collaboration.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/oc_admin_apps.png b/content/server/10.15/modules/admin_manual/images/oc_admin_apps.png deleted file mode 100644 index 2e10de5..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/oc_admin_apps.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/oracle-1.png b/content/server/10.15/modules/admin_manual/images/oracle-1.png deleted file mode 100644 index 17ecb70..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/oracle-1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/phpinfo.png b/content/server/10.15/modules/admin_manual/images/phpinfo.png deleted file mode 100644 index e18a425..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/phpinfo.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/preview_images.png b/content/server/10.15/modules/admin_manual/images/preview_images.png deleted file mode 100644 index bf90e1f..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/preview_images.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/security-setup-warning-complete.png b/content/server/10.15/modules/admin_manual/images/security-setup-warning-complete.png deleted file mode 100644 index 2bfb65e..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/security-setup-warning-complete.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/shib-gui5.png b/content/server/10.15/modules/admin_manual/images/shib-gui5.png deleted file mode 100644 index 1fbf3ae..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/shib-gui5.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/shib-gui6.png b/content/server/10.15/modules/admin_manual/images/shib-gui6.png deleted file mode 100644 index a9f0c33..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/shib-gui6.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/skeleton-files.png b/content/server/10.15/modules/admin_manual/images/skeleton-files.png deleted file mode 100644 index 7b6bb3c..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/skeleton-files.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/images/skeleton-files1.png b/content/server/10.15/modules/admin_manual/images/skeleton-files1.png deleted file mode 100644 index 793e3fa..0000000 Binary files a/content/server/10.15/modules/admin_manual/images/skeleton-files1.png and /dev/null differ diff --git a/content/server/10.15/modules/admin_manual/notes_for_the_navigation_file_nav.txt b/content/server/10.15/modules/admin_manual/notes_for_the_navigation_file_nav.txt deleted file mode 100644 index f86388b..0000000 --- a/content/server/10.15/modules/admin_manual/notes_for_the_navigation_file_nav.txt +++ /dev/null @@ -1,13 +0,0 @@ -The navigation files have been relocated and are accessed differently now. - -The main nav.adoc file is in ROOT and includes all nav.adoc files from the modules. To do so, the modules nav.adoc files needed to be relocated from: - -{modulesdir}/nav.adoc -to -{modulesdir}/partials/nav.adoc - -This is due to the fact that "Antora does not classify files located at the root of the module or in the modules folder" which means, there is no access path to a nav.adoc file which is located in the root of a module. - -As a result, the antora.yml file only contains the main ROOT/nav.adoc file. - -This is beneficial, as we now can structure products and their content in a better way. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/database/db_conversion.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/database/db_conversion.adoc deleted file mode 100644 index d4a1aa1..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/database/db_conversion.adoc +++ /dev/null @@ -1,108 +0,0 @@ -= Converting Database Type -:toc: right -:page-aliases: go/admin-db-conversion.adoc - -== Introduction - -SQLite is good for testing ownCloud, as well as small, single-user, -ownCloud servers. But, *it does not scale* for large, multi-user sites. -If you have an existing ownCloud installation which uses SQLite, and you -want to convert to a better performing database, such as _MySQL_, -_MariaDB_ or _PostgreSQL_, you can use -the ownCloud command line tool: xref:configuration/server/occ_command.adoc#convert-the-database-type[occ]. - -NOTE: ownCloud Enterprise edition does not support SQLite. - -== Preparation - -Add the following to your ownCloud `config/config.php`: - -[source,php] ----- -'mysql.utf8mb4' => true, ----- - -Add, or adjust, the following in `/etc/mysql/mariadb.conf.d/50-server.cnf`: - -NOTE: You can do the same for MySQL by replacing `mariadb.conf.d/50-server.cnf` with `mysql.conf.d/mysqld.cnf`. - -[source,mysql] ----- -key_buffer_size = 32M -table_cache = 400 -query_cache_size = 128M - -#in InnoDB: -innodb_flush_method=O_DIRECT -innodb_log_file_size=256M -innodb_log_buffer_size = 128M -innodb_buffer_pool_size=2048M -innodb_buffer_pool_instances=3 -innodb_io_capacity = 500 -innodb_file_format=Barracuda -character-set-server = utf8mb4 -collation-server = utf8mb4_general_ci ----- - -== Restart the Database Server - -When you have changed the database parameters, restart your database by running following command: - -[source,bash] ----- -sudo service mysql restart ----- - -== Run the conversion - -After you have restarted the database, run the following occ command in your ownCloud root folder, to convert the database to the new format: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} db:convert-type [options] type username hostname database ----- - -[NOTE] -==== -The converter searches for apps in your configured app folders and uses the schema definitions in the apps to create the new table. -As a result, tables of removed apps will not be converted — even with option `--all-apps` -For example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} db:convert-type --all-apps mysql oc_mysql_user 127.0.0.1 new_db_name ----- -==== - -To successfully proceed with the conversion, you must type `yes` when -prompted with the question `Continue with the conversion?` On success -the converter will automatically configure the new database in your -ownCloud config `config.php`. - -== Unconvertible Tables - -If you updated your ownCloud installation then the old tables, which are -not used anymore, might still exist. The converter will tell you which ones. - -[source,plaintext] ----- -The following tables will not be converted: - oc_permissions ----- - -You can ignore these tables. Here is a list of known old tables: - -* `oc_calendar_calendars` -* `oc_calendar_objects` -* `oc_calendar_share_calendar` -* `oc_calendar_share_event` -* `oc_fscache` -* `oc_log` -* `oc_media_albums` -* `oc_media_artists` -* `oc_media_sessions` -* `oc_media_songs` -* `oc_media_users` -* `oc_permissions` -* `oc_queuedtasks` -* `oc_sharing` diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/database/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/database/index.adoc deleted file mode 100644 index b0a283a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/database/index.adoc +++ /dev/null @@ -1,7 +0,0 @@ -= Database - -In this section, you can find out about - -- xref:configuration/database/db_conversion.adoc[Converting your Database Type] -- xref:configuration/database/linux_database_configuration.adoc[Database Configuration on Linux] - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/database/linux_database_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/database/linux_database_configuration.adoc deleted file mode 100644 index ad2fb25..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/database/linux_database_configuration.adoc +++ /dev/null @@ -1,438 +0,0 @@ -= Database Configuration on Linux -:toc: right -:avoid-deadlocks-galery-haproxy-url: https://severalnines.com/blog/avoiding-deadlocks-galera-set-haproxy-single-node-writes-and-multi-node-reads -:haproxy-url: https://www.haproxy.org/ -:maxscale-url: https://github.com/mariadb-corporation/MaxScale/wiki -:maxscale-readwrite-splitting-with-galera-cluster-url: https://mariadb.com/kb/en/mariadb-enterprise/mariadb-maxscale-14/maxscale-readwrite-splitting-with-galera-cluster/ -:mysql-set-transaction-url: https://dev.mysql.com/doc/refman/5.7/en/set-transaction.html -:mariadb-binary-log-overview-url: https://mariadb.com/kb/en/mariadb/overview-of-the-binary-log/ -:mysql-binary-log-overview-url: https://dev.mysql.com/doc/refman/5.6/en/binary-log.html -:mariadb-docs-url: https://mariadb.com/kb/en/ -:mysql-docs-url: https://dev.mysql.com/doc/ -:oracle-docs-url: https://docs.oracle.com/en/database/oracle/oracle-database/index.html -:postgresql-docs-url: https://www.postgresql.org/docs/manuals/ - -== Introduction - -ownCloud requires a database in which administrative data is stored. -The following databases are currently supported: - -* xref:mysql-mariadb[MySQL / MariaDB] -* xref:postgresql[PostgreSQL] -* xref:enterprise/installation/oracle_db_configuration.adoc[Oracle (_ownCloud Enterprise edition only_)] - -NOTE: The MySQL or MariaDB databases are the recommended database engines. - -IMPORTANT: After physically installing ownCloud, the setup of the owncloud database is either -done with the xref:installation/installation_wizard.adoc[installation wizard] or via the -command line. For more information see the -xref:installation/manual_installation/manual_installation.adoc#complete-the-installation[Complete the Installation] -section in the Manual Installation documentation. - -== Requirements - -Choosing to use MySQL / MariaDB, PostgreSQL, or Oracle as your database requires, -that you install and set up the server software first. - -TIP: Oracle users, see -xref:enterprise/installation/oracle_db_configuration.adoc[the Oracle Database Configuration guide]. - -The steps for configuring a third party database are beyond the scope of this document. -Please refer to the documentation below, for your database vendor. - -* The {mariadb-docs-url}[MariaDB Knowledge Base] -* The {mysql-docs-url}[MySQL documentation] -* The {oracle-docs-url}[Oracle Database documentation] -* The {postgresql-docs-url}[PostgreSQL documentation] - -=== MySQL / MariaDB - -==== Enabling Binary Logging - -ownCloud is currently using a `TRANSACTION_READ_COMMITTED` transaction isolation to avoid -data loss under high load scenarios (e.g., by using the sync client with many -clients/users and many parallel operations). This requires a disabled or correctly configured -binary logging when using MySQL or MariaDB. Your system is affected if you see the following -in your log file during the installation or update of ownCloud: - -[source,plaintext] ----- -An unhandled exception has been thrown: exception `PDOException' with message `SQLSTATE[HY000]: General error: 1665 Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED.' ----- - -There are two solutions: - -* One is to disable binary logging. Binary logging records all changes to your database, and how long each change took. The purpose of binary logging is to enable replication and to support backup operations. - -* The other is to change the BINLOG_FORMAT = STATEMENT in your database configuration file, -or possibly in your database startup script, to BINLOG_FORMAT = MIXED or BINLOG_FORMAT = ROW. -See {mariadb-binary-log-overview-url}[Overview of the Binary Log] and -{mysql-binary-log-overview-url}[The Binary Log] for detailed information. - -==== Set `READ COMMITTED` as the Transaction Isolation Level - -As discussed above, ownCloud is using the `TRANSACTION_READ_COMMITTED` transaction isolation -level. Some database configurations are enforcing other transaction isolation levels. -To avoid data loss under high load scenarios (e.g., by using the sync client with many -clients/users and many parallel operations), you need to configure the transaction isolation -level accordingly. Please refer to the {mysql-set-transaction-url}[MySQL manual] -for detailed information. - -==== Configuring the Storage Engine - -Since ownCloud 7, only InnoDB is supported as a storage engine. -Some shared hosts do not support InnoDB and only MyISAM. -Running ownCloud in such an environment is not supported. - -== Parameters - -For setting up ownCloud to use any database, use the instructions in -xref:installation/installation_wizard.adoc[the Installation Wizard]. -You should not have to edit the respective values in the `config/config.php`. -However, in exceptional cases (for example, if you want to connect your ownCloud instance -to a database created by a previous installation of ownCloud), some modification might -be required. - -=== MySQL / MariaDB - -If you decide to use a MySQL or MariaDB database, ensure the following: - -* That you have installed and enabled the `pdo_mysql` extension in PHP. -* That the `mysql.default_socket` points to the correct socket (if the database runs on - the same server as ownCloud). - -MariaDB is backward compatible with MySQL. -All instructions work for both, so you will not need to replace or revise any existing -MySQL client commands. The PHP configuration in -`/etc/php/{recommended-php-version}/apache2/conf.d/20-mysql.ini` could look like this: - -[source,ini] ----- -# configuration for PHP MySQL module -extension=pdo_mysql.so - -[mysql] -mysql.allow_local_infile=On -mysql.allow_persistent=On -mysql.cache_size=2000 -mysql.max_persistent=-1 -mysql.max_links=-1 -mysql.default_port= -mysql.default_socket=/var/lib/mysql/mysql.sock # Debian squeeze: /var/run/mysqld/mysqld.sock -mysql.default_host= -mysql.default_user= -mysql.default_password= -mysql.connect_timeout=60 -mysql.trace_mode=Off ----- - -An ownCloud instance configured with MySQL would contain the hostname on which the database -is running, a valid username and password to access it, and the name of the database. The -`config/config.php` as created by the -xref:installation/installation_wizard.adoc[installation wizard] -would therefore contain entries like this: - -[source,php] ----- - "mysql", -"dbname" => "owncloud", -"dbuser" => "username", -"dbpassword" => "password", -"dbhost" => "localhost", -"dbtableprefix" => "oc_", ----- - -==== Configure MySQL for 4-byte Unicode Support - -For supporting such features as emoji, both MySQL (or MariaDB) *and* ownCloud need to be -capable of using 4-byte Unicode instead of the default 3-byte and configured accordingly. - -[NOTE] -==== -If you are setting up - -* a new ownCloud installation, using version 10.0 or above, *and* -* you’re using a _minimum_ MySQL version of 5.7 - -*then you don’t need to do anything*, as support is checked during setup and used if available. -==== - -However, if - -* you have an *existing* ownCloud installation that you need to convert to use 4-byte Unicode support + -*or* -* you are working with a MySQL version _earlier_ than version 5.7 - -then you need to do two things: - -. In your MySQL configuration, add the configuration settings below. -If you already have them configured, update them to reflect the values specified: -+ -[source,mysql] ----- -[mysqld] -innodb_large_prefix=ON -innodb_file_format=Barracuda -innodb_file_per_table=ON ----- - -. Run the following occ command: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} db:convert-mysql-charset ----- -+ -When this is done, tables will be created with: -+ -* A `utf8mb4` character set. -* A `utf8mb4_bin` collation. -* `row_format` set to compressed. - -[TIP] -==== -For more information, please either refer to -xref:configuration/server/config_sample_php_parameters.adoc[config.sample.php], -or have a read through the following links: - -* https://dev.mysql.com/doc/refman/5.7/en/innodb-parameters.html#sysvar_innodb_large_prefix -* https://mariadb.com/kb/en/library/innodb-system-variables/#innodb_large_prefix -* http://www.tocker.ca/benchmarking-innodb-page-compression-performance.html -* http://dev.mysql.com/doc/refman/5.7/en/charset-unicode-utf8mb4.html -* https://dev.mysql.com/doc/refman/5.7/en/innodb-file-format.html -* https://dev.mysql.com/doc/refman/5.7/en/innodb-parameters.html#sysvar_innodb_large_prefix -==== - -=== PostgreSQL - -If you decide to use a PostgreSQL database, make sure that you have installed and enabled the -{php-net-url}/manual/en/book.pgsql.php[PostgreSQL extension] and the -{php-net-url}/manual/en/ref.pdo-pgsql.php[PostgreSQL PDO extension] in PHP. The PHP -configuration in `/etc/php/{recommended-php-version}/apache2/conf.d/20-pgsql.ini` -could look like this: - -[source,bash] ----- -# configuration for PHP PostgreSQL module -extension=pdo_pgsql.so -extension=pgsql.so - -[PostgresSQL] -pgsql.allow_persistent = On -pgsql.auto_reset_persistent = Off -pgsql.max_persistent = -1 -pgsql.max_links = -1 -pgsql.ignore_notice = 0 -pgsql.log_notice = 0 ----- - -[TIP] -==== -The default configuration for PostgreSQL (at least in Ubuntu 14.04) is to use the peer -authentication method. Check `/etc/postgresql/9.3/main/pg_hba.conf` to find out which -authentication method is used in your setup. -==== - -To start the PostgreSQL command-line mode use: - -[source,bash] ----- -sudo -u postgres psql -d template1 ----- - -Then a `template1=\#` prompt will appear. You can now enter your commands as required. When -finished, you can quit the prompt by entering: - -[source,psql] ----- -\q ----- - -An ownCloud instance configured with PostgreSQL will contain the hostname on which the -database is running, a valid username and password to access it, and the name of the -database. The `config/config.php` as created by -xref:installation/installation_wizard.adoc[the Installation Wizard] -would contain entries like this: - -[source,php] ----- - "pgsql", -"dbname" => "owncloud", -"dbuser" => "username", -"dbpassword" => "password", -"dbhost" => "localhost", -"dbtableprefix" => "oc_", ----- - -== Troubleshooting - -=== How to Workaround General Error: 2006 MySQL Server Has Gone Away - -The database request takes too long, and therefore the MySQL server times out. It's also -possible that the server is dropping a packet that is too large. Please refer to the manual -of your database for how to raise the configuration options `wait_timeout` and/or -`max_allowed_packet`. - -Some shared hosts are not allowing access to these config options. For such systems, -ownCloud is providing a `dbdriveroptions` configuration option within your `config/config.php` -where you can pass such options to the database driver. Please refer to -xref:configuration/server/config_sample_php_parameters.adoc[the sample PHP configuration parameters] -for an example. - -=== How Can I Find Out If My MySQL/PostgreSQL Server Is Reachable? - -To check the server’s network availability, use the ping command on the server's hostname -(`db.server.com` in this example): - -[source,bash] ----- -ping db.server.com - -PING db.server.com (ip-address) 56(84) bytes of data. -64 bytes from your-server.local.lan (192.168.1.10): icmp_req=1 ttl=64 time=3.64 ms -64 bytes from your-server.local.lan (192.168.1.10): icmp_req=2 ttl=64 time=0.055 ms -64 bytes from your-server.local.lan (192.168.1.10): icmp_req=3 ttl=64 time=0.062 ms ----- - -For a more detailed check whether the access to the database server software itself works -correctly, see the next question. - -=== How Can I Find Out If a Created User Can Access a Database? - -The easiest way to test if a database can be accessed is by starting the command-line interface: - -==== MySQL - -Assuming the database server is installed on the same system you’re running the command -from, use: - -[source,bash] ----- -mysql -uUSERNAME -p ----- - -To access a MySQL installation on a different machine, add the -h option with the -respective hostname: - -[source,bash] ----- -mysql -uUSERNAME -p -h HOSTNAME ----- - -[source,mysql] ----- -mysql> SHOW VARIABLES LIKE "version"; -+---------------+--------+ -| Variable_name | Value | -+---------------+--------+ -| version | 5.1.67 | -+---------------+--------+ -1 row in set (0.00 sec) -mysql> quit ----- - -==== PostgreSQL - -Assuming the database server is installed on the same system you’re running the command -from, use: - -[source,psql] ----- -psql -Uusername -downcloud ----- - -To access a PostgreSQL installation on a different machine, add the `-h` option with the applicable hostname: - -[source,psql] ----- -psql -Uusername -downcloud -h HOSTNAME ----- - -[source,psql] ----- -postgres=# SELECT version(); -PostgreSQL 8.4.12 on i686-pc-linux-gnu, compiled by GCC gcc (GCC) 4.1.3 20080704 (prerelease), 32-bit -(1 row) -postgres=# \q ----- - -=== Useful SQL Commands - -==== Show Database Users - -[options="header",cols="2"] -|=== -|MySQL -|PostgreSQL - -|`SELECT User,Host FROM mysql.user;` -|`SELECT * FROM pg_user;` -|=== - -==== Show Available Databases - -[options="header",cols="2"] -|=== -|MySQL -|PostgreSQL - -|`SHOW DATABASES;` -|`\l` -|=== - -==== Show ownCloud Tables in Database - -[options="header",cols="2"] -|=== -|MySQL -|PostgreSQL - -|`USE owncloud; SHOW TABLES;` -|`\c owncloud; \d` -|=== - -==== Quit Database - -[options="header",cols="2"] -|=== -|MySQL -|PostgreSQL - -|`quit;` -|`\q` -|=== - -=== How to Solve Deadlock Errors - -[source,plaintext] ----- -SQLSTATE[40001]: Serialization failure: 1213 Deadlock found when trying to get lock; try restarting transaction ----- - -==== Explanation - -This error occurs when two transactions write and commit to the same rows in separate -cluster nodes. Only one of them can successfully commit. The failing one will be aborted. -For cluster level aborts, Galera Cluster returns a deadlock error. - -==== Solution - -The solution, for Galera Cluster, would be to send all write requests to a single DB node, -instead of all of them. Here is {avoid-deadlocks-galery-haproxy-url}[a useful guide], -when using {haproxy-url}[HAProxy]. - -The same concept applies when {maxscale-url}[MaxScale] is used as a DB proxy. It needs to be -configured to send all write requests to a single DB node instead all of them and balance -read statements across the rest of the nodes. Here is -{maxscale-readwrite-splitting-with-galera-cluster-url}[a useful guide] -on how to configure MaxScale with Read/Write splitting. - -==== Enabling Causality Checks - -Additionally, to solve this issue, when using Galera Cluster, customers should try to set -`wsrep_sync_wait=1`. When enabled, the node triggers causality checks in response to certain -types of queries. This is disabled by default. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/big_file_upload_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/big_file_upload_configuration.adoc deleted file mode 100644 index bc84ff5..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/big_file_upload_configuration.adoc +++ /dev/null @@ -1,218 +0,0 @@ -= Big File Upload Configuration -:toc: right -:stem: -:mod_reqtimeout-url: https://httpd.apache.org/docs/current/mod/mod_reqtimeout.html -:limitrequestbody-url: https://httpd.apache.org/docs/current/en/mod/core.html#limitrequestbody -:sslrenegbuffersize-url: https://httpd.apache.org/docs/current/mod/mod_ssl.html#sslrenegbuffersize -:fcgidmaxrequestinmem-url: https://httpd.apache.org/mod_fcgid/mod/mod_fcgid.html#fcgidmaxrequestinmem -:fcgidmaxrequestlen-url: https://httpd.apache.org/mod_fcgid/mod/mod_fcgid.html#fcgidmaxrequestlen -:mod_fcgid_bug_51747-url: https://bz.apache.org/bugzilla/show_bug.cgi?id=51747 -:userini: .user.ini -:htaccess: .htaccess - -== Introduction - -If you're expecting big file uploads, some considerations have to be taken into account. Setups based on your needs can be configured. - -== General Considerations - -* Make sure that a version of PHP xref:installation/system_requirements.adoc[supported by ownCloud] is installed. -* Consider that user quotas may prevent big file uploads due to a user reaching the space limitation. -* Though ownCloud already disables the PHP setting *Output Buffering* in the shipped `.htaccess` and `.user.ini` to prevent PHP memory-related errors, it can be the case that you must manually set it in your `php.ini` or `VirtualHosts` when the other two configuration files can't be used in your environment. -* The directory used for `upload_tmp_dir` must be fully accessible by PHP / the webserver user, usually `www-data`. -* Your temp directory or partition has to be big enough to hold multiple parallel uploads from multiple users. The formula for this is `temp_space = concurrent_uploads * chunk size` + -For example, if the chunk size is *10MB* (which is the default but might vary between different clients) and the average number of users uploading at the same time is *25*, then you’ll need 250MB of temp space, as the formula below shows. -+ ----- -10MB x 25 users = 250MB required temp space ----- -* The user's upload directory, usually in `//uploads` (see xref:configuration/server/config_sample_php_parameters.adoc#define-the-directory-where-user-files-are-stored[Sample Config PHP Parameters] for details) also has to be big enough. The formula is a bit different, as this directory collects all chunks of a file for that upload for that user until the upload is completed. The space needed for this directory is temporarily the same size as for the final file size. As an example, if a user wants to upload a 4GB file, temporarily 4GB of space needs to be available in the upload directory to hold the chunks. When the upload has finished, all chunks are written to the final destination and the chunks are deleted afterwards freeing that temporary space. The formula for the upload directory's temp space for all users is: `temp_space = concurrent_uploads * average_upload_size_per_user`. The location of the upload directory can be defined via the config setting xref:configuration/server/config_sample_php_parameters.adoc#define-the-dav-chunk-base-directory[dav.chunk_base_dir]. -[NOTE] -==== -The space temporarily consumed in the upload directory will not count against the user quota. If a user has no quota left in his peronal storage and the quota excludes external mounts, uploads to a windows network drive share as example will succeed. The file temporarily created in the upload directory will not count against his personal storage. -==== -* In Centos and RHEL, Apache has a few more default configurations within systemd. -+ -[NOTE] -==== -You will have to set the `temp` directory in two places: - -. In php.ini, e.g., `sys_temp_dir = "/scratch/tmp"` -. In Apache systemd file e.g. `sudo systemctl edit httpd` and change/add: -+ ----- -PrivateTmp=false ----- - -When done, you need to reload the daemon and restart the service: - -[source,bash] ----- -sudo systemctl daemon-reload -sudo systemctl restart httpd ----- - -Please **do not** change `/usr/lib/systemd/system/httpd.service` directly, only use `sudo systemctl edit httpd`. If not doing so, a httpd package upgrade may revert your changes. -==== - -== Configuration via .htaccess/user.ini - -NOTE: ownCloud comes with its own `owncloud/.htaccess` file. When using `php-fpm`, PHP settings in `.htaccess` are not accessed. These settings must then be set in the `{userini}` file. `php-fpm` will read settings from any {userini} file in the same directory as the .php file that is being served via a web server. - -Set the following parameters inside the corresponding file using your own desired values, as in the following examples, both files are located in the ownCloud root folder: - -{userini}:: -[source,php] ----- -post_max_size=16G -output_buffering=0 -upload_max_filesize=16G -upload_tmp_dir=/mnt/php_big_temp/ ----- - -{htaccess}:: -[source,php] ----- -php_value post_max_size=16G -php_value output_buffering=0 -php_value upload_max_filesize=16G -php_value upload_tmp_dir=/mnt/php_big_temp/ ----- - -If you see PHP timeouts in your log files, increase the timeout values, which are in seconds, as in the example below. Use the `php_value` prefix like above when configuring the `{htaccess}` file: - -[source,php] ----- -max_input_time=3600 -max_execution_time=3600 ----- - -NOTE: Consider that any settings made in `{htaccess}` or `{userini}` may need to be repopulated after an upgrade of ownCloud. - -== Configuring via PHP Global Settings - -If you don't want to use the ownCloud `.htaccess` or `.user.ini` file, you may configure PHP globally instead. -Make sure to comment out or remove any lines in `.htaccess` if you added any like in the section above. - -NOTE: If you are running ownCloud on a 32-bit system, any `open_basedir` directive in your `php.ini` file needs to be commented out. - -See the *Loaded Configuration File* section of xref:configuration/general_topics/general_troubleshooting.adoc#php-version-and-information[PHP Version and Information] to find your relevant php.ini files. - -Set the following parameters inside the corresponding php.ini file using your own desired file size values, as in the following example: - -[source,php] ----- -post_max_size=16G -output_buffering=0 -upload_max_filesize=16G -upload_tmp_dir=/mnt/php_big_temp/ ----- - -If you see PHP timeouts in your log files, increase the timeout values, which are in seconds, as in the example below: - -[source,php] ----- -max_input_time=3600 -max_execution_time=3600 ----- - -== Configuring via a Virtual Host - -You can configure php parameters also per virtual host - if you have access to the Apache configuration file. This eliminates the need to maintain custom settings in a `{userini}` or `{htaccess}` file especially on upgrades. Note the mandatory prefix `php_admin_value` before the php parameter. - -[source,apache] ----- - - - DocumentRoot /var/www/owncloud - ServerName myowncloud.com - - php_admin_value post_max_size 16G - php_admin_value output_buffering 0 - php_admin_value upload_max_filesize 16G - php_admin_value upload_tmp_dir /mnt/php_big_temp/ - - ... ----- - -If you see PHP timeouts in your log files, increase the timeout values, which are in seconds, as in the example below: - -[source,php] ----- -php_admin_value max_input_time 3600 -php_admin_value max_execution_time 3600 ----- - -== Configuring via ownCloud - -As an alternative to the `upload_tmp_dir` of PHP (e.g., if you don't have access to your `php.ini`) you can also configure some parameters in `config.php`. - -* Set a temporary location for uploaded files by using the `tempdirectory` setting. -* If you have configured the `session_lifetime` setting in your `config.php`, -see xref:configuration/server/config_sample_php_parameters.adoc[Sample Config PHP Parameters], make sure it is not too low. This setting needs to be configured to at least the time (in seconds) that the longest upload will take. If unsure, remove this entirely from your configuration to reset it to the default shown in the `config.sample.php`. - -== General Upload Issues - -Various environmental factors could cause a restriction of the upload size. Examples are: - -* The `LVE Manager` of `CloudLinux` which sets an `I/O limit`. -* Some services like `Cloudflare` are also known to cause uploading issues. -* Upload limits enforced by proxies used by your clients. -* Other web server modules like described in xref:configuration/general_topics/general_troubleshooting.adoc[General Troubleshooting]. - -=== Apache Directives - -* {limitrequestbody-url}[LimitRequestBody] -* {sslrenegbuffersize-url}[SSLRenegBufferSize] - -=== Apache with mod_reqtimeout - -The {mod_reqtimeout-url}[mod_reqtimeout] Apache module could also stop large uploads from completing. If you're using this module and uploads of large files fail, either disable it in your Apache config or increase the configured `RequestReadTimeout` values. - -Disable mod_reqtimeout on Ubuntu:: -+ -On Ubuntu, you can disable the module by running the following command: -+ -[source,bash] ----- -sudo a2dismod reqtimeout ----- - -Disable mod_reqtimeout on CentOS:: -+ -On CentOS, comment out the following line in `/etc/httpd/conf/httpd.conf`: -+ -[source,apache] ----- -LoadModule reqtimeout_module modules/mod_reqtimeout.so ----- -+ -When you have run `asdismod` or updated `/etc/httpd/conf/httpd.conf`, restart Apache. -+ -TIP: There are also several other configuration options in your web server config which could prevent the upload of larger files. Refer to your web server's manual for how to configure those values correctly: - -=== Apache with mod_fcgid - -* {fcgidmaxrequestinmem-url}[FcgidMaxRequestInMem] -* {fcgidmaxrequestlen-url}[FcgidMaxRequestLen] - -WARNING: If you are using Apache 2.4 with mod_fcgid, as of February/March 2016, `FcgidMaxRequestInMem` still needs to be significantly increased from its default value to avoid the occurrence of segmentation faults when uploading big files. This is not a regular setting but serves as a workaround for {mod_fcgid_bug_51747-url}[Apache with mod_fcgid bug #51747]. - -Setting `FcgidMaxRequestInMem` significantly higher than usual may no longer be necessary, once bug #51747 is fixed. - -== Important Changes in Apache 2.4.54 - -In Apache HTTP Server 2.4.53 and earlier, the default value of the `LimitRequestBody` directive was 0 (unlimited). This has changed starting with Apache HTTP Server 2.4.54 where the default value is set to 1073741824 bytes (1 GB). This means, that uploads to public folders when chunking is not in effect will be limited to this file size. Change this value according to your needs in order to allow large file uploads. Please refer to the official Apache documentation {limitrequestbody-url}[LimitRequestBody] for more information. - -== Long-Running Uploads - -For very long-running uploads *those lasting longer than 1h* to public folders, _when chunking is not in effect_, `filelocking.ttl` should be set to a significantly large value in `config.php`. If not, large file uploads will fail with a file locking error, because the Redis garbage collection will delete the initially acquired file lock after 1 hour by default. - -To estimate a good value, use the following formula: - -[source,plaintext] ----- -time_in_seconds = (maximum_upload_file_size / slowest_assumed_upload_connection). ----- - -For the value of "_slowest assumed upload connection_", take the *upload* speed of the user with the slowest connection and divide it by two. For example, let's assume that the user with the slowest connection has an 8MBit/s DSL connection; which usually indicates the download speed. This type of connection would, usually, have 1MBit/s upload speed (but confirm with the ISP). Divide this value in half, to have a buffer when there is network congestion, to arrive at 512KBit/s as the final value. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/default_files_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/default_files_configuration.adoc deleted file mode 100644 index 4e3b15d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/default_files_configuration.adoc +++ /dev/null @@ -1,29 +0,0 @@ -= Providing Default Files - -You may distribute a set of default files and folders to all users by -placing them in the `owncloud/core/skeleton` directory on your ownCloud -server. These files appear only to new users after their initial login, -and existing users will not see files that are added to this directory -after their first login. The files in the skeleton directory are copied -into the users’ data directories, so they may change and delete the -files without affecting the originals. - -This screenshot shows a set of photos in the skeleton directory. - -image:skeleton-files.png[image] - -They appear on the user’s ownCloud Files page just like any other files. - -image:skeleton-files1.png[image] - -== Additional Configuration - -The configuration option `skeletondirectory` available in your `config.php` allows you to configure the directory where the skeleton files are located. - -These files will be copied to the data directory of new users. - -Leave this directory empty if you do not want to copy any skeleton files. - -The value of the `skeletondirectory` key **must not be empty** if you decide to use it in your `config.php`. - -TIP: See xref:configuration/server/config_sample_php_parameters.adoc[Sample Config PHP Parameters] for more the complete list of `config.php` options. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/encryption_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/encryption_configuration.adoc deleted file mode 100644 index d7bc816..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/encryption_configuration.adoc +++ /dev/null @@ -1,414 +0,0 @@ -= Encryption Configuration -:toc: right -:toclevels: 2 -:description: The primary purpose of the ownCloud server-side encryption is to protect users’ files when they’re located on remote storage sites, such as Dropbox and Google Drive, smoothly and seamlessly from within ownCloud. -:page-aliases: go/admin-encryption.adoc, \ -configuration/files/encryption/disabling-encryption.adoc, \ -configuration/files/encryption/enabling-user-key-encryption.adoc, \ -configuration/files/encryption/encryption-types.adoc, \ -configuration/files/encryption/external-backends.adoc, \ -configuration/files/encryption/master-key-encryption.adoc, \ -configuration/files/encryption/migration-guide.adoc, \ -configuration/files/encryption/moving-key-locations.adoc, \ -configuration/files/encryption/sharing-encrypted-files.adoc, \ -configuration/files/encryption_configuration.adoc - -:hackerone-url: https://hackerone.com/reports/108082 -:oc-uses-enc-url: https://owncloud.com/news/how-owncloud-uses-encryption-to-protect-your-data/ - -== Introduction - -{description} - -== General Notes - -Since ownCloud 9.0, server-side encryption for local and remote storage can operate independently. This allows encrypting a remote storage independent of the home storage on the ownCloud server. - -NOTE: Starting with ownCloud 9.0 we support Authenticated Encryption for all newly encrypted files. -See {hackerone-url}[Exploiting unauthenticated encryption mode] for more technical information about the impact. - -For maximum security, make sure to configure external storage with menu:Check for changes[Never]. This will let ownCloud ignore new files not added via ownCloud. This way, a malicious external storage administrator cannot add new files to the storage without your knowledge. However, you may not use this setting _if_ your external storage is subject to legitimate external changes. - -ownCloud’s server-side encryption encrypts files stored on the ownCloud server and files on remote storage sites that are connected to your ownCloud server. Encryption and decryption are performed on the ownCloud server. All files sent to remote storage will be encrypted by the ownCloud server and decrypted before serving them to you or any users that you shared them with. - -[NOTE] -==== -* See the important information on the xref:installation/manual_installation/manual_installation_prerequisites.adoc#openssl-version[OpenSSL Version] before you start configuring the encryption app. -* Encrypting files increases their size by an 8KB header plus 100 bytes per each 8KB block of the file. Remember to take this into account when you are both provisioning storage and setting storage quotas. -* If you are _running_ the encryption app before version 1.5.0 or _started_ with an encryption app version before 1.5.0, BASE64 encoding was used and might still be used for old files if untouched since then. In these cases, old encrypted files increased their size by roughly 35%. We recommend to update the ownCloud system to be able to use the benefits of reduced file sizes for new and rewritten files. Note that the encryption app version lower than 1.5.0 was delivered as part of the ownCloud system lower than 10.7. -* User quotas are based on the _unencrypted_ file size — *not* the encrypted size. This means that admins need to calculate with higher disk space requirements on the backend. -* You *CANNOT* use encryption for your _primary storage_ if the primary storage is an Amazon S3 compatible object storage. This is disabled by default, also see xref:configuration/files/external_storage/s3_compatible_object_storage_as_primary.adoc[S3 Compatible Object Storage as Primary Storage Location] -==== - -When files on an external storage are encrypted in ownCloud, you cannot share them directly from the external storage services, but only through ownCloud sharing. This is because the key to decrypt the data *never* leaves the ownCloud server. - -ownCloud’s server-side encryption generates a strong encryption key, which is unlocked by the user's password. As a result, your users don’t need to track an extra password. All they need to do is log in as they normally would. ownCloud transparently encrypts only the contents of files but not filenames and directory structures. - -=== Location of Encryption Keys - -The encryption keys are stored in the following directories: - -[width="100%",cols="30%,20%,80%",options="header",] -|=== -| Type -| Directory -| Description - -| Master Key -| `data/files_encryption/OC_DEFAULT_MODULE` -| Location of the master key necessary to decrypt files. - -| User Key + -(Deprecated) -| `data//files_encryption/keys/files` -| Location of the user key and share key per file necessary to decrypt files. -|=== - -NOTE: You can move the keys to a different location. To do so, refer to the xref:move-key-location[Move Key Location] section of the documentation. - -IMPORTANT: You should regularly back up all encryption keys to prevent permanent data loss. - -=== Rules and Restrictions - -When encryption is enabled, all files are encrypted and decrypted by the ownCloud application and stored encrypted on your local or remote storage. The latter protects your data on externally hosted storage. An ownCloud admin and a storage admin will only see encrypted files when directly browsing backend storage. - -Encryption keys are stored only on the ownCloud server, eliminating exposure of your data to third-party storage providers. The encryption application does *not* protect your data if your ownCloud server is compromised, and it does not prevent ownCloud administrators from reading users’ files. - -This would require client-side encryption, which this application does not provide. If your ownCloud server is not -connected to any external storage services, it is better to use other encryption tools, such as file-level or whole-disk encryption. - -[CAUTION] -==== -SSL terminates at the same time or before the web server on the ownCloud server. Consequently, all files are in an unencrypted state between the SSL connection termination and the ownCloud code that encrypts and decrypts them. This is potentially exploitable by anyone with administrator access to your server. For more information, read: {oc-uses-enc-url}[How ownCloud uses encryption to protect your data]. -==== - -//// -Section: Files Which Are Never Encrypted -is also used in the user guide, therefore included -//// - -include::partial$/configuration/files/encryption/not-encrypted-files.adoc[] - -== Using a Hardware Security Module (HSM) - -When using a HSM, see the additional information provided at xref:configuration/server/security/hsmdaemon/index.adoc[The HSM (Hardware Security Module) Daemon (hsmdaemon)] - -== Encryption Types - -ownCloud only provides the master key encryption type. There is only one key (or key pair) and all files are encrypted using that key pair. - -IMPORTANT: User-Key encryption has been deprecated with https://doc.owncloud.com/docs_main/next/server_release_notes.html#deprecation-note-for-user-key-storage-encryption[ownCloud release 10.7]. Existing installations using this method must xref:maintenance/encryption/migrating-from-user-key-to-master-key.adoc[migrate] to master key encryption. - -== Before Enabling Encryption - -Plan very carefully before enabling encryption, because it is not reversible via the ownCloud Web interface. If you lose your encryption keys, your files are *not* recoverable. Always have backups of your encryption keys stored in a safe location, and consider enabling all recovery options. - -You have more options via the xref:configuration/server/occ_command.adoc#encryption[occ command’s encryption options]. - -[IMPORTANT] -==== -You can’t manage encryption without access to the command line. If your ownCloud installation is on a hosted environment and you don’t have access to the command line, you won’t be able to run xref:configuration/server/occ_command.adoc[occ commands]. In this case, *don’t enable encryption*! -==== - -== Enable the Encryption App - -Before you can use encryption, you must enable the encryption app. You can do this either on the command-line or in the Web-UI. - -=== Enable Encryption From the Command-Line - -To enable the encryption app, run the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable encryption ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:enable ----- - -If the encryption app is successfully enabled, you should see the following confirmations: - -[source,plaintext] ----- -encryption enabled -Encryption enabled - -Default module: OC_DEFAULT_MODULE -Master key successfully enabled. ----- - -=== Enable Encryption in the Web-UI - -To enable encryption in the Web-UI: - -. Go to menu:Settings[Admin > Apps] and click on kbd:[Show disabled apps] -. When the disabled apps are rendered, click btn:[Enable] under _"Default encryption module"_. - -== Basic Configuration via the Web-UI - -You can do basic configuration of encryption via the Web-UI, but it is recommended to use the CLI. - -. Go to menu:Settings[Admin > Encryption], and enable btn:[Enable server-side encryption]. -. Select the _"Default encryption module"_, either _"Master Key"_ (recommended) or _"User-key"_ (depreciated). -. When User-specific encryption is enabled, users must log out and log back in to trigger the automatic personal encryption key generation process. - -== Master-Key-Based Encryption - -=== Enabling Master Key Based Encryption from the Command-Line - -To be safe and avoid any issues on a running instance, put your server in single user mode with the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on ----- - -Enabling encryption via the command line involves several commands. If not already done, enable the default encryption module app with the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable encryption ----- - -Then enable encryption, using the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:enable ----- - -Finally, encrypt all data, using the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:encrypt-all --yes ----- - -NOTE: This command is not typically required as the master key is often enabled at installation time. As a result when enabling it, there should be no data to encrypt. In case it’s being enabled after the installation and there are files which are unencrypted, xref:configuration/server/occ_command.adoc#encrypt-all[encrypt-all] can be used to encrypt them. Depending on the amount of existing data and the location, this operation can take a long time. - -Now you can turn off the single user mode: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --off ----- - -=== View Current Encryption Status - -Get the current encryption status and the loaded encryption module: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:status ----- - -=== Replacing an Existing Master Key - -If the master key needs replacement, for example because it has been compromised, an occ command is available. The command is xref:configuration/server/occ_command.adoc#encryption[encryption:recreate-master-key]. It replaces an existing master key with a new one and encrypts the files with the new key. - -=== Decrypt Master-Key Encryption - -You must first put your ownCloud server into single-user mode to prevent any user activity until encryption is completed. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on ----- - -[source,plaintext] ----- -Single user mode is currently enabled ----- - -Decrypt all user data files, or optionally a single user: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:decrypt-all [username] ----- - -=== Disable Encryption - -To disable encryption, put your ownCloud server into single-user mode, and then disable your encryption module with these commands: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:disable ----- - -Take it out of single-user mode when you are finished, by using the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --off ----- - -[IMPORTANT] -==== -You may only disable encryption by using the xref:configuration/server/occ_command.adoc#encryption[occ Encryption Commands]. Make sure you have backups of all encryption keys, including those for all your users if user key encryption was selected. -==== - -=== View Current Encryption Status - -Get the current encryption status and the loaded encryption module: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:status ----- - -=== Enable Users' File Recovery Keys - -If users encrypt their files and lose their ownCloud password, they lose access to their encrypted files as the files will be unrecoverable. It is not possible to reset a user’s password using the standard reset process if the user's files are encrypted. - -In such a case, you’ll see a yellow banner warning: - -[source,plaintext] ----- -Please provide an admin recovery password; otherwise, all user data will be lost. ----- - -To avoid all this, create a Recovery Key. To do so, go to the Encryption section of your Admin page and set a recovery key password. - -image:configuration/files/encryption10.png[image] - -You then need to ask your users to opt-in to the Recovery Key. For the users to do this, they need to go to the `**Personal**` page and enable the recovery key. This grants the admin the right to decrypt their data for recovery purposes. If they do _not_ do this, the Recovery Key won’t work for them. - -image:configuration/files/encryption7.png[image] - -Users who have enabled password recovery you can provide with a new password and recovery access to their encrypted files by supplying the Recovery Key on their page. - -image:configuration/files/encryption8.png[image] - -You may change your recovery key password. - -image:configuration/files/encryption12.png[image] - -NOTE: Sharing a recovery key with a user group is *not* supported. This is only supported with the xref:replacing-an-existing-master-key[master key]. - -=== Changing the Recovery Key Password - -If you have misplaced your recovery key password and need to replace it, here’s what you need to do: - -1. Delete the recovery key from both `data/owncloud_private_keys` and `data/public-keys`. -2. Edit your database table `oc_appconfig` and remove the rows with the config keys `recoveryKeyId` and `recoveryAdminEnabled` for the appid `files_encryption`. -3. Login as admin and activate the recovery key again with a new password. This will generate a new key pair. -4. All users who used the original recovery key will need to disable it and enable it again. This deletes the old recovery share keys from their files and encrypts their files with the new recovery key. - -NOTE: You can only change the recovery key password if you know the original. This is by design as only admins who know the recovery key password should be able to change it. Otherwise admins could hijack the recovery key from each other. - -IMPORTANT: Replacing the recovery key will mean that all users will lose the possibility to recover their files until they have applied the new recovery key. - -=== Decrypt User-Key Encryption - -You must first put your ownCloud server into single-user mode to prevent any user activity until encryption is completed. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on ----- - -[source,plaintext] ----- -Single user mode is currently enabled ----- - -=== Disable Encryption - -You may disable encryption only with `occ`. Make sure you have backups of all the encryption keys, including those for all users. Next, put your ownCloud server into single-user mode, and then disable your encryption module with this command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:disable ----- - -IMPORTANT: Encryption cannot be disabled without the user’s password or -xref:enable-users-file-recovery-keys[file recovery key]. -If you don’t have access to at least one of these then there is no way to decrypt all files. -Then, take it out of single-user mode when you are finished with this -command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --off ----- - -It is possible to disable encryption with the file recovery key _if_ every user has enabled it. In this case, "decrypt all" will decrypt all files of all users. - -NOTE: It is *not* planned to move this to the next user login or a background job. If that was done, then login passwords would need to be stored in the database, which could be a security issue. - -== Move Key Location - -View current location of keys: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:show-key-storage-root ----- - -[source,plaintext] ----- -Current key storage root: default storage location (data/) ----- - -You can move the keys to another folder inside your data directory. Moving your keys outside of your data folder is not supported. The folder must already exist, be owned by and restricted to root and the webserver group. This example is for Ubuntu Linux. Note that the new folder is relative to your data directory: - -[source,bash] ----- -mkdir /var/www/owncloud/data/new_keys ----- - -[source,bash] ----- -chown -R root:www-data /var/www/owncloud/data/new_keys ----- - -[source,bash] ----- -chmod -R 0770 /var/www/owncloud/data/new_keys ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:change-key-storage-root new_keys ----- - -[source,plaintext] ----- -Change key storage root from default storage location to new_keys -Start to move keys: - 4 [============================] -Key storage root successfully changed to new_keys ----- - -== LDAP and Other External User Back-ends - -If you use an external user back-end, such as an LDAP or Samba server, and you change a user’s password on that back-end, the user will be prompted to change their ownCloud login to match their next ownCloud login. The user will need both their old and new passwords to do this. - -If you have enabled the recovery key, then you can change a user’s password in the ownCloud Users panel to match their back-end password, and then — of course — notify the user and give them their new password. - -== Encrypting External Mountpoints - -You and your users can encrypt individual external mount points. You must have external storage enabled on your Admin page, and enabled for your users. Encryption settings can be configured in the mount options for an external storage mount; see xref:configuration/files/external_storage/configuration.adoc#mount-options[Mount Options]. - -== Sharing Encrypted Files - -After encryption is enabled, your users must also log out and log back in to generate their personal encryption keys. They will see a yellow warning banner that says "Encryption App is enabled, but your keys are not initialized. Please log-out and log-in again." - -Also, share owners may need to re-share files after encryption is enabled. Users who are trying to access the share will see a message advising them to ask the share owner to re-share the file with them. - -For individual shares, un-share and re-share the file. For group shares, share with any individuals who can't access the share. This updates the encryption, and then the share owner can remove the individual shares. - -image:configuration/files/encryption9.png[image] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/encryption_configuration_quick_guide.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/encryption_configuration_quick_guide.adoc deleted file mode 100644 index 6c6b043..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/encryption_configuration_quick_guide.adoc +++ /dev/null @@ -1,78 +0,0 @@ -= Encryption Configuration Quick Guide -:toc: right -:toclevels: 2 - -== Introduction - -This quick guide gives a brief summary of the commands needed without going into the details and backgrounds. See the xref:configuration/files/encryption/encryption_configuration.adoc[full encryption configuration guide] for more details. - -== Master-Key-Based Encryption - -=== Overview - -- Master key is default when enabled on new instances. -- If you have existing data, use the **occ encryption:encrypt-all** command. Depending on the amount of existing data and the location, this operation can take a long time. - -=== Activate Master Key-Based Encryption - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on -{occ-command-example-prefix} app:enable encryption -{occ-command-example-prefix} encryption:enable -{occ-command-example-prefix} encryption:encrypt-all --yes -{occ-command-example-prefix} maintenance:singleuser --off ----- - -=== View the Encryption Status - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:status ----- - -=== Decrypt Encrypted Files - -Depending on the amount of existing data, this operation can take a long time. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on -{occ-command-example-prefix} encryption:decrypt-all -{occ-command-example-prefix} maintenance:singleuser --off ----- - -=== Deactivate Master-Key-Based Encryption - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:disable - -# ignore the "already disabled" message -{occ-command-example-prefix} app:disable encryption ----- - -If the master key has been compromised or exposed, you can replace it. You will need the current master key for it. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:recreate-master-key ----- - -== Clean up Your Database - -Access your ownCloud database and remove the remaining entries that have not been automatically removed with this command: - -[source,sql] ----- -DELETE FROM oc_appconfig WHERE appid='encryption'; ----- - -== Clean up Your Storage - -The removal of remaining encryption keys is a manual process. You have to delete all encryption keys on the storage by running the following command. Modify the path to your data directory according to your installation. The `find` command limits the search to exactly one directory below the user level and for security reasons prompts before each deletion: - -[source,bash] ----- -find /var/www/owncloud/data/ -mindepth 2 -maxdepth 2 -type d -name "files_encryption" -exec rm -R -i {} + ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/index.adoc deleted file mode 100644 index 36efaff..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/encryption/index.adoc +++ /dev/null @@ -1,5 +0,0 @@ -:section-title: Encryption -:section-preamble-ender: to configure encryption in ownCloud -:page-aliases: configuration/files/encryption/root.adoc - -include::partial$section_page.adoc[] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/amazons3.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/amazons3.adoc deleted file mode 100644 index 25283c0..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/amazons3.adoc +++ /dev/null @@ -1,35 +0,0 @@ -= Amazon S3 -:toc: right -:description: Amazon S3 is used to connect ownCloud to your Amazon S3 bucket. - -== Introduction - -{description} - -== Configuration - -To connect your Amazon S3 buckets to ownCloud, you will need: - -* S3 access key -* S3 secret key -* Bucket name - -In the *Folder name* field enter a local folder name for your S3 mountpoint. If it does not exist, it will be created. - -In the *Available for* field, enter the users or groups who have permission to access your S3 mount. - -The `Enable SSL` checkbox enables HTTPS connections; using HTTPS is always highly recommended. - -image::configuration/files/external_storage/amazons3.png[image,width=500] - -Optionally, you can override the hostname, port and region of your S3 server, which is required for non-Amazon servers such as Ceph Object Gateway. - -*Enable path style* is usually not required (and is, in fact, incompatible with newer Amazon datacenters), but can be used with non-Amazon servers where the DNS infrastructure cannot be controlled. Ordinarily, requests will be made with -`\http://bucket.hostname.domain/`, but with path style enabled, requests are made with -`\http://hostname.domain/bucket` instead. - -See -xref:configuration/files/external_storage/configuration.adoc[External Storage Configuration] -for additional mount options and information, and -xref:configuration/files/external_storage/auth_mechanisms.adoc[External Storage Authentication mechanisms] -for more information on authentication schemes. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/auth_mechanisms.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/auth_mechanisms.adoc deleted file mode 100644 index 785e9f5..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/auth_mechanisms.adoc +++ /dev/null @@ -1,73 +0,0 @@ -= External Storage Authentication Mechanisms -:toc: right - -== Introduction - -ownCloud storage backends accept one or more authentication schemes such -as passwords, OAuth, or token-based, to name a few examples. Each -authentication scheme may be implemented by multiple authentication -mechanisms. Different mechanisms require different configuration -parameters, depending on their behaviour. - -== Special Mechanisms - -The *None* authentication mechanism requires no configuration -parameters, and is used when a backend requires no authentication. - -The *Built-in* authentication mechanism itself requires no configuration -parameters, but is used as a placeholder for legacy storages that have -not been migrated to the new system and do not take advantage of generic -authentication mechanisms. The authentication parameters are provided -directly by the backend. - -== Password-based Mechanisms - -The *Username and password* mechanism requires a manually-defined -username and password. These get passed directly to the backend. - -The *Log-in credentials, save in session* mechanism uses the ownCloud -login credentials of the user to connect to the storage. These are not -stored anywhere on the server, but rather in the user session, giving -increased security. The drawbacks are that sharing is disabled when this -mechanism is in use, as ownCloud has no access to the storage -credentials, and background file scanning does not work. - -NOTE: here is a workaround that allows background file scanning when using *Log-in credentials, save in session*, and that is using xref:configuration/server/background_jobs_configuration.adoc[Ajax cron mode]. -Be aware that the Ajax cron mode is triggered by browsing the ownCloud Web GUI. - -=== Known Limitations - -Please be aware that any operations must be performed by the logged-in mount owner, as credentials are not stored anywhere. -As a result, there are three known limitations, for both admin and personal mounts where both have the "_log-in credentials, save in session_" option. - -These are: - -. Directly sharing the storage or any of its sub-folders will go through, but the recipient will not see the share mounted. This is because the mount cannot be set up due to missing credentials. Federated sharing is also affected, because it works on a "_public link share token_" basis, which itself doesn't contain the user's storage password. As a result, the storage cannot be mounted in this case either. -. Any background task operating on the storage, such as background scanning. -. Any xref:configuration/server/occ_command.adoc[occ command] that operates on the storage, such as `occ files:scan`, will have no effect. - -NOTE: **Enterprise Users Only** + -The enterprise version has a mode called "**Save in DB**" where the credentials are saved, in encrypted form, in the database (via xref:enterprise/external_storage/windows-network-drive_configuration.adoc[the WND app]). In this mode, all of the above operations work. - -== Public-key Mechanisms - -Currently only the RSA mechanism is implemented, where a public/private -keypair is generated by ownCloud and the public half shown in the GUI. -The keys are generated in the SSH format, and are currently 1024 bits in -length. Keys can be regenerated with a button in the GUI. - -image:configuration/files/external_storage/auth_rsa.png[Form on admin page for generating RSA keys.] - -== OAuth - -OAuth 1.0 and OAuth 2.0 are both implemented, but currently limited to -the Dropbox and Google Drive backends respectively. These mechanisms -require additional configuration at the service provider, where an app -ID and app secret are provided and then entered into ownCloud. Then -ownCloud can perform an authentication request, establishing the storage -connection. - -image:configuration/files/external_storage/dropbox-oc.png[Dropbox storage mount configuration.] - -If ownCloud clients are unable to connect to your ownCloud server, -check that the bearer authorization header xref:configuration/general_topics/general_troubleshooting.adoc#owncloud-clients-cannot-connect-to-the-owncloud-server[is not being stripped out]. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/configuration.adoc deleted file mode 100644 index f80927e..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/configuration.adoc +++ /dev/null @@ -1,147 +0,0 @@ -= External Storage Configuration -:toc: right -:toclevels: 1 -:page-aliases: go/admin-external-storage.adoc, \ -configuration/files/external_storage_configuration_gui.adoc - -== Introduction - -The External Storage Support application enables you to mount external -storage services and devices as secondary ownCloud storage devices. You -may also allow users to mount their own external storage services. - -Starting with ownCloud 9.0, a new set of occ commands for -xref:configuration/server/occ_command#files-external[managing external storage] -is introduced. - -This also includes an option for the ownCloud admin to enable or disable sharing on individual -xref:mount-options[external mountpoints]. Sharing on such mountpoints is disabled by default. - -== Enabling External Storage Support - -Prerequisite: menu:Settings[Apps > External storage support] is enabled. -Tick the checkbox under `Settings > Storage > "Enable External Storage"`. - -image:configuration/files/external_storage/enable-app.png[Enabling External Storage Support in ownCloud] - -== Storage Configuration - -IMPORTANT: Before adding a storage in a production environment make sure its configuration is correct. Removal of the external storage or change of its configuration does not remove metadata entries from the database belonging to the previous storage configuration. - -To create a new external storage mount, select an available backend from -the dropdown *Add storage*. Each backend has different required options, -which are configured in the configuration fields. - -image:configuration/files/external_storage/external_storage_types.png[ownCloud External Storage Types] - -Each backend may also accept multiple authentication methods. These are -selected with the dropdown under *Authentication*. Different backends -support different authentication mechanisms; some specific to the -backend, others are more generic. See external_storage/auth_mechanisms -for more detailed information. - -When you select an authentication mechanism, the configuration fields -change as appropriate for the mechanism. The SFTP backend, for one -example, supports *username and password*, *Log-in credentials, save in -session*, and *RSA public key*. - -image:configuration/files/external_storage/auth_mechanism.png[An SFTP configuration example.] - -Required fields are marked with a red border. When all required fields -are filled, the storage is automatically saved. A green dot next to the -storage row indicates the storage is ready for use. A red or yellow icon -indicates that ownCloud could not connect to the external storage, so -you need to re-check your configuration and network availability. - -NOTE: If there is a connection issue with the target storage, it will be marked as unavailable for ten minutes. -To re-check it, click the btn:[colored icon] or reload your Admin page. - -== User and Group Permissions - -A storage configured in a user’s Personal settings is available only to -the user that created it. A storage configured in the Admin settings is -available to all users by default, and it can be restricted to specific -users and groups in the *Available for* field. - -image:configuration/files/external_storage/applicable.png[User and groups selector] - -IMPORTANT: Adding a storage for users or groups you don't have access rights to, an error notification will be shown and a red square icon appears on the mount. - -== Mount Options - -Hover your cursor to the right of any storage configuration to expose -the settings button and trashcan. When clicking the trashcan icon, you delete the -mountpoint. The settings button allows you to configure each storage -mount individually with the following options: - -* Encryption -* Read Only -* Previews -* Enable Sharing -* Filesystem check frequency (Never, Once per direct access) - -NOTE: The *Encryption* checkbox is visible only, when the Encryption app is enabled. - -*Enable Sharing* allows the ownCloud admin to enable or disable sharing -on individual mountpoints. When sharing is disabled, the shares are -retained internally, so that you can re-enable sharing and the previous -shares become available again. Sharing is disabled by default. - -image:configuration/files/external_storage/mount_options.png[Additional mount options exposed on mouseover.] - -== Using Self-Signed Certificates - -When using self-signed certificates for external storage mounts, the -certificate must be imported into ownCloud. - -TIP: Please refer to xref:configuration/server/import_ssl_cert.adoc[Importing System-wide and Personal SSL Certificates] for more information. - -== Available storage backends - -The following backends are provided by the external storages app. Other -apps may provide their own backends, which are not listed here. - -NOTE: A non-blocking or correctly configured SELinux setup is needed for these backends to work. Please refer to xref:installation/selinux_configuration.adoc[the SELinux configuration]. - -== Allow Users to Mount External Storage - -Check "__Allow users to mount external storage__" to allow your users -to mount storages on external services. Then enable the backends you want to allow. - -image:configuration/files/external_storage/user_mounts.png[Checkboxes to allow users to mount external storage services.] - -IMPORTANT: Be careful with the choices that you enable, as it allows a user to make potentially arbitrary -connections to other services on your network! - -== Detecting Files Added to External Storages - -* Rescanning S3 for manually added files is not possible -+ -NOTE: The command xref:configuration/server/occ_command.adoc#the-filesscan-command[occ files:scan] or a xref:configuration/server/occ_command.adoc#managing-background-jobs[background job] containing _files scan_ is only available for POSIX but not for S3 and compatible filesystems. - -* We recommend xref:configuration/server/background_jobs_configuration.adoc[configuring the background job Webcron or Cron] to enable ownCloud to automatically detect files added to your external storages. -+ -TIP: You cannot scan/detect changed files on external storage mounts when you select the -*Log-in credentials, save in session* authentication mechanism. However, there is a workaround, -and that is to use Ajax cron mode. -See xref:configuration/files/external_storage/auth_mechanisms.adoc#password-based-mechanisms[Password-based Mechanisms] for more information. - -* ownCloud may not always be able to find out what has been changed remotely -(files changed without going through ownCloud), especially when it’s very deep -in the folder hierarchy of the external storage. -+ -You might need to setup a cron job that runs -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:scan --all` ----- - -* Alternatively, replace `--all` with the user name to trigger a rescan of the user’s files periodically, -for example every 15 minutes, which includes the mounted external storage. -+ -TIP: See xref:configuration/server/occ_command.adoc#the-filesscan-command[occ’s file operations] for more information. - -== Known limitations - -- Removal of the external storage or change of its configuration does not remove metadata entries belonging to the previous storage configuration. This may impact performance of the installation as previous configuration metadata entries get orphaned. Removal of orphaned storage entries can be done manually by using the xref:configuration/server/occ_command.adoc#the-filesremove-storage-command[occ files:remove-storage] command. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/dropbox.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/dropbox.adoc deleted file mode 100644 index 4cb436a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/dropbox.adoc +++ /dev/null @@ -1,76 +0,0 @@ -= Dropbox -:toc: right -:description: Connecting Dropbox to your ownCloud installation requires only a few steps. - -== Introduction - -{description} Then you can easily keep a Dropbox folder in sync with an ownCloud folder. This guide assumes you already have a Dropbox account. - -== Install the ownCloud Dropbox App - -Install the External Storage Dropbox app from the ownCloud Marketplace - -1. Click btn:[Market] in the ownCloud web UI drop-down menu on the left side -2. Go to the *Storage* category -3. Select *External Storage: Dropbox* App -4. Click btn:[INSTALL] - -== Create a Dropbox App - -Next, you need to create a Dropbox app. To do that, https://www.dropbox.com/developers/apps/create[open the new app creation form], where you see three settings: - -1. "Choose an API" –> "Scoped access" -2. "Choose the type of access" –> "App folder" -3. "Name your app" - -Read and agree to the Dropbox API Terms and Conditions before clicking the blue btn:[Create app] button. After you do that, the settings page for the application loads. - -image::configuration/files/external_storage/dropbox/app-configuration.png[Dropbox app configuration settings,width=500] - -IMPORTANT: *Redirect URI*: Here you must enter the exact URL of the page where you configure the storage. - -Examples: - -When configuring as an *admin*: - -[source,plaintext] ----- -http(s)://<>/settings/admin?sectionid=storage ----- - -When configuring as a *user*: - -[source,plaintext] ----- -http(s)://<>/settings/personal?sectionid=storage ----- - -Take note of the App key and App secret since you'll need them in the next step. - -== Create a Dropbox Share - -Return to the ownCloud web interface. Under menu:Admin[Settings > Storage], check the btn:[Enable external storage] checkbox if it’s not already checked. Then, in the drop-down list under menu:External storage[], select Dropbox V2. - -Then, you need to provide a name for the folder in the "Folder name" field and a "client key" and "client secret" under "Configuration". The client key and client secret values are the "App key" and "App secret" which you saw earlier in your Dropbox app configuration settings. - -After you have entered these values, click btn:[Grant access]. ownCloud then interacts with the Dropbox API to set up the new shared folder. If the process is successful, a green circle icon appears at the far left-hand side of the row next to the folder name. - -image::configuration/files/external_storage/dropbox/successful-connection-to-dropbox.png[A Dropbox share successfully created,width=500] - -=== Other Options - -If you want to grant access to the share to a select list of users and groups, you can add them to the field in the "Available for" column. - -== Using the Dropbox Share - -After a Dropbox share is created, a new folder is available under "All Files" with the name you provided when you created the share. It is represented by an external share folder icon as in the image below. - -image::configuration/files/external_storage/dropbox/successful-connection-to-dropbox.png[A Dropbox share successfully created,width=500] - -This links to a new folder in your Dropbox account under "Dropbox > Apps" with the name of the Dropbox app that you created. - -image::configuration/files/external_storage/dropbox/dropbox-share-available.png[A new Dropbox share is available,width=500] - -Now, if you add files and folders in either the new Dropbox folder or the new ownCloud folder, they will be visible in both after they've been synced. - -image::configuration/files/external_storage/dropbox/dropbox-apps-folders.png[The Dropbox Apps folders,width=500] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/ftp.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/ftp.adoc deleted file mode 100644 index 2a31432..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/ftp.adoc +++ /dev/null @@ -1,29 +0,0 @@ -= FTP/FTPS - -:description: If you want to mount an FTP storage, ownCloud provides an app to do so. - -{description} Please install the {oc-marketplace-url}/apps/files_external_ftp[FTP Storage Support] app from the ownCloud Marketplace. - - -image::configuration/files/external_storage/ftp_storage_support.png[The ownCloud FTP Storage Support App,width=500] - -To connect to an FTP server, you will need: - -* A folder name for your local mountpoint; the folder will be created if it does not exist -* The URL of the FTP server -* Port number (default: 21) -* Username and password to access the resource -* Remote subfolder, the FTP directory to mount in ownCloud. + - ownCloud defaults to the root directory. If you specify a subfolder you must leave off the leading slash. For example, `public_html/images`. - -Your new mountpoint is available to all users by default, and you may restrict access by entering specific users or groups in the *Available for* field. - -Optionally, ownCloud can use FTPS (FTP over SSL) by checking `Secure ftps://`. This requires additional configuration with your root certificate, if the FTP server uses https://en.wikipedia.org/wiki/Self-signed_certificate[a self-signed certificate]. See xref:configuration/server/import_ssl_cert.adoc[Importing System-wide and Personal SSL Certificates] for more information. - -image::configuration/files/external_storage/ftp.png[ownCloud GUI FTP configuration,width=500] - -The external storage `FTP/FTPS` needs the `allow_url_fopen` PHP setting to be set to `1`. When having connection problems make sure that it is not set to `0` in your `php.ini`. See xref:configuration/general_topics/general_troubleshooting.adoc#php-version-and-information[PHP Version and Information] to learn how to find the right `php.ini` file to edit. - -See xref:configuration/files/external_storage/configuration.adoc[External Storage Configuration] for additional mount options and information. - -FTP uses the password authentication scheme; see xref:configuration/files/external_storage/auth_mechanisms.adoc[External Storage Authentication mechanisms] for more information on authentication schemes. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/google.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/google.adoc deleted file mode 100644 index 8a25a75..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/google.adoc +++ /dev/null @@ -1,173 +0,0 @@ -= Google Drive -:toc: right -:description: Using the Google Drive external storage in ownCloud, you can mount all or a subfolder of Google Drive. -:google_cloud_console-url: https://console.developers.google.com/ - -== Introduction - -{description} - -For subfolders, use the following scheme: - -- subfolder = empty (mounting the root, all of Google Drive will be used) -- subfolder = $user ($user variable represents the current logged in ownCloud username) -- subfolder = name (a folder name, can be cascaded like name1/name2 or name/$user) - -NOTE: If the subfolder is not present in Google Drive, no Google Drive mount will be shown in the users file list. - -NOTE: Using subfolders is beneficial if you want to selectively encrypt Google Drive mount points - -NOTE: The variable `$user` is the substitute for the currently logged-in user. The subfolder with the username must be created manually in Google Drive. - -ownCloud uses OAuth 2.0 to connect to Google Drive. This requires configuration through Google to get an app ID and app secret, as ownCloud registers itself as an app. - -All applications that access a Google API must be registered through the {google_cloud_console-url}[Google Cloud Console]. Follow along carefully, because the Google interface is a bit of a maze and it’s easy to get lost. - -In the examples used, `` represents how you access your ownCloud server, where you see the login screen. This may look like: - -[source,plaintext] ----- -https://example.com - or -http://example.com - or -IP/owncloud ----- - -== Preparations in the Google Cloud Console - -=== Create a Google Drive Project - -. You can use your existing Google account such as Groups, Drive, or Mail, or create a new one and log into the {google_cloud_console-url}[Google Cloud Console]. After logging in click the btn:[Create Project] button on the top right side. -+ -image::configuration/files/external_storage/google_drive/001.png[Google Cloud Console,width=500] - -. Add a new project by clicking the btn:[+] button on the top right side. -+ -image::configuration/files/external_storage/google_drive/002.png[Create Project,width=500] - -. Give your project a name, and either accept the default *Project ID* or create your own, then click the btn:[Create] button. For this example a random name was chosen, "owncloud-04-27". However, feel free to choose your own name. -+ -image::configuration/files/external_storage/google_drive/003.png[Choose a name,width=500] - -. After your project is created, click on the btn:[notifications bell] and select your project. -+ -image::configuration/files/external_storage/google_drive/004.png[Notification bell,width=500] - -. Go to Api overview to select google’s API. -+ -image::configuration/files/external_storage/google_drive/005.png[API,width=500] - -. Select Google Drive API -+ -image::configuration/files/external_storage/google_drive/006.png[Google API,width=500] - -. Enable the Google Drive API -+ -image::configuration/files/external_storage/google_drive/007.png[Enable,width=500] - -. You now must create your credentials. -+ -image::configuration/files/external_storage/google_drive/008.png[Create Credentials,width=500] - -. First, select btn:[Web Browser] and btn:[User data]. -+ -image::configuration/files/external_storage/google_drive/009.png[Access type and Data,width=500] - -. The next screen that opens is *Create OAuth 2.0 Client ID*. Enter your app name. -+ -image::configuration/files/external_storage/google_drive/010.png[Access type and Data,width=500] - -=== Configure Authorisations - -These authorizations are necessary to tell Google which source URI requests are allowed. You can configure multiple Authorized URIs if you wish to enable admin and personal access at the same time for different purposes. - -==== Authorized Redirect URIs - -To configure _Authorized Redirect URIs_, select one of the two possible URI Schemes: - -* If you are configuring storage as an administrator - choose the admin URI, -* If you are a user and configure your personal storage - pick the personal URI. - -[source,plaintext] ----- -https:///index.php/settings/admin?sectionid=storage - or -https:///index.php/settings/personal?sectionid=storage ----- - -==== Authorized JavaScript Origins - -This is just \https:// which represents how you access your ownCloud server, where you see the login screen. - -== Configure to connect to Google Drive - -The following example procedure configures an admin-based storage mount. The domain used in this example is \http://51a8725b.ngrok.io - -. Login to your ownCloud account -+ -image::configuration/files/external_storage/google_drive/011.png[Login in ownCloud,width=500] - -. Go to Storage in the Settings -+ -image::configuration/files/external_storage/google_drive/012.png[Go to Storage in the Settings] - -. Enable external Storage -+ -image::configuration/files/external_storage/google_drive/013.png[Enable external Storage] - -. Select Google Drive -+ -image::configuration/files/external_storage/google_drive/014.png[Select Google Drive from dropdown menu,width=500] - -. The Google Drive App is enabled -+ -Give the mount point a meaningful name. We have used `Google Drive` in this example. -+ -image::configuration/files/external_storage/google_drive/015.png[Now you have your Google Drive App enabled] - -. Copy the Authorized Redirect URI from the browser -+ -image::configuration/files/external_storage/google_drive/016.png[The URL from this page is the one you have to enter in the **Authorized Redirect URIs**] - -. Enter it the Google Drive Console here -+ -image::configuration/files/external_storage/google_drive/017.png[Client ID,width=500] - -. Choose a project name for the consent screen. -+ -A consent screen has to be created. This is the information in the screen Google shows you when you connect your ownCloud Google Drive app to Google the first time. -+ -image::configuration/files/external_storage/google_drive/018.png[Choose a Project Name,width=500] - -. Download the credentials as JSON file. -+ -image::configuration/files/external_storage/google_drive/019.png[Download your Credentials,width=500] -+ -You can either open this file with the editor of your choice (SublimeText for example), or you can put in your web browser to view it. You can always download this data from your Google Drive project at a later time for other Google Drive mounts. -+ -Here is an example output: -+ -image::configuration/files/external_storage/google_drive/020.png[Credentials,width=500] - -. Client ID and Client Secret -+ -Enter the Client ID and Client Secret in the ownCloud Google Drive mount screen and click btn:[Grant Access]. Now you have everything you need to mount your Google Drive in ownCloud. Your consent page appears when ownCloud makes a successful connection. -+ -Click btn:[Allow] when the consent screen appears. -+ -image::configuration/files/external_storage/google_drive/021.png[Grant Access,width=500] - -. Success -+ -You are finished when you see the green light confirming a successful connection. -+ -See the xref:configuration/files/external_storage/configuration.adoc[External Storage Configuration] for additional mount options and information. -+ -image::configuration/files/external_storage/google_drive/022.png[All Green,width=500] - -. Files View -+ -Go to your files view. You will see the newly mounted Google Drive. -+ -image::configuration/files/external_storage/google_drive/023.png[Your Google Drive Folder,width=500] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/index.adoc deleted file mode 100644 index 26a0a4a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/index.adoc +++ /dev/null @@ -1,5 +0,0 @@ -:section-title: External Storage -:section-preamble-ender: to configure external storage in ownCloud - -include::partial$section_page.adoc[] - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/local.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/local.adoc deleted file mode 100644 index f356253..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/local.adoc +++ /dev/null @@ -1,50 +0,0 @@ -= Local Storage -:toc: right -:description: Local storage provides the ability to mount any directory on your ownCloud server - -== Introduction - -IMPORTANT: *Using local storage is a security risk, only use it if you know what you are doing.* - -{description} that is: - -* Outside of your ownCloud `data/` directory -* Both readable and writable by your web server user - -== Details - -As this setup diffuses the difference between ownCloud Admin and sysadmin, this is a significant security risk and therefore off by default. - -[WARNING] -==== -* *Only enable local storage if ownCloud Admin and sysadmin are the same person on purpose.* -* A local ownCloud mount does not work well with external storages like SMB or FTP mounted in the Linux filesystem. If such a Linux mounted storage goes away, ownCloud is likely to see the underlying empty mountpoint as a perfectly valid folder and will _silently_ propagate content deletion, instead of forwarding error messages to the end users. -==== - -In any case, local storage is only configurable via the ownCloud admin settings. Non-admin users cannot create local storage mounts. - -See -xref:installation/manual_installation/manual_installation.adoc#script-guided-installation[Set Correct Permissions] -for information on correct file permissions, and find your HTTP user -xref:configuration/general_topics/general_troubleshooting.adoc#php-version-and-information[PHP Version and Information]. - -To enable Local storage, you must first enable it by editing your ownCloud installation’s `config/config.php` file adding the following configuration key: - -[source,php] ----- -'files_external_allow_create_new_local' => 'true', ----- - -To manage local storage, navigate to menu:Settings[Admin > Storage]. You can see an example in the screenshot below. - -image::configuration/files/external_storage/local.png[Manage local storage in ownCloud,width=500] - -. In the *Folder name* field enter the folder name that you want to appear on your ownCloud Files page. -. In the *Configuration* field enter the full file path of the directory you want to mount. -. In the *Available for* field enter the users or groups who have permission to access the mount; by default all users have access. - -See -xref:configuration/files/external_storage/configuration.adoc[External Storage Configuration] -for additional mount options and information, and -xref:configuration/files/external_storage/auth_mechanisms.adoc[External Storage Authentication mechanisms] -for more information on authentication schemes. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/owncloud.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/owncloud.adoc deleted file mode 100644 index 1727f64..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/owncloud.adoc +++ /dev/null @@ -1,14 +0,0 @@ -= ownCloud - -An ownCloud storage is a specialized webdav storage, with optimizations -for ownCloud-ownCloud communication. See the webdav documentation to -learn how to configure an ownCloud external storage. - -When filling in the *URL* field, use the path to the root of the -ownCloud installation, rather than the path to the WebDAV endpoint. So, -for a server at `\https://example.com/owncloud`, use -`\https://example.com/owncloud` and not -`\https://example.com/owncloud/remote.php/dav`. - -* See xref:configuration/files/external_storage/configuration.adoc[External Storage Configuration] for additional mount options and information. -* See xref:configuration/files/external_storage/auth_mechanisms.adoc[External Storage Authentication Mechanisms] for more information on authentication schemes \ No newline at end of file diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/s3_compatible_object_storage_as_primary.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/s3_compatible_object_storage_as_primary.adoc deleted file mode 100644 index 0879cdd..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/s3_compatible_object_storage_as_primary.adoc +++ /dev/null @@ -1,292 +0,0 @@ -= S3 Compatible Object Storage as Primary Storage Location -:toc: right -:description: Administrators can configure Amazon-S3-compatible object storages as the primary ownCloud storage location -:page-aliases: enterprise/external_storage/s3_swift_as_primary_object_store_configuration.adoc -:files_primary_s3-url: https://github.com/owncloud/files_primary_s3 -:creating-a-bucket-url: https://docs.aws.amazon.com/AmazonS3/latest/gsg/CreatingABucket.html - -== Introduction - -{description} with the {oc-marketplace-url}/apps/files_primary_s3[S3 Primary Object Storage] app. The referencing name is `files_primary_s3`. Using `files_primary_s3` replaces the default ownCloud `owncloud/data` directory. However, you *need* to keep the `owncloud/data` directory for the following reasons: - -* The ownCloud log file is saved in the data directory. -* Legacy apps may not support using anything but the `owncloud/data` directory. - -NOTE: Even if the ownCloud log file is stored in an alternate location (by changing the location in `config.php`), `owncloud/data` may still be required for backward compatibility with some apps. - -That said, {oc-marketplace-url}/apps/objectstore[Object Storage Support] (`objectstore`) is still available, but the {oc-marketplace-url}/apps/files_primary_s3[S3 Primary Object Storage] app is the preferred and only supported way to provide S3 storage support as primary storage. ownCloud provides consulting for migrations from `objectstore` -> `files_primary_s3`. - -[NOTE] -==== -Consider the following differentiation: - -{oc-marketplace-url}/apps/files_external_s3[External Storage: S3]:: -Integrate S3 object storages as external storages - -{oc-marketplace-url}/apps/files_primary_s3[S3 Primary Object Storage]:: -Leverage object storage via S3 as primary storage -==== - -NOTE: OpenStack Swift has been deprecated. - -When using `files_primary_s3`, the Amazon S3 bucket to be used needs to be created manually first, according to the {creating-a-bucket-url}[Amazon S3 developer documentation] and versioning needs to be enabled for this bucket. - -== Implications - -Read the following implications carefully **BEFORE** you start using `files_primary_s3`: - -. Apply this configuration before the first login of any user – including the admin user; otherwise, ownCloud can no longer find the user's files. - -. In "object store" mode as primary storage access, ownCloud expects exclusive access to the object store container, because it only stores the binary data for each file. While in this mode, ownCloud stores the metadata in the local database for performance reasons. - -. The current implementation is _incompatible_ with any app that uses direct file I/O (input/output) as it circumvents the ownCloud virtual file system. An excellent example is the xref:configuration/files/encryption/encryption_configuration.adoc[Encryption app], which fetches critical files in addition to any requested file, which results in significant overhead. + -**Therefore encrypting the S3 primary storage via ownCloud has been disabled and can not be enabled** - -. When requiring encryption for the bucket containing the primary storage, use the bucket built-in encryption provided by the S3 API. See the configuration examples below how to enable it. - -. When using S3 primary storage with multiple buckets, it is _not recommended_ to use the command to transfer file ownership between users -(xref:configuration/server/occ_command.adoc#the-filestransfer-ownership-command[occ files:transfer-ownership]) -as shares on the files can get lost. The reason for this is that file IDs are changed during such cross-storage move operations. - -[IMPORTANT] -==== -As ownCloud only stores the binary data in S3, while the metadata of the files is still stored on the DB, a regular database backup is highly recommended, as this is also needed for recovery in addition to the S3 backup! -==== - -== Configuration - -Copy the following relevant example part to your `config.php` file. - -[NOTE] -==== -Any object store needs to implement `\OCP\Files\ObjectStore\IObjectStore` and can be passed parameters in the constructor with the `arguments` key, as in the following example: - -[source,php] ----- - [ - 'class' => 'Implementation\Of\OCP\Files\ObjectStore\IObjectStore', - 'arguments' => [ - ... - ], - ], -]; ----- -==== - -=== Amazon S3 - -The S3 backend mounts a bucket of the Amazon S3 object store into the virtual filesystem. The class to be used is `OCA\Files_Primary_S3\S3Storage`, as in the following example: - -[source,php] ----- - [ - 'class' => 'OCA\Files_Primary_S3\S3Storage', - 'arguments' => [ - // - // replace with your bucket - 'bucket' => 'owncloud', - // - // uncomment to indicate available storage size in the objectstore in bytes (in this example 1TB), - // without this setting, apps relying on available storage might be limited in funcionality e.g. metrics app - //'availableStorage' => 1099511627776, - // - // uncomment to enable server side encryption - //'serversideencryption' => 'AES256', - // - // part size in bytes, applies to uploads between ownCloud and S3. This value must be between 5MB and 5GB, inclusive. - 'part_size' => 5242880, - // maximum number of concurrent UploadPart operations allowed during the multipart upload. - 'concurrency' => 3, - // storage specific options - 'options' => [ - // version and region are required - 'version' => '2006-03-01', - // change to your region - 'region' => 'eu-central-1', - 'credentials' => [ - // replace key and secret with your credentials - 'key' => 'owncloud123456', - 'secret' => 'secret123456', - ], - ], - ], - ], -]; ----- - -=== Ceph S3 - -The S3 backend can also be used to mount the bucket of a Ceph S3 object store via the Amazon S3 API into the virtual filesystem. The class to be used is `OCA\Files_Primary_S3\S3Storage`: - -[source,php] ----- - [ - 'class' => 'OCA\Files_Primary_S3\S3Storage', - 'arguments' => [ - // - // replace with your bucket - 'bucket' => 'owncloud', - // - // uncomment to indicate available storage size in the objectstore, in bytes (in this example 1TB), - // without this setting, apps relying on available storage might be limited in funcionality e.g. metrics app - //'availableStorage' => 1099511627776, - // - // uncomment to enable server side encryption - //'serversideencryption' => 'AES256', - // - // part size, in bytes, to use when doing a multipart upload. this must between 5 MB and 5 GB, inclusive. - 'part_size' => 5242880, - // maximum number of concurrent UploadPart operations allowed during the multipart upload. - 'concurrency' => 5, - // storage specific options - 'options' => [ - // version and region are required - 'version' => '2006-03-01', - 'region' => '', - // replace key, secret and bucket with your credentials - 'credentials' => [ - // replace key and secret with your credentials - 'key' => 'owncloud123456', - 'secret' => 'secret123456', - ], - // replace the ceph endpoint with your rgw url - 'endpoint' => 'http://ceph:80/', - // Use path style when talking to ceph - 'use_path_style_endpoint' => true, - ], - ], - ], -]; ----- - -=== Scality S3 - -The S3 backend can also be used to mount the bucket of a Scality S3 object store via the Amazon S3 API into the virtual filesystem. The class to be used is `OCA\Files_Primary_S3\S3Storage`: - -[source,php] ----- - [ - 'class' => 'OCA\Files_Primary_S3\S3Storage', - 'arguments' => [ - // - // replace with your bucket - 'bucket' => 'owncloud', - // - // uncomment to indicate available storage size in the objectstore, in bytes (in this example 1TB), - // without this setting, apps relying on available storage might be limited in funcionality e.g. metrics app - //'availableStorage' => 1099511627776, - // - // uncomment to enable server side encryption - //'serversideencryption' => 'AES256', - // - // part size, in bytes, to use when doing a multipart upload. this must between 5 MB and 5 GB, inclusive. - 'part_size' => 5242880, - // maximum number of concurrent UploadPart operations allowed during the multipart upload. - 'concurrency' => 5, - // storage specific options - 'options' => [ - // version and region are required - 'version' => '2006-03-01', - 'region' => 'us-east-1', - 'credentials' => [ - // replace key and secret with your credentials - 'key' => 'owncloud123456', - 'secret' => 'secret123456', - ], - 'use_path_style_endpoint' => true, - 'endpoint' => 'http://scality:8000/', - ], - ], - ], -]; ----- - -=== Backblaze S3 - -The S3 backend can also be used to mount the bucket of a Backblaze S3 object store via the Amazon S3 API into the virtual filesystem. The class to be used is `OCA\Files_Primary_S3\S3Storage`: - -[source,php] ----- - [ - 'class' => 'OCA\Files_Primary_S3\S3Storage', - 'arguments' => [ - // replace with your bucket - 'bucket' => 'owncloud', - // uncomment to enable server side encryption - //'serversideencryption' => 'AES256', - // - // part size, in bytes, to use when doing a multipart upload. this must between 5 MB and 5 GB, inclusive. - 'part_size' => 5242880, - // maximum number of concurrent UploadPart operations allowed during the multipart upload. - 'concurrency' => 5, - // - 'options' => [ - // version and region are required - 'version' => 'latest', - // replace with your region - 'region' => 'us-west-004', - 'credentials' => [ - // replace key and secret with your credentials - 'key' => 'owncloud123456', - 'secret' => 'secret123456', - ], - 'use_path_style_endpoint' => true, - // replace with your endpoint - 'endpoint' => 'https://s3.us-west-004.backblazeb2.com', - ], - ], - ], -]; ----- -=== Wasabi S3 - -The S3 backend can also be used to mount the bucket of a Wasabi S3 object store via the Amazon S3 API into the virtual filesystem. The class to be used is `OCA\Files_Primary_S3\S3Storage`: - -[source,php] ----- - [ - 'class' => 'OCA\Files_Primary_S3\S3Storage', - 'arguments' => [ - // replace with your Wasabi bucket name - 'bucket' => 'owncloud', - // uncomment to enable server side encryption. - //'serversideencryption' => 'AES256', - // - // part size, in bytes, to use when doing a multipart upload. this must between 5 MB and 5 GB, inclusive. - // Adjust for the common file sizes that are to uploaded to the ownCloud instance. - 'part_size' => 5242880, - // maximum number of concurrent UploadPart operations allowed during the multipart upload. - // This can be adjusted higher to allow for more concurrent connections. - 'concurrency' => 5, - // - 'options' => [ - // version and region are required - 'version' => 'latest', - // replace with your Wasabi region. Review the Wasabi documentation for the region names. - 'region' => 'us-east-2', - 'credentials' => [ - // replace key and secret with your Wasabi credentials that allow access to the bucket. - 'key' => 'wasabi-access-key-here', - 'secret' => 'wasabi-secret-key-here', - ], - // path style can either be used (true) or not (false). - 'use_path_style_endpoint' => false, - // replace with the Wasabi endpoint URL for your bucket - 'endpoint' => 'https://s3.us-east-2.wasabisys.com', - ], - ], - ], -]; ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/sftp.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/sftp.adoc deleted file mode 100644 index a3b91d9..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/sftp.adoc +++ /dev/null @@ -1,18 +0,0 @@ -= SFTP - -:description: ownCloud’s SFTP (FTP over an SSH tunnel) backend supports both password and public key authentication. - -{description} - -The *Host* field is required; a port can be specified as part of the *Host* field in the following format: `hostname.domain:port`. The default port is 22 (SSH). - -For public key authentication, you can generate a public/private key pair from your *SFTP with secret key login* configuration. - -image::configuration/files/external_storage/auth_mechanism.png[Generating an RSA key pair in the SFTP configuration,width=500] - -After generating your keys, you need to copy your new public key to the destination server to `.ssh/authorized_keys`. ownCloud will then use its private key to authenticate to the SFTP server. - -The default *Remote Subfolder* is the root directory (`/`) of the remote SFTP server, and you may enter any directory you wish. - -* See xref:configuration/files/external_storage/configuration.adoc[External Storage Configuration] for additional mount options and information. -* See xref:configuration/files/external_storage/auth_mechanisms.adoc[External Storage Authentication Mechanisms] for more information on authentication schemes diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/smb.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/smb.adoc deleted file mode 100644 index 07ef4c4..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/smb.adoc +++ /dev/null @@ -1,58 +0,0 @@ -= Samba File Server Configuration (SMB/CIFS) -:toc: right -:description: ownCloud can connect to Windows file servers, and other SMB-compatible servers - -:samba-url: https://www.samba.org -:smbcifs-url: https://docs.microsoft.com/en-us/windows/desktop/FileIO/microsoft-smb-protocol-and-cifs-protocol-overview - -== Introduction - -{description} (e.g., {samba-url}[Samba]), by using the {smbcifs-url}[SMB/CIFS] backend. - -== Dependencies - -To connect ownCloud to an SMB file server, you need to prepare your server. Please see the -xref:installation/manual_installation/manual_installation.adoc[Manual Installation on Linux] guides for more information, prerequisites and requirements. - -== Access Testing - -To ensure that you can connect to your file server with SMB, do a small test upfront like the following. - -[source,bash] ----- -sudo smbclient -L -U / ----- - -Please fix any issues before you connect ownCloud to a SMB file server. - -== Configuration - -When configuring ownCloud, you will need the following information: - -* The folder name, which will be your local mount point. -* The URL of the Samba server. -* The username or domain/username used to login to the Samba server. -* The password to login to the Samba server. -* The share name to mount on the remote Samba server. -* The remote subfolder inside the remote Samba share to mount. + -This is optional, as it defaults to `/`. -+ -TIP: To assign the ownCloud logon username automatically to the subfolder, use `$user` instead of a -subfolder name. The foldername=username must be present and is not created on access. - -* The ownCloud users and groups who get access to the share. -* A domain name, might be required or optional depending on your setup -+ -[TIP] -==== -You can specify a `Domain` which is useful in cases where the SMB server requires a domain and a username, and an advanced authentication mechanism like Active Directory (AD), or when using session credentials where the username cannot be modified. This is concatenated with the username, so the backend gets `domain\username` -==== - -image::configuration/files/external_storage/smb.png[Samba external storage configuration,width=500] - -== Further Information - -* xref:configuration/files/external_storage/configuration.adoc[External Storage Configuration] -for additional mount options and information. -* xref:configuration/files/external_storage/auth_mechanisms.adoc[External Storage Authentication Mechanisms] -for more information on authentication schemes. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/webdav.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/webdav.adoc deleted file mode 100644 index 2f6890a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/external_storage/webdav.adoc +++ /dev/null @@ -1,24 +0,0 @@ -= WebDAV -:web-disk-url: https://documentation.cpanel.net/display/ALD/Web+Disk -:description: Use this backend to mount a directory from any WebDAV server, or another ownCloud server. - -{description} - -image::configuration/files/external_storage/webdav.png[Webdav configuration form,width=500] - -You need the following information: - -* The name of your local mountpoint. - Optionally, a `Remote Subfolder` can be specified to change the destination directory. - The default is to use the whole root. -* The URL of the WebDAV or ownCloud server. -* The username and password for the remote server. - -TIP: We always recommend `https://` for security reasons, so encourage you to enable btn:[Secure https://]. - -NOTE: CPanel users should install {web-disk-url}[Web Disk] to enable WebDAV functionality. - -== Further Reading - -* See xref:configuration/files/external_storage/configuration.adoc[External Storage Configuration] for additional mount options and information. -* See xref:configuration/files/external_storage/auth_mechanisms.adoc[External Storage Authentication Mechanisms] for more information on authentication schemes. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/federated_cloud_sharing_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/federated_cloud_sharing_configuration.adoc deleted file mode 100644 index 02f4c42..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/federated_cloud_sharing_configuration.adoc +++ /dev/null @@ -1,223 +0,0 @@ -= Configuring Federation Sharing -:toc: right -:toclevels: 1 -:page-aliases: go/admin-sharing-federated.adoc -:description: With Federated Cloud Sharing, you can easily and securely link file shares between ownCloud servers, in effect creating a "cloud" of ownCloud installations. - -== Introduction - -{description} - -IMPORTANT: For security reasons federated sharing **strictly requires HTTPS (SSL/TLS)**. - -IMPORTANT: If you want to use HTTP for development and testing purposes, you have to set `'sharing.federation.allowHttpFallback' => true,` in **config/config.php**. - -== Configuration - -Follow these steps to establish a trusted connection between two servers. - -. Verify that both servers have SSL certificates. + -If you open the server URL in your browser and see a lock icon on the left-hand side of the address bar, the certificate is valid: -+ -.Lock icon in the address bars in Firefox, Google Chrome, and Safari -image::configuration/files/browser-address-bars.png[Lock icon in Firefox, Google Chrome, and Safari] - -. Verify that the `'overwrite.cli.url' => 'https://'` setting is configured to the correct URL instead of `localhost` in *config.php*: - -. Navigate to menu:Admin settings[Sharing > Federation] - -. Add **server 1** to the trusted servers on **server 2** - -. Add **server 2** to the trusted servers on **server 1** - -. Run on both servers: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} system:cron ----- - -. Run the `OCA\Federation\SyncJob` job with the `force` option on both servers. + -You can get the corresponding job ID by using the `background:queue:status` occ command: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:queue:execute --force ----- - -. The check should now be green - -. Now sync your users by running on both servers -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:sync-system-addressbook -{occ-command-example-prefix} federation:sync-addressbook ----- - -. Configure automatic acceptance of new federated shares -+ --- -NOTE: Automatic acceptance of new federated shares will not work if the option `Add server automatically once a federated share was created successfully` is also set. This is done because of security concerns. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set federation auto_accept_trusted --value '0' -{occ-command-example-prefix} config:app:set federatedfilesharing auto_accept_trusted --value 'yes' ----- --- - -== Working With Proxies - -There are ownCloud instances that are not connected to the internet. They have no possibility to reach the public network. Therefore Federation will not work without a proxy. - -Set the `proxy` and `proxyuserpwd` configuration variables, in `config/config.php`. `proxy` sets the proxy’s hostname, and `proxyuserpwd` sets the username and password credentials, in `username:password` format. - -== Creating a New Federation Share - -Follow these steps to create a new Federation share between two ownCloud servers. This requires no action by the user on the remote server; all it takes is a few steps on the originating server. - -. Enable the Federation app. - -. Create a federated share by entering username@serveraddress in the sharing dialog (for example `freda@https://example.com/owncloud`). When ownCloud verifies the link, -it displays it with the *(federated)* label. Click on this label to establish the link. -+ -image::configuration/files/federation-2.png[image, width=550] - -. When the link is successfully completed, you have a single share option, and that is *can edit*. -+ -image::configuration/files/federation-3.png[image, width=350] -+ -You may disconnect the share at any time by clicking the btn:[trash can] icon. - -== Federated Sharing Scanner CronJob Configuration - -IMPORTANT: As part of the migration step to 10.5, before enabling the cronjob described below, make sure to remove the system cron job from your crontab that executes legacy *occ incoming-shares:poll* - -The Federated Sharing Scanner is a background job used to scan the federated shares to ensure the integrity of the file cache. - -On each run the scanner will select federated shares that satisfy these requirements: - -. ensure that within a single cron run, at max [cronjob_scan_external_batch] scans will be performed out of all accepted external shares (default 100) - -. a scan of that external share has not been performed within the last [cronjob_scan_external_min_scan] seconds (default 3 hours) - -. the user still exists, and has been active recently, meaning logged in within the last [cronjob_scan_external_min_login] seconds (default 24 hours) - -. there has been a change in the federated remote share root etag or mtime, signaling a mandatory rescan - -To enable the cronjob, go to menu:Settings[Admin Settings > Federated Cloud Sharing] and enable the checkbox: - -image::configuration/files/sharing/federated-cloud-sharing/scan-cronjob.png[Checkbox, width=500] - -Alternatively you can use the command line: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_sharing cronjob_scan_external_enabled --value 'yes' ----- - -You can also configure these settings of the cronjob: - -. the minimum amount of time since last login of a user so that a scan is triggered (ensures only active users get fed shares synced) -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_sharing cronjob_scan_external_min_login --value ----- - -. the minimum amount of time since last scanned so that the next scan is triggered (avoid frequent scan when active collaboration) -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_sharing cronjob_scan_external_min_scan --value ----- - -. the maximum number of federated share scans per 10 minutes (scan performed only if fed share files got updated) -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_sharing cronjob_scan_external_batch --value ----- - -. Use the following command to force a run of the scanner cronjob: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:queue:execute --force --accept-warning ----- - -== Known Issues - -=== Persistent Locks Are Not Guaranteed - -There is a known bug in propagation of persistent locks to federated instances. If a user creates an exclusive lock on a share, no other users should be able to modify it, nor its contents, and all users should see a lock icon on the share. - -However, this isn't the case. The following functionality has been recorded: - -* The user who created the lock sees the lock icon throughout the share. -* The top-level of the share for receivers shows the lock icon. -* Sub-items of the share *do not show the lock icon*. -* The share and its contents *can still be modified by all users*; specifically: -** Sub-items *can be deleted*. -** Sub-items *can be created*. - -== Tips - -=== VCARD properties - -It is possible to configure the VCARD properties that are searched in order to retrieve a list of federated users in the share dialog. By default, ownCloud uses CLOUD and FN properties, however this list may be configured by the admin: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set dav remote_search_properties --value=CLOUD,FN,EMAIL ----- - -Possible values are: - -* VERSION -* UID -* FN -* N -* EMAIL -* CLOUD - -The value `CLOUD` enables searching by federation ID. Note that when `EMAIL` or `CLOUD` are enabled, hostnames are included in the search. Results are then returned for substrings of the hostname part, even when no user related field matches. - -=== Listing Federated Shares - -In case you want to see which federated shares exist on your server, you can use this command to list them. - -Currently there is no ownCloud `occ` command to list federated shares, that's why you have to use these database queries to obtain the information. - -Federated shares are saved in your database. - -[source,bash] ----- -sudo mysql -u -p -h ----- - -Incoming shares can be listed with the following query: - -[source,sql] ----- -select * from oc_share where share_type=6; ----- - -Each unique ID gives you an incoming federated share. - -Outgoing shares can be listed with the following query: (replace `cloud.example.com` with your instance URL) - -[source,sql] ----- -select * from oc_share_external where remote NOT IN ('https//cloud.example.com'); ----- - -Each unique ID gives you an outgoing federated share. - -Exit the database console with this command: - -[source,sql] ----- -quit ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/file_sharing_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/file_sharing_configuration.adoc deleted file mode 100644 index 78467d8..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/file_sharing_configuration.adoc +++ /dev/null @@ -1,548 +0,0 @@ -= File Sharing -:toc: right -:page-aliases: go/admin-sharing.adoc -:two-letter-url: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 -:description: This section describes how to set general configuration rules for sharing files. - -== Introduction - -{description} - -== General Notes - -The sharing policy is configured at menu:Settings[Admin > Sharing]. - -[NOTE] -==== -If you don't see the sharing section: - -* Check if you have installed an AdBlock browser plugin. - -If so, disable the plugin and recheck. -==== - -image:configuration/files/sharing-files-settings.png[ownCloud Sharing settings] - -From this section, ownCloud users can: - -* Share files with their ownCloud groups and other users on the same ownCloud server -* Share files with ownCloud users on other ownCloud servers, for more details see -xref:configuration/files/federated_cloud_sharing_configuration.adoc[Federated Cloud Sharing Configuration]. -* Create public link shares for people who are not ownCloud users. - -You have control of a number of user permissions on file shares: - -* Allow users to share files -* Allow users to create public link shares -** Allow public uploads to public link shares -** Enforce password protection on public link shares -** Set default expiration date on public link shares -** Allow users to send mail notification for shared files -** Set the language used for public mail notification for shared files -** Allow users to share file via social media -* Set default expiration date for user shares -** Set the number of days to expire after -** Enforce as maximum expiration date -* Set default expiration date for group shares -** Set the number of days to expire after -** Enforce as maximum expiration date -* Set default expiration date for remote shares -** Set the number of days to expire after -** Enforce as maximum expiration date -* Automatically accept new incoming local user shares -* Allow resharing -* Allow sharing with groups -* Restrict users to only share with users in their groups -* Restrict users to only share with groups they are a member of -* Allow users to send mail notification for shared files to other users -* Exclude groups from creating shares -* Allow username autocompletion in share dialog -** Restrict enumeration to group members -* Default user and group share permissions -* Extra field to display in autocomplete results - -NOTE: ownCloud includes a xref:configuration/server/security/password_policy.adoc[Share Link Password Policy app]. - -== Settings Explained - -=== Allow apps to use the Share API - -Check this option to enable users to share files. If this is not checked, no users can create file shares. - -=== Allow users to share via link - -Check this option to enable creating public link shares for people who are not ownCloud users via hyperlink. - -==== Allow public uploads - -Check this option to allow anyone to upload files to public link shares. - -==== Enforce password protection of public link shares - -Check these options to force users to set a password on public link shares. Passwords can be enforced on any or all of read-only, read-write, read-write-delete and upload-only (File Drop) public link shares. This does not apply to local user and group shares. - -==== Set default expiration date of public link shares - -Check this option to set a default expiration date on public link shares. Check _Enforce as maximum expiration date_ to limit the maximum expiration date to be the default. Users can choose an earlier expiration date if they wish. - -==== Allow users to send mail notification for shared files - -Check this option to enable sending notifications from ownCloud. When clicked, the administrator can choose the language for public mail notifications for shared files. - -image:configuration/files/sharing/choose-public-mail-notification-language.png[Choose the language for public -mail notifications for shared files in ownCloud.] - -What this means is, that email notifications will be sent in the language of the user that shared an item. By default the language is the share owner’s language. - -However, it can be changed to any of the currently available languages. It is also possible to change this setting on the command-line by using the -xref:configuration/server/occ_command.adoc#config-commands[occ config:app:set command], as in this example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} \ - config:app:set \ - core \ - shareapi_public_notification_lang \ - --value '' ----- - -NOTE: In the example above, the `` is an -{two-letter-url}[ISO 3166-1 alpha-2 two-letter country code], such as *de*, *gb*, *us*, *es* or others. - -NOTE: To use this functionality, your ownCloud server must be configured to send mail. - -==== Allow users to share file via social media - -Check this option to enable displaying of a set of links that allow for quickly sharing files and share links via *Twitter*, *Facebook*, *Google+*, *Diaspora*, and email. - -image:configuration/files/sharing/sharing-files-via-social-media.png[ownCloud social media sharing links] - -=== Set default expiration date for user shares - -Check this option to set a default expiration date when sharing with another user. The user can change or remove the default expiration date of a share. - -==== Set the number of days to expire after - -Set the default number of days that user shares will expire. The default value is 7 days. - -==== Enforce as maximum expiration date - -Check this option to limit the maximum expiration date to be the default. Users can choose an earlier expiration date if they wish. - -=== Set default expiration date for group shares - -Check this option to set a default expiration date when sharing with a group. The user can change or remove the default expiration date of a share. - -==== Set the number of days to expire after - -Set the default number of days that group shares will expire. The default value is 7 days. - -==== Enforce as maximum expiration date - -Check this option to limit the maximum expiration date to be the default. Users can choose an earlier expiration date if they wish. - -=== Set default expiration date for remote shares - -Check this option to set a default expiration date when sharing with a remote user. The user can change or remove the default expiration date of a share. - -==== Set the number of days to expire after - -Set the default number of days that remote shares will expire. The default value is 7 days. - -==== Enforce as maximum expiration date - -Check this option to limit the maximum expiration date to be the default. Users can choose an earlier expiration date if they wish. - -=== Automatically accept new incoming local user shares - -Disabling this option activates the "Pending Shares" feature. Users will be notified and have to accept new incoming user shares before they appear in the file list and are available for access giving them more control over their account. More information about -https://doc.owncloud.com/docs_main/next/server_release_notes.html#pending-shares[pending shares] -can be found in the release notes. - -=== Allow resharing - -Check this option to enable users to re-share files shared with them. - -=== Allow sharing with groups - -Check this option to enable users to share with groups. - -=== Default user and group share permissions - -Administrators can define the permissions for user/group shares that are set by default when users create new shares. As shares are created instantly after choosing the recipient, administrators can set the default to e.g. read-only to avoid creating shares with too many permissions unintentionally. - -=== Restrict users to only share with users in their groups - -Check this option to confine sharing within group memberships. - -NOTE: This setting does not apply to the Federated Cloud sharing feature. If -xref:configuration/files/federated_cloud_sharing_configuration.adoc[Federated Cloud Sharing] -is enabled, users can still share items with any users on any instances (_including the one they are on_) via a remote share. - -=== Restrict users to only share with groups they are a member of - -When this option is enabled, users can only share with groups they are a member of. They can still share with all users of the instance but not with groups they are not a member of. To restrict sharing to users in groups the sharer is a member of, the option _Restrict users to only share with users in their groups_ can be used. More information about -https://doc.owncloud.com/docs_main/next/server_release_notes.html#more-granular-sharing-restrictions[granular sharing restrictions] -can be found in the release notes. - -=== Allow users to send mail notification for shared files to other users - -Check this option to enable users to send an email notification to every ownCloud user that the file is shared with. - -=== Exclude groups from sharing - -Check this option to prevent members of specific groups from creating any file shares. When you check this, you will get a dropdown list of all your groups to choose from. Members of excluded groups can still receive shares, but not create any. - -=== Allow username autocompletion in share dialog - -Check this option to enable auto-completion of ownCloud usernames. - -==== Restrict enumeration to group members - -Check this option to restrict auto-completion of ownCloud usernames to only those users who are members of the same group(s) that the user is in. - -=== Extra field to display in autocomplete results - -The autocomplete dropdowns in ownCloud usually show the display name of other users when it is set. If it's not set, they show the user ID / login name, as display names are not unique you can run into situations where you cannot distinguish the proposed users. This option enables to add mail addresses or user ID's to make them distinguishable. - -== Blacklist Groups From Receiving Shares - -Sometimes it is necessary or desirable to block groups from receiving shares. For example, if a group has a significant number of users (> 5,000) or if it is a system group, it can be advisable to block it from receiving shares. In these cases, ownCloud administrators can blacklist one or more groups so that they cannot receive shares. - -To blacklist one or more groups via the Web UI, under menu:Settings[Admin > Sharing], add one or more groups to the _Files Sharing_ list. As you type the group’s name, if it exists, it will appear in the drop-down list where you can select it. - -image:configuration/files/sharing/blacklisting-groups.png[Blacklisting groups] - -== Transferring Files to Another User - -You may transfer files from one user to another with `occ`. The command transfers either all or a limited set of files from one user to another. It also transfers the outgoing shares and metadata info associated with those files (shares, tags, and comments, etc). Incoming shares are _not_ moved, as the sharing user holds the ownership of the respective files. This is useful when you have to transfer a user’s files to another user before you delete them. - -Trashbin contents are not transferred. - -Here is an example of how to transfer all files from one user to another. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:transfer-ownership \ - \ - ----- - -Here is an example of how to transfer _a limited group_ a single folder from one user to another. In it, `folder/to/move`, and any file and folder inside it will be moved to ``. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:transfer-ownership \ - --path="folder/to/move" \ - \ - ----- - -When using this command keep two things in mind: - -1. The directory provided to the `--path` switch *must* exist inside `data//files`. -2. The directory (and its contents) won’t be moved as is between the users. It will be moved inside the destination user’s `files` directory, and placed in a directory which follows the format: -`transferred from on `. Using the example above, it will be stored under: -`data//files/transferred from on 20170426_124510/` - -TIP: See the xref:configuration/server/occ_command.adoc[occ command reference], -for a complete list of `occ` commands. - -IMPORTANT: If an exception occurred during the transfer ownership command or the command terminated prematurely, it is advised to run following command for the source *and* target user: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:troubleshoot-transfer-ownership --uid ` ----- - -== Creating Persistent File Shares - -When a user is deleted, their files are also deleted. As you can imagine, this is a problem if they created file shares that need to be preserved, because these disappear as well. In ownCloud, files are tied to their owners. This means, whatever happens to the file owner also happens to the files. - -One solution to get around this issueis, to create persistent shares for your users. You can retain ownership of them, or you could create a special user for the purpose of establishing permanent file shares. Simply create a shared folder in the usual way, and share it with the users or groups who need to use it. Set the appropriate permissions on it and the share is independent which users come and go, the file shares will remain. Because all files added to the share or edited in it are automatically owned by the owner of the share regardless of who adds or edits them. - -== Create Shares Programmatically - -If you need to create new shares using command-line scripts, there are two available option. - -- <> -- <> - -=== occ files_external:create - -This command provides for the creation of both personal (for a specific user) and general shares. The command’s configuration options can be provided either as individual arguments or collectively, as a JSON object. For more information about the command, refer to the xref:configuration/server/occ_command.adoc#files-external[occ files-external documentation]. - -==== Personal Share - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files_external:create \ - /my_share_name windows_network_drive \ - password::logincredentials \ - --config={host=127.0.0.1, share='home', root='$user', domain='owncloud.local'} \ - --user someuser ----- - -or - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files_external:create \ - /my_share_name windows_network_drive \ - password::logincredentials \ - --config host=127.0.0.1 \ - --config share='home' \ - --config root='$user' \ - --config domain='somedomain.local' \ - --user someuser ----- - -==== General Share - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files_external:create \ - /my_share_name windows_network_drive \ - password::logincredentials \ - --config={host=127.0.0.1, share='home', root='$user', domain='owncloud.local'} ----- - -or - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files_external:create \ - /my_share_name windows_network_drive \ - password::logincredentials \ - --config host=127.0.0.1 \ - --config share='home' \ - --config root='$user' \ - --config domain='somedomain.local' ----- - -=== occ files_external:import - -You can create general and personal shares passing the configuration details via JSON files, using the `occ files_external:import` command. - -==== General Share - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files_external:import \ - /import.json ----- - -==== Personal Share - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files_external:import \ - /import.json --user someuser ----- - -In the two examples above, here is a sample JSON file, showing all of the available configuration options that the command supports. - -[source,json] ----- -{ - "mount_point": "\/my_share_name", - "storage": "OCA\\windows_network_drive\\lib\\WND", - "authentication_type": "password::logincredentials", - "configuration": { - "host": "127.0.0.1", - "share": "home", - "root": "$user", - "domain": "owncloud.local" - }, - "options": { - "enable_sharing": false - }, - "applicable_users": [], - "applicable_groups": [] -} ----- - -== Share Permissions - -=== Permissions Masks - -[width=50%,cols=3*~,options="header"] -|=== -| Permission -| Value -| web UI Value - -| READ -| 1 -| - -| UPDATE -| 2 -| _can update_ - -| CREATE -| 4 -| _can create_ - -| DELETE -| 8 -| _can delete_ - -| SHARE -| 16 -| _can reshare_ -|=== - -=== File Operations Shorthand for the Later Table - -[cols=2*~,options="header"] -|=== -| Operation -| Description - -| download -| Download/read/get a file or display a folder's contents. - -| upload -| A new file can be uploaded/created (file target does not exist). - -| upload_overwrite -| A file can overwrite an existing one. - -| rename -| Rename file to new name, all within the shared folder. - -| move_in -| Move a file from outside the shared folder into the shared folder. - -| move_in_overwrite -a| Move a file from outside the shared folder and overwrite a file inside the shared folder. - -NOTE: SabreDAV automatically deletes the target file first before moving, so requires DELETE permission too. - -| move_in_subdir -| Move a file already in the shared folder into a subdirectory within the shared folder. - -| move_in_subdir_overwrite -| Move a file already in the shared folder into a subdirectory within the shared folder and overwrite an existing file there. - -| move_out -| Move a file to outside of the shared folder. - -| move_out_subdir -| Move a file out of a subdirectory of the shared folder into the shared folder. - -| copy_in -| Copy a file from outside the shared folder into the shared folder. - -| copy_in_overwrite -a| Copy a file from outside the shared folder and overwrite a file inside the shared folder. - -NOTE: SabreDAV automatically deletes the target file first before copying, so requires DELETE permission too. - -| delete -| Delete a file inside the shared folder. - -| mkdir -| Create a folder inside the shared folder. - -| rmdir -| Delete folder inside the shared folder -|=== - -The following lists what operations are allowed for the different permission combinations (share permission is omitted as it is not relevant to file operations): - -[width=55%,cols="30%,30",options="header"] -|=== -| Operation(s) -| Permission Combinations - -| READ (aka read-only) -a| -* download - -| READ + + -CREATE -a| -* download -* upload -* move_in -* copy_in -* mkdir - -| READ + + -UPDATE -a| -* download -* upload_overwrite -* rename - -| READ + + -DELETE -a| -* download -* move_out -* delete -* rmdir - -| READ + + -CREATE + + -UPDATE -a| -* download -* upload -* upload_overwrite -* rename -* move_in -* copy_in -* mkdir - -| READ + + -CREATE + + -DELETE -a| -* download -* upload -* move_in -* move_in_overwrite -* move_in_subdir -* move_in_subdir_overwrite -* move_out -* move_out_subdir -* copy_in -* copy_in_overwrite -* delete -* mkdir -* rmdir - -| READ + + -UPDATE + + -DELETE -a| -* download -* upload_overwrite -* rename -* move_out -* delete -* rmdir - -| READ + + -CREATE + + -UPDATE + + -DELETE (all permissions) -a| -* download -* upload -* upload_overwrite -* rename -* move_in -* move_in_overwrite -* move_in_subdir -* move_in_subdir_overwrite -* move_out -* move_out_subdir -* copy_in -* copy_in_overwrite -* delete -* mkdir -* rmdir -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/file_versioning.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/file_versioning.adoc deleted file mode 100644 index 656b370..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/file_versioning.adoc +++ /dev/null @@ -1,165 +0,0 @@ -= Files Versions -:toc: right -:toclevels: 2 - -== Introduction - -Every time when a file gets rewritten to the storage, the versions app (`files_versions`) creates a new backup copy of the file. Versions are visible for the user in the webinterface only and do not get synced to clients. An admin can control the retention behaviour of versioned files. - -== How Versions are Created - -When a backup copy is created, it is stored inside a folder `files_versions` which is inside the users root folder. The app will add the suffix `.v` followed by the unix timestamp of the creation date of the backup copy. - ----- -. -├── files -│   └── welcome.txt -└── files_versions -    ├── welcome.txt.v1556203470 -    ├── welcome.txt.v1556203501 -    └── welcome.txt.v1556203567 ----- - -NOTE: File versioning only gets triggered if the change is made via the ownCloud ecosystem. It does not get triggered if the change is made at a mounted filesystem directly. - -Versions are displayed in the WebUI in the details view in the right sidebar if you click on the file row in the file listing. You can restore the current file to one of the earlier backup copies in the list, by clicking on the btn:[restore] icon of the specific version. - -image::configuration/files/files_versions/files-versions.png[File Versions in the WebUI] - -== How Versions are Deleted - -The versions app deletes old file versions automatically to ensure that users do not exceed their storage quotas. This is done by automatic background jobs which clean up the versions following a specific pattern. This pattern defines the expiration date for each backup version. - -=== Default Versions Delete Patterns - -This is the default pattern used to delete old versions: - -* For the last second we keep one version -* For the last 10 seconds ownCloud keeps one version every 2 seconds -* For the last minute ownCloud keeps one version every 10 seconds -* For the last hour ownCloud keeps one version every minute -* For the last 24 hours ownCloud keeps one version every hour -* For the last 30 days ownCloud keeps one version every day -* If the versions are older than 30 days ownCloud keeps one version every week - -The versions are adjusted along this pattern every time a new version is created and the background job was executed. - -==== Example - -[cols="2,3", options="header"] -|=== -|Time Period before last Expiration -|Maximum Number of Versions: - -|1 second -|1 - -|10 seconds -|5 - -| 1 minute -| 6 - -| 1 hour -| 59 - -| 1 day -| 23 - -| 30 days -| 30 -|=== - -WARNING: The versions app never uses more than 50% of the user’s storage quota. If the stored versions exceed this limit, ownCloud deletes the oldest file versions until it meets the disk space limit again. - -TIP: Adjust the `'versions_retention_obligation'` setting in `config.php` to avoid filling up the user's quota. For details see the section below. - -== Change the Expiration Settings - -You may alter the xref:configuration/server/config_sample_php_parameters.adoc#define-the-files-versions-retention-obligation[default pattern] in `config.php`. The default setting is `auto`, which sets the default pattern: - -[source,php] ----- -'versions_retention_obligation' => 'auto', ----- - -=== Possible Config Values - -[cols="1a,3"] -|=== -|`auto` -|Default value if nothing is set - -|`D, auto` -|Keep versions at least for D days, apply expiration rules to all versions that are older than D days - -|`auto, D` -|Delete all versions that are older than D days automatically, delete other versions according to expiration rules - -|`D1, D2` -|Keep versions for at least `D1` days and delete when they exceed `D2` days. - -|`disabled` -|Disable version retention; no files will be deleted. -|=== - -==== Example 1: - -Keep all versions for at least 10 days, apply expiration rules to all versions that are older than 10 days. This will keep a lot more versions during the last 10 days compared to the default pattern. - -[source,php] ----- -'versions_retention_obligation' => '10, auto', ----- - -==== Example 2: - -Apply expiration rules to all versions that are created during the last 30 days and do not keep any versions older than 30 days. - -[source,php] ----- -'versions_retention_obligation' => 'auto, 30', ----- - -==== Example 3: - -Do not apply any expiration rules. Delete all versions after 30 days. - -[source,php] ----- -'versions_retention_obligation' => '30, 30', ----- - -== Restoring a Version - -In the WebUI in the details view, there is a restore button next to the versions. It can be used to restore the file to a past version. Restore does not delete the old version, instead a new current version is created. - -WARNING: Note that retention policy can be applied after the restore operation, which could result in the old version being removed because of the retention policy. This behavior can be changed with the persistent major version feature discussed in the section below. - -== Extended Version Metadata - -Save additional metadata (author, version tag, etc.) of each version of uploaded and edited files. - -image::configuration/files/files_versions/version-metadata.png[Extended Version Metadata,width=300] - -You can enable the feature xref:configuration/server/config_sample_php_parameters.adoc#save-additional-metadata-for-versions[via an entry in config.php]. - -WARNING: The metadata is only collected after enabling the feature using the xref:configuration/server/config_sample_php_parameters.adoc#save-additional-metadata-for-versions[config.php] configuration file. This means the author or version number will show only for new versions of the file and be empty for older versions. - -=== Show the Author of a Version - -Each update to the file that generates a new file version will additionally show the author in the Versions Tab. This is helpful to keep track of who changed a version. - -=== Conscious Persistent Major Versions - -ownCloud can automatically generate and increment version numbers for new file versions. Based on this feature, one can define the actual version to be a major version which gets a major version number and all new upcoming versions start counting from this major number. Major versions are persistent versions that are not subject to any retention policies set by ownCloud. - -TIP: Publishing the version persists it until the original file is deleted by somebody with such permission or by the system administrator via occ versions:cleanup command. For more information check the xref:configuration/files/file_versioning.adoc#how-versions-are-deleted[versions retention] section. - -TIP: To create a new persistent major version, the user has to click on the check mark next to the version info tab. Check the image above. - -TIP: The versions follow the X.Y format, where X is a major part and Y is a minor part of the version. Version tags cannot be modified by the user, they are auto-generated by ownCloud. - -== Enterprise File Retention - -Enterprise customers have additional tools for managing file retention policies; see xref:enterprise/file_management/files_tagging.adoc[Advanced File Tagging With the Workflow App]. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/files_locking_transactional.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/files_locking_transactional.adoc deleted file mode 100644 index 3d57ece..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/files_locking_transactional.adoc +++ /dev/null @@ -1,35 +0,0 @@ -= Transactional File Locking -:page-aliases: go/admin-transactional-locking.adoc - -ownCloud’s Transactional File Locking mechanism locks files to avoid -file corruption during normal operation. It performs these functions: - -* Operates at a higher level than the filesystem, so you don’t need to -use a filesystem that supports locking -* Locks parent directories so they cannot be renamed during any activity -on files inside the directories -* Releases locks after file transactions are interrupted, for example -when a sync client loses the connection during an upload -* Manages locking and releasing locks correctly on shared files during -changes from multiple users -* Manages locks correctly on external storage mounts -* Manages encrypted files correctly - -Transactional File locking will not prevent multiple users from editing -the same document, nor give notice that other users are working on the -same document. Multiple users can open and edit a file at the same time -and Transactional File locking does not prevent this. Rather, it -prevents simultaneous file saving. - -[NOTE] -==== -Transactional file locking is in ownCloud core, and replaces the old File Locking app. -The File Locking app was removed from ownCloud in version 8.2.1. If your ownCloud server still has the File Locking app, -you *must* visit your Apps page to verify that it is disabled; the File Locking app and Transactional File Locking cannot both operate at the same time. -==== - -File locking is enabled by default, using the database locking backend. -This places a significant load on your database. Using -`memcache.locking` relieves the database load and improves performance. -Admins of ownCloud servers with heavy workloads should install -xref:configuration/server/caching_configuration.adoc[a memory cache] . diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/index.adoc deleted file mode 100644 index b69f845..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/index.adoc +++ /dev/null @@ -1,9 +0,0 @@ -= Files and Sharing - -This section contains all of the file and sharing related configuration documentation. -It includes such topics as: - -- xref:configuration/files/default_files_configuration.adoc[Default Files Configuration] -- xref:configuration/files/file_sharing_configuration.adoc[File Sharing Configuration]. -- xref:configuration/files/federated_cloud_sharing_configuration.adoc[Federated Cloud Sharing Configuration]. -- xref:configuration/files/manual_file_locking.adoc[Manual File Locking]. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/manual_file_locking.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/manual_file_locking.adoc deleted file mode 100644 index 6a15433..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/manual_file_locking.adoc +++ /dev/null @@ -1,95 +0,0 @@ -= Manual File Locking -:toc: right - -== Introduction - -Manual file locking allows users, if enabled, to lock files in shared areas while working on them in order to prevent concurrent changes from other users (check-in/check-out). - -The feature builds on the WebDAV Locks backend which has been introduced with Server 10.1 and is now available in the ownCloud Web Interface. All storages are supported as locking takes place on the WebDAV level. The locks will only be available via ownCloud, not when a user works directly on the storage. Using the context menu of files, every user who has access can lock them. Users can recognize locked files by the means of a new lock indicator. While a file is locked, other users can still access it but they can not make any changes. Locked files can manually be unlocked by the lock owner (the user who locked the file; exclusive locking) using the "Locks" tab in the file details view (right sidebar). - -== Example Use Case - -In a shared folder, one user wants to signal to others that nobody should change a certain file. To do so, the user locks the file. While locked, a copy can be download and locally edited (check-out). When done editing, the user first removes the lock and then uploads the changes (check-in). - -== Enable or Disable the UI Component - -NOTE: The _user-facing_ components in the web interface are disabled by default because this feature allows users to lock other users' files *exclusively*. Even the owner of the file can't unlock them. Lock releasing can only be done by the locking user, a user who is a member of a lock breaking group (if defined), or until the lock expires. - -By default, locks set by the user in the web interface will expire after 30 minutes. The maximum lock time by default is 24 hours. - -The main user-facing component in the web interface looks like in the following screenshots. If _Manual File Locking_ is disabled, the additional user-facing components are not present: - -[width="100%",cols="50%,50%",options="header"] -|=== -^| Manual Locking Disabled -^| Manual Locking Enabled - -a| image::configuration/files/manual_file_locking/lock-file-not-visible.png[File locking not visible] -a| image::configuration/files/manual_file_locking/lock-file-visible.png[File locking visible] -|=== - -If manual locking is enabled, the following additional user-facing components are present: - -[width="100%",cols="50%,50%"] -|=== -a| image::configuration/files/manual_file_locking/file-locked-symbol.png[File locked symbol] -a| image::configuration/files/manual_file_locking/file-locked-hint.png[File locking hint] - -a| image::configuration/files/manual_file_locking/file-locked-details.png[File locking details] -a| image::configuration/files/manual_file_locking/file-locked-unlock-symbol.png[File unlocking] - -|=== - -Administrators can enable _Manual File Locking_ for users either via the web interface or by executing an occ command: - -Web interface:: -Go to menu:Settings[Admin > General] -+ -image::configuration/files/manual_file_locking/manual-file-locking-with-lock-breaker.png[Enable file locking] - -Using the occ command:: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files enable_lock_file_action --value yes ----- - -== Configuration - -To prevent files being locked infinitely, there is a mechanism that automatically expires locks after a certain time. The expiration time of locks can either be configured via the web interface or using occ commands. In addition, administrators can define groups whose members can break locks. - -.The default timeout for the locks is, if not specified (in seconds): -Maximum lifetime of a lock set via the web interface (or by not specifying a timeout value when calling the WebDAV Locks API). - -.The maximum timeout for the locks (in seconds): -Maximum lifetime of locks which is allowed to be set by calling the WebDAV Locks API. - -.Define lock breaker groups: -Users who are a member of these groups can break locks set by another user. - -Web interface:: -Go to menu:Settings[Admin > General] + -The image is the same as shown above when enabling or disabling _Manual File Locking_. - -Using the occ command:: -* Default locks timeout -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files lock_timeout_default --value 1800 ----- -+ -* Maximum locks timeout -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files lock_timeout_max --value 86400 ----- -+ -* Define lock breaker groups -+ -The example below defines two lock breaker groups named `unlockers` and `admin`. -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set core lock-breaker-groups --value '["unlockers","admin"]' ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/mimetypes.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/mimetypes.adoc deleted file mode 100644 index 552eba2..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/mimetypes.adoc +++ /dev/null @@ -1,222 +0,0 @@ -= Mimetypes Management -:toc: right -:page-aliases: configuration/mimetypes/index.adoc - -:description: ownCloud allows you to create aliases for mimetypes and map file extensions to a mimetype. These allow administrators the ability to change the existing icons that ownCloud uses to represent certain file types and folders, as well as to use custom icons for mimetypes and file extensions which ownCloud doesn’t natively support. - -== Introduction - -{description} - -This is handy in a variety of situations, e.g. if you want a custom audio icon for audio mimetypes instead of the default file icon. - -== Mimetype Aliases - -ownCloud’s default mimetype configuration is defined in - -[source,plaintext] ----- -owncloud/resources/config/mimetypealiases.dist.json ----- - -Below you can see a snippet of the file where the mimetype’s on the left and the icon used to represent that mimetype is on the right. - -[source,json] ----- -{ - "application/coreldraw": "image", - "application/font-sfnt": "image", - "application/font-woff": "image", - "application/illustrator": "image", - "application/epub+zip": "text", - "application/javascript": "text/code" -} ----- - -You can see that: - -* the image icon is used to represent Corel Draw, SFNT and WOFF font files, and Adobe Illustrator files, -* ePub files are represented by the text file icon, -* JavaScript files are represented by the text/code icon. - -=== Changing Existing Icons and Using Custom Icons - -If you want to change one or more of the existing icons which ownCloud uses, or if you want to expand the available list, here’s how to do so: - -First, create a copy of - -[source,plaintext] ----- -resources/config/mimetypealiases.dist.json ----- - -and save it as - -[source,plaintext] ----- -config/mimetypealiases.json ----- - -This is required for two reasons: - -1. It will take precedence over the default file. -2. The original file will get replaced on each ownCloud upgrade. - -Then, either override one or more existing definitions or add new custom aliases as required. - -NOTE: Please refer to the xref:developer_manual:core/theming.adoc[ownCloud theming documentation] for where to put the new image files. - -Some common mimetypes that may be useful in creating aliases are: - -[cols=",",options="header",] -|============================================ -| Mimetype -| Description - -| `image` -| Generic image - -| `image/vector` -| Vector image - -| `audio` -| Generic audio file - -| `x-office/document` -| Word processed document - -| `x-office/spreadsheet` -| Spreadsheet - -| `x-office/presentation` -| Presentation - -| `text` -| Generic text document - -| `text/code` -| Source code -|============================================ - -Once you have made changes to - -[source,plaintext] ----- -config/mimetypealiases.json ----- - -use the xref:configuration/server/occ_command.adoc[occ command] to propagate the changes throughout your ownCloud installation. Here is an example for Ubuntu Linux: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mimetype:update-js ----- - -=== Example - Changing the JSON File Icon - -image:configuration/mimetypes/json-alias-before.png[The default icon for JSON files] - -Let’s go through an example of to change the icon that ownCloud uses to represent JSON files, which you can see above. - -1. From the root directory of your ownCloud installation, copy -+ -[source,plaintext] ----- -resources/config/mimetypealiases.dist.json ----- -+ -to -+ -[source,plaintext] ----- -config/mimetypealiases.json ----- - -2. Update the alias for `application/json`, which you should find on line 8, to match the following, and save the file: -+ -[source,plaintext] ----- -"application/json": "text/json", ----- - -3. Copy a new SVG icon to represent JSON files to `core/img/filetypes`, calling it `text-json.svg`. -+ -[NOTE] -==== -The name and location of the file are important. -* The location is because the `core/img/filetypes` directory stores the mimetype file icons. -* The name is important as it’s a rough mapping between the alias name and the icon’s file name, i.e., `text/json` becomes `text-json`. - -// to be tested if we need to add a config setting to exclude those files from integrity checks -==== - -4. Run the following command to update the mimetype alias database. -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mimetype:update-js ----- - -After doing so, whenever you view a folder that contains JSON files or upload one, your new icon file will be used to represent the file, as in the image below. - -image:configuration/mimetypes/json-alias-after.png[A replaced icon for JSON files] - -== Mimetype Mapping - -ownCloud allows administrators to map a file extension to a mimetype, e.g., such as mapping files ending in `mp3` to `audio/mpeg`. Which then, in turn, allows ownCloud to show the audio icon. - -The default file extension to mimetype mapping configuration is stored in - -[source,plaintext] ----- -resources/config/mimetypemapping.dist.json ----- - -This is similar to - -[source,plaintext] ----- -resources/config/mimetypealiases.dist.json ----- - -and also returns a basic JSON array. - -[source,json] ----- -{ - "3gp": ["video/3gpp"], - "7z": ["application/x-7z-compressed"], - "accdb": ["application/msaccess"], - "ai": ["application/illustrator"], - "apk": ["application/vnd.android.package-archive"], - "arw": ["image/x-dcraw"], - "avi": ["video/x-msvideo"], - "bash": ["text/x-shellscript"], - "json": ["application/json", "text/plain"] -} ----- - -In the example above, you can see nine mimetypes mapped to file extensions. Each of them, except the last (`json`), maps a file extension to a mimetype. Now take a look at the JSON example. - -In this case, ownCloud will first check if a mimetype alias is defined for `application/json`, in `mimetypealiases.json`. If it is, it will use that icon. If not, then ownCloud will fall back to using the icon for `text/plain`. - -If you want to update or extend the existing mapping, as with updating the mimetype aliases, create a copy of - -[source,plaintext] ----- -resources/config/mimetypemapping.dist.json ----- -and save it as - -[source,plaintext] ----- -config/mimetypemapping.json ----- - -Then, in this new file, make any changes required. - -NOTE: Please refer to the xref:developer_manual:core/theming.adoc[ownCloud theming documentation] for where to put the new image files. - -== Icon retrieval - -When an icon is retrieved for a mimetype, if the full mimetype cannot be found, the search will fallback to looking for the part before the slash. Given a file with the mimetype `image/my-custom-image`, if no icon exists for the full mimetype, the icon for `image` will be used instead. This allows specialized mimetypes to fallback to generic icons when the relevant icons are unavailable. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/previews_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/previews_configuration.adoc deleted file mode 100644 index 23a8013..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/previews_configuration.adoc +++ /dev/null @@ -1,257 +0,0 @@ -= Previews Configuration -:toc: right - -== Introduction - -The ownCloud preview system generates thumbnails and previews of files for all ownCloud apps that display files such as the Files or the Files Mediaviewer app. - -The following image shows some examples of previews of various file types. - -image:preview_images.png[Thumbnails of various image and audio/video files.] - -By default, ownCloud can generate previews for the following filetypes: - -* Images files -* Cover of MP3 files -* Text documents - -ownCloud supports the preview generation of file types such as PDF, SVG or various office documents. These document types can be a security issue as they can have javascript or other code either embedded or linked. - -IMPORTANT: Be careful enabling preview thumbnail generation for documents which could contain or reference executable code! ownCloud does NOT take any responsibility for any issues. - -== Important Considerations - -. Rendering takes place when the user accesses the folder and the preview has not been generated before. This means that each first folder access may create additional load on the server. - -. Previews are not a shared resource but rendered for each user individually. - -. Preview generation can only be set for the system and not for individual mounts. - -. When enabling preview generation for SVG, the preview code checks for the existence of `xlink:href` to external resources and disallows creating a preview. This minimizes the risk, but does not eliminate it. Such a check is not made for PDF or Office documents and enabling the creation of previews for those documents can be therefore a _serious security issue_. - -. When enabling preview generation for videos (or huge image files), consider the following points: -.. Because the video needs to be downloaded before a preview can be created, this may impact general accessibility of files for other users if the video resides on an external mount point with limited bandwidth like Google Drive. -.. The server may report timeouts if there are multiple videos to render and/or if the video is big. -.. Preview generation for videos is in general a resource intensive process. - -== Default Preview Providers - -Please note that the ownCloud preview system comes already with sensible defaults, and therefore it is usually not necessary to adjust those configuration values. If you want to configure previews, add or change the following parameters in `config/config.php`. - -The default list of enabled preview providers which do not need to be explicitly enabled in the config are: - -[source,plaintext] ----- -OC\Preview\BMP -OC\Preview\GIF -OC\Preview\JPEG -OC\Preview\WEBP -OC\Preview\MarkDown -OC\Preview\MP3 -OC\Preview\PNG -OC\Preview\TXT -OC\Preview\XBitmap ----- - -If you want to add or change the default list, you MUST define all elements used. If you just declare an additional item, only this item will be taken and none of the default list. - -== Prerequisites - -When defining your own preview providers, some things need to be considered. For some file types, ownCloud uses ImageMagick to generate previews. By default, the delivered version of ImageMagick for Ubuntu 20.04 is version 6, and the wrapper for php is version 3.4. This version of ImageMacick is _not_ capable of processing additional file formats like SVG or HEIC and many others. If you want to use those providers, you must upgrade ImageMagick to version 7 and the php wrapper to version 3.5. See the xref:installation/manual_installation/server_prep_ubuntu_20.04.adoc#php-imagick-library[php-imagick Library] section in the installation guide for more information. - -=== Notes for PDF Preview Generation - -If you handle the security risk and decide to allow creating previews for PDF files, change the following imagick security policy. Use an editor of your choice like `nano` and change the following file, adapt the path if using ImageMagick 7: - -[source,bash] ----- -sudo nano /etc/ImageMagick-6/policy.xml - or -sudo nano /etc/ImageMagick-7/policy.xml ----- - -Search for the following content: - -[source,plaintext] ----- - ----- - -and change: - -[source,plaintext] ----- -rights="none" --> rights="read|write" ----- - -After changing the policy file for ImageMagick, restart your Apache web server or your php-fpm service. -ImageMagick uses ghostscript for converting PDF. Please also make sure, that ghostscript is installed and the PDF format is listed when invoking the following command: - -[source,bash] ----- -convert -list format | grep -i pdf ----- - -=== Notes for Video Preview Generation - -To be able to create previews for video files when using the `OC\Preview\Movie` provider, you must install `ffmpeg`. There can be significant load on the server during conversion when video thumbnail generation is enabled. - -[source,bash] ----- -sudo apt install -y ffmpeg ----- - -=== List Extensions Used for the Preview Generation - -To get a list of file extensions linked to the image or video provider, change into the `owncloud` directory and run the following example command. Use a different filter for other provider types. - -[source,bash] ----- -cat resources/config/mimetypemapping.dist.json | grep image ----- - -== Preview Format Requirements - -The following providers require the php `imagick` extension to be enabled (check `phpinfo();`) and compiled with support for these formats: - -[source,plaintext] ----- -OC\Preview\AI -OC\Preview\EPS -OC\Preview\Heic -OC\Preview\PDF -OC\Preview\PSD -OC\Preview\SGI -OC\Preview\SVG -OC\Preview\TIFF -OC\Preview\TTF ----- - -The following providers are only available if either LibreOffice or OpenOffice is installed on the server: - -[source,plaintext] ----- -OC\Preview\MSOfficeDoc -OC\Preview\MSOffice2003 -OC\Preview\MSOffice2007 -OC\Preview\OpenDocument -OC\Preview\StarOffice ----- - -The following providers are available, but disabled by default due to performance or privacy/security concerns: - -[source,plaintext] ----- -OC\Preview\Font -OC\Preview\Illustrator -OC\Preview\Movie -OC\Preview\MSOfficeDoc -OC\Preview\MSOffice2003 -OC\Preview\MSOffice2007 -OC\Preview\OpenDocument -OC\Preview\StarOffice -OC\Preview\SVG -OC\Preview\PDF -OC\Preview\Photoshop -OC\Preview\Postscript -OC\Preview\TIFF ----- - -== Managing Your Preview Settings - -=== Disabling Previews - -Under certain circumstances, for example if the server has limited resources, you might want to consider disabling the generation of previews. Note that if you do this all previews in all apps are disabled and will display generic icons instead of thumbnails. - -Set the configuration option `enable_previews` to `false`: - -[source,php] ----- - 'enable_previews' => false, ----- - -=== Adding a Preview Provider - -The example below adds the preview provider for `SGI` and `HEIC` images: - -[source,php] ----- -'enabledPreviewProviders' => [ - 'OC\Preview\SGI', - 'OC\Preview\Heic', - 'OC\Preview\BMP', - 'OC\Preview\GIF', - 'OC\Preview\JPEG', - 'OC\Preview\MarkDown', - 'OC\Preview\MP3', - 'OC\Preview\PNG', - 'OC\Preview\TXT', - 'OC\Preview\XBitmap', - ], ----- - -NOTE: You have to add all default providers if you do not want to disable them. - -=== Maximum Image Dimensions - -Images up to a certain size feature preview generation (thumbnails and media viewer renderings). Images above that size show a default icon. -The default value is defined in `config/config.sample.php` as `6016x4000` which is sufficient for 24MP landscape images. - -The following example would change the limit so that 24MP portrait images also feature preview generation: - -[source,php] ----- - 'preview_max_dimensions' => '6016x6016', ----- - -NOTE: The dimensions here limit the size of the original image (input to the preview generator). A setting below limits the size of the generated preview images (output). For more details see the xref:configuration/server/config_sample_php_parameters.adoc#define-the-maximum-dimensions-of-the-original-image-for-preview-generation[Define the maximum dimensions of the original image for preview generation]. - -=== Maximum Preview Size - -There are two configuration options for setting the maximum size (in pixels) of a preview. These are `preview_max_x` which represents the x-axis and `preview_max_y` which represents the y-axis. The default value you can reference in `config/config.sample.php` is set to 2048. - -The following example would limit previews to a maximum size of 100 px × 100 px: - -[source,php] ----- - 'preview_max_x' => 100, - 'preview_max_y' => 100, ----- - -NOTE: If you want no limit applied for one or both of these values then set them to `null`. - -=== Maximum scale factor - -If a lot of small pictures are stored on the ownCloud instance and the preview system generates blurry previews, you might want to consider setting a maximum scale factor. By default, pictures are upscaled to 10 times the original size: - -[source,php] ----- - 'preview_max_scale_factor' => 10, ----- - -If you want to disable scaling at all, you can set the config value to `1': - -[source,php] ----- - 'preview_max_scale_factor' => 1, ----- - -If you want to disable the maximum scaling factor, you can set the config value to `null`: - -[source,php] ----- - 'preview_max_scale_factor' => null, ----- - -=== Define the JPEG Preview Quality - -The JP(E)G image quality can be defined in [%] for displaying thumbnails and image previews for apps like Files or Files Mediaviewer. Note that this setting is for displaying only and has no impact on the stored thumbnail / preview quality or size. - -[source,php] ----- - 'previewJPEGImageDisplayQuality' => -1, ----- - -The scale ranges from 1 to 100, where 1 is the lowest and 100 the highest. It defaults to -1 which is equivalent to approximately 75% of the original image quality. Consider that any value over 80 may result in an unnecessary increase of the displayed image and has larger response sizes when requesting images, without much increase of the image quality. Usually it is not necessary to have a quality setting over 75, but it can be increased if there is the need to display previews in high quality with the cost that every image requested generates a higher response load. Note that this setting does not affect downloading images. Setting a value takes immediate effect and nothing needs to be regenerated as it is for display requests only. - -For more information see: {php-net-url}/manual/en/function.imagejpeg.php[PHP imagejpeg — Output image to browser or file] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/files/trashbin_options.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/files/trashbin_options.adoc deleted file mode 100644 index cdcdefa..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/files/trashbin_options.adoc +++ /dev/null @@ -1,62 +0,0 @@ -= Managing the Trash Bin - -The ownCloud Trashbin (`files_trashbin`) permanently deletes files -according to users’ storage quotas and file ages. When a user deletes a -file it is not immediately removed from your ownCloud server, but goes -into the Trashbin. Then the user has the options to un-delete the file, -or to delete it permanently. - -image:configuration/files/trashbin-1.png[image] - -As the ownCloud server administrator, you have two `occ` commands for -permanently deleting files from the Trashbin manually, without waiting -for the normal aging-out process: - -[source,plaintext] ----- -trashbin - trashbin:cleanup Remove deleted files - trashbin:expire Expires the users trashbin ----- - -The `trashbin:cleanup` command removes the deleted files of all users, -or you may specify certain users in a space-delimited list. This example -removes all the deleted files of all users: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} trashbin:cleanup -Remove all deleted files -Remove deleted files for users on backend Database - user1 - user2 - user3 - user4 ----- - -This example removes the deleted files of user2 and user4: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} trashbin:cleanup user2 user4 - Remove deleted files of user2 - Remove deleted files of user4 ----- - -`trashbin:expire` deletes only expired files according to the -`trashbin_retention_obligation` setting in `config.php`. The default -setting is `auto`, which keeps files in the Trashbin for 30 days, then -deletes the oldest files as space is needed to keep users within their -storage quotas. Files may not be deleted if the space is not needed. - -The default is to delete expired files for all users, or you may list -users in a space-delimited list: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} trashbin:cleanup user1 user2 - Remove deleted files of user1 - Remove deleted files of user2 ----- - -See the *Deleted Files* section in xref:configuration/server/config_sample_php_parameters.adoc[Sample PHP Configuration Parameters], and xref:configuration/server/occ_command.adoc[the Trash Bin section] of the occ commands. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/code_signing.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/code_signing.adoc deleted file mode 100644 index 3d2f145..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/code_signing.adoc +++ /dev/null @@ -1,258 +0,0 @@ -= Code Signing -:toc: right -:page-aliases: issues/code_signing.adoc - -== Introduction - -ownCloud supports code signing for the core releases, and for ownCloud -applications. Code signing gives our users an additional layer of -security by ensuring that nobody other than authorized persons can push -updates. - -It also ensures that all upgrades have been executed properly, so that -no files are left behind, and all old files are properly replaced. In -the past, invalid updates were a significant source of errors when -updating ownCloud. - -All the possible errors and their explanations can be found xref:errors[here] - -== FAQ - -=== Why Did ownCloud Add Code Signing? - -By supporting Code Signing we add another layer of security by ensuring -that nobody other than authorized persons can push updates for -applications, and ensuring proper upgrades. - -=== Do We Lock Down ownCloud? - -The ownCloud project is open source and always will be. We do not want -to make it more difficult for our users to run ownCloud. Any code -signing errors on upgrades will not prevent ownCloud from running, but -will display a warning on the Admin page. For applications that are not -tagged "Official" the code signing process is optional. - -=== Not Open Source Anymore? - -The ownCloud project is open source and always will be. The code signing -process is optional, though highly recommended. The code check for the -core parts of ownCloud is enabled when the ownCloud release version -branch has been set to stable. - -For custom distributions of ownCloud it is recommended to change the -release version branch in version.php to something else than "stable". - -=== Is Code Signing Mandatory For Apps? - -Code signing is optional for all third-party applications. - -== Fixing Invalid Code Integrity Messages - -A code integrity error message (`There were problems with the code integrity check. More information…`) -appears in a yellow banner at the top of your ownCloud Web interface: - -image:issues/code-integrity-notification.png[Code integrity warning banner.] - -NOTE: The yellow banner is only shown for admin users. - -Clicking on this link will take you to your ownCloud admin page, which -provides the following options: - -1. Link to this documentation entry. -2. Show a list of invalid files. -3. Trigger a rescan. - -image:issues/code-integrity-admin.png[Links for resolving code integrity warnings.] - -To debug issues caused by the code integrity check click on btn:[List of invalid files], -and you will be shown a text document listing the different issues. -The content of the file will look similar to the following example: - ----- -Technical information -===================== -The following list covers which files have failed the integrity check. Please read -the previous linked documentation to learn more about the errors and how to fix -them. - -Results -======= -- core - - INVALID_HASH - - /index.php - - /version.php - - EXTRA_FILE - - /test.php -- calendar - - EXCEPTION - - OC\IntegrityCheck\Exceptions\InvalidSignatureException - - Signature data not found. -- tasks - - EXCEPTION - - OC\IntegrityCheck\Exceptions\InvalidSignatureException - - Certificate has been revoked. - -Raw output -========== -Array -( - [core] => Array - ( - [INVALID_HASH] => Array - ( - [/index.php] => Array - ( - [expected] => - f1c5e2630d784bc9cb02d5a28f55d6f24d06dae2a0fee685f3 - c2521b050955d9d452769f61454c9ddfa9c308146ade10546c - fa829794448eaffbc9a04a29d216 - [current] => - ce08bf30bcbb879a18b49239a9bec6b8702f52452f88a9d321 - 42cad8d2494d5735e6bfa0d8642b2762c62ca5be49f9bf4ec2 - 31d4a230559d4f3e2c471d3ea094 - ) - - [/version.php] => Array - ( - [expected] => - c5a03bacae8dedf8b239997901ba1fffd2fe51271d13a00cc4 - b34b09cca5176397a89fc27381cbb1f72855fa18b69b6f87d7 - d5685c3b45aee373b09be54742ea - [current] => - 88a3a92c11db91dec1ac3be0e1c87f862c95ba6ffaaaa3f2c3 - b8f682187c66f07af3a3b557a868342ef4a271218fe1c1e300 - c478e6c156c5955ed53c40d06585 - ) - - ) - - [EXTRA_FILE] => Array - ( - [/test.php] => Array - ( - [expected] => - [current] => - 09563164f9904a837f9ca0b5f626db56c838e5098e0ccc1d8b - 935f68fa03a25c5ec6f6b2d9e44a868e8b85764dafd1605522 - b4af8db0ae269d73432e9a01e63a - ) - - ) - - ) - - [calendar] => Array - ( - [EXCEPTION] => Array - ( - [class] => OC\IntegrityCheck\Exceptions\InvalidSignature - Exception - [message] => Signature data not found. - ) - - ) - [tasks] => Array - ( - [EXCEPTION] => Array - ( - [class] => OC\IntegrityCheck\Exceptions\InvalidSignatureException - [message] => Certificate has been revoked. - ) - - ) - [web] => Array - ( - [FILE_MISSING] => Array - ( - [.htaccess] => Array - ( - [expected] => 85ad7b1b88ad984f11f7f24f84e6aa9935eb75a36c50bf08efdbc5c295e67b3762a1bfacd8f981fb33e5c7c30d65eff7ebd6a47cb1f0de24e936a71cca2f023e - [current] => - ) - - ) - -) ----- - -In above error output it can be seen that: - -1. In the ownCloud core (that is, the ownCloud server itself) the files -`index.php` and `version.php` do have the wrong version. -2. In the ownCloud core the unrequired extra file `/test.php` has -been found. -3. It was not possible to verify the signature of the calendar -application. -4. The certificate of the task application was revoked. -5. The file `.htaccess` is missing. - -You have to do the following steps to solve this: - -1. Upload the correct `index.php` and `version.php` files from e.g. the archive of your ownCloud version. -2. Delete the `test.php` file. -3. Contact the developer of the application. A new version of the app -containing a valid signature file needs to be released. -4. Contact the developer of the application. A new version of the app -signed with a valid signature needs to be released. -5. Download the official server tar ball and copy the `.htaccess` into your instance. - -For other means on how to receive support please take a look at -the {oc-help-url}[Docs & Guides page]. After fixing these problems -verify by clicking btn:[Rescan]. - -NOTE: When using a FTP client to upload those files make sure it is using the `Binary` transfer mode instead of the `ASCII` transfer mode. - -== Rescans - -Rescans are triggered at installation, and by updates. You may run scans -manually with the `occ` command. The first command scans the ownCloud -core files, and the second command scans the named app. There is not yet -a command to manually scan all apps: - - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} integrity:check-core -{occ-command-example-prefix} integrity:check-app ----- - -TIP: See xref:configuration/server/occ_command.adoc[the occ command] to learn more about using `occ`. - -== Errors - -Please don’t modify the mentioned `signature.json` itself. - -The following errors can be encountered when trying to verify a code -signature. - -* `INVALID_HASH` -** The file has a different hash than specified within `signature.json`. -This usually happens when the file has been modified after writing the -signature data. -* `FILE_MISSING` -** The file cannot be found but has been specified within -`signature.json`. Either a required file has been left out, or -`signature.json` needs to be edited. -* `EXTRA_FILE` -** The file does not exist in `signature.json`. This usually happens -when a file has been removed and `signature.json` has not been updated. -It also happens if you have placed additional files in your ownCloud -installation folder. -* `EXCEPTION` -** Another exception has prevented the code verification. There are -currently these following exceptions: -*** `Signature data not found.` -**** The app has mandatory code signing enforced but no `signature.json` -file has been found in its `appinfo` folder. -*** `Certificate is not valid.` -**** The certificate has not been issued by the official ownCloud Code -Signing Root Authority. -*** `Certificate is not valid for required scope. (Requested: %s, current: %s)` -**** The certificate is not valid for the defined application. -Certificates are only valid for the defined app identifier and cannot be -used for others. -*** `Signature could not get verified.` -**** There was a problem with verifying the signature of -`signature.json`. -*** `Certificate has been revoked.` -**** The certificate which was used to sign the application was revoked. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/impersonate_users.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/impersonate_users.adoc deleted file mode 100644 index 42658e8..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/impersonate_users.adoc +++ /dev/null @@ -1,148 +0,0 @@ -= Impersonating Users -:toc: right -:page-aliases: issues/impersonate_users.adoc - -:description: To help users debug an issue or to get a better understanding of what they see when they use their ownCloud account, you can impersonate their ownCloud user. - -== Introduction - -{description} The ability to do so is a feature delivered via an ownCloud app called {oc-marketplace-url}/apps/impersonate[Impersonate]. - -== Limitations - -* This functionality is available to administrators only. -* Impersonating is not possible when the specific user has never logged in before. - -== Impersonating a User - -When installed, you can then impersonate users; in effect, you will be logged in as a specific user. To do so, go to the Users list, where you will now see a new column available called btn:[Impersonate], as in the screenshot below. - -image::apps/impersonate/picking-a-user-to-impersonate.png[Picking a User to Impersonate, width=450] - -Click the gray head icon next to the user that you want to impersonate. Doing so will log you in as that user, temporarily pausing your current session. You will see a notification at the top of the page that confirms you're now logged in as (or impersonating) that user. - -image::apps/impersonate/impersonating-a-user.png[Impersonating a user, width=350] - -Anything that you see until you log out will be what that user would see. - -== Ending an Impersonation - -When you're ready to stop impersonating the user, log out and you will return to your normal user session. - -== Group Concept for Impersonation - -Impersonate has two layers defining groups for impersonation. It is important to understand, that both the impersonator and the user to be impersonated must have the Impersonate app enabled. This means, if any groups are defined at the two layers, they must have an overlapping member area. - -. The first layer is defined at the level of the app, see xref:define-who-can-use-impersonate[Define Who can Use Impersonate]. This layer can be seen as a general area. If you do not want to have any restrictions, uncheck the checkbox, which means all users are eligible. - -. The second layer is defined at the level where the one who can impersonate and who can be impersonated are configured. See xref:define-who-is-allowed-to-impersonate[Define Who is Allowed to Impersonate]. This layer can be regarded as the detailed area. - -As a rule of thumb, first enable (1) as widely as wanted, then add option (2) as needed. - -NOTE: If an impersonator is granted the right to impersonate but cannot impersonate all or particular users, then the reason is usually that the impersonator is not a member of the respective groups. - -== Define Who can Use Impersonate - -* If you have installed and enabled the Impersonate App, you can define if any groups are granted the right to _use_ impersonation. To do so, go to menu:Your Username[Settings > Admin > Apps]. Members of the groups specified can use the Impersonate app, see xref:define-who-is-allowed-to-impersonate[Define Who is Allowed to Impersonate] -+ -image::apps/impersonate/impersonate_enable.png[Define who can use Impersonate,width=300] - -** You can also use an occ command to enable the Impersonate app for all users: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate enabled --value 'yes' ----- - -** You can also use an occ command to define groups whose members are granted the right to _use_ impersonation: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate enabled --value '["admin","einstein-g"]' ----- - -== Define Who is Allowed to Impersonate - -As a security measure, the application lets ownCloud administrators restrict the ability to impersonate users to: - -- ownCloud administrators only. -- All group administrators. -- Administrators for specific groups. - -NOTE: By default, when the Impersonate app is installed and no further configuration is taken, only ownCloud administrators will be allowed to impersonate users. - -To configure impersonation, go to the administrator settings panel, which you can find under menu:User Name[Settings > Admin > User Authentication], at section titled: btn:[Impersonate Settings]. - -* Use the following to allow impersonation for ownCloud admins only: -+ -image::apps/impersonate/impersonate_oc_admins_only.png[Impersonate for ownCloud admins only,width=500] - -** You can also use occ commands to do so: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_all_groupadmins --value false ----- -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_include_groups --value false ----- -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_include_groups_list --value '[]' ----- - -* If you want to allow all group admins to impersonate users within groups which they administer: -+ -image::apps/impersonate/impersonate_group_admins_only.png[Impersonate for all group admins,width=500] - -** You can also use occ commands to do so: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_all_groupadmins --value true ----- -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_include_groups --value false ----- -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_include_groups_list --value '[]' ----- - -* If you want to limit impersonation to admins of specific groups, first click btn:[Allow group admins of specific groups...]. With the option checked, click into the textbox underneath it. You will see a list of all groups on your ownCloud installation, which will change, based on what you type in the textbox to search for specific groups. Choose one or more groups from the list, and they will be added to the textbox, restricting this functionality to admins of those groups only. -+ -image::apps/impersonate/impersonate_groups_only.png[Impersonate for specific group admins,width=500] - -** You can also use occ commands to do so: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_all_groupadmins --value false ----- -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_include_groups --value true ----- -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - impersonate impersonate_include_groups_list --value '["group1", "group2"]' ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/index.adoc deleted file mode 100644 index 48ceb99..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/index.adoc +++ /dev/null @@ -1,7 +0,0 @@ -= General Topics - -In this section you will find information about: - -- xref:configuration/general_topics/code_signing.adoc[Code Signing] -- xref:configuration/general_topics/impersonate_users.adoc[Impersonating Users] -- xref:configuration/general_topics/search.adoc[Full Text Search] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/search.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/search.adoc deleted file mode 100644 index e57d073..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/general_topics/search.adoc +++ /dev/null @@ -1,351 +0,0 @@ -= Full Text Search -:toc: right -:toclevels: 4 -:page_aliases: configuration/search/index.adoc -:description: ownCloud offers the ability to use full text search via the Full Text Search app connecting to an Elasticsearch Server. This allows users to search not only for file names but also for content within files stored in ownCloud. - -:elastic-search-url: https://www.elastic.co/elasticsearch/ -:elastic-search-install-url: https://www.elastic.co/guide/en/elastic-stack/7.17/index.html -:search_elastic-app-url: {oc-marketplace-url}/apps/search_elastic -:simple-query-string-query-url: https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-simple-query-string-query.html -:ingest-url: https://www.elastic.co/guide/en/elasticsearch/plugins/current/ingest-attachment.html -:create-api-key-url: https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-create-api-key.html#security-api-create-api-key - -== Introduction - -{description} - -The {search_elastic-app-url}[Full Text Search] app integrates full text search into ownCloud, powered by Elasticsearch. This document describes how to setup the ownCloud part of the Full Text Search app. - -== Prerequisites - -. A fully functioning {elastic-search-url}[Elasticsearch Server 7]. Follow the {elastic-search-install-url}[Installation and Upgrade Guide] for your environment. -+ -[NOTE] -==== -* Version 1.0.0 of the Full Text Search app only works with Elasticsearch version 5.6. -* With version >=2.0.0 of the app, Elasticsearch version > 7 is required and has been tested and is supported up to version 8.6.2 though newer versions may work without any issues. -==== - -. The {ingest-url}[Ingest Attachment Processor Plugin] lets Elasticsearch extract metadata and text from over a thousand different file types such as PPT, XLS, PDF and more. To install the processor, run the following command from your Elasticsearch installation directory: -+ -[source,bash] ----- -sudo bin/elasticsearch-plugin install ingest-attachment ----- -+ -Post installing the Plugin, you need to restart the Elasticsearch server: -+ -[source,bash] ----- -sudo service elasticsearch restart ----- - -== Installation - -To install the app, use the Marketplace app on your ownCloud server or proceed manually: - -. Download and extract the tarball of the {search_elastic-app-url}[Full Text Search app] to the apps directory (or xref:installation/apps_management_installation.adoc#using-custom-app-directories[custom apps directory, prefered]) of your ownCloud instance. -. Use the xref:configuration/server/occ_command.adoc#apps-commands[App Commands] to enable the `search_elastic` application with: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable search_elastic ----- -+ -or enable it via the GUI menu:Settings[Admin > Apps > Full Text Search > Enable]. - -== Configuration - -To configure the Full Text Search, go to menu:Settings[Admin > Search]. - -=== Authentication Methods - -Independent of the authentication method selected below, you need to provide the URL of the Elasticsearch server. For any of the authentication methods selected, your Elasticsearch server must be prepared upfront. - -For the URL, both `HTTP` and `HTTPS` incuding the address and port can be used. - -The app provides several authentication methods. Select the one of your choice and check out the details for the respective authentication method below: - -image::apps/search_elastic/search_elastic_auth_items.png[Auth Items,width=450] - -==== No Authentication - -When using `No Authentication`, just fill in the URL of the ES server. - -image::apps/search_elastic/search_elastic_no_auth.png[No Auth,width=350] - -==== User / Password Authentication - -When using `User / Password Authentication`, enter the credentials set up on the ES server. Note that the password will be stored encrypted in the ownCloud database. - -image::apps/search_elastic/search_elastic_u_p_auth.png[User / Password Auth,width=350] - -==== API Key Authentication - -When using `API Key Authentication`, enter the API Key with which the ES server was set up. - -image::apps/search_elastic/search_elastic_api_key_auth.png[API Key Auth,width=350] - -IMPORTANT: The API Key needs to be the _encoded_ one, *not* the _api_key_ string. For details see the {create-api-key-url}[Create API key API] at the ES documentation. - -=== Search External Storage - -Define if external storage should be included in ES indexing by setting the checkmark accordingly with btn:[Scan external Storages]. Setting this checkmark not only enables search in external storages, but also search in federated shares. Note that this setting requires to rebuild the index. - -=== Connector Setup - -There are 2 different indexes. The `Legacy` is the old / current one while the `RelevanceV2` is the new one. The difference between the two is how index data is stored because both provide different capabilities and index in different ways. This results in different search capabilities. The Legacy doesn't differ from the current search while the RelevanceV2 has new capabilities. - -To populate the new connector with enhanced capabilities, an occ command needs to be run for each user, creating index data accordingly. See the occ command section xref:configuration/server/occ_command.adoc#fill-a-secondary-index[Fill a Secondary Index] for more details. - -image::apps/search_elastic/connector_setup.png[Connector Setup,width=600] - -==== Migrating to the RelevanceV2 Connector: - -* If you haven't indexed anything yet, you are encouraged to set up the connectors you want to use as part of the app configuration. The recommended one is `RelevanceV2` for `write` and `search`. - -* If you have indexed data already, use the following steps to migrate to the new index scheme: - -. Assuming you have the `Legacy` connector set up for `write` and `search`. - -. Add the `RelevanceV2` connector to the list of `write` connectors. The list should have both `Legacy` and `RelevanceV2`. - -. Run the `occ search:index:fillSecondary RelevanceV2 ` xref:configuration/server/occ_command.adoc#fill-a-secondary-index[command]. The command needs to be run for all users, or at least the ones using the search app. Note that this step is expected to take a lot of time. - -. Once indexed data has been migrated for all users, you can switch the search connector to use the new `RelevanceV2` search capabilities. - -. After checking everything is good, you can remove the old `Legacy` connector from the list of write connectors. - -. Finally you can completely remove the old index from Elasticsearch. - -With step 2, you will be writing into both indexes at the same time. This is expected to be slower. Note that step 2 just takes care of new files. Files indexed previously won't be present in the new index. This is why step 3 is there. - -Step 4 is important and you should stop at that point for a while. If something goes wrong, you can still revert things, in particular, you can switch back to the `Legacy` connector. In this case, use the occ command referenced above with the `Legacy` index. - -From step 5 the actions are irreversible. If you want to go back, you'll have to start a new migration. - -It's important to notice there isn't any expected downtime while the migration happens. Until step 4, the `Legacy` connector will keep updating the index normally. When the switch happens in the search connector, the new `RelevanceV2` connector will access the new index, which should have been fully updated. - -==== Enhanced Search Capabilities with RelevanceV2 - -The RelevanceV2 can boost scores of recently modified files. New files should appear first though this is not a guarantee because the score of a file could be too low. Even with the boost, files could score less than older but more relevant files. - -Additional searches you can do with the "RelevanceV2" connector: - -* Search by extension + -`ext:pdf`, `ext:docx`, `ext:gif`, `ext:mp4`, `ext:tar.gz`, `ext:gz`, etc., any extension is possible -* Search by size, only in bytes or megabytes -** Search by byte size: + -`size.b:<8092` , `size.b:>102400`, `size.b:[8092 TO 16184]` -** Search by megabyte size: + -`size.mb:<3`, `size.mb:>9`, `size.mb:[3 TO 9]` -* Search by type: only "file" or "folder" + -`type:file`, `type:folder` -* Search by date: -** Search by timestamp: + -`mtime:<1678960862`, `mtime:>1678960862`, `mtime:[1608111372 TO 1678960862]` + -** Search by date: + -`mtime:<2021-08-25`, `mtime:>2023-01-18`, `mtime:[2022-01-01 TO 2022-12-31]` -* Search by mimetype: + -`mime:image`, `mime:gif`, `mime:text` + -NOTE: To search for the whole mimetype such as "image/gif" use `mime.key:image\/gif`. - -Each search term will narrow the search. For example `brown ext:pdf` will be interpreted as "name or content containing brown AND extension = pdf", so "brown.pdf" and "a brown paper.pdf" will appear, but not "brown.txt" or "blue.pdf" - -Some examples of complex searches: - -* Files containing "confidential" updated since 2023 whose size is less than 10MB: + -`confidential mtime:>2023-01-01 size.mb:<10` -* Folders containing more than 1GB: + -`type:folder size.mb:>1024` -* Images between March and June 2020: + -`mime:image mtime:[2020-03-01 TO 2020-06-30]` - -Note that matching by name is pretty lax, so expect a bunch of unexpected results. Anyway, good results are expected to be on top. - -=== Save the Configuration - -Save the configuration with the btn:[Save configuration] button. - -=== Set up the ES Index - -When everything is set up, you can click the button btn:[Setup index] which will tell the ES server to create the plain empty index and other related internal settings. - -NOTE: This step is important, because the red dot will turn green showing that everything has been set up correctly. - -=== Resetting the ES Index - -You can at any time reset the index if required by clicking on btn:[Reset index] or with an occ command. The index will be recreated afterwards. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:reset ----- - -== Using occ Commands - -You can use the: - -* xref:configuration/server/occ_command.adoc#full-text-search[occ Full Text Search command set] to manage the app. These commands let administrators _create_, _rebuild_, _reset_, and _update_ the search index. For example, the following command resets and recreates the index for all users: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:reset ----- - -* xref:configuration/server/occ_command.adoc#config-commands[occ Config Commands command set] to configure the app. -+ -Examples: -+ -List app settings:: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:list search_elastic ----- -+ -[source,plaintext] ----- -{ - "apps": { - "search_elastic": { - "enabled": "yes", - "group": "content_searchers", - "installed_version": "2.1.0", - "nocontent": "false", - "scanExternalStorages": "1", - "servers": "elastic:xxxxxxx@172.17.0.3:9200", - "types": "filesystem" - } - } -} ----- - -Set app options:: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic scanExternalStorages --value 0 ----- -+ -or -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic scanExternalStorages --value 1 ----- - -== App Modes - -The Full Text Search app provides two modes, which are *active* and *passive*. - -=== Active Mode - -After enabling the app, it will be by default in _active mode_:: -+ -* File changes will be indexed in background jobs. + -System cron is recommended, otherwise a lot of jobs might queue up. -* Search results will be based on Elasticsearch. -* Search functionality based on ownCloud core database queries will no longer be used. -+ -NOTE: Active mode can cause a downtime for search when indexing starts on an already heavily used instance, because it takes a while until all files have been indexed. - -=== Passive Mode - -To do an initial full indexing without the app interfering, it can be put in _passive_ mode:: -+ -* The administrator can run occ commands changing the search configuration without notice to the users. -* The app will not index any changes by itself. -* Search results will still be based on ownCloud core database queries. - -=== Changing the App Mode - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic mode --value passive ----- - -or - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic mode --value active ----- - -== Restrict Search Results - -=== Index Metadata Only - -If you only want to use the Full Text Search app as a more scalable search on filenames, you can disable content indexing by setting the option `nocontent` to `true`, which defaults to `false`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic nocontent --value true ----- - -[NOTE] -==== -* You have to reindex all files if you change this back to `false`. Setting it to `true` does not require reindexing. -* It may be a more flexible way to go with limiting full text search to certain groups by setting the option `group.nocontent`, see xref:limit-metadata-search-for-groups[below] for details. -==== - -=== Limit Metadata Search for Groups - -If you only want to use search for shared filenames, you can disable full text search for specific groups by setting the option `group.nocontent` to the groups whose users should _only_ receive results based on filenames (not the full path), like users in the group `nofulltext` as in the example below: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic group.nocontent \ - --value nofulltext ----- - -You can also configure multiple groups by separating them with comma: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic group.nocontent \ - --value nofulltext,anothergroup,"group with blanks" ----- - -This allows a scalable search in shared files without clouding the results with content based hits. - -== Create the Index - -When everything has been set up and configured, you can initiate creating the index. This must be done with an occ command. Depending on using _active_ or _passive_ mode, you either have to: - -* *active mode*: wait until the job has finished and search is available to users, or -* *passive mode*: users continue to search with ownCloud embedded search and you switch over to active mode when the occ command has finished indexing. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:create ----- - -== Issues - -When the Elasticsearch server is down or the index has not been set up, you may get the following message. Check if the ES server is reachable or if the index was set up properly as one solution to fix the issue. - -image::apps/search_elastic/warning_could_not_setup_indexes_connection_failure.png[Warning no Index,width=350] - -image::apps/search_elastic/warning_could_not_setup_indexes_unknown_key.png[Warning unknown Key,width=350] - -== User Manual - -To find out more about the usage, check out the section in the User Manual: xref:classic_ui:files/webgui/search.adoc[Search & Full Text Search]. - -== Known Limitations - -Currently, the app has the following known limitations: - -* If a shared file is renamed by the sharee (share receiver), the sharee cannot find the file using the new filename. -* Search results are not updated when a text file is rolled back to an earlier version. -* The app does not return results for recieved federated share files. -* Search does currently not work when encrypting files via the encryption app. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/integration/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/integration/index.adoc deleted file mode 100644 index 9c75520..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/integration/index.adoc +++ /dev/null @@ -1,7 +0,0 @@ -= Integration - -This section is dedicated to integrating ownCloud with other products. - -- xref:configuration/integration/ms-teams.adoc[Microsoft Teams] - -- xref:configuration/integration/splunk.adoc[ownCloud App for Splunk] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/integration/ms-teams.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/integration/ms-teams.adoc deleted file mode 100644 index eefd555..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/integration/ms-teams.adoc +++ /dev/null @@ -1,154 +0,0 @@ -= Integrate ownCloud into Microsoft Teams -:toc: right -:toclevel: 3 -:appsource-url: https://appsource.microsoft.com/en-us/marketplace/apps?product=teams -:publish-custom-app-url: https://docs.microsoft.com/en-us/MicrosoftTeams/upload-custom-apps -:teams-app-setup-policies-url: https://docs.microsoft.com/en-us/microsoftteams/teams-app-setup-policies -:manage-apps-url: https://docs.microsoft.com/en-us/MicrosoftTeams/manage-apps -:what-are-tabs-url: https://docs.microsoft.com/en-us/microsoftteams/platform/tabs/what-are-tabs -:msteams-generator-url: https://msteamsgen.owncloud.com - -== Introduction - -If you're using Microsoft Teams in your organization or for private purposes, you will likely want to access your ownCloud installation from your Microsoft Teams account. For this purpose, we created the {msteams-generator-url}[ownCloud Generator for Admins] with which you can generate a customized Microsoft Teams app for your users accessing your ownCloud services. Each ownCloud domain to be accessed requires a separate generated Microsoft Teams app for your users. The generated app must then be uploaded in your organization's app catalog. - -NOTE: As a prerequisite, the OpenID Connect app is required. If you already have a OpenID Connect configuration made with another service, you have to reconfigure with Microsoft Azure AD, as only one identity provider configuration is allowed. - -== Prerequisites - -To get this working, you need to install and/or configure the following components: - -=== Option 1 "Enterprise": With Single Sign-On (SSO) and ownCloud Enterprise Edition -. Microsoft Azure Active Directory - -. ownCloud apps: -.. {oc-marketplace-url}/apps/openidconnect[OpenID Connect] -.. {oc-marketplace-url}/apps/msteamsbridge[MS-Teams Bridge App] - -. The custom app(s) you have generated with {msteams-generator-url}[ownCloud Generator for Admins] - -. Microsoft Teams - -=== Option 2 "Standard": With Basic Authentication and ownCloud Standard Edition - -. ownCloud apps: -.. {oc-marketplace-url}/apps/openidconnect[OpenID Connect] -. The custom Microsoft Teams app(s) you have generated with the {msteams-generator-url}[ownCloud Generator for Admins] -. Microsoft Teams - -Note: If you are using the Standard Edition, you can skip the following steps that describe the configuration of Azure AD and the MS-Teams Bridge App. - -== ownCloud - -=== Installation - -Assuming you have an ownCloud server version 10.7 or higher already running in your company or for personal use, perform the following steps: - -. Install and enable the MS-Teams Bridge app, minimum required version: v1.0.0. - -. Install and enable the {oc-marketplace-url}/apps/openidconnect[OpenID Connect] app from the ownCloud marketplace, minimum required version: v2.0.0. - -=== Configure the MS-Teams Bridge App - -You need to configure the MS-Teams Bridge app in two steps: - -. Add a _header_ directive to the Apache `.htaccess` configuration located in your ownCloud web root in section `` -+ -[source,apache,options="nowrap"] ----- -Header merge Content-Security-Policy "frame-ancestors 'self' teams.microsoft.com *.teams.microsoft.com" -Header edit* Content-Security-Policy , ; ----- -+ -Using `merge`, the response header is appended to any existing header of the same name, unless the value to be appended already appears in the header's comma-delimited list of values. When a new value is merged onto an existing header it is separated from the existing header with a comma. Merging avoids that headers of the same type and content being sent multiple times. This can happen if headers are also set on other locations. -+ -IMPORTANT: For the time being, if you add the header to the ownCloud's `.htaccess` file in the ownCloud web root, you have to manually add that header again after an ownCloud upgrade. - -. Add a config key to your `config.php` file -+ -This key is necessary for security reasons. Users will be asked to click a login button each time when accessing the ownCloud app after a fresh start of their Microsoft Teams app or after idle time. This behavior is by design. The button name can be freely set based on your requirements. -+ -[source,php] ----- -'msteamsbridge' => [ - "loginButtonName" => "Login to ownCloud with Azure AD", -], ----- - -. Enable xref:configuration/server/index_php_less_urls.adoc[index.php less URL´s] on your web server. - -== Microsoft - -=== Microsoft Azure and OpenID Connect - -Before you start to create your Microsoft Teams App, follow the procedure described in -xref:configuration/user/oidc/ms-azure-setup.adoc[Example Setup Using Microsoft Azure] to configure Microsoft Azure AD and OpenID Connect. - -=== Create Your Microsoft Teams App - -The following procedure creates an ownCloud app ready to be used by your users with Microsoft Teams in your environment. - -. In {msteams-generator-url}[ownCloud Generator for Admins] follow the guided instructions step by step. - -. Enter the Microsoft App/Client ID for your app. The ID´s to be entered *must* be the xref:configuration/user/oidc/ms-azure-setup.adoc#client-id[CLIENT-ID] from Microsoft Azure. -+ -image:configuration/integration/ms-teams/enter-app-id-msteamsgen.png[,width=80%] - -. Enter the version of the app you create. -+ -image:configuration/integration/ms-teams/define-app-version-msteamsgen.png[,width=80%] - -. Enter the name of the app you create. Take care about how to name your app. It *cannot* be changed later on. We recommend naming it *ownCloud for Teams* for easy identification. -+ -image:configuration/integration/ms-teams/app-name-msteamsgen.png[,width=80%] - -. Enter the description of the app you create. -+ -image:configuration/integration/ms-teams/app-description-msteamsgen.png[,width=80%] - -. Set the AccentColor of the app you create. -+ -image:configuration/integration/ms-teams/set-accent-color-msteamsgen.png[,width=80%] - -. Enter the URL how you access your owncloud instance like `+https://cloud.example.com+`. -+ -image:configuration/integration/ms-teams/owncloud-url-msteamsgen.png[,width=80%] - -. After performing all the steps, click the menu:download[] button and store the generated zip file locally. -+ -image:configuration/integration/ms-teams/download-zip-msteamsgen.png[,width=80%] - -. Go to the app section of Microsoft Teams and upload the generated zip file to your organization's app catalogue. Follow the {publish-custom-app-url}[Publish a custom app by uploading an app package] guide for more information. - -. The new app is now available to users in your organization's app catalog. - -. See the following documents on how to pin the app, set the order how apps appear or how to install apps on behalf of users. -.. {manage-apps-url}[Manage your apps in the Microsoft Teams admin center] -.. {teams-app-setup-policies-url}[Manage app setup policies in Microsoft Teams] - -See the xref:classic_ui:integration/ms-teams.adoc[users documentation] about their necessary steps how to integrate ownCloud into Microsoft Teams. - -=== Alternative ownCloud Website Tab - -As an alternative to creating an app for Microsoft Teams, it's also possible to embed ownCloud as a Microsoft Teams tab website. Tabs are Teams-aware webpages embedded in Microsoft Teams. See the {what-are-tabs-url}[What are Microsoft Teams tabs] documentation to find out more. - -. Press the btn:[+] plus button at the top of the Teams window. -+ -image:configuration/integration/ms-teams/add-a-tab-ms-teams.png[,width=80%] - -. Search for *website* and add by clicking on it. -+ -image:configuration/integration/ms-teams/add-website-ms-teams.png[,width=80%] - -. Add a meaningful name and the following URL replacing "cloud.example.com" with how you access your ownCloud instance. -+ -image:configuration/integration/ms-teams/name-and-url-ms-teams.png[,width=80%] -+ -[source,url] ----- -https://cloud.example.com/apps/msteamsbridge ----- - -== Support - -If you encounter problems with the integration of ownCloud and Teams, please contact ownCloud support or look for answers to those problems at the {oc-central-url}[Forum] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/integration/splunk.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/integration/splunk.adoc deleted file mode 100644 index 863d0df..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/integration/splunk.adoc +++ /dev/null @@ -1,83 +0,0 @@ -= ownCloud App for Splunk -:toc: right -:toclevel: 3 -:splunk-url: https://splunkbase.splunk.com/app/5503/ -:splunk-addon-url: https://splunkbase.splunk.com/app/5502/ -:splunk-docs-mult-index: https://docs.splunk.com/Documentation/Splunk/latest/Indexer/Setupmultipleindexes -:splunk-docs-uni-forwarder: https://docs.splunk.com/Documentation/Forwarder/latest/Forwarder/Installanixuniversalforwarder - -== Introduction - -The {splunk-url}[_ownCloud App for Splunk_] provides a sophisticated reporting and auditing tool for ownCloud service operators. It makes use of both ownCloud's technical logs (owncloud.log), audit logs and the _ownCloud Metrics_ API to provide insights. It shows information about users as well as storage and sharing usage across the instance and per user. It also makes audit evaluations quicker and more efficient. The app configures Splunk to retrieve and store the data and to provide visualizations, log filtering tools and pre-defined alerts for certain events. - -By aggregating, evaluating and visualizing the data provided by ownCloud, the _ownCloud App for Splunk_ allows service providers to gain insights into how their ownCloud platform is used and adopted (e.g., user, storage and sharing growth). Automatically gathering and processing ownCloud data enables a continuous reporting tool to be built up for stakeholders. For auditing purposes, the app provides very fine-grained and flexible tools that allow tracing actions by user, by operation or even by a single file and more. - -The app makes all relevant ownCloud data available in Splunk. The dashboards and tools can easily be extended or modified. With just a few clicks, they can be adapted to specific needs, using the filtering and visualization features provided by Splunk. - -== Prerequisites -To set up the _ownCloud App for Splunk_, a number of prerequisites have to be fulfilled. - -* ownCloud Classic has a minimum version of 10.5. -* Splunk has a minimum version of 7.2. -* The {oc-marketplace-url}/apps/metrics[_Metrics App_] is installed, configured and enabled on ownCloud Classic. -* The {oc-marketplace-url}/apps/admin_audit[_Auditing App_] is installed, configured and enabled on ownCloud Classic. -* Both components of the _ownCloud App for Splunk_ , the app and the add-on, are installed and configured. See below for further information on these components. - -== Setup & Configuration -=== ownCloud - -. Install and set up the {oc-marketplace-url}/apps/admin_audit[_Auditing App_] as xref:enterprise/logging/admin_audit.adoc[documented]. Take note of the log file paths (owncloud.log and admin_audit.log) as those will be required in the Splunk configuration below. - -. Install and set up the {oc-marketplace-url}/apps/metrics[_Metrics App_] as xref:enterprise/reporting/metrics.adoc[documented]. Take special care to set the Metrics API key as it will be required in the Splunk configuration below. - -=== Splunk - -The _ownCloud App for Splunk_ consists of two components that have to be installed and configured in Splunk. - -* The {splunk-addon-url}[_ownCloud Add-on for Splunk_] gathers and stores the ownCloud data in Splunk. -* The {splunk-url}[_ownCloud App for Splunk_] adds dashboards and other functionalities to the Splunk web interface. - -Both can be installed from the Splunkbase app store. You will find the necessary initial configuration below. - -==== ownCloud Add-on for Splunk (TA_owncloud) - -The {splunk-addon-url}[_ownCloud Add-on for Splunk_] (`TA_owncloud`) takes care of gathering the data from ownCloud as well as storing and indexing it in Splunk. It requires a Splunk Universal Forwarder to be installed on the ownCloud host. - -To get started, please follow the steps below. - -. Create an index for your ownCloud data (e.g., `index=owncloud`). -+ -The _ownCloud Add-on for Splunk_ does not ship with an index. You have to create an index on your Splunk instance or Splunk index cluster. For further help, refer to the respective {splunk-docs-mult-index}[Splunk documentation]. - -. Install a Splunk Universal Forwarder on your ownCloud host. For further information, consult the {splunk-docs-uni-forwarder}[Splunk documentation]. - -. Install the _ownCloud Add-on for Splunk_ - -* If you're using a standalone Splunk instance, you have to install the _ownCloud Add-on for Splunk_. -* If you're using a distributed Splunk installation, it depends on your setup: - * Search Heads: Installation of the _ownCloud Add-on for Splunk_ is required. - * Indexers: Installation of the _ownCloud Add-on for Splunk_ is conditional. It is not required if you use Heavy Forwarders to collect data. It is required if you use Universal Forwarders to collect data. - * Universal or Heavy Forwarders: Installation of the _ownCloud Add-on for Splunk_ required. In addition data and scripted input must be enabled as described below. - -. Enable data and scripted input with a configuration file. - -On your Universal Forwarder or Heavy Forwarder instance, you must enable input using the configuration files. - -. Copy `$SPLUNK_HOME/etc/apps/TA_owncloud/default/inputs.conf.example` to `$SPLUNK_HOME/etc/apps/TA_owncloud/local` directory and rename the file to `inputs.conf`. -. Open `$SPLUNK_HOME/etc/apps/TA_owncloud/local/inputs.conf` for editing. -. Check all `index = owncloud` settings and change the index name if needed. -. Check the ownCloud logs locations (default: `/var/www/owncloud/data/`) and change them to the values you configured on the ownCloud Classic server. -. Save the `$SPLUNK_HOME/etc/apps/TA_owncloud/local/inputs.conf` file. -. Copy `$SPLUNK_HOME/etc/apps/TA_owncloud/default/owncloud.conf.example` to `$SPLUNK_HOME/etc/apps/TA_owncloud/local` directory and rename the file to `owncloud.conf`. -. Open `$SPLUNK_HOME/etc/apps/TA_owncloud/local/owncloud.conf` for editing. -. Change the `METRICSAPIKEY` setting to the Metrics API key value you configured on the ownCloud Classic server. -. Change the `API_HOST` setting to your ownCloud instance domain name or IP address. This value is used to query the Metrics API for data. -. Save the `$SPLUNK_HOME/etc/apps/TA_owncloud/local/owncloud.conf` file. -. Restart the Splunk instance. - -==== ownCloud App for Splunk (owncloud_app) - -The {splunk-url}[_ownCloud App for Splunk_] (`owncloud_app`) adds the dashboards, visualizations and other functionalities to the Splunk web interface based on the indexed data. - -* Install the _ownCloud App for Splunk_ from Splunkbase. You only have to install it on Search Heads. -* If you created a custom index for ownCloud data, you have to modify a macro to include this index. You can do this in the Splunk web interface by navigating to menu:Settings[Advanced search > Search macros] and changing `owncloud-indexes` to your dedicated index (default: `index=owncloud`). diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/activity_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/activity_configuration.adoc deleted file mode 100644 index 0aeb38d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/activity_configuration.adoc +++ /dev/null @@ -1,35 +0,0 @@ -= Configuring the Activity App -:page-aliases: configuration_server/activity_configuration.adoc -:toc: right -:description: You can configure your ownCloud server to automatically send out email notifications to your users for various events. - -== Introduction - -{description} - -These events include: - -* A file or folder has been shared -* A file or folder has been changed -* A file or folder has been deleted -* A new file or folder has been created - -Users can see actions (_delete_, _add_, _modify_) that happen to files they have access to. Sharing actions are only visible to the sharer and recipient. - -== Enabling the Activity App - -The Activity App is shipped and enabled by default. If it is not enabled, go to menu:Settings[Admin > Apps] to enable it. - -== Configuring your ownCloud for the Activity App - -[TIP] -==== -A working email configuration is required to configure your ownCloud to send out email notifications. Furthermore, it is recommended to configure the xref:configuration/server/background_jobs_configuration.adoc#cron-jobs[background job] `Webcron` or `Cron`. -==== - -Email notifications for shared files can be enabled/disabled by administrators with the "_Allow users to send mail notifications for shared files to other users_" option, available in menu:Settings[Admin > Sharing]. There is also a xref:configuration/server/config_apps_sample_php_parameters.adoc#app-activity[configuration option] `activity_expire_days` available in your `config.php` which allows you to clean up older activities from the database. - -== Time Base - -* Whenever a default date is enabled and set for expiring shares (e.g. after 7 days), the time base for default dates is the time of the ownCloud server, not the time of the client accessing the ownCloud server. -* When a client receives an expiry notification for a share, the expiry is effective at the end of the day based on the time of the ownCloud server and not the time of the client accessing the ownCloud server. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/background_jobs_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/background_jobs_configuration.adoc deleted file mode 100644 index 209a7de..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/background_jobs_configuration.adoc +++ /dev/null @@ -1,175 +0,0 @@ -= Background Jobs -:toc: right -:page-aliases: go/admin-background-jobs.adoc -:cron_url: https://en.wikipedia.org/wiki/Cron -:crontab_url: https://linux.die.net/man/1/crontab -:systemd_url: https://wiki.archlinux.org/index.php/Systemd/Timers -:oc-docker-url: https://github.com/owncloud-docker/base#environment-variables - -== Introduction - -A system like ownCloud sometimes requires tasks to be done on a regular basis without requiring user interaction or hindering ownCloud's performance. For that reason, as a system administrator you can configure background jobs (for example, database clean-ups) to be executed without any user interaction. - -These jobs are typically referred to as {cron_url}[Cron Jobs]. Cron jobs are commands or shell-based scripts that are scheduled to periodically run at fixed times, dates, or intervals. To run Cron jobs with ownCloud, we recommend that you use the occ `system:cron` command. - -Use the xref:configuration/server/occ_command.adoc#background-jobs-selector[occ background command set] to select which scheduler you want to use for controlling. For more details on how to manage background jobs, refer to xref:configuration/server/occ_command.adoc#managing-background-jobs[Managing Background Jobs]. - -As an example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:cron ----- - -Is the same as using the *Cron* section on your ownCloud Admin page. - -=== Docker Note - -If you are using the official docker images you don't need to take care about the configuration for background jobs, the docker image is already configured to use cron internally. If required, this can also be adjusted by the {oc-docker-url}[environment variables] `OWNCLOUD_CROND_ENABLED` and `OWNCLOUD_CROND_SCHEDULE`. - -== Cron Jobs - -You can schedule Cron jobs in three ways: xref:cron[Cron], xref:webcron[Webcron], or xref:ajax[AJAX]. These can all be configured in the admin settings menu. However, the recommended method is to use Cron. The following sections describe the differences between each method. - -There are a number of things to keep in mind when choosing an automation option: - -. While the default method is AJAX, though the preferred way is to use Cron. + -The reason for this distinction is that AJAX is easier to get up and running. As a result, it makes sense (often times) to accept it in the interests of expediency. However, doing so is known to cause issues, such as backlogs and potentially not running every job on a heavily-loaded system. What's more, an increasing amount of ownCloud automation has been migrated from AJAX to Cron in recent versions. For this reason, we encourage you to not use it for too long — especially if your site is rapidly growing. - -. While Webcron is better than AJAX, it has limitations too. + -For example, running Webcron will only remove a single item from the job queue, not all of them. Cron, however, will clear the entire queue. - -NOTE: It's for this reason that we encourage you to use Cron — if at all possible. - -=== Cron - -Using the operating system Cron feature is the preferred method for executing regular tasks. This method enables the execution of scheduled jobs without the inherent limitations which the web server might have. - -For example, to run a Cron job on a *nix system every 15 minutes (recommended), under the default web server user (often, `www-data` or `wwwrun`) you must set up the following Cron job to call the occ `system:cron` command: - -[source,bash] ----- -sudo crontab -u www-data -e -*/15 * * * * /usr/bin/php -f /path/to/your/owncloud/occ system:cron ----- - -You can verify if the cron job has been added and scheduled by executing: - -[source,bash] ----- -sudo crontab -u www-data -l -*/15 * * * * /usr/bin/php -f /path/to/your/owncloud/occ system:cron ----- - -NOTE: You have to make sure that PHP is found by Cron; hence why we've deliberately added the full path. - -Please refer to {crontab_url}[the crontab man page] for the exact command syntax if you don't want to have it run every 15 minutes. - -NOTE: There are other methods to invoke programs by the system regularly, e.g., {systemd_url}[systemd timers] - -=== Webcron - -By registering your ownCloud `cron.php` script address as an external webcron service (for example, http://www.easycron.com/[easyCron]), you ensure that background jobs are executed regularly. To use this type of service, your external webcron service must be able to access your ownCloud server using the Internet. For example: - -[source,plaintext] ----- -URL to call: http[s]:///owncloud/cron.php ----- - -=== AJAX - -The AJAX scheduling method is the default option. + -However, it is also the _least_ reliable. Each time a user visits the ownCloud page, a single background job is executed. The advantage of this mechanism, however, is that it does not require access to the system nor registration with a third party service. The disadvantage of this mechanism, when compared to the xref:webcron[Webcron] service, is that it requires regular visits to the page for it to be triggered. - -NOTE: Especially when using the Activity App or external storages, where new files are added, updated, or deleted one of the other methods should be used. - -=== Parallel Task Execution - -Regardless of the approach which you take, since ownCloud 9.1, Cron jobs can be run in parallel. This is done by running `background:cron` multiple times. Depending on the process which you are automating, this may not be necessary. However, for longer-running tasks, such as those which are LDAP related, it may be very beneficial. - -There is no way to do so via the ownCloud UI. But, the most direct way to do so, is by opening three console tabs and in each one run - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} system:cron ----- - -Each of these processes would acquire their own list of jobs to process without overlapping any other. - -=== Available Background Jobs - -A number of existing background jobs are available to be run just for specific tasks. - -[NOTE] -==== -These jobs are generally only needed on large instances and can be run as background jobs. If the number of users in your installation ranges between 1,000 and 3,000, or if you're using LDAP and it becomes a bottleneck, then admins can delete several entries in the `oc_jobs` table and replace them with the corresponding `occ` command, which you can see here: - -* `OCA\\DAV\CardDAV\\SyncJob` -> `occ dav:sync-system-addressbook` -* `OCA\\Federation\\SyncJob` -> `occ federation:sync-addressbooks` -* `OCA\\Files_Trashbin\\BackgroundJob\\ExpireTrash` -> `occ trashbin:expire` -* `OCA\\Files_Versions\\BackgroundJob\\ExpireVersions` -> `occ versions:expire` - -If used, these should be scheduled to run on a daily basis. -==== - -While not exhaustive, these include: - -==== CleanupChunks - -The `CleanupChunks` command, `occ dav:cleanup-chunks`, will clean up outdated chunks (uploaded files) more than a certain number of days old and needs to be added to your crontab. - -NOTE: There is no matching background job to delete from the `oc_jobs` table. - -==== ExpireTrash - -The ExpireTrash job, contained in `OCA\Files_Trashbin\BackgroundJob\ExpireTrash`, will remove any file in the ownCloud trash bin which is older than the specified maximum file retention time. It can be run, as follows, using the xref:configuration/server/occ_command.adoc#trashbin[OCC trashbin] command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} trashbin:expire ----- - -==== ExpireVersions - -The ExpireVersions job, contained in `OCA\Files_Versions\BackgroundJob\ExpireVersions`, will expire versions of files which are older than the specified maximum version retention time. It can be run, as follows, using the xref:configuration/server/occ_command.adoc#versions[OCC versions] command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} versions:expire ----- - -CAUTION: Please take care when adding `ExpireTrash` and `ExpireVersions` as xref:cron[Cron] jobs. Make sure that they're not started in parallel on multiple machines. Running in parallel on a single machine is fine. But, currently, there isn't sufficient locking in place to prevent them from conflicting with each other if running in parallel across multiple machines. - -==== SyncJob (CardDAV) - -The `CardDAV SyncJob`, contained in `OCA\DAV\CardDAV\SyncJob`, syncs the local system address book, updating any existing contacts, and deleting any expired contacts. It can be run, as follows, using the xref:configuration/server/occ_command.adoc#dav-commands[OCC dav] command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:sync-system-addressbook ----- - -==== SyncJob (Federation) - -OCAFederationSyncJob - -It can be run, as follows, using the -xref:configuration/server/occ_command.adoc#federation-sync[OCC federation sync] command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} federation:sync-addressbooks ----- - -== Troubleshooting - -=== Remove Non-Existent Background Jobs - -See the xref:troubleshooting/remove_non_existent_bg_jobs.adoc[Remove Non-Existent Background Jobs] section in the general troubleshooting documentation for more details. - -=== Forbidden error for Scanner.php - -If you find a **Forbidden** error message in your log files, with a reference to the `Scanner.php` file, then you should: - -* Check if you have any shares with the status `pending`. -* Configure `conditional logging` for cron to see more output. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/caching_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/caching_configuration.adoc deleted file mode 100644 index 5abcccf..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/caching_configuration.adoc +++ /dev/null @@ -1,544 +0,0 @@ -= Memory Caching -:toc: right -:flushall_url: https://github.com/memcached/memcached/wiki/Commands#flushall -:redis_url: https://redis.io/ -:redis_doc_url: https://redis.io/documentation -:redis_security_url: https://redis.io/topics/security -:rediscli_url: https://redis.io/topics/rediscli -:redis_select_url: https://redis.io/commands/select -:redis_flushdb_url: https://redis.io/commands/flushdb -:redis-memcached-url: https://scalegrid.io/blog/redis-vs-memcached-2021-comparison/ - -== Introduction - -You can _significantly_ improve ownCloud server performance by using memory caching. This is the process of storing frequently requested objects in memory for faster retrieval later. There are two types of memory caching available: - -A PHP opcode Cache (OPcache):: -An opcode cache stores compiled PHP scripts (opcodes) so they don’t need to be parsed and compiled every time they are called. These compiled PHP scripts are stored in shared memory on the server on which they’re compiled. - -A Data Cache:: -A data cache stores copies of _data_, _templates_, and other types of _information-based files_. Depending on the cache implementation, it can be either _local_ or specific to one server or _distributed_ across multiple servers. This cache type is ideal when you have a scale-out installation. - -In addition, we suggest to use *External Transactional File Locking* which reduces load on the database significantly. - -== Supported Caching Backends - -The caching backends supported by ownCloud are: - -* xref:opcache[Opcache] + - This is an opcode cache only and does *not* cache any data. - Opcache is bundled with PHP from version 5.5.0 and later. -* xref:apcu[APCu] + - This is a data cache only and does *not* cache any opcode. - APCu 4.0.6 and up is required. -* xref:redis[Redis] + - This is an in-memory data structure store (cache) for single and multi-server ownCloud installations, which provides file locking and can be set up in local or distributed environments. Consider Redis younger, richer in features and more configurable than memcached. At least version 2.2.6 or higher of the PHP Redis extension is required. -* xref:memcached[Memcached] + - This is a distributed cache for multi-server ownCloud installations and has *no* file locking capabilities. - -See the following page to learn more about the {redis-memcached-url}[Redis vs. Memcached – 2021 Comparison]. - -[NOTE] -==== -You may use _both_ a local and a distributed cache. The recommended ownCloud caches are APCu and Redis. If you do not install and enable a local memory cache you will see a warning on your ownCloud admin page. If you enable only a distributed cache in your `config.php` (`memcache.distributed`) and not a local cache (`memcache.local`) you will still see the cache warning. -==== - -=== Cache Directory Location - -The cache directory defaults to `data/$user/cache` where `$user` is the current user. You may use the `'cache_path'` directive in your configuration for different locations. For details see the xref:configuration/server/config_sample_php_parameters.adoc#define-the-location-of-the-cache-folder[Define the location of the cache folder] description. - -== Cache Types - -=== Opcache - -Opcache should be enabled by default in your php installation. To check it, run the following command: - -[source,bash] ----- -php -r 'phpinfo();' | grep opcache.enable ----- - -=== APCu - -The easiest cache to use is APCu, because it is a pure data cache, very fast as it is memory-based only and _nothing needs to be configured_. APCu can not be used when running on an external server like in a distributed environment. - -==== Installing APCu - -On Ubuntu/Debian/Mint systems, if not already done: -[source,bash] ----- -sudo apt install php-apcu ----- - -With that done, assuming that you don’t encounter any errors, restart Apache and the extension is ready to use. - -=== Redis - -{redis_url}[Redis] is an excellent modern memory cache to use for both distributed caching and as a local cache for -xref:configuration/files/files_locking_transactional.adoc[transactional file locking], because it guarantees that cached objects are available for as long as they are needed. - -The performance of Redis when used with a socket connection can get close to the performance of APCu. - -NOTE: The Redis PHP module must be at least version 2.2.6 or higher. - -[NOTE] -==== -* For Ubuntu 20.04, the default shipped Redis Server version and the php-redis extension is 5.x. -* For Ubuntu 22.04, the default shipped Redis Server version is 6.0.16. -* For Ubuntu 22.04, the php7.4-redis extension has version 5.3.x. -* With Redis version 6, a new authentication mechanism has been introduced named ACL (Access Control Lists). ownCloud does currently not support Redis ACLs, but does support the password protection available with current Redis versions. -==== - -==== Installing Redis - -On Ubuntu/Debian/Mint systems, if not already done: - -[source,bash] ----- -sudo apt install redis-server php-redis ----- - -The installer will automatically launch Redis and configure it to launch at startup. - -After that, assuming that you don’t encounter any errors, restart Apache and the extension is ready to use. - -==== Redis Performance Consideration - -* Because Redis writes data to disk, it is recommended to use a high performance backend like SSD. -* If you do not have a distributed environment where the Redis server is installed at a different machine, you can configure Redis to be xref:redis-configuration-using-unix-sockets[socket-based] instead of TCP-based to xref:redis-performance-comparison-tcp-vs-socket[increase performance]. - -==== Additional notes for Redis vs. APCu on Memory Caching - -* APCu is faster at local caching than Redis when using TCP since APCu is memory-based only. -* If you have enough memory, use APCu for in memory caching and Redis for file locking. -* If you are limited in memory or only want to have one caching backend, use Redis for both. -* Consider using sockets instead of TCP when you decide on Redis but do not have a distributed caching environment. - -==== Clearing the Redis Cache - -The Redis cache can be flushed from the command-line using the {rediscli_url}[redis-cli tool], as in the following example: - -[source,bash] ----- -sudo redis-cli -SELECT -FLUSHDB ----- - -`` is the number of the Redis database where the cache is stored. It is zero by default at ownCloud. To check what yours is currently set to for ownCloud, check the `dbindex` value in `config/config.php`. To change it, see the -xref:configuration/server/config_sample_php_parameters.adoc#memory-caching-backend-configuration[Memory caching backend configuration] - -NOTE: Out of the box, every Redis instance supports 16 databases so `` has to be set between 0 and 15. - -Please read more about the instructions for the -{redis_select_url}[select] and {redis_flushdb_url}[flushdb] command. - -=== Memcached - -Memcached is a reliable old-timer for shared caching on distributed servers. It performs well with ownCloud with one exception: it is not suitable to use with -xref:configuration/files/files_locking_transactional.adoc[Transactional File Locking]. -This is because it does not store locks, and data can disappear from the cache at any time. Given that, Redis is the best memory cache to use. - -NOTE: Be sure to install the *memcached* PHP module, and not _memcache_, as in the following examples. ownCloud supports only the *memcached* PHP module. - -==== Installing Memcached - -===== On Ubuntu/Debian/Mint - -On Ubuntu/Debian/Mint run the following command: - -[source,bash] ----- -sudo apt-get install memcached php-memcached ----- - -NOTE: The installer will automatically start `memcached` and configure it to launch at startup. - -==== Configuration File Paths - -[cols=",",options="header",] -|=== -| PHP Version | Filename -| {recommended-php-version} | `/etc/php/{recommended-php-version}/mods-available/memcached.ini` -|=== - -Note that the PHP version depends on your envoronment. - -After that, assuming that you don’t encounter any errors: - -. Restart your Web server -. Add the appropriate entries to `config.php` (which you can find an example of below) -. Refresh your ownCloud admin page - -==== Clearing the Memcached Cache - -The Memcached cache can be flushed from the command line, using a range of common Linux/Unix tools including `netcat` and `telnet`. The following example uses telnet to log in, run the {flushall_url}[flush_all command], and log out: - -[source,bash,subs="attributes+"] ----- -telnet localhost {std-port-memcache} -flush_all -quit ----- - -== Configuring Memory Caching - -Memory caches must be explicitly configured in ownCloud by: - -. Installing and enabling your desired cache (whether that be the PHP extension and/or the caching server). -. Adding the appropriate entry to ownCloud’s `config.php`. - -See the -xref:configuration/server/config_sample_php_parameters.adoc#memory-caching-backend-configuration[Memory caching backend configuration] -for an overview of all possible config parameters, as the examples below only show basic configuration settings. After installing and enabling your chosen memory cache, verify that it is active by viewing the -xref:configuration/general_topics/general_troubleshooting.adoc#php-version-and-information[PHP configuration details]. - -=== Opcache Configuration - -Opcache should already be configured with PHP 7, see the {php-net-url}/manual/en/opcache.installation.php[opcache documentation] for details. - -=== APCu Configuration - -To use APCu, add this line to `config.php`: - -[source,php] ----- -'memcache.local' => '\OC\Memcache\APCu', ----- - -With that done, refresh your ownCloud admin page, and the cache warning should disappear. - -=== Redis Configuration - -Redis is very configurable; consult the {redis_doc_url}[Redis documentation] to learn more. - -Regardless of whether you have set up Redis to use TCP or a Unix socket, we recommend adding the following for best performance. This enables xref:configure-transactional-file-locking[External Transactional File Locking] based on Redis: - -[source,php] ----- -'filelocking.enabled' => true, -'memcache.locking' => '\OC\Memcache\Redis', ----- - -==== Redis Configuration Using TCP - -The following example `config.php` configuration connects to a Redis cache via TCP: - -// do not shrink the blanks on port because of proper alignment in rendering -[source,php,subs="attributes+"] ----- -'memcache.local' => '\OC\Memcache\Redis', -'redis' => [ - 'host' => 'localhost', // For a Unix domain socket, use '/var/run/redis/redis.sock' - 'port' => {std-port-redis}, // Set to 0 when using a Unix socket - 'timeout' => 0, // Optional, keep connection open forever - 'password' => '', // Optional, if not defined no password will be used. - 'dbindex' => 0, // Optional, if undefined SELECT will not run and will - // use Redis Server's default DB Index. -], ----- - -==== Redis Configuration Using Unix Sockets - -If Redis is running on the same server as ownCloud, it is recommended to configure it to use Unix sockets for increased performance. Follow these steps to do so: - -. Add the `www-data` user to the `redis` group: -+ -[source,bash] ----- -sudo usermod -G redis -a www-data ----- - -. Create your Redis folder that the Unix socket will be in: -+ -[source,bash] ----- -sudo mkdir -p /var/run/redis/ ----- - -. Set the permissions so the redis user and www-data group own it: -+ -[source,bash] ----- -sudo chown -R redis:www-data /var/run/redis ----- - -. Open an editor of your choice and change/add the following parameters to the Redis configuration file. Note that in the example `vi` is used as editor: -+ -[source,bash] ----- -sudo vi /etc/redis/redis.conf ----- -+ -[source,plaintext] ----- -# create a unix domain socket to listen on -unixsocket /var/run/redis/redis.sock - -# set permissions for the socket -unixsocketperm 770 ----- - -. Restart Redis to make the changes effective: -+ -[source,plaintext] ----- -sudo service redis-server restart ----- - -. Check if the Redis Unix socket was created: -+ -[source,plaintext] ----- -ls -lh /var/run/redis ----- -+ -The output should be like the following: -+ -[source,plaintext] ----- -srwxrwx--- 1 redis redis 0 May 12 12:26 redis.sock ----- - -Then, configure ownCloud to communicate with the Redis socket as in the following example. - -[source,php] ----- -# Change the host value, based on the socket's location in your distribution -'memcache.local' => '\OC\Memcache\Redis', -'redis' => [ - 'host' => '/var/run/redis/redis.sock', - 'port' => 0, // Set to 0 when using a Unix socket - 'password' => '', // Optional, if not defined no password will be used. - 'dbindex' => 0, // Optional, if undefined SELECT will not run and will - // use Redis Server's default DB Index. -], ----- - -==== Redis Performance Comparison TCP vs Socket - -To see a benchmark comparison, run: - -[source,bash] ----- -sudo redis-benchmark -q -n 100000 -sudo redis-benchmark -s /var/run/redis/redis-server.sock -q -n 100000 ----- - -In the following table, you will see an example gain of about +20% when using sockets compared -to TCP on localhost. The values can differ in your environment. Please do a local check. - -[width="80%",cols="20%,30%,30%,20%",options="header",] -|=== -| Test -| TCP (requests/s) -| Socket (requests/s) -| Gain (%) - -| PING_INLINE -| 15527.95 -| 23518.35 -| +34 - -| PING_BULK -| 16946.28 -| 23239.60 -| +27 - -| SET -| 18351.99 -| 22789.43 -| +19 - -| GET -| 18850.14 -| 22747.95 -| +17 - -| INCR -| 18663.68 -| 22914.76 -| +18 - -| LPUSH -| 19109.50 -| 24183.79 -| +21 - -| RPUSH -| 19076.69 -| 23196.47 -| +18 - -| LPOP -| 18460.40 -| 23485.21 -| +21 - -| RPOP -| 19058.51 -| 24752.47 -| +23 - -| SADD -| 18932.22 -| 22391.40 -| +15 - -| HSET -| 18491.12 -| 20785.70 -| +11 - -| SPOP -| 19069.41 -| 23282.89 -| +18 - -| LPUSH -| 19087.61 -| 23764.26 -| +20 - -| LRANGE_100 -| 15288.18 -| 17882.69 -| +15 - -| LRANGE_300 -| 9067.00 -| 10004.00 -| +10 - -| LRANGE_500 -| 6878.53 -| 7496.25 -| +8 - -| LRANGE_600 -| 5379.24 -| 6102.77 -| +12 - -| MSET (10 keys) -| 19297.57 -| 18178.51 -| -6 -|=== - -=== Memcached Configuration -This example uses APCu for the local cache, Memcached as the distributed memory cache, and lists all the servers in the shared cache pool with their port numbers: - -[source,php,subs="attributes+"] ----- -'memcache.local' => '\OC\Memcache\APCu', -'memcache.distributed' => '\OC\Memcache\Memcached', -'memcached_servers' => [ - ['localhost', {std-port-memcache}], - ['server1.example.com', {std-port-memcache}], - ['server2.example.com', {std-port-memcache}], - ], ----- - -== Configure Transactional File Locking - -xref:configuration/files/files_locking_transactional.adoc[Transactional File Locking] -prevents simultaneous file saving. It is enabled by default and uses the database to store the locking data. This places a significant load on your database. It is recommended to use a cache backend instead. You have to configure it in `config.php` as in the following example, which uses Redis TCP as the cache backend: - -[source,php,subs="attributes+"] ----- -'filelocking.enabled' => true, -'memcache.locking' => '\OC\Memcache\Redis', -'redis' => [ - 'host' => 'localhost', - 'port' => {std-port-redis}, - 'timeout' => 0, - 'password' => '', // Optional, if not defined no password will be used. - ], ----- - -CAUTION: For enhanced security, it is recommended to configure Redis to require a password. See {redis_security_url} for more information. - - -== Configuration Recommendations Based on Type of Deployment - -The examples give you an overview, adapt them to your environment and your needs. - -=== Private Home Server With Low Access Rates - -Use APCu for local caching, file locking is not mandatory. - -[source,php] ----- -'memcache.local' => '\OC\Memcache\APCu', ----- - -=== Small Server - -Use APCu for local caching and Redis for file locking. - -[source,php,subs="attributes+"] ----- -'filelocking.enabled' => true, -'memcache.local' => '\OC\Memcache\APCu', -'memcache.locking' => '\OC\Memcache\Redis', -'redis' => [ - 'host' => 'localhost', - 'port' => {std-port-redis}, -], ----- - -=== Small Organization, Single-server Setup - -Use Redis Socket for local caching and for file locking. - -[source,php,subs="attributes+"] ----- -'filelocking.enabled' => true, -'memcache.local' => '\OC\Memcache\Redis', -'memcache.locking' => '\OC\Memcache\Redis', -'redis' => [ - 'host' => '/var/run/redis/redis.sock', - 'port' => 0, -], ----- - -=== Large Organization, Clustered Setup - -Use Redis for everything except a local memory cache. Use the server’s IP address or hostname so that it is accessible to other hosts: - -[source,php,subs="attributes+"] ----- -'filelocking.enabled' => true, -'memcache.distributed' => '\OC\Memcache\Redis', -'memcache.locking' => '\OC\Memcache\Redis', -'memcache.local' => '\OC\Memcache\APCu', -'redis' => [ - 'host' => 'server1', // hostname example - 'host' => '12.34.56.78', // IP address example - 'port' => {std-port-redis}, -], ----- - -See xref:configuration/server/config_sample_php_parameters.adoc#define-redis-cluster-connection-details[Define Redis Cluster connection details] when using a Redis clustered setup. - -== Caching Exceptions - -If ownCloud is configured to use either Memcached or Redis as a memory cache, you may encounter issues with functionality. When these occur, it is usually a result of PHP being incorrectly configured or the relevant PHP extension not being available. - -In the table below, you can see all of the known reasons for reduced or broken functionality related to caching. - -[width="100%",cols="41%,59%",options="header",] -|=== -| Setup/Configuration | Result -| If file locking is enabled, but the locking cache class is missing, -then an exception will appear in the web UI | The application will not be usable -| If file locking is enabled and the locking cache is configured, but the -PHP module missing. | There will be a white page/exception in web UI. It -will be a full page issue, and the application will not be usable -| All enabled, but the Redis server is not running | The application will -be usable. But any file operation will return a "500 Redis went away" exception -| If Memcache is configured for `local` and `distributed`, but the -class is missing | There will be a white page and an exception written to -the logs, This is because autoloading needs the missing class. So there is no way to show a page -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/config_apps_sample_php_parameters.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/config_apps_sample_php_parameters.adoc deleted file mode 100644 index dc12276..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/config_apps_sample_php_parameters.adoc +++ /dev/null @@ -1,978 +0,0 @@ -= Apps Config.php Parameters -:toc: right -:toclevels: 1 - -== Introduction - -This document describes parameters for apps maintained by ownCloud that are not part of the core system. -All keys are only valid if the corresponding app is installed and enabled. -You must copy the keys needed to the active `config.php` file. - -== Multiple configuration files - -ownCloud supports loading configuration parameters from multiple files. -You can add arbitrary files ending with .config.php in the config/ directory. - -=== Example: - -You could place your email server configuration in `email.config.php`. -This allows you to easily create and manage custom configurations or to divide a large complex configuration file into a set of smaller files. -These custom files are not overwritten by ownCloud, and the values in these files take precedence over `config.php`. - -ownCloud may write configurations into `config.php`. -These configurations may conflict with identical keys already set in additional config files. Be careful when using this capability! - -// header end do not delete or edit this line - -== App: Activity - -Possible key: `activity_expire_days` DAYS - -=== Define the retention for activities of the activity app - -==== Code Sample - -[source,php] -.... -'activity_expire_days' => 365, -.... - -== App: Admin Audit - -Possible key: `log.conditions` ARRAY - -Possible key: `admin_audit.groups` ARRAY - -=== Configure the path to the log file - -==== Code Sample - -[source,php] -.... -'log.conditions' => [ - [ - 'apps' => ['admin_audit'], - // Adjust the path below, to match your setup - 'logfile' => '/var/www/owncloud/data/admin_audit.log' - ], -], -.... - -=== Filter the groups that messages are logged for - -==== Code Sample - -[source,php] -.... -'admin_audit.groups' => ['group1', 'group2'], -.... - -== App: Files Antivirus - -Possible key: `files_antivirus.av_path` STRING - -Possible key: `files_antivirus.av_cmd_options` STRING - -=== Default path to the _clamscan_ command line anti-virus scanner. - -This setting only applies when the operating mode of the `files_antivirus` app is set to executable mode. -See the documentation for more details. - -==== Code Sample - -[source,php] -.... -'files_antivirus.av_path' => '/usr/bin/clamscan', -.... - -=== Command line options for the _clamscan_ command line anti-virus scanner. - -This setting only applies when the operating mode of the `files_antivirus` app is set to executable mode. -See the documentation for more details. - -==== Code Sample - -[source,php] -.... -'files_antivirus.av_cmd_options' => '', -.... - -== App: Files PDF Viewer - -Possible key: `files_pdfviewer.enableScripting` STRING - -PDF files may contain JavaScript which for example can be necessary to process editable fields. -Under normal circumstances and for security reasons, scripts are not allowed to be processed. To allow -processing these scripts, the following config key can be set. Note that enabling scripting can be -a major security issue and should be considered as possible thread vector. - -=== Enable Scripting in PDF files. - -To enable scripting in PDF files, set the value to 'yes'. Any other value will be treated -as disable scripting. - -==== Code Sample - -[source,php] -.... -'files_pdfviewer.enableScripting' => '', -.... - -== App: Files Versions - -Possible key: `versions_retention_obligation` STRING - -Use following values to configure the retention behaviour. Replace `D` with the number of days. - -auto:: -Default value if nothing is set -D, auto:: -Keep versions at least for D days, apply expiration rules to all versions that are older than D days -auto, D:: -Delete all versions that are older than D days automatically, delete other versions according to expiration rules -D1, D2:: -Keep versions for at least D1 days and delete when they exceed D2 days -disabled:: -Disable Versions; no files will be deleted. - -=== Pattern to define the expiration date for each backup version created. - -==== Code Sample - -[source,php] -.... -'versions_retention_obligation' => 'auto', -.... - -== App: Firstrunwizard - -Possible key: `customclient_desktop` URL - -Possible key: `customclient_android` URL - -Possible key: `customclient_ios` URL - -=== Define the download links for ownCloud clients -Configuring the download links for ownCloud clients, -as seen in the first-run wizard and on Personal pages - -==== Code Sample - -[source,php] -.... -'customclient_desktop' => - 'https://owncloud.com/desktop-app/', -'customclient_android' => - 'https://play.google.com/store/apps/details?id=com.owncloud.android', -'customclient_ios' => - 'https://apps.apple.com/app/id1359583808', -.... - -== App: Kerberos - -Possible key: `kerberos.keytab` STRING - -Possible key: `kerberos.suppress.timeout` INTEGER - -Possible key: `kerberos.domain` STRING - -Possible key: `kerberos.login.buttonName` STRING - -Possible key: `kerberos.login.autoRedirect` BOOL - -=== Kerberos keytab File Location -Path to the 'keytab' file to use, defaults to '/etc/krb5.keytab'. - -==== Code Sample - -[source,php] -.... -'kerberos.keytab' => '/etc/apache2/www-data.keytab', -.... - -=== Kerberos SPNEGO Timeout -Timeout before re-enabling SPNEGO based authentication after logout, defaults to 60 seconds. - -==== Code Sample - -[source,php] -.... -'kerberos.suppress.timeout' => 60, -.... - -=== Kerberos Domain -The domain name - remove from principals to match the pure user name. - -Example: 'alice@corp.dir' will look for the user 'alice' in LDAP if 'kerberos.domain' is set to 'corp.dir'. - -==== Code Sample - -[source,php] -.... -'kerberos.domain' => '', -.... - -=== Login Name Button -The name of the login button shown on the login page. - -==== Code Sample - -[source,php] -.... -'kerberos.login.buttonName' => 'Windows Domain Login', -.... - -=== Immediate Login -If set to true, the login page will immediately try to log in via Kerberos. - -==== Code Sample - -[source,php] -.... -'kerberos.login.autoRedirect' => false, -.... - -== App: LDAP - -Possible key: `ldapIgnoreNamingRules` `doSet` or `false` - -Possible key: `user_ldap.enable_medial_search` BOOL - -=== Define parameters for the LDAP app - -==== Code Sample - -[source,php] -.... -'ldapIgnoreNamingRules' => false, -'user_ldap.enable_medial_search' => false, -.... - -== App: Market - -Possible key: `appstoreurl` URL - -=== Define the download URL for apps - -==== Code Sample - -[source,php] -.... -'appstoreurl' => 'https://marketplace.owncloud.com', -.... - -== App: Metrics - -Note: This app is for Enterprise customers only. - -Possible key: `metrics_shared_secret` STRING - -=== Secret to use the Metrics dashboard -You have to set a Metrics secret to use the dashboard. You cannot use the dashboard -without defining a secret. You can use any secret you like. In case you want to generate -a random secret, use the following example command: -`echo $(tr -dc 'a-z0-9' < /dev/urandom | head -c 20)` -It is also possible to set this secret via an occ command which writes key and data to the -config.php file. Please see the occ command documentation for more information. - -==== Code Sample - -[source,php] -.... -'metrics_shared_secret' => 'replace-with-your-own-random-string', -.... - -== App: Microsoft Office Online (WOPI) - -Note: This app is for Enterprise customers only. - -Possible key: `wopi.token.key` STRING - -Possible key: `wopi.proxy.key` STRING - -Possible key: `wopi.office-online.server` URL - -Possible key: `wopi_group` STRING - -Possible key: `wopi.proxy.url` URL - -Possible key: `wopi.business-flow.enabled` STRING - -=== Random Keys Created by the ownCloud Admin -Both, `wopi.token.key` and `wopi.proxy.key` are random keys created by the ownCloud admin. - -The keys are used by ownCloud to create encrypted JWT tokens for the communication with your -Microsoft Office Online instance. The keys must be distinct. -Note that `wopi.token.key` must be at least 32 bytes long. - -You can use the following example command to generate a random key: -`echo $(tr -dc 'a-z0-9' < /dev/urandom | head -c 32)` - -==== Code Sample - -[source,php] -.... -'wopi.token.key' => 'replace-with-your-own-very-long-random-string', -.... - -=== Microsoft Office Online instance URL -This is the URL of the Microsoft Office Online instance ownCloud communicates with. Keep -in mind that you need to grant communication access at your Microsoft Office -Online instance with this ownCloud instance. For further information, read the -ownCloud documentation. - -==== Code Sample - -[source,php] -.... -'wopi.office-online.server' => 'https://your.office.online.server.tld', -.... - -=== Define the group name for users allowed to use Microsoft Office Online -Restrict access to Microsoft Office Online to a defined group. Please note, only one group can be defined. Default = empty = no restriction. - -==== Code Sample - -[source,php] -.... -'wopi_group' => '', -.... - -=== Define the Proxy URL -This global option defines the proxy URL if you are a Microsoft Business user. - -Note that you will get a working URL from ownCloud Support after you provide a written -declaration that your company has an eligible Microsoft Business contract. - -==== Code Sample - -[source,php] -.... -'wopi.proxy.url' => 'https://o365.example.com', -.... - -=== Define if Business Flow Is Enabled -This global option defines if Office users are business users. - -In that case, Office Online will check if the user logged in has an Office 365 business account. -If not, the user must sign in and Office Online will check if the subscription is valid. -Use yes to enable it and no to disable it or remove the key completely. -To use this option, you need at least ownCloud’s Microsoft Office Online app version 1.6.0. - -==== Code Sample - -[source,php] -.... -'wopi.business-flow.enabled' => 'no', -.... - -== App: Microsoft Teams Bridge - -Possible key: `msteamsbridge` ARRAY - -Sub key: `loginButtonName` STRING - -=== Login Button Label -This key is necessary for security reasons. Users will be asked to click a login -button each time when accessing the ownCloud app after a fresh start of their -Microsoft Teams app or after idle time. This behavior is by design. The button -name can be freely set based on your requirements. - -==== Code Sample - -[source,php] -.... -'msteamsbridge' => [ - "loginButtonName" => "Login to ownCloud with Azure AD", -], -.... - -== App: OpenID Connect (OIDC) - -Possible key: `openid-connect` ARRAY - - -**Configure OpenID Connect - all possible sub-keys** - -_You have to use the main key `openid-connect` together with sub keys listed below, see code samples._ - -allowed-user-backends:: -Limit the users which are allowed to login to a specific user backend - e.g. LDAP -(`'allowed-user-backends' ⇒ ['LDAP']`) - -auth-params:: -Additional parameters which are sent to the IdP during the auth requests - -autoRedirectOnLoginPage:: -If `true`, the ownCloud login page will redirect directly to the Identity Provider -login without requiring the user to click a button. The default is `false`. - -auto-provision:: -If `auto-provision` is setup, an ownCloud user will be created if not exists, after successful -login using openid connect. The config parameters `mode` and `search-attribute` will be used -to create a unique user so that the lookup mechanism can find the user again. This is where -an LDAP setup is usually required. The profile picture will only be transferred upon account -creation, but will not be updated afterwards if it changes in the connected IdP. -If `auto-provision` is not setup or required, it is expected that the user exists and you -MUST declare this with `['enabled' => false]` like shown in the Easy Setup example. -`auto-provision` holds several sub keys, see the example setup with the explanations below. - -auto-update:: -When using the provisioning mode `auto-update`, user account info will update with the current -information provided by the OpenID Connect provider upon each user log in. - -insecure:: -Boolean value (`true`/`false`), no SSL verification will take place when talking to the -IdP - **DO NOT use in production!** - -jwt-self-signed-jwk-header-supported:: -If set to true, JWK (JSON Web Token) will be taken from the JWT header instead of the IdP's jwks_uri. -Should only be enabled in exceptional cases as this could lead to vulnerabilities -https://portswigger.net/kb/issues/00200902_jwt-self-signed-jwk-header-supported - -loginButtonName:: -The name as displayed on the login screen which is used to redirect to the IdP. -By default, the OpenID Connect App will add a button on the login page that will -redirect the user to the Identity Provider and allow authentication via OIDC. -This parameter allows the button text to be modified. - -mode:: -This is the attribute in the owncloud accounts table to search for users. -The default value is `email`. The alternative value is: `userid`. - -post_logout_redirect_uri:: -A given URL where the IdP should redirect to after logout. - -provider-params:: -Additional config array depending on the IdP to be entered here - usually only necessary if -the IdP does not support service discovery. - -provider-url, client-id and client-secret:: -Variables are to be taken from the OpenID Connect Provider's setup. -For the `provider-url`, the URL where the IdP is living. -In some cases (KeyCloak, Azure AD) this holds more than just a domain but also a path. - -redirect-url:: -The full URL under which the ownCloud OpenId Connect redirect URL is reachable - only -needed in special setups. - -scopes:: -Enter the list of required scopes depending on the IdP setup. - -search-attribute:: -The attribute which is taken from the access token JWT or user info endpoint to identify -the user. This is the claim from the OpenID Connect user information which shall be -used for searching in the accounts table. The default value is `email`. For -more information about the claim, see -https://openid.net/specs/openid-connect-core-1_0.html#Claims. - -token-introspection-endpoint-client-id:: -Client ID to be used with the token introspection endpoint. - -token-introspection-endpoint-client-secret:: -Client secret to be used with the token introspection endpoint. - -use-access-token-payload-for-user-info:: -If set to `true` any user information will be read from the access token. -If set to `false` the userinfo endpoint is used (starting app version 1.1.0). - -=== Easy setup - -==== Code Sample - -[source,php] -.... -'openid-connect' => [ - // it is expected that the user already exists in ownCloud - 'auto-provision' => ['enabled' => false], - 'provider-url' => 'https://idp.example.net', - 'client-id' => 'fc9b5c78-ec73-47bf-befc-59d4fe780f6f', - 'client-secret' => 'e3e5b04a-3c3c-4f4d-b16c-2a6e9fdd3cd1', - 'loginButtonName' => 'OpenId Connect' -], -.... - -=== Setup auto provisioning mode - -==== Code Sample - -[source,php] -.... -'openid-connect' => [ - // explicit enable the auto provisioning mode, - // if not exists, the user will be created in ownCloud - 'auto-provision' => [ - 'enabled' => true, - // documentation about standard claims: - // https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims - // only relevant in userid mode, defines the claim which holds the email of the user - 'email-claim' => 'email', - // defines the claim which holds the display name of the user - 'display-name-claim' => 'given_name', - // defines the claim which holds the picture of the user - must be a URL - 'picture-claim' => 'picture', - // defines a list of groups to which the newly created user will be added automatically - 'groups' => ['admin', 'guests', 'employees'], - // sets a claim which is defined at the IDP. - // the IDP will return a single value or an array like: - // "allowed_applications": ["erp", "owncloud"], - 'provisioning-claim' => 'allowed_applications', - // defines the matching case for the provisioning. the attribute can only be a - // single value in case no match is found against the IDP response, - // no provisioning will be made, "User not found" will be returned - 'provisioning-attribute' => 'owncloud', - // auto-update user account info with current information provided by the - // OpenID Connect provider account attributes, that will be updated, - // can be specified in `attributes` config option - 'update' => ['enabled' => true], - // enable the user info auto-update mode - ], - // `mode` and `search-attribute` will be used to create a unique user in ownCloud - 'mode' => 'email', - 'search-attribute' => 'email', -], -.... - -=== Manual setup - -==== Code Sample - -[source,php] -.... -'openid-connect' => [ - // it is expected that the user already exists in ownCloud - 'auto-provision' => ['enabled' => false], - 'autoRedirectOnLoginPage' => false, - 'client-id' => 'fc9b5c78-ec73-47bf-befc-59d4fe780f6f', - 'client-secret' => 'e3e5b04a-3c3c-4f4d-b16c-2a6e9fdd3cd1', - 'loginButtonName' => 'OpenId Connect', - 'mode' => 'userid', - 'search-attribute' => 'sub', - // only required if the OpenID Connect Provider does not support service discovery - // replace the dots with your values - 'provider-params' => [ - 'authorization_endpoint' => '...', - 'end_session_endpoint' => '...', - 'jwks_uri' => '...', - 'registration_endpoint' => '...', - 'token_endpoint' => '', - 'token_endpoint_auth_methods_supported' => '...', - 'userinfo_endpoint' => '...' - ], - 'provider-url' => '...', -], -.... - -=== Test setup - -==== Code Sample - -[source,php] -.... -'openid-connect' => [ - // it is expected that the user already exists in ownCloud - 'auto-provision' => ['enabled' => false], - 'provider-url' => 'http://localhost:3000', - 'client-id' => 'ownCloud', - 'client-secret' => 'ownCloud', - 'loginButtonName' => 'node-oidc-provider', - 'mode' => 'userid', - 'search-attribute' => 'sub', - // do not verify tls host or peer - 'insecure' => true -], -.... - -== App: Richdocuments - -Possible key: `collabora_group` STRING - -=== Define the group name for users allowed to use Collabora -Please note, only one group can be defined. Default = empty = no restriction. - -==== Code Sample - -[source,php] -.... -'collabora_group' => '', -.... - -== App: S3 Primary Object Storage - -Possible key: `objectstore` ARRAY - -=== Configure the access parameters for a particular S3 provider. - -The detailed configuration of that array depends on the S3 provider. -This example can therefore only show the general construct. -See the "S3 Compatible Object Storage as Primary Storage Location" documentation for more details. - -==== Code Sample - -[source,php] -.... -'objectstore' => [ - 'class' => 'OCA\Files_Primary_S3\S3Storage', - 'arguments' => [ - // ... - ], -], -.... - -== App: Windows Network Drive (WND) - -Note: This app is for Enterprise customers only. - -Possible key: `wnd.activity.registerExtension` BOOL - -Possible key: `wnd.activity.sendToSharees` BOOL - -Possible key: `wnd.connector.opts.timeout` INTEGER - -Possible key: `wnd.errorCodes.passwordReset` ARRAY - -Possible key: `wnd.fileInfo.parseAttrs.mode` STRING - -Possible key: `wnd.groupmembership.checkUserFirst` BOOL - -Possible key: `wnd.in_memory_notifier.enable` BOOL - -Possible key: `wnd.kerberos.servers` ARRAY - -Possible key: `wnd.listen_events.smb_acl` BOOL - -Possible key: `wnd.listen.reconnectAfterTime` INTEGER - -Possible key: `wnd.logging.enable` BOOL - -Possible key: `wnd.permissionmanager.cache.size` INTEGER - -Possible key: `wnd2.cachewrapper.normalize` BOOL - -Possible key: `wnd2.cachewrapper.ttl` INTEGER - -*Note* With WND 2.1.0, key `wnd.storage.testForHiddenMount` is obsolete and has been removed completely. - -=== Enable to Push WND Events to the Activity App -Register WND as extension into the Activity app in order to send information about what -the `wnd:process-queue` command is doing. The activity sent will be based on what -the `wnd:process-queue` detects, and the activity will be sent to each affected user. There -won't be any activity being sent outside of the `wnd:process-queue` command. - -`wnd:listen` + `wnd:process-queue` + `activity app` are required for this to work properly. See `wnd.activity.sendToSharees` -below for information on how to send activities for shared resources. Please consider -that this can have a performance impact when changes are sent to many users. - -==== Code Sample - -[source,php] -.... -'wnd.activity.registerExtension' => false, -.... - -=== Enable to Send WND Activity Notifications to Sharees -The `wnd:process-queue` command will also send activity notifications to the sharees -if a WND file or folder is shared (or accessible via a share). It's REQUIRED that the -`wnd.activity.registerExtension` flag is set to true (see above), otherwise this flag will -be ignored. This flag depends on the `wnd.activity.registerExtension` and has the same restrictions. - -==== Code Sample - -[source,php] -.... -'wnd.activity.sendToSharees' => false, -.... - -=== The Timeout (in ms) for All the Operations Against the Backend -The same timeout will be applied for all the connections. - -Increase it if requests to the server sometimes time out. This can happen when SMB3 -encryption is selected and smbclient is overwhelming the server with requests. - -==== Code Sample - -[source,php] -.... -'wnd.connector.opts.timeout' => 20000, // 20 seconds -.... - -=== Reset the Password When Receiving Any of the Following Error Codes. - -By default, we will reset the password with error code 13, which means -access denied. Depending on circumstances, you might want to add the -error code 1, which means an operation not permitted (although there could -be cases where this "operation not permitted" might not be caused by a wrong -password). - -Some examples: - -- `'wnd.errorCodes.passwordReset' => [13],` -- `'wnd.errorCodes.passwordReset' => [13, 1],` - -The password reset feature can be disabled by providing an empty list - -- `'wnd.errorCodes.passwordReset' => [],` - -Note that disabling the password reset feature can lead to an account lockout -if such feature is enabled in the target windows / samba machine. - -==== Code Sample - -[source,php] -.... -'wnd.errorCodes.passwordReset' => [13], -.... - -=== The Way File Attributes for Folders and Files will be Handled -There are 3 possible values: `none`, `stat` and `getxattr`: - -- `stat`. This is the default if the option is missing or has an invalid value. - This means that the file attributes will be evaluated only for files, NOT for folders. - Folders will be shown even if the "hidden" file attribute is set. - -- `none`. This means that the file attributes won't be evaluated in any case. Both - hidden files and folders will be shown, and you can write on read-only files - (the action is available in ownCloud, but it will fail in the SMB server). - -- `getxattr`. This means that file attributes will always be evaluated. However, due to - problems in recent libsmbclient versions (4.11+, it might be earlier) it will cause - malfunctions in ownCloud; permissions are wrongly evaluated. So far, this mode works - with libsmbclient 4.7 but not with 4.11+ (not tested with any version in between). - -Note that the ACLs (if active) will be evaluated and applied on top of this mechanism. - -==== Code Sample - -[source,php] -.... -'wnd.fileInfo.parseAttrs.mode' => 'stat', -.... - -=== Make the Group Membership Component Assume that the ACL Contains a User -The WND app doesn't know about the users or groups associated with ACLs. This -means that an ACL containing "admin" might refer to a user called "admin" or a -group called "admin". By default, the group membership component considers the ACLs to -target groups, and as such, it will try to get the information for such a group. This -works fine if the majority of the ACLs target groups. If the majority of the ACLs -contain users, this might be problematic. The cost of getting information on a -group is usually higher than getting information on a user. This option -makes the group membership component assume the ACL contains a user and checks whether -there is a user in ownCloud with such a name first. If the name doesn't refer to a user, -it will get the group information. Note that this will have performance implications -if the group membership component can't discard users in a large number of cases. It is -recommended to enable this option only if there are a high number of ACLs targeting users. - -==== Code Sample - -[source,php] -.... -'wnd.groupmembership.checkUserFirst' => false, -.... - -=== Enable or Disable the WND In-Memory Notifier for Password Changes -Having this feature enabled implies that whenever a WND process detects a -wrong password in the storage - maybe the password has changed in the -backend - all WND storages that are in-memory will be notified in order to reset -their passwords if applicable and not to requery again. - -The intention is to prevent a potential password lockout for the user in the backend. -As with PHP lower than 7.4, this feature can take a lot of memory resources. -This is because WND keeps the storage access and its caches in-memory. -With PHP 7.4 or above, the memory usage has been reduced significantly. -Alternatively, you can disable this feature completely. - -==== Code Sample - -[source,php] -.... -'wnd.in_memory_notifier.enable' => true, -.... - -=== A Map of Servers With the Required Kerberos Data - -A map of servers with the required data to get the Kerberos credentials -in order to access them. - -Each key of the map must be unique and identifies a server. This ID will -be used in the web UI to configure the mount points to use the Kerberos -authentication. You can use any ID (choose one meaningful and easy to remember). - -The data contained in each key is as follows: - -- `ockeytab` (required): The location of the keytab file that ownCloud -will use to access to the mounts using that server ID. The keytab must -be for a service account with special privileges, in particular, it must -be able to impersonate the users. It is highly recommended that the password -for this service account doesn't expire, otherwise you will have to replace -the file manually before the expiration. See the Kerberos documentation for details. - -- `ocservice` (required): The name of the service of the account. This matches -the SPN of the Windows / Samba account. It usually is in the form "HTTP/", -but it might be different. See the Kerberos documentation for details. - -- `usermapping` (optional): The ownCloud-to-windows user mapping to be used. See below -for available options. If no user mapping is provided, the `Noop` mapping will -be used. The mapping data contains the type of mapping and the parameters, if any. - -- `ccachettl` (optional): The time (in seconds) that the credential cache -will be considered as valid from the ownCloud's side. This TTL MUST be -lower than the actual TTL. Once the TTL is over, new credentials will be -requested automatically. The default TTL is 9 hours, which is less than -the 10 hours set by Windows by default. - -Available mapping types: - -- `Noop`: Do not perform any mapping. The ownCloud user ID will be -returned without changes, so it's expected that the ownCloud user ID -matches the Windows / Samba user ID. - -- `RemoveDomain`: Remove the domain (if any) from the ownCloud user ID. -This means that "user001@my.dom.com" will map to "user001". Note that -it's assumed that all users belong to the same domain, otherwise -"user001@my.dom.com" will be mapped to the same windows user as -"user001@not.mine.eu". - -- `EALdapAttr`: Use ownCloud's user extended attributes to map the ownCloud -user to the target LDAP attribute. The mapping has 2 parameters: -* `attr`: in order to select the LDAP attribute you want to use. Note -that it's required that the user_ldap app exposes the chosen attribute which -requires user_ldap 0.19.0+. -* `nomap` (optional): a list of uids not registered in ownCloud that -won't be mapped and be returned without any change. -- The following scenarios will cause errors: -** If ownCloud can't map the user and he isn't in the `nomap` list. -** If the user is registered in ownCloud and is in the `nomap` list. -** If it isn't a LDAP user. - -==== Code Sample - -[source,php] -.... -'wnd.kerberos.servers' => [ - 'server_ID1' => [ - 'ockeytab' => '/.keytab', - 'ocservice' => 'HTTP/', - 'usermapping' => ['type' => 'Noop'], - 'ccachettl' => 60 * 60 * 9, - ], - 'server_ID2' => [ - 'ockeytab' => '/.keytab', - 'ocservice' => 'HTTP/', - 'usermapping' => ['type' => 'RemoveDomain'], - 'ccachettl' => 60 * 60 * 9, - ], - 'server_ID3' => [ - 'ockeytab' => '/.keytab', - 'ocservice' => 'HTTP/', - 'usermapping' => [ - 'type' => 'EALdapAttr', - 'params' => [ - 'attr' => 'userPrincipalName', - 'nomap' => ['ocService@example.prv', 'secondaryAccount@company.com'], - ] - ], - 'cachettl' => 3600, - ], -], -.... - -=== Listen to the Events Triggered by the smb_acl App -The current use is to update the WND storages (with "login credentials, -saved in DB" authentication) when an ACL changes via the smb_acl app - -==== Code Sample - -[source,php] -.... -'wnd.listen_events.smb_acl' => false, -.... - -=== Mandatory Listener Reconnect to the Database -The listener will reconnect to the DB after given seconds. This will -prevent the listener to crash if the connection to the DB is closed after -being idle for a long time. - -==== Code Sample - -[source,php] -.... -'wnd.listen.reconnectAfterTime' => 28800, -.... - -=== Enable Additional Debug Logging for the WND App - -==== Code Sample - -[source,php] -.... -'wnd.logging.enable' => false, -.... - -=== Maximum Number of Items for the Cache Used by the WND Permission Managers -A higher number implies that more items are allowed, increasing the memory usage. - -Real memory usage per item varies because it depends on the path being cached. -Note that this is an in-memory cache used per request. -Multiple mounts using the same permission manager will share the same -cache, limiting the maximum memory that will be used. - -==== Code Sample - -[source,php] -.... -'wnd.permissionmanager.cache.size' => 512, -.... - -=== Manage UTF-8 Glyph Normalization on macOS -A glyph is a character like `ñ` as used in the spanish word `señorita` which can be composed by two different byte sequences. - -With https://www.utf8-chartable.de/unicode-utf8-table.pl?number=1024&unicodeinhtml=hex[UTF-8], glyphs can have two valid representations of these sequences in filesystems. -https://unicode.org/reports/tr15/#Norm_Forms[Normalization] makes it possible to determine whether any two Unicode strings are equivalent. -The most used normalization forms are NFC and NFD. By default, ownCloud usually normalizes names to NFC. -With macOS and HFS+ as filesystem, NFD is required. -When using WND collaborative mount points connecting to macOS with HFS+, or any other filesystem using NFD, probing both forms can be enforced by setting the config variable `wnd2.cachewrapper.normalize` to true. -This is necessary because if a file accessed via collaborative WND contains NFD characters, WND will not find the file and the WND app will assume user doesn't have access to it. -As a result, the file will not be shown. - -As a mandatory prerequisite, the mount point setting `Compatibility with Mac NFD encoding` must be checked. - -==== Code Sample - -[source,php] -.... -'wnd2.cachewrapper.normalize' => false, -.... - -=== TTL for the WND2 Caching Wrapper -Time to Live (TTL) in seconds to be used to cache information for the WND2 (collaborative) -cache wrapper implementation. The value will be used by all WND2 storages. Although the -cache isn't exactly per user but per storage id, consider the cache to be per user, because -it will be like that for common use cases. Data will remain in the cache and won't -be removed by ownCloud. Aim for a low TTL value in order to not fill the memcache -completely. In order to properly disable caching, use -1 or any negative value. 0 (zero) -isn't considered a valid TTL value and will also disable caching. - -==== Code Sample - -[source,php] -.... -'wnd2.cachewrapper.ttl' => 1800, // 30 minutes -.... - -== App: Workflow / Tagging - -Note: This app is for Enterprise customers only. - -Possible key: `workflow.retention_engine` STRING - -=== Provide Advanced Management of File Tagging -Enables admins to specify rules and conditions (file size, file mimetype, group membership and more) -to automatically assign tags to uploaded files. Values: `tagbased` (default) or `userbased`. - -==== Code Sample - -[source,php] -.... -'workflow.retention_engine' => 'tagbased', -.... - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/config_sample_php_parameters.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/config_sample_php_parameters.adoc deleted file mode 100644 index 1abdb1d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/config_sample_php_parameters.adoc +++ /dev/null @@ -1,2563 +0,0 @@ -= Config.php Parameters -:toc: right - -== Introduction - -ownCloud uses the `config/config.php` file to control server operations. -`config/config.sample.php` lists all the configurable parameters within -ownCloud, along with example or default values. This document provides a -more detailed reference. Most options are configurable on your Admin -page, so it is usually not necessary to edit `config/config.php`. - -NOTE: The installer creates a configuration containing the essential parameters. + -Only manually add configuration parameters to `config/config.php` if you need to use a special -value for a parameter. *Do not copy everything from* `config/config.sample.php` *. -Only enter the parameters you wish to modify!* - -ownCloud supports loading configuration parameters from multiple files. -You can add arbitrary files ending with .config.php in the config/ -directory, for example you could place your email server configuration -in email.config.php. This allows you to easily create and manage custom -configurations, or to divide a large complex configuration file into a -set of smaller files. These custom files are not overwritten by -ownCloud, and the values in these files take precedence over config.php. - -// header end do not delete or edit this line - -== Default Parameters - -These parameters are configured by the ownCloud installer and are required -for your ownCloud server to operate. - -=== Unique identifier for your ownCloud installation -This unique identifier is created automatically by the installer. - -This example is for documentation only, and you should never use it because it will not work. -A valid `instanceid` is created when you install ownCloud. Needs to start with a letter. - -'instanceid' => 'd3c944a9a', - -==== Code Sample - -[source,php] -.... -'instanceid' => '', -.... - -=== Auto-generated salt used to hash all passwords -The salt used to hash all passwords and is auto-generated by the ownCloud installer. - -(There are also per-user salts.) If you lose this salt, you lose all your -passwords. This example is for documentation only, and you should never use it. - -==== Code Sample - -[source,php] -.... -'passwordsalt' => '', -.... - -=== Define list of trusted domains that users can log into -Specifying trusted domains prevents host header poisoning. - -This parameter reperesents a white list of approved IP addresses and -hostnames that this server is known by / is used to access it. -Wildcards, slash notation and ports are not supported. -Do not remove this, as it performs necessary security checks. -Please consider that for backend processes like background jobs or occ commands, -the URL parameter in key `overwrite.cli.url` is used. For more details, please see that key. - -NOTE: When defined via the `OWNCLOUD_TRUSTED_DOMAINS` property in docker, the values should be -a comma delimited list without white space. like `OWNCLOUD_TRUSTED_DOMAINS=localhost,10.10.1.1`. -Wildcards, slash notation and ports are not supported. - -==== Code Sample - -[source,php] -.... -'trusted_domains' => [ - 'demo.example.org', - 'otherdomain.example.org', - ], -.... - -=== Define global list of CORS domains -All users can use tools running CORS (Cross-Origin Resource Sharing) requests -from the listed domains. - -==== Code Sample - -[source,php] -.... -'cors.allowed-domains' => [ - 'https://foo.example.org', - ], -.... - -=== Define the directory where user files are stored -This defaults to `data/` in the ownCloud directory. - -The SQLite database is also stored here, when you use SQLite. -(SQLite is not available in ownCloud Enterprise Edition) - -==== Code Sample - -[source,php] -.... -'datadirectory' => '/var/www/owncloud/data', -.... - -=== Define the directory where the crash logs will be stored -By default, this will be the same as the one configured as "datadirectory". - -The directory MUST EXIST and be WRITABLE by the web server. -Note that crashes are extremely rare (although they can come in burst due to -multiple requests), so the default location is usually fine. -Also note that the log can contain sensitive information, but it should be useful -to pinpoint where is the problem. - -==== Code Sample - -[source,php] -.... -'crashdirectory' => '/var/www/owncloud/data', -.... - -=== Current version number of your ownCloud installation -This is set up during installation and update, so you shouldn't need to change it. - -==== Code Sample - -[source,php] -.... -'version' => '', -.... - -=== Show or hide the ownCloud version information in `status.php` -This hardens an ownCloud instance by hiding the version information in `status.php`. - -This can be a legitimate step. Please consult the documentation before enabling this. - -==== Code Sample - -[source,php] -.... -'version.hide' => false, -.... - -=== Show or hide the server hostname in `status.php` -Optional config option, defaults to hidden. - -==== Code Sample - -[source,php] -.... -'show_server_hostname' => false, -.... - -=== Show the short hostname in `status.php` -Optional config option, defaults to use the gethostname() return value. - -==== Code Sample - -[source,php] -.... -'use_relative_domain_name' => false, -.... - -=== Identify the database used with this installation -See also config option `supportedDatabases` - -Available: -- sqlite (SQLite3 - Not in Enterprise Edition) -- mysql (MySQL/MariaDB) -- pgsql (PostgreSQL) -- oci (Oracle - Enterprise Edition Only) - -==== Code Sample - -[source,php] -.... -'dbtype' => 'mysql', -.... - -=== Define the database server host name -For example `localhost`, `hostname`, `hostname.example.com`, or the IP address. - -To specify a port use: `hostname:####`; -To specify a Unix socket use: `localhost:/path/to/socket`. - -==== Code Sample - -[source,php] -.... -'dbhost' => '', -.... - -=== Define the ownCloud database name -The name of the ownCloud database which is set during installation. - -You should not need to change this. - -==== Code Sample - -[source,php] -.... -'dbname' => 'owncloud', -.... - -=== Define the ownCloud database user -This must be unique across ownCloud instances using the same SQL database. - -This is set up during installation, so you shouldn't need to change it. - -==== Code Sample - -[source,php] -.... -'dbuser' => '', -.... - -=== Define the password for the database user -This is set up during installation, so you shouldn't need to change it. - -==== Code Sample - -[source,php] -.... -'dbpassword' => '', -.... - -=== Define the prefix for the ownCloud tables in the database - -==== Code Sample - -[source,php] -.... -'dbtableprefix' => '', -.... - -=== Indicate whether the ownCloud instance was installed successfully -`true` indicates a successful installation, -`false` indicates an unsuccessful installation. - -==== Code Sample - -[source,php] -.... -'installed' => false, -.... - -== User Experience - -These optional parameters control some aspects of the user interface. -Default values, where present, are shown. - -=== Define the default language of your ownCloud instance -Using ISO_639-1 language codes such as `en` for English, `de` for German, and `fr` for French. - -Overrides automatic language detection on public pages like login or shared items. -User's language preferences configured under `personal -> language` override -this setting after they have logged in. - -==== Code Sample - -[source,php] -.... -'default_language' => 'en_GB', -.... - -=== Define the default app to open on user login -Use the app names as they appear in the URL after clicking them in the Apps menu, -such as files, documents or calendar etc. You can use a comma-separated list of app names, -so if the first app is not enabled for a user then ownCloud will try the second one, and so -on. If no enabled apps are found it defaults to the Files app. - -==== Code Sample - -[source,php] -.... -'defaultapp' => 'files', -.... - -=== Enable or disable avatars or user profile photos -`true` enables avatars, or user profile photos, `false` disables them. - -These appear on the User page, on user's Personal pages and are used by some apps -(contacts, mail, etc). - -==== Code Sample - -[source,php] -.... -'enable_avatars' => true, -.... - -=== Allow or disallow users to change their display names -`true` allows users to change their display names (on their Personal pages), -`false` prevents them from changing their display names. - -==== Code Sample - -[source,php] -.... -'allow_user_to_change_display_name' => true, -.... - -=== Allow or disallow users to change their email addresses -`true` allows users to change their email address (on their Personal pages), -`false` prevents them from changing their email address. - -==== Code Sample - -[source,php] -.... -'allow_user_to_change_mail_address' => true, -.... - -=== Define the lifetime of the remember-login cookie -The remember-login cookie is set when the user clicks the `remember` checkbox -on the login screen. The default is 15 days, expressed in seconds. - -==== Code Sample - -[source,php] -.... -'remember_login_cookie_lifetime' => 60*60*24*15, -.... - -=== Define the lifetime of a session after inactivity -The web UI might send a "heartbeat" based on the activity happening -in order to extend the session lifetime and keeping it from timing out -prematurely. If there is no activity happening and the lifetime is -reached, you'll have to log in again. - -The default is 20 minutes, expressed in seconds. - -==== Code Sample - -[source,php] -.... -'session_lifetime' => 60 * 20, -.... - -=== Enable session keep-alive when a user is logged in to the Web UI -Enabling this sends a "heartbeat" to the server to keep it from -timing out regardless of any activity happening. This heartbeat will -keep extending the session over again, so the user won't be logged out -even if he isn't active in the web UI. - -==== Code Sample - -[source,php] -.... -'session_keepalive' => true, -.... - -=== Enable to force user logout -Force the user to get logged out after the specified number of seconds when -the tab or browser gets closed. A negative or 0 value disables this feature. - -Note that the user can still access the page without re-authenticating -(having valid access) if the timeout has not been reached. -The recommended minimum value is 5 or 10 seconds. Using a lower value -might cause unwanted logouts for users. - -Note that this feature works properly if the user uses one tab only. -If a user uses multiple tabs, closing one of them will likely -force the rest to re-authenticate. - -==== Code Sample - -[source,php] -.... -'session_forced_logout_timeout' => 0, -.... - -=== Enforce token only authentication for apps and clients connecting to ownCloud -If enabled, all access requests using the user's password are blocked for enhanced security. - -Users have to generate special app-passwords (tokens) for their apps or clients in their personal -settings which are further used for app or client authentication. Browser logon is not affected. - -==== Code Sample - -[source,php] -.... -'token_auth_enforced' => false, -.... - -=== Enforce strict login check with user backend -If enabled, strict login check for password in user backend will be enforced, -meaning only the login name typed by the user would be validated. With this -configuration enabled, e.g. an additional check for email will not be performed. - -==== Code Sample - -[source,php] -.... -'strict_login_enforced' => false, -.... - -=== Define additional login buttons on the logon screen -Provides the ability to create additional login buttons on the logon screen, for e.g., SSO integration, -see the following example structure: - ----- - 'login.alternatives' => [ - ['href' => 'https://www.testshib.org/Shibboleth.sso/ProtectNetwork?target=https%3A%2F%2Fmy.owncloud.tld%2Flogin%2Fsso-saml%2F', - 'name' => 'ProtectNetwork', - 'img' => '/img/PN_sign-in.gif' - ], - ['href' => 'https://www.testshib.org/Shibboleth.sso/OpenIdP.org?target=https%3A%2F%2Fmy.owncloud.tld%2Flogin%2Fsso-saml%2F', - 'name' => 'OpenIdP.org', - 'img' => '/img/openidp.png' - ], - ], ----- - -==== Code Sample - -[source,php] -.... -'login.alternatives' => [], -.... - -=== Enable or disable ownCloud's built-in CSRF protection mechanism - -In some specific setups CSRF protection is handled in the environment, e.g., -running F5 ASM. In these cases the built-in mechanism is not needed and can be disabled. -Generally speaking, however, this config switch should be left unchanged. - -WARNING: leave this as is if you're not sure what it does. - -==== Code Sample - -[source,php] -.... -'csrf.disabled' => false, -.... - -=== Define how to relax same site cookie settings -Possible values: `Strict`, `Lax` or `None`. - -Setting the same site cookie to `None` is necessary in case of OpenID Connect. -For more information about the impact of the values see: -https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie/SameSite#values and -https://web.dev/schemeful-samesite/ - -* Use 'strict' whenever possible -* If necessary relax to 'lax' -* Use 'none' if it needs to be relaxed even further - -==== Code Sample - -[source,php] -.... -'http.cookie.samesite' => 'Strict', -.... - -=== Define the directory where the skeleton files are located -These files will be copied to the data directory of new users. - -Set this to the empty string if you do not want to copy any skeleton files. -A valid path must be given for this key otherwise errors will be generated in owncloud.log. - -==== Code Sample - -[source,php] -.... -'skeletondirectory' => '/path/to/owncloud/core/skeleton', -.... - -=== Define the `user_backends` app -Those need to be enabled first and allow you to configure alternate authentication backends. - -Supported backends are: -IMAP (OC_User_IMAP), SMB (OC_User_SMB), and FTP (OC_User_FTP). - -==== Code Sample - -[source,php] -.... -'user_backends' => [ - [ - 'class' => 'OC_User_IMAP', - 'arguments' => ['{imap.gmail.com:993/imap/ssl}INBOX'] - ] - ], -.... - -=== Define a custom link to reset passwords -If your user backend does not allow password resets (e.g. when it's a read-only -user backend like LDAP), you can specify a custom link, where the user is -redirected to, when clicking the "reset password" link after a failed login-attempt. - -If you do not want to provide any link, replace the URL with 'disabled'. - -==== Code Sample - -[source,php] -.... -'lost_password_link' => 'https://example.org/link/to/password/reset', -.... - -=== Allow medial search on user account properties -These account properties can be display name, user id, email, and other search terms. - -Allows finding 'Alice' when searching for 'lic'. May slow down user search. -Disable this if you encounter slow username search in the sharing dialog. - -==== Code Sample - -[source,php] -.... -'accounts.enable_medial_search' => true, -.... - -=== Allow medial search on the group id -Allows finding 'test' in groups when searching for 'es'. - -This is only used in the DB group backend (local groups). -This won't be used against LDAP, Shibboleth or any other group backend. - -==== Code Sample - -[source,php] -.... -'groups.enable_medial_search' => true, -.... - -=== Define minimum characters entered before a search returns results -Defines the minimum characters entered before a search returns results for -users or groups in the share autocomplete form. Lower values increase search -time especially for large backends. - -Any exact matches to a user or group will be returned, even though less than -the minimum characters have been entered. The search is case-insensitive. -For example, entering "tom" will always return "Tom" if there is an exact match. - -==== Code Sample - -[source,php] -.... -'user.search_min_length' => 2, -.... - -== Mail Parameters - -These configure the email settings for ownCloud notifications and password resets. - -=== Define the email RETURN address -The return address that you want to appear on emails sent by the ownCloud server. - -Example: `oc-admin@example.com`, substituting your own domain, of course. - -==== Code Sample - -[source,php] -.... -'mail_domain' => 'example.com', -.... - -=== Define the email FROM address -The FROM address that overrides the built-in `sharing-noreply` and -`lostpassword-noreply` FROM addresses. - -==== Code Sample - -[source,php] -.... -'mail_from_address' => 'owncloud', -.... - -=== Enable or disable SMTP class debugging - -==== Code Sample - -[source,php] -.... -'mail_smtpdebug' => false, -.... - -=== Define the mode for sending an email -Modes to use for sending mail: `sendmail`, `smtp`, `qmail` or `php`. - -If you are using local or remote SMTP, set this to `smtp`. - -If you are using PHP mail you must have an installed and working email system -on the server. The program used to send email is defined in the `php.ini` file. - -For the `sendmail` option you need an installed and working email system on -the server, with `/usr/sbin/sendmail` installed on your Unix system. - -For `qmail` the binary is /var/qmail/bin/sendmail, and it must be installed -on your Unix system. - -==== Code Sample - -[source,php] -.... -'mail_smtpmode' => 'sendmail', -.... - -=== Define the IP address of your mail server host -Depends on `mail_smtpmode`. May contain multiple hosts separated by a semicolon. - -If you need to specify the port number, append it to the IP address separated by -a colon, like this: `127.0.0.1:24`. - -==== Code Sample - -[source,php] -.... -'mail_smtphost' => '127.0.0.1', -.... - -=== Define the port for sending an email -Depends on `mail_smtpmode`. - -==== Code Sample - -[source,php] -.... -'mail_smtpport' => 25, -.... - -=== Define the SMTP server timeout -Depends on `mail_smtpmode`. Sets the SMTP server timeout in seconds. - -You may need to increase this if you are running an anti-malware or spam scanner. - -==== Code Sample - -[source,php] -.... -'mail_smtptimeout' => 10, -.... - -=== Define the SMTP security style -Depends on `mail_smtpmode`. Specify when you are using `ssl` or `tls`. - -Leave empty for no encryption. - -==== Code Sample - -[source,php] -.... -'mail_smtpsecure' => '', -.... - -=== Define the SMTP authentication -Depends on `mail_smtpmode`. Change this to `true` if your mail server requires authentication. - -==== Code Sample - -[source,php] -.... -'mail_smtpauth' => false, -.... - -=== Define the SMTP authentication type -Depends on `mail_smtpmode`. If SMTP authentication is required, -choose the authentication type as `LOGIN` (default) or `PLAIN`. - -==== Code Sample - -[source,php] -.... -'mail_smtpauthtype' => 'LOGIN', -.... - -=== Define the SMTP authentication username -Depends on `mail_smtpauth`. Specify the username for authenticating to the SMTP server. - -==== Code Sample - -[source,php] -.... -'mail_smtpname' => '', -.... - -=== Define the SMTP authentication password -Depends on `mail_smtpauth`. Specify the password for authenticating to the SMTP server. - -==== Code Sample - -[source,php] -.... -'mail_smtppassword' => '', -.... - -=== Remove the sender display name in sharing emails -Mail notifications about shares include the display name of the sharer in the email -"from" address. This can cause some email filters to block these as impersonation -attempts. Set remove_sender_display_name to true to not include this information. - -==== Code Sample - -[source,php] -.... -'remove_sender_display_name' => false, -.... - -== Proxy Configurations - -=== Override automatic proxy detection -The automatic hostname detection of ownCloud can fail in certain reverse -proxy and CLI/cron situations. This option allows you to manually override -the automatic detection; for example `www.example.com`, or specify the port -`www.example.com:8080`. - -==== Code Sample - -[source,php] -.... -'overwritehost' => '', -.... - -=== Override protocol (http/https) usage -When generating URLs, ownCloud attempts to detect whether the server is -accessed via `https` or `http`. However, if ownCloud is behind a proxy -and the proxy handles the `https` calls, ownCloud would not know that -`ssl` is in use, which would result in incorrect URLs being generated. - -Valid values are `http` and `https`. - -==== Code Sample - -[source,php] -.... -'overwriteprotocol' => '', -.... - -=== Override ownClouds webroot -ownCloud attempts to detect the webroot for generating URLs automatically. - -For example, if `www.example.com/owncloud` is the URL pointing to the -ownCloud instance, the webroot is `/owncloud`. When proxies are in use, it -may be difficult for ownCloud to detect this parameter, resulting in invalid URLs. - -==== Code Sample - -[source,php] -.... -'overwritewebroot' => '', -.... - -=== Override condition for the remote IP address with a regular expression -This option allows you to define a manual override condition as a regular -expression for the remote IP address. The keys `overwritewebroot`, -`overwriteprotocol`, and `overwritehost` are subject to this condition. - -For example, defining a range of IP addresses starting with `10.0.0.` -and ending with 1 to 3: * `^10\.0\.0\.[1-3]$` - -==== Code Sample - -[source,php] -.... -'overwritecondaddr' => '', -.... - -=== Override cli URL -Use this configuration parameter to specify the base URL for any URLs which -are generated within ownCloud using any kind of command line tools (cron or occ). - -The value should contain the full base URL: `https://www.example.com/owncloud` -As an example, alerts shown in the browser to upgrade an app are triggered by -a cron background process and therefore uses the url of this key, even if the user -has logged on via a different domain defined in key `trusted_domains`. When the -user clicks an alert like this, they will be redirected to that URL and must log on again. - -==== Code Sample - -[source,php] -.... -'overwrite.cli.url' => '', -.... - -=== Define the Web base URL -This key is necessary for the navigation item to the new ownCloud Web UI and for redirecting -public and private links. - -==== Code Sample - -[source,php] -.... -'web.baseUrl' => '', -.... - -=== Define rewrite private and public links -Rewrite private and public links to the new ownCloud Web UI (if available). - -If web.rewriteLinks is set to 'true', public and private links will be redirected to this url. -The Web UI will handle these links accordingly. - -As an example, in case 'web.baseUrl' is set to 'http://web.example.com', -the shared link 'http://ocx.example.com/index.php/s/THoQjwYYMJvXMdW' will be redirected -by ownCloud to 'http://web.example.com/index.html#/s/THoQjwYYMJvXMdW'. - -==== Code Sample - -[source,php] -.... -'web.rewriteLinks' => false, -.... - -=== Define clean URLs without `/index.php` -This parameter will be written as `RewriteBase` on update and installation of -ownCloud to your `.htaccess` file. While this value is often simply the URL -path of the ownCloud installation it cannot be set automatically properly in -every scenario and needs thus some manual configuration. - -In a standard Apache setup this usually equals the folder that ownCloud is -accessible at. So if ownCloud is accessible via `https://mycloud.org/owncloud` -the correct value would most likely be `/owncloud`. If ownCloud is running -under `https://mycloud.org/` then it would be `/`. - -Note that the above rule is not valid in every case, as there are some rare setup -cases where this may not apply. However, to avoid any update problems this -configuration value is explicitly opt-in. - -After setting this value run `{occ-command-example-prefix} maintenance:update:htaccess`. Now, when the -following conditions are met ownCloud URLs won't contain `index.php`: - -- `mod_rewrite` is installed -- `mod_env` is installed - -==== Code Sample - -[source,php] -.... -'htaccess.RewriteBase' => '/', -.... - -=== Define the URL of your proxy server -Example: `proxy.example.com:8081`. - -==== Code Sample - -[source,php] -.... -'proxy' => '', -.... - -=== Define a list of hostnames that won't be proxied. - -This option only applies if the `proxy` option is used -Example: `['specific.hostname.com', '.sub.domain.com']`. - -==== Code Sample - -[source,php] -.... -'proxy_ignore' => [], -.... - -=== Define proxy authentication -The optional authentication for the proxy to use to connect to the internet. - -The format is: `username:password`. - -The username and the password need to be urlencoded to avoid breaking the -delimiter syntax "username:password@hostname:port" - -Example: `usern@me` needs to be encoded as `usern%40ame`. - -==== Code Sample - -[source,php] -.... -'proxyuserpwd' => '', -.... - -== Deleted Items (trash bin) - -These parameters control the Deleted files app. - -=== Define the trashbin retention obligation -If the trash bin app is enabled (default), this setting defines the policy -for when files and folders in the trash bin will be permanently deleted. - -The app allows for two settings, a minimum time for trash bin retention, -and a maximum time for trash bin retention. -Minimum time is the number of days a file will be kept, after which it may be deleted. -Maximum time is the number of days at which it is guaranteed to be deleted. -Both minimum and maximum times can be set together to explicitly define -file and folder deletion. For migration purposes, this setting is installed -initially set to `auto`, which is equivalent to the default setting in -ownCloud 8.1 and before. - -Available values: - -* `auto` - default setting. Keeps files and folders in the deleted files for up to - 30 days, automatically deleting them (at any time) if space is needed. - Note: files may not be removed if space is not required. -* `D, auto` - keeps files and folders in the trash bin for D+ days, delete anytime if - space needed (Note: files may not be deleted if space is not needed) -* `auto, D` - delete all files in the trash bin that are older than D days - automatically, delete other files anytime if space needed -* `D1, D2` - keep files and folders in the trash bin for at least D1 days and - delete when exceeds D2 days -* `disabled` - trash bin auto clean disabled, files and folders will be kept forever - -==== Code Sample - -[source,php] -.... -'trashbin_retention_obligation' => 'auto', -.... - -=== Define the trashbin purge limit -This setting defines the percentage of free space occupied by deleted files -that triggers auto purging of deleted files for this user - -==== Code Sample - -[source,php] -.... -'trashbin_purge_limit' => 50, -.... - -=== Define trashbin directory skip list -Define a list of directories that will skip the trashbin and therefore be deleted immediately. - -Only defined directories and only in the root of a mount will skip the trashbin. -Consider not to use reserved directory names when using snapshot capable storage systems. -The setting expects folder names with or without trailing slash. -All the content of such directories including their subdirectories will also skip the trashbin. - -==== Code Sample - -[source,php] -.... -'trashbin_skip_directories' => [ - 'temp', -], -.... - -=== Define trashbin file extension skip list -Define a list of file extensions to determine files that will skip the trashbin and therefore be deleted immediately. - -Extension names are valid for all mount points, take care when selecting the names. - -Values must not have a leading ".", otherwise corresponding files won't be detected. -Values are case-insensitive - -==== Code Sample - -[source,php] -.... -'trashbin_skip_extensions' => [ - 'iso', - 'mkv', -], -.... - -=== Define trashbin threshold size -Define a threshold for files to skip the trashbin and delete immediately -Once the size of a resource is greater than or equal the given value, the trashbin will be skipped. - -File sizes are valid for all mount points, take care when defining the threshold. - -All positive numbers and zero is allowed. Append one of the following options directly and without space: -B, K, KB, MB, M, GB, G, TB, T, PB, P - -==== Code Sample - -[source,php] -.... -'trashbin_skip_size_threshold' => "1GB", -.... - -== File versions - -These parameters control the Versions app. - -=== Define the files versions retention obligation -If the versions app is enabled (default), this setting defines the policy -for when versions will be permanently deleted. - -The app allows for two settings, a minimum time for version retention, -and a maximum time for version retention. -Minimum time is the number of days a version will be kept, after which it -may be deleted. Maximum time is the number of days at which it is guaranteed -to be deleted. -Both minimum and maximum times can be set together to explicitly define -version deletion. For migration purposes, this setting is installed -initially set to "auto", which is equivalent to the default setting in -ownCloud 8.1 and before. - -Available values: - -* `auto` - default setting. Automatically expire versions according to expire - rules. Please refer to https://doc.owncloud.com/server/latest/admin_manual/configuration/files/file_versioning.html - for more information. -* `D, auto` - keep versions at least for D days, apply expiry rules to all versions - that are older than D days -* `auto, D` - delete all versions that are older than D days automatically, delete - other versions according to expire rules -* `D1, D2` - keep versions for at least D1 days and delete when exceeds D2 days -* `disabled` - versions auto clean disabled, versions will be kept forever - -==== Code Sample - -[source,php] -.... -'versions_retention_obligation' => 'auto', -.... - -=== Save additional metadata for versions -Save additional metadata (author, version tag, etc.) of each version of uploaded and edited files. - -WARNING: This feature CANNOT be temporarily disabled once enabled. -Disabling and re-enabling would require a repair job that erases all extended versions metadata. -WARNING: This does not work for S3 storage backends. - -==== Code Sample - -[source,php] -.... -'file_storage.save_version_metadata' => false, -.... - -== ownCloud Verifications - -ownCloud performs several verification checks. There are two options, -`true` and `false`. - -=== Enable or disable updatechecker -Check if ownCloud is up-to-date and shows a notification if a new version is available. - -This option is only applicable to ownCloud core. It is not applicable to app updates. - -==== Code Sample - -[source,php] -.... -'updatechecker' => true, -.... - -=== Define the updatechecker URL -The URL that ownCloud should use to look for updates - -==== Code Sample - -[source,php] -.... -'updater.server.url' => 'https://updates.owncloud.com/server/', -.... - -=== Check for an internet connection -Is ownCloud connected to the Internet or running in a closed network? - -==== Code Sample - -[source,php] -.... -'has_internet_connection' => true, -.... - -=== Check for a `.well-known` setup -Allows ownCloud to verify a working .well-known URL redirect. - -This is done by attempting to make a request from JS to -`https://your-domain.com/.well-known/caldav/` - -==== Code Sample - -[source,php] -.... -'check_for_working_wellknown_setup' => true, -.... - -=== Define if config.php is read only -In certain environments it is desired to have a read-only configuration file. - -When this switch is set to `true` ownCloud will not verify whether the -configuration is writable. However, it will not be possible to configure -all options via the Web interface. Furthermore, when updating ownCloud -it is required to make the configuration file writable again for the update -process. - -==== Code Sample - -[source,php] -.... -'config_is_read_only' => false, -.... - -=== Define ownCloud operation modes -This defines the mode of operations. The default value is `single-instance` -which means, that ownCloud is running on a single node, which might be the -most common operations mode. The only other possible value for now is -`clustered-instance` which means, that ownCloud is running on at least 2 -nodes. The mode of operations has various impacts on the behavior of ownCloud. - -The primary impact is, that clustered instances won't download apps from the -marketplace and install in one server. Instead the admin has to ensure that -this happens manually on all servers. The same applies to config.php configuration -settings done via `occ`. - -==== Code Sample - -[source,php] -.... -'operation.mode' => 'single-instance', -.... - -== Logging - -These parameters configure the logging options. -For additional information or advanced configuration, please see the logging -section in the documentation. - -=== Define the log type -By default the ownCloud logs are sent to the `owncloud.log` file in the -default ownCloud data directory. - -If syslogging is desired, set this parameter to `syslog`. -Setting this parameter to `errorlog` will use the PHP error_log function -for logging. - -==== Code Sample - -[source,php] -.... -'log_type' => 'owncloud', -.... - -=== Define the log path -Log file path for the ownCloud logging type. - -Defaults to `[datadirectory]/owncloud.log` - -==== Code Sample - -[source,php] -.... -'logfile' => '/var/log/owncloud.log', -.... - -=== Define the log level -Loglevel to start logging at. Valid values are: 0 = Debug, 1 = Info, 2 = -Warning, 3 = Error, and 4 = Fatal. The default value is Warning. - -==== Code Sample - -[source,php] -.... -'loglevel' => 2, -.... - -=== Define the syslog tag -If you maintain different instances and aggregate the logs, you may want -to distinguish between them. `syslog_tag` can be set per instance -with a unique id. Only available if `log_type` is set to `syslog`. - -The default value is `ownCloud`. - -==== Code Sample - -[source,php] -.... -'syslog_tag' => 'ownCloud', -.... - -=== Define the syslog format -The syslog format can be changed to remove or add information. - -In addition to the %replacements% below %level% can be used, but it is used -as a dedicated parameter to the syslog logging facility anyway. - -==== Code Sample - -[source,php] -.... -'log.syslog.format' => '[%reqId%][%remoteAddr%][%user%][%app%][%method%][%url%] %message%', -.... - -=== Define log conditions -Log condition for log level increase based on conditions. Once one of these -conditions is met, the required log level is set to debug. This allows to -debug specific requests, users or apps - -Supported conditions: -- `shared_secret`: If a request parameter with the name `log_secret` is set to - this value the condition is met -- `users`: If the current request is done by one of the specified users, - this condition is met -- `apps`: If the log message is invoked by one of the specified apps, - this condition is met -- `logfile`: The log message invoked by the specified apps get redirected to - this logfile, this condition is met - Note: Not applicable when using syslog - -Defaults to an empty array - -==== Code Sample - -[source,php] -.... -'log.conditions' => [ - [ - 'shared_secret' => '57b58edb6637fe3059b3595cf9c41b9', - 'users' => ['user1'], - 'apps' => ['files_texteditor'], - 'logfile' => '/tmp/test.log' - ], - [ - 'shared_secret' => '57b58edb6637fe3059b3595cf9c41b9', - 'users' => ['user1'], - 'apps' => ['files_mediaviewer'], - 'logfile' => '/tmp/mediaviewer.log' - ], - [ - # special sql query logging - 'apps' => ['core/sql'], - 'logfile' => __DIR__ . '/../data/sql.jsonl' - ], - ], -.... - -=== Define the log date format -This uses PHP.date formatting; see http://php.net/manual/en/function.date.php - -==== Code Sample - -[source,php] -.... -'logdateformat' => 'F d, Y H:i:s', -.... - -=== Define the log timezone -The default timezone for logfiles is UTC. You may change this; see -http://php.net/manual/en/timezones.php - -==== Code Sample - -[source,php] -.... -'logtimezone' => 'Europe/Berlin', -.... - -=== Define logging if Cron ran successfully -Log successful cron runs. - -==== Code Sample - -[source,php] -.... -'cron_log' => true, -.... - -=== Define the maximum log rotation file size -Enables log rotation and limits the total size of the logfiles. - -The default is 0 or false which disables log rotation. -Specify a size in bytes, for example 104857600 -(100 megabytes = 100 * 1024 * 1024 bytes). -A new logfile is created with a new name when the old logfile reaches the defined limit. -If a rotated log file is already present, it will be overwritten. -If enabled, only the active log file and one rotated file are stored. - -==== Code Sample - -[source,php] -.... -'log_rotate_size' => false, -.... - -== Alternate Code Locations - -Some ownCloud code may be stored in alternate locations. - -=== Define alternative app directories -If you want to store apps in a custom directory instead of ownCloud's default -`/apps`, you need to modify the `apps_paths` key. There, you need to add a -new associative array that contains three elements. These are: - -- `path` The absolute file system path to the custom app folder. -- `url` The request path to that folder relative to the ownCloud web root, prefixed with /. -- `writable` Whether users can install apps in that folder. After the configuration is added, - new apps will only install in a directory where writable is set to true. - -The configuration example shows how to add a second directory, called `/apps-external`. -Here, new apps and updates are only written to the `/apps-external` directory. -This eases upgrade procedures of owncloud where shipped apps are delivered to apps/ by default. -`OC::$SERVERROOT` points to the web root of your instance. -Please see the Apps Management description on how to move custom apps properly. - -==== Code Sample - -[source,php] -.... -'apps_paths' => [ - 0 => - [ - 'path' => OC::$SERVERROOT.'/apps', - 'url' => '/apps', - 'writable' => false, - ], - 1 => - [ - 'path' => OC::$SERVERROOT.'/apps-external', - 'url' => '/apps-external', - 'writable' => true, - ], - ], -.... - -== Previews - -ownCloud supports previews of image files, the covers of MP3 files, and text files. -These options control enabling and disabling previews, and thumbnail size. - -=== Enable preview generation -By default, ownCloud can generate previews for the following filetypes: - -- Image files -- Covers of MP3 files -- Text documents - -Valid values are `true`, to enable previews, or `false`, to disable previews - -==== Code Sample - -[source,php] -.... -'enable_previews' => true, -.... - -=== Define the preview path -Location of the thumbnails folder, defaults to `data/$user/thumbnails` where -`$user` is the current user. When specified, the format will change to -`$previews_path/$user` where `$previews_path` is the configured previews base directory -and `$user` will be substituted with the user id automatically. - -For example if `previews_path` is `/var/cache/owncloud/thumbnails` then for a logged-in -user `user1` the thumbnail path will be `/var/cache/owncloud/thumbnails/user1`. - -==== Code Sample - -[source,php] -.... -'previews_path' => '', -.... - -=== Define the maximum x-axis width for previews -The maximum width, in pixels, of a preview. - -A value of `null` means there is no limit. - -==== Code Sample - -[source,php] -.... -'preview_max_x' => 2048, -.... - -=== Define the maximum y-axis width for previews -The maximum height, in pixels, of a preview. A value of `null` means there is no limit. - -==== Code Sample - -[source,php] -.... -'preview_max_y' => 2048, -.... - -=== Define the maximum preview scale factor -If a lot of small pictures are stored on the ownCloud instance and the -preview system generates blurry previews, you might want to consider setting -a maximum scale factor. By default, pictures are upscaled to 10 times the -original size. A value of `1` or `null` disables scaling. - -==== Code Sample - -[source,php] -.... -'preview_max_scale_factor' => 10, -.... - -=== Define the maximum preview filesize limit -Max file size for generating image previews with imagegd (default behaviour) -If the image is bigger, it will try other preview generators, -but will most likely show the default mimetype icon - -Value represents the maximum filesize in megabytes -Default is 50. Set to -1 for no limit. - -==== Code Sample - -[source,php] -.... -'preview_max_filesize_image' => 50, -.... - -=== Define the maximum dimensions of the original image for preview generation -In contrast to `preview_max_x` and `preview_max_y` which define the maximum -dimensions of generated previews, this setting limits the original image's size. - -Original images bigger than the defined dimension will not be processed. - -Value represents the maximum dimension in the format width x height -Default is 6016x6016. - -==== Code Sample - -[source,php] -.... -'preview_max_dimensions' => '6016x6016', -.... - -=== Define the custom path for the LibreOffice / OpenOffice binary - -==== Code Sample - -[source,php] -.... -'preview_libreoffice_path' => '/usr/bin/libreoffice', -.... - -=== Define additional arguments for LibreOffice / OpenOffice -Use this setting if LibreOffice/OpenOffice requires additional arguments. - -==== Code Sample - -[source,php] -.... -'preview_office_cl_parameters' => - '--headless --nologo --nofirststartwizard --invisible --norestore ', - '--convert-to pdf --outdir ', -.... - -=== Define preview providers -Show thumbnails for register providers that have been explicitly enabled. - -The following providers are enabled by default if no other providers are selected: - -- OC\Preview\PNG -- OC\Preview\JPEG -- OC\Preview\WEBP -- OC\Preview\GIF -- OC\Preview\BMP -- OC\Preview\XBitmap -- OC\Preview\MarkDown -- OC\Preview\MP3 -- OC\Preview\TXT - -See the Previews Configuration documentation for more details. - -==== Code Sample - -[source,php] -.... -'enabledPreviewProviders' => [ - 'OC\Preview\PDF', - 'OC\Preview\SGI', - 'OC\Preview\Heic', - 'OC\Preview\PNG', - 'OC\Preview\JPEG', - 'OC\Preview\WEBP', - 'OC\Preview\GIF', - 'OC\Preview\BMP', - 'OC\Preview\XBitmap', - 'OC\Preview\MP3', - 'OC\Preview\TXT', - 'OC\Preview\MarkDown' - ], -.... - -=== Define the jpeg preview quality -This setting defines the JP(E)G image quality in [%] for displaying thumbnails and image -previews for apps like 'files_mediaviewer'. Note that this setting is for displaying -only and has no impact on the stored thumbnail / preview quality or size. - -The scale ranges from 1 to 100, where 1 is the lowest and 100 the highest. -It defaults to -1 which is equivalent to approximately 75% of the original -image quality. - -Note that any value over 80 may result in an unnecessary increase of the -displayed image and has larger responses sizes when requesting images, -without much increase of the image quality. - -For more information see: -https://www.php.net/manual/en/function.imagejpeg.php - -==== Code Sample - -[source,php] -.... -'previewJPEGImageDisplayQuality' => -1, -.... - -== Comments - -Global settings for the Comments infrastructure - -=== Define an alternative Comments Manager -Replaces the default Comments Manager Factory. This can be utilized if an -own or 3rdParty CommentsManager should be used that – for instance – uses the -filesystem instead of the database to keep the comments. - -==== Code Sample - -[source,php] -.... -'comments.managerFactory' => '\OC\Comments\ManagerFactory', -.... - -=== Define an alternative System Tags Manager -Replaces the default System Tags Manager Factory. This can be utilized if an -own or 3rdParty SystemTagsManager should be used that – for instance – uses the -filesystem instead of the database to keep the tags. - -==== Code Sample - -[source,php] -.... -'systemtags.managerFactory' => '\OC\SystemTag\ManagerFactory', -.... - -== Maintenance - -These options are for halting user activity when you are performing server -maintenance. - -=== Enable maintenance mode to disable ownCloud -If you want to prevent users from logging in to ownCloud before you start -doing some maintenance work, you need to set the value of the maintenance -parameter to true. Please keep in mind that users who are already logged-in -are kicked out of ownCloud instantly. - -==== Code Sample - -[source,php] -.... -'maintenance' => false, -.... - -=== Enable or disable `single user mode` -When set to `true`, the ownCloud instance will be unavailable for all users -who are not in the `admin` group. - -==== Code Sample - -[source,php] -.... -'singleuser' => false, -.... - -== SSL - -=== Extra SSL options to be used for configuration - -==== Code Sample - -[source,php] -.... -'openssl' => [ - 'config' => '/absolute/location/of/openssl.cnf', - ], -.... - -=== Allow the configuration of system-wide trusted certificates - -==== Code Sample - -[source,php] -.... -'enable_certificate_management' => false, -.... - -== Memory caching backend configuration -Available cache backends: - -* `\OC\Memcache\APCu` APC user backend -* `\OC\Memcache\ArrayCache` In-memory array-based backend (not recommended) -* `\OC\Memcache\Memcached` Memcached backend -* `\OC\Memcache\Redis` Redis backend - -Advice on choosing between the various backends: - -* APCu should be easiest to install. Almost all distributions have packages. - Use this for single user environment for all caches. -* Use Redis or Memcached for distributed environments. - For the local cache (you can configure two) take APCu. - -=== Memory caching backend for locally stored data - -* Used for host-specific data, e.g. file paths - -==== Code Sample - -[source,php] -.... -'memcache.local' => '\OC\Memcache\APCu', -.... - -=== Memory caching backend for distributed data - -* Used for installation-specific data, e.g. database caching -* If unset, defaults to the value of memcache.local - -==== Code Sample - -[source,php] -.... -'memcache.distributed' => '\OC\Memcache\Memcached', -.... - -=== Define Redis connection details -Connection details for Redis to use for memory caching in a single server configuration. - -For enhanced security it is recommended to configure Redis to require a password. -See http://redis.io/topics/security for more information. - -==== Code Sample - -[source,php] -.... -'redis' => [ - 'host' => 'localhost', // can also be a unix domain socket: '/tmp/redis.sock' - 'port' => 6379, - 'timeout' => 0.0, - 'password' => '', // Optional, if not defined, no password will be used. - 'dbindex' => 0, // Optional, if undefined SELECT will not run and will use Redis Server's default DB Index. Out of the box, every Redis instance supports 16 databases so `` has to be set between 0 and 15. - // Optional config option - // In order to use connection_parameters php-redis extension >= 5.3.0 is required - // In order to use SSL/TLS redis server >= 6.0 is required - // In a single-server configuration, prefix the host with tls:// like tls://localhost - // In a single-server configuration the SSL/TLS data **must** be in the stream section - 'connection_parameters' => [ - 'stream' => [ - 'local_cert' => '/file/path/to/redis.crt', - 'local_pk' => '/file/path/to/redis.key', - 'cafile' => '/file/path/to/ca.crt', - 'verify_peer_name' => true - ], - ], - - ], -.... - -=== Define Redis Cluster connection details -Only for use with Redis Clustering, for Sentinel-based setups use the single -server configuration above, and perform HA on the hostname. - -Redis Cluster support requires the php module phpredis in version 3.0.0 or higher. - -Available failover modes: -- \RedisCluster::FAILOVER_NONE - only send commands to primary nodes (default) -- \RedisCluster::FAILOVER_ERROR - failover to replicas for read commands if primary is unavailable -- \RedisCluster::FAILOVER_DISTRIBUTE - randomly distribute read commands across primary and replica nodes - -==== Code Sample - -[source,php] -.... -'redis.cluster' => [ - 'seeds' => [ // provide some/all the cluster servers to bootstrap discovery, port required - 'localhost:7000', - 'localhost:7001' - ], - 'timeout' => 0.0, - 'read_timeout' => 0.0, - 'failover_mode' => \RedisCluster::FAILOVER_DISTRIBUTE, - 'password' => '', // Optional, if not defined, no password will be used. - // Optional config option - // In order to use connection_parameters php-redis extension >= 5.3.0 is required - // In order to use SSL/TLS redis server >= 6.0 is required - // In a cluster configuration, prefix the seeds with tls:// like tls://localhost:7000 - // In a cluster configuration the SSL/TLS data **must not** be in the stream section - 'connection_parameters' => [ - 'local_cert' => '/file/path/to/redis.crt', - 'local_pk' => '/file/path/to/redis.key', - 'cafile' => '/file/path/to/ca.crt', - 'verify_peer_name' => true - ], - ], -.... - -=== Define server details for memcached servers to use for memory caching -Server details for one or more memcached servers to use for memory caching - -==== Code Sample - -[source,php] -.... -'memcached_servers' => [ - // hostname, port and optional weight. Also see: - // http://www.php.net/manual/en/memcached.addservers.php - // http://www.php.net/manual/en/memcached.addserver.php - ['localhost', 11211], - //[other.host.local', 11211], - ], -.... - -=== Define connection options for memcached -For more details please see http://apprize.info/php/scaling/15.html - -==== Code Sample - -[source,php] -.... -'memcached_options' => [ - // Set timeouts to 50ms - \Memcached::OPT_CONNECT_TIMEOUT => 50, - \Memcached::OPT_RETRY_TIMEOUT => 50, - \Memcached::OPT_SEND_TIMEOUT => 50, - \Memcached::OPT_RECV_TIMEOUT => 50, - \Memcached::OPT_POLL_TIMEOUT => 50, - - // Enable compression - \Memcached::OPT_COMPRESSION => true, - - // Turn on consistent hashing - \Memcached::OPT_LIBKETAMA_COMPATIBLE => true, - - // Enable Binary Protocol - \Memcached::OPT_BINARY_PROTOCOL => true, - - // Binary serializer will be enabled if the igbinary PECL module is available - //\Memcached::OPT_SERIALIZER => \Memcached::SERIALIZER_IGBINARY, - ], -.... - -=== Define the location of the cache folder -The location of the cache folder defaults to `data/$user/cache` where -`$user` is the current user. When specified, the format will change to -`$cache_path/$user` where `$cache_path` is the configured cache directory -and `$user` is the user. - -==== Code Sample - -[source,php] -.... -'cache_path' => '', -.... - -=== Define the TTL for garbage collection -TTL of chunks located in the cache folder before they're removed by -garbage collection (in seconds). Increase this value if users have -issues uploading very large files via the ownCloud Client as upload isn't -completed within one day. - -==== Code Sample - -[source,php] -.... -'cache_chunk_gc_ttl' => 86400, // 60*60*24 = 1 day -.... - -=== Define the DAV chunk base directory -Location of the chunk folder, defaults to `/$user/uploads` where -`$user` is the current user and `datadirectory` is the datadirectory described here. - -When specified, the format will change to `$dav.chunk_base_dir/$user` where -`$dav.chunk_base_dir` is the configured cache directory here and `$user` is the user. - -==== Code Sample - -[source,php] -.... -'dav.chunk_base_dir' => '', -.... - -== Sharing - -Global settings for Sharing - -=== Define an alternative Share Provider -Replaces the default Share Provider Factory. This can be utilized if -own or 3rdParty Share Providers are used that – for instance – use the -filesystem instead of the database to keep the share information. - -==== Code Sample - -[source,php] -.... -'sharing.managerFactory' => '\OC\Share20\ProviderFactory', -.... - -=== Allow schema fallback for federated sharing servers -When talking with federated sharing server, allow falling back to HTTP -instead of hard forcing HTTPS - -==== Code Sample - -[source,php] -.... -'sharing.federation.allowHttpFallback' => false, -.... - -=== Show a quick action for the public link creation -Set this to true to display a quick action for creating public links -in the filelist. A public link created this way will be read-only per default. - -Note: if enforced password protection for read-only links is enabled, the -quick action will not be displayed! - -==== Code Sample - -[source,php] -.... -'sharing.showPublicLinkQuickAction' => false, -.... - -== All other configuration options - -=== Define additional database driver options -Additional driver options for the database connection, e.g. to enable SSL -encryption in MySQL or specify a custom wait timeout on a cheap hoster. - -==== Code Sample - -[source,php] -.... -'dbdriveroptions' => [ - PDO::MYSQL_ATTR_SSL_CA => '/file/path/to/ca_cert.pem', - PDO::MYSQL_ATTR_INIT_COMMAND => 'SET wait_timeout = 28800' - ], -.... - -=== Define sqlite3 journal mode -sqlite3 journal mode can be specified using this configuration parameter - -can be 'WAL' or 'DELETE' see for more details https://www.sqlite.org/wal.html - -==== Code Sample - -[source,php] -.... -'sqlite.journal_mode' => 'DELETE', -.... - -=== Define MySQL 3/4 byte character handling -During setup, if requirements are met (see below), this setting is set to true -and MySQL can handle 4 byte characters instead of 3 byte characters. - -If you want to convert an existing 3-byte setup into a 4-byte setup please -set the parameters in MySQL as mentioned below and run the migration command: -`{occ-command-example-prefix} db:convert-mysql-charset` -The config setting will be set automatically after a successful run. - -Consult the documentation for more details. - -MySQL requires a special setup for longer indexes (> 767 bytes) which are needed: - -[source,console] -.... -[mysqld] -innodb_large_prefix=ON -innodb_file_format=Barracuda -innodb_file_per_table=ON -.... - -Tables will be created with - * character set: utf8mb4 - * collation: utf8mb4_bin - * row_format: compressed - -See: -https://dev.mysql.com/doc/refman/5.7/en/charset-unicode-utf8mb4.html -https://dev.mysql.com/doc/refman/5.7/en/innodb-parameters.html#sysvar_innodb_large_prefix -https://mariadb.com/kb/en/mariadb/xtradbinnodb-server-system-variables/#innodb_large_prefix -http://www.tocker.ca/benchmarking-innodb-page-compression-performance.html -https://titanwolf.org/Network/Articles/Article?AID=58c487d4-7e0f-4fbe-9262-4285553ef443 (Using innodb_large_prefix to avoid ERROR 1071) - -==== Code Sample - -[source,php] -.... -'mysql.utf8mb4' => false, -.... - -=== Force a specific database platform class -False means that autodetection will take place. - -E.g. to fix MariaDB 1.2.7+ taken for MySQL -'db.platform' => '\Doctrine\DBAL\Platforms\MariaDb1027Platform', - -See: -https://docs.microsoft.com/en-us/azure/mariadb/concepts-limits#current-known-issues - -==== Code Sample - -[source,php] -.... -'db.platform' => false, -.... - -=== Define supported database types -Database types that are supported for installation. - -Available: -- sqlite (SQLite3 - Not in Enterprise Edition) -- mysql (MySQL) -- pgsql (PostgreSQL) -- oci (Oracle - Enterprise Edition Only) - -==== Code Sample - -[source,php] -.... -'supportedDatabases' => [ - 'sqlite', - 'mysql', - 'pgsql', - 'oci', - ], -.... - -=== Define the location for temporary files -Override where ownCloud stores temporary files. Useful in situations where -the system temporary directory is on a limited space ramdisk or is otherwise -restricted, or if external storages which do not support streaming are in use. - -The Web server user must have write access to this directory. - -==== Code Sample - -[source,php] -.... -'tempdirectory' => '/tmp/owncloudtemp', -.... - -=== Define the hashing cost -The hashing cost used by hashes generated by ownCloud. - -Using a higher value requires more time and CPU power to calculate the hashes. -As this number grows, the amount of work (typically CPU time or memory) necessary -to compute the hash increases exponentially. - -==== Code Sample - -[source,php] -.... -'hashingCost' => 10, -.... - -=== Define blacklisted files -Blacklist a specific file or files and disallow the upload of files -with this name. `.htaccess` is blocked by default. - -WARNING: USE THIS ONLY IF YOU KNOW WHAT YOU ARE DOING. - -==== Code Sample - -[source,php] -.... -'blacklisted_files' => [ - '.htaccess' - ], -.... - -=== Define blacklisted files regular expression(s) -Blacklist files that match any of the given regular expressions and disallow -the upload of those files. The matching is case-insensitive. - -WARNING: USE THIS ONLY IF YOU KNOW WHAT YOU ARE DOING. - -==== Code Sample - -[source,php] -.... -'blacklisted_files_regex' => [ - '.*\.ext', - '^somefilename.*' - ], -.... - -=== Define excluded directories -Exclude specific directory names and disallow scanning, creating and renaming -using these names. The matching is case-insensitive. - -Excluded directory names are queried at any path part like at the beginning, -in the middle or at the end and will not be further processed if found. -Please see the documentation for details and examples. -Use when the storage backend supports, e.g. snapshot directories to be excluded. - -WARNING: USE THIS ONLY IF YOU KNOW WHAT YOU ARE DOING. - -==== Code Sample - -[source,php] -.... -'excluded_directories' => [ - '.snapshot', - '~snapshot', - ], -.... - -=== Define excluded directories regular expression(s) -Exclude directory names that match any of the given regular expressions and -disallow scanning, creating and renaming using these names. The matching is -case-insensitive. - -Excluded directory names are queried at any path part like at the beginning, -in the middle or at the end and will not be further processed if found. -Please see the documentation for details and examples. -Use when the storage backend supports, e.g. snapshot directories to be excluded. - -WARNING: USE THIS ONLY IF YOU KNOW WHAT YOU ARE DOING. - -==== Code Sample - -[source,php] -.... -'excluded_directories_regex' => [ - '^backup.*', - '.*backup$', - ], -.... - -=== Define files that are excluded from integrity checking -Exclude files from the integrity checker command - -==== Code Sample - -[source,php] -.... -'integrity.excluded.files' => [ - '.DS_Store', - 'Thumbs.db', - '.directory', - '.webapp', - '.htaccess', - '.user.ini', - ], -.... - -=== Define apps or themes that are excluded from integrity checking -The list of apps that are allowed and must not have a signature.json file present. - -Besides ownCloud apps, this is particularly useful when creating ownCloud themes, -because themes are treated as apps. The app is identified with it´s app-id. -The app-id can be identified by the folder name of the app in your apps directory. -The following example allows app-1 and theme-2 to have no signature.json file. - -==== Code Sample - -[source,php] -.... -'integrity.ignore.missing.app.signature' => [ - 'app-id of app-1', - 'app-id of theme-2', - ], -.... - -=== Define a default folder for shared files and folders other than root -Please note that this setting is skipped for guests and the root folder will be used for such users. - -==== Code Sample - -[source,php] -.... -'share_folder' => '/', -.... - -=== Define the default cipher for encrypting files -Currently AES-128-CFB and AES-256-CFB are supported. - -==== Code Sample - -[source,php] -.... -'cipher' => 'AES-256-CFB', -.... - -=== Define the file format for encrypting files -Define if encrypted files will be written in the old format (`true`) or the new -binary format (`false`) which has a significant reduced filesize. Defaults to `false`. - -With binary, only new files are written in the binary format, existing encrypted files -in the old format stay readable. This guarantees a smooth transition. - -==== Code Sample - -[source,php] -.... -'encryption.use_legacy_encoding' => false, -.... - -=== Define the minimum supported ownCloud desktop client version -Define the minimum ownCloud desktop client version that is allowed to sync with -this server instance. All connections made from earlier clients will be denied -by the server. - -As shipped, the value here is the oldest desktop client that is technically -compatible with the server. The version number seen here does not imply official -support or test coverage on behalf of ownCloud. - -NOTE: Lowering this value may lead to unexpected behaviour, and can include data loss. - -==== Code Sample - -[source,php] -.... -'minimum.supported.desktop.version' => '3.2.1', -.... - -=== Define the suggested poll interval for clients -Specifies how often clients should poll the server for changes. - -The value is in milliseconds. The value is not enforced. -Clients may use this value to decide how frequently to check the server for -changes. - -==== Code Sample - -[source,php] -.... -'pollinterval' => 30000, -.... - -=== Define whether to include external storage in quota calculation -EXPERIMENTAL: option whether to include external storage in quota -calculation, defaults to false. - -==== Code Sample - -[source,php] -.... -'quota_include_external_storage' => false, -.... - -=== Define how often filesystem changes are detected -Specifies how often the local filesystem (the ownCloud data/ directory, and -NFS mounts in data/) is checked for changes made outside ownCloud. This -does not apply to external storages. - --> Never check the filesystem for outside changes, provides a performance -increase when it's certain that no changes are made directly to the -filesystem - --> Check each file or folder at most once per request, recommended for -general use if outside changes might happen. - -==== Code Sample - -[source,php] -.... -'filesystem_check_changes' => 0, -.... - -=== Define unsuccessful mountpoint rename attempts -This config value avoids infinite loops for seldom cases where a file renaming -conflict between different share backends could occur. - -The value defines how many unsuccessful mountpoint rename attempts are allowed. -e.g. target mountpoint name could be claimed as unused by the filesystem but -renaming to this target name will fail due to some other reasons like database -constraints. -Change this value only under supervision of ownCloud support. - -==== Code Sample - -[source,php] -.... -'filesystem.max_mountpoint_move_attempts' => 10, -.... - -=== Define where part files are located -By default ownCloud will store the part files created during upload in the -same storage as the upload target. Setting this to false will store the part -files in the root of the user's folder which might be required to work with certain -external storage setups that have limited rename capabilities. - -Note that setting this to false causes issues with the following apps: Encryption, -Document classification, Anti-Virus and Ransomware Protection. - -==== Code Sample - -[source,php] -.... -'part_file_in_storage' => true, -.... - -=== Prevent cache changes due to changes in the filesystem -When `true`, prevent ownCloud from changing the cache due to changes in the -filesystem for all storage. - -==== Code Sample - -[source,php] -.... -'filesystem_cache_readonly' => false, -.... - -=== Define ownClouds internal secret -Secret used by ownCloud for various purposes, e.g. to encrypt data. - -If you lose this string there will be data corruption. - -==== Code Sample - -[source,php] -.... -'secret' => '', -.... - -=== Define list of trusted proxy servers - -If you configure these also consider setting `forwarded_for_headers` which -otherwise defaults to `HTTP_X_FORWARDED_FOR` (the `X-Forwarded-For` header). - -==== Code Sample - -[source,php] -.... -'trusted_proxies' => [ - '203.0.113.45', - '198.51.100.128' - ], -.... - -=== Define `forwarded_for_headers` -Headers that should be trusted as client IP address in combination with -`trusted_proxies`. If the HTTP header looks like 'X-Forwarded-For', then use -'HTTP_X_FORWARDED_FOR' here. - -If set incorrectly, a client can spoof their IP address as visible to -ownCloud, bypassing access controls and making logs useless! - -If not set, defaults to 'HTTP_X_FORWARDED_FOR'. - -==== Code Sample - -[source,php] -.... -'forwarded_for_headers' => [ - 'HTTP_X_FORWARDED', - 'HTTP_FORWARDED_FOR' - ], -.... - -=== Define the maximum filesize for animated GIF´s -Max file size for animating gifs on public-sharing-site. - -If the gif is bigger, it'll show a static preview. - -Value represents the maximum filesize in megabytes. -Default is `10`. Set to `-1` for no limit. - -==== Code Sample - -[source,php] -.... -'max_filesize_animated_gifs_public_sharing' => 10, -.... - -=== Enable transactional file locking -Transactional file locking is enabled by default. - -Prevents concurrent processes from accessing the same files -at the same time. Can help prevent side effects that would -be caused by concurrent operations. Mainly relevant for -very large installations with many users working with shared files. - -==== Code Sample - -[source,php] -.... -'filelocking.enabled' => true, -.... - -=== Define the TTL for file locking -Set the lock's time-to-live in seconds. - -Any lock older than this will be automatically cleaned up. -If not set this defaults to either 1 hour or the php max_execution_time, whichever is higher. - -==== Code Sample - -[source,php] -.... -'filelocking.ttl' => 3600, -.... - -=== Define the memory caching backend for file locking - -Because most memcache backends can clean values without warning, -using redis is highly recommended to *avoid data loss*. - -==== Code Sample - -[source,php] -.... -'memcache.locking' => '\\OC\\Memcache\\Redis', -.... - -=== Disable the web based updater -The web based updater is enabled by default. - -==== Code Sample - -[source,php] -.... -'upgrade.disable-web' => false, -.... - -=== Explicitly enable the web updater - used by /updater/ -By default, it is disabled. - -==== Code Sample - -[source,php] -.... -'web-updater.enabled' => false, -.... - -=== Define whether to enable automatic update of market apps -Set to `false` to disable. - -==== Code Sample - -[source,php] -.... -'upgrade.automatic-app-update' => true, -.... - -=== Enable debugging mode for this ownCloud instance -Only enable this for local development and not in production environments -This will disable the minifier and outputs some additional debug information - -WARNING: -Be warned that, if you set this to `true`, exceptions display -stack traces on the web interface, *including passwords*, — **in plain text!**. -Furthermore the content-disposition header will be lost and thus files will be -displayed in the browser rather than downloaded. -We strongly encourage you never to use it in production. - -==== Code Sample - -[source,php] -.... -'debug' => false, -.... - -=== Define the data-fingerprint of the current data served -This is a property used by the clients to find out if a backup has been -restored on the server. Once a backup is restored run -{occ-command-example-prefix} maintenance:data-fingerprint -To set this to a new value. - -Updating/Deleting this value can make connected clients stall until -the user has resolved conflicts. - -==== Code Sample - -[source,php] -.... -'data-fingerprint' => '', -.... - -=== Define if you have copied the sample configuration -This entry is just here to show a warning in case somebody copied the sample configuration. - -WARNING: DO NOT ADD THIS SWITCH TO YOUR CONFIGURATION! - -If you, brave person, have read until here be aware that you should not -modify *ANY* settings in this file without reading the documentation. - -==== Code Sample - -[source,php] -.... -'copied_sample_config' => true, -.... - -=== Enable or disable the files_external local mount option -Set this property to true if you want to enable the files_external local mount option. - -Default: `false` - -==== Code Sample - -[source,php] -.... -'files_external_allow_create_new_local' => false, -.... - -=== Enable or disable debug logging for SMB access -Set this property to true if you want to enable debug logging for SMB access. - -==== Code Sample - -[source,php] -.... -'smb.logging.enable' => false, -.... - -=== Enable or disable async DAV extensions - -==== Code Sample - -[source,php] -.... -'dav.enable.async' => false, -.... - -=== Enable propfind depth infinity requests -Tell the clients whether `depth=infinity` is allowed for propfind requests. - -Streamed infinite depth propfind requests can reduce memory usage -with large responses. -For details see: https://datatracker.ietf.org/doc/html/rfc4918#section-10.2 - -==== Code Sample - -[source,php] -.... -'dav.propfind.depth_infinity' => false, -.... - -=== Show the grace period popup -Decide whether show or not the grace period popup. There is no change in the -behaviour of the grace period. - -==== Code Sample - -[source,php] -.... -'grace_period.demo_key.show_popup' => true, -.... - -=== Link to get a demo key during active grace period -The admin will be directed to that web page when they click on the "get a demo key" -link in the grace period popup. It's expected that the web page contains instructions -on how to get a valid demo key to be used in the ownCloud server. - -If this key isn't present, ownCloud's default will be used. - -==== Code Sample - -[source,php] -.... -'grace_period.demo_key.link' => 'https://owncloud.com/try-enterprise/', -.... - -=== Order of login policies -The order of the login policies that will be checked, if any. - -Policies must be registered in order to use / activate them. This is usually -done automatically by core or the app containing the policy. - -The names of the policies must be documented if they come from an app. -ownCloud core provides the following list of policies: - -- 'OC\Authentication\LoginPolicies\GroupLoginPolicy' - -In order to use / activate the policy, include the name in the policy -order below, such as: - -'loginPolicy.order' => ['OC\Authentication\LoginPolicies\GroupLoginPolicy'], - -Multiple policies could be used as long as they are registered (the -"SubnetPolicy" is just an example): -[source,php] -.... -'loginPolicy.order' => [ - 'OC\Authentication\LoginPolicies\GroupLoginPolicy', - 'OCA\CustomPolicies\SubnetPolicy' -], -.... - -The configuration of the policies depends on the policy itself, so they could -be configured in multiple and different ways which are not covered in detail here. - -==== Code Sample - -[source,php] -.... -'loginPolicy.order' => [], -.... - -=== Configuration of the Group Login Policy -Provide configuration for the -'OC\Authentication\LoginPolicies\GroupLoginPolicy' policy. - -The generic configuration is, 'allowOnly' and 'reject' do not need to be both present: -[source,php] -.... -'loginPolicy.groupLoginPolicy.forbidMap' => [ - '' => [ - 'allowOnly' => ['', ......, ''], - 'reject' => ['', ........, ''], - ], -], -.... - -As an example: -[source,php] -.... -'loginPolicy.groupLoginPolicy.forbidMap' => [ - 'password' => [ - 'allowOnly' => ['group1', 'group2'], - 'reject' => ['group3'], - ], -], -.... - -Each login type can have a list of groups that will be the ones -only allowed to log in using that login type, and also a list of -groups that will be rejected from using that login type. -Note that this applies to users belonging to those groups. If a user -is member of an "allowOnly" group and also of a "reject" group, -the "reject" will take priority, so the user won't be able to log in -using that login type. - -List of known login types: -[source,plaintext] -.... -- 'password' -> for the login page and basic auth (like for webdav) -- 'token' -> for app passwords - using an app password in the login page will - be considered as 'token' login type, not 'password'. - -Types from different apps which have to be installed first: -- 'apache' -> for the 'user_shibboleth' app - (data comes from the apache server) -- 'OCA\OAuth2\AuthModule' -> for oAuth2 -- 'OCA\OpenIdConnect\OpenIdConnectAuthModule' -> for openidconnect -- 'OCA\Kerberos\AuthModule' -> for kerberos -.... - -In some rare circumstances, the login type could be the empty string. -This could happen in earlier versions of the openidconnect app when using the web UI. - -==== Code Sample - -[source,php] -.... -'loginPolicy.groupLoginPolicy.forbidMap' => [], -.... - -=== Enable Sending Telemetry Reports for Enterprise Customers -Telemetry data is a subset of the config report as produced by the command `occ configreport:generate`. - -* If set to true and an enterprise license key is installed, a daily telemetry report is sent to https://telemetry.owncloud.com/oc10-telemetry -* If set to false or the configreport app is disabled, no telemetry reports are sent - -Default: true -For community servers (without a license key) telemetry reports are never sent. - -==== Code Sample - -[source,php] -.... -'telemetry.enabled' => true, -.... - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/custom_client_repos.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/custom_client_repos.adoc deleted file mode 100644 index b0b37c8..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/custom_client_repos.adoc +++ /dev/null @@ -1,32 +0,0 @@ -= Custom Client Download Repositories - -You may configure the URLs to your own download repositories for your -ownCloud desktop clients and mobile apps in config/config.php. This -example shows the default download locations: - -[source,php] ----- - "https://owncloud.com/desktop-app/", - "customclient_android" => "https://play.google.com/store/apps/details?id=com.owncloud.android", - "customclient_ios" => "https://itunes.apple.com/us/app/owncloud/id543672169?mt=8", ----- - -Simply replace the URLs with the links to your own preferred download -repos. - -You may test alternate URLs without editing config/config.php by setting -a test URL as an environment variable: - -[source,bash] ----- -export OCC_UPDATE_URL=https://test.example.com ----- - -When you’re finished testing you can disable the environment variable: - -[source,bash] ----- -unset OCC_UPDATE_URL ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/email_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/email_configuration.adoc deleted file mode 100644 index bea107c..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/email_configuration.adoc +++ /dev/null @@ -1,372 +0,0 @@ -= Email Configuration -:toc: right -:expermimental: -:page-aliases: go/admin-email.adoc - -== Introduction - -ownCloud is capable of sending emails for a range of reasons. These include: - -* Password reset emails -* Notifying users of new file shares -* Changes in files -* Activity notifications - -To make use of them, users need to configure which notifications they want to receive. They can do this on their Personal pages. - -NOTE: To be able to send emails, a functioning mail server must be available, whether locally in your network, or remotely. - -== The Graphical Email Configuration Wizard - -The wizard supports two mail server types: _SMTP_ and _PHP_. Use SMTP for a remote email server, and PHP when your mail server is on the same machine as ownCloud. - -In most cases the `smtp` option is best, because it removes the extra step of passing through PHP, and you can control all of your mail server options in one place, in your ownCloud's email server configuration. - -=== Configuring an SMTP Server - -To configure ownCloud to interact with an SMTP server, you can either update `config/config.php` by hand, or use the xref:the-graphical-email-configuration-wizard[Graphical Email Configuration Wizard], which updates `config/config.php` for you. - -You need the following information from your email server administrator to connect ownCloud to a remote SMTP server: - -* Encryption type: `None`, `SSL/TLS` or `STARTTLS`. -* The From address you want your outgoing ownCloud mails to use. -* Whether authentication is required. -* Authentication method: `None`, `Login`, `Plain`, or `NT LAN Manager`. -* The server’s IP address or fully-qualified domain name (FQDN). -* Login credentials, if required. - -image:configuration/server/email-configuration/smtp-config-smtp.png[image] - -Your changes are saved immediately. - -You must enter a valid email address to which a test email will be sent. This field is mandatory and will be prefilled with the logged-in admin's email if set, but can be changed to any other valid email address. Note that this test recipient address can't be set via a config value in `config.php`. Click the btn:[Send Email] button to test your configuration. This sends a test message to the email address you configured. The test message says: - ----- -If you received this email, the settings seem to be correct. - --- -ownCloud -web services under your control ----- - -=== Configuring PHP for sending Emails - -To configure PHP select it and enter your desired return address. - -image:configuration/server/email-configuration/smtp-config-php.png[image] - -Same as with the SMTP configuration above, you must enter an email address to which a test email will be sent when testing the configuration. For details see the section above. - -NOTE: PHP mode uses your local `sendmail` binary and any drop-in Sendmail replacement such as Postfix, Exim, or Courier. All of these include a `sendmail` binary, and are freely interchangeable. Use this if you want to use `php.ini` to control some of your mail server functions, such as setting _paths_, _headers_, or passing extra command options to the `sendmail` binary. These vary depending on which server you are using, so consult your server’s documentation to see what your options are. - -== Setting Mail Server Parameters via config.php - -If you prefer, you may set your email server parameters directly in `config/config.php`. - -=== Supported SMTP sending modes - -* xref:configuration/server/email_configuration.adoc#smtp[SMTP] -* xref:configuration/server/email_configuration.adoc#php-mail[PHP Mail] - -IMPORTANT: Compatibility of _sending modes_ might depend on the installation environment. In case of problems with a _sending mode_, it is recommended to try other mode configurations. - -==== SMTP - -If you want to send email using a local or remote SMTP server it is necessary to enter the name or IP address of the server, optionally followed by a colon and port number, e.g. *:425*. If this value is not given the default port `25/tcp` will be used unless you change that by modifying the *mail_smtpport* parameter. Multiple servers can be entered, separated by semicolons: - -[source,php] ----- -'mail_smtpmode' => 'smtp', -'mail_smtphost' => 'smtp-1.server.dom;smtp-2.server.dom:425', -'mail_smtpport' => 25, ----- - -Or: - -[source,php] ----- -'mail_smtpmode' => 'smtp', -'mail_smtphost' => 'smtp.server.dom', -'mail_smtpport' => 425, ----- - -If a malware or SPAM scanner is running on the SMTP server it might be necessary that you increase the SMTP timeout to e.g., 30s: - -[source,php] ----- -'mail_smtptimeout' => 30, ----- - -If the SMTP server accepts insecure connections, the default setting can be used: - -[source,php] ----- -'mail_smtpsecure' => '', ----- - -If the SMTP server only accepts secure connections you can choose between the following two variants: - -SSL/TLS -+++++++ - -A secure connection will be initiated using SSL/TLS via SMTPS on the default port `465/tcp`: - -[source,php] ----- -'mail_smtphost' => 'smtp.server.dom:465', -'mail_smtpsecure' => 'ssl', ----- - -STARTTLS -++++++++ - -A secure connection will be initiated using STARTTLS via SMTP on the default port `25/tcp`: - -[source,php] ----- -'mail_smtphost' => 'smtp.server.dom', -'mail_smtpsecure' => 'tls', ----- - -An alternative is the port `587/tcp` (recommended): - -[source,php] ----- -'mail_smtphost' => 'smtp.server.dom:587', -'mail_smtpsecure' => 'tls', ----- - -Authentication -++++++++++++++ - -And finally it is necessary to configure if the SMTP server requires authentication, if not, the default values can be taken as is. - -[source,php] ----- -'mail_smtpauth' => false, -'mail_smtpname' => '', -'mail_smtppassword' => '', ----- - -If SMTP authentication is required you have to set the required username and password and can optionally choose between the authentication types *LOGIN* (default) or *PLAIN*. - -[source,php] ----- -'mail_smtpauth' => true, -'mail_smtpauthtype' => 'LOGIN', -'mail_smtpname' => 'username', -'mail_smtppassword' => 'password', ----- - -==== PHP Mail - -If you want to use PHP mail it is necessary to have an installed and working email system on your server. Which program in detail is used to send email is defined by the configuration settings in the *php.ini* file. On *nix systems this will most likely be Sendmail. ownCloud should be able to send email out of the box. - -[source,php] ----- -'mail_smtpmode' => 'php', -'mail_smtphost' => '127.0.0.1', -'mail_smtpport' => 25, -'mail_smtptimeout' => 10, -'mail_smtpsecure' => '', -'mail_smtpauth' => false, -'mail_smtpauthtype' => 'LOGIN', -'mail_smtpname' => '', -'mail_smtppassword' => '', ----- - -== Send a Test Email - -Regardless of how you have configured ownCloud to interact with an email server, to test your email configuration, save your email address in your personal settings and then use the *Send email* button in the _Email Server_ section of the Admin settings page. - -== Using Self-Signed Certificates - -When using self-signed certificates on the remote SMTP server, the certificate must be imported into ownCloud. Please refer to xref:configuration/server/import_ssl_cert.adoc[Importing System-wide and Personal SSL Certificates] for more information. - -== Troubleshooting - -If you are unable to send email, try turning on debugging. Do this by enabling the `mail_smtpdebug parameter` in `config/config.php`. - -[source,php] ----- -'mail_smtpdebug' => true, ----- - -NOTE: Immediately after pressing the *Send email* button, as described before, several *SMTP -> get_lines(): …* messages appear on the screen. This is expected behavior and can be ignored. - -=== Why is my web domain different from my mail domain? - -The default domain name used for the sender address is the hostname where your ownCloud installation is served. If you have a different mail domain name you can override this behavior by setting the following configuration parameter: - -[source,php] ----- -'mail_domain' => 'example.com', ----- - -This setting results in every email sent by ownCloud (for example, the password reset email) having the domain part of the sender address appear as follows - ----- -no-reply@example.com ----- - -=== How can I find out if an SMTP server is reachable? - -Use the ping command to check the server availability - -[source,bash] ----- -ping smtp.server.dom ----- - ----- -PING smtp.server.dom (ip-address) 56(84) bytes of data. -64 bytes from your-server.local.lan (192.168.1.10): icmp_req=1 ttl=64 time=3.64ms ----- - -=== How can I find out if the SMTP server is listening on a specific TCP port? - -The best way to get mail server information is to ask your mail server admin. If you are the mail server admin, or need information in a hurry, you can use the `netstat` command. This example shows all active servers on your system, and the ports they are listening on. The SMTP server is listening on localhost port 25. - -[source,bash] ----- -netstat -pant ----- - -[source,bash,subs="attributes+"] ----- -Active Internet connections (servers and established) -Proto Recv-Q Send-Q Local Address Foreign Address State ID/Program name -tcp 0 0 0.0.0.0:631 0.0.0.0:* LISTEN 4418/cupsd -tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 2245/exim4 -tcp 0 0 127.0.0.1:{std-port-mysql} 0.0.0.0:* LISTEN 1524/mysqld ----- - -* 25/tcp is unencrypted smtp -* 110/tcp/udp is unencrypted pop3 -* 143/tcp/udp is unencrypted imap4 -* 465/tcp is encrypted smtps -* 993/tcp/udp is encrypted imaps -* 995/tcp/udp is encrypted pop3s - -=== How can I determine if the SMTP server supports SMTPS? - -A good indication that the SMTP server supports SMTPS is that it is -listening on port *465*. - -=== How can I determine what authorization and encryption protocols the mail server supports? - -SMTP servers usually announce the availability of STARTTLS immediately after a connection has been established. You can easily check this using the `telnet` command. - -NOTE: You must enter the marked lines to obtain the information displayed. - -[source,bash] ----- -telnet smtp.domain.dom 25 ----- - ----- -Trying 192.168.1.10... -Connected to smtp.domain.dom. -Escape character is '^]'. -220 smtp.domain.dom ESMTP Exim 4.80.1 Tue, 22 Jan 2013 22:39:55 +0100 -EHLO your-server.local.lan # <<< enter this command -250-smtp.domain.dom Hello your-server.local.lan [ip-address] -250-SIZE 52428800 -250-8BITMIME -250-PIPELINING -250-AUTH PLAIN LOGIN CRAM-MD5 # <<< Supported auth protocols -250-STARTTLS # <<< Encryption is supported -250 HELP -QUIT # <<< enter this command -221 smtp.domain.dom closing connection -Connection closed by foreign host. ----- - -== Enabling Debug Mode - -If you are unable to send email, it might be useful to activate further debug messages by enabling the `mail_smtpdebug` parameter: - -[source,php] ----- -'mail_smtpdebug' => true, ----- - -NOTE: Immediately after pressing the btn:[Send email] button, as described before, several *SMTP -> get_lines(): …* messages appear on the screen. This is expected behavior and can be ignored. - -== Using Email Templates - -NOTE: You have to install and enable a custom theme in order to use and customize email templates. - -Most emails sent from ownCloud are based on editable email templates, which are a mixture of PHP and HTML. The currently available templates are: - -[cols="40%,15%,40%,50%",options="header",] -|======================================================================= -| Email -| Format -| Description -| File Location - -| Activity notification mail -| plain text -| Notification of activities that users have enabled in the Notifications section of their Personal pages. -| `core/templates/mail.php` - -| Lost password mail -| HTML -| Password reset email for users who lose their passwords. -| `core/templates/lostpassword/email.php` - -| New user email -| HTML -| -| `settings/templates/email.new_user.php` - -| -| plain text -| -| `settings/templates/email.new_user_plain_text.php` - -| Public link share email -| HTML -| Notify users of new public link shares. -| `core/templates/mail.php` - -| -| plain text -| -| `core/templates/altmail.php` - -| New file share email -| HTML -| Notify users of new file shares. -| `core/templates/internalmail.php` - -| -| plain text -| -| `core/templates/internalaltmail.php` -|======================================================================= - -The templates are written in PHP and HTML, and are already loaded with the relevant variables such as _username_, _share links_, and _filenames_. You can, if you are careful, edit these — even without knowing PHP or HTML. Don’t touch any of the code, but it’s OK to edit the text portions of the messages. - -For example, this the lost password mail template: - -[source,php] ----- -t('Use the following link to reset your password: {link}') -); ----- - -You could change the text portion of the template, `Use the following link to reset your password:` to say something else, such as: - ----- -Click the following link to reset your password. -If you did not ask for a password reset, ignore this message. ----- - -Again, be very careful to change nothing but the message text, because the tiniest coding error will break the template. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/config_sample_php_parameters/default-config-sample-mariadb.php b/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/config_sample_php_parameters/default-config-sample-mariadb.php deleted file mode 100644 index d5489b4..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/config_sample_php_parameters/default-config-sample-mariadb.php +++ /dev/null @@ -1,21 +0,0 @@ - 'oc8c0fd71e03', - 'passwordsalt' => '515a13302a6b3950a9d0fdb970191a', - 'trusted_domains' => [ - 0 => 'localhost', - 1 => 'studio', - 2 => '192.168.10.155' - ], - 'datadirectory' => '/var/www/owncloud/data', - 'dbtype' => 'mysql', - 'version' => '7.0.2.1', - 'dbname' => 'owncloud', - 'dbhost' => 'localhost', - 'dbtableprefix' => 'oc_', - 'dbuser' => 'oc_carla', - 'dbpassword' => '67336bcdf7630dd80b2b81a413d07', - 'installed' => true, - 'operation.mode' => 'single-instance', -]; diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/config_sample_php_parameters/default-config-sample-sqlite.php b/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/config_sample_php_parameters/default-config-sample-sqlite.php deleted file mode 100644 index c814649..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/config_sample_php_parameters/default-config-sample-sqlite.php +++ /dev/null @@ -1,16 +0,0 @@ - 'occ6f7365735', - 'passwordsalt' => '2c5778476346786306303', - 'trusted_domains' => [ - 0 => 'localhost', - 1 => 'studio', - ], - 'datadirectory' => '/var/www/owncloud/data', - 'dbtype' => 'sqlite3', - 'version' => '7.0.2.1', - 'installed' => true, - 'operation.mode' => 'single-instance', -]; - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/reverse_proxy_configuration/multiple-domains-reverse-ssl-proxy.php b/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/reverse_proxy_configuration/multiple-domains-reverse-ssl-proxy.php deleted file mode 100644 index c8d5c62..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/examples/reverse_proxy_configuration/multiple-domains-reverse-ssl-proxy.php +++ /dev/null @@ -1,9 +0,0 @@ - ['10.0.0.1'], - "overwritehost" => "ssl-proxy.tld", - "overwriteprotocol" => "https", - "overwritewebroot" => "/domain.tld/owncloud", - "overwritecondaddr" => "^10\.0\.0\.1$", -]; diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/excluded_blacklisted_files.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/excluded_blacklisted_files.adoc deleted file mode 100644 index a26b153..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/excluded_blacklisted_files.adoc +++ /dev/null @@ -1,146 +0,0 @@ -= Excluding Directories and Blacklisting Files -:toc: right - -== Introduction - -This document describes how to manage blacklisted files and excluded directories. - -== Definitions of terms - -Blacklisted:: -Files that may harm the ownCloud environment like a foreign `.htaccess` file. -Blacklisting prevents anyone from uploading blacklisted files to the ownCloud server. - -Excluded:: -Existing directories on your ownCloud server, including directories on external storage mounts, -that are excluded from being processed by ownCloud. In effect they are invisible to ownCloud. - -Both types are defined in `config.php`. Blacklisted files and excluded directories are not scanned -by ownCloud, not viewed, not synced, and cannot be created, renamed, deleted, or accessed via direct -path input from a file manager. Even when a filepath is entered manually via a file explorer, -the path cannot be accessed. - -For example configurations please see the -xref:configuration/server/config_sample_php_parameters.adoc[config.sample.php] file. - -[NOTE] -==== -Many filesystems do not allow the coexistence of a file and folder with exactly the same name on the same -directory level. Therefore no differentiation is made in processing files and folders for blacklisting or -excluding, as it would just return a deny at a later stage. With the implementation made, you get an immediate -error message. - -Example: The storage backend has a reserved directory name ".snapshot" which is excluded by configuration. -If you try to add a file or folder via the browser or sync a file or folder from the client named ".snapshot", -you will get an immediate ownCloud triggered deny. -==== - -== Impact on System Performance - -If you have a filesystem mounted with 200,000 files and directories and 15 snapshots in rotation, you would -now scan and process 200,000 elements plus 200,000 x 15 = 3,000,000 elements additionally. These additional -3,000,000 elements, 15 times more than the original quantity, would also be available for viewing and -synchronisation. Because this is a big and unnecessary overhead, most times confusing to clients, further -processing can be eliminated by using excluded directories. - -== Blacklisted Files - -By default, ownCloud blacklists the file `.htaccess` to secure the running instance, which is important -when using Apache as webserver. A foreign `.htaccess` file could overwrite rules defined by ownCloud. -There is no explicit need to enter the file name `.htaccess` as parameter to the `blacklisted_files` array -in `config.php`, but you can add more blacklisted file names if necessary. You can also prevent uploading, -e.g., Outlook .pst files, with this mechanism to avoid massive backend space allocation. - -== Excluded Directories - -=== Reasons for Excluding Directories - -. Enterprise storage systems, or special filesystems like ZFS and BtrFS are capable of snapshots. - These snapshots are directories and keep point-in-time views of the data -.. Snapshot directories are read-only -.. There is no common naming convention for these directories, and there most likely will never be. - For example, NetApp uses `.snapshot` and `~snapshot`, EMC e.g., `.ckpt`, HDS e.g., `.latest` and `~latest`, - and the ZFS filesystem uses `.zfs` -.. It does not make sense for these directories to be visible to users as they are used to ease backup, - restoration, and cloning -. Directories which are part of the mounted filesystem, but must not be user accessible/visible -. Manual managed but user invisible backup directories - -*Example:* - -If you have a snapshot-capable storage or filesystem where snapshots are enabled and presented to clients, -each directory will contain a "special" visible directory named e.g. `.snapshot`. Depending on the -system, you may find underneath a list of snapshots taken and in the next lower level the complete set of -files and directories which were present when the snapshot was created. In most systems, this mechanism -is true in all directory levels: - ----- -/.snapshot - /nightly.0 - /home - /dat - /pictures - file_1 - file_2 - /nightly.1 - /home - /dat - /pictures - file_1 - file_2 - /nightly.2 - /home - /dat - /pictures - file_1 - file_2 - ... -/home -/dat -/pictures -file_1 -file_2 -... ----- - -Example `excluded_directories` entries in `config.php` can look like this: - -[source,php] ----- -'excluded_directories' => [ - '.snapshot', - '~snapshot', - 'dir1', - 'dir2', -], ----- - -Note that these are not pathnames, but directory names without any -slashes. Excluding `dir1` excludes: - ----- -/home/dir1 -/etc/stuff/dir1 ----- - -But not: - ----- -/home/.dir1 -/etc/stuff/mydir1 ----- - -=== Reasons for Blacklisting Files - -The reason for blacklisting files can be explained based on the example of a `.htaccess` file. -Such a file can lead to a unwanted behaviour of your webserver when visible to ownCloud in a directory. - -Example `blacklisted_files` entries in `config.php` can look like this: - -[source,php] ----- -'blacklisted_files' => [ - 'hosts', - 'evil_script.sh', -], ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/external_sites.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/external_sites.adoc deleted file mode 100644 index 44b9779..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/external_sites.adoc +++ /dev/null @@ -1,51 +0,0 @@ -= Linking External Sites - -You can embed external Web sites inside your ownCloud pages with the -External Sites app, as this screenshot shows. - -image:external-sites-1.png[Click to enlarge] - -This is useful for quick access to important Web pages such as the -ownCloud manuals and informational pages for your company, and for -presenting external pages inside your custom ownCloud branding, if you -use your own custom themes. - -The External sites app is included in all versions of ownCloud. Go to -*Apps > Not Enabled* to enable it. Then go to your ownCloud Admin page -to create your links, which are saved automatically. There is a dropdown -menu to select an icon, but there is only one default icon so you don’t -have to select one. Hover your cursor to the right of your links to make -the trashcan icon appear when you want to remove them. - -image:external-sites-2.png[Click to enlarge] - -The links appear in the ownCloud dropdown menu on the top left after -refreshing your page, and have globe icons. - -image:external-sites-3.png[image] - -Your links may or may not work correctly due to the various ways that -Web browsers and Web sites handle HTTP and HTTPS URLs, and because the -External Sites app embeds external links in IFrames. Modern Web browsers -try very hard to protect Web surfers from dangerous links, and safety -apps like https://www.eff.org/privacybadger[Privacy Badger] and -ad-blockers may block embedded pages. It is strongly recommended to -enforce HTTPS on your ownCloud server; do not weaken this, or any of -your security tools, just to make embedded Web pages work. After all, -you can freely access them outside of ownCloud. - -Most Web sites that offer login functionalities use the -`X-Frame-Options` or `Content-Security-Policy` HTTP header which -instructs browsers to not allow their pages to be embedded for security -reasons (e.g. "Clickjacking"). You can usually verify the reason why -embedding the website is not possible by using your browser’s console -tool. For example, this page has an invalid SSL certificate. - -image:external-sites-4.png[image] - -On this page, X-Frame-Options prevents the embedding. - -image:external-sites-5.png[image] - -There isn’t much you can do about these issues, but if you’re curious -you can see what is happening. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/harden_server.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/harden_server.adoc deleted file mode 100644 index e9c77d1..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/harden_server.adoc +++ /dev/null @@ -1,461 +0,0 @@ -= Hardening and Security Guidance -:toc: right -:page-aliases: go/admin-security.adoc, \ -go/use-https.adoc, \ -go/enable-http-strict-transport-security.adoc - -== Introduction - -ownCloud aims to ship with secure defaults that do not need to get -modified by administrators. However, in some cases some additional -security hardening can be applied in scenarios were the administrator -has complete control over the ownCloud instance. This page assumes that -you run ownCloud Classic on Apache2 in a Linux environment. - -NOTE: ownCloud will warn you in the administration interface if some critical security-relevant options are missing. -However, it is still up to the server administrator to review and maintain system security. - -== Limit on Password Length - -ownCloud uses the https://en.m.wikipedia.org/wiki/Bcrypt[bcrypt] -algorithm. It only verifies the -first 72 characters of passwords. This applies to all passwords you -use in ownCloud: user passwords, passwords on link shares and passwords -on external shares. - -== Rate Limiting - -Currently ownCloud deliberately does not provide any form of rate-limiting (though it does provide {oc-marketplace-url}/apps/brute_force_protection[brute-force protection]). -This is because ownCloud needs to integrate in to a diverse range of environments and infrastructure, which often already provide specialized rate-limiting solutions, e.g., _Apache_, _HAProxy_, and _F5_. - -If you are yet to implement a rate-limiting solution for your ownCloud instance, start by retrieving a list of all active routes. -This information is obtained by running xref:configuration/server/occ_command.adoc#security[occ's security:routes command], as in the following example. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} security:routes ----- - -It should print a list of all the routes as in the following truncated example. - -[source,plaintext] ----- -+-----------------------------------------------------------+-----------------+ -| Path | Methods | -+-----------------------------------------------------------+-----------------+ -| /apps/encryption/ajax/adminRecovery | POST | -| /apps/encryption/ajax/changeRecoveryPassword | POST | -| /apps/encryption/ajax/getStatus | GET | -| /apps/encryption/ajax/setEncryptHomeStorage | POST | -| /apps/encryption/ajax/updatePrivateKeyPassword | POST | -| /apps/encryption/ajax/userSetRecovery | POST | -| /apps/federatedfilesharing/ | GET | -| /apps/federatedfilesharing/notifications | POST | -+-----------------------------------------------------------+-----------------+ ----- - -With this information, you can begin customizing a rate-limiting solution specific to your ownCloud installation. - -=== Further Reading - -* Rate limiting with Apache -** https://github.com/jzdziarski/mod_evasive[mod_evasive] -** https://httpd.apache.org/docs/2.4/mod/mod_ratelimit.html[mod_ratelimit] -** https://johnleach.co.uk/words/2012/05/15/rate-limiting-with-apache-and-mod-security/[mod_security] -** Rate limiting with https://www.fail2ban.org/wiki/index.php/Main_Page[Fail2Ban] -** https://centos.tips/fail2ban-behind-a-proxyload-balancer/[Fail2Ban Behind A Proxy/Load Balancer] -* https://gist.github.com/procrastinatio/6b6579230d99be5bfa26d04acd788e7a[Rate limiting with HAProxy] -* https://www.fir3net.com/Loadbalancers/F5-BIG-IP/f5-ltm-ratelimiting.html[Rate limiting with F5] - -== Operating System - -=== Enable hardening modules such as SELinux - -We also recommend to enable hardening modules such as SELinux -where possible. See xref:installation/selinux_configuration.adoc[SELinux Configuration] to learn more about SELinux. - -== Database - -When using MySQL or MariaDB, enable the https://mariadb.com/docs/skysql-dbaas/ref/xpand/sql-modes/STRICT_TRANS_TABLES/#Setting_the_SQL_MODE[STRICT_TRANS_TABLES, window=_blank] if it is not already activated. - -. Check the status of `STRICT_TRANS_TABLES`: -+ --- -To check if `STRICT_TRANS_TABLES` are enabled, enter the following command: Note that the MySQL command-line client must be installed and configured. Alternatively, you can use a GUI, such as phpMyAdmin, to issue SQL commands. - -[source,bash] ----- -sudo mysql ----- - -Select the database. The example command uses `owncloud` as the database name: - -[source,sql] ----- -use owncloud; ----- - -Finally, check whether `STRICT_TRANS_TABLES` is enabled by issuing the following command: - -[source,sql] ----- -SELECT @@sql_mode; ----- - -If you see an output like this: - -[source,plaintext] ----- -+-------------------------------------------------------------------------------------------+ -| @@sql_mode | -+-------------------------------------------------------------------------------------------+ -| STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION | -+-------------------------------------------------------------------------------------------+ -1 row in set (0.000 sec) ----- - -and it contains STRICT_TRANS_TABLES, no further action is required. Otherwise, follow the next list item to enable it. --- - -. Enable `STRICT_TRANS_TABLES` for the selected database: -+ --- -In the same `mysql` command line client and with the owncloud database selected, run the following command: - -[source,sql] ----- -SET sql_mode = CONCAT(@@sql_mode, ',STRICT_TRANS_TABLES'); ----- - -To verify that it is enabled, enter the following command: - -[source,sql] ----- -SELECT @@sql_mode; ----- - -and check the output. --- - -== Deployment - -=== Place data directory outside of the web root - -A simple but efficient way to increase the security of your data is to place your `data` directory outside of the Web root (i.e. outside of `/var/www`), ideally at the time of installation. - -=== Disable preview image generation - -ownCloud is able to generate preview images of common file types such as -images or text files. By default, the preview generation for some file -types that we consider secure enough for deployment is enabled. However, administrators should be aware that these previews are -generated using PHP libraries written in C which might be vulnerable to -attack vectors. - -For high security deployments, we recommend disabling the preview -generation by setting the `enable_previews` switch to `false` in -`config.php`. As administrator you are also able to manage which -preview providers are enabled by modifying the `enabledPreviewProviders` -option switch. - -== Use HTTPS - -Using ownCloud without an encrypted HTTPS connection opens up your -server to a man-in-the-middle (MITM) attack and risks the interception -of user data and passwords. It is a best practice, and highly -recommended, to always use HTTPS on production servers and to never -allow unencrypted HTTP. - -For information on how to setup HTTPS, consult the documentation of your Web server. The following examples -apply to Apache. - -=== Redirect all unencrypted traffic to HTTPS - -To redirect all HTTP traffic to HTTPS, administrators are encouraged to -issue a permanent redirect using the 301 status code. Using Apache, -this can be achieved by adding a setting such as the following in the -Apache VirtualHosts configuration containing the `` -entry: - -[source,apache] ----- -Redirect permanent / https://example.com/ ----- - -=== Enable HTTP Strict Transport Security - -While redirecting all traffic to HTTPS is good, it may not completely -prevent man-in-the-middle attacks. Therefore we recommend -setting the HTTP Strict Transport Security header, which instructs browsers -to not allow any connection to the ownCloud instance using HTTP, and it -attempts to prevent site visitors from bypassing invalid certificate -warnings. - -This can be achieved by adding the following settings in the Apache -VirtualHost file containing the `` entry: - -[source,apache] ----- - - Header always set Strict-Transport-Security "max-age=15552000; includeSubDomains" - ----- - -If you don’t have access to your Apache configuration, it is also -possible to add this to the main `.htaccess` file shipped with ownCloud. -Make sure you’re adding it below the line: - ----- -#### DO NOT CHANGE ANYTHING ABOVE THIS LINE #### ----- - -This example configuration will make all subdomains only accessible via -HTTPS. If you have subdomains not accessible via HTTPS, remove -`includeSubDomains`. - -NOTE: This requires the `mod_headers` extension in Apache. - -=== Proper SSL configuration - -Default SSL configurations by Web servers are often not -state-of-the-art and require fine-tuning for an optimal performance and -security. The available SSL ciphers and options depend -completely on your environment, therefore we can't provide a general recommendation. - -However, We do recommend using the -https://mozilla.github.io/server-side-tls/ssl-config-generator/[Mozilla SSL Configuration Generator] -to generate a configuration suitable for your environment, and the free -https://www.ssllabs.com/ssltest/[Qualys SSL Labs Tests] gives good -guidance on whether your SSL server is correctly configured. - -Also ensure that HTTP compression is disabled to mitigate the BREACH -attack. - -== Use a dedicated domain for ownCloud - -Administrators are encouraged to install ownCloud on a dedicated domain -such as `cloud.domain.tld` instead of `domain.tld` to benefit -from the same-origin policy. - -== Ensure that your ownCloud instance is installed in a DMZ - -As ownCloud supports features such as Federated File Sharing, we do not -consider Server Side Request Forgery (SSRF) a threat. Given all our external storage adapters, this can be considered a feature and not a vulnerability. - -This means that a user on your ownCloud instance could probe whether -other hosts are accessible from the ownCloud network. If you do not want -this, you need to ensure that your ownCloud is installed in a -segregated network and proper firewall rules are in place. - -== Use of Security-Related Headers on the Web server - -Basic security headers are provided by ownCloud already in a default -environment. These include: - -`X-Content-Type-Options: nosniff`:: -Instructs some browsers to not sniff the MIME type of files. This is used for example to prevent browsers from interpreting text files as JavaScript. - -`X-XSS-Protection: 0`:: -The cross-site scripting filter is deprecated and not used in modern browsers anymore. - -`X-Robots-Tag: none`:: -Instructs search engines to not index these pages. - -`X-Frame-Options: SAMEORIGIN`:: -Prevents embedding of the ownCloud instance within an iframe on other domains to prevent clickjacking and similar attacks. - -These headers are hard-coded into the ownCloud server and need no -intervention by the server administrator. - -For optimal security, administrators are encouraged to let the Web server deliver these -HTTP headers. To do this, configure Apache to use the `.htaccess` file and enable the -following Apache modules: - -* `mod_headers` -* `mod_env` - -Verify this security change by accessing a static resource and check the above mentioned security headers are delivered. - -== Use Fail2ban - -Another approach to hardening ownCloud server -is to use an intrusion detection system. An excellent -one is https://www.fail2ban.org/wiki/index.php/Main_Page[Fail2ban]. -Fail2ban is designed to protect servers from brute force attacks. It -works by scanning log files (such as those for _ssh_, _web_, _mail_, -and _log_ servers) for certain patterns, specific to each server, and -taking actions should those patterns be found. - -Actions include banning the IP from which the detected actions originate. This makes the process more difficult and prevents DDOS-style attacks. However, after a predefined time -period, the banned IP is usually unbanned again. - -This helps if the login attempts were genuine, so that users don’t lock -themselves out permanently. An example of such an action is users -attempting to brute force log in to a server via ssh. In this case, -Fail2ban would look for something similar to the following in -`/var/log/auth.log`: - ----- -Mar 15 11:17:37 yourhost sshd[10912]: input_userauth_request: invalid user audra [preauth] -Mar 15 11:17:37 yourhost sshd[10912]: pam_unix(sshd:auth): check pass; user unknown -Mar 15 11:14:51 yourhost sshd[10835]: PAM 2 more authentication failures; logname= uid=0 euid=0 tty=ssh ruser= rhost=221.194.44.231 user=root -Mar 15 11:14:57 yourhost sshd[10837]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=221.194.44.231 user=root -Mar 15 11:14:59 yourhost sshd[10837]: Failed password for root from 221.194.44.231 port 46838 ssh2 -Mar 15 11:15:04 yourhost sshd[10837]: message repeated 2 times: [ Failed password for root from 221.194.44.231 port 46838 ssh2] -Mar 15 11:15:04 yourhost sshd[10837]: Received disconnect from 221.194.44.231: 11: [preauth] ----- - -NOTE: If you’re not familiar with what’s going on, this snippet highlights a number of failed login attempts. - -=== Using Fail2ban to secure an ownCloud login - -On Ubuntu, you can install Fail2ban using the following commands: - -[source,bash] ----- -apt update && apt upgrade -apt install fail2ban ----- - -Fail2ban installs several default filters for _Apache_ and -various other services, but none for ownCloud. Given that, we have to -define our own filter. To do so, you first need to make sure that -ownCloud uses your local timezone for writing log entries; otherwise, -fail2ban cannot react appropriately to attacks. To do this, edit your -`config.php` file and add the following line: - -[source,php] ----- -'logtimezone' => 'Europe/Berlin', ----- - -NOTE: Adjust the timezone to the one that your server is located in, based on -{php-net-url}/manual/en/timezones.php[PHP’s list of supported timezones]. - -This change takes effect as soon as you save `config.php`. You can test -the change by: - -1. entering false credentials at your ownCloud login screen, then -2. checking the timestamp of the resulting entry in ownCloud’s log -file. - -Next, define a new Fail2ban filter rule for ownCloud. To do so, create a -new file called `/etc/fail2ban/filter.d/owncloud.conf`, and insert the -following configuration: - -[source,conf] ----- -[Definition] -failregex={.*Login failed: \'.*\' \(Remote IP: \'\'\)"} -ignoreregex = ----- - -This filter needs to be loaded when Fail2ban starts, so a further -configuration entry is required to be added in -`/etc/fail2ban/jail.d/defaults-debian.conf`, which you can see below: - -[source,conf] ----- -[owncloud] -enabled = true -port = 80,443 -protocol = tcp -filter = owncloud -maxretry = 3 -bantime = 10800 -logpath = /var/owncloud_data/owncloud.log ----- - -This configuration: - -1. Enables the filter rules for TCP requests on ports 80 and 443. -2. Bans IPs for 10800 seconds (3 hours). -3. Sets the path to the log file to analyze for malicious logins - -NOTE: The most important part of the configuration is the `logpath` parameter. -If this does not point to the correct log file, Fail2ban will either not work properly or refuse to start. - -After saving the file, restart Fail2ban by running the following command: - -[source,bash] ----- -service fail2ban restart ----- - -To test that the new ownCloud configuration has been loaded, use the -following command: - -[source,bash] ----- -fail2ban-client status ----- - -If "owncloud" is listed in the console output, the filter is both -loaded and active. If you want to test the filter, run the following -command, adjusting the path to your `owncloud.log` if necessary: - -[source,bash] ----- -fail2ban-regex /var/owncloud_data/owncloud.log /etc/fail2ban/filter.d/owncloud.conf ----- - -The output will look similar to the following if you had one failed -login attempt: - -[source,bash] ----- -fail2ban-regex /var/www/owncloud_data/owncloud.log /etc/fail2ban/filter.d/owncloud.conf - -Running tests -============= - -Use failregex file : /etc/fail2ban/filter.d/owncloud.conf -Use log file : /var/www/owncloud_data/owncloud.log - -Results -======= - -Failregex: 1 total -|- #) [# of hits] regular expression -| 1) [1] {.*Login failed: \'.*\' \(Remote IP: \'\'\)"} -`- - -Ignoreregex: 0 total - -Date template hits: -|- [# of hits] date format -| [40252] ISO 8601 -`- - -Lines: 40252 lines, 0 ignored, 1 matched, 40251 missed ----- - -The `Failregex` counter increases in increments of 1 for every failed login attempt. -To unban an IP locked either during testing or -unintentionally, use the following command: - -[source,bash] ----- -fail2ban-client set owncloud unbanip ----- - -You can check the status of your ownCloud filter with the following -command: - -[source,bash] ----- -fail2ban-client status owncloud ----- - -This will produce an output similar to this: - ----- -Status for the jail: owncloud -|- filter -| |- File list: /var/www/owncloud_data/owncloud.log -| |- Currently failed: 1 -| `- Total failed: 7 -`- action - |- Currently banned: 0 - | `- IP list: - `- Total banned: 1 ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/import_ssl_cert.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/import_ssl_cert.adoc deleted file mode 100644 index 0a5b33f..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/import_ssl_cert.adoc +++ /dev/null @@ -1,60 +0,0 @@ -= Importing System-wide and Personal SSL Certificates -:toc: right - -== Introduction - -Modern Web browsers try to keep us safe, and so they blast us with scary -warnings when sites have the smallest errors in their SSL certificates, -or when they use self-signed SSL certificates. ownCloud admins encounter -this when creating Federation shares, or setting up external storage -mounts. There is no reason against using self-signed certificates on -your own networks; they’re fast, free, and easy. - -== Importing Personal SSL Certificates - -ownCloud has several methods for importing self-signed certificates so -that you don’t have to hassle with Web browser warnings. When you allow -your users to create their own external storage mounts or Federation -shares, they can import SSL certificates for those shares on their -Personal pages. - -image:configuration/server/import-ssl-cert-1.png[image] - -Click the *Import root certificate* button to open a file picker. You -can distribute copies of your SSL certificates to your users (via an -ownCloud share!), or users can download them from their Web browsers. -Click on the little padlock icon and click through until you see a btn:[View -Certificate] button, then keep going until you can download it. In -Firefox and Chromium there is an btn:[Export] button for downloading your -own copy of a site’s SSL certificate. - -image:configuration/server/import-ssl-cert-2.png[Click 'More information' in Firefox to import SSL certificate] - -== Site-wide SSL Import - -The personal imports only work for individual users. -You can enable site-wide SSL certificates for all of your users on your ownCloud admin page. -To enable this, you must add this line to your `config.php` file: - -[source,php] ----- -'enable_certificate_management' => true, ----- - -Then you’ll have an btn:[Import root certificate] button on your admin page, -just like the one on your personal page. -Navigate to it by clicking menu:Settings[General > SSL Root Certificates] which is located almost at the bottom. - -image:configuration/server/import-ssl-cert/import-ssl-root-certificates-admin.png[Import Root SSL Certificate in ownCloud] - -== Using OCC to Import and Manage SSL Certificates - -The `occ` command has options for listing and managing your SSL certificates: - ----- -security:certificates list trusted certificates -security:certificates:import import trusted certificate -security:certificates:remove remove trusted certificate ----- - -See xref:configuration/server/occ_command.adoc[Using the occ Command] to learn about how to use `occ`. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/index.adoc deleted file mode 100644 index b763555..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/index.adoc +++ /dev/null @@ -1,5 +0,0 @@ -:section-title: Server Configuration -:section-preamble-ender: to configure ownCloud - -include::partial$section_page.adoc[] - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/index_php_less_urls.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/index_php_less_urls.adoc deleted file mode 100644 index 52d5288..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/index_php_less_urls.adoc +++ /dev/null @@ -1,49 +0,0 @@ -= Enable index.php-less URLs -:toc: right - -== Introduction - -Since ownCloud 9.0.3 you need to explicitly configure and enable index.php-less URLs (e.g. `\https://example.com/apps/files/` instead of `\https://example.com/index.php/apps/files/`). The following documentation provides the needed steps to configure this for the `Apache` Web server. - -== Prerequisites - -Before being able to use index.php-less URLs you need to enable the `mod_rewrite` and `mod_env` Apache modules. Furthermore a configured `AllowOverride All` directive within the vhost of your Web server is needed. Please have a look at the `Apache` manual for how to enable and configure these. - -Furthermore these instructions are only working when using Apache together with the `mod_php` Apache module for PHP. Other modules like `php-fpm` or `mod_fastcgi` are unsupported. - -Finally the user running your Web server (e.g. `www-data`) needs to be able to write into the `.htaccess` file shipped within the ownCloud root directory (e.g., `/var/www/owncloud/.htaccess`). If you have applied xref:installation/manual_installation/manual_installation.adoc#script-guided-installation[Set Correct Permissions], the user might be unable to write into this file and the needed update will fail. You may need to revert this strong permissions temporarily for upgrading. - -== Configuration steps - -The first step is to configure the `overwrite.cli.url` and `htaccess.RewriteBase` config.php options (See config_sample_php_parameters). If you’re accessing your ownCloud instance via `\https://example.com/` the following two options need to be added / configured: - -[source,php] ----- -'overwrite.cli.url' => 'https://example.com', -'htaccess.RewriteBase' => '/', ----- - -If the instance is accessed via `\https://example.com/owncloud` the following configuration is needed: - -[source,php] ----- -'overwrite.cli.url' => 'https://example.com/owncloud', -'htaccess.RewriteBase' => '/owncloud', ----- - -As a second step ownCloud needs to enable index.php-less URLs. This is done: - -* during the next update of your ownCloud instance -* by manually running the occ command `occ maintenance:update:htaccess` (See occ_command) - -Afterwards your instance should have index.php-less URLs enabled. - -== Troubleshooting - -If accessing your ownCloud installation fails after following these instructions and you see messages like this in your ownCloud log: - ----- -The requested uri(\\/login) cannot be processed by the script '\\/owncloud\\/index.php' ----- - -make sure that you have configured the two `config.php` options listed above correctly. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/language_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/language_configuration.adoc deleted file mode 100644 index 5b4be5b..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/language_configuration.adoc +++ /dev/null @@ -1,29 +0,0 @@ -= Language Configuration -:wiki-url: https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes - -In normal cases, ownCloud will automatically detect the language of the -Web UI. If this does not work as expected, or you want to make sure that -ownCloud always starts with a given language, you can use the -*default_language* configuration parameter. - -This parameter can be set in _config/config.php_ - -== Parameters - -[source,php] ----- -'default_language' => 'en', ----- - -Keep in mind that this will not affect the language preferences of users, -which can be configured under menu:Settings[Personal > General > Language] once they have logged in. - -More supported languages can be found in directory _/settings/l10n_. List all files with _ls *.js_. -The language code to be used is the filename without extension. - -Example: ----- -en_GB.js --> en_GB ----- - -Refer to {wiki-url}[Wikipedia] for a match of language code to country. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/legal_settings_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/legal_settings_configuration.adoc deleted file mode 100644 index b352771..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/legal_settings_configuration.adoc +++ /dev/null @@ -1,72 +0,0 @@ -= Legal Settings Configuration -:toc: right -:coppa-url: https://www.ftc.gov/enforcement/rules/rulemaking-regulatory-reform-proceedings/childrens-online-privacy-protection-rule -:caloppa-url: https://consumercal.org/about-cfc/cfc-education-foundation/california-online-privacy-protection-act-caloppa-3/ -:pipeda-url: https://www.priv.gc.ca/en/privacy-topics/privacy-laws-in-canada/the-personal-information-protection-and-electronic-documents-act-pipeda/ -:release-notes-imprint-and-privacy-url: https://doc.owncloud.com/docs/next/server_release_notes.html#new-options-to-display-imprint-and-privacy-policy - -== Introduction - -Because of one or more legal frameworks around the world, some ownCloud instances may need to display links to both an Imprint as well as a Privacy Policy on all pages (both in the Web UI and within email templates). -An Imprint document is a legally mandated statement of the ownership and authorship of the ownCloud installation. -You can think of an Imprint as a rather fancy "*About Us*" page or an enhanced "*Terms and Conditions*" page; in Germany, this is known as an "*Impressum*". - -[NOTE] -==== -Imprint and Privacy Policy links are shown on all *public* pages and in e-mail footers. -Authenticated pages, such as files app or settings, do not show them. -==== - -Some of the more global legal frameworks prominent are: - -- The https://eur-lex.europa.eu/eli/reg/2016/679/oj[GDPR General Data Protection Regulation] -- The https://www.oaic.gov.au/privacy/the-privacy-act[Australian Privacy Act 1988] -- {pipeda-url}[The Canadian Personal Information Protection and Electronic Data Act (PIPEDA)] -- {caloppa-url}[The California Online Privacy Protection Act (CalOPPA)] -- {coppa-url}[The Children's Online Privacy Protection Rule (COPPA)] - -If you're required to link to either one of these, you can specify the link to them in two ways: - -- xref:using-the-web-ui[Using the Web UI] -- xref:using-the-command-line[Using the Command Line] - -== Using the Web UI - -In the Web UI, under menu:Settings[Admin > General], under the heading "*Legal*", you can provide a link to an Imprint and a Privacy Policy URL, as you can see in the screenshot below. - -[#img-owncloud-webui-legal-urls-configuration] -.Configuring Imprint and Privacy Policy URLs in the ownCloud Web UI. -image:configuration/server/owncloud-webui-legal-urls-configuration.png[Configuring Imprint and Privacy Policy URLs in the ownCloud Web UI.] - -NOTE: The values entered will auto-save. - -== Using the Command Line - -From the command line, you can use the `occ config:app:get` and `occ config:app:set` commands, as in the code sample below. - -Get the current values, if any, for the Imprint and Privacy Policy URLs: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:get core legal.imprint_url -{occ-command-example-prefix} config:app:get core legal.privacy_policy_url ----- - -Set the Imprint and Privacy Policy URLs: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set core legal.imprint_url --value=new_value -{occ-command-example-prefix} config:app:set core legal.privacy_policy_url --value=new_value ----- - -For more information about these commands, refer to xref:configuration/server/occ_command.adoc#config-commands[the config command reference in the occ commands documentation]. - -== Viewing the URLs - -[TIP] -==== -Customized email templates and themes that were built prior to ownCloud version 10.0.9 {release-notes-imprint-and-privacy-url}[need to be updated]. -==== - -Once the settings have been updated, you will see two links appear at the bottom the ownCloud login page, one for each option, as in the screenshot below. - -image:configuration/server/legal-settings/login-form-with-legal-settings-links.png[The Imprint and Privacy Policy URLs on the ownCloud login page] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/logging/logging_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/logging/logging_configuration.adoc deleted file mode 100644 index 74e19a6..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/logging/logging_configuration.adoc +++ /dev/null @@ -1,120 +0,0 @@ -= Logging Configuration -:toc: right -:page-aliases: configuration/server/logging_configuration.adoc - -:description: Use your ownCloud log to review system status, or to help debug problems. You may adjust logging levels and choose between using the ownCloud log or using the default syslog daemon. - -== Introduction - -{description} - -== Parameters - -Logging levels range from *DEBUG*, which logs all activity, to *FATAL*, which logs only fatal errors. - -* *0*: DEBUG: Debug, informational, warning, and error messages, and fatal issues. -* *1*: INFO: Informational, warning, and error messages, and fatal issues. -* *2*: WARN: Warning, and error messages, and fatal issues. -* *3*: ERROR: Error messages and fatal issues. -* *4*: FATAL: Fatal issues only. - -By default the log level is set to *2* (WARN). Use *DEBUG* when you have a problem to diagnose, and then reset your log level to a less-verbose level, as *DEBUG* outputs a lot of information, and can affect your server performance. - -Logging level parameters are set in the config/config.php file, or on the Admin page of your ownCloud Web GUI. - -=== ownCloud - -All log information will be written to a separate log file which can be viewed using the log viewer on your Admin page. By default, a log file named *owncloud.log* will be created in the directory which has been configured by the *datadirectory* parameter in config/config.php. As an example see: - -[source,php] ----- -'datadirectory' => '/var/www/owncloud/data', ----- - -When not using the default location for the logfile, it can be xref:configuration/server/config_sample_php_parameters.adoc#define-the-log-path[specified] via: - -[source,php] ----- -'logfile' => '/owncloud.log', ----- - -Note that the web server user must have write rights to that directory. - -The desired date format can optionally be defined using the xref:configuration/server/config_sample_php_parameters.adoc#define-the-log-date-format[logdateformat] parameter in config/config.php. By default the {php-net-url}/manual/en/function.date.php[PHP date function] parameter `__c__` is used, and therefore the date/time is written in the format `__2013-01-10T15:20:25+02:00__`. By using the date format in the example below, the date/time format will be written in the format `__January 10, 2013 15:20:25__`. - -[source,php] ----- -"log_type" => "owncloud", -"logfile" => "owncloud.log", -"loglevel" => "3", -"logdateformat" => "F d, Y H:i:s", ----- - -=== syslog - -The log type can be set to xref:configuration/server/config_sample_php_parameters.adoc#define-the-log-type[syslog] and all log information will be sent to your default syslog daemon. - -[source,php] ----- -"log_type" => "syslog", -"logfile" => "", -"loglevel" => "3", ----- - -The syslog format can be changed to remove or add information. In addition to the `%replacements%` below, `%level%` can be used, but it is used as a dedicated parameter to the syslog logging facility anyway. - -[source,php] ----- -'log.syslog.format' => '[%reqId%][%remoteAddr%][%user%][%app%][%method%][%url%] %message%', ----- - -For the old syslog message format use: -[source,php] ----- -'log.syslog.format' => '{%app%} %message%', ----- - -=== Conditional Logging Level Increase - -xref:configuration/server/config_sample_php_parameters.adoc#define-log-conditions[Log conditions] for log level increase based on conditions can be set. This will increase the logging level automatically to `debug` when the first condition inside a condition block is met. All conditions are optional ! - -* `shared_secret`: A unique token. If a http(s) request parameter named `log_secret` is added to the request and set to this token, the condition is met. -* `users`: If the current request is done by one of the specified users, this condition is met. -* `apps`: If the log message is invoked by one of the specified apps, this condition is met. -* `logfile`: The log message invoked gets redirected to this logfile when a condition above is met. - -Notes regarding the logfile key: - -1. If no logfile is defined, the standard logfile is used. -2. Not applicable when using syslog. - -[verse] --- -The following example demonstrates how all three conditions can look like. -The first one that matches triggers the condition block writing the log entry to the defined logfile. --- - -[source,php] ----- -'log.conditions' => [ - [ - 'shared_secret' => '57b58edb6637fe3059b3595cf9c41b9', - 'users' => ['user1', 'user2'], - 'apps' => ['comments'], - 'logfile' => '/tmp/test2.log' - ] -], ----- - -Based on the conditional log settings above, the following logs are written to the same logfile: - -* Requests matching `log_secret` are debug logged. - -[source,bash] ----- -curl -X PROPFIND -u sample-user:password \ - https://your_domain/remote.php/webdav/?log_secret=57b58edb6637fe3059b3595cf9c41b9 ----- - -* `user1` and `user2` gets debug logged. -* Access to app `comments` gets debug logged. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/logging/request_tracing.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/logging/request_tracing.adoc deleted file mode 100644 index ae676bd..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/logging/request_tracing.adoc +++ /dev/null @@ -1,39 +0,0 @@ -= Request Tracing -:uuid-rfc4122-url: https://tools.ietf.org/html/rfc4122 -:traefik-loadbalancing-url: https://doc.traefik.io/traefik/routing/services/#servers-load-balancer -:big-ip-loadbalancing-url: https://www.f5.com/products/big-ip-services -:page-aliases: configuration/server/request_tracing.adoc - -ownCloud logs the `X-REQUEST-ID` header from desktop and mobile clients in the ownCloud log when sent with client requests. - -The header helps when clients have a problem communicating with an ownCloud server, because: - -. The user can include the value in bug reports; and -. System administrators can filter log files for the header value. - -Storing this information makes searching more efficient, as system administrators don’t have to rely solely on normal log entry elements, such as timestamps and IP addresses. - -== The Header’s Value - -The header's value is a {uuid-rfc4122-url}[UUID (version 4)]. -These are generated from truly random (or pseudo-random) numbers by the client and do not contain _any_ sensitive information. -As a result it will not violate the user's privacy nor allow users to be tracked. - -== Required Server Configuration - -Before the value can be stored in your web server's log files, your system administrator(s) need to configure two areas: - -. *The web server:* The web server's logging configuration needs to be adjusted, e.g., Apache’s access and error log format, so that the value is stored in request log entries. An example of configuring Apache’s CustomLog format xref:web-server-configuration-example[is provided below]. -. *Load balancers:* All load balancers sitting in-between clients and your ownCloud instance(s), e.g., {traefik-loadbalancing-url}[Traefik], {big-ip-loadbalancing-url}[Big-IP], need to be configured to pass the header through. - This way it is possible to track ("trace") requests through larger environments. - Please refer to your load balancer’s configuration for details on how to adjust their configuration. - -== Web Server Configuration Example - -.Example for Apache -[source,apache] ----- -CustomLog /var/log/apache2/access.log "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\" \"%{X-Request-ID}i\"" ----- - -TIP: The exact log format chosen is entirely up to your system administrator(s). diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/oc_server_tuning.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/oc_server_tuning.adoc deleted file mode 100644 index a0578da..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/oc_server_tuning.adoc +++ /dev/null @@ -1,201 +0,0 @@ -= ownCloud Classic Tuning -:toc: right -:memcached-url: https://memcached.org -:thp-url: https://www.kernel.org/doc/Documentation/vm/transhuge.txt -:redis-guide: https://redis.io/topics/latency -:sql-lite-limits-url: http://www.sqlite.org/whentouse.html -:page-aliases: go/admin-performance.adoc - -== Using Cron to Perform Background Jobs - -See xref:configuration/server/background_jobs_configuration.adoc[Background Jobs] for a -description and the benefits. - -== Enable Memory Caching - -Caching improves performance by storing data, code, and other objects in -memory. Memory cache configuration for ownCloud is no longer -automatically available from ownCloud 8.1 but must be installed and -configured separately. ownCloud supports https://redis.io[Redis], -{php-net-url}/manual/en/intro.apcu.php[APCu], and -{memcached-url}[Memcached] as memory caching backends. See -xref:configuration/server/caching_configuration.adoc[Memory Caching], for further details. - -== Use Redis-based Transactional File Locking - -File locking is enabled by default, using the database locking backend. -However, this places a significant load on your database. See the -section xref:configuration/files/files_locking_transactional.adoc[Transactional File Locking] -for how to configure ownCloud to use Redis-based Transactional File Locking. - -== Redis Tuning - -Redis tuning improves both file locking (if used) and memory caching -(when using Redis). Here is a brief guide for tuning Redis to improve -the performance of your ownCloud installation, when working with -sizeable instances. - -=== TCP-Backlog - -If you raised the TCP-backlog setting, the following warning appears in -the Redis logs: - -[source,plaintext] ----- -WARNING: The TCP backlog setting of 20480 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of.. ----- - -If so, please consider that newer versions of Redis have their own -TCP-backlog value set to `511`, and that you have to increase if you -have many connections. In high requests-per-second environments, you -need a significant backlog to avoid slow clients connection issues. - -NOTE: The Linux kernel will silently truncate the TCP-backlog setting to the value of -`/proc/sys/net/core/somaxconn`. So make sure to raise both the value of `somaxconn` and -`tcp_max_syn_backlog`, to get the desired effect. - -To fix this warning, set the value of `net.core.somaxconn` to `65535` in -`/etc/rc.local`, so that it persists upon reboot, by running the following command. - -[source,bash] ----- -sudo echo sysctl -w net.core.somaxconn=65535 >> /etc/rc.local ----- - -After the next reboot, 65535 connections will be allowed, instead of the default value. - -=== Transparent Huge Pages (THP) - -If you are experiencing latency problems with Redis, the following -warning may appear in your Redis logs: - -[source,plaintext] ----- -WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. -This creates both latency and memory usage issues with Redis. ----- - -If so, unfortunately, when a Linux kernel has {thp-url}[Transparent Huge Pages] -enabled, Redis incurs a significant latency penalty after -the fork call is used, to persist information to disk. Transparent Huge -Pages are the cause of the following issue: - -1. A fork call is made, resulting in two processes with shared huge pages being created. -2. In a busy instance, a few event loops cause commands to target a few -thousand pages, causing the copy-on-write of almost the entire process memory. -3. Big latency and memory usage result. - -As a result, make sure to disable Transparent Huge Pages using the following command: - -[source,bash] ----- -echo never > /sys/kernel/mm/transparent_hugepage/enabled ----- - -=== Redis Latency Problems - -If you are having issues with Redis latency, please refer to the {redis-guide}[official Redis guide] on how to handle them. - -== Database Tuning - -=== Using MariaDB/MySQL Instead of SQLite - -MySQL or MariaDB are preferred because of the {sql-lite-limits-url}[performance limitations of SQLite with highly concurrent applications], like ownCloud. - -See the section xref:configuration/database/linux_database_configuration.adoc[Linux Database Configuration] for how to configure ownCloud for MySQL or MariaDB. -If your installation is already running on SQLite then it is possible to convert to MySQL or MariaDB using the steps provided in xref:configuration/database/db_conversion.adoc[database conversion]. - -=== Tune MariaDB/MySQL - -A comprehensive guide to tuning MySQL and MariaDB is outside the scope -of the ownCloud documentation. However, here are three links that can -help you find further information: - -* https://github.com/major/MySQLTuner-perl/[MySQLTuner] -* https://tools.percona.com/wizard[Percona Tools for MySQL] -* https://mariadb.com/kb/en/optimization-and-tuning/[Optimizing and Tuning MariaDB] - -=== Tune PostgreSQL - -A comprehensive guide to tuning PostgreSQL is outside the scope of the -ownCloud documentation. However, here are three links that can help you -find further information: - -* http://de.slideshare.net/PGExperts/five-steps-perform2013[Five Steps to PostgreSQL Performance] -* https://grokbase.com/t/postgresql/pgsql-admin/103qcpdrpf/tuning-auto-vacuum-for-highly-active-tables#20100323hfs3jtjuaywwufukoqtexkpjti[Tuning the autovacuum process for tables with huge update workloads (oc_filecache)] - -== SSL / Encryption App - -SSL (HTTPS) and file encryption/decryption can be offloaded to a -processor’s AES-NI extension. This can both speed up these operations -while lowering processing overhead. This requires a processor with the -http://wikipedia.org/wiki/AES_instruction_set[AES-NI instruction set]. - -Here are some examples how to check if your CPU / environment supports -the AES-NI extension: - -* For each CPU core present: `grep flags /proc/cpuinfo` or as a summary -for all cores: `grep -m 1 ^flags /proc/cpuinfo` If the result contains -any `aes`, the extension is present. -* Search e.g. on the Intel web if the processor used supports the -extension http://ark.intel.com/MySearch.aspx?AESTech=true[Intel Processor Feature Filter]. -You may set a filter by `"AES New Instructions"` to get a reduced result set. -* For versions of openssl >= 1.0.1, AES-NI does not work via an engine -and will not show up in the `openssl engine` command. It is active by -default on the supported hardware. You can check the openssl version via -`openssl version -a` -* If your processor supports AES-NI but it does not show up e.g. via grep -or coreinfo, it is maybe disabled in the BIOS. -* If your environment runs virtualized, check the virtualization vendor -for support. - -== Webserver Tuning - -=== Tune Apache - -==== Enable HTTP/2 Support - -If you want to improve the speed of an ownCloud installation, while at -the same time increasing its security, you can -https://httpd.apache.org/docs/2.4/howto/http2.html[enable HTTP/2 support for Apache]. -Please be aware that https://caniuse.com/http2[most browsers require HTTP/2 to be used with SSL enabled]. - -==== Apache Processes - -An Apache process uses around 12MB of RAM. Apache should be configured -so that the maximum number of HTTPD processes times 12MB is lower than the -amount of RAM. Otherwise the system begins to swap and the performance goes down. - -==== Use KeepAlive - -The https://en.wikipedia.org/wiki/HTTP_persistent_connection[KeepAlive] -directive enables persistent HTTP connections, allowing multiple -requests to be sent over the same TCP connection. Enabling it reduces -latency by as much as 50%. We recommend to keep the KeepAliveTimeout between 3 and 5. -Higher numbers can block the Server with inactive connections. -In combination with the periodic checks of the sync client the following settings are recommended: - -[source,apache] ----- -KeepAlive On -KeepAliveTimeout 3 -MaxKeepAliveRequests 200 ----- - -==== Hostname Lookups - -[source,bash] ----- -cat /etc/httpd/conf/httpd.conf ----- - -[source,plaintext] ----- - ... -HostnameLookups off ----- - -==== Log files - -Log files should be switched off for maximum performance. -To do that, comment out the https://httpd.apache.org/docs/current/mod/mod_log_config.html#customlog[CustomLog] directive. However, keep https://httpd.apache.org/docs/2.4/logs.html#errorlog[ErrorLog] set, so errors can be tracked down. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_command.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_command.adoc deleted file mode 100644 index 14eaf14..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_command.adoc +++ /dev/null @@ -1,377 +0,0 @@ -= Using the occ Command -:toc: macro -:toclevels: 2 -:page-aliases: configuration/server/occ_app_command.adoc, \ -go/admin-cli-upgrade.adoc, \ -configuration/files/external_storage_configuration.adoc, \ -configuration/server/occ_commands/core_commands/app_commands.adoc, \ -configuration/server/occ_commands/core_commands/background_jobs_selector.adoc, \ -configuration/server/occ_commands/core_commands/config_commands.adoc, \ -configuration/server/occ_commands/core_commands/config_reports_commands.adoc, \ -configuration/server/occ_commands/core_commands/command_line_installation_commands.adoc, \ -configuration/server/occ_commands/core_commands/command_line_upgrade_commands.adoc, \ -configuration/server/occ_commands/core_commands/dav_commands.adoc, \ -configuration/server/occ_commands/core_commands/database_conversion_commands.adoc, \ -configuration/server/occ_commands/core_commands/encryption_commands.adoc, \ -configuration/server/occ_commands/core_commands/federation_sync_commands.adoc, \ -configuration/server/occ_commands/core_commands/file_commands.adoc, \ -configuration/server/occ_commands/core_commands/files_external_commands.adoc, \ -configuration/server/occ_commands/core_commands/full_text_search_commands.adoc, \ -configuration/server/occ_commands/core_commands/group_commands.adoc, \ -configuration/server/occ_commands/core_commands/integrity_check_commands.adoc, \ -configuration/server/occ_commands/core_commands/localisation_commands.adoc, \ -configuration/server/occ_commands/core_commands/logging_commands.adoc, \ -configuration/server/occ_commands/core_commands/managing_background_jobs.adoc, \ -configuration/server/occ_commands/core_commands/maintenance_commands.adoc, \ -configuration/server/occ_commands/core_commands/migration_steps_commands.adoc, \ -configuration/server/occ_commands/core_commands/mimetype_update_commands.adoc, \ -configuration/server/occ_commands/core_commands/notifications_commands.adoc, \ -configuration/server/occ_commands/core_commands/incoming_shares_commands.adoc, \ -configuration/server/occ_commands/core_commands/security_commands.adoc, \ -configuration/server/occ_commands/core_commands/sharing_commands.adoc, \ -configuration/server/occ_commands/core_commands/trashbin_commands.adoc, \ -configuration/server/occ_commands/core_commands/2fa_core_commands.adoc, \ -configuration/server/occ_commands/core_commands/user_commands.adoc, \ -configuration/server/occ_commands/core_commands/versions_commands.adoc, \ -configuration/server/occ_commands/app_commands/activity_commands.adoc, \ -configuration/server/occ_commands/app_commands/antivirus_commands.adoc, \ -configuration/server/occ_commands/app_commands/admin_audit_commands.adoc, \ -configuration/server/occ_commands/app_commands/brute_force_protection_commands.adoc, \ -configuration/server/occ_commands/app_commands/calendar_commands.adoc, \ -configuration/server/occ_commands/app_commands/contacts_commands.adoc, \ -configuration/server/occ_commands/app_commands/custom_groups.adoc, \ -configuration/server/occ_commands/app_commands/data_explorer_commands.adoc, \ -configuration/server/occ_commands/app_commands/files_lifecycle.adoc, \ -configuration/server/occ_commands/app_commands/ldap_integration_commands.adoc, \ -configuration/server/occ_commands/app_commands/market_commands.adoc, \ -configuration/server/occ_commands/app_commands/metrics_commands.adoc, \ -configuration/server/occ_commands/app_commands/password_policy_commands.adoc, \ -configuration/server/occ_commands/app_commands/ransomware_protection_commands.adoc, \ -configuration/server/occ_commands/app_commands/richdocuments.adoc, \ -configuration/server/occ_commands/app_commands/oauth2_commands.adoc, \ -configuration/server/occ_commands/app_commands/s3objectstore_commands.adoc, \ -configuration/server/occ_commands/app_commands/saml_sso_shibboleth_integration_commands.adoc, \ -configuration/server/occ_commands/app_commands/2fa_app_commands.adoc, \ -configuration/server/occ_commands/app_commands/wnd_commands.adoc - -ownCloud's `occ` command (ownCloud console) is ownCloud's command-line interface. -You can perform many common server operations with `occ`, such as installing and upgrading ownCloud, managing users and groups, encryption, passwords, app settings, and more. - -//The following is a trick to create a distance between the upper text and the table of contents. Using {empty} produces a clean empty line. Else the "Table of Contents" would stick right below the last text. See: https://discuss.asciidoctor.org/Getting-blank-lines-in-AsciiDoc-td47.html - -{empty} - -toc::[] - -== Running occ - -=== Check if occ Is Set to Executable - -Note that this step is not necessary when using a docker installation. - -To check if the `occ` command is set to executable, change to your ownCloud directory first, then enter the command: - -[source,bash] ----- -ls -lhF occ ----- - -This should give an output similar to this: - -[source,plaintext] ----- --rwxr-x--x 1 root www-data 283 May 18 17:44 occ* ----- - -In case it does not, set the occ command to executable with: - -[source,bash] ----- -sudo chmod +x occ ----- - -=== As Your HTTP User - -On a regular ownCloud installation, `occ` is in the `owncloud/` directory, this is on Ubuntu Linux for example `/var/www/owncloud` . `occ` itself is a PHP script. - -*You must run it as your HTTP user* to ensure that the correct permissions are maintained on your ownCloud files and directories. The default HTTP user is different on the various Linux distributions. - -* The HTTP user and group in Debian/Ubuntu is `www-data`. -* The HTTP user and group in Fedora/CentOS is `apache`. -* The HTTP user and group in Arch Linux is `http`. -* The HTTP user in openSUSE is `wwwrun`, and the HTTP group is `www`. - -[TIP] -==== -Use the following command to find your HTTP user: -[source,bash] ----- -ps -ef | egrep '(apache|httpd)' | grep -v grep | grep -v root | head -n1 | awk '{print $1}' ----- -==== - -If your HTTP server is configured to use a different PHP version than the default (/usr/bin/php), `occ` should be run with the same version. + -For example, in CentOS with SCL-PHP74 installed, the command looks like this: - -[source,bash] ----- -sudo -u apache /opt/rh/php74/root/usr/bin/php /var/www/html/owncloud/occ ----- - -=== occ Command Structure - -The `occ` command has _options_, _commands_, and _arguments_. - -. Options are optional. -. Commands are required. -. Arguments can be required _or_ optional. - -The generic syntax is: - -[source,bash] ----- -occ [options] command [arguments] ----- - -.Example command running occ in Ubuntu -[source,bash] ----- -sudo -u www-data /var/www/owncloud/occ ----- - -If your web server is configured to use a different PHP version than the default (/usr/bin/php), the `occ` command should be run with the same version. - -=== With a Docker Container - -If your ownCloud instance is set up in a docker container, you need a user in the group `docker` to perform `occ` commands. An example command looks like this: - -[source,docker] ----- -docker exec --user www-data occ ----- - -For more information on docker, refer to section xref:installation/docker/index.adoc[Installing with Docker]. - -=== Example Commands - -Running `occ` with no options lists all commands and options, like this example on Ubuntu: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} -ownCloud version 10.8.0 - -Usage: - command [options] [arguments] - -Options: - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - --no-warnings Skip global warnings, show command output only - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, - 2 for more verbose output and 3 for debug - -Available commands: - check Check dependencies of the server environment - help Displays help for a command - list Lists commands - status Show some status information - upgrade Run upgrade routines after installation of - a new release. The release has to be installed before -... ----- - -This is the same as `{occ-command-example-prefix} list`. -Run it with the `-h` option for syntax help: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} -h ----- - -Display your ownCloud version: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} -V - ownCloud version 10.8.0 ----- - -Query your ownCloud server status: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} status - - installed: true - - version: 10.8.0.4 - - versionstring: 10.8.0 - - edition: Community ----- - -The `status` command from above has an option to define the output format. - -The default is plain text, but it can also be `json`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} status --output=json -{"installed":true,"version":"10.8.0.4","versionstring":"10.8.0","edition":""} ----- - -or `json_pretty`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} status --output=json_pretty -{ - "installed": true, - "version": "10.8.0.4", - "versionstring": "10.8.0", - "edition": "Community" -} ----- - -This output option is available on all list and list-like commands, which include `status`, `check`, `app:list`, `config:list`, `encryption:status` and `encryption:list-modules`. - -Get detailed information on individual commands with the `help` command, like in this example for the `maintenance:mode` command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} help maintenance:mode --help -Usage: - maintenance:mode [options] - -Options - --on Enable maintenance mode - --off Disable maintenance mode - --output[=OUTPUT] Output format (plain, json or json_pretty, default is plain) [default: "plain"] - -h, --help Display this help message - -q, --quiet Do not output any message - -V, --version Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - -n, --no-interaction Do not ask any interactive question - --no-warnings Skip global warnings, show command output only - -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, - 2 for more verbose output and 3 for debug ----- - -== Core Commands - -This command reference covers the ownCloud core commands, which are always available. - -include::./occ_commands/core_commands/_app_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_background_jobs_selector.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_config_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_config_reports_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_command_line_installation_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_command_line_upgrade_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_dav_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_database_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_encryption_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_federation_sync_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_federation_trusted_servers.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_file_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_files_external_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_group_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_integrity_check_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_localisation_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_logging_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_managing_background_jobs.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_maintenance_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_migration_steps_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_mimetype_update_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_notifications_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_previews_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_incoming_shares_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_security_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_sharing_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_system_command.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_trashbin_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_2fa_core_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_user_commands.adoc[leveloffset=+2] - -include::./occ_commands/core_commands/_versions_commands.adoc[leveloffset=+2] - -== Apps Commands - -This command reference covers the ownCloud maintained apps commands, which are only available if the respective app is installed and enabled. - -include::./occ_commands/app_commands/_activity_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_antivirus_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_admin_audit_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_brute_force_protection_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_calendar_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_contacts_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_custom_groups.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_data_exporter_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_files_lifecycle.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_full_text_search_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_ldap_integration_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_market_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_metrics_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_migrate_to_kitworks_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_migrate_to_ocis_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_password_policy_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_ransomware_protection_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_richdocuments.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_oauth2_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_s3objectstore_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_saml_sso_shibboleth_integration_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_2fa_app_commands.adoc[leveloffset=+2] - -include::./occ_commands/app_commands/_wnd_commands.adoc[leveloffset=+2] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_2fa_app_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_2fa_app_commands.adoc deleted file mode 100644 index fa543aa..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_2fa_app_commands.adoc +++ /dev/null @@ -1,52 +0,0 @@ -= Two-Factor TOTP - -Marketplace URL: {oc-marketplace-url}/apps/twofactor_totp[2-Factor Authentication] - -The following commands manage the _2-Factor Authentication App_. TOTP stands for _time-based one-time password_. There is also a core component independent of the _2-Factor Authentication App_ with which a particular user can be enabled or disabled for the two-factor authentication. For details see section xref:two-factor-authentication[Two-Factor Authentication]. - -The following commands are available for the 2-Factor Authentication app: - -[source,plaintext] ----- - twofactor_totp - twofactor_totp:delete-redundant-secret Delete the redundant secret of non-existing users - twofactor_totp:set-secret-verification-status Set secret verification status of specified users or all users ----- - -== Delete Redundant Secrets - -Delete the redundant secrets of non-existing users: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} twofactor_totp:delete-redundant-secret ----- - -== Set Secret Verification Status - -Set secret verification status of specified users or all users: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} twofactor_totp:set-secret-verification-status [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `set-verified` -| Secret verification status to set. (true or false) -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--all` -| Will affect all users that use TOTP - -| `-u, --uid=UID` -| The user's uid is used. + -This option can be used as --uid="Alice" --uid="Bob" (multiple values allowed) -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_activity_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_activity_commands.adoc deleted file mode 100644 index b464523..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_activity_commands.adoc +++ /dev/null @@ -1,43 +0,0 @@ -= Activity - -The `activity` command is used for sending automated activity email notifications in ownCloud server. - -[source,plaintext] ----- - activity - activity:send-emails Send all pending activity emails now ----- - -== Send Emails Now - -The `activity:send-emails` command sends all pending activity emails immediately, regardless of the time they are scheduled. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} activity:send-emails ----- - -== Manage Rename and Move Action Notifications - -Starting with Activity app version 2.7.0, rename and move action notifications can be sent. This feature is disabled by default and must be enabled manually. - -=== Enable Rename and Move Action Notifications - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set activity enable_move_and_rename_activities --value "yes" ----- - -=== Disable Rename and Move Action Notifications - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set activity enable_move_and_rename_activities --value "no" ----- - -or - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete activity enable_move_and_rename_activities ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_admin_audit_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_admin_audit_commands.adoc deleted file mode 100644 index 6b1c406..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_admin_audit_commands.adoc +++ /dev/null @@ -1,42 +0,0 @@ -= Auditing - -Marketplace URL: {oc-marketplace-url}/apps/admin_audit[Auditing] - -Tracks various activities and actions of your users and admins. For details, please see the -xref:enterprise/logging/admin_audit.adoc[Auditing] documentation. - -Ignore all CLI triggered events. - -== Set or Change Ignore CLI Events - -To ignore all CLI triggered events, you can set the following option, defaults to track cli events: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - "admin_audit ignore_cli_events" \ - --value "yes" ----- - -== Get Value of Ignore CLI Events - -This command reads the value of `admin_audit ignore_cli_events`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:get "admin_audit ignore_cli_events" ----- - -[source,plaintext] ----- -yes ----- - -== Delete Ignore CLI Events - -This command completely removes the key and the value: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete "admin_audit ignore_cli_events" ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_antivirus_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_antivirus_commands.adoc deleted file mode 100644 index 62622c0..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_antivirus_commands.adoc +++ /dev/null @@ -1,132 +0,0 @@ -= Anti-Virus - -Marketplace URL: {oc-marketplace-url}/apps/files_antivirus[Anti-Virus] - -Use these commands to configure the Anti-Virus app. -Parametrisation must be done with the `occ config` command set. - -== List the Current Settings - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:list files_antivirus ----- - -== Set the Setting - -To set a new value, use the command below and replace `` and value `` accordingly. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus --value= --update-only ----- - -=== Antivirus Mode [string] - -Antivirus Configuration. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_mode` -| Default | 'executable' -| Possible Values | 'executable' + -'daemon' + -'socket' -|=== - -=== Antivirus Socket [string] - -Antivirus Socket. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_socket` -| Default | '/var/run/clamav/clamd.ctl' -|=== - -=== Antivirus Host [string] - -Hostname or IP address of Antivirus Host. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_host` -| Default | -|=== - -=== Antivirus Port [integer] - -Port number of Antivirus Host, 1-65535. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_port` -| Default | -| Possible Values | 1-65535 -|=== - -=== Antivirus Command Line Options [string] - -Extra command line options (comma-separated). - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_cmd_options` -| Default | -|=== - -=== Antivirus Path to Executable [string] - -Path to clamscan executable. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_path` -| Default | '/usr/bin/clamscan' -|=== - -=== Antivirus Maximum Filesize [integer] - -File size limit, -1 means no limit. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_max_file_size` -| Default | '-1' -| Possible Values | '-1' + -integer number -|=== - -=== Antivirus Maximum Stream Length [integer] - -Max Stream Length. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_stream_max_length` -| Default | '26214400' -|=== - -=== Antivirus Action [string] - -When infected files were found during a background scan. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_infected_action` -| Default | 'only_log' -| Possible Values | 'only_log' + -'delete' -|=== - -=== Antivirus Scan Process [string] - -Define scan process. - -[width="80%",cols="30%,70%",] -|=== -| Key | `av_scan_background` -| Default | 'true' -| Possible Values | 'true' + -'false' -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_brute_force_protection_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_brute_force_protection_commands.adoc deleted file mode 100644 index 08d4a67..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_brute_force_protection_commands.adoc +++ /dev/null @@ -1,53 +0,0 @@ -= Brute Force Protection - -Marketplace URL: {oc-marketplace-url}/apps/brute_force_protection[Brute-Force Protection] - -Use these commands to configure the Brute Force Protection app. -Parametrisation must be done with the `occ config` command set. -The combination of `uid` and `IP address` is used to trigger the ban. - -== List the Current Settings - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:list brute_force_protection ----- - -== Set the Setting - -To set a new value, use the command below and replace `` and value `` accordingly. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set brute_force_protection --value= --update-only ----- - -=== Fail Tolerance [attempts] - -Number of wrong attempts to trigger the ban. - -[width="80%",cols="30%,70%",] -|=== -| Key | `brute_force_protection_fail_tolerance` -| Default | 3 -|=== - -=== Time Threshold [seconds] - -Time in which the number of wrong attempts must occur to trigger the ban. - -[width="80%",cols="30%,70%",] -|=== -| Key | `brute_force_protection_time_threshold` -| Default | 60 -|=== - -=== Ban Period [seconds] - -Time how long the ban will be active if triggered. - -[width="80%",cols="30%,70%",] -|=== -| Key | `brute_force_protection_ban_period` -| Default | 300 -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_calendar_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_calendar_commands.adoc deleted file mode 100644 index 6ef4276..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_calendar_commands.adoc +++ /dev/null @@ -1,5 +0,0 @@ -= Calendar - -Marketplace URL: {oc-marketplace-url}/apps/calendar[Calendar] - -For commands for managing the calendar, please see the DAV Command section in the occ core command set. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_contacts_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_contacts_commands.adoc deleted file mode 100644 index 078f416..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_contacts_commands.adoc +++ /dev/null @@ -1,5 +0,0 @@ -= Contacts - -Marketplace URL: {oc-marketplace-url}/apps/contacts[Contacts] - -For commands for managing contacts, please see the DAV Command section in the occ core command set. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_custom_groups.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_custom_groups.adoc deleted file mode 100644 index a0d99d4..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_custom_groups.adoc +++ /dev/null @@ -1,90 +0,0 @@ -= Custom Groups - -Marketplace URL: {oc-marketplace-url}/apps/customgroups[Custom Groups] - -Use these commands to configure the Custom Groups app. - -Parameterization should be done with the `occ config` command set, though some but not all settings result in an entry in config.php which also can be set manually. - -// note that the behaviour of the config:app settings was derived from the code of the app, see https://github.com/owncloud/customgroups and an issue https://github.com/owncloud/docs-webui/pull/41 - -== Get a Current Setting - -You can get the value of a current setting. For details how to do so see the xref:config-commands[Config Command Set]. - -== Disallow Admin Access - -By default, administrators can administrate custom groups of an instance. When changed, only group admins can administrate custom groups. You can change this behaviour with the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set \ - customgroups.disallow-admin-access-all \ - --type boolean --value true ----- - -This occ command will create a key-value pair in your config.php which must be writable for the webserver user. You can also do this manually by adding the following key in config.php: - -[source.plaintext] ----- - 'customgroups.disallow-admin-access-all' => true, ----- - -== Disallow Members of Defined Groups - -You can hide custom groups from a user's personal settings page based on a user's group membership. This makes it easier to collect users you want to exclude into defined groups which will be further used for this setting: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set \ - customgroups.disallowed-groups \ - --type json \ - --value '["no_guest_app_users", "project5"]' ----- - -This occ command will create a key-value pair in your config.php which must be writable for the webserver user to be set. You can also set this manually by adding the following key in config.php: - -[source.plaintext] ----- - 'customgroups.disallowed-groups' => - array ( - 0 => 'no_guest_app_users', - 1 => 'project5', - ), ----- - -== Restrict Group Creation - -This setting defines if ordinary users are allowed to create custom groups. By default, all users can create custom groups, but this can be restricted to admins (if allowed as above) and group-admins. Values to be set can be 'true' and 'false', defaults to 'false'. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - customgroups \ - only_subadmin_can_create \ - --value 'true' ----- - -== Restrict Add or Remove Group Members - -This setting defines if an existing ordinary group member is allowed to add other users to the target group or remove them. By default, all users can add members to groups, but this can be restricted to admins (if allowed as above) and group-admins. Values to be set can be 'yes' and 'no', defaults to 'no'. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - core \ - shareapi_only_share_with_group_members \ - --value 'yes' ----- - -== Allow Duplicate Group Display Names - -This setting allows the creation of multiple groups with the same display name. By default, group display names must be unique, but it can be be allowed to have multiple identical group display names. Values to be set can be 'true' and 'false', defaults to 'false'. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - customgroups \ - allow_duplicate_names \ - --value 'false' ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_data_exporter_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_data_exporter_commands.adoc deleted file mode 100644 index 7ecf599..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_data_exporter_commands.adoc +++ /dev/null @@ -1,72 +0,0 @@ -= Data Exporter - -This app is only available as a https://github.com/owncloud/data_exporter.git[git clone]. -See the xref:maintenance/export_import_instance_data.adoc[Data Exporter] description for more information on how to install this app. Import and export users from one ownCloud instance in to another. The export contains all user settings, files and shares. - -The following commands are available for the Data Exporter app: - -[source,plaintext] ----- - instance - instance:export Exports global instance data - instance:export:user Exports a single user - instance:import Imports global instance data - instance:import:user Imports a single user - instance:export:migrate:share Converts the local shares pointing to the given user to federated shares - pointing at the remote instance. An important prerequisite is that the user - and his shares have already been imported on that remote instance ----- - -== Export User Data - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} instance:export:user ----- - -=== Arguments - -[width="80%",cols="30%,70%",] -|=== -| `userId` | User to export. -| `exportDirectory` | Path to the directory to export data to. -|=== - -== Import User Data - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} instance:import:user [options] [--] ----- - -=== Arguments - -[width="80%",cols="30%,70%",] -|=== -| `userId` | User to export. -| `importDirectory` | Path to the directory to import data from. -|=== - -=== Options - -[width="80%",cols="30%,70%",] -|=== -| `-a [UID]` + -`--as=[UID]` | Import the user under a different user id. -|=== - -== Migrate Shares - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} instance:export:migrate:share ----- - -=== Arguments - -[width="80%",cols="30%,70%",] -|=== -| `userId` | The exported userId whose shares we want to migrate. -| `remoteServer` | The remote ownCloud server where the exported user is now, -for example "https://myown.server:{std-port-http}/owncloud". -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_files_lifecycle.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_files_lifecycle.adoc deleted file mode 100644 index dbcef98..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_files_lifecycle.adoc +++ /dev/null @@ -1,205 +0,0 @@ -= File Lifecycle Management - -Marketplace URL: {oc-marketplace-url}/apps/files_lifecycle[File Lifecycle Management] - -The File Lifecycle Management extension allows service providers to manage the lifecycle of files within ownCloud. For details please see the -xref:enterprise/file_management/files_lifecycle.adoc[File Lifecycle Management] documentation. - -The `lifecycle` commands configure the File Lifecycle Management app. - -.App Configuration -[source,plaintext] ----- -lifecycle - lifecycle:archive Archive files which have reached a certain age - lifecycle:expire Expire files from Archive which have reached a certain age - lifecycle:restore Restore files from Archive to the original location - lifecycle:restore-all Restore all archived files in the system back to their - original locations - lifecycle:set-upload-time Set upload time for files which do not have one ----- - -`config:app` commands configure the Policies for the File Lifecycle Management app. - - -.Policy Configuration -[source,plaintext] ----- - config:app:get|set - files_lifecycle archive_period Number of days since upload (or restore) - after which files will be archived - files_lifecycle expire_period Number of days since archiving after which files will - be permanently deleted - files_lifecycle excluded_groups Define groups of users that are exempt from the - lifecycle policies - files_lifecycle policy Restoration policies for users - files_lifecycle disable_ui Enable/Disable the user interface components ----- - -== App Configuration - -== Archive Aged Files - -Archive files which have reached a certain age. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:archive [options] ----- - -=== Options - -[width="90%",cols="40%,80%",] -|=== -| `-d, + ---dryrun[=DRYRUN]` -| Don't apply changes to the system [default: false] -|=== - -== Expire Files From Archive - -Expire files from archive which have reached a certain age. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:expire [options] ----- - -=== Options - -[width="90%",cols="40%,80%",] -|=== -| `-d, + ---dryrun[=DRYRUN]` -| Don't apply changes to the system [default: false] -|=== - -== Restore Files From Archive - -Restore files from archive to the original location. Note that the location for archived files always follows the pattern `$userid/archive/files/...` - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:restore ----- - -=== Arguments - -[width="90%",cols="40%,80%",] -|=== -| `path` -| Enter path to a folder or to a single file -|=== - -=== Example - -Restore all files in folder `project1` for user alice with path `/work/projects/project1` - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:restore /alice/archive/files/work/projects/project1 ----- - -== Restore All Files From Archive - -Restore all archived files for all users in the system back to their original locations. This command has no additional arguments or options. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:restore-all ----- - -== Set Default Upload Time - -Set upload time for files which do not have one. - -NOTE: Files without upload time are silently skipped by `occ lifecycle:archive` -This can happen with files that were uploaded before the files_lifecycle app was configured or when it was temporarily disabled and therefore do not have an upload time set. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:set-upload-time [options] [--] ----- - -=== Arguments - -[width="90%",cols="40%,80%",] -|=== -| `date` -| Date in format y-m-d. Example: 2018-07-23 -|=== - -=== Options - -[width="90%",cols="40%,80%",] -|=== -| `-d, + ---dryrun[=DRYRUN]` -| Don't apply changes to the system [default: false] -|=== - -== Policy Configuration - -All policy configurations are set and queried with the `config:app` command set. The examples below set a value. To query a value use `config:app:get` and the corresponding key without any options or attributes. - -== Set the Archive Period - -The number of days since upload (or restore) after which files will be archived. - -The following example command sets the time passed since upload (or restore) for archiving files to 90 days. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle archive_period --value='90' ----- - -== Set the Expire Period - -The number of days since archiving after which files will be permanently deleted. - -The following example command sets the time passed to delete files to 180 days. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle expire_period --value='180' ----- - -== Set Groups to be Excluded - -Define groups of users that are exempt from the lifecycle policies (comma-separated group ids). - -The following example command specifies groups whose members will not be part of the lifecycle management. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle excluded_groups --value='group1,group2' ----- - -== Restoration Policy for Users - -Set a policy who can restore files. Use the value `soft` for self-service and `hard` for admin/groupadmin-service. - -The following example command sets the restoration policy for users to `soft` (default). - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle policy --value='soft' ----- - -== Disable User Interface - -Disable the whole user interface for the File Lifecycle Management app. - -The following example command disables the user interface for the File Lifecycle Management app. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle disable_ui --value='yes' ----- - -You can reenable it by deleting the key: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete files_lifecycle disable_ui ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_full_text_search_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_full_text_search_commands.adoc deleted file mode 100644 index 13f419c..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_full_text_search_commands.adoc +++ /dev/null @@ -1,285 +0,0 @@ -= Full Text Search - -Use these commands when you manage full text search related tasks. - -== Command Description - -[source,plaintext] ----- -search - search:index:create Create initial search index for one or all users. - This command could not update the search index correctly - after the initial indexing. - search:index:fillSecondary Fill a secondary index based on the indexed data we have. - search:index:rebuild Rebuild the search index for a given User. - If you want to rebuild the whole index, run - `search:index:reset` and then `search:index:create --all`. - search:index:reset Reset the index. - search:index:update Update the search index by running all pending background jobs. ----- - -In addition to the settings provided by the Full Text Search app, you can set/read additional options via the `occ config:app` commands. These are xref:set-app-modes[Set App Modes], xref:index-metadata-only[Index Metadata Only] and xref:limit-metadata-search-for-groups[Limit Metadata Search for Groups]. - -== Create the Full Text Search Index - -The command `search:index:create` creates the initial full text search index for one or all users. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:create ()... ----- - -=== Arguments - -[width="100%",cols="20%,100%"] -|=== -| `` -| The ID of the user (or space-separated list of user IDs) to create a full text search index for. -A full text search index is created for all users, if this value is omitted. -|=== - -=== Options - -[width="100%",cols="20%,100%"] -|=== -| `--all` -| Will create index for all files of all known users. -|=== - -=== Example 1 - -This example creates a full text search index for the user with user id `testuser`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:create testuser - -Indexing user testuser ----- - -=== Example 2 - -This example creates a full text search index for the users with user ids `admin` and `testuser`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:create admin testuser - -Indexing user admin -Indexing user testuser ----- - -== Fill a Secondary Index - -Fill a secondary index based on the indexed data we have. Files not matching the "indexed" status will be ignored. This is intended to be used in index data migrations, so the connector for this secondary index should have been configured as "write connector". See the xref:configuration/general_topics/search.adoc[Full Text Search] documentation for more details. Note that the values of the `connector_name` are hardcoded and have to be written as described. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:fillSecondary [options] [--] ... ----- - -=== Arguments - -[width="100%",cols="20%,100%"] -|=== -| connector_name -| The name of the connector. `Legacy` (default) or `RelevanceV2`. - -| `` -| Provide a userId. This argument is required. -|=== - -=== Options - -[width="100%",cols="20%,100%"] -|=== -| `-q` `--quiet` -| Do not output any message. - -| `-f` `--force` -| Use this option to fill the secondary index without further questions. - -| `--startOver` -| Start indexing from the beginning, not from a previous savepoint. - -| `--chunkSize=CHUNKSIZE` -| The savepoint will be updated after processing this number of files. [default: "100"] -|=== - -== Rebuild the Full Text Search Index - -Rebuild the index for a given user. All the indexes associated with the configured connectors will be rebuilt. This won't apply any change to the configuration of the index if it's already set up but it will set up any index that hasn't been set up yet. Check "search:index:reset" to reset all the indexes associated to the configured connectors. - -If you want to rebuild the whole index, run `search:index:reset` and then `search:index:create --all`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:rebuild ()... ----- - -=== Arguments - -[width="100%",cols="20%,100%"] -|=== -| `` -| Provide a user ID. This argument is required. -|=== - -=== Options - -[width="100%",cols="20%,100%"] -|=== -| `-q` `--quiet` -| Do not output any message. -| `-f` `--force` -| Use this option to reset the index without further questions. -|=== - -=== Example 1 - -This example rebuilds the full text search index for the user with user ID `testuser`. - -.Rebuild the index for a single user -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:rebuild testuser - -Indexing user testuser - -This will delete all full text search index data for testuser! Do you want to proceed? - [0] no - [1] yes - > 1 -Rebuilding full text search Index for testuser ----- - -=== Example 2 - -This example rebuilds the full text search index for the users with user IDs `admin` and `testuser`. - -.Rebuild the index for multiple users -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:rebuild admin testuser - -This will delete all search index data for admin, testuser! Do you want to proceed? - [0] no - [1] yes - > 1 -Rebuilding Search Index for admin -Rebuilding Search Index for testuser ----- - -=== Rebuild the Entire Index - -The entire index can be rebuilt by running the following two commands: - -[source="console",subs="attributes+"] ----- -{occ-command-example-prefix} search:index:reset -{occ-command-example-prefix} search:index:create --all ----- - -== Reset the Full Text Search Index - -Reset all the configured indexes. Changes in the configuration of the indexes associated with the configured connectors will take place. All the data in those indexes will be removed, so you'll need to rebuild the indexes, usually with "search:index:rebuild". - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:reset ----- - -=== Arguments - -[width="100%",cols="20%,100%"] -|=== -| `-f` `--force` -| Use this option to reset the index without further questions. -|=== - -=== Example - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:reset -This will delete the whole search index! Do you want to proceed? - [0] no - [1] yes - > 1 -Search index has been reset. ----- - -== Update the Full Text Search Index - -Updates to the search index due to changed content or changed metadata are happening via background jobs that are added to a queue. These background jobs are normally run by the ownCloud cronjob. The command `search:index:update` updates the full text search index by running all pending background jobs. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:update ----- - -=== Arguments - -[width="100%",cols="20%,100%"] -|=== -| `-q` `--quiet` -| Suppress all output from the command. -|=== - -=== Example - -This example updates the full text search index for all users. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} search:index:update -Start Updating the Elastic search index: -No pending jobs found. ----- - -== Set App Modes - -To do an initial full indexing without the Full Text Search app interfering, it can be put in passive mode. See the xref:configuration/general_topics/search.adoc#app-modes[App Modes] section in the Full Text Search description for details. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic mode --value passive ----- - -Switching back to active mode can be done by running the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic mode --value active ----- - -== Restrict Search Results - -Search results can be restricted in different ways, see the xref:configuration/general_topics/search.adoc#restrict-search-results[Restrict Search Results] section in the Full Text Search description for details. - -=== Index Metadata Only - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic nocontent --value true ----- - -Switching back to provide all content search results can be done by running the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic nocontent --value false ----- - -=== Limit Metadata Search for Groups - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - search_elastic group.nocontent \ - --value group1,group2,"group with blank" ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_ldap_integration_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_ldap_integration_commands.adoc deleted file mode 100644 index 2610e4c..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_ldap_integration_commands.adoc +++ /dev/null @@ -1,453 +0,0 @@ -= LDAP Integration - -Marketplace URL: {oc-marketplace-url}/apps/user_ldap[LDAP Integration] - -[source,plaintext] ----- -ldap - ldap:check-user Checks whether a user exists on LDAP - ldap:create-empty-config Creates an empty LDAP configuration - ldap:delete-config Deletes an existing LDAP configuration - ldap:invalidate-cache Invalidates the LDAP cache - ldap:search Executes a user or group search - ldap:set-config Modifies an LDAP configuration - ldap:show-config Shows the LDAP configuration - ldap:test-config Tests an LDAP configuration ----- - -== Search for a User - -Search for an LDAP user, using this syntax: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:search [options] [--] ----- -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `search` -| The search string (can be empty) -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--group` -| Searches groups instead of users - -| `--offset=OFFSET` -| The offset of the result set. Needs to be a multiple of limit. [default: 0] - -| `--limit=LIMIT` -| Limit the results. 0 means no limit. [default: 15] -|=== - -Note that the search string can be empty to list all users, or groups when the `--group` option is set. In this case, the search string must be declared with `''`. It is by default a prefix search. Start the string with `*` to change to infix (substring) search. - -=== Search Configuration and Rules - -Search attributes are configurable in the LDAP wizard (menu:Settings[Admin > User Authentication > LDAP]) or via an occ command `ldap:set-config` as described below: - -.General rule -. If User/Group _Search Attributes_ are *NOT* defined (empty), the entry defined in the User/Group _Display Name Field_ is used as the search attribute, for details see below. -. Important when having multiple search attributes, results are unique as long hits correspond to a unique user or group entry. - -.Rules for users -. If *User Search Attributes* are defined (not empty) in: -+ -menu:Settings[Admin > User Authentication > LDAP > Advanced > User Search Attributes] -+ -`ldapAttributesForUserSearch` - -.. Example -+ -If your search attributes would be `givenName` and `sn` you can find users by first name + last name very quickly. You will find "Terri Hanson" by searching for `te ha`. Trailing whitespace is ignored. -. Else use the *User Display Name Field* which usually defaults to the default displayname attribute "displayname" -+ -menu:Settings[Admin > User Authentication > LDAP > Advanced > User Display Name Field] -+ -`ldapUserDisplayName` - - -.Rules for groups -. If *Group Search Attributes* are defined (not empty) in: -+ -menu:Settings[Admin > User Authentication > LDAP > Advanced > Group Search Attributes] -+ -`ldapAttributesForGroupSearch` -. Else use the *Group Display Name Field* which usually defaults to the default displayname attribute "cn" -+ -menu:Settings[Admin > User Authentication > LDAP > Advanced > Group Display Name Field] -+ -`ldapGroupDisplayName` - -.Offset and Limit -The best way understanding `offset` and `limit` is the following table when using `occ ldap:search '' [options]` -[caption=] -[width="50%",cols="20%,30%",options="header"] -|=== -| Options -| Result Set - -| `--offset 0` + -`--limit 5` -| "A", "B", "C", "D" and "E" - -| `--offset 5` + -`--limit 5` -| "F", "G", "H", "I" and "J" - -| `--offset 1` + -`--limit 3` -| "B", "C" and "D" -|=== - - - -=== Examples - -Searches match at the beginning of the attribute value only. This example searches for `givenNames` that start with 'rob': - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:search "rob" ----- - -This will find "robbie", "roberta", and "robin". -Broaden the search to find, for example, `jeroboam` with the asterisk wildcard: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:search "*rob" ----- - -The following examples use `offset` and `limit` options: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:search "re" -Rebecca OShea (Rebecca.OShea) -Rebecca Vintin (Rebecca.Vintin) -Rebekka Da-Cahuna (Rebekka.Da-Cahuna) -Rekha Cox (Rekha.Cox) -Rekha Craft (Rekha.Craft) ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:search "re" --offset 0 --limit 3 -Rebecca OShea (Rebecca.OShea) -Rebecca Vintin (Rebecca.Vintin) -Rebekka Da-Cahuna (Rebekka.Da-Cahuna) ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:search "re" --offset 3 --limit 3 -Rekha Cox (Rekha.Cox) -Rekha Craft (Rekha.Craft) ----- - -== Check if an LDAP User Exists - -This only works if the ownCloud server is connected to an LDAP server. - -[source,plaintext] ----- -ldap:check-user [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `ocName` -| The user name as used in ownCloud (see e.g. the user's Federated Cloud ID). -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--force` -| Ignores disabled LDAP configuration -|=== - -Example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:check-user robert ----- - -`ldap:check-user` will not run a check when it finds a disabled LDAP connection. This prevents users that exist on disabled LDAP connections from being marked as deleted. If you know for sure that the user you are searching for is not in one of the disabled connections and exists on an active connection, use the `--force` option to force a check of all active LDAP connections. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:check-user --force robert ----- - -== Create an Empty LDAP Configuration - -Create an empty LDAP configuration. - -[source,plaintext] ----- -ldap:create-empty-config [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `configID` -| Create a configuration with the specified id -|=== - -Configurations that you create without assigning a are automatically assigned IDs. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:create-empty-config - Created new configuration with configID 's01' ----- - -== List and View Your Configurations - -You can list and view your configurations: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:show-config [options] [--] [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `configID` -| Will show the configuration of the specified id -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--show-password` -| Show LDAP bind password - -| `--output[=OUTPUT]` -| The output format to use (plain, json or json_pretty). [default: "plain"] -|=== - -==== Examples - -If you omit the `configID`, all configuration ID's with their settings are listed: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:show-config ----- - -View the configuration for a single `configID`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:show-config s01 ----- - -== Delete an Existing LDAP Configuration - -Deletes an existing LDAP configuration. - -[source,plaintext] ----- - ldap:delete-config ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `configID` -| The configuration ID -|=== - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:delete s01 -Deleted configuration with configID 's01' ----- - -== Invalidate LDAP Cache - -This command invalidates the LDAP cache for all users: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:invalidate-cache ----- - -== Manipulate LDAP Configurations - -This command manipulates LDAP configurations. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:set-config ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `configID` -| The configuration ID - -| `configKey` -| The configuration key - -| `configValue` -| The new configuration value -|=== - -If a `configKey` allows multiple entries like the key `ldapAttributesForUserSearch`, use semicolons without a whitespace to separate them. - -This example sets search attributes: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:set-config s01 ldapAttributesForUserSearch "cn;givenname;sn;displayname;mail" ----- - -Available keys, along with default values for configValue, are listed in the table below. - -[width="70%",cols=",",options="header",] -|=== -| Configuration | Setting -| hasMemberOfFilterSupport | -| hasPagedResultSupport | -| homeFolderNamingRule | -| lastJpegPhotoLookup | 0 -| ldapAgentName | cn=admin,dc=owncloudqa,dc=com -| ldapAgentPassword | _*_ -| ldapAttributesForGroupSearch | -| ldapAttributesForUserSearch | -| ldapBackupHost | -| ldapBackupPort | -| ldapBase | dc=owncloudqa,dc=com -| ldapBaseGroups | dc=owncloudqa,dc=com -| ldapBaseUsers | dc=owncloudqa,dc=com -| ldapCacheTTL | 600 -| ldapConfigurationActive | 1 -| ldapDynamicGroupMemberURL | -| ldapEmailAttribute | -| ldapExperiencedAdmin | 0 -| ldapExpertUUIDGroupAttr | -| ldapExpertUUIDUserAttr | -| ldapExpertUsernameAttr | -| ldapGroupDisplayName | cn -| ldapGroupFilter | -| ldapGroupFilterMode | 0 -| ldapGroupFilterObjectclass | -| ldapGroupMemberAssocAttr | uniqueMember -| ldapHost | ldap://host -| ldapIgnoreNamingRules | -| ldapLoginFilter | (&((objectclass=inetOrgPerson))(uid=%uid)) -| ldapLoginFilterAttributes | -| ldapLoginFilterEmail | 0 -| ldapLoginFilterMode | 0 -| ldapLoginFilterUsername | 1 -| ldapNestedGroups | 0 -| ldapNetworkTimeout | 15 -| ldapOverrideMainServer | -| ldapPagingSize | 500 -| ldapPort | 389 -| ldapQuotaAttribute | -| ldapQuotaDefault | -| ldapTLS | 0 -| ldapUserDisplayName | displayName -| ldapUserDisplayName2 | -| ldapUserFilter | ((objectclass=inetOrgPerson)) -| ldapUserFilterGroups | -| ldapUserFilterMode | 0 -| ldapUserFilterObjectclass | inetOrgPerson -| ldapUuidGroupAttribute | auto -| ldapUuidUserAttribute | auto -| turnOffCertCheck | 0 -| useMemberOfToDetectMembership | 1 -|=== - -== Test Your Configuration - -Tests whether your configuration is correct and can bind to the server. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:test-config ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `configID` -| The configuration ID -|=== - -Example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:test-config s01 -The configuration is valid and the connection could be established! ----- - -== Set and Unset LDAP App Configurations - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set user_ldap updateAttributesInterval --value=7200 ----- - -In the example above, the interval is being set to 7200 seconds. -Assuming the above example was used, the command would output the following: - -[source,plaintext] ----- -Config value updateAttributesInterval for app user_ldap set to 7200 ----- - -If you want to reset (or unset) the setting, then you can use the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete user_ldap updateAttributesInterval ----- - -*Reuse Existing LDAP Accounts if Available* - -If you want to allow new LDAP logins to attempt to reuse existing `oc_accounts` entries that match the resolved username attribute, and have backend set to `User_Proxy`, then set the `reuse_accounts` config setting to `yes`. - -Below is an example of how to do so. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set user_ldap reuse_accounts --value="yes" ----- - -This functionality is valuable for several reasons; these are: - -* It handles the situation of when admins mistakenly delete one or more user mappings, and subsequent logins then create new accounts. -* It allows auto-provisioned users with Shibboleth to be moved over to an LDAP server, but be able to continue using ownCloud. - -[IMPORTANT] -==== -This functionality will not work in the following situations: - -. No user or group account exists with the supplied username. -. A user or group account exists, but it uses a different backend. -==== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_market_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_market_commands.adoc deleted file mode 100644 index 1317989..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_market_commands.adoc +++ /dev/null @@ -1,120 +0,0 @@ -= Market - -Marketplace URL: {oc-marketplace-url}/apps/market[Market] - -The `market` commands _install_, _uninstall_, _list_, and _upgrade_ applications from the ownCloud Marketplace. - -[source,plaintext] ----- -market - market:install Install apps from the marketplace. If already installed and - an update is available the update will be installed. - market:uninstall Uninstall apps from the marketplace. - market:list Lists apps as available on the marketplace. - market:upgrade Installs new app versions if available on the marketplace ----- - -NOTE: The user running the update command, which will likely be your webserver user, requires write permission for the `/apps` respectively `apps-external` folder. - -NOTE: If they don’t have write permission, the command may report that the update was successful, but it may silently fail. - -These commands are not available in single-user (maintenance) mode. -For more details please see the Maintenance Commands section in the occ core command set. - -== Install an Application - -Applications can be installed both from {oc-marketplace-url}/[the ownCloud Marketplace] and from a local file archive. - -== Install Apps From The Marketplace - -To install an application from the Marketplace, you need to supply the app’s id, which can be found in the app’s Marketplace URL. -For example, the URL for _Two factor backup codes_ is {oc-marketplace-url}/apps/twofactor_backup_codes. -So its app id is `twofactor_backup_codes`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} market:install [option] ----- - -=== Arguments - -[width="80%",cols="30%,70%",] -|=== -| `ids` | Ids of the apps -|=== - -=== Options -[width="80%",cols="30%,70%",] -|=== -| `-l [LOCAL]` + -`--local=[LOCAL]` | Optional path to a local app package. -|=== - -== Install Apps From a File Archive - -To install an application from a local file archive, you need to supply the path to the archive, and that you pass the `-l` switch. -Only `zip`, `gzip`, and `bzip2` archives are supported. - -== Usage Example - -[source,bash,subs="attributes+"] ----- -# Install an app from the marketplace. -{occ-command-example-prefix} market:install twofactor_backup_codes - -# Install an app from a local archive. -{occ-command-example-prefix} market:install -l /mnt/data/richdocuments-2.0.0.tar.gz ----- - -NOTE: The target directory has to be *accessible to the webserver user* and you have to *enable* the app afterwards with the `occ app:enable` command. - -== Uninstall an Application - -To uninstall an application use the following commands: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} market:uninstall ----- - -=== Arguments - -[width="80%",cols="30%,70%",] -|=== -| `ids` | Ids of the apps -|=== - -== List Apps From The Marketplace - -This command lists apps available on the marketplace. -It returns the ids of the apps. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} market:list ----- - -== Upgrade an Application - -Install new app versions if available on the marketplace by using following commands: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} market:upgrade [options] ----- - -=== Arguments - -[width="80%",cols="30%,70%",] -|=== -| `ids` | Ids of the apps -|=== - -=== Options - -[width="80%",cols="30%,70%",] -|=== -| `-l [LOCAL]` + -`--local=[LOCAL]` | Optional path to a local app package. -| `--major` | Allow update to a new major version. -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_metrics_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_metrics_commands.adoc deleted file mode 100644 index e3813fd..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_metrics_commands.adoc +++ /dev/null @@ -1,60 +0,0 @@ -= Metrics - -Marketplace URL: {oc-marketplace-url}/apps/metrics[Metrics] - -Monitoring and reporting of ownCloud Classic. For details please see the -xref:enterprise/reporting/metrics.adoc[Metrics] documentation. - -Set a secret for authenticating requests at the endpoint. - -In case you want to generate a random secret, use the following example command: + - -[source,bash] ----- -echo $(tr -dc 'a-z0-9' < /dev/urandom | head -c 20) ----- - -== Set or change the Secret - -Writes the key `metrics_shared_secret` and the secret to config.php. The name must not be changed and be exactly as written. - -Note: You can also set the config key/value manually into your config.php file. - - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set \ - "metrics_shared_secret" \ - --value "your-metrics-secret" ----- - -The above command adds the following at the end of `config.php`: - -[source,php] ----- -'metrics_shared_secret' => 'your-metrics-secret', ----- - -== Get the Secret - -This command reads the value of the `metrics_shared_secret` key from config.php: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:get "metrics_shared_secret" ----- - -[source,plaintext] ----- -your-metrics-secret ----- - -== Delete the Secret - -This command completely removes the key and the value from config.php: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:delete "metrics_shared_secret" ----- - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_migrate_to_kitworks_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_migrate_to_kitworks_commands.adoc deleted file mode 100644 index bd50c40..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_migrate_to_kitworks_commands.adoc +++ /dev/null @@ -1,179 +0,0 @@ -= Migrate to Kiteworks - -The _Migrate to Kiteworks_ app is not available on the ownCloud marketplace. If you plan a migration, get in touch with {oc-support-url}[ownCloud support] for more details. - -See the xref:maintenance/migrating_to_kiteworks.adoc[Migrating to Kiteworks Private Content Network] documentation for the sequence and details of the migration including the description how to get the required parameters for the commands. - -Note that the argument `$KW_ADMIN_USER` in the description below is noted like when defining it as environment variable as proposed in the migration document. - -The following commands manage the migration of ownCloud to Kiteworks: - -[source,plaintext] ----- - migrate:to-kiteworks - migrate:to-kiteworks:init Initialize the migration process. - migrate:to-kiteworks:verify Verifies the ownCloud instance to be ready for migration. - migrate:to-kiteworks:users Migrates ownCloud users to the configured Kiteworks instance. - migrate:to-kiteworks:files Migrates ownCloud files and folders to the configured Kiteworks instance. - migrate:to-kiteworks:shares Migrates ownCloud shares to the configured Kiteworks instance. - migrate:to-kiteworks:disable-users Disables users in Kiteworks. ----- - -== Initialize the Migration Process - -To start the migration, it must be initialized first: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-kiteworks:init KW_HOST KW_APPLICATION_ID "KW_SECRET" ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| KW_HOST -| The IP address, hostname or URL to reach the Kiteworks instance - -| KW_APPLICATION_ID -| Client application ID - -| KW_SECRET -| Secret key -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-f --force` -| Normally, init is protected against accidentially overwriting an existing kiteworks connection. Use --force to do so. -|=== - -== Verify That the Migration can be Started - -After initialisation, the migration must be verified to be ready: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-kiteworks:verify $KW_ADMIN_USER ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| $KW_ADMIN_USER -| The Kiteworks admin users email address -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-k, --insecure` -| Allow insecure (untrusted) certificates. Used for testing purposes. -|=== - -== Migrate Users - -After verification, migrating users can be started: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-kiteworks:users $KW_ADMIN_USER $KW_PROFILE_GUEST ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| $KW_ADMIN_USER -| The Kiteworks admin users email address - -| KW_PROFILE_GUEST -| The Kiteworks guest user profile, defaults to "restricted" -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-k, --insecure` -| Allow insecure (untrusted) certificates. Used for testing purposes. -|=== - -== Migrate Files - -After migrating users, migrating files can be started: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-kiteworks:files $KW_ADMIN_USER ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| $KW_ADMIN_USER -| The Kiteworks admin users email address -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-k, --insecure` -| Allow insecure (untrusted) certificates. Used for testing purposes. -|=== - -== Migrate Shares - -After migrating files, shares can be migrated. Note that when initiating this step, migrating files and users cant be run again: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-kiteworks:shares $KW_ADMIN_USER ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| $KW_ADMIN_USER -| The Kiteworks admin users email address -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-k, --insecure` -| Allow insecure (untrusted) certificates. Used for testing purposes. -|=== - -== Disable Users in Kiteworks - -After migrating shares, the final step can be processed. This is to disable migrated users in Kiteworks that are disabled in ownCloud: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-kiteworks:disable-users $KW_ADMIN_USER ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| $KW_ADMIN_USER -| The Kiteworks admin users email address -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-k, --insecure` -| Allow insecure (untrusted) certificates. Used for testing purposes. -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_migrate_to_ocis_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_migrate_to_ocis_commands.adoc deleted file mode 100644 index 18433d3..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_migrate_to_ocis_commands.adoc +++ /dev/null @@ -1,167 +0,0 @@ -= Migrate to oCIS - -The _Migrate to oCIS_ app is not available on the ownCloud marketplace. If you plan a migration, get in touch with {oc-support-url}[ownCloud support] for more details. - -See the xref:maintenance/migrating_to_ocis.adoc[Migrating to ownCloud Infinite Scale] documentation for the sequence and details of the migration. - -The following commands manage the migration of ownCloud to oCIS: - -[source,plaintext] ----- - migrate:to-ocis - migrate:to-ocis:init Initialize the migration process. - migrate:to-ocis:verify Verifies the ownCloud instance to be ready for migration. - migrate:to-ocis:migrate:users Migrates ownCloud users to the configured oCIS instance. - migrate:to-ocis:assign-role Assigns the chosen role to all users in the configured oCIS instance. - migrate:to-ocis:migrate:groups Migrates ownCloud groups to the configured oCIS instance. - migrate:to-ocis:migrate:files Migrates ownCloud files to the configured oCIS instance. - migrate:to-ocis:migrate:shares Migrates ownCloud shares to the configured oCIS instance. ----- - -== Initialize the Migration Process - -To start the migration, it must be initialized first: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-ocis:init OCIS_HOST ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| OCIS_HOST -| The hostname or URL of the target oCIS instance -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-f, --force` -| Reset the migration and start from the beginning. Data already migrated to the oCIS instance will remain there and the target oCIS instance should be cleaned before restarting. - -| `-k, --insecure` -| Ignore the SSL certificate of the oCIS instance. Useful for self-signed or untrusted certificates. -|=== - -== Verify That the Migration can be Started - -After initialization, verify that the ownCloud instance meets all requirements for migration: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-ocis:verify ----- - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--skip` -| Skip this step and move to the next one. Any problems caused by duplicate or missing emails will be your responsibility. -|=== - -== Migrate Users - -After verification, migrate the ownCloud users to oCIS: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-ocis:migrate:users ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| -| The oCIS admin account username. The password will be asked interactively. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--skip` -| Skip this step. Use this for LDAP migrations where users are already provisioned by the LDAP server. -|=== - -== Assign a Role to Migrated Users - -After migrating users, assign a role to all migrated users. The available roles are fetched from the oCIS instance and the role to assign is selected interactively: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-ocis:assign-role ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| -| The oCIS admin account username. The password will be asked interactively. -|=== - -NOTE: This step is mandatory and cannot be skipped. - -== Migrate Groups - -After assigning roles, migrate the ownCloud groups to oCIS: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-ocis:migrate:groups ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| -| The oCIS admin account username. The password will be asked interactively. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--skip` -| Skip this step. Note that shares targeting groups may fail to be created if those groups are not present in oCIS. -|=== - -== Migrate Files - -After migrating groups, migrate each user's files to oCIS using the rclone binary bundled with the app. oCIS impersonation via the auth-app is used to access each user's account: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-ocis:migrate:files ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| -| The oCIS admin account username. The password will be asked interactively. -|=== - -== Migrate Shares - -After migrating files, migrate all user, group, and link shares. oCIS impersonation via the auth-app is used to access each user's account: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrate:to-ocis:migrate:shares ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| -| The oCIS admin account username. The password will be asked interactively. -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_oauth2_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_oauth2_commands.adoc deleted file mode 100644 index f297513..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_oauth2_commands.adoc +++ /dev/null @@ -1,133 +0,0 @@ -= OAuth2 - -Marketplace URL: {oc-marketplace-url}/apps/oauth2[OAuth2] - -Use these commands to configure OAuth2 clients via the OAuth2 app: - -[source,plaintext] ----- -oauth2 - oauth2:add-client Adds an OAuth2 client - oauth2:list-clients Lists OAuth2 clients - oauth2:remove-client Removes an OAuth2 client - oauth2:modify-client Modify OAuth2 client details ----- - -== Add a Client - -=== Usage - -[source,plaintext] ----- -oauth2:add-client [ [ []]] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `name` -| Name of the client - will be displayed in the authorization page to the user - -| `client-id` -| Identifier of the client - used by the client during the implicit and authorization code flow - -| `client-secret` -| Secret of the client - used by the client during the authorization code flow - -| `redirect-url` -| Redirect URL - used in the OAuth flows to post back tokens and authorization codes to the client - -| `allow-sub-domains` -| Defines if the redirect url is allowed to use sub-domains. Enter true or false [default: "false"] - -| `trusted` -| Defines if the client is trusted. Enter true or false [default: "false"] - -| `force-trust` -| Trust the client even if the redirect-url is localhost. [default: "false"] -|=== - -== List Clients - -=== Usage - -[source,plaintext] ----- -oauth2:list-clients [options] ----- - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--output[=OUTPUT]` -| The output format to use (plain, json or json_pretty). [default: "plain"] -|=== - -.Example Output -[source,plaintext] ----- - - Desktop Client: - - name: Desktop Client - - redirect-url: http://localhost:* - - client-id: xdXOt13JKxym1B1QcEncf2XDkLAexMBFwiT9j6EfhhHFJhs2KM9jbjTmf8JBXE69 - - client-secret: UBntmLjC2yYCeHwsyj73Uwo9TAaecAetRwMw0xYcvNL9yRdLSUi0hUAHfvCHFeFh - - allow-sub-domains: false - - trusted: false - - Android: - - name: Android - - redirect-url: oc://android.owncloud.com - - client-id: e4rAsNUSIUs0lF4nbv9FmCeUkTlV9GdgTLDH1b5uie7syb90SzEVrbN7HIpmWJeD - - client-secret: dInFYGV33xKzhbRmpqQltYNdfLdJIfJ9L5ISoKhNoT9qZftpdWSP71VrpGR9pmoD - - allow-sub-domains: false - - trusted: false - - iOS: - - name: iOS - - redirect-url: oc://ios.owncloud.com - - client-id: mxd5OQDk6es5LzOzRvidJNfXLUZS2oN3oUFeXPP8LpPrhx3UroJFduGEYIBOxkY1 - - client-secret: KFeFWWEZO9TkisIQzR3fo7hfiMXlOpaqP8CFuTbSHzV1TUuGECglPxpiVKJfOXIx - - allow-sub-domains: false - - trusted: false ----- - -== Modify Client Details - -=== Usage - -[source,plaintext] ----- -oauth2:modify-client ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `name` -| Name of client - -| `key` -| Key to be changed. Valid keys are: + -`name`, `client-id`, `client-secret`, `redirect-url`, `allow-sub-domains`, `trusted` - -| `value` -| The new value of the key. -|=== - -== Remove a Client - -=== Usage - -[source,plaintext] ----- -oauth2:remove-client ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `client-id` -| Identifier of the client - used by the client during the implicit and authorization code flow -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_password_policy_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_password_policy_commands.adoc deleted file mode 100644 index 37099c6..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_password_policy_commands.adoc +++ /dev/null @@ -1,84 +0,0 @@ -= Password Policy - -Marketplace URL: {oc-marketplace-url}/apps/password_policy[Password Policy] - -Command to expire a user or group of users’ passwords. - -== Command Description - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:expire-password [] ----- - -=== Arguments - -[width="100%",cols="20%,82%",] -|=== -| `uid` | User ID. -| `expiredate` | The date and time when a password expires, + -e.g. `2019-01-01 14:00:00 CET` or -1 days. -|=== - -TIP: The expiry date can be provided using any of {php-net-url}/manual/datetime.formats.php[PHP's supported date and time formats]. - -=== Options - -[width="100%",cols="23%,82%",] -|=== -| `-a, --all` -| Will add password expiry to all known users. -uid and group option are discarded if the option is provided by user. - -| `-u [UID]` + -`--uid=[UID]` -| The uid of the user to expire the password for. + -To expire the password of multiple users, pass the `-u` or `--uid` option multiple times, as in this example: `--uid "Alice" --uid "Bob"`. - -| `-g [GROUP]` + -`--group=[GROUP]` -| Add password expiry to user(s) in one or more groups. + -This option can be used as `--group foo --group bar` to add expiry passwords for users in multiple groups. -|=== - -If an expiry date is not supplied, the password will expire with immediate effect. -This is because the password will be set as being expired 24 hours before the command was run. -For example, if the command was run at `2018-07-**12** 13:15:28 UTC`, then the password's expiry -date will be set to `2018-07-**11** 13:15:28 UTC`. - -After the command completes, console output, similar to that below, confirms when the user's password is set to expire. - ----- -The password for frank is set to expire on 2018-07-12 13:15:28 UTC. ----- - -== Command Examples - -[source,bash,subs="attributes+"] ----- -# The password for user "frank" will be set as being expired 24 hours before the command was run. -{occ-command-example-prefix} user:expire-password -u frank - -# Expire the user "frank"'s password in 2 days time. -{occ-command-example-prefix} user:expire-password -u frank '+2 days' - -# Expire the user "frank"'s password on the 15th of August 2005, at 15:52:01 in the local timezone. -{occ-command-example-prefix} user:expire-password --uid frank '2005-08-15T15:52:01+00:00' - -# Expire the user "frank"'s password on the 15th of August 2005, at 15:52:01 UTC. -{occ-command-example-prefix} user:expire-password --uid frank '15-Aug-05 15:52:01 UTC' ----- - -== Caveats - -Please be aware of the following implications of enabling or changing the password policy's "*days until user password expires*" option. - -* Administrators need to run the `occ user:expire-password` command to initiate expiry for new users. -* Passwords will never expire for users who have *not* changed their initial password, because they do not have a password history. - To force password expiration use the `occ user:expire-password` command. -* A password expiration date will be set after users change their password for the first time. - To force password expiration use the `occ user:expire-password` command. -* Passwords changed for the first time, will expire based on the *active* password policy. - If the policy is later changed, it will not update the password's expiry date to reflect the new setting. -* Password expiration dates of users where the administrator has run the `occ user:expire-password` command *won't* automatically update to reflect the policy change. - In these cases, Administrators need to run the `occ user:expire-password` command again and supply a new expiry date. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_ransomware_protection_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_ransomware_protection_commands.adoc deleted file mode 100644 index c187c6e..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_ransomware_protection_commands.adoc +++ /dev/null @@ -1,149 +0,0 @@ -= Ransomware Protection (Enterprise Edition only) - -Marketplace URL: {oc-marketplace-url}/apps/ransomware_protection[Ransomware Protection] - -Use these commands to help users recover from a Ransomware attack. -You can find more information about the application in the xref:enterprise/security/ransomware-protection/index.adoc[Ransomware Protection documentation]. - -== Command Description - -[source,bash,subs="attributes+"] ----- -ransomguard - ransomguard:scan Scan the ownCloud database for changes in order - to discover anomalies in a user’s account and their origin. - ransomguard:restore Revert all operations in a user account after a point in time. - ransomguard:lock Set a user account as read-only for ownCloud and other WebDAV - clients when malicious activity is suspected. - ransomguard:unlock Unlock a user account after ransomware issues have been resolved - ransomguard:blacklist:set-file Set the file that will contain the blacklist. - A new file will be created if it does not exist. - ransomguard:blacklist:update:from-file Update the blacklist with the contents from the file. - ransomguard:blacklist:update:from-site Update the blacklist with the contents from the site ----- - -== Scan Command Description - -Scan the ownCloud database for changes in order to discover anomalies in a user’s account and their origin. Add a `` and a `` for the search to start with. Note that `` must be in the Linux timestamp format. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ransomguard:scan ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `` + -`` -| Report all changes in a user's account, starting from timestamp. -|=== - -== Restore Command Description - -Revert all operations in a user account after a given point in time. Note that `` must be in the Linux timestamp format. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ransomguard:restore ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `` + -`` -| Revert all operations in a user account after a point in time. -|=== - -== Lock Command Description - -When necessary, set a user account as `read-only` for ownCloud and other WebDAV clients when malicious activity is suspected. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ransomguard:lock ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `` -| Set a user account as read-only for ownCloud and other WebDAV clients when malicious activity is suspected. -|=== - -== Unlock Command Description - -When ransomware issues have been resolved, the user account can be unlocked. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ransomguard:unlock ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `` -| Unlock a user account after ransomware issues have been resolved. -|=== - -== Blacklist Handling - -The information which files to blacklist can be dynamically maintained either via a file or a URL where the data can be retrieved from. Independent of where updates come from, the file the app uses for identifying blacklist patterns is defined via `set-file`. - -=== Blacklist Set-File Command Description - -This command will set the location of the blacklist file the app will use. The location needs to be shared in all ownCloud servers in case of a multi-server setup. If you try to update the blacklist using the command `blacklist:update:from-file` without having run the `blacklist:set-file` command first, the blacklist file will be generated using the bundled `blacklist.txt.dist` file and saved in the ownCloud's data directory as `ransomware_blacklist.txt`. That file will then be used as default. Running the command again using a different `` as argument will copy the contents from the old location to the new location without deleting the old one. It is highly recommended to use a different filename than the bundled one. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ransomguard:blacklist:set-file ----- - -==== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `` -| The location of the file -|=== - -=== Blacklist From-File Command Description - -This command will update the contents of the blacklist file using another file as source. The format of the file is the same as the `blacklist.txt.dist` file bundled in the app. The command will only add the new items, which are displayed in the terminal. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ransomguard:blacklist:update:from-file ----- - -==== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `` -| The location of the file updated data gets loaded from -|=== - -=== Blacklist From-Site Command Description - -This command will update the contents by getting the blacklist from a website. The default site is https://fsrm.experiant.ca/api/v1/get. Other sites can be used as long as the response follows the same format as the default site. The behavior is the same as with the `from-file` variant. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ransomguard:blacklist:update:from-site ----- - -==== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `` -a| The URL to get the data from, defaults to: + -https://fsrm.experiant.ca/api/v1/get -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_richdocuments.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_richdocuments.adoc deleted file mode 100644 index b8c7c9f..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_richdocuments.adoc +++ /dev/null @@ -1,113 +0,0 @@ -= Collabora Online / Secure View - -Marketplace URL: {oc-marketplace-url}/apps/richdocuments[Collabora Online] - -Collabora Online allows you to work with all kinds of collabora office documents inside ownCloud for improved productivity. For details, see the -xref:enterprise/collaboration/collabora_secure_view.adoc[Collabora Online / Secure View] documentation. - -`config:app` commands to configure the Collabora Online app. - -[source,plaintext] ----- - config:app:get|set - richdocuments wopi_url WOPI Server URL - richdocuments secure_view_option Enable Secure View - richdocuments watermark_text Watermark pattern displayed in the document - richdocuments open_in_new_tab Open documents in a new tab - richdocuments secure_view_can_print_default Define if documents can be printed or exported - richdocuments secure_view_open_action_default Enforce displaying the watermark by default ----- - -== App Configuration - -All app configurations are set and queried with the `config:app` command set. The examples below set a value. To query a value use `config:app:get` and the corresponding key without any options or attributes. Note that values have to be set in single quotes. - -== Define the WOPI Server URL - -WOPI Server URL - -This command sets the WOPI Server to `[IP/URL]:port` + -`[IP/URL]:port` can be any IP/URL plus the port on which the WOPI server can be accessed like: - -- `a.b.c.d` -- `http://a.b.c.d:8098` -- `https://rd.yourdomain.com` -- ... - -Adding the port is only necessary when not using standard ports. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set richdocuments wopi_url --value='[IP/URL]:port' ----- - -== Enable Secure View - -Enable Secure View (possible values: true/false, default: false). - -The following example command enables secure view globally on the system: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set richdocuments secure_view_option --value='true' ----- - -== Define the Watermark Pattern Displayed - -A watermark pattern is displayed in the document when it is viewed. It can be an arbitrary string. The keyword \{viewer-email} will be replaced with the current user's email address in the document watermark. If an email address is not set, then the user's display name will be used. - -The following example command sets the watermark pattern displayed in the document: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set richdocuments watermark_text --value='Restricted to \{viewer-email}' ----- - -== Open Documents in a New Tab - -By default, documents will open in a new tab if not otherwise defined. You can change this behaviour with a command (possible values: true/false, default: false). - -The following example command makes documents open in the same tab: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set richdocuments open_in_new_tab --value='false' ----- - -== Define the Print and Exporting Option - -Enable documents in secure view mode to be printed and exported (possible values: true/false, default: false). - -The following example command enables the option to globally print and export documents although secure view is enabled: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set secure_view_can_print_default --value='true' ----- - -== Enforce Displaying the Watermark - -Open documents in secure view with watermark by default (possible values: true/false, default: false). - -The following example command enables the option to globally enforce displaying the watermark when documents are viewed: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set richdocuments secure_view_open_action_default --value='true' ----- - -== Delete a Key or Change a Key - -You can delete a key with the following example command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete richdocuments secure_view_open_action_default ----- - -You can change a key with the following example command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set richdocuments secure_view_option --value='false' ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_s3objectstore_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_s3objectstore_commands.adoc deleted file mode 100644 index f93c170..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_s3objectstore_commands.adoc +++ /dev/null @@ -1,41 +0,0 @@ -= S3 Primary Objectstore - -Commands to configure Amazon S3 compatible object storages as the primary ownCloud storage location. - -Marketplace URL: {oc-marketplace-url}/apps/files_primary_s3[S3 Primary Object Storage] - -== List objects, buckets or versions of an object - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} s3:list ----- - -=== Arguments - -[width="80%",cols="30%,70%",] -|=== -| `bucket` | Name of the bucket; it`s objects will be listed. -| `object` | Key of the object; it`s versions will be listed. -|=== - -== Create a bucket as necessary to be used - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} s3:create-bucket ----- - -=== Arguments - -[width="80%",cols="30%,70%",] -|=== -| `bucket` | Name of the bucket to be created. -|=== - -=== Options -[width="80%",cols="30%,70%",] -|=== -| `update-configuration` | If the bucket exists, the configuration will be updated. -| `accept-warning` | No warning about the usage of this command will be displayed. -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_saml_sso_shibboleth_integration_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_saml_sso_shibboleth_integration_commands.adoc deleted file mode 100644 index 29b0577..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_saml_sso_shibboleth_integration_commands.adoc +++ /dev/null @@ -1,10 +0,0 @@ -= SAML/SSO Shibboleth Integration (Enterprise Edition only) - -Marketplace URL: {oc-marketplace-url}/apps/user_shibboleth[SAML/SSO Integration] - -`shibboleth:mode` sets your Shibboleth mode to `notactive`, `autoprovision`, or `ssoonly` - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} shibboleth:mode [mode] ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_wnd_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_wnd_commands.adoc deleted file mode 100644 index 0a7501d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/app_commands/_wnd_commands.adoc +++ /dev/null @@ -1,133 +0,0 @@ -= Windows Network Drive (WND) - -Marketplace URL: {oc-marketplace-url}/apps/windows_network_drive[External Storage: Windows Network Drives] - -Integrate Windows and Samba/CIFS shared network drives as external storages. For details please see the -xref:enterprise/external_storage/windows-network-drive_configuration.adoc[Windows Network Drive (WND)] documentation. - -The `wnd` commands configure the WND app. - -[source,plaintext] ----- -wnd - wnd:listen Listen to smb changes and store notifications for later processing - wnd:process-queue Process the notifications stored by the wnd:listen command - wnd:set-service-account Sets the service account for the target mount point (deprecated) ----- - -Please see the -xref:enterprise/external_storage/windows-network-drive_configuration.adoc#wnd-notifications[Windows Network Drive Notifications] for how to properly setup `wnd:listen` and `wnd:process-queue`. - -== Configure the Listener - -Listen to smb changes and store notifications for later processing in the database - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen [options] [--] [] ----- - -=== Arguments - -[width="90%",cols="40%,80%",] -|=== -| `host` -| The hostname or IP address of the server to listen to -| `share` -| The share inside the host to listen to for changes -| `username` -| The username that will be used to connect to the share -| `password` -| The user's password (will be asked for if it isn't provided) -|=== - -=== Options - -[width="90%",cols="40%,80%",] -|=== -| `-p, + ---path=PATH` -| The path inside the share to watch for changes [default: ""] - -| `--password-file=PASSWORD-FILE` -| The file containing the password for the account to be used to listen - -| `--password-from-service-account` -| Use the password from the matching service account. This works only for collaborative WND mounts - -| `--password-trim` -| Trim blank characters from the password - -| `--unbuffering-option=UNBUFFERING-OPTION` -| Force the usage of that unbuffering option for the underlying smbclient command. Possible options are either "auto", "pty" or "stdbuf" [default: "auto"] - -| `--output[=OUTPUT]` -| The output format to use (plain, json or json_pretty). [default: "plain"] -|=== - -[NOTE] -==== -. To enter the password of the service account via the console, the `password` option, the `password-file` option and the `password-from-service-account` option must not be set. - -. To use the password for the service account from the mount point settings, use the `password-from-service-account` option. - -. If you use the `password` option together with the `password-file` option, the `password-file` option takes precedence over the `password` argument. -==== - -== Process Notifications - -Process the notifications stored by the `wnd:listen` command - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:process-queue [options] [--] ----- - -=== Arguments - -[width="90%",cols="40%,80%",] -|=== -| `host` -| The server whose notifications will be processed -| `share` -| The share whose notifications will be processed -|=== - -=== Options - -[width="90%",cols="40%,80%",] -|=== -| `--output[=OUTPUT]` -| The output format to use (plain, json or json_pretty). [default: "plain"] -|=== - -== Set the Service Account - -NOTE: This command is deprecated starting with ownCloud Classic 10.8. All mount options marked as _password_ are now encrypted by default. Existing old settings are migrated automatically. - -Sets the service account for the target mount point. You'll be asked for the password of the service account. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:set-service-account [options] [--] ----- - -Please see the occ documentation of -xref:configuration/server/occ_command.adoc#files_externallist[files_external:list] -to get the required mount-id. - -=== Arguments - -[width="90%",cols="40%,80%",] -|=== -| `mount-id` -| ID of the mount point. Use "occ files_external:list --short" to find it -|=== - -=== Options - -[width="90%",cols="40%,80%",] -|=== -| `--output[=OUTPUT]` -| The output format to use (plain, json or json_pretty). [default: "plain"] -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_2fa_core_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_2fa_core_commands.adoc deleted file mode 100644 index e7a912c..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_2fa_core_commands.adoc +++ /dev/null @@ -1,48 +0,0 @@ -= Two-Factor Authentication - -The following commands only enable or disable the two-factor authentication for a particular user. See the xref:two-factor-totp[Two-Factor TOTP] section for managing the two-factor app provided by ownCloud. - -If a two-factor provider app is enabled, it is enabled for all users by default but a user has to opt-in, though the provider can decide whether or not the user has to pass the challenge. In case a user is losing access to the second factor like a lost or defect phone with two-factor SMS/app verification, the user would now be locked out. To give the user access to his account, an admin can temporarily disable the two-factor check for that user via the occ command. After the issue has been fixed, the admin can reenable two-factor authentication for that user. - -The following commands are available for the two-factor authentication: - -[source,plaintext] ----- - twofactorauth - twofactorauth:disable Disable two-factor authentication for a user. - twofactorauth:enable Enable two-factor authentication for a user. ----- - -== Disable - -Disable two-factor authentication for a user: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} twofactorauth:disable [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `uid` -| The user (user id) to be disabled for two-factor authentication. -|=== - -== Enable - -Enable two-factor authentication for a user: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} twofactorauth:enable [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `uid` -| The user (user id) to be (re)enabled for twofactor authentication. -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_app_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_app_commands.adoc deleted file mode 100644 index dabc638..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_app_commands.adoc +++ /dev/null @@ -1,115 +0,0 @@ -= App Commands - -The `app` commands list, enable, and disable apps. - -[source,plaintext] ----- -app - app:check-code check code to be compliant - app:disable disable an app - app:enable enable an app - app:getpath Get an absolute path to the app directory - app:list List all available apps ----- - -== List Available Apps - -List all of your installed apps or optionally provide a search pattern to restrict the list of apps to those whose name matches the given regular expression. -The output shows whether they are enabled or disabled. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:list [--] [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `search-pattern` -| Show only those apps whose names match the given search pattern (regular expression). -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--enabled` -| Only display enabled apps. -When used, the output will contain the app's version number as well - -| `--disabled` -| Only display disabled apps. If the app was previously enabled, the app version is also displayed. -When used, the output will contain the app's version number as well, _if_ it was previously enabled - -| `--shipped=` -| If `SHIPPED` is set to `true`, only shipped apps will be listed. -If `SHIPPED` is set to `false`, only non-shipped apps will be listed - -| `-m` + -`--minimal` -| Minimal view - only display apps with version -When used, the output will contain the app's version number as well. - -| --output[=OUTPUT] -| The output format to use (`plain`, `json` or `json_pretty`). [default: "plain"] -|=== - -== Enable an App - -Enable an app, for example the Market app. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable market -market enabled ----- - -== Disable an App - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:disable market -market disabled ----- - -NOTE: Be aware that the following apps cannot be disabled: _DAV_, _FederatedFileSharing_, _Files_ and _Files_External_. - -== Check App Code - -`app:check-code` has multiple checks: - -* It checks if an app uses ownCloud's public API (`OCP`) or private API (`OC_`), -* It also checks for deprecated methods and the validity of the `info.xml` file. - -By default all checks are enabled. The Activity app is an example of a correctly-formatted app. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:check-code notifications -App is compliant - awesome job! ----- - -If your app has issues, you'll see output like this. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:check-code foo_app -Analysing /var/www/owncloud/apps/files/foo_app.php -4 errors - line 45: OCP\Response - Static method of deprecated class must not be called - line 46: OCP\Response - Static method of deprecated class must not be called - line 47: OCP\Response - Static method of deprecated class must not be called - line 49: OC_Util - Static method of private class must not be called ----- - -== Get the App Installation Path - -You can get the full file path to an app. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:getpath notifications -/var/www/owncloud/apps/notifications ----- - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_background_jobs_selector.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_background_jobs_selector.adoc deleted file mode 100644 index 57652ce..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_background_jobs_selector.adoc +++ /dev/null @@ -1,29 +0,0 @@ -= Background Jobs Selector - -Use the `background` command to select which scheduler you want to use for controlling xref:configuration/server/background_jobs_configuration.adoc[background jobs]. -This is the same as using the *Cron* section on your ownCloud Admin page. - -[source,plaintext] ----- -background - background:ajax Use ajax to run background jobs - background:cron Use cron to run background jobs - background:webcron Use webcron to run background jobs ----- - -== Examples - -[source,bash,subs="attributes+"] ----- -# Set the background scheduler to Ajax -{occ-command-example-prefix} background:ajax - -# Set the background scheduler to Cron -{occ-command-example-prefix} background:cron - -# Set the background scheduler to Webcron -{occ-command-example-prefix} background:webcron ----- - -TIP: Check out the sections xref:configuration/server/occ_command.adoc#managing-background-jobs[Managing Background Jobs] and xref:configuration/server/background_jobs_configuration.adoc[Background Jobs configuration] to learn more. - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_command_line_installation_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_command_line_installation_commands.adoc deleted file mode 100644 index 67ba27f..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_command_line_installation_commands.adoc +++ /dev/null @@ -1,124 +0,0 @@ -= Command Line Installation - -ownCloud can be installed entirely from the command line. After downloading the tarball and copying ownCloud into the appropriate directories, you can use `occ` commands in place of running the graphical Installation Wizard. Also see xref:installation/manual_installation/manual_installation.adoc[Manual Installation on Linux]. - -NOTE: These instructions assume that you have a fully working and configured webserver. -If not, please refer to the documentation on configuring xref:installation/manual_installation/manual_installation.adoc#configure-the-web-server[Configure the Web Server] for detailed instructions. - -Apply the xref:installation/manual_installation/manual_installation.adoc#script-guided-installation[correct permissions] to your ownCloud directories. Then choose your `occ` options. This lists your available options: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} occ -ownCloud is not installed - only a limited number of commands are available -ownCloud version 10.15.0 - -Usage: - [options] command [arguments] - -== Options - --help (-h) Display this help message - --quiet (-q) Do not output any message - --verbose (-v|vv|vvv) Increase the verbosity of messages: 1 for normal output, - 2 for more verbose output and 3 for debug - --version (-V) Display this application version - --ansi Force ANSI output - --no-ansi Disable ANSI output - --no-interaction (-n) Do not ask any interactive question - -Available commands: - check Check dependencies of the server environment - help Displays help for a command - list Lists commands - status Show some status information - app - app:check-code Check code to be compliant - l10n - l10n:createjs Create javascript translation files for a given app - maintenance - maintenance:install Install ownCloud ----- - - -== Command Description - -Display your `maintenance:install` options. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} help maintenance:install -ownCloud is not installed - only a limited number of commands are available -Usage: ----- - -[source,plaintext] ----- -maintenance:install [--database=["..."]] [--database-connection-string=["..."]] \ - [--database-name=["..."]] [--database-host=["..."]] \ - [--database-user=["..."]] [--database-pass=["..."]] \ - [--database-table-prefix=["..."]] [--admin-user=["..."]] \ - [--admin-pass=["..."]] [--data-dir=["..."]] ----- - -=== Options - -[width="100%",cols="22%,70%",] -|=== -| `--database` -a| Supported database type (default: `sqlite`). -The supported values are: - -* `mysql`: MySQL/MariaDB -* `oci`: Oracle (_ownCloud Enterprise edition only_) -* `pgsql`: PostgreSQL -* `sqlite`: SQLite3 (_ownCloud Community edition only_) - -| `--database-connection-string` -a| An Oracle-specific connection string. - -NOTE: As soon as this parameter is provided, other parameters like database-host and database-name are not used and do not need to be provided. -For example: - -*Example* - -[source,plaintext] ----- -sales= - (DESCRIPTION= - (ADDRESS= (PROTOCOL=tcp)(HOST=sales-server)(PORT=1521)) - (CONNECT_DATA= - (SERVICE_NAME=sales.us.acme.com))) ----- -| `--database-name` -| Name of the database. -| `--database-host` -| Hostname of the database (default: `localhost`). -| `--database-user` -| User name to connect to the database. -| `--database-pass` -| Password of the database user. -| `--database-table-prefix` -| Prefix for all tables (default: `oc_` ). -| `--admin-user` -| Password of the admin account. -| `--data-dir` -| Path to data directory (default: `/var/www/owncloud/data`). -|=== - -=== Example - -This example completes the installation: - -[source,bash,subs="attributes+"] ----- -cd /var/www/owncloud/ -{occ-command-example-prefix} maintenance:install \ - --database "mysql" \ - --database-name "owncloud" \ - --database-user "root" \ - --database-pass "password" \ - --admin-user "admin" \ - --admin-pass "password" -ownCloud is not installed - only a limited number of commands are available -ownCloud was successfully installed ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_command_line_upgrade_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_command_line_upgrade_commands.adoc deleted file mode 100644 index 16e9a15..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_command_line_upgrade_commands.adoc +++ /dev/null @@ -1,71 +0,0 @@ -= Command Line Upgrade - -These commands are available only after you have downloaded upgraded packages or tar archives, and before you complete the upgrade. -List all options, like this example on CentOS Linux: - -== Command Description - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} upgrade --help -Usage: -upgrade [options] ----- - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--major` | Automatically update apps to new major versions during minor updates of ownCloud Classic. -| `--no-app-disable` | Skip disabling of third party apps. -|=== - -When you are performing an update or upgrade on your ownCloud server (see the Maintenance section of this manual), it is better to use `occ` to perform the database upgrade step, rather than the Web GUI, in order to avoid timeouts. -PHP scripts invoked from the Web interface are limited to 3600 seconds. -In larger environments this may not be enough, leaving the system in an inconsistent state. -After performing all the preliminary steps (see xref:maintenance/upgrade.adoc[the maintenance upgrade documentation]) use this command to upgrade your databases, like this example on CentOS Linux: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} upgrade -ownCloud or one of the apps require upgrade - only a limited number of -commands are available -Turned on maintenance mode -Checked database schema update -Checked database schema update for apps -Updated database -Updating ... -Updated to 2.1.0 -Update successful -Turned off maintenance mode ----- - -Note how it details the steps. Enabling verbosity displays timestamps: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} upgrade -v -ownCloud or one of the apps require upgrade - only a limited number of commands are available -2017-06-23T09:06:15+0000 Turned on maintenance mode -2017-06-23T09:06:15+0000 Checked database schema update -2017-06-23T09:06:15+0000 Checked database schema update for apps -2017-06-23T09:06:15+0000 Updated database -2017-06-23T09:06:15+0000 Updated to 0.6.6 -2017-06-23T09:06:15+0000 Update successful -2017-06-23T09:06:15+0000 Turned off maintenance mode ----- - -If there is an error it throws an exception, and the error is detailed in your ownCloud logfile, so you can use the log output to figure out what went wrong, or to use in a bug report. - ----- -Turned on maintenance mode -Checked database schema update -Checked database schema update for apps -Updated database -Updating ... -Exception -ServerNotAvailableException: LDAP server is not available -Update failed -Turned off maintenance mode ----- - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_config_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_config_commands.adoc deleted file mode 100644 index 97f61ee..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_config_commands.adoc +++ /dev/null @@ -1,453 +0,0 @@ -= Config Commands - -The `config` commands are used to configure the ownCloud server. - -[NOTE] -==== -* In general, key names are not checked for validity, they are used as written. -* Whenever you use the *app* parameter, a config is read or written from or to the database. -* Whenever you use the *system* parameter, a config is read or written from or to the config.php file. -==== - ----- -config - config:app:delete Delete an app config value - config:app:get Get an app config value - config:app:set Set an app config value - config:import Import a list of configuration settings - config:list List all configuration settings - config:system:delete Delete a system config value - config:system:get Get a system config value - config:system:set Set a system config value ----- - -== config:app References - -The following apps, core functions or documents use/refer to `config:app` settings: - -.Standard -* xref:configuration/files/federated_cloud_sharing_configuration.adoc[Configuring Federation Sharing] -* xref:configuration/user/user_management.adoc#enabling-custom-groups[Custom Groups] -* xref:configuration/files/file_sharing_configuration.adoc[File Sharing] -* xref:configuration/server/security/hsmdaemon/index.adoc[The HSM (Hardware Security Module) Daemon (hsmdaemon)] -* xref:configuration/general_topics/impersonate_users.adoc[Impersonating Users] -* xref:configuration/user/user_auth_ldap.adoc[LDAP Integration] -* xref:configuration/server/legal_settings_configuration.adoc[Legal Settings Configuration] -* xref:configuration/files/manual_file_locking.adoc[Manual File Locking] -* xref:maintenance/manually-moving-data-folders.adoc[Manually Move a Data Directory] -* xref:configuration/user/oidc/oidc.adoc[OpenID Connect (OIDC)] -* xref:configuration/server/ui-configuration.adoc[UI Configuration] -* xref:configuration/server/virus-scanner-support.adoc[Virus Scanner Support] - -.Enterprise -* xref:enterprise/logging/admin_audit.adoc[Auditing] -* xref:enterprise/file_management/files_lifecycle.adoc[File Lifecycle Management] -* xref:enterprise/user_management/user_auth_shibboleth.adoc[Shibboleth Integration] - -.occ Commands -* xref:configuration/server/occ_command.adoc#anti-virus[occ Anti-Virus] -* xref:configuration/server/occ_command.adoc#auditing[occ Auditing] -* xref:configuration/server/occ_command.adoc#brute-force-protection[occ Brute Force Protection] -* xref:configuration/server/occ_command.adoc#collabora-online-secure-view[occ Collabora Online / Secure View] -* xref:configuration/server/occ_command.adoc#custom-groups[occ Custom Groups] -* xref:configuration/server/occ_command.adoc#encryption[occ Encryption] -* xref:configuration/server/occ_command.adoc#file-lifecycle-management[occ File Lifecycle Management] -* xref:configuration/server/occ_command.adoc#full-text-search[occ Full Text Search] -* xref:configuration/server/occ_command.adoc#ldap-integration[occ LDAP Integration] - -== config:system References - -The following apps, core functions or documents use/refer to `config:system` settings: - -.Standard -* xref:installation/quick_guides/ubuntu_20_04.adoc[Quick Install on Ubuntu 20.04] -* xref:installation/quick_guides/ubuntu_22_04.adoc[Quick Install on Ubuntu 22.04] - -.occ Commands -* xref:configuration/server/occ_command.adoc#metrics[occ Metrics] - -.Enterprise -* xref:enterprise/reporting/metrics.adoc[Metrics] - -== Config App Commands - -These commands manage the configurations of apps. Keys and values are stored in the database. - -== config:app:delete - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `app` | Name of the app. -| `name` | Name of the config to delete. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--error-if-not-exists` | Checks whether the config exists before deleting it. -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json_pretty`, default is `plain`). -|=== - -=== Examples: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete myappname provisioning_api -Config value provisioning_api of app myappname deleted ----- - -The delete command will by default not complain if the configuration was not set before. -If you want to be notified in that case, set the `--error-if-not-exists` flag. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete doesnotexist --error-if-not-exists -Config provisioning_api of app appname could not be deleted because it did not exist ----- - -== config:app:get - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:get [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `app` | Name of the app. -| `name` | Name of the config to get. -|=== - -=== Options - -[width="100%",cols="33%,70%",] -|=== -| `--default-value[=DEFAULT-VALUE]` | If no default value is set and the config does not exist, -the command will exit with 1. -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json_pretty`, default is `plain`). -|=== - -=== Examples - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:get activity installed_version -2.2.1 ----- - -== config:app:set - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `app` | Name of the app. Must not be an empty string. -| `name` | Name of the config to set. Must not be an empty string. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--value=[VALUE]` | The new value of the config. -| `--update-only` | Only updates the value. If it is not set before, it is not being added. -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json_pretty`, default is `plain`). -|=== - -=== Examples - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - files_sharing \ - incoming_server2server_share_enabled \ - --value=true \ - --type=boolean -Config value incoming_server2server_share_enabled for app files_sharing set to yes ----- - -The `config:app:set` command creates the value, if it does not already exist. To update an existing value, set `--update-only`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - doesnotexist \ - --value=true \ - --type=boolean \ - --update-only -Value not updated, as it has not been set before. ----- - -== General Config Commands -These commands manage listing and importing configurations. - -== config:import - -The exported content can also be imported again to allow the fast setup of similar instances. -The import command will only add or update values. -Values that exist in the current configuration, but not in the one that is being imported are left untouched. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:import filename.json ----- - -It is also possible to import remote files, by piping the input: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:import < local-backup.json ----- - -NOTE: While it is possible to update/set/delete the versions and installation statuses of apps and ownCloud itself, it is *not* recommended to do this directly. -Use the `occ app:enable`, `occ app:disable` and `occ update` commands instead. - -== config:list - -The `config:list` command lists all configuration values for your ownCloud setup as well as for any apps. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:list [options] [--] [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `app` -| Name of the app. You can use "_system_" to get the config.php values, or "_all_" (the default) for all apps and system. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--private` -| Use this option when you want to include sensitive configs, like passwords and salts. -|=== - -By default, passwords and other sensitive data are omitted from the report so that the output can be posted publicly (e.g., as part of a bug report). You can see a sample output in the example below. - -[source,json] ----- -include::partial$configuration/server/occ_command/config-list-report.json[] ----- - -=== Displaying Sensitive Information - -To generate a full report which includes sensitive values, such as passwords and salts, use the `--private` option, as in the following example. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:list --private ----- - -=== Filtering Information Reported - -The output can be filtered to just the core information, core and apps, or one specific app. -In the example below, you can see how to filter for each of these categories. - -[source,bash,subs="attributes+"] ----- -# List only system configuration details -{occ-command-example-prefix} config:list -- system - -# List system and app configuration details -# This is the default, so doesn't need to be explicitly specified -{occ-command-example-prefix} config:list -- all - -# List configuration details of the dav app -{occ-command-example-prefix} config:list -- dav ----- - -Below is an example of listing the config details for a single app. - -[source,json] ----- -{ - "apps": { - "files_versions": { - "enabled": "yes", - "installed_version": "1.3.0", - "types": "filesystem" - } - } -} ----- - -== Config System Commands -These commands manage system configurations. - -== config:system:delete - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:delete [options] [--] ()... ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `name` | Name of the config to delete, specify multiple for array parameter. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--error-if-not-exists` | Checks whether the config exists before deleting it. -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json_pretty`, default is `plain`). -|=== - -=== Examples: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:delete maintenance:mode -System config value maintenance:mode deleted ----- - -== config:system:get - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:get [options] [--] ()... ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `name` | Name of the config to get. Specify multiple for array parameter. -|=== - -=== Options - -[width="100%",cols="33%,70%",] -|=== -| `--default-value[=DEFAULT-VALUE]` | If no default value is set and the config does not exist, -the command will exit with 1. -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json_pretty`, default is `plain`). -|=== - -=== Examples: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:get version -10.7.0.4 ----- - -== config:system:set - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set [options] [--] ()... ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `name` | Name of the config parameter, specify multiple for array parameter. Must not be an empty string. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--type=[TYPE]` | Value type to use (`string`, `integer`, `double`, `boolean`, `json`, default is `string`). + -Note: you must use json to write multi array values. -| `--value=[VALUE]` | The new value of the config. -| `--update-only` | Only updates the value. If it is not set before, it is not being added. -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json_pretty`, default is `plain`). -|=== - -NOTE: In order to write a boolean, float, JSON, or integer value to the configuration file, you need to specify the type of your command. This applies only to the `config:system:set` command. See table above for available types. - -=== Examples - -Disable the maintenance mode: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set maintenance \ - --value=false \ - --type=boolean - -ownCloud is in maintenance mode - no app have been loaded -System config value maintenance set to boolean false ----- - -Create the `app_paths` config setting (using a JSON payload because of multi array values): - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set apps_paths \ - --type=json \ - --value='[ - { - "path":"/var/www/owncloud/apps", - "url":"/apps", - "writable": false - }, - { - "path":"/var/www/owncloud/apps-external", - "url":"/apps-external", - "writable": true - } - ]' ----- - -Adding Redis to the configuration: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set \ - redis \ - --value '{"host": "{oc-examples-server-ip}", "port": "{std-port-redis}"}' \ - --type json - -System config value redis set to json {"host": "{oc-examples-server-ip}", "port": "{std-port-redis}"} ----- - -Some configurations (e.g., the trusted domain setting) are an array of data. -The array starts counting with 0. In order to set (and also get) the value of one key, you can specify multiple `config` names separated by spaces: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:get trusted_domains -localhost -owncloud.local -sample.tld ----- - -To replace `sample.tld` with `example.com` trusted_domains => 2 needs to be set: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set trusted_domains 2 --value=example.com -System config value trusted_domains => 2 set to string example.com - -{occ-command-example-prefix} config:system:get trusted_domains -localhost -owncloud.local -example.com ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_config_reports_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_config_reports_commands.adoc deleted file mode 100644 index dc15bb7..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_config_reports_commands.adoc +++ /dev/null @@ -1,31 +0,0 @@ -= Config Reports - -If you're working with ownCloud support and need to send them a configuration summary, you can generate it using the `configreport:generate` command. -This command generates the same JSON-based report as the Admin Config Report, which you can access under `admin -> Settings -> Admin -> General -> Generate Config Report -> Download ownCloud config report`. - -From the command-line in the root directory of your ownCloud installation, run it as your webserver user as follows, (assuming your webserver user is `www-data`): - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} configreport:generate ----- - -This will generate the report and send it to `STDOUT`. -You can optionally pipe the output to a file and then attach it to an email to ownCloud support, by running the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} configreport:generate > generated-config-report.txt ----- - -Alternatively, you could generate the report and email it all in one command, by running: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} configreport:generate | mail \ - -s "configuration report" \ - -r \ - ----- - -NOTE: These commands are not available in xref:maintenance-commands[single-user (maintenance) mode]. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_database_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_database_commands.adoc deleted file mode 100644 index e024967..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_database_commands.adoc +++ /dev/null @@ -1,46 +0,0 @@ -= Database Commands - -== Database Conversion Commands - -=== Convert the Database Type - -The SQLite database is good for testing, and for ownCloud servers with small single-user workloads that do not use sync clients, but production servers with multiple users should use MariaDB, MySQL, or PostgreSQL. You can use `occ` to convert from SQLite to one of these other databases. - -[source,plaintext] ----- -db - db:convert-type Convert the ownCloud database to the newly configured one ----- - -You need: - -* Your desired database and its PHP connector installed. -* The login and password of a database admin user. -* The database port number, if it is a non-standard port. - -This is example converts SQLite to MySQL/MariaDB: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} db:convert-type mysql oc_dbuser 127.0.0.1 oc_database ----- - -TIP: For a more detailed explanation see xref:configuration/database/db_conversion.adoc[converting database types]. - -=== Convert the MySQL Charset - -Convert charset of MySQL/MariaDB to use utf8mb4. If you are using an older ownCloud installation, the database may not be setup to use the 4-byte unicode charset. This command changes the database charset to use `utf8mb4`. Check your database charset before you use this command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} db:convert-mysql-charset ----- - -== Restore the Table Format - -This command sets the default row format of MySQL/MariaDB tables. This is only necessary once before you are going to e.g. install MariaDB 10.6 or higher because the COMPRESSED row format is now read-only by default. As a prerequisite, ownCloud Classic 10.9 needs to be installed first. See the xref:maintenance/upgrading/database_upgrade.adoc[Database Upgrade] guide for details. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} db:restore-default-row-format ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_dav_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_dav_commands.adoc deleted file mode 100644 index ce89b5a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_dav_commands.adoc +++ /dev/null @@ -1,155 +0,0 @@ -= DAV Commands - -A set of commands to create and sync address books and calendars: - -[source,plaintext] ----- -dav - dav:cleanup-chunks Cleanup outdated chunks - dav:create-addressbook Create a dav address book - dav:create-calendar Create a dav calendar - dav:sync-birthday-calendar Synchronizes the birthday calendar - dav:sync-system-addressbook Synchronizes users to the system address book ----- - -NOTE: These commands are not available in xref:maintenance-commands[single-user (maintenance) mode]. - -== Cleanup Chunks - -`dav:cleanup-chunks` cleans up outdated chunks (uploaded files) more than a certain number of days old. By default, the command cleans up chunks more than 2 days old. However, by supplying the number of days to the command, the range can be increased. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:cleanup-chunks [options] [--] [] ----- - -=== Arguments - -[width="100%",cols="25%,70%",] -|==== -| `minimum-age-in-days` -| Minimum age of uploads to cleanup (in days - minimum 2 days - maximum 100) [default: 2] -|==== - -=== Options - -[width="100%",cols="25%,70%",] -|==== -| `-l` + -`--local` -| Only delete chunks that exist on the local filesystem. This applies to setups with multiple servers connected to the same database and chunk folder is not shared among them. -|==== - -=== Example - -In the example below, chunks older than 10 days will be removed. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:cleanup-chunks 10 - -# example output -Cleaning chunks older than 10 days(2017-11-08T13:13:45+00:00) -Cleaning chunks for admin - 0 [>---------------------------] ----- - -== Create Addressbook - -Create a dav address book. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:create-addressbook ----- - -=== Arguments - -[width="100%",cols="25%,70%",] -|==== -| `user` -| User for whom the address book will be created - -| `name` -| Name of the addressbook -|==== - -=== Example - -This example creates the address book `mollybook` for the user molly: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:create-addressbook molly mollybook ----- - -Molly will immediately see her address book. - -== Create Calendar - -Create a dav calendar. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:create-calendar ----- - -=== Arguments - -[width="100%",cols="25%,70%",] -|==== -| `user` -| User for whom the calendar will be created - -| `name` -| Name of the calendar -|==== - -=== Example - -This example creates a new calendar `mollycal` for user molly: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:create-calendar molly mollycal ----- - -Molly will immediately see her calendar. - -// NOTE: dav:migrate-addressbooks has been removed with: https://github.com/owncloud/core/pull/23976 - - -== Sync Birthday Calendar - -Synchronizes the birthday calendar. It adds all birthdays to your calendar from address books shared with you. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:sync-birthday-calendar [] ----- - -=== Arguments - -[width="100%",cols="25%,70%",] -|==== -| `user` -| User for whom the birthday calendar will be synchronized -|==== - -=== Example - -This example syncs to your calendar from user `bernie`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:sync-birthday-calendar bernie ----- - -== Sync System Addressbook - -Synchronizes all users to the system addressbook. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} dav:sync-system-addressbook ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_encryption_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_encryption_commands.adoc deleted file mode 100644 index 0f5b896..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_encryption_commands.adoc +++ /dev/null @@ -1,277 +0,0 @@ -= Encryption - -`occ` includes a complete set of commands for managing encryption. When using a HSM (Hardware Security Module, can also be emulated by software), additional occ encryption-related commands can be used. - -[source,plaintext] ----- -encryption - config:app:set encryption encryptHomeStorage Encrypt the users home storage - - encryption:change-key-storage-root Change key storage root - encryption:decrypt-all Disable server-side encryption and decrypt all files - encryption:disable Disable encryption - encryption:enable Enable encryption - encryption:encrypt-all Encrypt all files for all users - encryption:fix-encrypted-version Fix the encrypted version if the encrypted file(s) are - not downloadable. - encryption:list-modules List all available encryption modules - encryption:migrate Initial migration to encryption 2.0 - encryption:recreate-master-key Replace existing master key with new one. Encrypt the - file system with newly created master key - encryption:select-encryption-type Select the encryption type. Only `masterkey` is available. - Note that this setting is only necessary when migration from user - key encryption. New encryptions will autmatically use master key. - encryption:set-default-module Set the encryption default module - encryption:show-key-storage-root Show current key storage root - encryption:status Lists the current status of encryption ----- - -When using a HSM (Hardware Security Module, additional occ encryption-related commands can be used, see the HSM occ documentation below. The occ commands can also be used when HSM is initiated via software emulation like SoftHSM2. - -[source,plaintext] ----- -encryption - encryption:hsmdaemon Export or Import the Masterkey - encryption:hsmdaemon:decrypt Decrypt a String - config:app:set encryption Various encryption configuration commands for HSM ----- - -== Status - -`occ encryption:status` shows whether you have active encryption and your default encryption module. -To enable encryption you must first enable the Encryption app and then run `occ encryption:enable`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable encryption -{occ-command-example-prefix} encryption:enable -{occ-command-example-prefix} encryption:status - - enabled: true - - defaultModule: OC_DEFAULT_MODULE ----- - -== Encrypt the Users Home Storage - -Server-side encryption for local storage like the users home and remote storages like Google Drive can operate independently of each other. By doing so, you can encrypt a remote storage without also having to encrypt the users home storage on your ownCloud server. Possible values are `0` and `1` - -[source,bash,subs="attributes+"] ----- -config:app:set encryption encryptHomeStorage --value '1' ----- - -== Change Key Storage Root - -`encryption:change-key-storage-root` is for moving your encryption keys to a different folder within your data directory. -It takes one argument, which defines your new root folder. -The folder must exist and the path is relative to your data directory. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:change-key-storage-root ../data/security/oc-keys ----- - -You can see the current location of your keys folder: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:show-key-storage-root -Current key storage root: default storage location (data/) ----- - -== List Modules - -`encryption:list-modules` displays your available encryption modules. -You will see a list of modules only if you have enabled the Encryption app. -Use `encryption:set-default-module [module name]` to set your desired module. - -== Encrypt All - -`encryption:encrypt-all` encrypts all data files for all users. -You must first put your ownCloud server into xref:maintenance-commands[single-user mode] to prevent any user activity until encryption is completed. - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `-y` + -`--yes` -| Answer yes to all questions. + -This argument automatically answers, potential, questions with "yes", which is particularly important for automated deployments with Ansible or similar tools. -|=== - -== Decrypt All - -`encryption:decrypt-all` decrypts all user data files, or optionally a single user: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:decrypt freda ----- - -Users must have enabled recovery keys on their Personal pages. You must first put your ownCloud server into single-user mode, using xref:maintenance-commands[the maintenance commands], to prevent any user activity until decryption is completed. - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `-m=[METHOD]` -| Accepts the methods: + -`recovery` or `password` + -If the _recovery_ method is chosen, then the recovery password will be used to decrypt files. + -If the _password_ method is chosen, then individual user passwords will be used to decrypt files. - -| `-c=[COMMAND]` -| Accepts the commands: + -`yes` or `no` + -This lets the command know whether to ask for permission to continue or not. -|=== - -=== Method Descriptions - -==== Recovery method - -This method reads the value from the environment variable `OC_RECOVERY_PASSWORD`. -This variable bounds the value of recovery password set in the encryption page. -If this variable is not set the recovery process will be halted. -This has to be used for decrypting all users. -While opting recovery method user should not forget to set `OC_RECOVERY_PASSWORD` in the shell. - -==== Password method - -This method reads the value from the environment variable `OC_PASSWORD`. -This variable bounds the value of user password. -The password which user uses to login to oC account. -When password method is opted the user needs to set this variable in the shell. - -==== Continue Option Description - -The continue option can be used to bypass the permissions asked like `yes` or `no` while decrypting the file system. -If the user is sure about what he/she is doing with the command and would like to proceed, then `-c yes` when provided to the command would not ask permissions. -If `-c no` is passed to the command, then permissions would be asked to the user. It becomes interactive. - -Use `encryption:disable` to disable your encryption module. -You must first put your ownCloud server into xref:maintenance-commands[single-user mode] to prevent any user activity. - -`encryption:migrate` migrates encryption keys after a major ownCloud version upgrade. -You may optionally specify individual users in a space-delimited list. -See xref:configuration/files/encryption/encryption_configuration.adoc[encryption configuration] to learn more. - -`encryption:recreate-master-key` decrypts the ownCloud file system, replaces the existing master key with a new one, and encrypts the entire ownCloud file system with the new master key. -Given the size of your ownCloud filesystem, this may take some time to complete. -However, if your filesystem is quite small, then it will complete quite quickly. -The `-y` switch can be supplied to automate acceptance of user input. - -== Fix Encrypted Version - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:fix-encrypted-version [options] [--] ----- - -`encryption:fix-encrypted-version` fixes the encrypted version of files if the encrypted file(s) are not downloadable for a given user. You only need this command if you get an "Invalid Signature" message in the browser or the clients. - -Background: the `oc_filecache` database table contains the integer columns "version" and "encryptedVersion" which start with 1 and are incremented on every file modification. When using encryption, those values are used together with the ciphertext to generate a cryptographic signature for the file. The version value is required to verify the signature. In some very rare cases like timeouts or bugs etc., the value might not get updated accordingly or get lost. The brute-force approach is to use the `fix:encrypted:version` command until the file can be decrypted. Starting with ownCloud Classic 10.8, the behavior of the command got improved so that the encryptedVersion value is reset to its original value if no correct version was found. Before that fix, the last tried value was stored in the database thus modifying the state of the system and making further rescue attempts non-deterministic. - -=== Arguments - -[width="100%",cols="30%,70%",] -|=== -| `user` -| The id of the user whose files need fixing. -|=== - -=== Options - -[width="100%",cols="30%,70%",] -|=== -| `-p` + -`--path=PATH` -| Limit files to fix with path, e.g., --path="/Music/Artist". + -If path indicates a directory, all the files inside directory will be fixed. - -| `-i` + -`--increment-range=INCREMENT-RANGE` -| Find the correct version of the file to verify the signature. + -Searches in increments from -n to +n. [default: "5"] -|=== - -== HSM Related Commands - -=== Export or Import the Masterkey - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:hsmdaemon [options] ----- - -=== Options - -[width="100%",cols="30%,70%",] -|=== -| `--export-masterkey` -| Export the private master key in base64 - -| `--import-masterkey= + -IMPORT-MASTERKEY` -| Import a base64 encoded private masterkey. -|=== - -`--export-masterkey` prints the base64_encode of the file `data/files_encryption/OC_DEFAULT_MODULE/master_*.privateKey`. - -The private key file in the directory may be named like `master_08ea43b7.privateKey`. - - -=== Test to Decrypt a String - -Allows to test the `hsmdaemon` setup by providing an encrypted string to ownCloud and test if it can be decrypted. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:hsmdaemon:decrypt [options] [--] ----- - -=== Arguments - -[width="100%",cols="30%,70%",] -|=== -| `decrypt` -| The string to decrypt -|=== - -=== Options - -[width="100%",cols="30%,70%",] -|=== -| `--username[=USERNAME]` -| The name of the user who is able to decrypt the provided string - -| `--keyId[=KEYID]` -| The keyId which was used to encrypt the provided string -|=== - -=== Set the HSM URL - -Set the url on which the `hsmdaemon` REST-API is reachable. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set encryption hsm.url --value 'http://127.0.0.1:8513' ----- - -=== Set the JSON Web Token Secret - -To access the `hsmdaemon` API, ownCloud must authenticate with a JWT (JSON Web Token). The given secret is shared between the `hsdmdaemon` (see the hsmdaemon.toml configuration file) and ownCloud to sign the JWT. See the xref:configuration/server/security/hsmdaemon/index.adoc[HSM documentation] for an example how to generate a secret. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set encryption hsm.jwt.secret --value '7a7d1826-b514-4d9f-afc7-a7485084e8de' ----- - -=== Set the JWT Clockskew - -The JWT described above has an expiry timestamp. In case the time clocks on ownCloud and hsmdaemon system drift or skew apart, additional time is added to the expiry time to counteract this situation. Set or change the clockskew only if ownCloud advises to do so. Defaults to 120, value is in seconds. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set encryption hsm.jwt.clockskew --value '120' ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_federation_sync_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_federation_sync_commands.adoc deleted file mode 100644 index 5ddd017..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_federation_sync_commands.adoc +++ /dev/null @@ -1,13 +0,0 @@ -= Federation Sync - -Synchronize the address books of all federated ownCloud servers. - -Servers connected with federation shares can share user address books, and auto-complete usernames in share dialogs. -Use this command to synchronize federated servers: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} federation:sync-addressbooks ----- - -NOTE: This command is only available when the "Federation" app (`federation`) is enabled. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_federation_trusted_servers.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_federation_trusted_servers.adoc deleted file mode 100644 index 95d528f..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_federation_trusted_servers.adoc +++ /dev/null @@ -1,102 +0,0 @@ -= Federation Trusted Servers - -A set of commands to manage trusted federated servers from the command line. - -[source,plaintext] ----- -federation:trusted-servers - federation:trusted-servers:add - federation:trusted-servers:list - federation:trusted-servers:remove ----- - -== Add a Trusted Server - -This command adds a trusted federated server. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} federation:trusted-servers:add ----- - -=== Arguments - -[width="100%",cols="25%,70%",] -|==== -| `url` -| The url pointing to the server, such as \https://myserver:8888/server/owncloud -|==== - -=== Example - -In the example below, the named trusted server is added. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} federation:trusted-servers:add / - https://myserver:8888/server/owncloud ----- - -== List Trusted Servers - -This command lists all trusted federated servers that have been added. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} federation:trusted-servers:list ----- - -=== Example - -In the example below, all trusted servers that have been added are listed. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} configured - ----- - -*Output:* - -[source,plaintext] ----- -+----+--------------------------------------------+--------+ -| id | server | status | -+----+--------------------------------------------+--------+ -| 1 | https://oc10130b1.qa.owncloud.test | OK | -| 2 | https://oc10122-20230818.qa.owncloud.test | OK | -+----+--------------------------------------------+--------+ ----- - -== Remove a Trusted Server - -This command removes a trusted federated server. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} federation:trusted-servers:remove ----- - -=== Arguments - -[width="100%",cols="25%,70%",] -|==== -| `id` -| The id of the server. Check with occ federation:trusted-servers:list -|==== - -=== Example - -In the example below, the trusted server with ID=2 gets removed. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} federation:trusted-servers:remove 2 ----- - -*Output:* - -[source,plaintext] ----- -Removed server with id 2 ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_file_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_file_commands.adoc deleted file mode 100644 index b318bb1..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_file_commands.adoc +++ /dev/null @@ -1,420 +0,0 @@ -= File Operations - -`occ` has the following commands for managing files in ownCloud. - -[source,plaintext] ----- -files - files:check-cache Check if the target file exists in the primary storage - files:checksums:verify Get all checksums in filecache and compares them by - recalculating the checksum of the file. - files:cleanup Deletes orphaned file cache entries. - files:remove-storage Remove a storage from the storages table and related files - from the filecache table. - files:scan Rescans the filesystem. - files:transfer-ownership All files and folders are moved to another user - - outgoing shares are moved as well (incoming shares are - not moved as the sharing user holds the ownership of the respective files). - files:troubleshoot-transfer-ownership - Scan for problems that might have occurred while running ownership transfer ----- - -IMPORTANT: These commands are not available in xref:maintenance-commands[single-user (maintenance) mode]. - -== The files:check-cache command - -The main purpose of this command is to clear the cache for objectstores (`objectstore` and `files_primary_S3` apps) as primary storage, but it is not limited to this type of storage. It can be used for any other type as long it is the primary storage. - -Files in the primary storage could be deleted outside of ownCloud, leaving information in ownCloud's file cache. -This command intends to check if the target file can be read from the primary backend storage and, if not, allows you to remove the information cached. - -[NOTE] -==== -Removing files directly from the primary storage is not supported and should not happen. -As such, the cases where you need to run this command should be extremely rare. -This is why this command is only provided to check for one file instead of scanning the whole of ownCloud's filesystem. -==== - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:check-cache --help - Usage: - files:check-cache [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `uid` | The user (user id) who owns the file -| `target-file` | The file we want to check -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--remove` | Remove the file from the cache if it's missing in the backend -|=== - -Examples of checking files for user maria: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:check-cache maria welcome.txt - -welcome.txt has been accessed properly ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:check-cache maria maria@smbhome/myfile.txt - -Ignoring maria@smbhome/myfile.txt because it is shared or not inside the primary storage - ----- - -== The files:checksums:verify command - -ownCloud supports file integrity checking, by computing and matching checksums. -Doing so ensures that transferred files arrive at their target in the exact state as they left their origin. - -In some rare cases, wrong checksums are written to the database which leads to synchronization issues, such as with the Desktop Client. -To mitigate such problems a new command is available: `occ files:checksums:verify`. - -Executing the command recalculates checksums, either for all files of a user or within a specified filesystem path on the designated storage. -It then compares them with the values in the database. -The command also offers an option to repair incorrect checksum values (`-r, --repair`). - -CAUTION: Executing this command might take some time depending on the file count. - -Below is sample output that you can expect to see when using the command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:checksums:verify - -This operation might take very long. -Mismatch for files/welcome.txt: - Filecache: SHA1:eeb2c08011374d8ad4e483a4938e1aa1007c089d MD5:368e3a6cb99f88c3543123931d786e21 ADLER32:c5ad3a63 - Actual: SHA1:da39a3ee5e6b4b0d3255bfef95601890afd80709 MD5:d41d8cd98f00b204e9800998ecf8427e ADLER32:00000001 -Mismatch for thumbnails/9/2048-2048-max.png: - Filecache: SHA1:2634fed078d1978f24f71892bf4ee0e4bd0c3c99 MD5:dd249372f7a68c551f7e6b2615d49463 ADLER32:821230d4 - Actual: SHA1:da39a3ee5e6b4b0d3255bfef95601890afd80709 MD5:d41d8cd98f00b204e9800998ecf8427e ADLER32:00000001 ----- - -=== Options - -[width="100%",cols="20%,70%",] -|=== -|`-r, --repair` -|Repair filecache-entry with mismatched checksums. - -|`-u, --user=USER` -|Specific user to check. - -|`-p, --path=PATH` -|Path to check relative to user folder. [default: ""]. -For example, if the user's id was "john" and the `--path` value was "tree/apple", the command would check the ownCloud directory `/john/files/tree/apple`. -|=== - -== The files:cleanup command - -`files:cleanup` tidies up the server's file cache by deleting all file entries that have no matching entries in the storage table. - -== The files:remove-storage command - -When a mount point gets removed, the storage ID and file cache related info stay in the database. Over time, this can consume a considerable amount of database space and can slow down database queries. With the `files:remove-storage` command, these orphans can be removed. As a rule of thumb, though not essential, this command should be run in single user mode to avoid any conflicting access. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:remove-storage --help - Usage: - files:remove-storage [options] [--] []... ----- - -=== Arguments - -[width="100%",cols="23%,70%",] -|=== -| `storage-id` | The numeric ID of the storage. -|=== - -=== Options - -[width="100%",cols="25%,70%",] -|=== -| `--chunk-size=[value]` | The number of rows that will be deleted at the same time. Defaults to 1000. -| `--show-candidates` | Show possible candidates for obsolete storages. This query can take a while. -|=== - -[IMPORTANT] -==== -This command should be handled with absolute care because *any* storage ID and the correlated file cache can be removed. For safety reasons, the following advices are given: - -* Switch to single user mode. -* Make a backup of the database first. -* To identify removal candidates, run this command with option `--show-candidates` first. -==== - -=== Example Output - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:remove-storage --show-candidates ----- - -[source,plaintext] ----- -+------------+-------------------------------------------------+------------+ -| storage-id | name | file_count | -+------------+-------------------------------------------------+------------+ -| 3 | local::/mnt/project/files/ | 3 | -| 12 | wnd::MOUNTAIN\mountainUser1@10.0.2.203/foobar// | 9 | -| 15 | NULL | 8 | -+------------+-------------------------------------------------+------------+ ----- - -Note that the name can be NULL as shown at storage 15 if there is no info about it in the `oc_storages` table. It can also be hashed if it's too long (as it is in the DB). - -== The files:scan command - -The `files:scan` command - -* Scans for new files. -* Scans not fully scanned files. -* Repairs file cache holes. -* Updates the file cache. - -File scans can be performed per-user, for a space-delimited list of users, for groups of users, and for all users. - -IMPORTANT: Scanning is only possible when using POSIX filesystems but not for object storages like S3. This is because the object storage implementation uses the database as primary data source and the S3 storage for only holding the data blobs but no metadata. A sync from S3 storage to database is therefore not reasonable. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:scan --help - Usage: - files:scan [options] [--] []... ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `user_id` | Will rescan all files of the given user(s). -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json_pretty`, default is `plain`). -| `-p --path=[PATH]` | Limit rescan to this path, e.g. --path="/alice/files/Music", -the user_id is determined by the path and the user_id parameter and --all are ignored. -| `--group=[GROUP]` | Scan user(s) under the group(s). - This option can be used as --group=foo --group=bar to scan groups foo and bar (multiple values allowed) -| `-g --groups=[GROUP]` | Scan user(s) under the group(s). - This option can be used as --groups=foo,bar to scan groups foo and bar (multiple values allowed separated by commas) -| `-q --quiet` | Do not output any message. -| `--all` | Will rescan all files of all known users. -| `--repair` | Will repair detached filecache entries (slow). -| `--unscanned` | Only scan files which are marked as not fully scanned. -|=== - -TIP: If not using `--quiet`, statistics will be shown at the end of the scan. - -=== The `--path` Option - -When using the `--path` option, the path must be in one of the following formats: - ----- -"user_id/files/path" -"user_id/files/mount_name" -"user_id/files/mount_name/path" ----- - -For example: - ----- ---path="/alice/files/Music" ----- - -In the example above, the user_id `alice` is determined implicitly from the path component given. -To get a list of scannable mounts for a given user, use the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files_external:list user_id ----- - -TIP: Mounts are only scannable at the point of origin. -Scanning of shares including federated shares is not necessary on the receiver side and therefore not possible. - -NOTE: Mounts based on session credentials can not be scanned as the users credentials are not available to the occ command set. - - -The `--path`, `--all`, `--group`, `--groups` and `[user_id]` parameters are exclusive - only one must be specified. - -=== The `--repair` Option - -As noted above, repairs can be performed for individual users, groups of users, and for all users in an ownCloud installation. -What's more, repair scans can be run even if no files are known to need repairing and if one or more files are known to be in need of repair. -Two examples of when files need repairing are: - -* If folders have the same entry twice in the web UI (known as a '__ghost folder__'), this can also lead to strange error messages in the desktop client. -* If entering a folder doesn't seem to lead into that folder. - -CAUTION: We strongly suggest that you backup the database before running this command. - -The `--repair` option can be run within two different scenarios: - -* Requiring a downtime when used on all affected storages at once. -* Without downtime, filtering by a specified User Id. - -The following commands show how to enable single user mode, run a repair file scan in bulk on all storages, and then disable single user mode. -This way is much faster than running the command for every user separately, but it requires single user mode. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on -{occ-command-example-prefix} files:scan --all --repair -{occ-command-example-prefix} maintenance:singleuser --off ----- - -The following command filters by the storage of the specified user. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:scan USERID --repair ----- - -TIP: If many users are affected, it could be convenient to create a shell script, which iterates over a list of User ID's. - -== The files:transfer-ownership command - -You may transfer all files and *outgoing* shares from one user to another. - -Incoming shares are not transferred. - -If the target users don't exist, they will be created. - -This command is useful before removing users. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:transfer-ownership --help - Usage: - files:transfer-ownership [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `source-user` | owner of files which shall be moved -| `destination-user` | user who will be the new owner of the files -|=== - -=== Options - -[width="100%",cols="35%,70%",] -|=== -| `--path=[PATH]` | selectively provide the path to transfer. + -For example --path="folder_name" -| `-s, + ---accept-skipped-shares` | always confirm to continue in case of skipped shares. -| `--destination-use-user-folder` | transfer directly to top-level user folder, + -operation only possible if destination user + -never logged in and command aborts otherwise. -|=== - - -For example, to move all files from `` to `` transfer folder, use the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:transfer-ownership \ - \ - ----- - -You can also move a limited set of files from `` to `` transfer folder by making use of the `--path` switch, as in the example below. -Ownership of `folder/to/move` and all files and folders which it contains will be transferred to `` transfer folder. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:transfer-ownership \ - --path="folder/to/move" \ - \ - ----- - -If the entire user folder of `` needs to be migrated to `` user folder, use the `--destination-use-user-folder` switch, as in the example below. -The destination user needs to be created but never log in, we recommend using owncloud maintenance mode for this operation. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:transfer-ownership \ - --destination-use-user-folder \ - \ - ----- - -Please keep the following in mind when using this command: - -. The directory provided to the `--path` switch *must* exist inside `data//files`. -. The directory and its contents won't be moved as-is between the users. - It will be moved into the destination user's `files` directory, into a directory name which follows the format: `transferred from on `. - Using the example above, it will be stored under: `data//files/transferred from on 20170426_124510/` -. Currently file versions can't be transferred. - Only the latest version of moved files will appear in the destination user's account. - -== The files:troubleshoot-transfer-ownership command - -This command is used to scan for problems, that might have occurred during a run of -ownership transfer using the above command `files:transfer-ownership`. -It can also be used to automatically attempt to fix problems. -For example, transferred shares that may now have an invalid share owner. - -NOTE: By default, the command performs a dry run and displays the problems found to the console output. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:troubleshoot-transfer-ownership --help - Usage: - files:troubleshoot-transfer-ownership [options] [--] [] ----- - -=== Arguments - -[width="100%",cols="30%,90%",] -|=== -| `type` | "all", "invalid-owner", "invalid-initiator", + -[default: ""] -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-f, --fix` | perform auto-fix for found problems -| `-u, --uid=UID` | scope for particular user -|=== - -Run the command with one of the type arguments: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:troubleshoot-transfer-ownership \ - ----- - -The command can attempt to fix the issues with the `--fix` flag, + -or execute for a single user using `--uid ` - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:troubleshoot-transfer-ownership all \ - --fix \ - --uid=UID ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_files_external_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_files_external_commands.adoc deleted file mode 100644 index ed0f5d8..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_files_external_commands.adoc +++ /dev/null @@ -1,382 +0,0 @@ -= Files External - -These commands replace the `data/mount.json` configuration file used in ownCloud releases before 9.0. -Commands for managing external storage. - -[source,plaintext] ----- -files_external - files_external:applicable Manage applicable users and groups for a mount - files_external:backends Show available authentication and storage backends - files_external:config Manage backend configuration for a mount - files_external:create Create a new mount configuration - files_external:delete Delete an external mount - files_external:export Export mount configurations - files_external:import Import mount configurations - files_external:list List configured mounts - files_external:option Manage mount options for a mount - files_external:verify Verify mount configuration ----- - -These commands replicate the functionality in the ownCloud Web GUI, plus two new features: `files_external:export` and `files_external:import`. - -Use `files_external:export` to export all admin mounts to stdout, and `files_external:export [user_id]` to export the mounts of the specified ownCloud user. - -NOTE: These commands are only available when the "External storage support" app (`files_external`) is enabled. -It is not available in xref:maintenance-commands[single-user (maintenance) mode]. - -== files_external:list - -List configured mounts. - -=== Usage - -[source,plaintext] ----- -files_external:list [--show-password] [--full] [-a|--all] [-s|--short] [--] [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `user_id` | User ID to list the personal mounts for, if no user is provided admin mounts will be listed. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--show-password` | Show passwords and secrets -| `--mount-options` | Show all mount options independent if they are set to their default value or not -| `--full` | Don't truncate long values in table output -| `-a, --all` | Show both system-wide mounts and all personal mounts. -| `-s, --short` | Show only a reduced mount info. -| `-i, --importable-format`| Provide output values in a format compatible with files_external:import -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json_pretty`, default is `plain`). -|=== - -=== Example - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files_external:list user_1 --short -+----------+------------------+----------+ -| Mount ID | Mount Point | Type | -+----------+------------------+----------+ -| 1 | /mount_1 | Personal | -| 2 | /mount_2 | Personal | -+----------+------------------+----------+ ----- - -NOTE: The `--importable-format` option helps to make the technical mount settings visible. -To see all settings you still need to use the other options such as `--show-password`, -`--full` and `--all`. When you want to export the mount settings for later import, -use the `files_external:export` command. `files_external:export` ensures that all the -necessary settings are included in the output. - -== files_external:applicable - -Manage applicable users and groups for a mount. - -=== Usage - -[source,plaintext] ----- -files_external:applicable - [--add-user ADD-USER] - [--remove-user REMOVE-USER] - [--add-group ADD-GROUP] - [--remove-group REMOVE-GROUP] - [--remove-all] - [--output [OUTPUT]] - [--] - ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `mount_id` | Can be obtained using `occ files_external:list`. -|=== - - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--add-user` | user to add as applicable (multiple values allowed). -| `--remove-user` | user to remove as applicable (multiple values allowed). -| `--add-group` | group to add as applicable (multiple values allowed). -| `--remove-group` | group to remove as applicable (multiple values allowed). -| `--remove-all` | Set the mount to be globally applicable. -| `--output=[OUTPUT]` | The output format to use (plain, json or json_pretty, default is plain). -|=== - -== files_external:backends - -Show available authentication and storage backends. - -=== Usage - -[source,plaintext] ----- -files_external:backends [options] - [--] - [] - [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `type` | Only show backends of a certain type. Possible values are `authentication` or `storage`. -| `backend` | Only show information of a specific backend. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--output=[OUTPUT]` | The output format to use (plain, json or json_pretty, default is plain. -|=== - -== files_external:config - -Manage backend configuration for a mount. - -=== Usage - -[source,plaintext] ----- -files_external:config [options] - [--] - - - [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `mount_id` | The ID of the mount to edit. -| `key` | Key of the config option to set/get. -| `value` | Value to set the config option to, when no value is provided the -existing value will be printed. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--output=[OUTPUT]` | The output format to use (_plain_, _json_ or _json_pretty_. The default is plain). -|=== - -== files_external:create - -Create a new mount configuration. - -=== Usage - -[source,plaintext ----- -files_external:create [options] - [--] - - - ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `mount_point` | Mount point for the new mount. -| `storage_backend` | Storage backend identifier for the new mount, see -`occ files_external:backends` for possible values. -| `authentication_backend` | Authentication backend identifier for the new mount, see -`occ files_external:backends` for possible values. -|=== - -==== Options - -[width="100%",cols="20%,70%",] -|=== -| `--user=[USER]` | User to add the mount configurations for, -if not set the mount will be added as system mount. -| `-c, --config=[CONFIG]` | Mount configuration option in `key=value` format (multiple values allowed). -| `--dry` | Don't save the imported mounts, only list the new mounts. -| `--output=[OUTPUT]` | The output format to use (`plain`, `json` or `json`pretty`). -The default is `plain`. -|=== - -=== Storage Backend Details - -[width="80%",cols="40%,60%",options="header"] -|=== -| Storage Backend | Identifier -| Windows Network Drive | `windows_network_drive` -| WebDav | `dav` -| Local | `local` -| ownCloud | `owncloud` -| SFTP | `sftp` -| Amazon S3 | `amazons3` -| Dropbox | `dropbox` -| Google Drive | `googledrive` -| SMB / CIFS | `smb` -|=== - -=== Authentication Details - -[width="80%",cols="40%,60%",options="header"] -|=== -| Authentication method | Identifier, name, configuration - -| Log-in credentials, save in session | `password::sessioncredentials` -| Log-in credentials, save in database | `password::logincredentials` -| User entered, store in database | `password::userprovided` (*) -| Global Credentials | `password::global` -| None | `null::null` -| Builtin | `builtin::builtin` -| Username and password | `password::password` -| OAuth1 | `oauth1::oauth1` (*) -| OAuth2 | `oauth2::oauth2` (*) -| RSA public key | `publickey::rsa` (*) -| OpenStack | `openstack::openstack` (*) -| Rackspace | `openstack::rackspace` (*) -| Access key (Amazon S3) | `amazons3::accesskey` (*) -|=== - -(*) - Authentication methods require additional configuration. - -NOTE: Each Storage Backend needs its corresponding authentication methods. - -== files_external:delete - -Delete an external mount. - -=== Usage - -[source,plaintext] ----- -files_external:delete [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `mount_id` | The ID of the mount to edit. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-y, --yes` | Skip confirmation. -| `--output=[OUTPUT]` | The output format to use (plain, json or json_pretty, default is plain). -|=== - -== files_external:export - -=== Usage - -[source,plaintext] ----- -files_external:export [options] [--] [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `user_id` | User ID to export the personal mounts for, if no user is provided admin -mounts will be exported. -|=== - -==== Options - -[width="100%",cols="20%,70%",] -|=== -| `-a, --all` | Show both system-wide mounts and all personal mounts. -|=== - -== files_external:import - -Import mount configurations. - -=== Usage - -[source,plaintext ----- -files_external:import [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `path` | Path to a json file containing the mounts to import, use `-` to read from stdin. -|=== - -==== Options - -[width="100%",cols="20%,70%",] -|=== -| `--user=[USER]` | User to add the mount configurations for, if not set the mount will be -added as system mount. -| `--dry` | Don't save the imported mounts, only list the new mounts. -| `--output=[OUTPUT]` | The output format to use (_plain_, _json_ or _json_pretty_, default is _plain_). -|=== - -== files_external:option - -Manage mount options for a mount. - -=== Usage - -[source,plaintext] ----- -files_external:option [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `mount_id` | The ID of the mount to edit. -| `key` | Key of the mount option to set/get. -| `value` | Value to set the mount option to, when no value is provided the existing -value will be printed. -|=== - -== files_external:verify - -Verify mount configuration. - -=== Usage - -[source,plaintext] ----- -files_external:verify [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `mount_id` | The ID of the mount to check. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-c, --config=[CONFIG]` | Additional config option to set before checking in `key=value` pairs, -required for certain auth backends such as login credentials (multiple values allowed). -| `--output=[OUTPUT]` | The output format to use (_plain_, _json_ or _json_pretty_, default is plain). -|=== - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_group_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_group_commands.adoc deleted file mode 100644 index d311cc8..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_group_commands.adoc +++ /dev/null @@ -1,181 +0,0 @@ -= Group Commands - -The `group` commands provide a range of functionality for managing ownCloud groups. -This includes creating and removing groups and managing group membership. -Group names are case-sensitive, so "Finance" and "finance" are two different groups. - -The full list of commands is: - -[source,plaintext] ----- -group - group:add Adds a group - group:add-member Add members to a group - group:delete Deletes the specified group - group:list List groups - group:list-members List group members - group:remove-member Remove member(s) from a group ----- - -== Creating Groups - -You can create a new group with the `group:add` command. The syntax is: - ----- -group:add groupname ----- - -This example adds a new group, called "Finance": - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:add Finance - Created group "Finance" ----- - -== Listing Groups - -You can list the names of existing groups with the `group:list` command. -The syntax is: - ----- -group:list [options] [] ----- - -Groups containing the `search-pattern` string are listed. -Matching is not case-sensitive. -If you do not provide a search-pattern then all groups are listed. - -=== Options - -[width="100%",cols="20%,50%",] -|==== -| `--output=[OUTPUT]` | Output format (plain, json or json_pretty, default is plain) [default: "plain"]. -|==== - -This example lists groups containing the string "finance". - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:list finance - - All-Finance-Staff - - Finance - - Finance-Managers ----- - -This example lists groups containing the string "finance" formatted with `json_pretty`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:list --output=json_pretty finance - [ - "All-Finance-Staff", - "Finance", - "Finance-Managers" - ] ----- - -== Listing Group Members - -You can list the user IDs of group members with the `group:list-members` command. -The syntax is: - ----- -group:list-members [options] ----- - -=== Options - -[width="100%",cols="20%,50%",] -|==== -| `--output=[OUTPUT]` | Output format (plain, json or json_pretty, default is plain) [default: "plain"]. -|==== - -This example lists members of the "Finance" group. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:list-members Finance - - aaron: Aaron Smith - - julie: Julie Jones ----- - -This example lists members of the Finance group formatted with `json_pretty`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:list-members --output=json_pretty Finance - { - "aaron": "Aaron Smith", - "julie": "Julie Jones" - } ----- - -== Adding Members to Groups - -You can add members to an existing group with the `group:add-member` command. -Members must be existing users. -The syntax is: - ----- -group:add-member [-m|--member [MEMBER]] ----- - -This example adds members "aaron" and "julie" to group "Finance": - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:add-member --member aaron --member julie Finance - User "aaron" added to group "Finance" - User "julie" added to group "Finance" ----- - -You may attempt to add members that are already in the group, without error. -This allows you to add members in a scripted way without needing to know if the user is already a member of the group. -For example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:add-member --member aaron --member julie --member fred Finance - User "aaron" is already a member of group "Finance" - User "julie" is already a member of group "Finance" - User fred" added to group "Finance" ----- - -== Removing Members from Groups - -You can remove members from a group with the `group:remove-member` command. -The syntax is: - ----- -group:remove-member [-m|--member [MEMBER]] ----- - -This example removes members "aaron" and "julie" from group "Finance". - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:remove-member --member aaron --member julie Finance - Member "aaron" removed from group "Finance" - Member "julie" removed from group "Finance" ----- - -You may attempt to remove members that have already been removed from the group, without error. -This allows you to remove members in a scripted way without needing to know if the user is still a member of the group. -For example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:remove-member --member aaron --member fred Finance - Member "aaron" could not be found in group "Finance" - Member "fred" removed from group "Finance" ----- - -== Deleting a Group - -To delete a group, you use the `group:delete` command, as in the example below: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} group:delete Finance ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_incoming_shares_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_incoming_shares_commands.adoc deleted file mode 100644 index 0e9f6a2..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_incoming_shares_commands.adoc +++ /dev/null @@ -1,26 +0,0 @@ -= Poll Incoming Federated Shares For Updates - -This command must be used if received federated shares are being referenced by desktop clients but not regularly accessed via the webUI. -This is because, for performance reasons, federated shares do not update automatically. -Instead, federated share directories are only updated when users browse them using the xref:classic_ui:files/webgui/overview.adoc[webUI]. - -ownCloud and system administrators can use the `incoming-shares:poll` command to poll federated shares for updates. - -NOTE: The command polls all received federated shares, so does not require a path. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} incoming-shares:poll ----- - -[IMPORTANT] -==== -When using federation, it is recommended to execute `occ incoming-shares:poll` regularly xref:configuration/server/background_jobs_configuration.adoc#cron-jobs[using Cron jobs]. -The time interval between executions is a trade-off between the availability of changes in federated shares and resource consumption; which naturally depends a lot on the number of federated shares and the frequency of changes within those shares. - -Executing the command once every 12 hours _should_ be safe enough for most instances. -However, the interval can be reduced to once every 2 hours, for instances with a small number of federated shares. - -Depending on the desired resource consumption, this value should be lowered or increased based on individual expectations. -To find a value that fits a specific setup, it is recommended to execute the command once, measure the execution time and set the interval, so that the background job can finish before the next execution is triggered. -==== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_integrity_check_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_integrity_check_commands.adoc deleted file mode 100644 index fd07535..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_integrity_check_commands.adoc +++ /dev/null @@ -1,39 +0,0 @@ -= Integrity Check - -Apps which have an official tag *must* be code signed. -Unsigned official apps won't be installable anymore. -Code signing is optional for all third-party applications. - -[source,plaintext] ----- -integrity - integrity:check-app Check app integrity using a signature. - integrity:check-core Check core integrity using a signature. - integrity:sign-app Signs an app using a private key. - integrity:sign-core Sign core using a private key ----- - -After creating your signing key, sign your app like this example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} integrity:sign-app \ - --privateKey=/Users/karlmay/contacts.key \ - --certificate=/Users/karlmay/CA/contacts.crt \ - --path=/Users/karlmay/Programming/contacts ----- - -Verify your app: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} integrity:check-app --path=/pathto/app appname ----- - -When it returns nothing, your app is signed correctly. -When it returns a message then there is an error. - -`integrity:sign-core` is for ownCloud core developers only. - -TIP: See xref:configuration/general_topics/code_signing.adoc[code signing] to learn more. - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_localisation_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_localisation_commands.adoc deleted file mode 100644 index 4444e67..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_localisation_commands.adoc +++ /dev/null @@ -1,57 +0,0 @@ -= l10n, Create Javascript Translation Files for Apps - -This command creates JavaScript and JSON translation files for ownCloud applications. - -NOTE: The command does not update existing translations if the source translation file has been updated. -It only creates translation files when none are present for a given language. - -[source,plaintext] ----- -l10n - l10n:createjs Create Javascript translation files for a given app ----- - -The command takes two parameters; these are: - -* `app`: the name of the application. -* `lang`: the output language of the translation files; more than one can be supplied. - -To create the two translation files, the command reads translation data from a source PHP translation file. - -== A Working Example - -In this example, we'll create Austrian German translations for the Comments app. - -NOTE: This example assumes that the ownCloud directory is `/var/www/owncloud` and that it uses ownCloud's standard apps directory, `app`. - -First, create a source translation file in `/var/www/owncloud/apps/comments/l10n`, called `de_AT.php`. -In it, add the required translation strings, as in the following example. -Refer to the developer documentation on xref:developer_manual:app/advanced/l10n.adoc#creating-your-own-translatable-files[creating translation files], if you're not familiar with creating them. - -[source,php] ----- - "Freigeben" -]; -$PLURAL_FORMS = "nplurals=2; plural=(n != 1);"; ----- - -After that, run the following command to create the translation. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} l10n:createjs comments de_AT ----- - -This will generate two translation files, `de_AT.js` and `de_AT.json`, in `/var/www/owncloud/apps/comments/l10n`. - -=== Create Translations in Multiple Languages - -To create translations in multiple languages simultaneously, supply multiple languages to the command, as in the following example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} l10n:createjs comments de_AT de_DE hu_HU es fr ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_logging_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_logging_commands.adoc deleted file mode 100644 index fc5786e..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_logging_commands.adoc +++ /dev/null @@ -1,55 +0,0 @@ -= Logging Commands - -These commands view and configure your ownCloud logging preferences. - -[source,plaintext] ----- -log - log:manage Manage logging configuration - log:owncloud Manipulate ownCloud logging backend ----- - -== Command Description - -Run `log:owncloud` to see your current logging status: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} log:owncloud -Log backend ownCloud: enabled -Log file: /opt/owncloud/data/owncloud.log -Rotate at: disabled ----- - -=== Options - -[width="100%",cols="20%,50%",] -|==== -| `--enable` | Enable this logging backend. -| `--file=[FILE]` | Set the log file path. -| `--rotate-size=[ROTATE-SIZE]` | Set the file size for log rotation, 0 = disabled. -|==== - -Use the `--enable` option to turn on logging. Use `--file` to set a different log file path. -Set your rotation by log file size in bytes with `--rotate-size`; 0 disables rotation. -Run `log:manage` to set your logging backend, log level, and timezone: -The defaults are `owncloud`, `Warning`, and `UTC`. - -Options for `log:manage`: - -[width="100%",cols="20%,50%",] -|==== -| `--backend=[BACKEND]` | Set the logging backend [owncloud, syslog, errorlog]. -| `--level=[LEVEL]` | Set the log level [debug, info, warning, error, fatal]. -|==== - -Log level can be adjusted by entering the number or the name: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} log:manage --level 4 -{occ-command-example-prefix} log:manage --level error ----- - -TIP: Setting the log level to debug ( 0 ) can be used for finding the cause of an error, but should not be the standard as it increases the log file size. - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_maintenance_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_maintenance_commands.adoc deleted file mode 100644 index e699214..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_maintenance_commands.adoc +++ /dev/null @@ -1,262 +0,0 @@ -= Maintenance Commands - -Use these commands when you upgrade ownCloud, manage encryption, perform backups and other tasks that require locking users out until you are finished. - -[source,plaintext] ----- -maintenance - maintenance:data-fingerprint Update the systems data-fingerprint after a backup is restored - maintenance:install Install ownCloud - maintenance:mimetype:update-db Update database mimetypes and update filecache - maintenance:mimetype:update-js Update mimetypelist.js - maintenance:mode Set maintenance mode - maintenance:repair Repair this installation - maintenance:singleuser Set single user mode - maintenance:update:htaccess Updates the .htaccess file ----- - -== Update the Systems Data-Fingerprint - -When a backup has been restored, the ETag information, which is necessary when accessing ownCloud with clients, has been changed. Run the following command to tell desktop and mobile clients that a server backup has been restored. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:data-fingerprint ----- - -This command changes the ETag for all files in the communication with sync clients, informing them that one or more files were modified. After the command completes, users will be prompted to resolve any conflicts between newer and older file versions. - -== Install ownCloud - -NOTE: This command is only available if the following key in your `config.php` is not present or set to `false`. This is the case when the installation has not been made or not finalized. This key automatically turns to `true` after a successful installation. This results in the command no longer being available. - -[source,php] ----- -'installed' => false, ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:install [options] ----- - -The `maintenance:install` command supports the following options: - -[cols="30%,75%",options="header"] -|=== -| Option -| Description - -| `--database`=DATABASE -| Supported database type. [default: `sqlite`] + -Possible values: `sqlite` ,`mysql`, `pgsql`, `oci` + -Note that `oci` (Oracle) is only available with the Enterprise license. - -| `--database-connection-string`=DATABASE-CONNECTION-STRING -| Oracle specific connection string. As soon as this parameter is provided, other parameters like database-host and database-name are not used and do not need to be provided. - -| `--database-name`=DATABASE-NAME -| Name of the database. - -| `--database-host`=DATABASE-HOST -| Hostname of the database. [default: "localhost"] - -| `--database-user`=DATABASE-USER -| User name to connect to the database. - -| `--database-pass`=DATABASE-PASS -| Password of the database user. - -| `--database-table-prefix`=DATABASE-TABLE-PREFIX -| Prefix for all tables (default: oc_). - -| `--admin-user`=ADMIN-USER -| User name of the admin account. [default: "admin"] - -| `--admin-pass`=ADMIN-PASS -| Password of the admin account. - -| `--data-dir`=DATA-DIR -| Path to the data directory. [default: "/var/www/owncloud/data"] -|=== - -== Update Database Mimetypes - -Update database mimetypes and file cache. - -Usage: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mimetype:update-db [options] ----- - -The `maintenance:mimetype:update-db` command supports the following options: - -[cols="25%,75%",options="header"] -|=== -| Option -| Description - -| `--repair-filecache` -| Repair the file cache for all mimetypes, not just the new ones. -|=== - -== Update the mimetypelist.js File - -This command updates the `mimetypelist.js` file. - -Usage: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:update-js ----- - -== Enable or Disable Maintenance Mode - -`maintenance:mode` command locks the sessions of all logged-in users, including administrators, and displays a status screen warning that the server is in maintenance mode. Users who are not already logged in cannot log in until maintenance mode is turned off. Once you take the server out of maintenance mode, logged-in users must refresh their Web browsers to continue working. - -Usage: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode [options] ----- - -The `maintenance:mode` command supports the following options: - -[cols="25%,75%",options="header"] -|=== -| Option -| Description - -| `--on` -| Enable maintenance mode. - -| `--off` -| Disable maintenance mode. -|=== - -Turn on maintenance mode: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --on ----- - -Turn it off when you’re finished with the maintenance tasks: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -== Installation Repair Commands - -The `maintenance:repair` command helps administrators repair an installation. The command runs automatically during upgrades to clean up the database. So, while you can run it manually, there usually isn't a need to. - -NOTE: Your ownCloud installation needs to be in maintenance mode to use the `maintenance:repair` command. - -Usage: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:repair [options] ----- - -=== Repair Command Options - -The `maintenance:repair` command supports the following options: - -[cols="25%,75%",options="header"] -|=== -| Option -| Description - -| `--list` -| Lists all possible repair steps. - -| `-s` `--single=SINGLE` -| Run just one repair step given its class name. - -| `--include-expensive` -| Use this option when you want to include resource and load expensive tasks. -|=== - -=== Running All Repair Steps - -Here is an example of running the command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:repair ----- - -To list all off the possible repair steps, use the `--list` option. It should output the following list to the console: - -[source,plaintext] ----- -Found 16 repair steps - -OC\Repair\RepairMimeTypes -> Repair mime types -OC\Repair\RepairMismatchFileCachePath -> Detect file cache entries with path that does not match parent-child relationships -OC\Repair\FillETags -> Generate ETags for file where no ETag is present. -OC\Repair\CleanTags -> Clean tags and favorites -OC\Repair\DropOldTables -> Drop old database tables -OC\Repair\DropOldJobs -> Drop old background jobs -OC\Repair\RemoveGetETagEntries -> Remove getetag entries in properties table -OC\Repair\RepairInvalidShares -> Repair invalid shares -OC\Repair\RepairSubShares -> Repair sub shares -OC\Repair\SharePropagation -> Remove old share propagation app entries -OC\Repair\MoveAvatarOutsideHome -> Move user avatars outside the homes to the new location -OC\Repair\RemoveRootShares -> Remove shares of a users root folder -OC\Repair\RepairUnmergedShares -> Repair unmerged shares -OC\Repair\DisableExtraThemes -> Disable extra themes -OC\Repair\OldGroupMembershipShares -> Remove shares of old group memberships -OCA\DAV\Repair\RemoveInvalidShares -> Remove invalid calendar and addressbook shares ----- - -=== Running a Single Repair Step - -To run a single repair step, use either the `-s` or `--single` options, as in the following example. - -Usage: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:repair \ - --single="OCA\DAV\Repair\RemoveInvalidShares" ----- - -TIP: The step's name must be quoted, otherwise you will see the following warning message appear, and the command will fail: -"_Repair step not found. Use --list to show available steps._" - -== Single User Mode - -Putting your ownCloud server into single-user mode allows admins to log in and work, but not ordinary users. -This is useful for performing maintenance and troubleshooting on a running server. - -Usage: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --on ----- - -Turn it off when you're finished: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --off ----- - -== Update the .htaccess File - -This command updates the `.htaccess` file. - -Usage: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:update:htaccess ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_managing_background_jobs.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_managing_background_jobs.adoc deleted file mode 100644 index 2ab9645..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_managing_background_jobs.adoc +++ /dev/null @@ -1,155 +0,0 @@ -= Managing Background Jobs - -Use the `background:queue` command to manage background jobs. - -[source,plaintext] ----- -background:queue - background:queue:delete Delete a job from the queue - background:queue:execute Run a single background job from the queue - background:queue:status List queue status ----- - -== Deleting a Background Job - -The command `background:queue:delete` deletes a queued background job. -It requires the job id of the job to be deleted. - -[source,plaintext] ----- -background:queue:delete ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `Job ID` | ID of the job to be deleted -|=== - -WARNING: Deleting a job cannot be undone. Be sure that you want to delete the job before doing so. - -This example deletes queued background job #12. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:queue:delete 12 - -Job has been deleted. ----- - -== Executing a Background Job - -The command `background:queue:execute` executes a queued background job. -It requires the job id of the job to be executed. - -[source,plaintext] ----- -background:queue:execute [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `Job ID` | ID of the job to be deleted -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-f` + -`--force` | Force run the job even if within timing interval -| `--accept-warning` | No warning about the usage of this command will be displayed -|=== - -This example executes queued background job #12. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:queue:execute 12 - -This command is for maintenance and support purposes. -This will run the specified background job now. Regular scheduled runs of the job will -continue to happen at their scheduled times. -If you still want to use this command please confirm the usage by entering: yes -yes -Found job: OCA\UpdateNotification\Notification\BackgroundJob with ID 12 -Running job... -Finished in 0 seconds ----- - -== List Queued Backgroundjobs - -The command `background:queue:status` will list queued background jobs, including details when it last ran. - -[source,plaintext] ----- -background:queue:status ----- - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--display-invalid-jobs` | Also display jobs that are no longer valid -|=== - -This example lists the queue status: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:queue:status - -+--------+----------------------------------------------------+---------------+----------+---------------------------+-------------+------------------------+ -| Job ID | Job | Job Arguments | Last Run | Last Checked | Reserved At | Execution Duration (s) | -+--------+----------------------------------------------------+---------------+----------+---------------------------+-------------+------------------------+ -| 1 | OCA\Files\BackgroundJob\ScanFiles | | N/A | 2022-09-08T16:42:47+00:00 | N/A | N/A | -| 2 | OCA\Files\BackgroundJob\DeleteOrphanedItems | | N/A | 2022-09-08T16:42:47+00:00 | N/A | N/A | -| 3 | OCA\Files\BackgroundJob\CleanupFileLocks | | N/A | 2022-09-08T16:42:47+00:00 | N/A | N/A | -| 4 | OCA\Files\BackgroundJob\CleanupPersistentFileLocks | | N/A | 2022-09-08T16:42:47+00:00 | N/A | N/A | -| 5 | OCA\Files\BackgroundJob\PreviewCleanupJob | | N/A | 2022-09-08T16:42:47+00:00 | N/A | N/A | -| 6 | OCA\DAV\CardDAV\SyncJob | | N/A | 2022-09-08T16:42:49+00:00 | N/A | N/A | -| 7 | OCA\DAV\BackgroundJob\CleanProperties | | N/A | 2022-09-08T16:42:49+00:00 | N/A | N/A | -| 8 | OCA\Activity\BackgroundJob\EmailNotification | | N/A | 2022-09-08T16:42:49+00:00 | N/A | N/A | -| 9 | OCA\Activity\BackgroundJob\ExpireActivities | | N/A | 2022-09-08T16:42:49+00:00 | N/A | N/A | -| 10 | OCA\Federation\SyncJob | | N/A | 2022-09-08T16:42:50+00:00 | N/A | N/A | -| 11 | OCA\Files_Sharing\DeleteOrphanedSharesJob | | N/A | 2022-09-08T16:42:51+00:00 | N/A | N/A | -| 12 | OCA\Files_Sharing\ExpireSharesJob | | N/A | 2022-09-08T16:42:51+00:00 | N/A | N/A | -| 13 | OCA\Files_Sharing\External\ScanExternalSharesJob | | N/A | 2022-09-08T16:42:51+00:00 | N/A | N/A | -| 14 | OCA\Files_Trashbin\BackgroundJob\ExpireTrash | | N/A | 2022-09-08T16:42:51+00:00 | N/A | N/A | -| 15 | OCA\Files_Versions\BackgroundJob\ExpireVersions | | N/A | 2022-09-08T16:42:51+00:00 | N/A | N/A | -| 16 | OCA\Market\CheckUpdateBackgroundJob | | N/A | 2022-09-08T16:42:51+00:00 | N/A | N/A | -| 17 | OCA\UpdateNotification\Notification\BackgroundJob | | N/A | 2022-09-08T16:42:52+00:00 | N/A | N/A | -| 18 | OC\Authentication\Token\DefaultTokenCleanupJob | | N/A | 2022-09-08T16:42:52+00:00 | N/A | N/A | -+--------+----------------------------------------------------+---------------+----------+---------------------------+-------------+------------------------+ ----- - -There may be background jobs that are no longer valid. This can be because they are for an app that is now disabled or deleted, or jobs from an older version of an app that are no longer relevant. These jobs can be displayed with the `--display-invalid-jobs` option. Invalid jobs are listed with status "invalid". You can then delete invalid jobs with the `background:queue:delete` command using the job id. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:queue:status --display-invalid-jobs - -+--------+----------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------+---------------------------+-------------+------------------------+---------+ -| Job ID | Job | Job Arguments | Last Run | Last Checked | Reserved At | Execution Duration (s) | Status | -+--------+----------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------+---------------------------+-------------+------------------------+---------+ -| 1 | OCA\Files\BackgroundJob\ScanFiles | | 2023-07-21T08:25:49+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 2 | OCA\Files\BackgroundJob\DeleteOrphanedItems | | 2023-07-21T08:25:48+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 3 | OCA\Files\BackgroundJob\CleanupFileLocks | | 2023-07-21T08:25:48+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 4 | OCA\Files\BackgroundJob\CleanupPersistentFileLocks | | 2023-07-21T08:25:48+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 5 | OCA\DAV\CardDAV\SyncJob | | 2023-07-21T07:10:30+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 6 | OCA\DAV\BackgroundJob\CleanProperties | | 2023-07-21T07:10:30+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 7 | OCA\Federation\SyncJob | | 2023-07-21T07:10:31+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 8 | OCA\Files_Sharing\DeleteOrphanedSharesJob | | 2023-07-21T08:25:49+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 9 | OCA\Files_Sharing\ExpireSharesJob | | 2023-07-21T07:10:31+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 10 | OCA\Files_Trashbin\BackgroundJob\ExpireTrash | | 2023-07-21T08:25:49+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 11 | OCA\Files_Versions\BackgroundJob\ExpireVersions | | 2023-07-21T08:25:49+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 12 | OCA\UpdateNotification\Notification\BackgroundJob | | 2023-07-21T07:10:31+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 23 | OCA\Files_Antivirus\Cron\Task | null | 1687247852 | 1689923430 | 1689923430 | 0 | invalid | -| 66 | OCA\Files_Sharing\External\ScanExternalSharesJob | | 2023-07-21T08:25:49+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -| 227 | OCA\Search_Elastic\Jobs\DeleteJob | null | 0 | 1689923433 | 1689923433 | -1 | invalid | -| 228 | OCA\Files\BackgroundJob\PreviewCleanupJob | | 2023-07-21T08:25:49+00:00 | 2023-07-21T08:26:28+00:00 | N/A | 0 | | -+--------+----------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------+---------------------------+-------------+------------------------+---------+ ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_migration_steps_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_migration_steps_commands.adoc deleted file mode 100644 index 2598f26..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_migration_steps_commands.adoc +++ /dev/null @@ -1,26 +0,0 @@ -= Migration Steps Command - -You can run migration steps with the `migrations` command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrations:execute ----- - -== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `app` | Name of the app this migration command shall work on. -| `version` | The version to execute. -|=== - -== Example - -This example executes the migration step for the core app: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrations:execute core 20181220085457 ----- - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_mimetype_update_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_mimetype_update_commands.adoc deleted file mode 100644 index 36adc0d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_mimetype_update_commands.adoc +++ /dev/null @@ -1,5 +0,0 @@ -= Mimetype Update Commands - -`maintenance:mimetype:update-db` updates the ownCloud database and file cache with changed mimetypes found in `config/mimetypemapping.json`. -Run this command after modifying `config/mimetypemapping.json`. -If you change a mimetype, run `maintenance:mimetype:update-db --repair-filecache` to apply the change to existing files. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_notifications_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_notifications_commands.adoc deleted file mode 100644 index d4b1a2b..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_notifications_commands.adoc +++ /dev/null @@ -1,47 +0,0 @@ -= Notifications - -If you want to send notifications to users or groups use the following command. - -[source,sourceCode,console] ----- -notifications - notifications:generate Generates a notification. ----- - -== Command Description - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} notifications:generate [-u|--user USER] [-g|--group GROUP] [-l|--link ] [--] [] ----- - -=== Arguments: - -[width="100%",cols="20%,70%",] -|=== -| `subject` | The notification subject - maximum 255 characters. -| `message` | A more extended message - maximum 4000 characters. -| `linktext` | A link to an HTML page. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-u [USER]` + -`--user=[USER]` | User id to whom the notification shall be sent. -| `-g [GROUP]` + -`--group=[GROUP]` | Group id to whom the notification shall be sent. -| `-l [LINK]` + -`--link=[LINK]` | A link associated with the notification. -|=== - -At least one user or group must be set. -A link can be useful for notifications shown in client apps. -Example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} notifications:generate -g Office "Emergency Alert" "Rebooting in 5min" ----- - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_previews_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_previews_commands.adoc deleted file mode 100644 index 4507627..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_previews_commands.adoc +++ /dev/null @@ -1,66 +0,0 @@ -= Previews Commands - -A set of commands to remove unreferenced preview images: - -[source,plaintext] ----- -previews - previews:cleanup Remove unreferenced previews ----- - -== Cleanup - -Removing not referenced previews can be necessary, e.g., when the image has been deleted or the ID of the mountpoint changes which happens when renaming it. Previews will be generated anew when accessing the image again, but not referenced previews are orphans. To avoid orphans, an occ command has been added to manually remove those not referenced previews as they are eating up storage space unnecessarily. In addition, a background job has been created which automatically removes them on a regular basis. For more info see the xref:background-job[Background Job] section and the example listing xref:configuration/server/occ_command.adoc#list-queued-backgroundjobs[OCA\Files\BackgroundJob\PreviewCleanupJob]. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} previews:cleanup [options] [--] [] ----- - -=== Arguments - -[width="100%",cols="25%,70%",] -|==== -| `chunk_size` -| Define the number of files being processed in one loop [default: 1000] -|==== - -=== Options - -[width="100%",cols="25%,70%",] -|==== -| `--all` -| Run as many loops until no chunks remain -|==== - -Description: - -* The value of `chunk size` defines the number of files being processed in one loop and also how often a database commit will be made. The lower the number, the more commits are generated. -* if `--all` is set, the loop will loop until all are processed -* if `--all` is not set, the loop will run once - -[NOTE] -==== -* Cleaning up previews is a database-intense operation. The command can take a considerable amount of time when the database and filesystem are on NFS. Note that the command execution time depends on the total quantity of items in the database and not on the number of items likely to be cleaned up. -* Once started, the command cannot be stopped, e.g. with kbd:[CTRL+C], you need to end the process manually. -* If you have upgraded your system but the backgroundjob does not appear in the job list, you can manually add it. -==== - -=== Example - -In the example below, you run one loop with max (default) 1000 files processed. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} previews:cleanup ----- - -Other combinations could be: - -* `previews:cleanup -- 50`: run once and process 50 files -* `previews:cleanup --all 50`: process all files in blocks of 50 files - -=== Background Job - -The background job to cleanup previews is added by default and suits smaller installations of the community edition. The occ command should be used in regular system cron jobs on bigger installations using the enterprise edition. In this case, the background job can stay enabled, but in combination with a cron job admins have better control. Note that you also can remove a background job if it does not fit your environment. - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_security_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_security_commands.adoc deleted file mode 100644 index 7acf433..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_security_commands.adoc +++ /dev/null @@ -1,107 +0,0 @@ -= Security - -Use these commands when you manage security related tasks. -Routes displays all routes of ownCloud. -You can use this information to grant strict access via firewalls, proxies or load balancers etc. - -== Command Description - -[source,plaintext] ----- -security:routes [options] ----- - -=== Options - -[width="100%",cols="20%,70%",] -|==== -| `--output=[OUTPUT]` | Output format (plain, json or json-pretty, default is plain). -| `--with-details` | Adds more details to the output. -|==== - -Example 1: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} security:routes ----- - -[source,plaintext] ----- -+-----------------------------------------------------------+-----------------+ -| Path | Methods | -+-----------------------------------------------------------+-----------------+ -| /apps/federation/auto-add-servers | POST | -| /apps/federation/trusted-servers | POST | -| /apps/federation/trusted-servers/ | DELETE | -| /apps/files/ | GET | -| /apps/files/ajax/download.php | | -... ----- - -Example 2: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} security:routes --output=json-pretty ----- - -[source,plaintext] ----- -[ - { - "path": "\/apps\/federation\/auto-add-servers", - "methods": [ - "POST" - ] - }, ----- - -Example 3: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} security:routes --with-details ----- - -[source,plaintext] ----- -+---------------------------------------------+---------+-------------------------------------------------------+--------------------------------+ -| Path | Methods | Controller | Annotations | -+---------------------------------------------+---------+-------------------------------------------------------+--------------------------------+ -| /apps/files/api/v1/sorting | POST | OCA\Files\Controller\ApiController::updateFileSorting | NoAdminRequired | -| /apps/files/api/v1/thumbnail/{x}/{y}/{file} | GET | OCA\Files\Controller\ApiController::getThumbnail | NoAdminRequired,NoCSRFRequired | -... ----- - - -The following commands manage server-wide SSL certificates. -These are useful when you create federation shares with other ownCloud servers that use self-signed certificates. - -[source,plaintext] ----- -security:certificates List trusted certificates -security:certificates:import Import trusted certificate -security:certificates:remove Remove trusted certificate ----- - -This example lists your installed certificates: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} security:certificates ----- - -Import a new certificate: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} security:certificates:import /path/to/certificate ----- - -Remove a certificate: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} security:certificates:remove [certificate name] ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_sharing_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_sharing_commands.adoc deleted file mode 100644 index f41027e..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_sharing_commands.adoc +++ /dev/null @@ -1,41 +0,0 @@ -= Sharing - -== Cleanup Remote Storages - -This is an occ command to clean up orphaned remote storages. -To explain why this is necessary, a little background is required. -While shares are able to be deleted as a normal matter of course, remote storages with `shared::` are not included in this process. - -This might not, normally, be a problem. -However, if a user has re-shared a remote share which has been deleted it will. -This is because when the original share is deleted, the remote re-share reference is not. -Internally, the `fileid` will remain in the file cache and storage for that file will not be deleted. - -As a result, any user(s) who the share was re-shared with will now get an error when trying to access that file or folder. -That's why the command is available. -So, to cleanup all orphaned remote storages, run it as follows: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} sharing:cleanup-remote-storages ----- - -You can also set it up to run as xref:background-jobs-selector[a background job]. - -NOTE: These commands are not available in xref:maintenance-commands[single-user (maintenance) mode]. - -== Allow to Temporarily Ignore Invalid Federated Shares - -Currently, if a federated share is invalid or the API endpoint returns a "not found", the availability check tests whether this is a problem with a server. If checks complete, that given share is removed. However, in some cases these checks might not be enough like in complex migrations of tightly federated setups. In that case, invalidation behavior can be disabled using the below app setting. When set, instead of removing the share, a warning is displayed in the browser. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_sharing enable_cleanup_invalid_external_shares --value no ----- - -To revert that setting to its default behavior, run: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete files_sharing enable_cleanup_invalid_external_shares ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_system_command.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_system_command.adoc deleted file mode 100644 index 3e5a5a7..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_system_command.adoc +++ /dev/null @@ -1,71 +0,0 @@ -= System Commands - -[source,console] ----- - system - system:cron Execute background jobs as cron ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} -h system:cron --Usage: - system:cron [options] ----- - -== Options - -[width="100%",cols="20%,70%",] -|=== -| -p, --progress -| Shows a progress bar - for use in manual execution. -Do not use when executing from crontab -|=== - -To execute xref:configuration/server/background_jobs_configuration.adoc[background jobs] using xref:configuration/server/background_jobs_configuration.adoc#cron[cron], you can use the `system:cron` command, as in the following example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} system:cron ----- - -If the `--progress` or `-p` argument is specified, then progress output will be displayed in the console, as in the example below. - -[source,console] ----- -Executing: 12 - OCA\UpdateNotification\Notification\BackgroundJob - 13 [------------->--------------] ----- - -If neither of these arguments is provided, no output will be displayed by the command. - -NOTE: Displaying progress information is useful when you want visual confirmation that background jobs have been executed. -However, in a non-interactive environment, such as crontab, it should not be used. - -== Updating an Existing System Cron Configuration - -[NOTE] -==== -If you have already automated background jobs via Cron, you must update the relevant `crontab` entry -using the example below as a guide. - -Instead of the following configuration -[source,console,subs="attributes+"] ----- -/usr/bin/php -f /path/to/your/owncloud/cron.php ----- - -Use the following one instead -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} system:cron ----- -==== - -[NOTE] -==== -This command does not work if: - -* xref:maintenance-commands[Maintenance or Admin-only (single user) modes] are enabled -* Background jobs are disabled -==== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_trashbin_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_trashbin_commands.adoc deleted file mode 100644 index 12cc425..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_trashbin_commands.adoc +++ /dev/null @@ -1,38 +0,0 @@ -= Trashbin - -NOTE: These commands are only available when the 'Deleted files' app (`files_trashbin`) is enabled. -These commands are not available in xref:maintenance-commands[single-user (maintenance) mode]. - -[source,plaintext] ----- -trashbin - trashbin:cleanup Remove deleted files - trashbin:expire Expires the users trash bin ----- - -The `trashbin:cleanup` command removes the deleted files of the specified users in a space-delimited list, or all users if none are specified. -This example removes all the deleted files of all users: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} trashbin:cleanup -Remove all deleted files -Remove deleted files for users on backend Database - freda - molly - stash - rosa - edward ----- - -This example removes the deleted files of users `molly` and `freda`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} trashbin:cleanup molly freda -Remove deleted files of molly -Remove deleted files of freda ----- - -`trashbin:expire` deletes only expired files according to the `trashbin_retention_obligation` setting in `config.php` (see xref:configuration/server/config_sample_php_parameters.adoc[the "Deleted Files" section documentation]). -The default is to delete expired files for all users, or you may list users in a space-delimited list. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_user_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_user_commands.adoc deleted file mode 100644 index cbe274e..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_user_commands.adoc +++ /dev/null @@ -1,1007 +0,0 @@ -= User Commands - -:temp-dir-url: https://systemd.io/TEMPORARY_DIRECTORIES/ - -The `user` commands provide a range of functionality for managing ownCloud users. -This includes: creating and removing users, resetting user passwords, displaying a report which shows how many users you have, and when a user was last logged in. -The full list, of commands is: - -[source,plaintext] ----- -user - user:add Adds a user - user:delete Deletes the specified user - user:disable Disables the specified user - user:enable Enables the specified user - user:home List home directories and users in a particular home - user:inactive Reports users who are known to owncloud, - but have not logged in for a certain number of days - user:lastseen Shows when the user was logged in last time - user:list List users - user:list-groups List groups for a user - user:modify Modify user details - user:move-home Move a user's home folder to a new location - user:report Shows how many users have access - user:resetpassword Resets the password of the named user - user:setting Read and modify user application settings - user:sync Sync local users with an external backend service ----- - -== Creating Users - -You can create a new user with the `user:add` command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:add \ - [--password-from-env] \ - [--display-name [DISPLAY-NAME]] \ - [--email [EMAIL]] \ - [-g|--group [GROUP]] \ - [--] \ - ----- - -=== Arguments - -[width="100%",cols="30%,70%",] -|==== -| `uid` -| User ID used to login (must only contain a-z, A-Z, 0-9, -, _ and @). - -| `--password-from-env` -| Read the password from the `OC_PASS` environment variable. -A password is *not required*, _if_ an email address is provided. -If a password is not provided, a temporary one will be generated. -It cannot be set to `0`. - -| `--display-name=[DISPLAY-NAME]` -| This corresponds to the *Full Name* on the Users page in your ownCloud Web UI. - -| `--email=[EMAIL]` -| Email address for the user (optional). -The user will be emailed a link to set their password, _if_ email is configured correctly. - -| `-g [GROUP]` + -`--group=[GROUP]` -| The groups the user should be added to. -The group will be created if it does not exist. -Multiple values are allowed. -|==== - -=== Command Examples - -This example adds new user, Layla Smith, and adds her to the `users` and `db-admins` groups. -If either group does not exist, it is created. - -.Create a user with a password, email address, and display name, and add them to two groups -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:add \ - --display-name="Layla Smith" \ - --group="users" \ - --group="db-admins" \ - --email=layla.smith@example.com layla - Enter password: - Confirm password: - The user "layla" was created successfully - Display name set to "Layla Smith" - Email address set to "layla.smith@example.com" - User "layla" added to group "users" - User "layla" added to group "db-admins" ----- - -.Create a user with a temporary password (the user will receive a link to set their password). -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:add \ - --display-name "Layla Smith" \ - --email "***********" \ - --group "users" \ - --group "db-admins" layla - -The user "layla" was created successfully -Display name set to "Layla Smith" -Email address set to "************" -User layla added to group users -User layla added to group db-admins ----- - -== Deleting A User - -To delete a user, you use the `user:delete` command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:delete [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|==== -| `uid` -| The username. -|==== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `-f` + -`--force` -| Try to force the deletion of the user data even if the user is missing. -|=== - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:delete fred ----- - -== Disable Users - -Admins can disable users via the occ command too: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:disable ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|==== -| `uid` -| The user name. -|==== - -NOTE: Once users are disabled, their connected browsers will be disconnected. Use the following command to enable the user again: - -== Enable Users - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:enable ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|==== -| `uid` -| The user name. -|==== - -== List User Home Directories - -List all available root directories for user homes that are currently in use. For details see xref:configuration/user/user_management.adoc#moving-the-user-home[Moving the User Home] documentation. - -This command is complementary when using `user:move-home`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:home:list-dirs [options] ----- - -=== Options - -[width="100%",cols="20%,70%"] -|=== -| `--output=[OUTPUT]` -| Output format (plain, json or json_pretty, default is plain) [default: "plain"]. -|=== - -=== Examples - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:home:list-dirs - - /var/www/owncloud/data ----- - -== List all Users For a Given Home Directory - -List all users that have their home in a given path. For details see xref:configuration/user/user_management.adoc#moving-the-user-home[Moving the User Home] documentation. - -This command is complementary when using `user:move-home`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:home:list-users [options] [--] [] ----- - -=== Arguments - -[width="100%",cols="20%,70%"] -|=== -| `path` -| Path where the user home must be located -|=== - -=== Options - -[width="100%",cols="20%,70%"] -|=== -| `--all` -| List all users for every home path. - -| `--output=[OUTPUT]` -| Output format (plain, json or json_pretty, default is plain) [default: "plain"]. -|=== - -=== Examples - -Note for the example below, some user accounts originated from LDAP. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:home:list-users /var/www/owncloud/data - - admin - - aca4c3ec-691d-103b-8380-55a4da3d3a76 - - 9918b614-6a2e-103b-89a7-f5edf5d332f5 - - c298ae18-6a2e-103b-89a8-f5edf5d332f5 - - dbcca7b4-7306-103b-813a-19652cf0a9d2 ----- - -Run the following command to list all users from all available home directories. The example shows, that user `lisa` has been moved to a different home directory with `user:move-home`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:home:list-users --all - - /mnt/newhome_1 - - lisa - - /var/www/owncloud/data - - admin - - user01 ----- - -== Finding Inactive Users - -To view a list of users who've not logged in for a given number of days, use the `user:inactive` command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:inactive [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|=== -| `` -| The number of days (integer) that the user has not logged in since. -|=== - -=== Options - -[width="100%",cols="20%,70%",] -|=== -| `--output=[OUTPUT]` -| Output format (plain, json or json_pretty, default is plain) [default: "plain"]. -|=== - -The example below searches for users inactive for five days or more: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:inactive 5 ----- - -By default, this will generate output in the following format: - -[source,plaintext] ----- -- 0: - - uid: admin - - displayName: admin - - inactiveSinceDays: 5 ----- - -You can see a counting number starting with `0`, the user's user ID, display name and the number of days they've been inactive. If you're passing or piping this information to another application for further processing, you can also use the `--output` switch to change its format. Using the output option `json` will render the output formatted as follows. - -[source,json] ----- -[{"uid":"admin","displayName":"admin","inactiveSinceDays":5}] ----- - -Using the output option `json_pretty` will render the output formatted as follows. - -[source,json] ----- -[ - { - "uid": "admin", - "displayName": "admin", - "inactiveSinceDays": 5 - } -] ----- - -== Finding the User's Last Login - -To view a user's most recent login, use the `user:lastseen` command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:lastseen ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|==== -| `uid` -| The user name. -|==== - -Example - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:lastseen layla - layla's last login: 09.01.2015 18:46 ----- - -== Listing Users - -You can list existing users with the `user:list` command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list [options] [] ----- - -User IDs containing the `search-pattern` string are listed. -Matching is not case-sensitive. -If you do not provide a search-pattern then all users are listed. - -=== Options - -[width="90%",cols="40%,80%",] -|==== -| `--output=[OUTPUT]` -| Output format (plain, json or json-pretty, default is plain). - -| `-a [ATTRIBUTES]` + -`--attributes=[ATTRIBUTES]` -| Adds more details to the output. + -Allowed attributes, multiple values possible: + -`uid`, `displayName`, `email`, `quota`, `enabled`, `lastLogin`, `home`, + -`backend`, `cloudId`, `searchTerms` [default: [`displayName`]] - -| `-s` + -`--show-all-attributes` -| All attributes to include from `uid`, `displayName`, `email`, `quota`, + -`enabled`, `lastLogin`, `home`, `backend`, `cloudId`, `searchTerms` -|==== - -This example lists user IDs containing the string `ron` - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list ron - - aaron: Aaron Smith ----- - -The output can be formatted in JSON with the output option `json` or `json_pretty`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list --output=json_pretty - { - "aaron": "Aaron Smith", - "herbert": "Herbert Smith", - "julie": "Julie Jones" - } ----- - -This example lists all users including the attribute `enabled`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list -a enabled - - admin: true - - foo: true ----- - -== Listing Group Membership of a User - -You can list the group membership of a user with the `user:list-groups` command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list-groups [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|==== -| `uid` -| User ID. -|==== - -=== Options - -[width="100%",cols="20%,70%",] -|==== -| `--output=[OUTPUT]` -| Output format (plain, json or json-pretty, default is plain). -|==== - -=== Examples - -This example lists group membership of user `julie`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list-groups julie - - Executive - - Finance ----- - -The output can be formatted in JSON with the output option `json` or `json_pretty`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list-groups --output=json_pretty julie - [ - "Executive", - "Finance" - ] ----- - -== Modify User Details - -This command modifies either the users username or email address. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:modify [options] [--] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|==== -| `uid` -| User ID used to login. - -| `key` -| Key to be changed. Valid keys are: `displayname` and `email`. - -| `value` -| The new value of the key. -|==== - -All three arguments are mandatory and can not be empty. Example to set the email address: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:modify carla email foobar@foo.com ----- - -The email address of `carla` is updated to `foobar@foo.com`. - -== Move a Users Home Folder - -This command moves a user's home folder to a new location. For details see xref:configuration/user/user_management.adoc#moving-the-user-home[Moving the User Home] documentation. Note that moving a users home is only possible for POSIX file systems. Also see the `user:home` commands for additional support. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:move-home ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|==== -| `user_id` -| ID of the user whose home folder is to be moved. - -| `new_location` -| Absolute path to the parent folder of the new location of the home folder. -|==== - -[NOTE] -==== -You must not use temp directories like `/tmp` and `/var/tmp` as target directory. - -* Any data located in one of the two directories will not survive a reboot -* For systemd services, they are private sub-directories of the host’s real /tmp/ and /var/tmp/, and thus not system-wide locations anymore, but service-specific ones. For more details see {temp-dir-url}[Using /tmp/ and /var/tmp/ Safely] -==== - -Example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:move-home lisa /mnt/newhome_1 ----- - -This command moves the home directory of user `lisa` to the new location `/mnt/newhome_1` - -== Generating a User Count Report - -Generate a simple report that counts all users including users on external user authentication servers such as LDAP, -and guest users which are created by the guests app. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:report ----- - -There are no arguments and no options beside the default once to parametrize the output. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:report -+--------------------------+-----+ -| User Report | | -+--------------------------+-----+ -| OCA\User_LDAP\User_Proxy | 23 | -| OC\User\Database | 100 | -| | | -| guest users | 20 | -| | | -| total users | 143 | -| | | -| user directories | 4 | -+--------------------------+-----+ ----- - -NOTE: A user directory is created, when a local user has logged on the first time after creation. Therefore the difference between `OC\User\Database` and `user directories` equals all users which have been created locally, but have not logged on at least once. - -== Setting a User's Password - -Resets the password of the named user. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:resetpassword [options] [--] ----- - -include::partial$configuration/user/update-password-note.adoc[] - -=== Arguments - -[width="100%",cols="25%,70%",] -|==== -| `uid` -| The user's name. -|==== - -=== Options - -[width="100%",cols="25%,70%",] -|==== -| `--password-from-env` -| Read the password from the OC_PASS environment variable. - -| `--send-email` -| The email ID set while creating the user, will be used to send. -link for password reset. This option will also display the link sent to user. - -| `--output-link` -| The link to reset the password will be displayed. -|==== - -`password-from-env` allows you to set the user's password from an environment variable. This prevents the password from being exposed to all users via the process list and will only be visible in the history of the user (root) running the command. This also permits creating scripts for adding multiple new users. - -NOTE: To use `password-from-env` you must run as "real" root, rather than `sudo`, because `sudo` strips environment variables. - -NOTE: To use `send-email`, the ownCloud instance must have email access fully configured. - -=== Examples - -Add a new user, called Fred Jones: - -[source,plaintext] ----- -export OC_PASS=newpassword -su -s /bin/sh www-data -c 'occ user:add --password-from-env - --display-name="Fred Jones" --group="users" fred' -The user "fred" was created successfully -Display name set to "Fred Jones" -User "fred" added to group "users" ----- - -You can reset any user's password, including administrators (see xref:configuration/user/reset_admin_password.adoc[Reset Admin Password]): - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:resetpassword layla - Enter a new password: - Confirm the new password: -Successfully reset password for layla ----- - -You may also use `password-from-env` to reset passwords: - -[source,plaintext] ----- -export OC_PASS=newpassword -su -s /bin/sh www-data -c 'occ user:resetpassword \ - --password-from-env \ - layla' -Successfully reset password for layla ----- - -This example emails a password reset link to the user. -Additionally, when the command completes, it outputs the password reset link to the console: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:resetpassword \ - --send-email \ - --output-link \ - layla -The password reset link is: http://localhost:{std-port-http}/index.php/lostpassword/reset/form/rQAlCjNeQf3aphA6Hraq2/layla ----- - -If the specified user does not have a valid email address set, then the following error will be output to the console, and the email will not be sent: - -[source,plaintext] ----- -Email address is not set for the user layla ----- - -== User Application Settings - -To manage application settings for a user, use the `user:setting` command. This command provides the ability to: - -* Retrieve all settings for an application -* Retrieve a single setting -* Set a setting value -* Delete a setting - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:setting [options] [--] [[ []] ----- - -=== Arguments - -[width="100%",cols="20%,40%",] -|==== -| `uid` -| User ID used to login. - -| `app` -| Restrict listing the settings for a given app. [default: ""]. - -| `key` -| Setting key to set, get or delete [default: ""]. -|==== - -=== Options - -[width="100%",cols="20%,40%",] -|==== -| `--output=[OUTPUT]` -| Output format (plain, json or json-pretty, default is plain). - -| `--ignore-missing-user` -| Use this option to ignore errors when the user does not exist. - -| `--default-value=[DEFAULT-VALUE]` -| If no default value is set and the config does not exist, the command + -will exit with 1. Only applicable on get. - -| `--value=[VALUE]` -| The new value of the setting. - -| `--update-only` -| Only updates the value, if it is not set before, it is not being added. - -| `--delete` -| Specify this option to delete the config. - -| `--error-if-not-exists` -| Checks whether the setting exists before deleting it. -|==== - -The descriptions for the `app` and `key` arguments may not be completely transparent. Here's a description of both. - -[width="100%",cols="20%,70%",options="header",] -|==== -| Argument -| Description - -| `app` -| When a value is supplied, `user:setting` limits the settings displayed to those for that specific application - assuming that the application is installed and that there are settings available for it. -Some example applications are `core`, `files_trashbin`, and `user_ldap`. -A complete list cannot be supplied as it is impossible to know the entire list of applications a user could potentially install. - -| `key` -| This value specifies the setting key to be manipulated (set, retrieved, or deleted) by the `user:setting` command. -|==== - -=== Retrieving User Settings - -To retrieve settings for a user, you need to call the `user:setting` command and supply at least the user's user name. You can drill down restricting results to a particular app and a key in the app. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:setting [] [] ----- - -=== Arguments - -[width="100%",cols="20%,70%",] -|==== -| `uid` -| User ID used to log in. - -| `app` -| Restrict listing the settings for a given app. [default: ""]. - -| `key` -| Setting key to set, get or delete [default: ""]. -|==== - -*Examples:* - -. Retrieve all settings set for a given user: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:setting layla - - core: - - lang: en - - login: - - lastLogin: 1465910968 - - settings: - - email: layla@example.tld ----- -+ -Here we see that the user has settings for the application `core`, when they last logged in, and what their email address is. - -. Retrieve all settings set restricted to application `core` for a given user: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:setting layla core - - core: - - lang: en ----- -+ -In the output, you can see that one setting is in effect, `lang`, which is set to `en`. - -. Retrieve all settings set restricted to application `core`, key `lang` for a given user -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:setting layla core lang ----- -+ -This will display the value for that setting, such as `en`. - -=== Setting and Deleting a Setting - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:setting [options] [--] [] [] ----- - -IMPORTANT: In case you want to change the email address, use xref:modify-user-details[the `user:modify` command]. - -Here's an example of how you would set the language of the user `layla`. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:setting layla core lang --value=en ----- - -Deleting a setting is quite similar to setting a setting. -In this case, you supply the username, application (or setting category) and key as above. -Then, in addition, you supply the `--delete` flag. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:setting layla core lang --delete ----- - -== Syncing User Accounts - -This command syncs users stored in external backend services, such as _LDAP_, _Shibboleth_, and _Samba_, with ownCloud's, internal user database. -However, it's not essential to run it regularly, unless you have a large number of users whose account properties have changed in a backend outside of ownCloud. -When run, it will pick up changes from alternative user backends, such as LDAP, where properties like `cn` or `display name` have changed, and sync them with ownCloud's user database. -If accounts are found that no longer exist in the external backend, you are given the choice of either removing or disabling the -accounts. - -NOTE: It's also xref:configuration/server/background_jobs_configuration.adoc#available-background-jobs[one of the commands] that you should run on a regular basis to ensure that your ownCloud installation is running optimally. - -NOTE: This command replaces the old `show-remnants` functionality, and brings the LDAP feature more in line with the rest of ownCloud's functionality. - -=== Usage - -[source,plaintext] ----- -user:sync [options] [--] [] ----- - -Synchronize users from a given backend to the accounts table. - -=== Arguments: - -[width="100%",cols="40%,90%,30%",options="header"] -|=== -| backend-class Type -| The quoted PHP class name for the backend -| Short Form - -| LDAP: -| `"OCA\User_LDAP\User_Proxy"` -| `ldap` - -| Samba: -| `"OCA\User\SMB"` -| `samba` - -| Shibboleth: -| `"OCA\User_Shibboleth\UserBackend"` -| `shibboleth` -|=== - -The argument for the backend class can be the quoted PHP class name but also the short form can be used. - -=== Options - -[width="90%",cols="50%,80%",] -|=== -| `-l` + -`--list` -| List all enabled backend classes. - -| `-u [UID]` + -`--uid=[UID]` -| Sync only the user with the given user id. - -| `-s` + -`--seenOnly` -| Sync only seen users. - -| `-c` + -`--showCount` -| Calculate user count before syncing. - -| `-m [MISSING-ACCOUNT-ACTION]` + -`--missing-account-action[=MISSING-ACCOUNT-ACTION]` -| Action to take if the account isn't connected to a backend any longer. + -Options are `disable` and `remove`. + -Note that removing the account will also remove the stored data and files for that account - -| `-r` + -`--re-enable` -| When syncing multiple accounts re-enable accounts that are disabled in ownCloud but available in the synced backend. -|=== - -Below are examples of how to use the command with an _LDAP_, _Samba_, -and _Shibboleth_ backend. - -=== LDAP - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:sync "OCA\User_LDAP\User_Proxy" ----- - -=== Samba - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:sync "OCA\User\SMB" -vvv ----- - -Below are examples of how to use the command with the *LDAP* backend along with example console output. - -=== Example 1 - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:sync "OCA\User_LDAP\User_Proxy" -m disable -r - Analysing all users ... - 6 [============================] - - No removed users have been detected. - - No existing accounts to re-enable. - - Insert new and update existing users ... - 4 [============================] ----- - -=== Example 2 - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:sync "OCA\User_LDAP\User_Proxy" -m disable -r - Analysing all users ... - 6 [============================] - - Following users are no longer known with the connected backend. - Disabling accounts: - 9F625F70-08DD-4838-AD52-7DE1F72DBE30, Bobbie, bobbie@example.org disabled - 53CDB5AC-B02E-4A49-8FEF-001A13725777, David, dave@example.org disabled - 34C3F461-90FE-417C-ADC5-CE97FE5B8E72, Carol, carol@example.org disabled - - No existing accounts to re-enable. - - Insert new and update existing users ... - 1 [============================] ----- - -=== Example 3 - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:sync "OCA\User_LDAP\User_Proxy" -m disable -r - Analysing all users ... - 6 [============================] - - Following users are no longer known with the connected backend. - Disabling accounts: - 53CDB5AC-B02E-4A49-8FEF-001A13725777, David, dave@example.org skipped, already disabled - 34C3F461-90FE-417C-ADC5-CE97FE5B8E72, Carol, carol@example.org skipped, already disabled - B5275C13-6466-43FD-A129-A12A6D3D9A0D, Alicia3, alicia3@example.org disabled - - Re-enabling accounts: - 9F625F70-08DD-4838-AD52-7DE1F72DBE30, Bobbie, bobbie@example.org enabled - - Insert new and update existing users ... - 1 [============================] ----- - -=== Example 4 - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:sync "OCA\User_LDAP\User_Proxy" -m disable -r - Analysing all users ... - 6 [============================] - - No removed users have been detected. - - Re-enabling accounts: - 53CDB5AC-B02E-4A49-8FEF-001A13725777, David, dave@example.org enabled - 34C3F461-90FE-417C-ADC5-CE97FE5B8E72, Carol, carol@example.org enabled - B5275C13-6466-43FD-A129-A12A6D3D9A0D, Alicia3, alicia3@example.org enabled - - Insert new and update existing users ... - 4 [============================] ----- - -=== Example 5 - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:sync "OCA\User_LDAP\User_Proxy" -m remove - ----- - -=== Example 6 - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:sync "OCA\User_LDAP\User_Proxy" -If unknown users are found, what do you want to do with their accounts? (removing the account will also remove its data) -[0] disable -[1] remove -[2] ask later ----- - -=== Syncing via cron job - -Here is an example for syncing with LDAP four times a day on Ubuntu: - -[source,bash] ----- -crontab -e -u www-data ----- - -[source,plaintext] ----- -* */6 * * * /usr/bin/php /var/www/owncloud/occ user:sync -vvv \ - --missing-account-action="disable" \ - -n "OCA\User_LDAP\User_Proxy" ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_versions_commands.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_versions_commands.adoc deleted file mode 100644 index 5857d89..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/occ_commands/core_commands/_versions_commands.adoc +++ /dev/null @@ -1,61 +0,0 @@ -= Versions - -NOTE: These commands are only available when the "Versions" app (`files_versions`) is enabled. -These commands are not available in xref:maintenance-commands[single-user (maintenance) mode]. - -== versions:cleanup - -`versions:cleanup` can delete all versioned files, as well as the `files_versions` folder, for either specific users, or for all users. A Published version persists until the original file is deleted by somebody with such permission or via the `occ versions:cleanup` command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} versions:cleanup []... ----- - -Options - -[width="100%",cols="22%,70%",] -|=== -| `user_id` | Delete versions of the given user(s), if no user is given all versions will be deleted. -|=== - -The example below deletes all versioned files for all users: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} versions:cleanup -Delete all versions -Delete versions for users on backend Database - freda - molly - stash - rosa - edward ----- - -You can delete versions for specific users in a space-delimited list: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} versions:cleanup freda molly -Delete versions of freda -Delete versions of molly ----- - -== versions:expire - -`versions:expire` deletes only expired files according to the `versions_retention_obligation` setting in `config.php` (see the File versions section in config_sample_php_parameters). -The default is to delete expired files for all users, or you may list users in a space-delimited list. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} versions:expire []... ----- - -Options - -[width="100%",cols="22%,70%",] -|=== -| `user_id` | Expire file versions of the given user(s), if no user is given file versions -for all users will be expired. -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/reverse_proxy_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/reverse_proxy_configuration.adoc deleted file mode 100644 index 44f6629..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/reverse_proxy_configuration.adoc +++ /dev/null @@ -1,72 +0,0 @@ -= Reverse Proxy Configuration -:toc: right -:toclevels: 1 -:page-aliases: go/admin-reverse-proxy.adoc - -== Introduction - -ownCloud can be run through a reverse proxy, which can cache static -assets such as images, CSS, or Javascript files, move the load of -handling HTTPS to a different server or load balance between multiple servers. - -== Defining Trusted Proxies - -For security, you must explicitly define the proxy servers that ownCloud -is to trust. Connections from trusted proxies will be specially treated -to get the real client information, for use in access control and -logging. Parameters are configured in config/config.php - -Set the `trusted_proxies` parameter as an array of IP address to define -the servers ownCloud should trust as proxies. This parameter provides -protection against client spoofing, and you should secure those servers -as you would your ownCloud server. - -A reverse proxy can define HTTP headers with the original client IP -address, and ownCloud can use those headers to retrieve that IP address. -ownCloud uses the de-facto standard header `X-Forwarded-For` by default, -but this can be configured with the `forwarded_for_headers` parameter. -This parameter is an array of PHP lookup strings, for example -`X-Forwarded-For` becomes `HTTP_X_FORWARDED_FOR`. Incorrectly setting -this parameter may allow clients to spoof their IP address as visible to -ownCloud, even when going through the trusted proxy! The correct value -for this parameter is dependent on your proxy software. - -== Overwrite Parameters - -The automatic hostname, protocol or webroot detection of ownCloud can -fail in certain reverse proxy situations. This configuration allows the -automatic detection to be manually overridden. - -If ownCloud fails to automatically detect the hostname, protocol or -webroot you can use the `overwrite` parameters inside the -config/config.php. The `overwritehost` parameter is used to set the -hostname of the proxy. You can also specify a port. The -`overwriteprotocol` parameter is used to set the protocol of the proxy. -You can choose between the two options `HTTP` and `HTTPS`. The -`overwritewebroot` parameter is used to set the absolute web path of the -proxy to the ownCloud folder. When you want to keep the automatic -detection of one of the three parameters you can leave the value empty -or don’t set it. The `overwritecondaddr` parameter is used to overwrite -the values dependent on the remote address. The value must be a *regular -expression* of the IP addresses of the proxy. This is useful when you -use a reverse SSL proxy only for HTTPS access and you want to use the -automatic detection for HTTP access. - -== Example - -=== Multiple Domains Reverse SSL Proxy - -If you want to access your ownCloud installation `\http://domain.tld/owncloud` via a -multiple domains reverse SSL proxy `\https://ssl-proxy.tld/domain.tld/owncloud` with -the IP address `10.0.0.1` you can set the following parameters inside the config/config.php. - -With an Apache as reverse proxy (ssl-proxy.tld) you can use this configuration: - -[source,apache] ----- -ProxyPass "/domain.tld/owncloud" "http://domain.tld/owncloud" -ProxyPassReverse "/domain.tld/owncloud" "http://domain.tld/owncloud" ----- - -NOTE: If you want to use the SSL proxy during installation you have to create -`config/config.php` manually, otherwise you have to extend the existing `$CONFIG` array. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/brute_force_protection.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/security/brute_force_protection.adoc deleted file mode 100644 index 2587ce9..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/brute_force_protection.adoc +++ /dev/null @@ -1,10 +0,0 @@ -= Brute-Force Protection - -The Brute-Force Protection extension allows administrators to specify a maximum number of unsuccessful user account login attempts. This protection not only covers login via browser but also password protected shares. On reaching the unsuccessful login limit, ownCloud temporarily bans further login attempts to those user accounts from the originating IP address. The time frame of the ban is configurable by ownCloud administrators. - -To configure this app in the web interface, navigate to `admin -> settings -> admin/security`. - -image:configuration/server/security/brute-force-protection.png[Brute-Force Protection] - -To configure this app on the command line you can use xref:configuration/server/occ_command.adoc#brute-force-protection[occ commands]. - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/dependency_notes.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/security/dependency_notes.adoc deleted file mode 100644 index 2c7d9e4..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/dependency_notes.adoc +++ /dev/null @@ -1,47 +0,0 @@ -= Dependency Notes -:toc:right -:page-aliases: configuration/server/security/jquery_warnings.adoc - -:description: The following list of dependencies may be reported as vulnerable but either have been fixed in the ownCloud codebase or do not apply. - -== Introduction - -{description} - -If you are aware of any issues that have not yet been patched or which are not included in this list, please notify us at mailto:security@owncloud.com[]. - -== Fixed Issues - -* jQuery - -** CVE-2020-11022 and CVE-2020-11023 + -https://github.com/owncloud/core/pull/37596[patched in 10.5.0] - -** CVE-2015-9251 + -https://github.com/owncloud/core/pull/31972[patched in 10.0.9 RC3] - -** CVE-2019-11358 + -https://github.com/owncloud/core/pull/38841[patched in 10.8.0] - -** CVE-2016-7103 + -https://github.com/owncloud/core/pull/39545[patched in 10.9.0] - -* jQuery-ui - -** CVE-2021-41182, CVE-2021-41183 and CVE-2021-41184 + -https://github.com/owncloud/core/pull/39451[patched in 10.9.0] - -** CVE-2022-31160 + -Component "checkboxradio" is not used by ownCloud - -* Select2 -** CVE-2016-10744 + -Component "select2" cannot be exploited - -* PDF -** CVE-2024-4367 + -When app `files_pdfviewer` is enabled with xref:configuration/server/config_apps_sample_php_parameters.adoc#enable-scripting-in-pdf-files[disabled scripting], CVE-2024-4367 can not be exploited - -* Bootstrap -** CVE-2024-6485 and CVE-2024-6484 + -There is no vulnerability because affected components are not used by ownCloud diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/hsmdaemon/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/security/hsmdaemon/index.adoc deleted file mode 100644 index 6231323..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/hsmdaemon/index.adoc +++ /dev/null @@ -1,549 +0,0 @@ -= The HSM (Hardware Security Module) Daemon (hsmdaemon) -:toc: right -:description: Learn how to install ownCloud’s custom HSM (Hardware Security Module) and configure ownCloud to delegate encryption to it. -:keywords: hsmdaemon, hardware security module, security, pkcs11, softhsm2 -:base64-encoding-url: https://en.wikipedia.org/wiki/Base64 -:hsm-url: https://en.wikipedia.org/wiki/Hardware_security_module -:jwt-url: https://jwt.io/ -:network-sockets-url: https://en.wikipedia.org/wiki/Network_socket -:opensc-wiki-url: https://github.com/OpenSC/OpenSC/wiki -:php-exec-function-url: https://www.php.net/manual/en/function.exec.php -:pkcs11-url: https://en.wikipedia.org/wiki/PKCS_11 -:pkcs11-tool-url: https://linux.die.net/man/1/pkcs11-tool -:softhsm2-url: https://www.opendnssec.org/softhsm/ -:unix-sockets-url: http://beej.us/guide/bgipc/html/multi/unixsock.html -:opendnssec-url: https://www.opendnssec.org/softhsm/ - -== Introduction - -The `hsmdaemon` is a daemon provided by ownCloud to delegate encryption to an {hsm-url}[HSM (Hardware Security Module)]. This can be necessary as PHP cannot directly interface with {pkcs11-url}[a PKCS11 stack], neither with an API wrapper because none exists, nor via the OpenSSL bindings. Therefore a separate process is needed to decrypt anything with the private key stored in an HSM. - -NOTE: When using `hsmdaemon` with an HSM, the keys _may_ still be stored on the same physical machine as ownCloud. - -NOTE: For `hsmdaemon` support, you need ownCloud Enterprise Edition >= 10.2. We recommend consulting with us when deploying storage encryption with an HSM. - -NOTE: Starting with the Encryption App version 1.5.1, HSM can now work with both `binary` and `base64` encoding/decoding. If not otherwise configured, `binary` is the default. - -Running {php-net-url}/manual/en/function.exec.php[exec()] to decrypt the key with a command line command to do the encryption might leak the HSM credentials if the admin lists the currently running processes. To prevent that, an HSM daemon will be used that can open a session to the HSM upon startup. - -This daemon will be used by ownCloud to decrypt the current master key upon request. The communication happens via {unix-sockets-url}[UNIX sockets] or {network-sockets-url}[TCP sockets] and is authorized by a shared token that the daemon stores in the ownCloud database via a REST/JSON route. - -ownCloud internally uses OpenSSL to encrypt and decrypt keys and that is extended to support en-/decrypt operations via the new daemon. The current solution encrypts the ownCloud master key with a key from the HSM. - -NOTE: From the technical point of view the `Crypt` class is extended to handle the key generation in the HSM device and also to get the key from HSM. For the read/write operation on a file, the request goes to the HSM and then, based on the keys fetched from HSM, the files are encrypted or decrypted. The keys are not replaced. - -== How The HSM Daemon Interacts with ownCloud - -Upon startup, the daemon will generate a token and send it to ownCloud via a new REST/JSON route. After connecting with the HSM daemon, an unsophisticated, line-based, protocol is used (every line ends with CRLF): - -. ownCloud sends the token read from database. -. The daemon compares the received token with its token and returns an `OK` line. -. ownCloud then sends the data it wants to decrypt as a {base64-encoding-url}[Base64-encoded], one-line string. -. The daemon returns the decrypted data as a Base64-encoded one-line string. - -Doing so ensures that an evil admin will need to wiretap the communication between either the database or the HSM daemon and ownCloud. - -== Quick Overview - -HSM support consists of two core parts: - -. An actual HSM PKCS11 module. -. A `hsmdaemon` that provides a {jwt-url}[JWT] - protected web API for the PKCS11 stack to generate key pairs and decrypt data. - -== Deployment Recommendation - -We recommend running `hsmdaemon` on every web server to reduce latency. - -== Installation - -Integrating the `hsmdaemon` with ownCloud requires 3 steps; these are: - -. xref:install-a-pkcs11-module[Install a PKCS11 Module] -. xref:install-and-configure-the-hsmdaemon[Install and Configure the hsmdaemon] -. xref:configure-owncloud[Configure ownCloud] - -[NOTE] -==== -The installation instructions in this guide have been designed to work with xref:installation/system_requirements.adoc#server[ownCloud's supported operating systems]. -If you are using a different operating system or distribution, please adjust the instructions to suit your environment. -==== - -=== Install a PKCS11 Module - -==== Install Using a Preconfigured PKCS11 Module - -At least one PKCS11 library is necessary. This is typically provided by an HSM vendor. If a PKCS11 library is not available, you can xref:configuration/server/security/hsmdaemon/softhsm2.adoc[use the software HSM - _SoftHSM2_]. - -==== Initialise the Token - -Now we can initialize the token: - -[source,bash] ----- -sudo softhsm2-util --init-token --slot 0 --label "My token 1" ----- - -It will ask for two PINs, an SO and a User pin. See {opendnssec-url}[opendnssec] for more information. The SO PIN can e.g. be used to re-initialize the token and the user PIN is handed out to the application so it can interact with the token. - -==== Install PKCS11 CLI tools (optional) - -To use the PKCS11 API on the CLI, we need to install {opensc-wiki-url}[OpenSC]. - -* xref:initialise-on-debian-and-ubuntu[Debian and Ubuntu] -* xref:initialise-on-opensuse-and-suse-linux-enterprise-server[openSUSE and SUSE Linux Enterprise Server] -* xref:initialise-on-fedora-and-red-hat-enterprise-linux-and-centos[Fedora and Red Hat Enterprise Linux and Centos] - -===== Initialise on Debian and Ubuntu - -To install OpenSC on Debian and Ubuntu, run the following command: - -[source,bash] ----- -sudo apt install -y opensc ----- - -===== Initialise on openSUSE and SUSE Linux Enterprise Server - -To install OpenSC on openSUSE and SUSE Linux Enterprise Server, run the following command: - -[source,bash] ----- -sudo zypper install -y --auto-agree-with-licenses opensc ----- - -===== Initialise on Fedora and Red Hat Enterprise Linux and Centos - -To install OpenSC on Fedora and Red Hat Enterprise Linux and Centos, run the following command: - -[source,bash] ----- -sudo yum install --assumeyes opensc ----- - -==== List Tokens - -You can list available tokens using the {pkcs11-tool-url}[pkcs11-tool] by running the following command: - -[source,bash] ----- -sudo pkcs11-tool --module -l --pin -O ----- - -===== The Module Parameter - -The module parameter is either the library provided by the HSM vendor or `libsofthsm2` which was installed with SoftHSM 2. If you are using `libsofthsm2`, the path to `libsofthsm2.so` for each of the supported distributions is available below. - -[options="headers",cols="2"] -|=== -|Distribution -| Path - -|Debian and Ubuntu -| `/usr/lib/softhsm/libsofthsm2.so` - -|openSUSE and SUSE Linux Enterprise Server -| `/usr/lib64/pkcs11/libsofthsm2.so` - -|Fedora and Red Hat Enterprise Linux and Centos -| `/usr/lib64/pkcs11/libsofthsm2.so` -|=== - -TIP: See the {opensc-wiki-url}[OpenSC Wiki] for more information. - -=== Install and Configure the hsmdaemon - -Installing hsmdaemon requires several steps. These are: - -. xref:install-the-hsmdaemon-binary[Install the hsmdaemon Binary] -. xref:copy-the-config-file[Copy the Config File] -. xref:install-the-system-service[Install the System Service] -. xref:configure-the-pkcs11-module-path[Configure the PKCS 11 Module Path] -. xref:configure-the-slot-and-pin[Configure Slot and Pin] -. xref:test-the-hsmdaemon[Test the hsmdaemon] -. xref:configure-other-options-optional[Configure Other Options] - -==== Install the hsmdaemon Binary - -After you have obtained the `hsmdaemon` from ownCloud, you need to move the `hsmdaemon` binary to a directory located in your system path and make the binary executable: - -[source,bash] ----- -sudo install -m 755 ./hsmdaemon /usr/local/bin/hsmdaemon ----- - -==== Copy the Config File - -The default location where `hsmdaemon` looks for its config file is `/etc/hsmdaemon/hsmdaemon.toml`. To create it from the example config file available in the provided package, run the following commands: - -Create the hsmdaemon configuration directory: -[source,bash] ----- -sudo mkdir /etc/hsmdaemon ----- - -Copy the example config file, allow only root and users in the root group to read & write the configuration file: -[source,bash] ----- -sudo install -m 640 ./hsmdaemon.toml /etc/hsmdaemon/hsmdaemon.toml ----- - -==== Install the System Service - -Now that the binary is available and the configuration file is in place, `hsmdaemon` must be installed as a system service. To do so, run it with the `install` option as in the example below. - -[source,bash] ----- -sudo /usr/local/bin/hsmdaemon install -sudo service hsmdaemon start ----- - -If it installs successfully, you should see the following console output: - -[source,plaintext] ----- -Install HSM Daemon: [ OK ] ----- - -It should now be running and set to start automatically at boot time. - -[TIP] -==== -The daemon is managed using the following three commands: - -* `sudo service hsmdaemon start` -* `sudo service hsmdaemon stop` and -* `sudo service hsmdaemon status` -==== - -==== Configure the PKCS11 Module Path - -To set the path to the PKCS11 module, update the line below in `/etc/hsmdaemon/hsmdaemon.toml`, with the appropriate path on your system. - -[source,toml] ----- -[pkcs11] -# softhsm v2 -module = "/usr/lib/x86_64-linux-gnu/softhsm/libsofthsm2.so" ----- - -==== List Available Slots - -This command lists the available slots. - -[source,bash] ----- -sudo hsmdaemon listslots ----- - -[source,plaintext] ----- -{"level":"debug","ts":"2019-02-14T09:27:02.068+0100","caller":"hsmdaemon/keymanager.go:27","msg":"initialize pkcs11 module","module":"/usr/lib/softhsm/libsofthsm2.so"} -{"level":"info","ts":"2019-02-14T09:27:02.087+0100","caller":"hsmdaemon/keymanager.go:65","msg":"Slots found","slotIds":[550099622,1989683358,2]} -Available slots: -Slot: 550099622, - Slot info: - Description: SoftHSM slot ID 0x20c9daa6 - Manufacturer ID: SoftHSM project - Hardware version: 2.2 - Firmware version: 2.2 - Token present: yes - Flags: - Token info: - Manufacturer ID: SoftHSM project - Model: SoftHSM v2 - Hardware version: 2.2 - Firmware version: 2.2 - Serial number: e8ba06bca0c9daa6 - Initialized: yes - User PIN init.: yes - Label: oc token without pin - MaxSessionCount: 0 - SessionCount: 18446744073709551615 - MaxRwSessionCount: 0 - RwSessionCount: 18446744073709551615 - MaxPinLen: 255 - MinPinLen: 4 - TotalPublicMemory: 18446744073709551615 - FreePublicMemory: 18446744073709551615 - TotalPrivateMemory: 18446744073709551615 - FreePrivateMemory: 18446744073709551615 - UTCTime: 2019021408270200 - Flags: CKF_RNG CKF_LOGIN_REQUIRED CKF_RESTORE_KEY_NOT_NEEDED CKF_USER_PIN_COUNT_LOW -Slot: 1989683358, - Slot info: - Description: SoftHSM slot ID 0x7698289e - Manufacturer ID: SoftHSM project - Hardware version: 2.2 - Firmware version: 2.2 ----- - -TIP: See the {opensc-wiki-url}[OpenSC Wiki] for more information. - -==== Configure the Slot and Pin - -Define which slot to use and if a PIN is needed. Update `/etc/hsmdaemon/hsmdaemon.toml` with the information gathered in the `pkcs11` section as in the example below. - -[source.toml] ----- -[pkcs11] -# softhsm v2 -module = "/usr/lib/x86_64-linux-gnu/softhsm/libsofthsm2.so" -# The user pin supplied when running softhsm2-util --init-token, comment it out -# or leave empty if no pin is necessary -pin = "1234" -# Find your slot id with `sudo hsmdaemon listslots` -slot = 550099622 ----- - -== Test the hsmdaemon - -=== Test Key Generation - -[NOTE] -==== -If no PIN is supplied, generating a new key might be protected by an operator card that has to be inserted in the HSM. In this case, coordinate testing and final master key generation with your HSM team. -==== - -For testing the key generation, run the following example command: - -[source,bash] ----- -sudo hsmdaemon genkey test - -Id: 9bac3719-2b8d-11e9-aeab-0242b5ece4c3, label: test - ------BEGIN PUBLIC KEY----- -MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAl1BO4vsI+xDk+x0nccl7 -HQhMR/hwfa0+N8fyYNI8yzTTmYDqz9aaF20qG48+mjC0AUEt2kfKo94xM3UeEw4c -st4j1dpRJtmAJThcuN8OH3sa+3MeXWgGuWxjB1lxEEOqax2A6XzllDlbDsogwkOL -hSkUU9AaMRBtF8fASJGtJDP+iXwdb7OsFg78PS1wBAISYSUwk06xY7LwWIxge+hY -4oU+5x4itusdO6rz6kbcJtmUyDUb8DhKnN6OdkhnifUZLBG9HQyTa5OM+BAabbFZ -mTM2gZlUnGKXN7c4kaBPFt1IfjjVYu7pvj3B2uxUf4GywuSuWGWnAy89FqeXteRV -jwIDAQAB ------END PUBLIC KEY----- ----- - -=== Test Showing Keys - -To show an existing key, use the `hsmdaemon showkey` command with the key's id as in the following example. - -[source,bash] ----- -sudo hsmdaemon showkey 9bac3719-2b8d-11e9-aeab-0242b5ece4c3 ----- - -=== Test Data Encryption - -For testing data encryption, run the following example commands: - -The first argument is the `Id:` value from running the genkey command above. The second is the `base64-encoded data` to be encrypted. -[source,bash] ----- -sudo hsmdaemon encrypt 9bac3719-2b8d-11e9-aeab-0242b5ece4c3 Zm9vYmFy ----- - -If successful, you should see output similar to the example below: - -[source,plaintext,options="nowrap"] ----- -{"level":"debug","ts":"2019-03-20T12:43:40.540+0100","caller":"hsmdaemon/keymanager.go:27","msg":"initialize pkcs11 module","module":"/usr/lib/softhsm/libsofthsm2.so"} -{"level":"debug","ts":"2019-03-20T12:43:40.545+0100","caller":"hsmdaemon/keymanager.go:205","msg":"openHSMSession","slotID":858597139} -{"level":"info","ts":"2019-03-20T12:43:40.549+0100","caller":"hsmdaemon/keymanager.go:621","msg":"Fetching private key","keyID":"9bac3719-2b8d-11e9-aeab-0242b5ece4c3"} -{"level":"debug","ts":"2019-03-20T12:43:40.549+0100","caller":"hsmdaemon/keymanager.go:641","msg":"Got uuid","string":"13d34146-4b02-11e9-adbd-0023ae27c404"} -WcezVb2N6bF8wlDooKZcmFn3tZgoIpoFGx6wQetx9sp1nK7JW2Y4OKt7P+0VKKlFO7yXaffVDD2Q6jZZCQukQVRV1zJrwbI9xU3YlOAwJFPP+WM/dZ1vdUwi7L05wq8UpL13LJWlMkvd1eIqKJS7apMnFk2hbnxXP6UKZmI++1tXvqbAc6fwhcB5J+JG6lmS4RwnD+eJC3dq5t00zzdI6vuIM/y3UT7ESklmHl5bKl+N+d6yk6qLxnFnIJweL+M3Tf13+XPNAh5JxZpheJPvN3oL28uX76aizy4BCLnRgQ/ryUQeDF+a4zNF22sMwBh4Pt46KrYGNDZAnQpVzmkrZQ== ----- - -=== Test Data Decryption - -For testing data decryption, run the following example commands: - -[source,bash] ----- -sudo grep "generated keypair" /var/log/hsm.log ----- - -You should see output similar to the example below: - -[source,plaintext,options="nowrap"] ----- -{"level":"debug","ts":"2021-06-19T03:10:01.562+0200","msg":"generated keypair","tokenID":"1262668f-d09b-11eb-b283-960000c05f34"} -{"level":"debug","ts":"2021-06-19T03:10:03.043+0200","msg":"generated keypair","tokenID":"1374447f-d09b-11eb-83c8-960000c05f34"} -{"level":"debug","ts":"2021-06-19T03:10:03.710+0200","msg":"generated keypair","tokenID":"13cd3f95-d09b-11eb-83c8-960000c05f34"} ----- - -[source,bash] ----- -key_id=$(sudo grep "generated keypair" /var/log/hsm.log | head -1 | jq .tokenID -r) ----- - -[source,plaintext] ----- -hello="Hello, world!" ----- - -[source,bash] ----- -echo "$hello" | base64 - -SGVsbG8sIHdvcmxkIQo= ----- - -[source,bash] ----- -test_enc=$(sudo ./hsmdaemon encrypt $key_id $(echo "$hello" | base64) | tee /dev/stderr) ----- - -[source,plaintext,options="nowrap"] ----- -ep6Y1aAVAYpAesZ1+sQzzUepjO82o34kjmm63Drmz+6KED4oIBARQkXeW/OoxgUg6kQhQK1thA/3Ww33aaRxIESzVQF598qjXhhEXQ/OGL6BC+3tPclC7ujUZaA7CG1NDkMneLFDd2+Tbax4OM+/w0zhfTMPgT0I1NrH/03owVglbWHjgLZmN/vxpPZKm/lyAV9tI2HW36UjVLEMD2qtPFXqjLU4YjZOVnMdETxQNSCWIVauFw0+VQQ/RiAqiXzRXEgO6YKxOBk0n9IMT6XEH4MkMQTgb9pB12jrNSa9aMHbCvCneEmhd0CHBxPX499EkxxwtoEnXe6PATXsOg3VRA== ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:hsmdaemon:decrypt --keyId $key_id "$test_enc" - -decrypted string (base64 encoded): 'SGVsbG8sIHdvcmxkIQo=' ----- - -[source,bash] ----- -sudo tail -5 /var/log/hsm.log ----- - -[source,plaintext,options="nowrap"] ----- -{"level":"debug","ts":"2021-06-20T23:46:11.958+0200","msg":"openHSMSession","slotID":757826573} -{"level":"debug","ts":"2021-06-20T23:46:11.960+0200","msg":"created new session"} -{"level":"debug","ts":"2021-06-20T23:46:11.960+0200","msg":"Got uuid","string":"1262668f-d09b-11eb-b283-960000c05f34"} -{"level":"debug","ts":"2021-06-20T23:46:11.962+0200","msg":"found object","id":"\u0012bf\ufffdЛ\u0011벃\ufffd\u0000\u0000\ufffd_4"} -{"level":"debug","ts":"2021-06-20T23:46:11.963+0200","msg":"Decrypted"} ----- - -**Results** - -* [x] The base64 encoded string matches before encryption and after decryption. -* [x] The key-id seen in the log with "generated keypair" causes no errors during encryption. -* [x] The key-id re-appears in the log during decryption ("Got uuid") - -//// -=== Testing Key Deletion - -TODO. -//// - -== Configure Other Options (optional) - -For more options see the self-documented default config file `hsmdaemon.toml`. - -[TIP] -==== -During ownCloud config, you might want to run the hsmdaemon service in the foreground to see what is going on. You can do so using the following command (which also shows example console output, formatted for readability): - -[source,bash] ----- -sudo hsmdaemon ----- - -[source,plaintext] ----- -{ - "level": "info", - "ts": "2019-02-14T09:32:59.081+0100", - "caller": "hsmdaemon/hsmdaemon.go:146", - "msg": "Server listening", - "host": "localhost", - "port": 8513, - "version": "0.0.7", - "build": "2019-02-08T10:47:55+00:00" -} ----- -==== - -== Configure ownCloud - -[IMPORTANT] -==== -If anyone accesses ownCloud while encryption is enabled, it will automatically generate the keys. To prevent this shut down the web server until encryption is appropriately configured. -==== - -Configuring ownCloud to work with the `hsmdaemon` requires the following steps: - -* xref:generate-a-secret-for-the-hsmdaemon-rest-api[Generate a Secret for the hsmdaemon REST API] -* xref:configure-hsm-based-encryption[Configure HSM-based Encryption] -* xref:initialize-and-check-generated-keys[Initialize and Check Generated Keys] - -=== Generate a Secret for the hsmdaemon REST API - -Generate a shared secret to use for the `hsmdaemon`. - -[source,bash] ----- -cat /proc/sys/kernel/random/uuid ----- -[source,plaintext] ----- -7a7d1826-b514-4d9f-afc7-a7485084e8de ----- - -Use this generated secret for hsmdaemon in `/etc/hsmdaemon/hsmdaemon.toml` - -[source,toml] ----- -[jwt] -secret = "7a7d1826-b514-4d9f-afc7-a7485084e8de" ----- - -Set the generated secret for ownCloud: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set encryption hsm.jwt.secret --value '7a7d1826-b514-4d9f-afc7-a7485084e8de' ----- - -If the command succeeds, you should see the following console output: - -[source,plaintext] ----- -Config value hsm.jwt.secret for app encryption set to 7a7d1826-b514-4d9f-afc7-a7485084e8de ----- - -=== Configure HSM-based Encryption - -Enable the HSM mode and enable encryption by running the commands in the following example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable encryption -{occ-command-example-prefix} config:app:set encryption hsm.url --value 'http://localhost:8513' -{occ-command-example-prefix} encryption:enable ----- - -If the commands are successful, you should see the following console output: - -[source,plaintext] ----- -encryption enabled - -Config value hsm.url for app encryption set to http://localhost:8513 - -Master key successfully enabled. - -Encryption enabled -Default module: OC_DEFAULT_MODULE ----- - -//// -==== Configure Authorization - -TBW. -//// - -=== Initialize and Check Generated Keys - -Now start your web server and log in with any user to initialize the keys, have a look at the output of the `hsmdaemon` to see key generation and decryption requests. Check that the private key `/path/to/data/files_encryption/OC_DEFAULT_MODULE/` is less than *1000 bytes*. If it is not, then something is not configured correctly. You have to wipe all keys and reset the database flags for encryption to get a clean start for the ownCloud setup. - -//// -TODO - -* Provide occ commands for key initialization and removal. Don't rely on user login to generate keys. -//// diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/hsmdaemon/softhsm2.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/security/hsmdaemon/softhsm2.adoc deleted file mode 100644 index c471f26..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/hsmdaemon/softhsm2.adoc +++ /dev/null @@ -1,122 +0,0 @@ -= SoftHSM2 -:toc: right -:softhsm2-url: https://www.opendnssec.org/softhsm/ -:opensuse-security-repositories-url: https://download.opensuse.org/repositories/security/ - -SoftHSM2 is a simple approach for employing storage encryption with a master key in an HSM, because it stores the keys in place of ownCloud. - -== Use SoftHSM2 With hsmdaemon - -SoftHSM2 can be used with and xref:configuration/server/security/hsmdaemon/index.adoc[hsmdaemon] to store keys in place of ownCloud; either on the same or a different machine as ownCloud. -Because keys are stored with a different owner to ownCloud, it prevents the web server (xref:installation/system_requirements.adoc#officially-supported-environments[typically Apache]) from directly reading the key material. -This helps prevent a malicious actor from reading files, if they can impersonate the web server user. -However, it doesn't help if the malicious actor can manipulate PHP files and run arbitrary code. - -IMPORTANT: If you run SoftHSM2 and hsmdaemon on a different machine on the network, know that the hsmdaemon traffic is not encrypted. -In this scenario, the systems administrator would need to setup a secure tunnel to encrypt the traffic. - -== Install SoftHSM2 - -If you do not have an HSM-provided PKCS11 library, then you can use {softhsm2-url}[SoftHSM2] instead. -To do so, follow the instructions for you Linux distribution below. - -* xref:install-on-debian-and-ubuntu[Debian and Ubuntu] -* xref:install-on-opensuse-and-suse-linux-enterprise-server[openSUSE and SUSE Linux Enterprise Server] -* xref:install-on-fedora-and-red-hat-enterprise-linux-and-centos[Fedora and Red Hat Enterprise Linux and Centos] - -NOTE: Installing these two packages also installs `/usr/lib/x86_64-linux-gnu/softhsm/libsofthsm2.so`, which is a module that we will need later, for interaction with the PKCS11 API. - -=== Install on Debian and Ubuntu - -To install SoftHSM2 on either Debian or Ubuntu, run the command below. - -[source,bash] ----- -sudo apt-get update -sudo apt-get install -y softhsm2 libsofthsm2 ----- - -=== Install on openSUSE and SUSE Linux Enterprise Server - -To install SoftHSM2, you first have to ensure that you have {opensuse-security-repositories-url}[the official security repository] for your server enabled in your server's repositories list. -To check if it is, run the command `zypper lr`, which will show you output similar to the following: - -[source,plaintext] ----- -# | Alias | Name | Enabled | GPG Check | Refresh ----+---------------------------+-----------------------------------------+---------+-----------+-------- - 1 | openSUSE-Leap-15.3-1 | openSUSE-Leap-15.3-1 | No | ---- | ---- - 2 | repo-debug | Debug Repository | No | ---- | ---- - 3 | repo-debug-non-oss | Debug Repository (Non-OSS) | No | ---- | ---- - 4 | repo-debug-update | Update Repository (Debug) | No | ---- | ---- - 5 | repo-debug-update-non-oss | Update Repository (Debug, Non-OSS) | No | ---- | ---- - 6 | repo-non-oss | Non-OSS Repository | Yes | (r ) Yes | Yes - 7 | repo-oss | Main Repository | Yes | (r ) Yes | Yes - 8 | repo-sle-debug-update | Update repository with debuginfo for... | No | ---- | ---- - 9 | repo-sle-update | Update repository with updates from... | Yes | (r ) Yes | Yes -10 | repo-source | Source Repository | No | ---- | ---- -11 | repo-update | Main Update Repository | Yes | (r ) Yes | Yes -12 | repo-update-non-oss | Update Repository (Non-Oss) | Yes | (r ) Yes | Yes ----- - -TIP: Use the `-d` flag to show the URI for each repository as well. - -If there is no security repository listed, then add it using the following command for openSUSE Leap 15.3: - -[source,bash] ----- -sudo zypper addrepo \ - --check \ - --refresh \ - --name "openSUSE-Leap-15.3-Security" \ - https://download.opensuse.org/repositories/security/openSUSE_Leap_15.3/security.repo \ - "repo-security" ----- - -Running `zypper lr` again should now display an additional line: - -[source,plaintext] ----- -13 | security | openSUSE-Leap-15.3-Security | Yes | (r ) Yes | No ----- - -For different Leap versions, SUSE Linux Enterprise or openSUSE Tumbleweed, change the name and modify the product part of the URI as listed in {opensuse-security-repositories-url}[the official security repository]. - -With the repository enabled, install SoftHSM2 by running the following command: - -[source,bash] ----- -sudo zypper install -y --auto-agree-with-licenses softhsm ----- - -=== Install on Fedora and Red Hat Enterprise Linux and Centos - -To install SoftHSM2 on Fedora and Red Hat Enterprise Linux and Centos, run the command below. - -[source,bash] ----- -sudo yum install --assumeyes softhsm ----- - -=== Check the Configuration File - -Once SoftHSM2 is installed, check that the directory specified by `directories.tokendir` in SoftHSM2's configuration file exists. - -[options="headers",cols="3"] -|=== -|Distribution |Configuration File Location |Tokens Directory -|Debian and Ubuntu |`/etc/softhsm/softhsm2.conf` .3+|`/var/lib/softhsm/tokens/` -|openSUSE and SUSE Linux Enterprise Server |`/etc/softhsm2.conf` -|Fedora and Red Hat Enterprise Linux and Centos |`/etc/softhsm2.conf` -|=== - -[source,ini] ----- -# SoftHSM v2 configuration file - -directories.tokendir = /var/lib/softhsm/tokens/ -objectstore.backend = file - -# ERROR, WARNING, INFO, DEBUG -log.level = INFO ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/index.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/security/index.adoc deleted file mode 100644 index 73af901..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/index.adoc +++ /dev/null @@ -1,10 +0,0 @@ -:section-title: Server Security -:section-preamble-ender: to configure ownCloud securely - -include::partial$section_page.adoc[] - -* xref:configuration/server/security/oauth2.adoc[OAuth2] -* xref:configuration/server/security/password_policy.adoc[Password Policy] -* xref:configuration/server/security/brute_force_protection.adoc[Brute-Force Protection] -* xref:configuration/server/security/hsmdaemon/softhsm2.adoc[Hardware Security Module Daemon] -* xref:configuration/server/security/jquery_warnings.adoc[jQuery Warnings] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/oauth2.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/security/oauth2.adoc deleted file mode 100644 index 5bc9d0f..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/oauth2.adoc +++ /dev/null @@ -1,238 +0,0 @@ -= Open Authentication (OAuth2) -:toc: right -:mod_headers-url: http://httpd.apache.org/docs/current/mod/mod_headers.html -:mod_rewrite-url: http://httpd.apache.org/docs/current/mod/mod_rewrite.html -:oauth2-user-auth-url: https://oauth.net/articles/authentication/ -:shibboleth-app-url: {oc-marketplace-url}/apps/user_shibboleth -:official-oauth2-rfc-url: https://datatracker.ietf.org/doc/html/rfc6749#section-10 -:official-client-registration-rfc-url: https://tools.ietf.org/html/rfc6749#section-2 -:official-authorization-request-rfc-url: https://tools.ietf.org/html/rfc6749#section-4.1.1 -:official-authorization-response-rfc-url: https://tools.ietf.org/html/rfc6749#section-4.1.2 -:client-authentication-url: https://tools.ietf.org/html/rfc6749#section-2.3 -:official-access-token-request-rfc-url: https://tools.ietf.org/html/rfc6749#section-4.1.3 -:official-access-token-response-rfc-url: https://tools.ietf.org/html/rfc6749#section-4.1.4 -:stackoverflow-url: https://stackoverflow.com/a/16341985/222011 - -== Introduction - -OAuth2 (OpenAuthentication) is summarized in https://tools.ietf.org/html/rfc6749#section-4.1.1[RFC 6749] as follows: - -[quote,OAuth2 Overview] -The OAuth 2.0 authorization framework enables a third-party application to obtain limited access to an HTTP service, either on behalf of a resource owner by orchestrating an approval interaction between the resource owner and the HTTP service, or by allowing the third-party application to obtain access on its own behalf. - -Here is an overview of how the process works: - -// Based on the kroki extension. Marked for ease of finding. Be aware that this renders by default to svg which has issues when building pdf. ATM, this is not an issue as this document is not part of the pdf (too deep in the level limit) and because the extension is not added to the pdf build call. This would need an adjustment of the script. Be aware that tabs.js MUST be excluded in case (html only)! https://github.com/Mogztter/asciidoctor-kroki - -image:configuration/server/security/oauth2-workflow-diagram.png[] -//// -[ditaa, "OAuth2 workflow diagram"] ----- - +----------+ - | Resource | - | Owner | - | | - +----------+ - ^ - | - (B) - | - | - +----------+ Client Identifier +---------------+ - | |----(A)-- & Redirection URI ---->| | - | User- | | Authorization | - | Agent |----(B)-- User authenticates --->| Server | - | | | | - | |<---(C)-- Authorization Code ----| | - +----------+ +---------------+ - ^ | ^ | - | | | | - (A) (C) | | - | | | | - | v | | - +---------+ | | - | |----(D)-- Authorization Code ---------+ | - | Client | & Redirection URI | - | | | - | |<---(E)----- Access Token -------------------+ - +---------+ (w/ Optional Refresh Token) ----- -//// - -== The OAuth2 App - -OAuth2 support is available in ownCloud via the {oc-marketplace-url}/apps/oauth2[OAuth2] application which is available from the ownCloud Marketplace. The app aims to: - -. Connect ownCloud clients (both desktop and mobile) in a standardized and secure way. -. Make 3rd party software integrations easier by providing an unified authorization interface. - -=== Requirements - -To use the OAuth2 app, your ownCloud installation will need to meet the following dependencies: - -* *Apache:* If you are hosting your ownCloud installation using the Apache web server, then {mod_rewrite-url}[mod_rewrite] and {mod_headers-url}[mod_headers] modules must be installed and enabled. -* *Redis:* You will need to have a Redis server available, ideally the latest, stable version. -* *PHP-Redis:* You PHP installation must have the php-redis extension (>= 4.2) installed and enabled. - -See the xref:installation/manual_installation/manual_installation.adoc[Detailed Installation Guide] for how to install Redis and PHP-Redis. - -=== Installation - -To install the application, download the {oc-marketplace-url}/apps/oauth2[OAuth2 app] from the marketplace to the ownCloud `app` directory or use the Market app. - -=== Basic Configuration - -To enable token-only based app or client logins in `config/config.php`, set `token_auth_enforced` to `true`. This prevents new clients logging in via username and password. Existing client connections remain active, until they log out. See xref:configuration/server/config_sample_php_parameters.adoc[config sample file] for more details. - -TIP: The OAuth2 app comes with a set of `occ` commands to configure clients. For more information on usage of `occ` for OAuth2, see section xref:configuration/server/occ_command.adoc#oauth2[OAuth2 Commands]. - -==== Trusting Clients - -Since version 0.5.0 of the OAuth2 app, you can mark clients as trusted. This will have the effect that the consent step in the authentication process will be skipped for this client. - -CAUTION: Only mark trustworthy clients and web apps under your control as trusted. Apps which cannot keep the `Client Identifier (ID)` secret or have `redirect URIs` which can not be fully controlled should not be marked as trusted. + -Refer to the {official-oauth2-rfc-url}[official OAuth2 RFC sections 10.1 and 10.2] for further information about the risks. - -image:configuration/server/security/oauth2_configuration.png[image] - -If you want to mark an existing client as trusted, you have to: - -* Copy the `Client Identifier (ID)` and the `Client Secret`. -* Then delete the existing entry either in the UI or via the xref:configuration/server/occ_command.adoc#oauth2[occ oauth2 remove command]. -* And finally add it again with the xref:configuration/server/occ_command.adoc#oauth2[occ oauth2 add command] with the trusted setting enabled. + -When deleting in the web UI, you might need to scroll horizontally to see the delete buttons. Follow this link regarding xref:configuration/user/oidc/oidc.adoc#client-ids-secrets-and-redirect-uris[Client IDs, Secrets and Redirect URIs] for ownCloud clients. - -==== Restricting Usage - -- Enterprise installations can limit the access of authorized clients, preventing unwanted clients from connecting. - -==== Endpoints - -[width="60%",cols="30%,70%",options="header",] -|========================== -| Description -| URI - -| Authorization URL -| `/index.php/apps/oauth2/authorize` - -| Access Token URL -| `/index.php/apps/oauth2/api/v1/token` -|========================== - -=== Protocol Flow - -==== Client Registration - -Clients first have to be registered in the web-UI menu:Settings[Admin > Authentication]. You need to specify a name for the client (the name is unrelated to the OAuth 2.0 protocol and is just used to recognize it later) and the redirection URI. A _client identifier_ and _client secret_ are generated when adding a new client, which both consist of 64 characters. - -Refer to the -{official-client-registration-rfc-url}[official client registration RFC from the IETF] -for further information about client registration. - -==== Authorization Request - -For every registered client, an authorization request can be made. The client redirects the resource owner to the authorization URL and requests authorization. The following URL parameters have to be specified: - -[width="100%",cols="15%,^10%,60%",options="header",] -|========================== -| Parameter -| Required -| Description - -| `response_type` -| yes -| Needs to be `code` because at this time only the authorization code flow is implemented. - -| `client_id` -| yes -| The client identifier obtained when registering the client. - -| `redirect_uri` -| yes -| The redirection URI specified when registering the client. - -| `state` -| no -| Can be set by the client "to maintain state between the request and callback". See `RFC 6749`_ for more information. -|========================== - -Refer to the -{official-authorization-request-rfc-url}[official authorization request RFC from the IETF] -for further information about client registration. - -==== Authorization Response - -After the resource owner's authorization, the app redirects to the `redirect_uri` specified in the authorization request and adds the authorization code as `URL parameter code`. An authorization code is valid for 10 minutes. - -Refer to the -{official-authorization-response-rfc-url}[official authorization response RFC from the IETF] -for further information about client registration. - -==== Access Token Request - -With the authorization code, the client can request an access token using the access token URL. -{client-authentication-url}[Client authentication] is done using basic authentication with the client identifier as username and the client secret as a password. The following URL parameters have to be specified: - -[width="100%",cols="15%,60%,50%",options="header",] -|========================== -| Parameter -| Required -| Description - -| `grant_type` -| -| Use either `authorization_code` or `refresh_token`. - -| `code` -| If the grant type `authorization_code` is used. -| - -| `redirect_uri` -| If the grant type `authorization_code` is used. -| - -| `refresh_token` -| If the grant type `refresh_token` is used. -| -|========================== - -Refer to the -{official-access-token-request-rfc-url}[official access token request RFC from the IETF] -for further information about client registration. - -==== Access Token Response - -The app responds to a valid access token request with a JSON response like the following. An access token is valid for 1 hour and can be refreshed with a refresh token. - -[source,json] ----- -{ - "access_token" : "1vtnuo1NkIsbndAjVnhl7y0wJha59JyaAiFIVQDvcBY2uvKmj5EPBEhss0pauzdQ", - "token_type" : "Bearer", - "expires_in" : 3600, - "refresh_token" : "7y0wJuvKmj5E1vjVnhlPBEhha59JyaAiFIVQDvcBY2ss0pauzdQtnuo1NkIsbndA", - "user_id" : "admin", - "message_url" : "https://www.example.org/owncloud/index.php/apps/oauth2/authorization-successful" -} ----- - -Refer to the -{official-access-token-response-rfc-url}[official access token response RFC from the IETF] -for further information about client registration. - -NOTE: For a succinct explanation of the differences between access tokens and authorization codes, -check out this {stackoverflow-url}[answer on StackOverflow]. - -=== Limitations - -- Since the app does not handle user passwords, only master key encryption works (similar to the {shibboleth-app-url}[Shibboleth app]). -- Clients cannot migrate accounts from Basic Authorization to OAuth2, if they are currently using the `user_ldap` backend. -- It is not possible to explicitly end user sessions when using OAuth2. Have a read through {oauth2-user-auth-url}[User Authentication with OAuth 2.0] to find out more. - -== Further Reading - -* https://oauth.net/articles/authentication/[User Authentication with OAuth 2.0] -* http://www.thread-safe.com/2012/01/problem-with-oauth-for-authentication.html[The problem with OAuth for Authentication.] -* https://security.stackexchange.com/questions/81756/session-authentication-vs-token-authentication[Session Authentication vs Token Authentication] -* https://tools.ietf.org/html/rfc7009[OAuth 2.0 Token Revocation] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/password_policy.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/security/password_policy.adoc deleted file mode 100644 index b57f584..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/security/password_policy.adoc +++ /dev/null @@ -1,77 +0,0 @@ -= Password Policy -:toc: right - -== The Password Policy App - -image:configuration/server/security/password-policy-app.png[The Password Policy application] - -From the 2.0.0 release of {oc-marketplace-url}/apps/password_policy[the Password Policy app], -ownCloud administrators (both enterprise **and** community edition) have the option of installing and enabling -the application. The Password Policy application enables administrators to define password requirements -for user passwords and public links. - -Some policy rules apply to both user passwords and public links, and some apply to just one or the other. -The table below shows where each option can be used. - -[cols="2,1,1",options="header"] -|=== -| Setting -| User Passwords -| Public Links - -| Specify valid password requirements -| * -| * - -| Disallow usage of a number of previous passwords -| * -| - -| Specify a password expiration period -| * -| - -| Forced password change on first login -| * -| - -| Disallowing passwords that match a configurable number of previous passwords (defaults to the previous 3). -| * -| - -| Users can be notified a configurable number of days before their password expires -| * -| - -| Users will be notified when their password has expired. -| * -| - -| Specify expiration dates for public link shares -| -| * - -| Specify the number of days until link expires if a password is set -| -| * - -| Specify the number of days until link expires if a password is *not* set -| -| * - -|=== - -Here is an example of what an administrator will see: - -image:configuration/server/password-policy/password-policy-configuration-web-ui.png[The ownCloud Password Policy app.] - -NOTE: Active user sessions will **not** end when passwords expire. -However, a password change will be forced when the user session expires (e.g., on logout). -OAuth2 tokens for app or client authentication, and App passwords are not affected. - -NOTE: Installing and enabling the application also extends the occ command to support -xref:configuration/server/occ_command.adoc#password-policy[password policy] management. - -CAUTION: After enabling the "*days until user password expires*" policy setting in the web UI, -administrators need to run the `occ user:expire-password` command to set an initial password -change date for all existing users. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/security_setup_warnings.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/security_setup_warnings.adoc deleted file mode 100644 index 6823016..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/security_setup_warnings.adoc +++ /dev/null @@ -1,135 +0,0 @@ -= Warnings on Admin Page -:toc: right - -== Introduction - -Your ownCloud server has a built-in configuration checker, and it -reports its findings at the top of your Admin page. These are some of -the warnings you might see, and what to do about them. - -image:security-setup-warning-complete.png[image] - -== Cache Warnings - ----- -No memory cache has been configured. To enhance your performance please configure a memcache if available. ----- - -ownCloud supports multiple PHP caching extensions: - -* APCu -* Memcached -* Redis (minimum required PHP extension version: 2.2.6) - -You will see this warning if you have no caches installed and enabled, -or if your cache does not have the required minimum version installed; -older versions are disabled because of performance problems. - -If you see `__\{Cache}__ below version _\{Version}_ is installed. for -stability and performance reasons we recommend to update to a newer -_\{Cache}_ version` then you need to upgrade, or, if you’re not using it, remove it. - -You are not required to use any caches, but caches improve server -performance. See caching_configuration. - -== Transactional file locking is disabled - ----- -Transactional file locking is disabled, this might lead to issues with race conditions. ----- - -Please see xref:configuration/files/files_locking_transactional.adoc[Transactional File Locking] -for how to correctly configure your environment for transactional file locking. - -== Background Jobs - ----- -We recommend to enable system cron as any other cron method has possible performance and reliability implications. ----- - -Further Information can be found in the docs article on xref:configuration/server/background_jobs_configuration.adoc[Background Jobs] - -== You are accessing this site via HTTP - ----- -You are accessing this site via HTTP. We strongly suggest you configure your server to require using HTTPS instead. ----- - -Please take this warning seriously; using HTTPS is a fundamental security measure. -You must configure your Web server to support it, and then there are some settings in the *Security* section of your ownCloud Admin page to enable. -The following pages describe how to enable HTTPS on the Apache webserver. - -* xref:installation/manual_installation/manual_installation.adoc#configure-the-web-server[Enable SSL on Apache] -* xref:configuration/server/harden_server.adoc#use-https[Use HTTPS] - -== The test with getenv("PATH") only returns an empty response - -Some environments are not passing a valid PATH variable to ownCloud. -The xref:installation/configuration_notes_and_tips.adoc#php-fpm[PHP FPM tips] provides the information about how to configure your environment. - -== The "Strict-Transport-Security" HTTP header is not configured - ----- -The `Strict-Transport-Security` HTTP header is not configured to least `15552000` seconds. -For enhanced security we recommend enabling HSTS as described in our security tips. ----- - -The HSTS header needs to be configured within your Web server by following the -xref:configuration/server/harden_server.adoc#enable-http-strict-transport-security[Enable HTTP Strict Transport Security] -documentation. - -== Your Web server is not yet set up properly to allow file synchronization - ----- -Your web server is not yet set up properly to allow file synchronization because the WebDAV interface seems to be broken. ----- - -At the ownCloud community forums a larger -{oc-central-url}/t/how-to-fix-caldav-carddav-webdav-problems/852[FAQ] -is maintained containing various information and debugging hints. - -== Outdated NSS / OpenSSL version - ----- -cURL is using an outdated OpenSSL version (OpenSSL/$version). Please -update your operating system or features such as installing and updating -apps via the ownCloud Marketplace or Federated Cloud Sharing will not -work reliably. ----- - ----- -cURL is using an outdated NSS version (NSS/$version). Please update -your operating system or features such as installing and updating apps -via the ownCloud Marketplace or Federated Cloud Sharing will not work -reliably. ----- - -There are known bugs in older OpenSSL and NSS versions leading to -misbehaviour in combination with remote hosts using SNI. A technology -used by most of the HTTPS websites. To ensure that ownCloud will work -properly you need to update OpenSSL to at least 1.0.2b or 1.0.1d. For -NSS the patch version depends on your distribution and an heuristic is -running the test which actually reproduces the bug. There are -distributions such as RHEL/CentOS which have this backport still -https://bugzilla.redhat.com/show_bug.cgi?id=1241172[pending]. - -== Your Web server is not set up properly to resolve /.well-known/caldav/ or /.well-known/carddav/ - -Both URLs need to be correctly redirected to the DAV endpoint of ownCloud. Please refer to -xref:configuration/general_topics/general_troubleshooting.adoc#service-discovery[Service Discovery] -for more info. - -== Some files have not passed the integrity check - -Please refer to the xref:configuration/general_topics/code_signing.adoc#fixing-invalid-code-integrity-messages[Fixing Invalid Code Integrity Messages] documentation how to debug this issue. - -== Your database does not run with "READ COMMITTED" transaction isolation level - ----- -Your database does not run with"READ COMMITTED" transaction isolation level. -This can cause problems when multiple actions are executed in parallel. ----- - -Please refer to -xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB with Binary Logging Enabled]) -how to configure your database for this requirement. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/thirdparty_php_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/thirdparty_php_configuration.adoc deleted file mode 100644 index 0dbd109..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/thirdparty_php_configuration.adoc +++ /dev/null @@ -1,25 +0,0 @@ -= Using Third Party PHP Components - -ownCloud uses some third party PHP components to provide some of its -functionality. These components are part of the software package and are -contained in the */3rdparty* folder. - -== Managing Third Party Parameters - -When using third party components, keep the following parameters in mind: - -* *3rdpartyroot* – Specifies the location of the 3rd-party folder. To -change the default location of this folder, you can use this parameter -to define the absolute file system path to the folder location. -* *3rdpartyurl* – Specifies the http web path to the 3rdpartyroot -folder, starting at the ownCloud web root. - -An example of what these parameters might look like is as follows: - -[source,php] ----- - OC::$SERVERROOT."/3rdparty", -"3rdpartyurl" => "/3rdparty", ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/ui-configuration.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/ui-configuration.adoc deleted file mode 100644 index ad2b655..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/ui-configuration.adoc +++ /dev/null @@ -1,40 +0,0 @@ -== UI Configuration -:toc: right - -== Introduction - -The web UI can be configured for optimal user experience. - -== Configuration Options - -=== Hide the Upload Estimation - -Note that this setting is available for ownCloud Classic only. - -When uploading a document, an upload estimation (progress bar) is shown like in the example below: - -image:configuration/server/ui-configuration/upload-progress-bar.png[Upload Progress Bar] - -This progress bar can be hidden with the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files hide_upload_estimation --value="yes" ----- - -To show the progress bar again, type one of the following commands: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files hide_upload_estimation --value="no" ----- - -or - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete files hide_upload_estimation ----- - -The current value can be queried with the `config:app:get` or the `config:list` command. For details see the -xref:configuration/server/occ_command.adoc#config-commands[occ Config Commands] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/server/virus-scanner-support.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/server/virus-scanner-support.adoc deleted file mode 100644 index 1b8622a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/server/virus-scanner-support.adoc +++ /dev/null @@ -1,667 +0,0 @@ -= Virus Scanner Support -:toc: right -:toclevels: 4 -:page-aliases: configuration/server/antivirus_configuration.adoc -:clamav-url: http://www.clamav.net/index.html -:icap-url: https://tools.ietf.org/html/rfc3507 -:c-icap-url: https://sourceforge.net/p/c-icap/wiki/configcicap/ -:kasperski-scanengine-url: https://support.kaspersky.com/ScanEngine/1.0/en-US/179682.htm -:kaspersky-icap-url: https://support.kaspersky.com/ScanEngine/1.0/en-US/179708.htm -:mcaffee-demo-url: https://www.skyhighsecurity.com/en-us/products/secure-web-gateway.html -:fortinetsandbox-url: https://www.fortinet.com/de/products/sandbox/fortisandbox - -:description: When sharing files, security is a key aspect. The ownCloud Anti-Virus extension helps by protecting against malicious software like trojans or viruses. - -== Introduction - -{description} - -You can get the {oc-marketplace-url}/apps/files_antivirus[Anti-Virus] extension from the marketplace. - -* When uploading, files are forwarded from the ownCloud server to a malware scanning engine before they are written to the storage. When a file is recognized as malicious, it can be logged and prevented from being uploaded to the server to ensure that files in ownCloud are free of malware. More sophisticated rules may be specified by the admin in the ownCloud Web interface menu:User Name[Settings > Admin > Security]. -* When downloading, the files are scanned again to prevent infections to spread, which were not known by the scanner at the time of the upload and therefore missed. - -== General Info - -Native Mode:: -Out of the box, the ownCloud Anti-Virus extension works with {clamav-url}[Clam AntiVirus (ClamAV)] as the directly supported virus scanner. It detects all forms of malware including trojans, viruses and worms and scans compressed files, executables, image files, PDF, as well as many other file types. The ownCloud Anti-Virus application relies on the underlying ClamAV virus scanning engine, to which the admin points ownCloud when configuring the application. The ClamAV virus definitions need to be kept up to date in order to provide effective protection. - -ICAP:: -Starting with Anti-Virus version 1.0.0, the app also offers an ICAP integration *only available with Enterprise installations*. Admins can integrate their favorite enterprise-grade antivirus scanners through the open standard {icap-url}[Internet Content Adaptation Protocol (ICAP)]. With this setup, ownCloud can delegate the scanning of uploaded files to another machine, the ICAP server. The ICAP server then checks them and either greenlights them or, if malicious code is found, treats the offending file(s) as specified in the settings and notifies the ownCloud server. ownCloud can then act accordingly and based on the settings made reject the upload. Offloading the anti-virus scans to another dedicated server can greatly improve performance compared to running the ClamAV virus scanner on the same machine as ownCloud. -+ -Starting with Anti-Virus version 1.1.0, additional scanners like the FortiSandbox and McAfee Web Gateway have been added as selectable ICAP scanners. - -Antivirus scanner modes:: -The following image shows the currently supported scanners including how they are connected. -+ -image::configuration/server/virus-scanner-support/av_modes.png[Antivirus Configuration Modes,width=500] - -Common notes:: -A file is parsed and an exit code returned, or an exit code is evaluated if no result is available to determine the response from the scan. In case of an infected file, the appropriate action is _always_ to delete the file. Though the setting can be made, the choice `delete` or `log` for the infected condition only applies to the special case of background scans. -+ -NOTE: The whole file is scanned when it is moved or saved to the final location. Individual chunks are *not* scanned. - -== When Infected Files are Found - -During an upload these actions are taken: - -* The upload is blocked. -* The event is logged in the ownCloud server log. -* The event is reported and/or logged by the client / Web UI. - -During a _background_ scan, the app can take one of two actions: - -* **Log Only**: Log the event. -* **Delete file**: Delete the detected file. - -Set btn:[When infected files were found during a background scan] to the value that suits your needs. - -== Install the ownCloud Anti-Virus App - -. The Anti-Virus app needs to be installed from the ownCloud Market (it's available in the _"Security"_ category) and then as admin enabled in ownCloud under menu:Settings[Admin > Apps]. -+ -image::configuration/server/virus-scanner-support/antivirus-app.png[Anti-Virus App,width=500] - -. To install the app via the occ command, execute: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} market:install files_antivirus ----- -+ -and enable it with the following occ command: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable files_antivirus ----- - -== Ways of Configuration - -=== Configure the Anti-Virus App Using GUI - -Navigate to menu:Settings[Admin > Security], where you'll find the "**Antivirus Configuration**" panel to configure the Anti-Virus app via the GUI. - -=== Configure the Anti-Virus App Using occ - -All of the configuration settings for the Anti-Virus app are configurable by passing the relevant key and value to the `occ config:app:set files_antivirus` command. For example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus \ - av_socket --value="/var/run/clamav/clamd.ctl" ----- - -To get a current option, run for example: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:get files_antivirus \ - av_socket ----- - -[caption=] -.Available configuration settings, availability is _av_mode_ dependent -[cols="23%,45%,15%",options="header"] -|=== -| Setting -| Description -| Default - -| `av_cmd_options` -| Extra command-line options (comma-separated) to pass to ClamAV. -| - -| `av_host` -| The host name or IP address of the antivirus server. -| - -| `av_infected_action` -| The action to take when infected files were found during a background scan. + -It can be set to `only_log` or `delete`. -| `only_log` - -| `av_max_file_size` -| The maximum file size limit; + -`-1` means no limit. -| `-1` - -| `av_mode` -a| The Anti-Virus binary operating mode. + -It can be set to one of the following options: - -* Native Mode -** `daemon`, ClamAV Daemon (TCP Socket) -** `socket`, ClamAV Daemon (Unix Socket) -** `executable`, ClamAV Executable -* ICAP -** `icap`, ClamAV & Kaspersky (ICAP) -** `fortinet`, Fortinet (ICAP) -** `mawgw`, MacAfee Webgateway / Skyhigh Secure Webgateway (ICAP) -| `executable` - -| `av_request_service` -a| ICAP request service, dependent on the ICAP mode - -* `avscan` for ClamAV, -* `req` for Kaspersky ScanEngine, -* `respmod` for Fortinet and McAfee Webgateway/ Skyhigh Secure Webgateway. -| - -| `av_response_header` -a| ICAP response header holding the virus information, -dependent on the ICAP mode - -* `X-Virus-ID` or + -`X-Infection-Found` for ClamAV and Kaspersky ScanEngine, -* `X-Virus-Name` for McAfee Webgateway / Skyhigh Secure Webgateway, -* `X-Virus-ID` for Fortinet. -| - -| `av_path` -| The path to the `clamscan` executable. -| `/usr/bin/clamscan` - -| `av_port` -| The port number of the antivirus server. + -Allowed values are `1 - 65535`. -| - -| `av_scan_background` -| Should scans run in the background? -| `true` - -| `av_socket` -| The name of ClamAV's UNIX socket file. -| `/var/run/clamav/clamd.ctl` - -| `av_stream_max_length` -a| The maximum stream length that ClamAV will accept in bytes ^(*)^. -| `26214400` -|=== - -(*) ... The `Stream Length` value sets the number of bytes to read in one pass and defaults to 26214400 bytes (twenty-six megabytes). This value should be no larger than the PHP `memory_limit` settings or physical memory if `memory_limit` is set to -1 (no limit). - -== ClamAV In Native Mode - -=== ClamAV Feature List - -* Operates on all major operating systems, including _Windows_, _Linux_, and _macOS_. -* Detects all forms of malware including _Trojan horses_, _viruses_, and _worms_. -* Scans _compressed files_, _executables_, _image files_, _Flash_, _PDF_, as well as many others. - -What's more, ClamAV's Freshclam daemon automatically updates its malware signature database at scheduled intervals. - -=== ClamAV Integration Into ownCloud - -ownCloud integrates with ClamAV natively in several ways, see xref:configuration-modes[Configuration Modes]. - -[NOTE] -==== -* Scanner exit status rules are used to handle errors when ClamAV is run in CLI mode. -* Scanner output rules are used in daemon/socket mode only. -==== - -=== Scanning Notes for ClamAV - -. Files are checked when they are uploaded or updated and before they are downloaded. -. ownCloud does not maintain a cache of previously scanned files. -. If the app is either not configured or is misconfigured, then it rejects file uploads. -. If ClamAV is unavailable, then the app rejects file uploads. -. A file size limit applies both to background scans and to file uploads. -. After installing ClamAV and the related tools, you will have two configuration files: `/etc/freshclam.conf` and `/etc/clamd.d/scan.conf`. -. We recommend that you enable verbose logging in both `clamd.conf` and `freshclam.conf` initially, to verify correct operation of both. - -=== Installing ClamAV - -Install ClamAV on Ubuntu with the following command: - -[source,bash] ----- -sudo apt install clamav clamav-daemon ----- - -This automatically creates the default configuration files and launches the `clamd` and `freshclam` daemons. - -==== Enabling and Running ClamAV - -Enable and start the `clamd` service with following commands. - -[source,bash] ----- -sudo systemctl daemon-reload -sudo systemctl enable clamav-daemon.service -sudo systemctl start clamav-daemon.service ----- - -When successful, an output similar to the following should appear on the terminal: - -[source,plainetxt] ----- -Synchronizing state of clamav-daemon.service with SysV service script with -/lib/systemd/systemd-sysv-install. -Executing: /lib/systemd/systemd-sysv-install enable clamav-daemon ----- - -==== ClamAV Virus Database Updates - -. You can manually start the updating process with this command: -+ -[source,bash] ----- -sudo freshclam ----- -+ -You should update manually at least once before using ClamAV within ownCloud. The initial update can take several minutes. In case of persisting issues running `freshclam`, you can gently end the process with the following command: -+ -[source,bash] ----- -sudo pkill -15 -x freshclam ----- -+ -and retry manually updating again. - -. To automate the update process, run this cron entry for example. -+ -[source,plaintext] ----- -# m h dom mon dow command -47 * * * * /usr/bin/freshclam --quiet ----- -+ -NOTE: Avoid any multiples of 10 to better distribute the load on the ClamAV virus pattern servers. This can reduce the load on the servers and therefore update times. - -=== Configuring ClamAV within ownCloud - -IMPORTANT: If the app is enabled but either not or incorrectly configured, it will *strictly reject all uploads* for the whole instance! - -ClamAV can be configured in the following two ways: - -. xref:configure-the-anti-virus-app-using-gui[By using the Antivirus Configuration panel] -. xref:configure-the-anti-virus-app-using-occ[By using the `occ config:app` command set.] - -==== Change Log Level Temporarily - -Once ClamAV is installed, select menu:Settings[General (Admin)] and, in the "*Log*" section, temporarily set btn:[Log level] to "_Everything (fatal issues, errors, warnings, info, debug)_". - -image::configuration/server/virus-scanner-support/antivirus-logging.png[Setting loglevels] - -==== Configuration Modes - -ClamAV runs in one of three modes: - -* xref:daemon-socket-same-server[ClamAV Daemon (Unix Socket)] -* xref:daemon-different-server[ClamAV Daemon (TCP Socket)] -* xref:executable[ClamAV Executable] - -[TIP] -==== -In both daemon modes, background scans are enabled by default. If you want to disable them, run the command: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus av_scan_background --value 'false' ----- -==== - -[[daemon-socket-same-server]] -===== ClamAV Daemon (Unix Socket) - -In _ClamAV Daemon (Unix Socket)_ mode, ClamAV runs in the background on the *same* server as the ownCloud installation, or the socket can be made available via a share mount. When there is no activity, `clamd` places a minimal load on your system. Consider that high CPU usage can occur when users upload large volumes of files. - -IMPORTANT: You must run `freshclam` at least once for ClamAV to generate the socket. - -image::configuration/server/virus-scanner-support/clamav_daemon_socket.png[ClamAV Deamon TCP,width=500] - -. Set btn:[Mode] to "*ClamAV Daemon (Unix Socket)*". ownCloud should detect your `clamd` socket and fill in the "*Socket*" field. This is the `LocalSocket` option in `clamd.conf`. -+ -You can run `ss` (a utility to investigate sockets) to verify it, as in the example below: -+ -[source,bash] ----- -sudo ss -a | grep -iq clamav && echo "ClamAV is running" ----- -+ -[TIP] -==== -If you don't have `ss` installed, you may have `netstat` installed. If so, you can run the following to check if ClamAV is running: -[source,bash] ----- -netstat -a | grep -q clam && echo "ClamAV is running" ----- -==== - -. When infected files were found during a background scan, you have the choice of either: -+ -* Logging any alerts without deleting the files -* Immediately deleting infected files - -[[daemon-different-server]] -===== ClamAV Daemon (TCP Socket) - -In _ClamAV Daemon (TCP Socket)_ mode, ClamAV can run on a different server. This is a good option to reduce load on the ownCloud servers when high network bandwidth is available and many concurrent uploads happen. - -image::configuration/server/virus-scanner-support/clamav_daemon_tcp.png[ClamAV Deamon TCP,width=500] - -. Set btn:[Mode] to "*ClamAV Daemon (TCP Socket)*". -. Set btn:[Host] to the host name or IP address of the remote server running ClamAV, and set btn:[Port] to the server's port number. -+ -TIP: The port number is the value of `TCPSocket` in `/etc/clamav/clamd.conf`. - -[[executable]] -===== ClamAV Executable - -In _ClamAV Executable_ mode, ClamAV runs on the *same* server as the ownCloud installation, with the `clamscan` command running only when a file is uploaded. - -TIP: `clamscan` can respond slower and may not always be reliable for on-demand usage; it is better to use one of the daemon modes. - -image::configuration/server/virus-scanner-support/clamav_executable.png[ClamAV Executable,width=500] - -The image shows a command line option `--allmatch=yes` (continue scanning within the file after finding a match) which is not necessary to be set and just used here for demonstration purposes of the field. - -NOTE: Starting with ownCloud Anti-Virus version 1.0.0, the path to `clamscan` and the command line options are set via a config.php entry and are read-only in the user interface. Refer to the xref:configuration/server/config_apps_sample_php_parameters.adoc[config.php parameters for apps] for more details. - -NOTE: If you had configured the path and command line options before via the user interface, the values are being migrated from the database to config.php automatically. Check the settings in config.php for their presence after upgrading. - -. Set btn:[Mode] to "*ClamAV Executable*". -. Set btn:[Path to clamscan] to the path of `clamscan`, which is the interactive ClamAV scanning command, on your server. To find the exact path, run -+ -[source,bash] ----- -which clamscan ----- - -==== Set Back Log Level - -When you are satisfied with how ClamAV is operating, you might want to go back and change all of your logging to less verbose levels. - -==== Configuration Warnings - -The Anti-Virus App shows one of three warnings if it is misconfigured or ClamAV is not available. You can see an example of all three below. - -image::configuration/server/virus-scanner-support/anti-virus-message-host-connection-problem.png[Configuration error message: 'Antivirus app is misconfigured or antivirus inaccessible. Could not connect to host 'localhost' on port 999'.] - -image::configuration/server/virus-scanner-support/anti-virus-message-misconfiguration-problem.png[Configuration error message: 'Antivirus app is misconfigured or antivirus inaccessible. The antivirus executable could not be found at path '/usr/bin/clamsfcan''.] - -image::configuration/server/virus-scanner-support/anti-virus-message-socket-connection-problem.png[Configuration error message: 'Antivirus app is misconfigured or antivirus inaccessible. Could not connect to socket ´/var/run/clamav/cslamd-socket´: No such file or directory (code 2)'.] - -== ICAP - -{icap-url}[ICAP] is an open standard supported by many antivirus products. With the release of the _Anti-Virus_ app 1.0.0, other virus scanners beside ClamAV can be used via ICAP if you are running it on an ownCloud Enterprise Edition. - -Currently the only tested and supported virus scanners are: - -* ClamAV, -* Kaspersky ScanEngine, -* FortiSandbox and -* McAfee Web Gateway / Skyhigh Secure Web Gateway. - -Due to the wide distribution of the ICAP standard, more products can be implemented on request. The use of ICAP requires an enterprise license. The functionality can be tested without a license with a grace period of 24 hours. - -NOTE: Either saving a setting using ICAP via the GUI or using the occ command and set the `av_mode` to one of the ICAP modes triggers a grace period of 24 hours if you don't have an Enterprise license but want to test ICAP. - -Depending on your ICAP server, select one of the following example configurations. - -* xref:clamav-kaspersky-icap[ClamAV & Kaspersky (ICAP)] -* xref:fortinet-icap[Fortinet (ICAP)] -* xref:mcafee-web-gateway-skyhigh-secure-web-gateway-icap[McAfee Web Gateway / Skyhigh Secure Web Gateway (ICAP)] - -=== General ICAP Settings Using occ - -==== Common Settings - -Use the following occ commands to set configurations based on your environment: - -. Set the IP address of your anti-virus server: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus \ - av_host --value="172.17.0.3" ----- - -. Specify the port of the anti-virus server: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus \ - av_port --value="1344" ----- - -. Enable background scans: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus \ - av_scan_background --value="true" ----- - -. Specify what to do with the offending file: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus \ - av_infected_action --value="delete" ----- -+ -Possible values are `delete` and `only_log`. -+ -Note that this setting is only used when `av_scan_background` is set to `true`. - -==== Mode Dependent Settings - -The following settings are just examples and must be adjusted for the scanner you use. For possible values see xref:configure-the-anti-virus-app-using-occ[Configure the Anti-Virus App Using occ] - -. Set the ICAP mode: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus \ - av_mode --value="icap" ----- - -. Set the request service: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus \ - av_request_service --value="avscan" ----- - -. Set the response header: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_antivirus \ - av_response_header --value="X-Infection-Found" ----- - -=== ClamAV & Kaspersky (ICAP) - -If you decide to use ClamAV, you must first install and configure {c-icap-url}[c-icap on sourceforge]. With regard to selecting ClamAV in their configuration, see the section: https://sourceforge.net/p/c-icap/wiki/ModulesConfiguration/[ModulesConfiguration]. - -. Install ClamAV based on the instructions at the beginning of this document and `c-icap` as referenced above. - -. Select btn:[ClamAV & Kaspersky (ICAP)] from the drop-down menu in the Anti-Virus app: -+ -image::configuration/server/virus-scanner-support/icap_clamav.png[ClamAV & Kasperski (ICAP)],width=500] - -NOTE: The older versions of Kaspersky’s KAV did not send back the virus/infection name in an ICAP header. Starting with KAV v2.0.0, the header to transport the virus can be configured. Default: No header is sent. For more configuration details see {kaspersky-icap-url}[Using Kaspersky Scan Engine in ICAP mode]. - -// note that the original document regarding "VirusNameICAPHeader" https://support.kaspersky.com/ScanEngine/1.0/en-US/201214.htm is not available anymore (404, no cache entry) and no appropriate replacement has been found. the link above is the best possible alternative. - -=== McAfee Web Gateway / Skyhigh Secure Web Gateway (ICAP) - -Follow the procedure below to configure ownCloud for the McAfee Web Gateway 10.x and higher in ICAP Mode. - -. Install McAfee Web Gateway based on their instructions. - -. Select btn:[McAfee Web Gateway / Skyhigh Secure Web Gateway (ICAP)] from the drop-down menu in the Anti-Virus app. -+ -image::configuration/server/virus-scanner-support/icap_mcafee.png[McAfee Web Gateway / Skyhigh Secure Web Gateway (ICAP)],width=500] - -NOTE: McAfee provides demo versions with limited runtime for evaluation purposes. Have a look at the {mcaffee-demo-url}[McAfee Web page] for the Web Gateway. - -=== Fortinet (ICAP) - -. Install FortiSandbox based on their instructions. - -. Select btn:[Fortinet] from the drop-down menu in the Anti-Virus app. -+ -image::configuration/server/virus-scanner-support/icap_mcafee.png[McAfee Web Gateway / Skyhigh Secure Web Gateway (ICAP)],width=500] - -NOTE: Fortinet provides some demo versions of the FortiSandbox. Have a look at their {fortinetsandbox-url}[product page] for more information. - -== Response Rule Configuration (Advanced) - -CAUTION: Do not change the rules hidden under btn:[Advanced] unless you know exactly what you're doing. The defaults should work best. If you have special requirements, contact us at consulting@owncloud.com. - -ownCloud provides the ability to customize how it reacts to the response given by an antivirus scan. -To do so, under menu:Admin[Security (Admin)] click btn:[Advanced], which you can see in the screenshot below, you can view and change the existing rules. -You can also add new ones. - -image::configuration/server/virus-scanner-support/anti-virus-configuration-rules.png[image] - -Rules can match on either an exit status (e.g., 0, 1, or 40) or a pattern in the string returned from ClamAV (e.g., `/.\*: (.\*) FOUND$/`). - -Here are some points to bear in mind about rules: - -* Scanner exit status rules are used to handle errors when ClamAV is run in CLI mode, while -* Scanner output rules are used in daemon/socket mode. -* Daemon output is parsed by regexp. -* In case there are no matching rules, the status is: `Unknown`, and a warning will be logged. - -=== Default Rule Set - -[caption=] -.The default rule set for ClamAV is populated automatically with the following rules: -[cols="20%,45%,15%",options="header",] -|=== -| Exit Status or Signature -| Description -| Marks File As - -| 0 -| -| Clean - -| 1 -| -| Infected - -| 40 -| Unknown option passed -| Unchecked - -| 50 -| Database initialization error -| Unchecked - -| 52 -| Not supported file type -| Unchecked - -| 53 -| Can't open directory -| Unchecked - -| 54 -| Can't open file -| Unchecked - -| 55 -| Error reading file -| Unchecked - -| 56 -| Can't stat input file -| Unchecked - -| 57 -| Can't get absolute path name of current working directory -| Unchecked - -| 58 -| I/O error -| Unchecked - -| 62 -| Can't initialize logger -| Unchecked - -| 63 -| Can't create temporary files/directories -| Unchecked - -| 64 -| Can't write to temporary directory -| Unchecked - -| 70 -| Can't allocate memory (calloc) -| Unchecked - -| 71 -| Can't allocate memory (malloc) -| Unchecked - -| /.*: OK$/ -| -| Clean - -| /.\*: (.*) FOUND$/ -| -| Infected - -| /.\*: (.*) ERROR$/ -| -| Unchecked -|=== - -The rules are always checked in the following order: - -. Infected -. Error -. Clean - -In case there are no matching rules, the status would be `Unknown` and a warning would be logged. - -=== Update an Existing Rule - -. You can change the rules to either match an exit status or the scanner's output. -** To match on an exit status, change the -* btn:[Match by] dropdown list to btn:[Scanner exit status] and -* in the "**Scanner exit status or signature to search**" field, add the status code to match on. -** To match on the scanner's output, change the -* btn:[Match by] dropdown list to btn:[Scanner output] and -* in the btn:[Scanner exit status or signature to search] field, add the regular expression to match against the scanner's output. - -. Then, while not mandatory, add a description of what the status or scan output means. After that, set what ownCloud should do when the exit status or regular expression you set matches the value returned by ClamAV. To do so, change the value of the dropdown in the btn:[Mark as] column. -+ -[caption=] -.The dropdown supports the following three options: -[width="50%",cols="20%,60%",options="header",] -|=== -| Option -| Description - -| Clean -| The file is clean and contains no viruses - -| Infected -| The file contains a virus - -| Unchecked -| No action should be taken -|=== - -With all these changes made, click the [pass:[✓]] on the left-hand side of the btn:[Match by] column, to confirm the change to the rule. - -=== Add A New Rule - -To add a new rule, click the button marked btn:[Add a rule] at the bottom left of the rules table. -Then follow the process outlined in xref:update-an-existing-rule[Update An Existing Rule]. - -=== Delete An Existing Rule - -To delete an existing rule, click the btn:[rubbish bin] icon on the far right-hand side of the rule that you want to delete. - diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/custom_groups_app.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/custom_groups_app.adoc deleted file mode 100644 index 4d723e3..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/custom_groups_app.adoc +++ /dev/null @@ -1,57 +0,0 @@ -= Custom Groups App -:toc: right - -:description: With Custom Groups, users are able to define their own groups and manage contributing users themselves. - -== Introduction - -{description} When the xref:configuration/user/guests_app.adoc[Guest App] has been enabled, you can also add external guests to custom groups. - -== Installation - -Install and enable the {oc-marketplace-url}/apps/customgroups[Custom Groups] app if not already installed with your bundle. The Custom Groups app requires the email settings to be configured in your ownCloud setup, because you need to be able to invite the group members by email. - -== Configuration - -Check your Custom Groups app's configuration in menu:Settings[Admin > Sharing > Custom Groups]. There you can set the following items: - -image::configuration/user/custom_groups/custom_groups.png[] - -=== Overriding Default Behavior - -Depending on your custom groups and ownCloud's global settings, configured by the ownCloud admin, the Custom Groups app may behave differently depending on settings made via occ commands. For details see xref:configuration/server/occ_command.adoc#custom-groups[occ for Custom Groups]. Note that some settings shown in the examples below can also be set via `config/config.php`. For best practice, use the occ command where possible. - -==== Preventing Administrators from Administering Custom Groups - -* Creating or renaming a custom group, using an existing name of another custom group can be allowed or not depending on administrative settings. - -* Custom group creation can be limited to ownCloud **group admins**. - -* Disable administration of custom groups by ownCloud administrators: -+ -[source,php] ----- -'customgroups.disallow-admin-access-all' => true, ----- - -==== Hide Custom Groups App Based on Group Membership - -The app can be hidden from a user's personal settings page if the user belongs to one or more disallowed groups. -To specify the disallowed groups, list them against the `customgroups.disallowed-groups` key in `config/config.php` as in the following example. - -[source,php] ----- -// Hide the Custom Groups app for users in the -// 'no_guest_app_users' and 'project5' group. -'customgroups.disallowed-groups' => ['no_guest_app_users', 'project5'], ----- - -==== Set Custom Group Admins - -Assigning custom group admins can only be done via the browser. In case the group admin has left the company and you need to set a different one, you temporarily must allow the xref:preventing-administrators-from-administering-custom-groups[ownCloud instance admins] access to groups if disallowed before. Then set one or more new group admins and change the instance admin setting back. - -== User Settings - -See the following image as example of user related settings and the https://doc.owncloud.com/webui/next/classic_ui/personal_settings/custom_groups.html[Custom Groups] section in the user manual for details: - -image::configuration/user/custom_groups/user_settings_custom_groups.png[] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/guests_app.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/guests_app.adoc deleted file mode 100644 index 61d22f7..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/guests_app.adoc +++ /dev/null @@ -1,32 +0,0 @@ -= Guests App - -== Introduction - -Share with external users conveniently just by entering an email address in the sharing dialog. Recipients receive an email containing an activation link. They can log in using their email address as user name and the password they chose during activation. Guests may even use the ownCloud desktop clients and mobile apps to connect to ownCloud and work on shared contents. - -NOTE: Guest users do not have storage space and can only work on content that is shared with them. - -// The video is outdated, but we keep this for reference in case there will be an update -// Have a look at our informational YouTube video below, for an introduction to the Guests app. - -// video::L42PBHgqKVI[youtube,width=640,height=360] - -== Installation - -Install and enable the {oc-marketplace-url}/apps/guests[Guests] app if not already installed with your bundle. The Guests app requires the email settings to be configured in your ownCloud setup, because you need to be able to invite your guests by email. - -== Configuration - -Check your Guests app's configuration in menu:Settings[Admin > Sharing]. There you can change the Guest's **group name** and add to or exclude apps from the app **whitelist** of the Guests app. Guests cannot access apps that are not on that list. - -With a blocklist, an admin can block domains for guest invitations: - -* Up to Guests 0.12.1, the blocklist entries were a suffix match. An entry like `example.com` would also block `user@otherexample.com` -- this was considered an error and admins relying on this feature must review their blocklists when upgrading to Guests 0.12.2. - -* Starting with Guests 0.12.2, the entries in the blocklist are exact matches. That means, that an entry `example.com` blocks `user@example.com`, but `user@mail.example.com` is *not* blocked. Admins are advised to list all possible subdomains explicitly. - -image::configuration/user/guest_app/guest_app_settings.png[width=470] - -== Troubleshooting - -If for some reason you don't see all the buttons, try a different browser to exclude a possible script or adblocking add-on as a cause. If for example you as a guest user cannot open a PDF document via your ownCloud but you can download it - check the **whitelist** in the configuration settings described above. You have to explicitly specify that the guest users can access the required app. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/login_policies.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/login_policies.adoc deleted file mode 100644 index 98db064..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/login_policies.adoc +++ /dev/null @@ -1,64 +0,0 @@ -= Login Policies -:toc: right - -:description: ownCloud provides login policies that will allow or reject users from login. With the group login policy, admins can allow or reject groups of users to access ownCloud via specific login mechanisms. - -== Introduction - -{description} - -Login policies will emit a `failed login` event if the user isn't allowed to log in. - -== Use Cases - -Login policies can be used to restrict members of particular groups to use only particular login types. This is especially true for guest users as they do not have an ownCloud account and cannot be validated via OpenID Connect but can log in using their email and password. - -For example, a desired rule could be that only the groups `guests` and `admin` can log in to the instance via username + password, while the rest of the users must login through other mechanisms such as OpenID Connect. - -== Configuration - -Login policies are handled via groups that users are members of and maintained via the config.php file. See the xref:configuration/server/config_sample_php_parameters.adoc#order-of-login-policies[Order of login policies] for details. - -If no login policy is activated in the `loginPolicy.order` list, ownCloud will work normally. Only the policies in the `loginPolicy.order` list are used. - -To enable login policies, use the following example: - -[source,php] ----- -'loginPolicy.order' => ['OC\Authentication\LoginPolicies\GroupLoginPolicy'], ----- - -After enabling the `loginPolicy.order`, the configuration of the `groupLoginPolicy` can be made. The key definition below must be set according to the needs and the description in xref:configuration/server/config_sample_php_parameters.adoc#configuration-of-the-group-login-policy[Configuration of the Group Login Policy]: - -[source,php] ----- -'loginPolicy.groupLoginPolicy.forbidMap' => [ - '' => [ - 'allowOnly' => ['', ......, ''], - 'reject' => ['', ........, ''], - ], -], ----- - -The following example gives an idea of how to configure the `Group Login Policy`: - -* Users belonging to the admin group won't be able to access via token (app password), while the rest of the users can. -* Only users from group1 and group2 are allowed to access through username + password, and users from group3 will be rejected. -* If a user is a member of both an allowOnly group and a reject group, rejection will take priority. This means that even if user1 is a member of group1 he won't be able to access if he's also a member of group3. -* Only members of group4 can log in using OIDC. - -[source,php] ----- -loginPolicy.groupLoginPolicy.forbidMap => [ - 'password' => [ - 'allowOnly' => ['group1, group2'], - 'reject' => ['group3'], - ], - 'token' => [ - 'reject' => ['admin'], - ], - 'OCA\OpenIdConnect\OpenIdConnectAuthModule' => [ - 'allowOnly' => ['group4'], - ], -] ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/kopano-setup.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/kopano-setup.adoc deleted file mode 100644 index a2aeae9..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/kopano-setup.adoc +++ /dev/null @@ -1,90 +0,0 @@ -= Example Setup Using Kopano Konnect -:toc: right -:toclevels: 2 -:openid-connect-frontchannel-logout-url: https://openid.net/specs/openid-connect-frontchannel-1_0.html -:konnect-url: https://github.com/Kopano-dev/konnect -:konnect-docs-url: https://github.com/kopano-dev/konnect#running-konnect -:konnect-webserver-url: https://documentation.kopano.io/kopanocore_administrator_manual/configure_kc_components.html#configure-a-webserver-for-konnect - -== Introduction - -Kopano Konnect is an OpenID Connect provider (IdP) that directly integrates a Web login and consent form. It brings support for both OpenID Connect (OIDC) and Open Authentication (OAuth 2.0). In addition to the easier integration with third-party applications, Kopano Konnect will also provide the authentication part for the Kopano RestAPI and clients consuming it. - -== Setup and Configuration - -The sections below will explain these areas and provide configuration examples using {konnect-url}[Kopano Konnect] as the external identity provider. - -For the configuration examples, let's assume we have: - -- ownCloud Classic available as `+https://cloud.example.com+` -- Kopano Konnect available as `+https://idp.example.com+` - -=== Set Up and Configure Kopano - -To get your identity provider running and ready to be used with ownCloud, you have to obtain Kopano Konnect and run it with a set of configuration values which can be provided as environment variables. See the {konnect-docs-url}[Kopano Konnect documentation] for details. - -Specifically, you have to: - -- Provide basic configuration. -- Set up a reverse proxy to expose the routes required to connect to Kopano Konnect. You'll find instructions in the {konnect-webserver-url}[Kopano Konnect documentation]. -- Register the ownCloud clients. - -TIP: Kopano Konnect can be set up via Docker. Images are available on Docker Hub (`kopano/konnectd`). - -=== Configure ownCloud Classic - -To set up ownCloud Classic to work with OpenID Connect, you have to: - -1. Install the {oc-marketplace-url}/apps/openidconnect[OpenID Connect App] -2. Configure `config.php` -3. Set up service discovery - -TIP: It is recommended to first figure out all configurations on a test system and to bring it to the production system once it's proven to work. Enabling the OpenID Connect app on the production system should be the last step in this process as it will then advertise OpenID Connect to all clients. - -==== List of OpenID Connect config.php Parameters - -Follow this link to read more about the -xref:configuration/server/config_apps_sample_php_parameters.adoc#app-openid-connect-oidc[OIDC config.php parameters] available to configure OpenID Connect on ownCloud Classic. - -==== Example config.php - -An example snippet that can be added to `config.php` is shown below. - -[source,php] ----- -'openid-connect' => [ - 'provider-url' => 'https://idp.example.com', - 'client-id' => '', - 'client-secret' => '', - 'loginButtonName' => 'Kopano', - 'autoRedirectOnLoginPage' => false, - // change this to 'email' if necessary (see identity provider configuration) - 'mode' => 'userid', - // change this to suit your environment (see identity provider configuration) - 'search-attribute' => 'preferred_username' -], ----- - -=== Register ownCloud Clients - -To allow the ownCloud clients (Web/Desktop/Android/iOS) to interact with the identity provider, you have to register them as clients. In the case of Kopano Konnect, you can do this using Konnect's `identifier-registration.yaml`. The default values for the regular ownCloud clients are shown below. Other environments might require a different set of values. - -[TIP] -==== -* When registering ownCloud as an OpenID Client, use the following redirect URL: -+ -[source,url] ----- -https://cloud.example.com/index.php/apps/openidconnect/redirect ----- -* If {openid-connect-frontchannel-logout-url}[OpenID Connect Front-Channel Logout 1.0] is supported, enter the following as the logout URL within the client registration of the OpenID Provider: -+ -[source,url] ----- -https://cloud.example.com/index.php/apps/openidconnect/logout ----- -==== - -=== Client IDs, Secrets and Redirect URIs - -Use the data provided in the xref:configuration/user/oidc/oidc.adoc#client-ids-secrets-and-redirect-uris[ownCloud Desktop and Mobile Clients] section. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/ms-azure-setup.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/ms-azure-setup.adoc deleted file mode 100644 index 58aaf3a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/ms-azure-setup.adoc +++ /dev/null @@ -1,154 +0,0 @@ -= Example Setup Using Microsoft Azure -:toc: right -:toclevels: 2 -:ms-azure-ad: Microsoft Azure Active Directory (Azure AD) -:login-azure-url: https://portal.azure.com/#home -:openid-connect-frontchannel-logout-url: https://openid.net/specs/openid-connect-frontchannel-1_0.html -:ms-configure-openid-settings-url: https://docs.microsoft.com/en-us/powerapps/maker/portals/configure/configure-openid-settings -:ms-ad-redir-url: https://docs.microsoft.com/en-us/azure/active-directory/develop/reply-url#prefer-127001-over-localhost - -== Introduction - -{ms-azure-ad} is Microsoft’s multi-tenant cloud-based directory and identity management service. This document describes how to integrate Microsoft Azure Active Directory (Azure AD) as an identity provider (IdP) by configuring OpenID Connect (OIDC) in both Single Sign‑On and Azure AD. - -== Setup and Configuration - -The sections below will explain these areas and provide configuration examples using {ms-azure-ad} as the external Identity Provider. - -=== Configure Microsoft Azure AD - -Follow these steps to configure Microsoft Azure AD for use with OpenID Connect (OIDC): - -. Login to {login-azure-url}[Azure]. -+ -image:configuration/user/oidc/ms-azure-ad/login-with-ms-azure.png[width=200] - -. Go to menu:Manage Azure Active Directory[]. -+ -image:configuration/user/oidc/ms-azure-ad/select-manag-azure-ad.png[width=500] - -. Then go to menu:Properties[Tenant ID] and note your [#tenant-id]#`tenant ID`# for later use. -+ -image:configuration/user/oidc/ms-azure-ad/portal-tenant-id-ms-azure-ad.png[width=400] - -. Then go to menu:App registrations[New registration]. -+ -image:configuration/user/oidc/ms-azure-ad/new-registration-ms-azure-ad.png[width=500] - -. Provide all required information. -+ -image:configuration/user/oidc/ms-azure-ad/provide-required-information-ms-azure-ad.png[width=400] - -. Go to menu:Authentication[Add a platform] and select btn:[Web] in Configure Platforms. -+ -image:configuration/user/oidc/ms-azure-ad/setup-web-application-ms-azure-ad.png[width=600] - -. Go to menu:Authentication[Configure Web > Redirect URI] and setup your btn:[Redirect URI]. -+ -image:configuration/user/oidc/ms-azure-ad/setup-redirect-url-ms-azure-ad.png[width=600] - -. Go to menu:Certificates & secrets[Add a client secret] and setup the [#client-secret]#`client secret`# for your app. -+ -image:configuration/user/oidc/ms-azure-ad/setup-client-secret-ms-azure-ad.png[width=500] - -. Go to menu:Token configuration[Add optional claim] and setup the claims. -+ -image:configuration/user/oidc/ms-azure-ad/setup-claims-ms-azure-ad.png[width=500] - -. Go to menu:API permissions[Configured permissions > Add a permission] and add delegated permissions. -+ -image:configuration/user/oidc/ms-azure-ad/graph-permission-ms-azure-ad.png[width=600] - -. On the same page, do not forget to set menu:Grant admin consent[] to all permissions. -+ -image:configuration/user/oidc/ms-azure-ad/admin-consent-ms-azure-ad.png[width=600] - -. Go to menu:Expose an API[Set the App ID URI] and set the btn:[Application ID URI]. -+ -image:configuration/user/oidc/ms-azure-ad/app-id-uri-ms-azure-ad.png[width=600] - -. Then on the same page: -.. menu:Add a scope[Scope name] give the scope a meaningful name like *owncloud* and -.. menu:Add a scope[Who can consent] allow *Admins and users* to consent. You will see the full api [#api-scope]#`scope name`# below your entered scope name. -+ -image:configuration/user/oidc/ms-azure-ad/scope-consent-ms-azure-ad.png[width=600] - -. You get the [#client-id]#`CLIENT-ID`# after you have completed the Microsoft Azure setup process. On the following screen, you find an overview of most settings made. You can get there by clicking on menu:Overview[]. -+ -image:configuration/user/oidc/ms-azure-ad/overview-screen-ms-azure.png[width=500] - -=== Microsoft Azure AD and RedirectURI - -When it comes to use `127.0.0.1` instead of `localhost` as Redirect URI, the task is not straight forward. Microsoft has an own documentation for this describing a workaround, see {ms-ad-redir-url}[Prefer 127.0.0.1 over localhost]. In summary, you have to select in your app menu:Manifest[Manage], then search for `replyUrlsWithType` and either add a new entry with `127.0.0.1` or modify an existing one. - -image:configuration/user/oidc/ms-azure-ad/ms-azure-manifest.png[width=500] - -=== Configure ownCloud Classic - -To set up ownCloud Classic to work with OpenID Connect, you have to: - -1. Install the {oc-marketplace-url}/apps/openidconnect[OpenID Connect App]. -2. Configure `config.php`. -3. Set up service discovery. - -TIP: It is recommended to first figure out all configurations on a test system and to bring it to the production system once it's proven to work. Enabling the OpenID Connect App on the production system should be the last step in this process as it will then advertise OpenID Connect to all clients. - -==== List of OpenID Connect config.php Parameters - -Follow this link to read more about the -xref:configuration/server/config_apps_sample_php_parameters.adoc#app-openid-connect-oidc[OIDC config.php parameters] available to configure OpenID Connect on ownCloud Classic. - -==== Example config.php Setup - -An example snippet that can be added to `config.php` is shown below. You need to add both config values as listed below. The example expects that login users have already been created in ownCloud. - -Use these links to see the corresponding configuration section for: - -* xref:tenant-id[YOUR-DIRECTORY-TENANT-ID] -* xref:client-secret[YOUR-CLIENT-SECRET] -* xref:api-scope[YOUR-APPLICATION-ID-SCOPE-URI/owncloud] -* xref:client-id[YOUR-CLIENT-ID] - -[source,php] ----- -'http.cookie.samesite' => 'None', - -'openid-connect' => [ - 'auto-provision' => ['enabled' => false], - 'provider-url' => 'https://login.microsoftonline.com/YOUR-DIRECTORY-TENANT-ID/v2.0/', - 'client-id' => 'YOUR-CLIENT-ID', - 'client-secret' => 'YOUR-CLIENT-SECRET', - 'loginButtonName' => 'Azure AD', - 'autoRedirectOnLoginPage' => false, - 'scopes' => [ - 'openid', - 'api://YOUR-APPLICATION-ID-SCOPE-URI/owncloud', - 'profile', 'email', 'offline_access', - ], - 'mode' => 'email', - 'search-attribute' => 'unique_name', - 'use-access-token-payload-for-user-info' => true, -], ----- - -If you want to let ownCloud create users which are not present during a OIDC authentication, replace + -`'auto-provision' => ['enabled' => false],` with: - -[source,php] ----- - 'auto-provision' => [ - 'enabled' => true, - 'email-claim' => 'email', - 'display-name-claim' => 'name', - ], ----- - -=== Use oAuth2 authentication for ownCloud Desktop and Mobile Clients - -To allow the ownCloud clients (ownCloud Web, Desktop, Android and iOS) to interact with the ownCloud Classic server, you have to install and enable the oAuth2 app. Please see the xref:configuration/server/security/oauth2.adoc[Open Authentication (OAuth2)] for more details. In this setup, your ownCloud Clients will work without extra hassles, but please be advised that the ownCloud Classic server is acting as identity provider for the clients and you will not be able to delete those clients directly from your identity management solution. - -=== Register ownCloud Desktop and Mobile Clients with Azure AD - -To allow the ownCloud clients (ownCloud Web, Desktop, Android and iOS) to interact directly with the identity provider, you have to register them as clients. - -Only branded ownCloud desktop and mobile clients can be registered with Azure AD, because they need to be built with customized `scope` and `prompt` parameters. As prerequisite, an ownCloud full branding subscription is needed. For more details get in touch with {oc-support-url}[ownCloud Support]. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/oidc.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/oidc.adoc deleted file mode 100644 index d00365e..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/oidc.adoc +++ /dev/null @@ -1,285 +0,0 @@ -= OpenID Connect (OIDC) -:toc: right -:toclevels: 2 -:page-aliases: configuration/user/oidc/index.adoc -:openid-connect-url: https://openid.net/connect/ -:schemeful-samesite-url: https://web.dev/schemeful-samesite/ -:ms-azure-ad-url: https://azure.microsoft.com/en-us/services/active-directory/ -:ms-adfs-url: https://docs.microsoft.com/en-us/windows-server/identity/active-directory-federation-services -:ping-identity-url: https://developer.pingidentity.com/en/cloud-software/pingfederate.html -:cidaas-url: https://www.cidaas.com/ -:keycloak-url: https://www.keycloak.org/ -:kopano-konnect-github-url: https://github.com/Kopano-dev/konnect - -== Introduction - -{openid-connect-url}[OpenID Connect] is an open standard for single sign-on, identity and access management. With ownCloud it can be used for user authentication and client authorization against an external identity provider(IdP). - -**Benefits of using ownCloud with OpenID Connect** - -- Increased security by shifting user authentication to an external identity provider. -- Seamless integration into single sign-on (SSO) environments as well as with third party products. -- Centralized client management within the identity provider. -- Enterprise-grade security through the use of authentication security features (e.g., multi-factor authentication) and policies (e.g., automatic token expiration on certain conditions) provided by identity providers. - -NOTE: ownCloud only supports one configured identity provider which is then valid for all requests. - -Click on the -xref:attachment$/configuration/user/oidc/OAuth-code-flow-sequence-diagram.png[OAuth code flow sequence diagram] -link to get more details on the flow sequence. - -== Supported Identity Providers - -ownCloud Classic can work with identity providers (IdP) that support OpenID Connect. There are many identity providers available and the OpenID Connect implementations vary a lot in terms of supported features as well as configuration needs. - -The currently supported products are - -- {ms-azure-ad-url}[Microsoft Azure AD] -- {ms-adfs-url}[Microsoft ADFS] ^1^ -- {ping-identity-url}[PingIdentity PingFederate] -- {cidaas-url}[cidaas] -- {keycloak-url}[Keycloak] -- {kopano-konnect-github-url}[Kopano Konnect] - -(1) ... Note that ADFS does not support client-secrets that contain an `_` (underscore). - -Please get in touch with ownCloud Consulting if you need help with a specific identity provider product. - -== Prerequisites - -Setting up ownCloud Classic to work with OpenID Connect requires a couple of components to work together: - -- An external identity provider configured to work with the ownCloud components -- A distributed memcache setup - such as Redis or Memcached - is required to operate this app. Follow the xref:configuration/server/caching_configuration.adoc[caching documentation] on how to set it up. -- The {oc-marketplace-url}/apps/openidconnect[OpenID Connect App] installed on ownCloud Classic -- Configuration settings in `config.php` on ownCloud Classic -+ -* `'http.cookie.samesite' \=> 'None',` -+ -See xref:configuration/server/config_sample_php_parameters.adoc#define-how-to-relax-same-site-cookie-settings[config.sample.php] and {schemeful-samesite-url}[Schemeful Same-Site] for examples and details. -+ -* Settings for the OpenID Connect App -+ -See xref:configuration/server/config_apps_sample_php_parameters.adoc#app-openid-connect-oidc[config.apps.sample.php] for examples and details or see section xref:save-settings-in-the-database[Save Settings in the Database] below when running clustered setups. -- Service discovery for the xref:owncloud-desktop-and-mobile-clients[ownCloud Clients] - -=== Save Settings in the Database - -If you run a clustered setup, the following method configuring the OpenID Connect app is preferred, because it is stateless. The app checks for settings in the database first. If none are found, it falls back to the settings stored in `config.php`. The settings are stored as a JSON formatted string with the following keys and values: - -[width="50%",cols="40%,50%",options="header"] -|=== -| Key -| Value - -| appid -| 'openidconnect' - -| configkey -| 'openid-connect' - -| configvalue -| _JSON-String_ -|=== - -If a malformed JSON string is found, an error is logged. The _key->value_ pairs are the same as when storing them to the `config.php` file. This task has to be done by invoking an occ command, see the following example. Use the occ commands `config:app:get` to view the current setting or `config:app:delete` to delete it. See the xref:configuration/server/occ_command.adoc#config-commands[Config Command Set] for more details. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set \ - openidconnect \ - openid-connect \ - --value='{"provider-url":"https:\/\/idp.example.net","client-id":"fc9b5c78-ec73-47bf-befc-59d4fe780f6f","client-secret":"e3e5b04a-3c3c-4f4d-b16c-2a6e9fdd3cd1","loginButtonName":"Login via OpenId Connect"}' ----- - -NOTE: Only set either the database or the config.php keys but not both for the OpenID Connect app. - -== Set Up Service Discovery - -. Webserver Service Discovery Information -+ -In order to allow the ownCloud Clients (Desktop/Android/iOS) to make use of OpenID Connect, the webserver serving ownCloud Classic needs to _provide service discovery information_ under the following static path: -+ -[source,url] ----- -https://cloud.example.com/.well-known/openid-configuration ----- - -. App Service Discovery Information -+ -When enabled, the OpenID Connect App provides the service discovery information on the endpoint: -+ -[source,url] ----- -https://cloud.example.com/index.php/apps/openidconnect/config ----- - -. Webserver Rewrite Rule -+ -To make the endpoint available under the static service discovery path, it is recommended to put a `RewriteRule` in place using in the `VirtualHost` section. The Apache module `rewrite` must be enabled, and if SSL is used, also the modules `proxy`, `proxy_http` and `proxy_connect`: -+ -[source,apache] ----- -RewriteEngine on -RewriteRule "^/.well-known/openid-configuration" "/index.php/apps/openidconnect/config" [P] -SSLProxyEngine On #This can be omitted if no SSL is used ----- -+ -TIP: Depending on the respective infrastructure setup there can be other ways to solve this. In any case, please make sure _not to use redirect rules_ as this will violate the OpenID Connect specification. -+ -IMPORTANT: If you use the `.htaccess` file in the ownCloud web root, you have to manually add that rewrite rule again after any ownCloud upgrade. - -. Once service discovery is available as described above, the ownCloud clients will attempt to connect via OpenID Connect. - -== General Example Setup - -All IdPs have their own setup, but often share common ways of configuring things. Although not identical, the xref:example-setup-using-kopano-konnect[Kopano Konnect] example may be a good starting point for the specific configuration of your setup. As Microsoft with Azure AD is different, it has its own example section. - -== Example Setup Using Kopano Konnect - -Follow this link to see -xref:configuration/user/oidc/kopano-setup.adoc[Example Setup Using Kopano Konnect]. - -== Example Setup Using Microsoft Azure AD - -Follow this link to see -xref:configuration/user/oidc/ms-azure-setup.adoc[Example Setup Using Microsoft Azure AD]. - -== Example Setup Using OneLogin - -Follow this link to see -xref:configuration/user/oidc/onelogin-setup.adoc[Example Setup Using OneLogin]. - -== ownCloud Desktop and Mobile Clients - -ownCloud desktop and mobile clients detect whether OIDC is available (service discovery) and use this login method when a new account is created. - -NOTE: The desktop and mobile apps (clients) have a default client ID and secret hard-coded, which are used for ownCloud's oauth2 app. When using Kopano as IdP, it does not pre-define a client ID and secret. You can use the default ones of the client to configure Kopano properly. With some IdPs like MS-Azure, these and other required parameters come from the IdP and must be coded into the client. Note that each IdP has different requirements. Get in touch with ownCloud for a branding subscription to customize the clients according to your needs. - -=== Client Support for OIDC - -[caption=] -.Following owncloud clients support OIDC -[width="60%",cols="40%,60%",options="header"] -|=== -| ownCloud Client -| Release with OIDC support - -| Desktop -| >= 2.7.0 - -| Android -| >= 2.15 - -| iOS -| >= 1.2 -|=== - -=== Client IDs, Secrets and Redirect URIs - -All IdPs can use ownCloud's default _client IDs, secrets and redirect URIs_ with the exception of Microsoft Azure AD, which uses a different approach. Here is the data necessary for the configuration. - -==== Client ID - -[width="80%",cols="35%,90%",options="header"] -|=== -| Source -| Key - -| Server/Web -| as specified in `config.php` - -| Desktop -| `xdXOt13JKxym1B1QcEncf2XDkLAexMBFwiT9j6EfhhHFJhs2KM9jbjTmf8JBXE69` - -| Android -| `e4rAsNUSIUs0lF4nbv9FmCeUkTlV9GdgTLDH1b5uie7syb90SzEVrbN7HIpmWJeD` - -| iOS -| `mxd5OQDk6es5LzOzRvidJNfXLUZS2oN3oUFeXPP8LpPrhx3UroJFduGEYIBOxkY1` -|=== - -==== Client Secret - -[width="80%",cols="35%,90%",options="header"] -|=== -| Source -| Key - -| Server/Web -| as specified in `config.php` - -| Desktop -| `UBntmLjC2yYCeHwsyj73Uwo9TAaecAetRwMw0xYcvNL9yRdLSUi0hUAHfvCHFeFh` - -| Android -| `dInFYGV33xKzhbRmpqQltYNdfLdJIfJ9L5ISoKhNoT9qZftpdWSP71VrpGR9pmoD` - -| iOS -| `KFeFWWEZO9TkisIQzR3fo7hfiMXlOpaqP8CFuTbSHzV1TUuGECglPxpiVKJfOXIx` -|=== - -==== Redirect URIs - -[width="60%",cols="50%,85%",options="header"] -|=== -| Source -| Redirect URI ^1^ - -| Desktop ≤ 2.8 -| `\http://localhost` - -| Desktop ≥ 2.9 -| `\http://127.0.0.1` - -| Android -| `oc://android.owncloud.com` - -| iOS -| `oc://ios.owncloud.com` -|=== - -(1) See the xref:configuration/user/oidc/ms-azure-setup.adoc#microsoft-azure-ad-and-redirecturi[following note] when using Microsoft Azure AD and 127.0.0.1 as redirect URI. - -=== Default Scope and Prompt Parameters - -ownCloud desktop and mobile apps come with default `scope` and `prompt` parameters. These parameters can be modified in custom branded builds. See the https://openid.net/specs/openid-connect-core-1_0.html#AuthRequest[OIDC Authentication Request specs] for more details about the parameters. - -[width="60%",cols="50%,100%",options="header"] -|=== -| Parameter -| Default value - -| `scope` -| `openid offline_access email profile` - -| `prompt` -| `select_account consent` + -(for Android you need app version 4.0+) -|=== - -=== Migrate Clients from Basic Authentication to OIDC - -If your users are logged in to their desktop and mobile clients via basic authentication (username/password) against ownCloud Classic and you are not using OAuth2 to authorize the ownCloud clients, a migration to OIDC can be conducted as follows: - -1. Make sure you have a working OIDC configuration based on the above sections. -2. Enable the OpenID Connect App. -3. Enable xref:configuration/server/config_sample_php_parameters.adoc#enforce-token-only-authentication-for-apps-and-clients-connecting-to-owncloud[token-only authentication]. - -Once the OpenID Connect App is enabled, token-only authentication is enforced and service discovery is properly set up, the ownCloud clients will ask the users to re-authenticate. After a successful re-authentication, the migration is done. - -To connect legacy clients, users have to generate xref:classic_ui:personal_settings/security.adoc#app-passwords-tokens[special app passwords (tokens)]. - -=== Migrate Clients from OAuth2 to OIDC - -If you use OAuth2 for client authorization, a migration to OIDC can be conducted as follows: - -1. Make sure you have a working configuration based on the above sections. -2. Enable the OpenID Connect App (while having the OAuth2 App still enabled). -3. Disable the OAuth2 App. - -Once the OAuth2 App is disabled and service discovery is properly set up, the ownCloud Clients will ask the users to re-authenticate. After a successful re-authentication, the migration is done. - -== Migrate Web Login (and Client Login) from SAML to OIDC - -If you are using SAML/SSO, a migration to OIDC depends on your identity provider and is not straight forward. Please get in touch with ownCloud Consulting to plan the migration. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/onelogin-setup.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/onelogin-setup.adoc deleted file mode 100644 index 87c6ec9..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/oidc/onelogin-setup.adoc +++ /dev/null @@ -1,108 +0,0 @@ -= Example Setup Using OneLogin -:toc: right -:toclevels: 2 -:openid-connect-frontchannel-logout-url: https://openid.net/specs/openid-connect-frontchannel-1_0.html -:onelogin-url: https://www.onelogin.com -:description: OneLogin is a cloud-based identity and access management provider. This document describes how to integrate OneLogin as an identity provider (IdP) by configuring OpenID Connect (OIDC). - -== Introduction - -{description} See {onelogin-url}[OneLogin] for details about the service. - -IMPORTANT: At the moment, ownCloud clients don't work with OneLogin as IdP which is a known issue. - -== Setup and Configuration - -The sections below will explain these areas and provide configuration examples using OneLogin as the external Identity Provider. - -=== Configure OneLogin - -Follow these steps to configure OneLogin for use with OpenID Connect (OIDC): - -. Login to OneLogin via your domain login `\https://.onelogin.com/admin2`. - -. Go to menu:Applications[Applications] to manage the registered applications. -+ -image:configuration/user/oidc/onelogin/onelogin-select-application.png[width=80%] - -. Click on btn:[Add App] in the upper right corner. - -. Search for `openid` and select the `OpenId Connect (OIDC)` app -+ -image:configuration/user/oidc/onelogin/onelogin-select-openid-app.png[width=80%] - -. Provide a name and configure images if needed. - -. Hit btn:[Save] - -. Go to menu:Configuration[] and enter values for `Login Url` which points to you system and the `Redirect URI's`, which is the url of you system followed by `/index.php/apps/openidconnect/redirect` -+ -image:configuration/user/oidc/onelogin/onelogin-oidc-configuration.png[width=90%] - -. Go to menu:SSO[] and note the values for [#client-id]#Client ID#, [#client-secret]#Client Secret# and [#issuer-url]#Issuer URL# for later use. -+ -image:configuration/user/oidc/onelogin/onelogin-oidc-sso.png[width=90%] - -=== Configure ownCloud Classic - -These are the generic steps to set up ownCloud Classic to work with OpenID Connect, for details see the sections below: - -1. Install the {oc-marketplace-url}/apps/openidconnect[OpenID Connect App]. -2. Configure `config.php`. -3. Set up service discovery. - -TIP: It is recommended to first figure out all configurations on a test system and to bring it to the production system once it's proven to work. Enabling the OpenID Connect App on the production system should be the last step in this process as it will then advertise OpenID Connect to all clients. - -==== List of OpenID Connect config.php Parameters - -Follow this link to read more about the -xref:configuration/server/config_apps_sample_php_parameters.adoc#app-openid-connect-oidc[OIDC config.php parameters] available to configure OpenID Connect on ownCloud Classic. - -==== Example config.php Setup - -An example snippet that can be added to `config.php` is shown below. You need to add both config values as listed below. The example expects that login users have already been created in ownCloud. - -Use these links to see the corresponding configuration section for: - -* xref:client-secret[YOUR-CLIENT-SECRET] -* xref:client-id[YOUR-CLIENT-ID] -* xref:issuer-url[YOUR-ISSUER-URL] - -[source,php] ----- -'http.cookie.samesite' => 'None', - -'openid-connect' => [ - 'auto-provision' => ['enabled' => false], - 'provider-url' => 'YOUR-ISSUER-URL', - 'client-id' => 'YOUR-CLIENT-ID', - 'client-secret' => 'YOUR-CLIENT-SECRET', - 'loginButtonName' => 'OneLogin', - 'autoRedirectOnLoginPage' => false, - 'mode' => 'email', - 'scopes' => [], - 'use-access-token-payload-for-user-info' => false, -], ----- - -If you want to let ownCloud create users which are not present during a OIDC authentication, replace + -`'auto-provision' => ['enabled' => false],` with: - -[source,php] ----- - 'auto-provision' => [ - 'enabled' => true, - 'email-claim' => 'email', - 'display-name-claim' => 'name', - ], ----- - -==== Service Discovery Setup - -For details see xref:configuration/user/oidc/oidc.adoc#set-up-service-discovery[Set Up Service Discovery]. - -//// -=== Register ownCloud Clients - -To allow the ownCloud clients (Web/desktop/Android/iOS) to interact with the identity provider, you have to register them as clients. -//// diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/reset_admin_password.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/reset_admin_password.adoc deleted file mode 100644 index 0578507..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/reset_admin_password.adoc +++ /dev/null @@ -1,37 +0,0 @@ -= Resetting a Lost Admin Password - -The normal ways to recover a lost password are: - -1. Click the password reset link on the login screen; this appears -after a failed login attempt. This works only if you have entered your -email address on your Personal page in the ownCloud Web interface, so -that the ownCloud server can email a reset link to you. -2. Ask another ownCloud server admin to reset it for you. - -If neither of these is an option, then you have a third option, and that -is using the `occ` command. `occ` is in the `owncloud` directory, for -example `/var/www/owncloud/occ`. `occ` has a command for resetting all -user passwords, `user:resetpassword`. It is best to run `occ` as the -HTTP user, as in this example on Ubuntu Linux: - -[source,bash,subs="attributes+"] ----- -$ {occ-command-example-prefix} user:resetpassword admin -Enter a new password: -Confirm the new password: -Successfully reset password for admin ----- - -If your ownCloud username is not `admin`, then substitute your ownCloud -username. - -You can find your HTTP user in your HTTP configuration file. These are -the default Apache HTTP user:group on Linux distros: - -* Centos, Red Hat, Fedora: `apache:apache` -* Debian, Ubuntu, Linux Mint: `www-data:www-data` -* openSUSE: `wwwrun:www` - -See xref:configuration/server/occ_command.adoc[Using the occ Command] to learn more about using the `occ` command. - -include::partial$configuration/user/update-password-note.adoc[] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/reset_user_password.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/reset_user_password.adoc deleted file mode 100644 index a7c95d0..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/reset_user_password.adoc +++ /dev/null @@ -1,16 +0,0 @@ -= Resetting a User Password - -The ownCloud login screen displays a *Wrong password. Reset it?* message -after a user enters an incorrect password, and then ownCloud -automatically resets their password. However, if you are using a -read-only authentication backend such as LDAP or Active Directory, this -will not work. In this case you may specify a custom URL in your -`config.php` file to direct your user to a server than can handle an -automatic reset: - -[source,php] ----- -'lost_password_link' => 'https://example.org/link/to/password/reset', ----- - -include::partial$configuration/user/update-password-note.adoc[] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_ftp_smb_imap.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_ftp_smb_imap.adoc deleted file mode 100644 index 1eff9f4..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_ftp_smb_imap.adoc +++ /dev/null @@ -1,151 +0,0 @@ -= User Authentication with IMAP, SMB, and FTP -:toc: right -:toclevels: 1 - -== Introduction - -You may configure additional user backends in ownCloud’s configuration -file (`config/config.php`) using the following syntax: - -[source,php] ----- - [ - 0 => [ - "class" => ..., - "arguments" => [ - 0 => ... - ], - ], -], ----- - -NOTE: A non-blocking or correctly configured SELinux setup is needed for these backends to work, -if SELinux is enabled on your server. Please refer to the -xref:installation/selinux_configuration.adoc[SELinux configuration] for further details. - -Currently the https://github.com/owncloud/user_external[External user support app] (user_external), -_which is not enabled by default_, provides three backends. These are: - -* xref:imap[IMAP] -* xref:smb[SMB] -* xref:ftp[FTP] - -See xref:installation/apps_management_installation.adoc[Installing and Managing Apps] for more information. - -== IMAP - -Provides authentication against IMAP servers. - -[cols=",",options="header",] -|==== -| Option -| Value/Description - -| Class -| `OC_User_IMAP`. - -| Arguments -| A mailbox string as defined + -{php-net-url}/manual/en/function.imap-open.php[in the PHP documentation]. - -| Dependency -| {php-net-url}/manual/en/book.imap.php[PHP’s IMAP extension]. + -See xref:installation/manual_installation/manual_installation.adoc[Manual Installation on Linux] for instructions on how to install it. -|==== - -=== Example - -[source,php] ----- - [ - 0 => [ - "class" => "OC_User_IMAP", - "arguments" => [ - // The IMAP server to authenticate against - '{imap.gmail.com:993/imap/ssl}', - // The domain to send email from - 'example.com' - ], - ], -], ----- - -IMPORTANT: The second `arguments` parameter ensures that only users from that domain are allowed to login. When set, after a successful login, the domain will be stripped from the email address and the rest used as an ownCloud username. For example, if the email address is `guest.user@example.com`, then `guest.user` will be the username used by ownCloud. - -SMB ---- - -Provides authentication against Samba servers. - -[cols=",",options="header",] -|==== -| Option -| Value/Description - -| Class -| `OC_User_SMB` - -| Arguments -| The samba server to authenticate against. - -| Dependency -| https://pecl.php.net/package/smbclient[PECL’s smbclient extension] or + -xref:configuration/files/external_storage/smb.adoc[smbclient]. -|==== - -=== Example - -[source,php] ----- - [ - [ - "class" => "OC_User_SMB", - "arguments" => [ - 'localhost' - ], - ], -], ----- - -FTP ---- - -Provides authentication against FTP servers. - -[cols=",",options="header",] -|=== -| Option -| Value/Description - -| Class -| `OC_User_FTP` - -| Arguments -| The FTP server to authenticate against. - -| Dependency -| {php-net-url}/manual/en/book.ftp.php[PHP’s FTP extension]. + -See xref:installation/manual_installation/manual_installation.adoc[Source Installation] for instructions on how to install it. -|=== - -=== Example - -[source,php] ----- - [ - [ - "class" => "OC_User_FTP", - "arguments" => [ - 'localhost' - ], - ], -], ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_ldap.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_ldap.adoc deleted file mode 100644 index 8fd00ff..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_ldap.adoc +++ /dev/null @@ -1,871 +0,0 @@ -= LDAP Integration -:toc: right -:toclevels: 3 -:description: The LDAP Integration app allows you to integrate your existing LDAP users in ownCloud. - -:activate-ldap-directory-syntax-filters-url: http://social.technet.microsoft.com/wiki/contents/articles/5392.active-directory-ldap-syntax-filters.aspx -:ad-group-membership-with-powershell-url: http://blogs.technet.com/b/heyscriptingguy/archive/2014/11/25/active-directory-week-explore-group-membership-with-powershell.aspx -:ad-ldap-filters-syntax-url: https://social.technet.microsoft.com/wiki/contents/articles/5392.active-directory-ldap-syntax-filters.aspx -:config-dynamic-groups-url: http://www.zytrax.com/books/ldap/ch11/dynamic.html -:enumerate-ad-user-groups-permissions-url: https://serverfault.com/questions/167371/what-permissions-are-required-for-enumerating-users-groups-in-active-directory/167401#167401 -:index-attribute-in-ad-url: https://docs.microsoft.com/en-us/previous-versions/tn-archive/aa995762(v=exchg.65) -:ldap-schema-for-owncloud-quota: https://github.com/valerytschopp/owncloud-ldap-schema -:memberof-url: https://docs.microsoft.com/en-us/windows/win32/ad/security-properties -:openldap-index-tuning-guide-url: https://www.openldap.org/doc/admin24/tuning.html#Indexes -:oracle-ismemberof-url: https://docs.oracle.com/cd/E29127_01/doc.111170/e28967/ismemberof-5dsat.htm -:reverse-group-membership-maintenance-url: https://www.openldap.org/doc/admin24/overlays.html#Reverse%20Group%20Membership%20Maintenance -:selinux-url: https://selinuxproject.org/page/Main_Page -:service-ldap-with-tls-url: https://ubuntu.com/server/docs/service-ldap-with-tls -:ldap-over-ssl-ldaps-certificate-url: https://social.technet.microsoft.com/wiki/contents/articles/2980.ldap-over-ssl-ldaps-certificate.aspx - -== Introduction - -{description} - -The LDAP application supports: - -* LDAP group support -* File sharing with ownCloud users and groups -* Access via WebDAV and ownCloud Desktop Client -* Versioning, external Storage and all other ownCloud features -* Seamless connectivity to Active Directory, with no extra configuration required -* Support for primary groups in Active Directory -* Only read access to your LDAP (edit or delete of users on your LDAP is not supported) - -== Configuration - -First, install the {oc-marketplace-url}/apps/user_ldap[LDAP Integration] app. Then, go to your Admin page to configure it. The LDAP configuration panel has four tabs. A correctly completed first tab ("Server") is mandatory to access the other tabs. A green indicator light appears when the configuration is correct. Hover your cursor over the fields to see some pop-up tooltips. - -=== Server Tab - -Start with the Server tab. You may configure multiple servers if you have them. At a minimum, you must supply the LDAP server's hostname. If your server requires authentication, enter your credentials on this tab. - -image::apps/user_ldap/ldap-wizard/server-tab.png[LDAP Wizard - Server Tab, width=500] - -==== LDAPS Configuration - -LDAPS encrypts the connection between your LDAP server and ownCloud via SSL/TLS. - -For LDAPS you need a LDAP server with certificates:: - -{empty} - -. For Windows Server, install the _Active Directory Certificate Services (AD CS)_ role and configure it as a company CA. -. Export the CA certificate using this method: -.. Open `certutil` with admin privileges and execute the following command where `ca_name` is just a placeholder for the certificate name. Adjust it accordingly. -+ --- -[source,plaintext] ----- -certutil -ca.cert ca_name.cer ----- -This ensures you have the right certificate for configuring LDAPS. --- -. Copy the certificate `ca_name.cer` to your ownCloud server. -. Do the following tasks on the ownCloud server. -.. Convert the certificate with: -+ --- -[source,plaintext] ----- -openssl x509 -inform der -in ca_name.cer -out certificate.pem ----- --- -.. Double-check with: -+ --- -[source,bash] ----- -cat certificate.pem ----- -The output is the same one you had with `certutil`. --- - -Move the Certificate:: - -Move the certificate to `/etc/ldap/certs/` (on Ubuntu) or `/etc/openldap/certs/ (on centOS)`. You have to create the `certs` folder inside those directories beforehand. - -. Only for `centOS`: + -Change permissions with `chown` so the ldap client can access the certificate: -+ --- -[source,bash] ----- -chown centos:centos certificate.pem ----- --- -. Edit the `ldap.conf` file inside the ldap directory: -+ --- -.Ubuntu -[source,plaintext] ----- - TLS_CACERT /etc/ldap/certs/certificate.pem ----- -.centOS -[source,plaintext] ----- - TLS_CACERT /etc/openldap/certs/certificate.pem ----- --- -. Restart the web server. - -If you have a openLDAP server, perform the following steps:: - -{empty} - -. Import the ssl certificate from openLDAP to ownCloud server. -. Put it in the /etc/ldap/certs/ or /etc/openldap/certs/ folder, depending on whether you have Ubuntu or centOS. -. Include it in your `ldap.conf`: -+ --- -.Ubuntu -[source,plaintext] ----- - TLS_CACERT /etc/ldap/certs/certificate.pem ----- -.centOS -[source,plaintext] ----- - TLS_CACERT /etc/openldap/certs/certificate.pem ----- --- -. Restart the web server. - -{empty} - -Configure the ownCloud LDAP app:: - -. Finalize LDAPS via section xref:server-configurations[Server Configurations] below: -.. If you were using LDAP with port 389, you have to change the port to 636 and add `ldaps://` to your LDAP host in the server tab. -.. Click on menu:Test BaseDN[] and you should see a green light and a number of entries that were found in your LDAP. - -LDAPS is prepared:: - -Finally you have LDAPS configured and your LDAP traffic is encrypted with a SSL certificate. - -==== Server Configurations - -Server Configuration:: - Configure one or more LDAP servers. - Click btn:[Delete Configuration] to remove the active configuration. - -Host:: -+ --- -The hostname or IP address of the LDAP server. -It can also be an `ldaps://` URI. -If you enter the port number, it speeds up server detection. - -*Examples:* - -* `directory.my-company.com` -* `ldaps://directory.my-company.com` -* `directory.my-company.com:9876` --- - -Port:: -+ --- -The port on which to connect to the LDAP server. - -Example: - -* `389` for unencrypted connection -* `636` for encrypted connection --- - -User DN:: -+ --- -The name as DN of a user who has permissions to do searches in the LDAP directory. Leave it empty for anonymous access. We recommend that you have a special LDAP system user for this. - -Example: - -[width=100,cols="70%,30%",options=header] -|=== -| User DN -| LDAP Directory - -| `uid=owncloudsystemuser,cn=sysusers,dc=my-company,dc=com` -| OpenLDAP - -| `Administrator@my-company.com` -| MicroSoft AD-Server -|=== --- - -Password:: - The password for the user given above. - Empty for anonymous access. - -Base DN:: -+ --- -The base DN of LDAP, from where all users and groups can be reached. You may enter multiple base DNs, one per line. Base DNs for users and groups can be set in the Advanced tab. You can either enter this value manually, or click btn:[Detect Base DN] to have ownCloud attempt to determine the value. - -Example: - -* `dc=my-company,dc=com` --- - -=== User Filter - -Use this to control which LDAP users are listed as ownCloud users on your ownCloud server. In order to control which LDAP users can log in to your ownCloud server, use the Login filter. You may bypass the form fields and enter a raw LDAP filter if you prefer. - -image::apps/user_ldap/ldap-wizard/users-tab.png[LDAP Wizard - Users Tab, width=500] - -Only those Object Classes:: - ownCloud determines the object classes that are typically available for user objects in your LDAP. - ownCloud automatically selects the object class that returns the highest number of users. - You may select multiple object classes. - -Only From those Groups:: -+ --- -If your LDAP server supports the `memberof-overlay` in LDAP filters, you can define that only users from one or more certain groups are allowed to appear in user listings in ownCloud. By default, no value is selected. You may select multiple groups. - -[NOTE] -==== -Group membership is configured by adding `memberUid`, `uniqueMember` or member attributes to an LDAP group see (xref:group-member-association[Group Member association]) below. -To efficiently look up the groups, a user who is a member of the LDAP server must support a `memberof-overlay`. -It allows using the virtual `memberOf` or `isMemberOf` attributes of an LDAP user in the user filter. -If your LDAP server does not support the `memberof-overlay` in LDAP filters, the input field is disabled. -Please contact your LDAP administrator. - -* Active Directory uses {memberof-url}[memberOf] and is enabled by default. -* OpenLDAP uses `memberOf`. {reverse-group-membership-maintenance-url}[Reverse Group Membership Maintenance] needs to be enabled. -* Oracle uses {oracle-ismemberof-url}[isMemberOf] and is enabled by default. -==== --- - -Edit Raw Filter Instead:: -+ --- -Clicking on this text toggles the filter mode, and you can enter the raw LDAP filter directly. Example: - -[source,plaintext] ----- -include::example$configuration/user/user_auth_ldap/group_filter.ldif[] ----- --- - -// <x> --> renders to - -<x> Users Found:: -+ --- -This is an indicator that tells you approximately how many users will be listed in ownCloud. -The number updates automatically after any changes. - -[IMPORTANT] -==== -No matter what search filter is given, the app always adds the value of the `User Display Name Field` (default `(displayName=*)` ) to the filter to ensure that your users have this field, otherwise the count will be 0. -==== - -Active Directory offers "_Recursive retrieval of all AD group memberships of a user_". This means that you would be able to search the group you enter and all the other child groups from this group for users. Enter this filter to access this feature for a single group: - -[source,plaintext] ----- -include::example$configuration/user/user_auth_ldap/single_group_search.ldif[] ----- - -Enter your group name instead of the `` placeholder. If you want to search multiple groups with this feature, adjust your filter like this: - -[source,plaintext] ----- -include::example$configuration/user/user_auth_ldap/multi_group_search.ldif[] ----- - -You can add as many groups to recurse by using the format: `(|(m1)(m2)(m3).....)`. {ad-ldap-filters-syntax-url}[Here is the description from Microsoft (point #10)]: - -____ -The string `1.2.840.113556.1.4.1941` specifies `LDAP_MATCHING_RULE_IN_CHAIN`. -This applies only to DN attributes. -This is an extended match operator that walks the chain of ancestry in objects all the way to the root until it finds a match. -**This reveals group nesting.** -It is available only on domain controllers with Windows Server 2003 SP2 or Windows Server 2008 (or above). -____ - -For more information, see the following from Technet: - -* {activate-ldap-directory-syntax-filters-url}[Active Directory: LDAP Syntax Filters, window="_blank"] -* {ad-group-membership-with-powershell-url}[Active Directory Week: Explore Group Membership with PowerShell, window="_blank"] --- - -=== Login Filter - -The settings in the Login Filter tab determine which LDAP users can log in to your ownCloud system and which attribute or attributes the provided login name is matched against (e.g., LDAP/AD username, email address). You may select multiple user details. You may bypass the form fields and enter a raw LDAP filter if you prefer. - -You may override your User Filter settings on the User Filter tab by using a raw LDAP filter. - -image::apps/user_ldap/ldap-wizard/login-attributes-tab.png[LDAP Wizard - Login Attributes Tab, width=500] - -LDAP Username:: - If this value is checked, the login value will be compared to the username in the LDAP directory. - The corresponding attribute, usually `uid` or `samaccountname` will be detected automatically by ownCloud. - -LDAP Email Address:: - If this value is checked, the login value will be compared to an email address in the LDAP directory; specifically, the `mailPrimaryAddress` and `mail` attributes. - -[IMPORTANT] -==== -Disallowing login with LDAP Email Address requires enabling strict login checking to be effective: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set --type boolean --value true strict_login_enforced ----- -==== - -Other Attributes:: - This multi-select box allows you to select other attributes for the comparison. - The list is generated automatically from the user object attributes in your LDAP server. - -Edit Raw Filter Instead:: -+ --- -Clicking on this text toggles the filter mode, and you can enter the raw LDAP filter directly. Example: - -The `%uid` placeholder is replaced with the login name entered by the user upon login. - -*Examples:* - -* Only Username: -+ -[source,ldap] ----- -include::example$configuration/user/user_auth_ldap/only_username.ldif[] ----- - -* Username or Email Address: -+ -[source,plaintext] ----- -include::example$configuration/user/user_auth_ldap/username_email.ldif[] ----- --- - -=== Group Filter - -By default, no LDAP groups will be available in ownCloud. The settings in the group filter tab determine which groups will be available in ownCloud. You may also elect to enter a raw LDAP filter instead. - -image::apps/user_ldap/ldap-wizard/groups-tab.png[LDAP Wizard - Groups Tab, width=500] - -Only those object classes:: - ownCloud will determine the object classes that are typically available for group objects in your LDAP server. - ownCloud will only list object classes that return at least one group object. - You can select multiple object classes. - A typical object class is `group`, or `posixGroup`. - -Only From those Groups:: - ownCloud will generate a list of available groups found in your LDAP server. - From these groups, you can select the group or groups that get access to your ownCloud server. - -Edit Raw Filter Instead:: -+ --- - Clicking on this text toggles the filter mode, and you can enter the raw LDAP filter directly. - -Example: - -* `objectClass=group` -* `objectClass=posixGroup` --- - -// <x> --> renders to - -<x> Groups Found:: - This tells you approximately how many groups will be available in ownCloud. - The number updates automatically after any change. - -NOTE: Renaming of LDAP-Groups on the LDAP Server is not supported. Changes like renaming groups in LDAP will not be propagated to ownCloud. - -=== Advanced Settings - -The LDAP Advanced Setting section contains options that are not needed for a working connection. This provides controls to disable the current configuration, configure replica hosts, and various performance-enhancing options. - -The Advanced Settings are structured into three parts: - -* Connection Settings -* Directory Settings -* Special Attributes - -==== Connection Settings - -image::apps/user_ldap/ldap-wizard/advanced-tab-connection-settings.png[LDAP Wizard - Advanced Tab - Connection Settings, width=500] - -Configuration Active:: - Enables or Disables the current configuration. - By default, it is turned off. - When ownCloud makes a successful test connection, it is automatically turned on. - -Backup (Replica) Host:: -+ --- -If you have a backup LDAP server, enter the connection settings here. ownCloud will then automatically connect to the backup when the main server cannot be reached. The backup server must be a replica of the main server so that the object UUIDs match. - -Example: - -* `directory2.my-company.com` --- - -Backup (Replica) Port:: -+ --- - The connection port of the backup LDAP server. - If no port is supplied, but only a host, then the main port (as specified above) will be used. - -Example: - -* `389` --- - -Disable Main Server:: - - You can manually override the main server and make ownCloud only connect to the **backup server**. - This is useful for planned downtimes for example **Upgrades or Updates of the Main Server**. - **Backup Server Handling** - When ownCloud is not able to contact the main LDAP server, ownCloud assumes it is offline and will not try to connect again for the time specified in" **Cache Time-To-Live**". - -Turn off SSL certificate validation:: -+ --- -Turns off SSL certificate checking. - -TIP: Use it for testing only! --- - -Cache Time-To-Live:: -+ --- -A cache is introduced to avoid unnecessary LDAP traffic, for example caching usernames so they don't have to be looked up for every page, and speeding up loading of the Users page. Saving the configuration empties the cache. -The time is given in seconds. Note that almost every PHP request requires a new connection to the LDAP server. If you require fresh PHP requests, we recommend defining a minimum lifetime of about 15 seconds or higher, rather than completely eliminating the cache. - -*Examples:* - -* Ten minutes: `600` -* One hour: `3600` - -See xref:caching[the Caching section below] for detailed information on how the cache operates. --- - -==== Directory Settings - -image::apps/user_ldap/ldap-wizard/advanced-tab-directory-settings.png[LDAP Wizard - Advanced Tab - Directory Settings, width=500] - -User Display Name Field:: -+ --- -The attribute that should be used as display name in ownCloud. - -*Examples:* - -* `displayName` -* `givenName` -* `sn` --- - -2nd User Display Name Field:: -+ --- -An optional second attribute displayed in brackets after the display name, for example using the `mail` attribute displays as `Molly Foo (molly@example.com)`. - -*Examples:* - -* `mail` -* `userPrincipalName` -* `sAMAccountName` --- - -Base User Tree:: -+ --- -The base DN of LDAP, from where all users can be reached. This must be a complete DN, regardless of what you have entered for your Base DN in the Basic setting. You can specify multiple base trees, one on each line. - -*Examples:* - -* `cn=programmers,dc=my-company,dc=com` -* `cn=designers,dc=my-company,dc=com` --- - -User Search Attributes:: -+ --- -These attributes are used when searches for users are performed, for example in the share dialogue. The user display name attribute is the default. You may list multiple attributes, one per line. - -If an attribute is not available on a user object, the user will not be listed, and will be unable to login. This also affects the display name attribute. If you override the default you must specify the display name attribute here. - -*Examples:* - -* `displayName` -* `mail` --- - -Group Display Name Field:: -+ --- -The attribute that should be used as ownCloud group name. -ownCloud allows a limited set of characters (`a-zA-Z0-9.-_@`). -Once a group name is assigned it cannot be changed. - -*Examples:* - -* `cn` --- - -Base Group Tree:: -+ --- -The base DN of LDAP, from where all groups can be reached. -This must be a complete DN, regardless of what you have entered for your Base DN in the Basic setting. -You can specify multiple base trees, one in each line. - -*Examples:* - -* `cn=barcelona,dc=my-company,dc=com` -* `cn=madrid,dc=my-company,dc=com` --- - -Group Search Attributes:: -+ --- -These attributes are used when a search for groups is done, for example in the share dialogue. -By default the group display name attribute as specified above is used. -Multiple attributes can be given, one in each line. - -If you override the default, the group display name attribute will not be taken into account, unless you specify it as well. - -*Examples:* - -* `cn` -* `description` --- - -[[group-member-association]] -Group Member Association:: -+ --- -The attribute that is used to indicate group memberships, i.e., the attribute used by LDAP groups to refer to their users. ownCloud detects the value automatically. You should only change it if you have a very valid reason and know what you are doing. - -*Examples:* - -* `member` with FDN for Active Directory or for objectclass `groupOfNames` groups -* `memberUid` with RDN for objectclass `posixGroup` groups -* `uniqueMember` with FDN for objectclass `groupOfUniqueNames` groups - -NOTE: The Group Member association is used to efficiently query users of a certain group, e.g., on the userManagement page or when resolving all members of a group share. --- - -Dynamic Group Member URL:: - The LDAP attribute that on group objects contains an LDAP search URL that determines what objects belong to the group. - An empty setting disables dynamic group membership functionality. - See {config-dynamic-groups-url}[Configuring Dynamic Groups] for more details. - -Nested Groups:: - This makes the LDAP connector aware that groups could be stored inside existing group records. - By default a group will only contain users, so enabling this option isn't necessary. However, if groups are contained inside groups, and this option is not enabled, any groups contained within other groups will be ignored and not returned in search results. - -Paging Chunk Size:: - This sets the maximum number of records able to be returned in a - response when ownCloud requests data from LDAP. If this value is - greater than the limit of the underlying LDAP server (such as 3000 for - Microsoft Active Directory) the LDAP server will reject the request - and the search request will fail. Given that, it is important to set - the requested chunk size to a value no larger than that which the - underlying LDAP server supports. - -==== Special Attributes - -image::apps/user_ldap/ldap-wizard/advanced-tab-special-attributes.png[LDAP Wizard - Advanced Tab - Special Attributes, width=500] - -Quota Field:: - The name of the LDAP attribute to retrieve the user quota limit from. You have to decide which LDAP attribute you want to use and set a value to it in the Attribute Editor. - -Quota Default:: -+ --- -Override ownCloud's default quota *for LDAP users* who do not have a quota set in the Quota Field. - -. After installation ownCloud uses an unlimited quota by default. -. Administrators can modify this value, at any time, in the user management page. -. However, when an LDAP quota is set it will override any values set in ownCloud. -. If an LDAP per/attribute quota is set in the active directory, it will override the LDAP Quota Default value. - -NOTE: Administrators are not allowed to modify the user quota limit in the user management page when steps 3 or 4 are in effect. At this point, updates are only possible via LDAP. See the {ldap-schema-for-owncloud-quota}[LDAP Schema for ownCloud Quota] --- - -Quota Priority:: - If set, this is the current Quota Priority: - - 1. **Quota Field** overrides **LDAP Quota Default** - 2. **LDAP Quota Default** overrides **ownCloud Default Quota** - 3. **ownCloud Default Quota** overrides **Unlimited Quota** - -Email Field:: - Set the user's email from an LDAP attribute, e.g., `mail`. - Leave it empty for default behavior. - -User Home Folder Naming Rule:: -+ --- -By default, the ownCloud server creates the user directory in your ownCloud data directory and gives it the ownCloud username, e.g., `/var/www/owncloud/data/5a9df029-322d-4676-9c80-9fc8892c4e4b`, if your data directory is set to `/var/www/owncloud/data`. - -It is possible to override this setting and name it after an LDAP attribute value, e.g., `attr:cn`. The attribute can return either an absolute path, e.g., `/mnt/storage43/alice`, or a relative path which must not begin with a `/`, e.g., `CloudUsers/CookieMonster`. This relative path is then created inside the data directory (e.g., `/var/www/owncloud/data/CloudUsers/CookieMonster`). - -Since ownCloud 8.0.10 and up the home folder rule is enforced. This means that once you set a home folder naming rule (get a home folder from an LDAP attribute), it must be available for all users. If it isn't available for a user, then that user will not be able to login. Also, the filesystem will not be set up for that user, so their file shares will not be available to other users. For older versions you may enforce the home folder rule with the `occ` command, like this example on Ubuntu: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set user_ldap enforce_home_folder_naming_rule --value=1 ----- - -Starting with ownCloud Classic 10.0, the home folder naming rule is only applied when first provisioning the user. This prevents data loss due to re-provisioning the users home folder in case of unintentional changes in LDAP. --- - -=== Expert Settings - -IMPORTANT: Please check both the advanced and expert configurations carefully before using in production. - -image::apps/user_ldap/ldap-wizard/expert-tab.png[LDAP Wizard - Expert Tab, width=500] - -In "*Expert Settings*", fundamental behavior can be adjusted to your needs. The configuration should be well-tested before starting production use. - -Internal Username:: -+ --- -The internal username is the identifier in ownCloud for LDAP users. -By default it will be created from the UUID attribute. -The UUID attribute ensures that the username is unique, and that characters do not need to be converted. -Only these characters are allowed: `[\a-\zA-\Z0-\9_.@-]`. -Other characters are replaced with their ASCII equivalents, or are simply omitted. - -The LDAP backend ensures that there are no duplicate internal usernames in ownCloud, i.e., that it is checking all other activated user backends (including local ownCloud users). -On collisions, a random number (between 1000 and 9999) will be attached to the retrieved value. -For example, if "alice" exists, the next username may be `alice_1337`. - -The internal username is the default name for the user home folder in ownCloud. -It is also a part of remote URLs, for instance for all *DAV services. - -You can override all of this with the "*Internal Username*" setting. -Leave it empty for default behavior. -Changes will affect only newly mapped LDAP users. - -*Examples:* - -* `uid` --- - -Override UUID Detection:: -+ --- -By default, ownCloud auto-detects the UUID attribute. -The UUID attribute is used to uniquely identify LDAP users and groups. -The internal username will be created based on the UUID, if not specified otherwise. - -You can override the setting and pass an attribute of your choice. -You must make sure that the attribute of your choice can be fetched for both users and groups and that it is unique. -Leave it empty for default behavior. -Changes will have effect only on newly mapped LDAP users and groups. - -It also will take effect when a user or group's DN changes and an old UUID was cached, which will result in a new user. -Because of this, the setting should be applied before putting ownCloud in production use and clearing the bindings the (see xref:user-and-group-mapping[User and Group Mapping`] section below). - -*Examples:* - - * `cn` --- - -Username-LDAP User Mapping:: -+ --- -ownCloud uses usernames as keys to store and assign data. -In order to precisely identify and recognize users, each LDAP user will have an internal username in ownCloud. -This requires a mapping from an ownCloud username to an LDAP user. - -The created username is mapped to the UUID of the LDAP user. -Additionally, the DN is cached to reduce LDAP interaction, but it is not used for identification. -If the DN changes, the change will be detected by ownCloud by checking the UUID value. - -The same is valid for groups. -The internal ownCloud name is used all over in ownCloud. -Clearing the mappings will have leftovers everywhere. -Never clear the mappings in a production environment, but only in a testing or experimental server. - -IMPORTANT: Clearing the mappings is not configuration sensitive, it affects all LDAP configurations! --- - -=== Testing the Configuration - -The "**Test Configuration**" button checks the values as currently given in the input fields. You do not need to save before testing. By clicking on the button, ownCloud will try to bind to the ownCloud server using the settings currently given in the input fields. If the binding fails you'll see a yellow banner with the error message: - -`The configuration is invalid. Please have a look at the logs for further details.` - -When the configuration test reports success, save your settings and check if the users and groups are fetched correctly on the Users page. - -image::configuration/user/user-page.png[Users Page, width=500] - -=== Syncing Users - -While users who match the login and user filters can log in, only synced users will be found in the sharing dialog. Whenever users log in, their display name, email, quota, avatar and search attributes will be synced to ownCloud. If you want to keep the metadata up to date you can set up a cron job, using the xref:configuration/server/occ_command.adoc#syncing-user-accounts[occ user:sync command]. Versions of ownCloud before 10.0 imported all users when the users page was loaded, but this is no longer the case. - -IMPORTANT: During initial sync, make sure to check the ownCloud log for errors that could indicate a possible misconfiguration. - -TIP: We recommend xref:configuration/server/background_jobs_configuration.adoc#cron-jobs[creating a Cron job], to automate regularly syncing LDAP users with your ownCloud database. If you have many users, you do not have to sync all of them to update a small number of users. You can use the xref:developer_manual:core/apis/ocs-user-sync-api.adoc[OCS User Sync API] to sync individual users. It provides a way to trigger user sync from outside of ownCloud. - -=== How Often Should the Job Run? - -This depends on the amount of users and speed of the update, but we recommend _at least_ once per day. You can run it more frequently, but doing so may generate too much load on the server. - -=== Reuse Existing User and Group LDAP Accounts - -New LDAP logins can attempt to reuse _existing_ user and group accounts if: - -* They match the resolved username attribute. -* They have `User_Proxy` set as their backend. - -To enable this functionality, the `reuse_accounts` config setting must be set to `yes`. To enable it, run the following command. - -[source,bash,subs="attributes+"] -.... -{occ-command-example-prefix} config:app:set user_ldap reuse_accounts --value=yes -.... - -=== ownCloud Avatar Integration - -ownCloud supports user profile pictures, which are also called avatars. If a user has a photo stored in the `jpegPhoto` or `thumbnailPhoto` attribute on your LDAP server, it will be used as their avatar. In this case the user cannot alter their avatar (on their Personal page) as it must be changed in LDAP. `jpegPhoto` is preferred over `thumbnailPhoto`. - -// note the following image does not exist anymore and cant be found, commenting out -// image::ldap-fetched-avatar.png[Profile picture fetched from LDAP, width=500] - -If the `jpegPhoto` or `thumbnailPhoto` attribute is not set or empty, then users can upload and manage their avatars on their ownCloud Personal pages. Avatars managed in ownCloud are not stored in LDAP. - -The `jpegPhoto` or `thumbnailPhoto` attribute is fetched once a day to make sure the current photo from LDAP is used in ownCloud. LDAP avatars override ownCloud avatars, and when an LDAP avatar is deleted then the most recent ownCloud avatar replaces it. - -Photos served from LDAP are automatically cropped and resized in ownCloud. This affects only the presentation, and the original image is not changed. - -== Troubleshooting, Tips and Tricks - -=== LDAPS - -Use these commands to troubleshoot: - -Test encrypted connection: - -`openssl s_client -connect 10.211.55.15:636` - -look for **verify return:1** - -Try an ldapsearch query - -[source,bash] ----- -ldapsearch \ --H ldaps://ad16.oc.local:636 \ --D "cn=Administrator,cn=users,dc=oc,dc=local" \ --b "dc=oc,dc=local" \ --w MyPassword ----- - -Check: - -`/etc/ldap/ldap.conf` -`/etc/openldap/ldap.conf` - -look for - -`TLS_CACERT /etc/ssl/certs/ca-certificates.crt` - -Turn off certificate validation for testing: - -`TLS_REQCERT ALLOW` - -=== Microsoft Active Directory - -Compared to earlier ownCloud versions, no further tweaks need to be done to make ownCloud work with Active Directory. ownCloud will automatically find the correct configuration in the set-up process. - -=== memberOf / Read MemberOf Permissions - -If you want to use `memberOf` within your filter you might need to give your querying user the permissions to use it. For Microsoft Active Directory this is described {enumerate-ad-user-groups-permissions-url}[here]. - -=== Duplicating Server Configurations - -In case you have a working configuration and want to create a similar one or "snapshot" configurations before modifying them you can do the following: - -. Go to the "**Server**" tab -. On "**Server Configuration**" choose "**Add Server Configuration**" -. Answer the question "**Take over settings from recent server configuration?**" with "**yes**". -. (optional) Switch to "**Advanced**" tab and uncheck "**Configuration Active**" in the "**Connection Settings**", so the new configuration is not used on Save -. Click btn:[Save] - -Now you can modify and enable the configuration. - -// === Performance Tips - -=== Filter out Deactivated Users - -With this filter you can filter out the deactivated users -and show only active users. - -[source,plaintext] ----- -!(userAccountControl:1.2.840.113556.1.4.803:=2) ----- - -Here is what the full filter can look like. - -[source,plaintext] ----- -(&(|(objectclass=organizationalPerson)) - (!(userAccountControl:1.2.840.113556.1.4.803:=2)) - (|(|(memberof=CN=Domain Users,CN=Users,DC=dp,DC=mosreg,DC=ru)(primaryGroupID=513))) -) ----- - -=== Caching - -Using xref:configuration/server/caching_configuration.adoc[caching] to speed up lookups. The ownCloud cache is populated on demand, and remains populated until the `**Cache Time-To-Live**` for each unique request expires. User logins are not cached, so if you need to improve login times set up a replica LDAP server to share the load. - -You can adjust the "**Cache Time-To-Live**" value to balance performance and freshness of LDAP data. All LDAP requests will be cached for 10 minutes by default, and you can alter this with the "**Cache Time-To-Live**" setting. The cache answers each request that is identical to a previous request, within the time-to-live of the original request, rather than hitting the LDAP server. - -The "**Cache Time-To-Live**" is related to each single request. After a cache entry expires there is no automatic trigger for re-populating the information, as the cache is populated only by new requests, for example by opening the User administration page, or searching in a sharing dialog. - -There is one trigger which is automatically triggered by a certain background job which keeps the `user-group-mappings` up-to-date, and always in cache. - -Under normal circumstances, all of the users are never loaded at the same time. Typically, the loading of users happens while page results are generated in steps of 30, until the limit is reached or no results are left. - -TIP: Please ensure that you're using the minimum supported PHP version ({minimum-php-printed}). - -ownCloud remembers which user belongs to which LDAP-configuration. That means each request will always be directed to the right server unless a user is defunct, for example due to a server migration or unreachable server. In this case the other servers will also receive the request. - -=== LDAP Indexing - -Turn on indexing. Deciding which attributes to index depends on your configuration and which LDAP server you are using. See {openldap-index-tuning-guide-url}[the openLDAP tuning guide] for openLDAP, and {index-attribute-in-ad-url}[How to Index an Attribute in Active Directory] for Active Directory. - -=== Use Precise Base DNs - -The more precise your base DN, the faster LDAP can search because it has fewer branches to search. - -=== Use Precise Filters - -Use good filters to further define the scope of LDAP searches, and to intelligently direct your server where to search, rather than forcing it to perform needlessly-general searches. - -=== ownCloud LDAP Internals - -Some parts of how the LDAP backend works are described here. - -=== User and Group Mapping - -In ownCloud, the user or group name is used to have all relevant information in the database assigned. To work reliably, a permanent internal user name and group name are created and mapped to the LDAP DN and UUID. If the DN changes in LDAP, it will be detected, and there will be no conflicts. - -Those mappings are done in the database table `ldap_user_mapping` and `ldap_group_mapping`. The user name is also used for the user's folder (except if something else is specified in _User Home Folder Naming Rule_), which contains files and meta data. - -The internal user name and a visible display name are separated. This is not the case for group names yet, as a group name cannot be altered. - -That means that your LDAP configuration should be good and ready before putting it into production. The mapping tables are filled early, but as long as you are testing, you can empty the tables any time. - -TIP: Do not do this in production. - -=== Handling with Backup Server - -When ownCloud is not able to contact the main LDAP server, ownCloud assumes it is offline and will not try to connect again for the time specified in "Cache Time-To-Live". If you have a backup server configured ownCloud will connect to it instead. When you have scheduled downtime, check btn:[Disable Main Server] to avoid unnecessary connection attempts. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_twofactor.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_twofactor.adoc deleted file mode 100644 index aab51a4..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_auth_twofactor.adoc +++ /dev/null @@ -1,61 +0,0 @@ -= User Two-Factor Authentication -:toc: right -:description: With two-factor authentication (2FA), users can access their ownCloud web accounts only by using an additional trusted device like their mobile phone. - -== Introduction - -{description} When users want to sign in, they need to provide two pieces of information (factors): - -* the password, -* the six-digit verification code that's automatically displayed on the trusted device or sent to the phone number. - -== Setting Up 2FA - -To provide 2FA functionality, the {oc-marketplace-url}/apps/twofactor_totp[2-Factor Authentication] app needs to be installed and enabled. Though there are other apps available, the description and screenshots refer to the named one. - -If the two-factor provider app is enabled: - -* It is enabled for all users by default but a user has to opt in. -* It can be enforced for all users as default. -* Groups of users can be excluded from using 2FA. - -image::apps/2fa/2fa-exclude-groups.png[Setup Two-Factor Authentication, width=500] - -Note that when users are forced to use 2FA, they are not able to do the setup process the same way as when using opt-in. For this case on first login after enforcing 2FA, the user is shown a special login screen where the QR code to finalize the 2FA process is displayed. - -image::apps/2fa/2fa-init-qr.png[Login Screen with QR Code for Two-Factor Authentication, width=500] - -TIP: For the opt-in and login with enforced 2FA to work, ImageMagick and php-imagick are required to create the QR code. Depending on your operating system, these packages may need to be installed manually. - -== Using 2FA with ownCloud Desktop and Mobile Apps - -ownCloud Desktop and Mobile Apps support 2FA login with browser-based login flows. - -NOTE: OAuth 2.0 is the recommended authentication method for clients. - -=== Enable OAuth 2.0 App - -When using the OAuth 2.0 App, the ownCloud Desktop client will open the login page in the system web browser and ownCloud Mobile Apps will open the login page in an embedded web view. After entering the regular credentials, users will see a second page, where they need to enter the second factor. - -For more information see the xref:configuration/user/user_oauth2.adoc[User Auth Open Authentication (OAuth2)] documentation. - -=== App Passwords / Tokens - -Without the OAuth 2.0 App, users need to log in to their ownCloud account in a regular web browser first, then create an app password or tokens, which can be used in the ownCloud Desktop and Mobile apps. - -For more information see the xref:classic_ui:personal_settings/security.adoc#app-passwords-tokens[App Passwords / Tokens] documentation. - -== Troubleshooting - -=== Tasks for the User - -Because the user has to opt in, see the xref:classic_ui:personal_settings/security.adoc[Security section in Personal Settings] for tasks on the user side. - -=== Second Factor is Inaccessible - -In case a user loses access to the second factor, e.g. by breaking or losing the phone with two-factor SMS/app verification, the user is locked out. To give the user access to the account again, an admin can temporarily disable the two-factor check _for that user_ via the xref:configuration/server/occ_command.adoc#two-factor-authentication[occ commands for Two-Factor Authentication]. After the issue has been fixed, the admin can enable two-factor authentication for that user again. - -=== Manage Secrets - -If owncloud's {oc-marketplace-url}/apps/twofactor_totp[2-Factor Authentication] is used, the admin can manage -the secrets via xref:configuration/server/occ_command.adoc#two-factor-totp[Two-Factor TOTP occ commands]. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_management.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/user_management.adoc deleted file mode 100644 index 006bddb..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_management.adoc +++ /dev/null @@ -1,252 +0,0 @@ -= User Management -:toc: right -:toclevels: 1 -:page-aliases: configuration/user/user_configuration.adoc - -:description: This page shows common tasks for administrators when managing users. - -== Introduction - -{description} - -Note that most user-related tasks can also be managed via xref:configuration/server/occ_command.adoc#user-commands[occ commands for managing users]. - -== Default View - -The **default view** displays basic information about your users. - -image::configuration/user/users-page.png[image] - -The **Group filter** on the left sidebar lets you quickly filter users by -their group memberships, and create new groups. - -image::configuration/user/users-page-group-tab.png[image] - -Click the btn:[gear] icon on the lower left sidebar to view the available settings. - -image::configuration/user/users-page-gear.png[image] - -**User accounts** have the following **properties**: - -_Login Name (Username)_:: - The unique ID of an ownCloud user. Note that it **cannot** be changed after creating the user. The user can log in either using the login name or the e-mail address. -_Full Name_:: - The user’s display name that appears on file shares, the ownCloud Web interface and emails. Admins and users may change the full name anytime. If the full name is not set, it defaults to the login name. -_Password_:: - The admin sets the new user’s first password. Both the user and the admin can change the user’s password at anytime. -_E-Mail_:: - The admin sets the new user’s e-mail. The user then gets an e-mail to set the password. Both the user and the admin can change the user’s e-mail at anytime. -_Groups_:: - You may create system (non-LDAP) groups and assign system group memberships to users. By default, new users are not assigned to any groups. -_Group Admin_:: - Group admins are granted administrative privileges on system groups and can add new users, edit user properties, and remove existing users from those groups. -_Quota_:: - The maximum disk space assigned to each user. Any user that exceeds the quota cannot upload or sync data. You have the option to include external storage in user quotas. - -== Creating a New User - -To create a user account: - -* Enter the new user’s *Login Name* and their *E-Mail* -* Optionally, assign *Groups* memberships -* Click the btn:[Create] button - -image:configuration/user/users-page-new-user.png[image] - -Login names may contain letters (a-z, A-Z), numbers (0-9), dashes (-), underscores (_), periods (.) and at signs (@). After creating the user, you may fill in their *Full Name* if it is different from the login name, or leave it for the user to complete. - -== Password Reset - -You cannot recover a user’s password, but you can set a new one: - -* Hover your cursor over the user’s *Password* field -* Click on the btn:[pencil] icon -* Enter the user’s new password in the password field, and remember to -provide the user with their password - -image::configuration/user/users-page-new-password.png[image] - -If you have encryption enabled, there are special considerations for user password resets. - -TIP: See xref:configuration/files/encryption/encryption_configuration.adoc[Encryption Configuration]. - -=== Renaming a User - -Each ownCloud user has two names: a unique *Login Name* used for authentication, and a *Full Name*, which is their display name. You can edit the display name of a user, but you cannot change the login name of any user. - -To set or change a user’s display name: - -* Hover your cursor over the user’s *Full Name* field -* Click on the btn:[pencil] icon -* Enter the user’s new display name - -== Deleting Users - -image::configuration/user/delete-user-confirmation.png[The ownCloud delete user confirmation dialog] - -To delete a user, hover your cursor over their name on the *Users* page and click the trashcan icon that appears at the far right. You’ll then see a confirmation dialog appear, asking if you’re sure that you want to delete the user. - -If you click btn:[Yes], the user is permanently deleted, including all the files owned by the user, including all files they have shared. If you need to preserve the user’s files and shares, you must first download them from their ownCloud Files page, (which compresses them into a zip file). - -Alternatively, you can use a sync client to copy them to your local computer. - -If you click btn:[No], the confirmation dialog will disappear and the user is not deleted. - -TIP: See xref:configuration/files/file_sharing_configuration.adoc[File Sharing Configuration] to learn how to create persistent file shares that survive user deletions. - -== Granting Administrator Privileges - -ownCloud has two types of administrators: - -* *ownCloud Administrators* have full rights on your ownCloud server and can access and modify all settings. To assign the ownCloud administrator role to a user, simply add them to the `admin` group. - -* *Group Administrators*. Group administrators have the rights to create, edit and delete users in their assigned system (non-LDAP) groups. Use the dropdown menus in the Group Admin column to assign group admin privileges. - -== Managing Groups - -You can assign new users to groups when you create them, and create new groups when you create new users. You may also use the btn:[Add Group] button at the top of the left pane to create new groups. New group members will immediately have access to file shares that belong to their new groups. - -== Enabling Custom Groups - -As the next step in managing groups, you can enable the Custom Groups app which provides group management to users. For details see the xref:configuration/user/custom_groups_app.adoc[Custom Groups App]. - -== Setting Storage Quotas - -There are 4 types of quota settings in ownCloud when dealing with LDAP users. - -=== Quota Field - -Found in menu:User Authentication[the Advanced Tab > Special Attributes], this setting overwrites the rest. If set, this is what will be set for an LDAP user’s quota in ownCloud. - -=== Quota Default - -Found in menu:User Authentication[the Advanced Tab > Special Attributes], this is the fallback option if no quota field is defined. - -=== User Quota - -This is what you set in the web UI drop down menu, and is how you set user quota. - -=== Default Quota - -This will be used if no quota is set and is found in menu:Users Tab[Gear Wheel > Default Quota]. If the *Quota* is not set, but *Default Quota* is, and a systems administrator tries to set a quota for an LDAP user with *User Quota*, it will not work since it is overridden by *Default Quota*. - -Click the btn:[gear] icon on the lower left pane to set a default storage quota. This is automatically applied to new users. You may assign a different quota to any user by selecting a preset value from the *Quota* dropdown or by entering a custom value. When you create custom quotas, use the usual abbreviations for your storage values such as 500 MB, 5 GB, 5 TB, and so on. - -=== External Storage Quota - -You now have a configurable option in `config.php` that controls whether external storage is counted against user’s quotas. This is still experimental and may not work as expected. The default is to not counting external storage as part of user storage quotas. If you prefer to include it, then change the default `false` to `true`.: - -[source,php] ----- -'quota_include_external_storage' => false, ----- - -=== Storage Space Considerations - -Metadata (such as thumbnails, temporary files, and encryption keys) takes up about 10% of disk space but is not counted against user quotas. Users can check their used and available space on their Personal pages. Only files that originate from a user, or are in a share owned by the user, count against that user's quota, not file shares received from other users. For example, if you upload files to a different user’s share, those files count against that user's quota. If you share a folder with other user's and they add files to that folder, then those files count against your quota. If you re-share a file that another user shared with you, that file does not count against your quota, but the originating user’s. - -Encrypted files are a little larger than unencrypted files; the unencrypted size is calculated against the user’s quota. - -Deleted files that are still in the trash bin do not count against quotas. The trash bin is set to 50% of quota. Deleted file aging is set to 30 days. When deleted files exceed 50% of quota, then the oldest files are removed until the total is below 50%. - -=== Versions - -If version control is enabled, the older file versions are not counted against quotas. - -=== Public Links - -When a user creates a public link share via URL and allows uploads, all uploaded files count against that user’s quota. - -== User GDPR Requests - -To comply with article 15 of the GDPR framework, ownCloud provides buttons in all users' personal settings view which can be accessed via menu:User Name[Settings > Personal > General > Account] to: - -* Request data export -* Request account deletion - -When a user clicks on one of these buttons, the admin group will receive an email with the user's request for further processing. - -== Moving the User Home - -Usually, a user's home folder is located in the `data/` directory, the location of which is defined in `config.php` and defaults to `/var/www/owncloud/data`. In smaller installations, the data directory is often mounted on a physical drive of the server. On larger installations, the data directory is usually mounted via NFS. This can be less than ideal for very big installations with thousands of users and/or users with very big space consumption. This can result in a high load on a single mount point. - -ownCloud offers moving the home folder location of single users from the default location to another path outside the data directory to distribute the load to different mount points. You can also move back a user's home to the location defined in config.php. - -NOTE: In general, moving a user's home should be the last step after all optimizations of the mount point have been done. Carefully monitor over a period of time the changes made before moving a user's home. - -NOTE: Consider that these new home mount points also need to be part of a xref:maintenance/backup_and_restore/backup.adoc[backup] and xref:maintenance/backup_and_restore/restore.adoc[restore] plan. - -=== Steps to Move a User's Home - -For details of the occ user commands used below, see the xref:configuration/server/occ_command.adoc#user-commands[User Commands] section of the occ command reference. The examples use the user ID `lisa` and the mount for the new home is `/mnt/newhome_1`. - -. To report a users home, use the following command: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list lisa -a home - - lisa: /var/www/owncloud/data/lisa ----- -+ -Here you can see, that the home of user `lisa` is located in `/var/www/owncloud/data/lisa` - -. Prepare new mounts *in advance* for one or more users: -+ -Use the OS methods to create one or more new mount points for users home directories not located as defined in config.php. You can create as many new homes as required containing as many new user homes as wanted - there is no ownCloud limitation. The mounts must be fully accessible by the webserver user (usually www-data). - -. Move the users home: -+ -[NOTE] -==== -* To move a users home, the target folder *must not contain* a subfolder with the user's ID. -* The target folder *can contain* other user folders. -==== -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:move-home lisa /mnt/newhome_1 ----- -+ -The user gets disconnected and the user's home is now moved which may take a while depending on the load of the server and the bandwidth available on the mount points. When the move operation has finished, -+ --- -* all data from the user is _copied_ to the new home, -* the new path is set in the ownCloud database and -* the user gets enabled again. --- -+ -After checking, the old user's home location can safely be deleted manually. -+ -NOTE: If you are using LDAP and the xref:enterprise/external_storage/ldap_home_connector_configuration.adoc[LDAP Home Connector] app, update the user's home mount in the attribute used accordingly. - -. To check the user's new home, use the following command: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:list lisa -a home - - lisa: /mnt/newhome_1/lisa ----- -+ -Here you can see that the home of user `lisa` is now located in `/mnt/newhome_1/lisa`. - -. To list the available user home root directories, use the following command: -+ -The following command lists all available user homes. Note a home only gets listed, if it contains at least one user. -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:home:list-dirs - - /var/www/owncloud/data - - /mnt/newhome_1/lisa ----- - -. To list all users from a users home root directory, use the following command: -+ -The following command lists all users from a given home. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:home:list-users /var/www/owncloud/data - - admin - - user01 ----- diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_oauth2.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/user_oauth2.adoc deleted file mode 100644 index df4890f..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_oauth2.adoc +++ /dev/null @@ -1,23 +0,0 @@ -= User Auth Open Authentication (OAuth2) -:toc: right - -== Introduction - -OAuth2 (Open Authentication) is the open industry-standard protocol for secure authorization of clients. It can be used as a way for users to grant web services or applications access to their data stored in ownCloud. The use of OAuth2 in ownCloud greatly enhances security while facilitating the integration of third party applications or web services: - -* Connect ownCloud clients (Desktop, Android, iOS) through a standardized and secure authorization flow. -* Provide a user authorization interface for developers to facilitate the integration of ownCloud in third party applications. - -== Benefits Provided by the OAuth2 Interface - -* No user passwords are being stored in ownCloud clients or third party web applications - -Instead of connecting clients with username/password, a user only needs to provide the information once in the browser. The respective client is then provided with a unique access token which is used for future connections to the ownCloud server. ownCloud clients or third party applications never get to know the actual login credentials. - -* The use of different access tokens per client provides the ability to selectively revoke user sessions - -When using OAuth2 a unique access token is generated for each device or third party application. Users can check their authorized clients in the personal settings and have the ability to selectively invalidate access tokens when e.g. a device is lost. This strengthens control and access security significantly. - -== The OAuth2 App - -OAuth2 functionality is available in ownCloud via the {oc-marketplace-url}/apps/oauth2[OAuth2] application which is available from the ownCloud Marketplace. For more information on how to set it up, see section xref:configuration/server/security/oauth2.adoc[Open Authentication (OAuth2)] diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_provisioning_api.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/user_provisioning_api.adoc deleted file mode 100644 index 31eb68d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_provisioning_api.adoc +++ /dev/null @@ -1,8 +0,0 @@ -= User Provisioning API - -== Introduction -The User Provisioning API provides instruction sets to communicate with the user backend. -External systems can use this API to create, edit, delete and query user attributes. - -== Using the User Provisioning API -See xref:developer_manual:core/apis/provisioning-api.adoc#instruction-set-for-users[User Provisioning API] for available API endpoints and detailed examples. diff --git a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_roles.adoc b/content/server/10.15/modules/admin_manual/pages/configuration/user/user_roles.adoc deleted file mode 100644 index 6da429e..0000000 --- a/content/server/10.15/modules/admin_manual/pages/configuration/user/user_roles.adoc +++ /dev/null @@ -1,101 +0,0 @@ -= ownCloud Roles -:toc: right -:toclevels: 1 -:files_pdfviewer-url: {oc-marketplace-url}/apps/files_pdfviewer -:collabora-online-app-url: {oc-marketplace-url}/apps/richdocuments - -:description: ownCloud provides several roles a user can have. This description gives an overview of these roles. - -== Introduction - -{description} - -== Anonymous - -* Is not a regular user. -* Has access to specific content made available via public links. -** Can be password-protected (optional, enforced, policy-enforced). -** Can have an expiration date (optional, enforced, enforced dependent on password). -* Has no personal space -* Has no file ownership (ownership of uploaded/created files is directed to sharer). -* Has no use of clients. -* Quota is that of the sharer. -* Permissions are those granted by the sharer for specific content, e.g., _view-only_, _edit_, and _File Drop_. -* Can only use file and viewer apps, such as {files_pdfviewer-url}[PDF Viewer] and {collabora-online-app-url}[Collabora Online]. - -== Guest - -* The {oc-marketplace-url}/apps/guests[Guests app] is available on the ownCloud Marketplace. You must install and enable it first. -* Is a regular user with restricted permissions, identified via e-mail address. -* Has no personal space. -* Has no file ownership (ownership of uploaded/created files is directed to sharer). -* Has access to shared space. The permissions are granted by the sharer. -* Is not bound to the inviting user. -** Can log in as long as shares are available. -** Becomes deactivated when no shares are left; this is the xref:shared-with-guests-filter[shared with guests filter]. -** Reactivated when a share is received. -** Administrators will be able to automate user cleanup ("*disabled for x days*"). -* Can use all clients. -* Fully auditable in the enterprise edition. -* Can be promoted to group administrator or administrator, but will still have no personal space. -* Apps are specified by the admin (whitelist). - -[[shared-with-guests-filter]] -[NOTE] -==== -.The Shared with Guests Filter -This filter makes it easy for sharers to view and remove their shares with a guest, which also removes their responsibility for guests. -When all of a guest’s shares are removed, the guest is then disabled and can no longer login. -==== - -== Standard User - -* Is a regular user (from LDAP, ownCloud user backend, or another backend). -* Has personal space. Permissions are granted by the administrator. -* Shared space: Permissions as granted by sharer. -* Apps: All enabled, might be restricted by group membership. - -== Federated User - -* Is not an internal user. -* Can trust xref:faq/index.adoc#what-is-a-federated-system[a federated system]. -* Has access to shared space through users on the considered ownCloud system. -* Can share data with the considered system (accept-/rejectable). - -== ownCloud Group Administrator - -* Is a regular user, such as from LDAP, an ownCloud user backend, or another backend. -* Can manage users in their groups, such as adding and removing them, and changing quota of users in the group. -* Can add new users to their groups and can manage guests. -* Can enable and disable users. -* Can impersonate users in their groups. -* Custom group creation may be restricted to group admins. - -== ownCloud Administrator - -* Is a regular user (from LDAP, ownCloud user backend, or another backend). -* Can configure ownCloud features via the UI, such as sharing settings, app-specific configurations, and external storages for users. -* Can manage users, such as adding and removing, enabling and disabling, quota and group management. -* Can restrict app usage to groups, where applicable. -* Configurable access to log files. -* Mounting of external shares and local shares (of external filesystems) is disabled by default. - -== System Administrator - -* Is not an ownCloud user. -* Has access to ownCloud code (e.g., `config.php` and apps folders) and command-line tool (occ xref:configuration/server/occ_command.adoc[occ]). -* Configures and maintains the ownCloud environment (_PHP_, _Webserver_, _DB_, _Storage_, _Redis_, _Firewall_, _Cron_, and _LDAP_, etc.). -* Maintains ownCloud, such as updates, backups, and installs extensions. -* Can manage users and groups, such as via xref:configuration/server/occ_command.adoc[occ]. -* Has access to the master key when storage encryption is used. -* *Storage admin:* Encryption at rest, which prevents the storage administrator from having access to data stored in ownCloud. -* *DB admin:* Calendar/Contacts etc. DB entries not encrypted. - -== Auditor - -* Is not an ownCloud user. -* Conducts usage and compliance audits in enterprise scenarios. -* App logs (especially {oc-marketplace-url}/apps/admin_audit[Auditlog]) can be separated from ownCloud log. - This separates the Auditor and Sysadmin roles. - An `audit.log` file can be enabled, which the Sysadmin can’t access. -* *Best practice:* parse separated log to an external analyzing tool. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/authentication/enterprise_only_auth.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/authentication/enterprise_only_auth.adoc deleted file mode 100644 index 1dd2e91..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/authentication/enterprise_only_auth.adoc +++ /dev/null @@ -1,235 +0,0 @@ -= Enterprise-Only Authentication Options -:toc: right -:description: ownCloud provides several authentication options for mounting storages. Depending on the edition, these options can vary. -:page-aliases: enterprise/external_storage/enterprise_only_auth.adoc - -== Introduction - -{description} - -== Authentication Options - -The following table shows which authentication option is available for which edition of ownCloud. - -{empty} - -[width="70%",cols="20%,^9%,^11%",options="header"] -|=== -| Authentication Method -| Free Edition -| Enterprise Edition - -| Username and password -| x -| x - -| Log-in credentials, save in session -| x -| x - -| Log-in credentials, save in database -| -| x - -| User entered, store in database -| -| x - -| Global credentials -| -| x - -| Credentials hardcoded in config file * -| -| x - -| Kerberos -| -| x - -| RSA public key ** -| x -| x -|=== - -(*) Note that `Credentials hardcoded in config file` will appear only if the Windows Network Drive (WND) app is installed and enabled. As long you have WND enabled, you can also use this authentication method for other mount types. If you use this authentication method with other mount types but disable WND, you will lose the connection to all the mounts where this authentication method was used. - -(**) Note that `RSA public key` is only available when selecting mount type `SFTP`. - -Use the dropdown selector to choose the authentication backend when you create a new external mount. - -image::enterprise/authentication/enterprise-only-auth/authentication-backends.png[Authentication dropdown selector,width=300] - -== Storage Implementations - -The following table shows which storage implementation can use the above authentication options. -Note that this table does not cover other storage implementations like Google Drive or One Drive etc., as those use other authentication backends. - -{empty} - -[width="60%",cols="20%,^13%,^15%",options="header"] -|=== -| Storage implementation -| Free Edition -| Enterprise Edition - -| FTP -| x -| x - -| SFTP -| x -| x - -| ownCloud -| x -| x - -| SMB/CIFS -| x -| x - -| WebDAV -| x -| x - -| Windows Network Drive -| -| x -|=== - -== Authentication Option Details - -Log-in credentials, save in session:: - Credentials are only stored in the session and not captured in the database. Files cannot be shared, as credentials are not stored. - -Log-in credentials, save in database:: - Credentials are stored in the database, and files can be shared. - -User entered, store in database:: - Users provide their own login credentials, rather than using admin-supplied credentials. User credentials are stored in the database, and files can be shared. - -Credentials hardcoded in config file:: - Used when all the users will share the same password and the password is not known to the users like for a shared space. The user ID is always taken from the session. This authentication option can also be chosen when using OAuth or OpenIDConnect, etc. For more details see xref:notes-for-credentials-hardcoded-in-config-file[Notes for Credentials Hardcoded in Config File]. Files can be shared. - -Global credentials:: - With re-usable credentials entered by the admin, files can be shared based on credentials only the admin has knowledge about. Credentials are entered in a separate form via menu:Settings[Admin > Storage] (global) or menu:Settings[Personal > Storage] (personal). -+ -image::enterprise/authentication/enterprise-only-auth/global-credentials.png[Global credentials form] - -Kerberos:: - With Kerberos authentication, users get authenticated via Kerberos tickets. ownCloud needs a Kerberos service account enabled for delegation. ownCloud credentials are not required. - -Username and password:: - This is the default; a login entered by the admin when the external mount is created. The login is stored in the database, which allows sharing and background jobs, such as file scanning, to operate. - -RSA public key:: -This authentication method is limited to SFTP only. Manually enter the public key or press btn:[Generate] in the mount form to generate one. Files can be shared. - -=== Authentication Options Allowing Sharing - -If available for sharing, the following will be shown additionally when defining the mount point: - -image::enterprise/external_storage/windows_network_drive/wnd-available-for.png[WND Sharing Options,width=350] - -This table shows which authentication option allows sharing: - -{empty} - -[width="50%",cols="50%,^25%",options="header"] -|=== -| Authentication Option -| Sharing Allowed - -| Username and password -| x - -| Log-in credentials, save in session -| - -| Log-in credentials, save in database -| x - -| User entered, store in database -| x - -| Credentials hardcoded in config file -| x - -| Global credentials -| x - -| Kerberos -| - -| RSA public key -| x -|=== - -=== Notes for Credentials Hardcoded in Config File - -In general, when using this authentication method, the user and the password used are separated. - -* The username is the same as the `user id` of the ownCloud session. + -For example, ownCloud user "Alice" with password "mysecret" (or even without password) will use "Alice" as username and the password from the config.php file to access the storage. Note that for LDAP, the `user id` is usually like _1223-cbdf-cacc-1234...,_ unless the configuration in the user_ldap app is changed. - -* The password will be fetched from a key inside the config.php file. + -For details see the section below. Even if the account doesn't have a password like OAuth or OpenIDConnect, etc., the connection with the storage will use the password from config.php. -+ -NOTE: The password will be the same for any user accessing the particular mount! - -==== Defining key/value pairs in config.php - -Key/value pairs in config.php must have the following structure: - -.Example having a single array -[source,php] ----- -'customApp.config' => 'the_password', ----- - -.Example having nested arrays -[source,php] ----- -'customApp.config' => [ - 'server1' => 'the_first_password', - 'server2' => 'the_second_password', - .... -] ----- - -customApp.config:: -The naming of this key must be a string that is valid as an array key in a PHP array like the above `customApp.config` or as another example `my.config.key`, but not any reserved ownCloud key. - -Arrays:: -You can use an array as described in the example above. When using an array, you can use as many sub-keys according your needs where the naming of the sub-key must be a string that is valid as an array key in a PHP array. -+ -The array syntax is beneficial when having more than one server (host) with a password, but keeping them together in one master key. To access a particular sub-key in the mount definition, use the following scheme: -+ -[source,plaintext] ----- -##... ----- -+ -From the example above, + -`customApp.config` corresponds to `key` and + -`server1` corresponds to `sub-key-level-1`. - - -==== Value to be entered in the mount point `config key` field - -Single array:: -Taking the single array example above to use the password for the mount, the value to be entered would be like: -+ -[source,plaintext] ----- -customApp.config ----- - -Nested arrays:: -Taking the nested array example above to use the password for the mount for the host with sub-key `server1`, the value to be entered would be like: -+ -[source,plaintext] ----- -customApp.config#server1 ----- diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/authentication/kerberos.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/authentication/kerberos.adoc deleted file mode 100644 index 196b8f4..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/authentication/kerberos.adoc +++ /dev/null @@ -1,622 +0,0 @@ -= Kerberos -:toc: right -:toclevels: 4 -:description: Kerberos is an authentication protocol and authenticates two hosts using the shared secret authentication technique. The main goal of Kerberos is to enable application authentication without the need to transmit user passwords. - -== Introduction - -{description} It will share a secret among the two hosts that only they and the Key Distribution Center (KDC) know. Kerberos builds a secure communication link between two trusted hosts across an untrusted network like the Internet, using tickets. - -With the Kerberos app, you can reuse the authentication ticket generated from a user's Windows domain login for ownCloud and access file server resources via ownCloud without re-authentication. - -== General Information - -When using the Kerberos app, the Windows login session from the user is taken to log in to ownCloud. This is very convenient, as the user does not need to re-authenticate for using ownCloud as he already has authenticated to his Domain. In addition by using the Kerberos ticket, the user can also use file resoures via the xref:enterprise/external_storage/windows-network-drive_configuration.adoc[Windows Network Drive (WND)] app without the need to re-authenticate. This generates a seamless user experience. This is done by the configuration made, which enables the webserver to make the ticket available for PHP for further processing. - -=== Kerberos Benefits - -This is a brief list of Kerberos benefits: - -* *Secure* + -Kerberos never transmits passwords over the network. - -* *Single-Sign-On* + -Kerberos only requires the user to type their password once when first authenticating the client. - -* *Trusted Third Party* + -Kerberos uses a centralized authentication server known as the Key Distribution Center (KDC) that all other devices in the network trust by default. This outsourcing ensures that sensitive information is not stored on a local machine. - -* *Mutual Authentication* + -In Kerberos, both ends of communication must be authenticated before communication is permitted. - -* *Delegated Authentication* + -Kerberos can provide delegated authentication for accessing backend systems. Delegated authentication allows to impersonate a client when accessing resources on the client’s behalf. - -* *Interoperability* + -The Kerberos V5 protocol implemented in Active Directory Domain Services is based on standards set forth by the IETF. It allows Kerberos implementations in Active Directory to interoperate with other networks in which Kerberos V5 is used for authentication. - -* *Microsoft Azure AD Kerberos* is a new authentication capability of Azure AD that allows using the Kerberos authentication protocol to authenticate against Azure AD. - -=== Kerberos Core Components - -* *Kerberos Realm* + -A logical network, similar to a domain, over which a Kerberos authentication server has the authority to authenticate a user, host or service. - -* *Key Distribution Centre (KDC)* + -Contains the Authentication Server (AS) and the Ticket Granting Service (TGS). Its main function is to be a mediator between these two, relaying messages from the AS, grants a ticket-granting ticket (TGT), then passing that to be encrypted by the TGS. The KDC for a domain is located on a domain controller. - -* *Authentication Server (AS)* + -A client authenticates themselves to the AS using a username and password login. The AS then forwards the username to the KDC that in turn grants a TGT. - -* *Ticket Granting Service (TGS)* + -When a client wants to access a service, they must present their TGT to the TGS. - -* *Service Principal Name (SPN)* + -An identifier given to a service instance to associate a service instance with a domain service account. - -=== What are Kerberos Tickets? - -The main structures handled by Kerberos are the tickets. These tickets are delivered to the users in order to be used by them to perform several actions in the Kerberos realm. There are 2 types: - -* The *TGS (Ticket Granting Service)* is the ticket which the user can use to authenticate against a service. It is encrypted with the service key. - -* The *TGT (Ticket Granting Ticket)* is granted by the KDC after the client is successfully authenticated. It is presented to the KDC to request for TGSs and is encrypted with the KDC key. - -=== Comparison Domain Authentication Versus LDAP - -* When users authenticate themselves to their desktop, the Windows OS sends their credentials to a Domain Controller which is also a Kerberos Distribution Center (KDC). The users get a ticket which can be used to authenticate to other network services. - -* When accessing an LDAP server using Kerberos authentication, the user binds to LDAP using a Kerberos ticket rather than sending a password. The LDAP server then validates the ticket and verifies that it belongs to the user trying to bind. - -* LDAP is not specific to Active Directory. Microsoft implemented LDAP as part of Active Directory capabilities to allow AD DS to work with LDAP-based applications. Kerberos is more secure than LDAP, but they are often used together in Active Directory. When you view objects in Active Directory Users and Computers (ADUC), you are authenticated with Kerberos, and then LDAP is used to query the Active Directory database efficiently and effectively. - -=== Kerberos Terms - -* Kerberos: + -Kerberos is an authentication protocol that supports the concept of Single Sign-On (SSO). In the case of HTTP, support for Kerberos is usually provided using the term "SPNEGO" authentication mechanism. - -* Kerberos Realm: + -An administrative domain for authentication is denoted by the term _realm_. In Windows, realms are called domains. Its goal is to define the restrictions on when an authentication server can authenticate a user, host, or service. This does not imply that a user and a service must be members of the same realm in order for authentication to occur: if the two objects are connected through a trust connection despite belonging to different realms, authentication can still occur. - -* Principal: + -In a Kerberos system, a Kerberos Principal represents a distinct identity to whom Kerberos can issue tickets for access to Kerberos-aware services. The "/" separator is used to separate the various components that make up principal names. The "@" character can be used to identify a realm as the name's final element. If no realm is specified, it is presumed that the Principal belongs to the default realm set in the `krb5.conf` file. - -* Users: + -A process that accesses a service on the behalf of a user. There can be multiple users within a realm. - -* Service: + -Something the user wants to gain access to. - -* GSSAPI: + -Programs can access security services through the Generic Security Service Application Program Interface(GSSAPI), which is an application programming interface (API). GSSAPI is an IETF standard. It doesn't offer any security on its own. Instead, GSSAPI implementations are offered by security-service providers. The exchange of opaque messages (tokens), which conceals the implementation detail from the higher-level application, is the distinguishing characteristic of GSSAPI applications. - -* SPNEGO: + -Client-server software uses the Simple and Protected GSSAPI Negotiation Mechanism, frequently called "spen-go," to negotiate the selection of security technology. When a client application has to log in to a remote server but neither end is certain which authentication protocols the other supports, SPNEGO is employed. The pseudo-mechanism uses a protocol to identify the available common GSSAPI mechanisms, chooses one, and then assigns all subsequent security actions to that chosen mechanism. - -* KDC: + -A Key Distribution Center is a network service that supplies tickets and temporary sessions keys; or an instance of that service or the host on which it runs. The KDC services both initial ticket and ticket-granting requests. The initial ticket portion is sometimes referred to as the Authentication Server (or service). The ticket-granting ticket portion is sometimes referred to as the ticket-granting server (or service). - -=== Overview Image - -The following image gives a brief overview about the main components and processes: - -image::enterprise/authentication/kerberos/kerberos-principle.drawio.svg[Kerberos Process Overview, width=450] - -== Server Prerequisites - -* Make sure the clocktime of the KDC, the client and the server the ownCloud instance is running on is in sync. 5 minutes are the highest difference you may allow for Kerberos to work properly. Without going into the details, you may use NTP for that task. - -* All members in the realm, which includes cients, must support `DES3, AES128 or AES256` encryption. This applies to Windows 10 and modern Linux based OS desktops. If a client does not support this encryption standard, he can not use Kerberos. Alternatively the legacy crypto `RC4-HMAC-EXP` can be added during configuration - which is _strongly discouraged_ for security reasons. See the http://web.mit.edu/kerberos/krb5-1.5/krb5-1.5/doc/krb5-admin/Supported-Encryption-Types.html#Supported%20Encryption%20Types[Kerberos supported encryption types,window=_blank] for more information. - -* Replace in the configuration examples where applicapable the placeholders accordingly: -** `` + -The name of the user account like `owncloud_spnego_user` which is used as principal. -** `` + -A complex password for ``. Remember this password as it helps debugging, but keep protected as you can access domain servcies with it. Also see: xref:keytab-files[Keytab Files] for additional info when this password needs to be changed. -** `` + -The fully qualified domain name the ownCloud instance is accessed, like `owncloud.example.com`. -** `` + -The name of the realm is taken to be the DNS domain name of the server in all *lowercase* letters like `example.com`. -** `` + -The name of the REALM is taken to be the DNS domain name of the server in all *capital* letters like `EXAMPLE.COM`. -** + -A path that is accessible by Apache like `/etc/apache2/`. -** `` + -The KDC. The Active Directory server is `dc1.example.com`. In a larger organization, two or more domain controllers for redundancy reasons can be found like `dc2.example.com` and `dc3.example.com`. -** `` + -The administration server. This is typically the same as the LDAP/Active Directory server like `dc1.example.com` or in case of multiple domain controllers, this should be normally set to the master DC. - -// https://docs.typo3.org/p/causal/ig_ldap_sso_auth/2.1/en-us/AdministratorManual/ConfigureApacheKerberos.html - -=== ownCloud Classic Side - -//// -* The host the ownCloud instance is running on must be part of the domain. -** If this is not the case, you need to https://wiki.samba.org/index.php/Setting_up_Samba_as_a_Domain_Member[Setting up Samba as a Domain Member]. -//// - -* Check that you have the latest xref:installation/manual_installation/server_prep_ubuntu_22.04.adoc#updating-pear[pear] version installed. - -* Install, if not already done the `php-dev-` environment: -+ --- -[source,bash] ----- -sudo apt install php-dev- ----- - -Check the existance of `phpize` with: -[source,bash] ----- -whereis phpize ----- --- - -* Install and enable the `php-krb5` library: -+ --- -[source,bash] ----- -sudo apt install libkrb5-dev -sudo pecl channel-update pecl.php.net -sudo pecl install krb5 ----- - -If not exists, add a file in `/etc/php//mods-available/krb5.ini` with the following content: - -[source,bash] ----- -extension=krb5.so ----- - -Finalize with: - -[source,bash] ----- -sudo phpenmod krb5 ----- - -Check with: - -[source,bash] ----- -php -i | grep Kerb ----- -[source,plaintext] ----- -Kerberos 5 support => enabled -Library version => Kerberos 5 release 1.17 ----- --- - -* Install handy command-line tools for Kerberos: + -Note that `krb5-user` is an actual requirement, the Kerberos implementation in the WND app requires the `kvno` command which is contained in that package. -+ --- -[source,bash] ----- -sudo apt install krb5-user ----- --- - -* DNS records + -Create a DNS record for the public FQDN of the ownCloud instance (``). -** If there is only a single web site on the web server, the simplest option is to make sure that the public URL of the site is the same as the FQDN of the server configured in the `/etc/hosts` configuration file. Create an A DNS record for this FQDN pointing directly to the server’s IP address. - -** However, if there are two or more web sites hosted on the same web server with different host headers, the situation becomes a bit more complicated and the DNS CNAME records and keytab file have to properly be configured. One option in this case is to use the same service account identity for all web sites hosted on the web server, configure the keytab file for the server’s own FQDN configured in the `/etc/hosts` file and create CNAME DNS aliases for the web site pointing to the server’s FQDN. The browsers will perform DNS name canonization and will request Kerberos service tickets not for the CNAME addresses of the web sites, but for the server’s own FQDN. -+ -This option can also be used if you have only one web site but want to keep the servers hostname and website address distinct. -// https://imatviyenko.github.io/blog/2018/09/11/Apache-AD-kerberos - -* Download the ownCloud Kerberos app from the {oc-marketplace-url}/apps/kerberos[Marketplace,window=_blank] and enabe it with: -+ -[source.bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable kerberos ----- - -=== Domain Controller Side - -==== Service Principal Name (SPN) - -* A Service Principle Name (SPN) is the unique, in the entire Domain Forest identity for a Service, mapped with a specific service account in a server. It is used for mutual authentication between a user and a service account. SPNs help with Kerberos authentication client applications to request service authentication for an account, even if the client doesn't have the account name. - -* Note that Kerberos depends on accurate naming, as server names are used to build the Service Principal Name (SPN) used to request tickets from a KDC. For clients, this becomes crucial when a load balancer is used, because they have, intentionally, no idea which server they are going to connect. For more details see: https://ssimo.org/blog/id_019.html[Load Balancers and Kerberos,window=_blank]. - -* A SPN consists of: `/:/`, where `` and `` are optional components. -+ -Using `HTTP`, which is a built in service class, in the configuration example below, enables that all Web applications on the same host including applications hosted by Apache, if they are configured for the use with Kerberos, will be granted tickets based on the domain user account. - -* Note that SPN always include the name of the host computer on which the service instance is running, for more details see: https://learn.microsoft.com/en-us/windows/win32/ad/service-principal-names[Microsoft: Service Principal Names,window=_blank]. - -==== Keytab Files - -* Keytab files contain pairs of Kerberos principals and encrypted keys. Any account with read permission on a keytab file can use all of the keys it contains. Access restrictions and monitoring permissions on any Kerberos keytab files used must be part of the Kerberos configuration. - -* It is recommended that a regular user account for the server in the Active Directory domain is created. It must be a user account, not a computer account. This is because, in a Microsoft Active Directory Domain, a keytab file is only generated for user accounts, not computer or service accounts. Computer and service accounts manage their own passwords. - -* Multiple service instances can not be mapped to the same user account. - -* The Keytab file entry is encrypted with the Active Directory account password. Therefore, the keytab file must be regenerated whenever the Active Directory `` password has changed. - -==== User Account - -The user account `` must be associated with the service principal name (SPN) and is used by the Kerberos domain controller to generate and verify service tickets. The SPN is derived from the URL of the service to be accessed. - -The user account should have the following properties set: - -* User cannot change password -* Password never expires - -==== Domain on Windows - -If you are running a Windows native domain, you can use the Windows Server Support Tools, `setspn` and `ktpass`. These are command line utilities enable to map the `` to the application server and its service class respectively crating a keytab file. Login as administrator to the domain controller for the next tasks. - -. Create a principal (user): + -Use the Microsoft Management Console (MMC) to create a new user account with the DNS name of the server that hosts the ownCloud instance. -.. First name: `` -.. Password: `complex-password` -.. User login name: `HTTP/@` -.. Pre-windows logon name: `` -.. _Select_ option: `Password never expires` -.. _Do not select_ this option: `User must change password at next logon` -.. In menu:Delegation[] -+ --- -* _Select_ `Trust this user for delegation to specified services only` -* _Select_ `Use any authentication protocol` -* _Add_ the service type and server(s) for delegated credentials like: + -`cifs/` + -(choose the server(s) where the smb service is provided and select cifs as service type) -+ -image:enterprise/authentication/kerberos/kerberos-win-principal.png[User Delegation, width=250] --- - -. Associate the new user with the Service Principal Name (SPN). + -To do so, open a command shell and type: -+ --- -[source,powershell] ----- -setspn -S HTTP/@ ----- - -Verify `setspn` with: - -[source,powershell] ----- -setspn -L ----- -See the https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2012-R2-and-2012/cc731241(v=ws.11)[Microsoft setspn,window=_blank] documentation for details and more parameters. --- - -. Map the account + -Map the account `` to the service principal `HTTP/@` and generate a keytab file. To do so, open a command shell and type: -+ --- -[source,powershell] ----- -ktpass - -princ HTTP/@ - -mapuser @ - -crypto AES256-SHA1 - -ptype KRB5_NT_PRINCIPAL - -pass - -out C:\temp\.keytab ----- -Note that the parameter https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/ktpass[crypto,window=_blank] is according the Microsoft documentation recommended to be set. --- - -. Move the generated keytab file `.keytab` to the Linux server hosting the ownCloud instance to location ``. Note that the file must be accessible by the web server. - -//// -To configure an SPN account for the application server on the AD domain controller, you need to use the Windows Server Support Tools, `setspn` and `ktpass`. These are command line utilities that enable you to map the server user name to the application server and its HTTP service. - -The steps to follow to configure an SPN account for an application server are: - -. Assign the SPN to the Active Directory account using the `setspn` command. -. Repeat this command for any number of SPN to the same account. -. Generate a keytab file for the user account. - -https://learn.microsoft.com/en-us/azure-stack/hci/manage/kerberos-with-spn[Kerberos with Service Principal Name (SPN)] -https://4sysops.com/archives/setspn-manage-service-principal-names-in-active-directory-from-the-command-line/[Manage SPNs from the Command Line] - -https://docs.tibco.com/pub/amx-bpm/4.3.0/doc/html/bpmhelp/GUID-6E7B3AD0-D18A-490E-ADED-2D48647CD9C7.html[Configure an SPN Account for an Active Directory Domain Controller] -//// - -==== Domain on Linux - -The following section is only necessary if the domain runs via Samba. In this case the necessary libraries have been installed which also contain the command line tool https://www.samba.org/samba/docs/current/man-html/samba-tool.8.html[samba-tool,window=_blank]. - -. Create a user for use with Kerberos: -+ --- -[source,bash] ----- -samba-tool user create -samba-tool user setexpiry --noexpiry ----- --- - -. Set the correct cipher version to be used, see https://wiki.samba.org/index.php/Generating_Keytabs[Samba Generating Keytabs,window=_blank] and https://www.samba.org/samba/docs/current/man-html/net.8.html[Samba net tool,window=_blank]: -+ --- -[source,bash] ----- -net ads enctypes list ----- - -Set `AES256-CTS-HMAC-SHA1-96` explicit, because if not set, unsecure ciphers are also enabled. - -[source,bash] ----- -net ads enctypes set 10 ----- --- - -. Configure SPN for use with Kerberos and export the keytab file: -+ --- -[source,bash] ----- -samba-tool spn add HTTP/@ ----- -[source,bash] ----- -samba-tool spn list ----- -[source,bash] ----- -samba-tool domain exportkeytab --principal=HTTP/ /.keytab ----- --- - -. Move the generated keytab file `.keytab` to the Linux server hosting the ownCloud instance to location ``. Note that the file must be accessible by the web server. - -== Configure ownCloud Classic - -Follow these steps on the server running ownCloud: - -. Configure `/etc/krb5.conf` for use with Kerberos. + -Note that only required/recommended or non-default settings are used: -+ --- -[source,plaintext] ----- -[libdefaults] - default_realm = - default_tkt_enctypes = aes256-cts-hmac-sha1-96 - default_tgs_enctypes = aes256-cts-hmac-sha1-96 - permitted_enctypes = aes256-cts-hmac-sha1-96 - forwardable = true - -[realms] - = { - kdc = - #kdc = - #kdc = - #master_kdc = - admin_server = - } - -[domain_realm] - . = - = - -[logging] - kdc = SYSLOG:NOTICE - admin_server = SYSLOG:NOTICE - default = SYSLOG:NOTICE ----- - -A description of each section and the meaning of keys is available at the http://web.mit.edu/kerberos/krb5-1.5/krb5-1.5/doc/krb5-admin/krb5.conf.html[MIT krb5.conf,window=_blank] documentation. --- -. Protect the `keytab` file so only the owner (the web server) can read it: -+ --- -[source,bash] ----- -sudo chown www-data:www-data /.keytab ----- -[source,bash] ----- -sudo chmod 0400 /.keytab ----- --- - -. Check the validity of the `keytab` file: -+ --- -[source,bash] ----- -klist -e -k -t /.keytab ----- -[source,plaintext] ----- -Keytab name: FILE:.keytab -KVNO Timestamp Principal ----- ---------------- --------------------------------------------- - 4 10/01/2023 16:23 HTTP/@ (aes256-cts-hmac-sha1-96) ----- --- - -. Display the current key version number for a principal: -+ --- -[source,bash] ----- -kvno HTTP/@ ----- -[source,plaintext] ----- -HTTP/@: kvno = 4 ----- --- - -. Attempt to use the `keytab` file to authenticate as the service principal: -+ --- -[source,bash] ----- -kinit -k -t /.keytab HTTP/@ ----- -[source,bash] ----- -klist ----- -[source,plaintext] ----- -Ticket cache: FILE:/tmp/krb5cc_0 -Default principal: HTTP/@ - -Valid starting Expires Service principal -31/10/2023 14:11 01/11/2023 00:10 /@ - renew until 01/11/2024 14:11 ----- --- - -. Destroy the Kerberos ticket for security reasons: -+ --- -[source,bash] ----- -kdestroy ----- -[source,plaintext] ----- -Tickets destroyed ----- -Note that if you issue this command during regular operation, all sessions for users using ownCloud with Kerberos will end and need to re-login. --- - -. Create a new ownCloud config file `/path-to-owncloud/config/kerberos.config.php` with the following contents or add only the comment and key to an existing `config.php` file. More Kerberos config options can be found in the xref:configuration/server/config_apps_sample_php_parameters.adoc#app-kerberos[Config Apps Sample] description: -+ --- -[source,php] ----- - '/.keytab', -]; ----- --- -A new file will be read xref:configuration/server/config_sample_php_parameters.adoc#introduction[additionally] to existing config files. See the xref:configuration/server/config_apps_sample_php_parameters.adoc[Apps Config.php Parameters] for more Kerberos configuration options. - -//// -=== Webserver Side - -* Add the following Kerberos relevant configuration to the sites definition: -+ --- -[source,apache] ----- - - AuthType Kerberos - AuthName "Kerberos for " - KrbAuthRealms - KrbServiceName HTTP - Krb5Keytab /.keytab - KrbMethodNegotiate On - KrbMethodK5Passwd Off - ----- - -See the https://modauthkerb.sourceforge.net/configure.html[mod-auth-kerb,window=_blank] documentation for more details on the settings used. --- - -* Restart Apache: -+ --- -[source,bash] ----- -sudo apachectl -k graceful ----- --- -//// - -== Browser Prerequisites - -=== Configure Google Chrome and Microsoft Edge - -.For Google Chrome and Microsoft Edge on Windows, Kerberos authentication is configured in general settings of the operating system: -{empty} - -. Open the _Control Panel_ by pressing kbd:[Win + R] and type *control*, select menu:Internet Options[Advanced]. -. On the *Advanced* tab and in the menu:Security[] section, select btn:[Enable Integrated Windows Authentication] (if it was not checked, a restart is required). -. On the *Security* tab, select menu:Local intranet[], Click btn:[Custom Level]. -. In the *User Authentication/Logon* section, select btn:[Automatic logon only in Intranet zone]. -. Click OK. -. Click menu:Sites[] and select all check boxes. -. Click *Advanced* and add, if not exists, the ownCloud website to the local zone . For example, `\https://`. -. Click btn:[Add]. - -.For Google Chrome on Linux or macOS, Kerberos authentication is configured ieither via command line parameters or policy files: -{empty} - -. Command line parameters -+ --- -[source,plaintext] ----- ---auth-server-whitelist="" ---auth-negotiate-delegate-whitelist="" ----- -You can see which policies are enable by typing `chrome://policy/` into Chrome’s address bar. --- -. Policy files -+ --- -With Linux, Chrome will also read policy files from `/etc/opt/chrome/policies/managed` directory. Add a file like `kerberos-policies.json` with the following content: - -[source,json] ----- -{ - "AuthServerWhitelist" : "", - "AuthNegotiateDelegateWhitelist" : "", - "DisableAuthNegotiateCnameLookup" : true, - "EnableAuthNegotiatePort" : true -} ----- --- - -=== Configure Mozilla Firefox - -.For Mozilla Firefox, Kerberos authentication is configured via preferences: -{empty} - -. In the browser window, enter the following URL: menu:about:config[]. -. Click Accept the Risk and Continue. -. In the Search preference name field, enter: + -`network.negotiate-auth.trusted-uris` + -and double click it. -. Specify a FQDN of the ownCloud website with a protocol, for example, `\https://`. -. Click btn:[Save]. - -=== Configure Opera - -.For Opera, Kerberos authentication is currently not possible. - -Though some research has been made, no options have been identified. This section will be updated on changes known. - -//// -must be enabled via a command line sitch - -https://support.google.com/chrome/thread/201738899/kerberos-sso-stopped-working-under-linux-after-updating-chrome-to-110?hl=en - -https://peter.sh/experiments/chromium-command-line-switches/ -//// - -== Windows Domain Login - -When users log in to the domain, the client has received the necessary Kerberos ticket, see xref:overview-image[image above], which is also available to browsers. Now, when users open a browser and try to log in to ownCloud with the Kerberos app enabled, they will see the following screen: - -image::enterprise/authentication/kerberos/kerberos-login-screenshot.png[Alternative Windows Domain Login, width=300] - -Compared to a standard login using a user name and password, the user clicks on the btn:[Windows Domain Login] button. With this button, ownCloud requests a new ticket on behalf of the Windows user logged in, which is technically a constrained delegation. With this button, the browser takes the Kerberos ticket from the client and uses it for the ownCloud login process. If the WND App is installed as well, the ownCloud service user might request later on an additional Kerberos ticket on behalf of the Windows user logged in, which is technically again a constrained delegation. - -Note that if you have not accessed a service like ownCloud via Kerberos before, Windows will show a popup to authenticate, which is a standard Windows security procedure. This can also happen if the Kerberos ticket has expired. - -Note that the text printed on the button _Windows Domain Login_ can be customized, see the xref:configuration/server/config_apps_sample_php_parameters.adoc[Apps Config.php Parameters]. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/clients/custom_client_repos.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/clients/custom_client_repos.adoc deleted file mode 100644 index 46bca38..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/clients/custom_client_repos.adoc +++ /dev/null @@ -1,4 +0,0 @@ -= Custom Client Download Repositories - -See xref:configuration/server/custom_client_repos.adoc[Custom Client Download Repositories] -to learn how to test and configure custom download repository URLs for your branded clients. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/collaboration/collabora_secure_view.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/collaboration/collabora_secure_view.adoc deleted file mode 100644 index 3c15849..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/collaboration/collabora_secure_view.adoc +++ /dev/null @@ -1,94 +0,0 @@ -= Collabora Online / Secure View -:toc: right -:secure-view-label: Secure View (with watermarks) -:page-aliases: collabora_online_integration.adoc, enterprise/collaboration/index.adoc - -== Introduction - -Collabora Online allows you to work with all kinds of Collabora office documents directly in your browser. This application can connect to a Collabora Online (or other) server (WOPI-like client) where ownCloud is the WOPI host. - -When Collabora Online is properly set up and integrated into ownCloud Classic, secure view functionality is available. Secure view is a mode where users can place limitations on files and folders that are shared. - -These limitations can include: - -* No copying -* No downloading -* No editing -* Watermarking -* Optional printing and exporting to PDF with watermarks included, which can be adjusted - -[IMPORTANT] -==== -Documents never leave the server when shared with secure view. - -Collabora Online Server opens them and streams the files to the user's browser with watermark applied (much like a video stream). Consequently, there's no way to extract the original document from the browser. -==== - -[IMPORTANT] -==== -Secure view is enforced on a received share if at least 1 share has secure view enabled. - -If a file or folder has been shared multiple times to different groups with different permissions, secure view will be enforced if at least 1 received share has secure view enabled as a result of membership in the group. This restriction propagates to any reshares. -==== - -== Prerequisites - -* ownCloud *10.3* or above -* _Enterprise Edition_ -* {oc-marketplace-url}/apps/richdocuments[ownCloud Collabora Online] app version *2.2.0* or above -* Collabora Online Server *4.0.10* or above, set up and integrated - -== Configure ownCloud for Collabora Online / Secure View - -To configure ownCloud for use with Collabora, you need to set up a WOPI server and configure ownCloud to connect with this server. You can also configure the secure view option, the watermark pattern and the secure view default open action via the command line. To do so see the -xref:configuration/server/occ_command.adoc#collabora-online-secure-view[Collabora related occ command set]. - -== How to Enable Secure View - -To enable _secure view_, navigate to menu:Settings[Admin > Additional (Admin) > Collabora Online]. At the bottom of the Collabora Online section, check btn:[Enable Secure View]. - -Once enabled, default share permissions for all users can be enabled. Currently, these default share permissions are: - -* *{secure-view-label}*. - When enabled, files are shared in secure view mode. In this mode, all the - xref:limitations-and-security-hardening[Limitations and Security Hardening] take effect. - When this mode and "_can edit_" are disabled, the share is a regular "read-only" share. -* *Can print / export PDF*. -+ --- -NOTE: This option is only visible if btn:[{secure-view-label}] is enabled. - -When enabled, this mode allows documents to be printed or exported to PDF format — with a watermark — through Collabora Online. --- - -NOTE: Admins can specify that all shares are "_secure view_" by default and that the user has to intentionally change this setting. - -== Secure View Restrictions - -When "_{secure-view-label}_" is enabled, any attempts to download the file will be blocked as shown in the screenshot below. In addition, copy & paste is disabled. - -image:enterprise/collaboration/access-denied.png[Access denied to a document when it is protected by secure view, width=80%] - -== Limitations and Security Hardening - -To make sure that the secure view feature is deployed securely and cannot be circumvented, it is important to disable the following extensions: - -* {oc-marketplace-url}/apps/onlyoffice[ONLYOFFICE] -* {oc-marketplace-url}/apps/wopi[Microsoft Office Online] -* {oc-marketplace-url}/apps/files_texteditor[Text editor] - -Additionally, you might want to _disable public link sharing_ via menu:Settings[Admin > Sharing > Allow users to share via link] so that users cannot accidentally share files publicly without secure view protection. - -== Supported File Formats - -Secure view only supports a limited number of file formats: - -* Microsoft Word (.docx) -* Microsoft Excel (.xlsx) -* Microsoft PowerPoint (.pptx) -* OpenDocument Text Document (.odt) -* OpenDocument Presentation Document (.odp) -* OpenDocument Spreadsheet Document (.ods) -* PDF - -If a folder shared with Secure View contains unsupported file types (e.g., JPG), they will not be accessible. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/collaboration/msoffice-wopi-integration.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/collaboration/msoffice-wopi-integration.adoc deleted file mode 100644 index a4de568..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/collaboration/msoffice-wopi-integration.adoc +++ /dev/null @@ -1,146 +0,0 @@ -= Microsoft Office Online / WOPI Integration -:toc: right -:toclevels: 1 -:msoffice-online-server-url: https://www.microsoft.com/en-us/microsoft-365/blog/2016/05/04/office-online-server-now-available/ -:office365-url: https://products.office.com/en-us/business/office -:wopi-protocol-url: https://docs.microsoft.com/en-us/microsoft-365/cloud-storage-partner-program/rest/ -:office-online-server-url: https://docs.microsoft.com/de-de/officeonlineserver/deploy-office-online-server -:wopi-timeout-documentation-url: https://docs.microsoft.com/en-us/microsoft-365/cloud-storage-partner-program/rest/concepts#lock-length -:tls-office: https://docs.microsoft.com/de-de/officeonlineserver/enable-tls-1-1-and-tls-1-2-support-in-office-online-server -:tls-chrome: https://help.hotschedules.com/hc/en-us/articles/360020184072-Enabling-TLS-1-2-on-web-browsers#Chrome -:shared-locked-url: https://answers.microsoft.com/en-us/msoffice/forum/all/errorthe-file-is-locked-for-shared-use/8b852d6a-c1d5-4765-8734-9b4a4ebdd3aa -:sharepoint-locked-url: https://techcommunity.microsoft.com/t5/sharepoint/quot-error-the-file-is-locked-quot-when-using-office-online/m-p/227866 - -== Introduction - -The WOPI (Web Application Open Platform Interface) app, which is bundled with ownCloud Enterprise Edition, is the connector between ownCloud server and {msoffice-online-server-url}[Microsoft Office Online Server] or {office365-url}[Office 365 (cloud)]. - -It allows Microsoft Office users to collaboratively work with Office documents in ownCloud in the browser, by connecting ownCloud with your Microsoft Office Online Server or Office 365 (cloud) via {wopi-protocol-url}[the WOPI protocol]. - - - *Microsoft Office Online Server:* To use it, you need to have a running Microsoft Office Online Server in your data center. - - *Office 365 (cloud):* To use it, you need an active Microsoft 365 subscription. - -[NOTE] -==== -Please bear in mind: - -* WOPI is only available for ownCloud enterprise. It _is not available_ in the community version. -* Out-of-the box only the on-premise version of Microsoft Office Online Server is supported. -* If you want to integrate the {office365-url}[Office 365 (cloud)] version of Microsoft Office Online, you need to {oc-support-url}[get in touch with us]. -* This app requires at minimum ownCloud Version 10.5 and php 7.1. -==== - -== Procedure using Microsoft 365 - -Apart from licensing, when using Microsoft 365, the following procedure applies, contact {oc-support-url}[ownCloud Support] for more details: - -* Customers provide ownCloud with: -** a written statement about their Microsoft 365 entitlement. -** the URL of their ownCloud instance. Only users coming from this URL will be able to use Microsoft 365. -* ownCloud provides customers with a required proxy URL to be used in the settings, see below. -** Among other things, the proxy checks if users originate from the given ownCloud Instance URL. -* When users open an office document via the ownCloud instance and Office 365 for the web is loaded, Microsoft checks if these users are already signed in via a Microsoft 365 business account. If users are not yet signed in, they will be prompted to sign in. - -== Preparing the Environment - -To use Microsoft Office for the web, you need: - -- an {office-online-server-url}[Office Online Server] locally installed, or -- an active Microsoft 365 subscription including the data provided by ownCloud, see xref:procedure-using-microsoft-365[Procedure using Microsoft 365]. - -All involved servers (Office Online Server and the ownCloud server) need to be accessible by HTTPS with valid certificates. - -== Configuring the WOPI App in ownCloud - -To configure the WOPI app in your ownCloud installation, add the following configuration to `config/config.php`, and adjust it based on the details of your setup: - -[source,php,subs="post_replacements,attributes+"] ----- -# ownCloud Support URL: {oc-support-url} - -# WOPI token: -# For Office Online Server: Replace the token with your own random string -# For Office 365 (cloud): Request the string from us -# (this has to match the `O365_PROXY_SHARED_KEY` -# configuration of the O365 proxy) -'wopi.token.key' => 'REPLACE_WITH_WOPI_TOKEN_KEY' - -# Office server URL -# For Office Online Server: Enter your https://your.office.online.server.tld -# For Office 365 (cloud): Upstream url to Microsoft O365. -# Microsoft will only accept connections from registered ownCloud domains. -# For Office 365 quality assurance upstream URL: -# https://ffc-onenote.officeapps.live.com/hosting/discovery -# For Office 365 production upstream URL: -# https://onenote.officeapps.live.com/hosting/discovery -'wopi.office-online.server' => 'https://THE_OFFICE_SERVER_URL', - -# Proxy URL -# Only for Office 365 (cloud), not needed for Office Online Server -# URL of the O365 proxy instance. -# Note that you will get a working URL from ownCloud Support -# post a written declaration that your company has an eligable -# Microsoft Business contract. -'wopi.proxy.url' => 'https://o365.example.com', - -# Enable Business Flow -# Only for Office 365 (cloud), not needed for Office Online Server -# Necessary for the O365 proxy key above. -'wopi.business-flow.enabled' => 'yes', - -# Samesite Cookie -# Only for Office 365 (cloud), not needed for Office Online Server -# Necessary to allow e.g. opening ownCloud sharing from O365. -# Use `None` if you are using OpenID Connect. -'http.cookie.samesite' => 'Lax', ----- - -== Restrict Usage to Users in a Specific Group - -Microsoft Office Online access can be restricted to users in a specific group, by use of the `wopi_group` configuration key (in `config/config.php`), as in the following example. - -[source,php] ----- -'wopi_group' => 'admin' ----- - -In the example above, only users in the `admin` group would be able to access Microsoft Office Online. - -NOTE: If the key is not defined, then all users have access to this Microsoft Office Online service connected via WOPI. - -== Locking the Document - -If you open a document with Microsoft Office Online in ownCloud, it makes use of the WebDAV file locking functionality available in ownCloud server. The idea is to lock the file so other users with access can't make changes to the document while you're editing it. - -In other words, the feature ensures that you are the "master editor". Your changes will always be the "master state". Other users can make changes, e.g., with the desktop client, but those will create conflict files for them, which can be resolved afterward. When you close the document, Microsoft Office Online unlocks the file so others can edit it. - -You can always click on the lock icon next to your file name and unlock it manually using the button in the sidebar. - -=== Lock Timeout - -If a user is editing a file and loses their internet connection, the lock will timeout, freeing the lock after 30 minutes. Refer to {wopi-timeout-documentation-url}[the WOPI documentation] for further information. - -== Known Issues - -=== Document Locks Are Not Released When Using Google Chrome - -When editing a document with Google Chrome (and Chromium) via ownCloud in Microsoft Office Online, the document lock is _not released_ when the document is closed. The document lock is only released after the 30-minute timeout or a manual lock release. To mitigate the issue, try to remember to manually unlock the document before closing it. - -More information about this issue is available in the following links: - -* The {shared-locked-url}[file is locked for shared use] -* The {sharepoint-locked-url}[file is locked when using Office Online within SharePoint Online] - -== Troubleshooting - -Checklist if something is not working: - -. **Client** can reach the **ownCloud Classic** (browse to web page and log in) -. **Client** can reach the **Office Online Server** (via hosting/discovery url with https) -. **ownCloud Classic** can reach the **Office Online Server** (via hosting/discovery url with https) -. **Office Online Server** can reach **ownCloud Classic** (browse to web page and log in) - -Make sure TLS 1.2 is being used: - -* {tls-chrome}[Enable TLS 1.2 Support in Chrome] -* {tls-office}[Enable TLS 1.2 Support in Microsoft Office Online Server] diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/document_classification/classification_and_policy_enforcement.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/document_classification/classification_and_policy_enforcement.adoc deleted file mode 100644 index ec1d3a9..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/document_classification/classification_and_policy_enforcement.adoc +++ /dev/null @@ -1,391 +0,0 @@ -= Document Classification and Policy Enforcement -:toc: right -:page-aliases: document_classification/index.adoc, \ -enterprise/classification_and_policy_enforcement.adoc, \ -enterprise/document_classification/index.adoc - -:iso_27001_url: https://www.iso.org/isoiec-27001-information-security.html -:vda_url: https://www.vda.de/de/themen/digitalisierung/daten/informationssicherheit -:novapath_url: https://www.m-und-h.de/en-novapath/ -:msft_azure_info_protection_url: https://azure.microsoft.com/en-us/services/information-protection/ -:ocis_youtube_long_url: https://www.youtube.com/watch?v=ke2QuznI_9g -:ocis_youtube_short_url: ke2QuznI_9g - -:description: When dealing with large amounts of data in an enterprise, it is essential to have mechanisms in place that allow you to stay in control of data flows. - -== Introduction - -{description} To implement such mechanisms the first step to take is to define guidelines that describe how the content of different security levels have to be treated. - -See the following in-line YouTube video for more details or use the link:{ocis_youtube_long_url}[link, window=_blank] to view it in a separate browser tab. - -.Document Classification and Policy Enforcement with ownCloud - ownCloud Conference 2018 -video::{ocis_youtube_short_url}[youtube] - -Depending on the industry, such information security guidelines can originate from regulatory requirements, from recommendations of industry associations, or they can be self-imposed if there's no external factor but internal risk management requirements that demand special treatment for specific information. - -The leading information security standard {iso_27001_url}[ISO 27001] defines guidelines for managing information security which can be certified. More specifically: - -. Information should enter an asset inventory (A.8.1.1) -. Information should be classified (A.8.2.1) -. Information should be labeled (A.8.2.2) -. Information should be handled in a secure way (A.8.2.3) - -As the leading international standard and certification for information security, ISO 27001 https://www.certificationeurope.com/app/uploads/2018/05/GDPR-ISO-27001-Mapping-Guide.pdf[covers 75-80% of the GDPR]. -This makes it the ideal framework choice to support https://gdpr-info.eu[GDPR] compliance requirements. Please see https://www.certificationeurope.com/app/uploads/2018/05/GDPR-ISO-27001-Mapping-Guide.pdf[the GDPR to ISO-27001 Mapping Guide] as an example to match the mentioned ISO Controls to the relevant _General Data Protection Regulation_ (GDPR) articles. - -Once the guidelines are set up, they need to be put into practice. First of all, highly sensitive data needs to be separated from less sensitive data. This is, usually, done by outlining the security levels present in the enterprise, and defining the criteria for information to qualify for each of these security levels. - -Typically used security levels are "_Public_", "_Internal_", "_Confidential_", and "_Strictly Confidential_", but the requirements are usually determined individually. For example, if you are seeking GDPR compliance, then administrators can add additional ones, such as "_No PID (Personally Identifiable Information)_", "_PID_", and "_Special PID_". - -The actual separation of information can then be done by requiring users to classify documents according to the security levels before they leave their workstation, or by using other criteria to assign classification levels to data during further processing. - -Based on the classification level, information can then be labeled and policies can be enforced to ensure that information is handled in a secure way - and in compliance with corporate guidelines. - -ownCloud can boost productivity with unique collaboration features. Firstly, there's "_Document Classification and Policy Enforcement_". This adds the capability to ensure that sensitive data is handled as required by information security guidelines. - -Specifically, it enables ownCloud providers to: - -* Comply with information security standards, such as {iso_27001_url}[ISO 27001/2] as {vda_url}[recommended by the German Association of the Automotive Industry (VDA)] and get certified to work securely within your value chain. -* Handle data in compliance with GDPR -* Manage risks effectively and cover potential data breaches. -* Separate information based on metadata. -* Display the data classification levels to raise user awareness. -* Prevent human mistakes when dealing with sensitive information. -* Fulfil corporate data protection requirements. - -== Classification - -Employing document classification and respective policies in ownCloud generally involves three steps, which are outlined in detail below. - -. xref:tags-for-classification[Create tags for classification] -. xref:set-up-classification-rules[Configure rules for classification (tagging)] -. xref:policy-enforcement[Associate policies to the classification rules] - -=== Tags for Classification - -Document classification levels in ownCloud are represented via xref:classic_ui:files/webgui/tagging.adoc[Collaborative Tags]. -Different categories of tags can be used to achieve different behaviors for users; these are detailed in the table below. - -.Tag Categories Available in ownCloud -[cols="15%,85", options="header"] -|=== -| Tag Name -| Description - -| Visible -| These tags are not available for classification based on metadata and feature policies because users can edit and delete them, which is undesirable in many cases - -| Restricted -| These tags can be created by administrators using xref:enterprise/file_management/files_tagging.adoc#tag-manager[Collaborative Tags Management]. -This category is recommended as it enables users to recognize the classification level of files and to be able to filter accordingly. -Additionally, certain groups of users can have the privilege to edit and assign or unassign these tags. - -| Static -| These tags can be created by administrators using xref:enterprise/file_management/files_tagging.adoc#tag-manager[Collaborative Tags Management]. -This category is recommended as it enables users to recognize the classification level of files and to be able to filter accordingly. Additionally this tag category should be used for manual classification as users in specified groups can only assign and unassign them but only administrators can edit or delete them. This way administrators can provide a tag linked to a classification policy that specified users can then impose on files. - -| Invisible -| These tags can be created by administrators using xref:enterprise/file_management/files_tagging.adoc#tag-manager[Collaborative Tags Management]. -This category is recommended when users should not be able to recognize the classification level of files or to be able to filter accordingly. -|=== - -For setting up each classification rule, create a separate tag using xref:enterprise/file_management/files_tagging.adoc#tag-manager[Collaborative Tags Management], which you can later assign to classification rules and/or policies. - -=== Automated Classification Based on Document Metadata - -Automated classification based on document metadata consists of two parts: - -. The actual classification metadata is embedded in documents using Office suite features, and also in documents using the EXIF Standard for metadata. -. Document metadata is evaluated on file upload via the web interface and all ownCloud Clients. Automated classification in ownCloud therefore takes place on file upload. Existing files containing classification metadata currently can't be classified subsequently, except via manual user interaction. - -=== Office Suite Features for Document Classification - -Microsoft Office can be extended with the {novapath_url}[NovaPath] addon, to provide classification capabilities. -Currently Microsoft Office formats (_docx_, _dotx_, _xlsx_, _xltx_, _pptx_, _ppsx_ and _potx_) are supported -LibreOffice provides an integrated classification manager (TSCP). - -To use automated classification based on document metadata, install and enable the {oc-marketplace-url}/apps/files_classifier[Document Classification] extension. The configuration depends on the tools and the classification framework in use. - -Administrators can find examples and generalized configuration instructions below. - -=== EXIF Header Metadata - -IMPORTANT: For several file types, the classification relies on the installation of `exiftool`. For details see below. - -PDF and several Image formats like JPEG, PNG, HEIC support EXIF metadata. See the documentation for a full list of https://exiftool.org/#supported[supported file formats] of exiftool. Support for EXIF was added in version 1.5.0 of the {oc-marketplace-url}/app/files_classifier[Files Classifier app]. Please note that the feature requires the installation of exiftool. - -[source,bash] ----- -sudo apt install exiftool ----- - -==== Basic Examples for Classification and Policy Enforcement - -===== Microsoft Office with Add-Ons - -Microsoft Office does _not_ provide classification capabilities out-of-the-box. To extend it, we recommend the {msft_azure_info_protection_url}[Microsoft Azure Information Protection] or {novapath_url}[NovaPath] add-ons. These extensions come with easy-to-use default classification categories, and provide the flexibility to set up custom classification schemes as desired. - -Let's assume you want to use the default classification framework provided by NovaPath. -In addition, let's assume that you take the classification level for documents classified as _Confidential_ over to ownCloud to set up a policy that prevents said documents from being accessed by users in the group "**Trainees**". - -This is how you set up an automated classification and the access policy in ownCloud: - -* As an ownCloud administrator, navigate to menu:Settings[Workflows & Tags]. - Adding a group with special privileges for the tag is optional. -* Within "User Management", create the group "_Trainees_" and add some users. -* Set up the classification rule in the panel "_Document Classification and Feature Policies_" in the same section, and set the following two properties: -** **Property XPath** = +//property[@name='Klassifizierung']/vt:lpwstr+ -** **Property Value** = +Confidential+ -+ --- -TIP: Take care, the property and value fields are case-sensitive! --- -* For "_Tag_", choose btn:[Class: Confidential]. -* Don't tick a policy checkbox as you don't want to set up a feature policy but an access policy. -* Hit btn:[Save]. -* Set up the access policy in menu:Settings[Security]. -* In the panel "_File Firewall_" enter a name for the group of rules like `Confidential` (optional). Hint: first click btn:[Add group] if you already have other rules configured. -* From the drop-down menu, choose btn:[System file] tag. In the tag picker, choose btn:[Class: Confidential]. - Now you should have `[System file tag] [is] [Class: Confidential]`. -* To add the group restriction, click btn:[Add rule], choose btn:[User group] from the drop-down menu. In the group picker drop-down, choose btn:[Trainees]. Now you should have `[User group] [is] [Trainees]`. -* Hit btn:[Save Rules] to put the rules in place. -* To verify that the rule is in place, upload a classified file and check for the tag. Then share it with a member of the group "Trainees" (or with the whole group) and try to access it from a user account that is a member of said group. - -===== LibreOffice - -https://help.libreoffice.org/Writer/Document_Classification/tr[LibreOffice implemented the open standards] produced by TSCP (_Transglobal Secure Collaboration Participation, Inc._): - -- The https://www.tscp.org/wp-content/uploads/2013/08/TSCP_BAFv1.pdf[Business Authentication Framework (BAF)] specifies how to describe the existing policy in a machine-readable format -- The https://www.tscp.org/wp-content/uploads/2013/08/TSCP_BAILSv1.pdf[Business Authorization Identification and Labeling Scheme (BAILS)] defines how to refer to such a BAF policy in a document - -There are three default BAF categories that come with different classification levels, which can be used out-of-the-box: - -- Intellectual Property -- National Security -- Export Control - -Assume you want to use the BAF category "_Intellectual Property_" and take the classification level for documents classified as "_Confidential_" over to ownCloud, to set up a policy that prevents said documents from being shared via a xref:classic_ui:files/public_link_shares.adoc[public link]. -This is how you set up an automated classification and the feature policy in ownCloud: - -* As an ownCloud administrator, navigate to menu:Settings[Workflows & Tags]. Adding a group with special privileges for the tag is optional. -* Scroll down to the panel _Document Classification and Feature Policies_: -+ -image:enterprise/classification/document_classification.png[Document Classification and Feature Policies,width=450] -* Set up the classification rule and feature policy: -** **Property XPath** = +//property[@name='urn:bails:IntellectualProperty:BusinessAuthorizationCategory:Name']/vt:lpwstr+ -** **Property Value** = +Confidential+ + -(Take care, the property and value fields are case-sensitive!) -** For "_Tag_" choose btn:[Class: Confidential]. -** Tick the checkbox btn:[Prevent link sharing]. -** Hit btn:[Save]. -* To verify that the rule is in place, upload a classified file, check for the tag and try to create a public link share. - -===== EXIF Metadata - -The available elements in EXIF metadata can vary depending how the file was created. - -* Software creating PDF documents may embed their name: + -**Property XPath** = +//xmp:CreatorTool+ + -**Property Value** = +Adobe InDesign 15.0 (Macintosh)+ - -* Photo cameras may embed the Product name: + -**Property XPath** = +//IFD0:Model+ + -**Property Value** = +Canon EOS 40D+ - -* Screenshot or graphics software may have: + -**Property XPath** = +///PNG:Software+ + -**Property Value** = +gnome-screenhot+ -+ -**Property XPath** = +//PNG:Comment+ + -**Property Value** = +Created with GIMP+ - -== General Approach - -Apart from the concrete examples above, a generalized method to employ document classification is available below. - -=== Find the Metadata Properties and Values - -- Classify a document in LibreOffice/MS Office and save it in an MS Office format. -- Rename the document's file extension to "_.zip_" and open it. -- Find the file `docProps/custom.xml` in the archive and open it with a text editor. -- Within `custom.xml`, find the property that contains the classification level value. -- Note down the classification property and value. -- Repeat the steps for all classification properties and values you want to set up classification rules for in ownCloud. - -==== Finding Metadata in PDF or Images - -* The command line tool `exiftool` can be used to inspect a file for suitable metadata. -* The output of `exiftool -n -q -b -X example.pdf` shows the metadata XML syntax. Use the XML element names to generate XPath queries and XML element data for the Property Value. -* The metadata may use XML namespaces. In `xmp:CreatorTool` the namespace is `xmp`. -* We can use more complex XPath expressions to match the `CreatorTool` like in any namespace or by prefix: + -**Property XPath** = +//*[local-name()='Comment']+ + -**Property Value** = +Created with GIMP+ -+ -**Property XPath** = +//*[local-name() = 'CreatorTool']+ -+ -**Property XPath** = +//*[starts-with(local-name(), 'Creator')]+ - -Note that other XPath selectors than `local-name()` or `starts-with` are currently not supported. - -=== Set Up Classification Rules - -* As an ownCloud administrator, navigate to menu:Settings[Workflows & Tags] -* In the panel _**Document Classification and Feature Policies**_ set up the rules: -** **Property XPath**: Enter the XPath that identifies the classification property. - Below you find a generalized example where `classification-property` is a placeholder for the property to evaluate. -+ --- -[source,plaintext] ----- -property[@name='classification-property']/vt:lpwstr ----- --- -** **Property Value**: Enter the value that triggers the classification rule when it matches with the metadata of an uploaded document, e.g., `Confidential`. - Take care, the property and value fields are case-sensitive. -** **Tag**: Choose the tag to apply to files when a match occurs. -* Repeat the steps to create classification rules for all desired properties and values - -=== Automated Classification Based on File or User Properties - -Apart from automated classification based on document metadata, uploaded files may also be classified according to criteria inherent to files or to the users uploading them, making use of the xref:enterprise/file_management/files_tagging.adoc[Workflow] extension. - -* Administrators may add rules for automated classification of files according to a file's size or file type. -* File uploads by specific users, devices, or source networks can be used as indicators for classification. -* Furthermore, administrators can define shared folders to automatically classify files uploaded to such folders, by tagging the respective folder and creating a _Workflow_ rule based on the chosen _System file tag_. -* Additionally, the rules may be linked to achieving a more granular classification behavior (e.g., PDF files uploaded by a specific group of users should be classified as _Confidential_). - -Assume you want to automatically classify all PDF documents uploaded by users that are members of the "**Management**" group. You can construct a workflow rule using the following steps: - -* Within user management create the group "_Management_" and add some users. -* Navigate to menu:Settings[Workflows & Tags]. -* In the xref:enterprise/file_management/files_tagging.adoc#tag-manager[Collaborative Tags Management] panel, create a tag of type "_Static_" and call it `Class: Confidential`. - Adding a group with special privileges for the tag is optional. -* In the panel "_Workflow_" you can now set up the classification rules. Hit btn:[Add new workflow] and specify a useful name. - Now configure the conditions that trigger the classification once they are met. - For that choose "_User group_" from the drop-down menu, click btn:[\+], then choose "_File mimetype_" and click btn:[+] again. - Then you have to provide the group "_Management_" and the MIME type for PDF (`application/pdf`) in the respective fields. -* Select the tag btn:[Class: Confidential] to be added when the rules match. -* Click btn:[Add workflow] to save and enable it. - -NOTE: For more information, please check the options available for auto-tagging and consult the -xref:enterprise/file_management/files_tagging.adoc[Workflow Extension documentation]. -For files classified with the _Workflow_ extension, administrators can impose feature and access policies -as described in the next section. - -=== Manual Classification - -As a further measure, it is possible to supply tags for users to autonomously classify all types of files in their own or shared spaces. - -- As an ownCloud administrator, create a group within user management and add the users that should be able to classify files. -- Then navigate to menu:Settings[Workflows & Tags]. -- In the xref:enterprise/file_management/files_tagging.adoc#tag-manager[Collaborative Tags Management] panel, create a tag of type "_Static_" and give it a meaningful name. - Then assign the group you created, in the beginning, to give its users special privileges for the tag. -- Users that are not a member of the specified group(s) will only be able to see the respective tag but can't alter or assign/un-assign it. - -For files that are classified manually, administrators can impose feature and access policies as described in the next section. - -== Policy Enforcement - -ownCloud currently provides two types of policies that can be enforced based on classification, _Feature_ and _Access_ policies. -These policies can be imposed independently of the classification mechanism. -The following sections illustrate the available policies and explain how they can be applied to classified contents. - -=== Feature Policies - -Feature policies are restrictions that prevent users from using a feature or force them to use it in a certain way. -They are provided by the {oc-marketplace-url}/apps/files_classifier[Document Classification] extension, which currently supports the following policies: - -- xref:prevent-upload[Prevent Upload] -- xref:prevent-link-sharing[Prevent Link Sharing] -- xref:unprotected-links-expire-after-x-days[Unprotected Links Expire After X Days] - -=== Prevent Upload - -To follow guidelines that prevent data of certain classification levels (e.g., "_strictly confidential_") from being used in ownCloud at all, the "_Prevent upload_" policy is the right instrument to use. -To impose such policies, tick the checkbox associated with the classification rule for the respective classification level. - -When trying to upload documents caught by the policy, users will get an error message: `A policy prohibits uploading files classified as ''`, where `` is the tag chosen for the classification rule. - -NOTE: Even though the server won't accept the uploaded files, in the end, it is mandatory to configure a tag -for the classification rule to work. - -=== Prevent Link Sharing - -The prevent link sharing policy is tasked to ensure that classified data of certain confidentiality levels can't be shared publicly. -This way, users can collaborate on the data internally, but it can't leave the company via ownCloud. -To enable such policies, tick the checkbox associated with the classification rule for the respective classification level. - -Documents with the associated classification level: - -- Can't be shared via link (_public links on single files and folders containing classified files_); and -- Can't be moved to a publicly shared folder. - -In all cases the user will see an error message containing the reasoning and the respective file(s): -`The file(s) "**, **" can't be shared via public link (classified as )`, where `` is the tag chosen for the classification rule. - -=== Unprotected Links Expire After X Days - -The policy _Unprotected links expire after X days_ enables administrators to define public link expiration policies depending on the classification levels of the data that is shared via public links without password protection. - -This makes it possible, for instance, to allow documents classified as _public_ to be shared via public links for 30 days while documents classified as _internal_ require public links to expire after seven days. -To enable such policies, just define an expiration period associated with the classification rule for the respective classification level. - -NOTE: The xref:configuration/server/security/password_policy.adoc[Password Policy] -extension also provides options to enforce public link expiration depending on whether the user sets -a password or not. - -The option "_X days until link expires if password is not set_" is mutually exclusive with this policy. -When you enable the Password Policy option, it will always be dominant and effectively override the policy discussed in this section. -In contrast, the Password Policy option "_X days until link expires if password is set_" can be used in parallel. - -NOTE: The xref:configuration/files/file_sharing_configuration.adoc[Sharing settings option] provides the means to define a general public link expiration policy. -This option currently is also mutually exclusive and will always override the policy discussed in this section. - -=== Setting Up Policies Without Automated Classification Based on Document Metadata - -All policies can also be enforced when using xref:manual-classification[Manual Classification] or xref:automated-classification-based-on-file-or-user-properties[Automated Classification based on File or User Properties]. -For this, specify the tag that determines the files that the policy should apply to and leave the fields for "_Property XPath_" and "_Property Value_" empty. -Then choose the desired policy and click btn:[Save]. - -== Access Policies - -Access policies are restrictions that prevent users or groups of users from accessing specific resources even though they appear in their file list, e.g., via a share from another user. -They are provided by the xref:enterprise/firewall/file_firewall.adoc[File Firewall] extension which currently supports policies to prevent access to classified documents. - -To link access policies with classification levels, the bottom line of such policies is the associated classification tag (`[System file tag] [is] []`). -It can, for instance, be combined with the following conditions to realize exclusive (`[is]`) or inclusive (`[is not]`) policies: - -Documents with the respective classification tag can't be accessed: - -* _User group_: by users that are a member of the configured group (or can only be accessed by users that are a member of the configured group when using the `[is not]` operator). -* _User device_: from the configured device(s) (or only from the configured devices when using the `[is not]` operator) -* _Request time_: within the configured time frame (or only within the configured time frame when using the `[is not]` operator) -* _IP Range (Source network)_: from the configured IP range (or only from the configured IP range when using the `[is not]` operator) - -== Logging - -When classified documents are uploaded, log entries will be written to ownCloud's log file, (`data/owncloud.log`). -For this, it is possible to additionally specify another metadata property that will be used to add its value to the log entries in the form of a "**Document ID**". - -With this, it is possible to filter the log according to a document identifier or to forward classification events for certain documents to external log analyzers. -To set it up, add the desired property XPath to the "_Document ID XPath_" field of the respective rule as you did for the classification property. - -Each uploaded file will generate three entries with different log levels. -See some exemplary entries below: - -[source,plaintext] ----- -INFO: "Checking classified file 'confidential.xlsx' with document id '2'" -INFO: "Alice uploaded a classified file 'confidential.xlsx' with document class 'Confidential'" -DEBUG: "Assigning tag 'Class: Confidential' to 'confidential.xlsx'" ----- - -== Limitations - -=== Automated Classification Based on Document Metadata: Handling Classification Changes for Existing Files - -- When a formerly classified document is replaced with a new version that does not contain classification metadata, the classification tag will remain assigned, and configured policies will still apply. - In this case, it is recommended to either delete the original or upload the new version with a different name. -- When a formerly unclassified document is replaced with a new version that does contain classification metadata, the classification tag will be assigned. However, when the policy "**Prevent upload**" is set up in addition, the original file will be deleted, and the new version will be rejected due to the policy. - diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/ldap_home_connector_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/ldap_home_connector_configuration.adoc deleted file mode 100644 index 81bbef5..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/ldap_home_connector_configuration.adoc +++ /dev/null @@ -1,130 +0,0 @@ -= LDAP Home Connector -:toc: right - -== Introduction - -The {oc-marketplace-url}/apps/files_ldap_home[LDAP Home Connector] app enables you to configure your ownCloud server to display your users’ Windows home directories on the ownCloud Files pages view, just like any other folder. - -Typically, Windows home directories are stored on a network server in a root folder, such as Home, which then contains individual folders for each user. - -.Directory Structure User Home Share ----- -Home - user_1 - user_2 - ... ----- - -The Windows home directory can be published as a share and due to the permissions set, any user can only see his personal home folder. - -To integrate a user's home folder from Windows into ownCloud, the Home share is locally mounted. An LDAP attribute is added to the user's profile containing the path of the local mount and then used by the LDAP Home Connector to show the user's home in ownCloud. - -// Based on the kroki extension. -image:enterprise/external_storage/ldap-home-connector/ldap-home-connector-diagram.png[] -//// -[ditaa, "LDAP User Home diagram"] ----- - +---------------+ +------------------+ - | Windows Share |<---(local cifs mount)----| OS | - | Home | | /mnt/share/users | - +---------------+ | | - ^ +------------------>| | - | | +------------------+ - | | (same value) ^ - | | | - | | | - | | | - v | v - +------------------+ | +---------------------+ - | User Profile |<----+ | LDAP Home Connector | - | | | | - | LDAP | | LDAP | - | Attribute |--------(Attribute)----->| Attribute | - | | | | - | /mnt/share/users | | /mnt/share/users | - +------------------+ +---------------------+ - ^ ^ - | | - v v - +----------------+ +---------------------+ - | AD | | LDAP Integration | - | | | | - | LDAP |<----------------------->| LDAP | - +----------------+ +---------------------+ - ^ - | - +-----------------------+ - | - v - +----------------+ - | ownCloud | - | | - | Files View | - | | - | user home | - +----------------+ ----- -//// - -== Prerequisites - -The following prerequisites are required: - -* Mounting cifs is available on the server where ownCloud is installed -* The {oc-marketplace-url}/apps/user_ldap[LDAP Integration] app is enabled and has a working LDAP/Active Directory configuration in ownCloud. - -* The {oc-marketplace-url}/apps/files_ldap_home[LDAP Home Connector] app is installed. - -== Configuration - -The configuration is done in several steps: - -. Mount the root Windows home directory to the ownCloud server -. Configure Active Directory/LDAP by adding a LDAP attribute to the user profile -. Use the LDAP Home Connector app to connect it to ownCloud - -=== Mount the Home Directory - -For enhanced security, create a file where the credentials are stored accessing the cifs share like: - -[source,plaintext] ----- -/etc/credentials ----- - -with the username and password on separate lines, replacing the values according your setup: - -[source,plaintext] ----- -username=winhomeuser -password=winhomepassword ----- - -Create an entry in `/etc/fstab` for the remote Windows root home directory mount and use the credentials file created above, substitute and adapt your parameters and filenames: - -[source,plaintext] ----- -//192.168.1.58/home /mnt/share/users cifs credentials=/etc/credentials,uid=33,gid=33 ----- - -=== Configure the LDAP Server - -In Active Directory, open the user profile. Scroll to the *Extensions* section and open the *Attribute Editor* tab. - -image:enterprise/external_storage/ldap-home-connector/ldap-home-connector-2.png[Active Directory Attribute editor.] - -Use any LDAP attribute that is not already in use (UserSharedFolder in this instance) and click *Edit*. Enter the user's home directory. - -image:enterprise/external_storage/ldap-home-connector/ldap-home-connector-3.png[Editing the LDAP attribute.] - -Save your changes. - -=== Configure the LDAP Home Connector - -* Enable the LDAP Home Connector app. -* Go to the LDAP Home Connector form on your ownCloud admin page. In the *Display folder as:* field enter the name as you want it to appear on your users’ File pages. -* In the *Attribute name:* field enter the LDAP attribute name from above that contains the home directory and press btn:[Save]. - -image:enterprise/external_storage/ldap-home-connector/ldap-home-connector-1.png[LDAP Home Connector configuration.] - -The Windows user's home directory is now available to the user when they log on in ownCloud. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/sharepoint-integration_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/sharepoint-integration_configuration.adoc deleted file mode 100644 index ecafe73..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/sharepoint-integration_configuration.adoc +++ /dev/null @@ -1,117 +0,0 @@ -= Configuring SharePoint Integration -:toc: right - -== Introduction - -Native SharePoint support has been added to the ownCloud Enterprise -edition as a secondary storage location for SharePoint 2007, 2010 and -2013. When this is enabled, users can access and sync all of their -SharePoint content via ownCloud, whether in the desktop sync, mobile or -Web interfaces. Updated files are bi-directionally synced automatically. -SharePoint shares are created by the ownCloud admin, and optionally by -any users who have SharePoint credentials. - -The ownCloud SharePoint plugin uses SharePoint document lists as remote -storage folders. ownCloud respects SharePoint access control lists -(ACLs), so ownCloud sharing is intentionally disabled for SharePoint -mountpoints. This is to preserve SharePoint ACLs and ensure content is -properly accessed as per SharePoint rules. - -The plugin uses the Simple Object Access Protocol (SOAP) and WebDAV for -the uploads and downloads to talk to SharePoint servers. Your ownCloud -server must have the php modules `php-phpseclib` and `php-soap` installed -and the SOAP module enabled with `phpenmod soap`. A webserver restart may be required after adding/changing php modules. - -The supported authentication methods are: - -* Basic Auth -* NTLM (Recommended) - -== Creating a SharePoint Mount - -Enable the SharePoint app, and then enter the `Admin` panel to set up -SharePoint connections in the `SharePoint Drive Configuration` section. - -Enter your SharePoint Listing credentials. These credentials are not -stored in the database, but are used only during plugin setup to list -the Document Libraries available per SharePoint site. - -image:enterprise/external_storage/sharepoint/sharepoint-1.png[Listing and global credentials.] - -`Global credentials` is optional. If you fill in these fields, these -credentials will be used on all SharePoint mounts where you select: -*Use global credentials* as the authentication credentials. - -image:enterprise/external_storage/sharepoint/sharepoint-2.png[Creating a new mountpoint.] - -Enter your ownCloud mountpoint in the `Local Folder Name` column. This -is the name of the folder that each user will see on the ownCloud -filesystem. You may use an existing folder, or enter a name to create a -new mount point - -Select who will have access to this mountpoint, by default *All users*, -or a user or a group. - -Enter your SharePoint server URL, then click the little refresh icon to -the left of the `Document Library` field. If your credentials and URL -are correct you’ll get a dropdown list of available SharePoint -libraries. Select the document library you want to mount. - -image:enterprise/external_storage/sharepoint/sharepoint-3.png[Selecting auth credentials.] - -Select which kind of Authentication credentials you want to use for this -mountpoint. If you select *Custom credentials* you will have to enter -the credentials on this line. Otherwise, the global credentials or -the user’s own credentials will be used. Click Save, and you’re done - -== Enabling Users - -You may allow your users to create their own SharePoint mounts on their -Personal pages, and allow sharing on these mounts. - -image:enterprise/external_storage/sharepoint/sharepoint-4.png[Allow user SharePoint mounts.] - -== Note - -Speed up load times by disabling file previews in `config.php`, because -the previews are generated by downloading the remote files to a temp -file. This means ownCloud will spend a lot of time creating previews for -all of your SharePoint content. To disable file previews, add the -following line to the ownCloud config file found in -`/owncloud/config/config.php`: - -[source,php] ----- -'enable_previews' => false, ----- - -== Troubleshooting - -=== Unsharing - -SharePoint unsharing is handled in the background via Cron. If you -remove the sharing option from a SharePoint mount, it will take a little -time for the share to be removed, until the Cron job runs. - -=== Logging - -Turn on SharePoint app logging by modifying `config/config.php`, setting -`sharepoint.logging.enable` to `true`, as in the example below. - -[source,php] ----- -'sharepoint.logging.enable' => true, ----- - -=== Mount Points - -Global mount points can’t be accessed: You have to fill out your -SharePoint credentials as User on the personal settings page, or in the -popup menu. These credentials are used to mount all global mount points. - -Personal mount points can’t be accessed: You have to fill your -SharePoint credentials as User on the personal settings page in case -your personal mount point doesn’t have its own credentials. - -A user can’t update the credentials: Verify that the correct credentials -are configured, and the correct type, either global or custom. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/windows-network-drive_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/windows-network-drive_configuration.adoc deleted file mode 100644 index 9673cd2..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/windows-network-drive_configuration.adoc +++ /dev/null @@ -1,944 +0,0 @@ -= Windows Network Drive (WND) -:toc: right -:toclevels: 3 -:page-aliases: enterprise/external_storage/index.adoc -:description: The Windows Network Drives app seamlessly integrates Windows and Samba/CIFS shared network drives as external storages. WND has great advantages compared to standard SMB access. - -:anacron-examples: http://www.thegeekstuff.com/2011/05/anacron-examples -:flock-docs-url: https://linux.die.net/man/2/flock -:shell-flock-intro: https://linuxaria.com/howto/linux-shell-introduction-to-flock -:msft-security-bulletin-ms17-010-url: https://docs.microsoft.com/en-us/security-updates/SecurityBulletins/2017/ms17-010 -:samba-478-url: https://www.samba.org/samba/history/samba-4.7.8.html -:samba-481-url: https://www.samba.org/samba/history/samba-4.8.1.html -:samba-url: https://www.samba.org/ -:smb2-url: https://en.wikipedia.org/wiki/Server_Message_Block#SMB_2.0 -:smbclient-manpage-url: https://www.samba.org/samba/docs/man/manpages-3/smbclient.1.html -:wannacry-ransomware-attack-url: https://en.wikipedia.org/wiki/WannaCry_ransomware_attack -:acl-url: https://en.wikipedia.org/wiki/Access-control_list -:password-lockout-policies-url: https://docs.microsoft.com/en-us/previous-versions/tn-archive/dd277400(v=technet.10) -:manage-systemd-services-url: https://www.digitalocean.com/community/tutorials/how-to-use-systemctl-to-manage-systemd-services-and-units -:base64-url: https://www.base64decode.org/ -:vaultproject-url: https://www.vaultproject.io -:hashicorp-url: https://learn.hashicorp.com/collections/vault/getting-started -:pass-url: http://xmodulo.com/manage-passwords-command-line-linux.html - -== Introduction - -{description} - -The {oc-marketplace-url}/apps/windows_network_drive[Windows Network Drives app] creates a control panel in your Admin page. Any Windows file share and Samba servers on Linux and other Unix-type operating systems use the SMB/CIFS file-sharing protocol. The files and directories on the SMB/CIFS server will be visible on your Files page just like your other ownCloud files and folders. - -Compared to standard SMB access, WND has advanced features like: - -. User lockout prevention and password reset -. More authentication mechanisms against the backend like xref:enterprise/authentication/kerberos.adoc[Kerberos] -. Listen to change information triggered by the backend -. Enhanced ACL support -. Collaborative WND (CWND) - -.Brief Description of Advanced Features: - -User lockout prevention and password reset:: -Depending on the Windows or Samba policy, users could get locked out of their account if they enter a wrong password a number of times. The lockout prevention tries to avoid this from happening by resetting the password if it is wrong. This is also true for Collaborative WND when using `login credentials saved in database` and a repeatedly running files-scan job which may use outdated credentials. In the case of ownCloud's standard SMB connector, the password won't be reset. It could happen that users get locked out of the file server. - -More authentication mechanisms against the backend:: -Please see the details about the xref:enterprise/external_storage/enterprise_only_auth.adoc[Enterprise-Only Authentication Options]. - -Listen to change information triggered by the backend:: -Native Windows file servers provide the ability to send change notifications regarding modified files and folders somewhere in a share. On the other hand, SMB can send change notifications as well, as long as all the change actions are performed through the SMB protocol. However, for Samba this won't work if the action is performed directly inside the filesystem used by Samba. Additionally, there are some technical limitations that prevent using the Samba notification capability. With the implementation of ownCloud's listener, the benefits of both worlds are available for proper change notifications. This listener updates the ownCloud database on changes and provides the changes made to accessing users. Users do not need to manually check for changes in all possible locations of their mount. Changes processed are also propagated to sync clients automatically. - -Enhanced ACL support:: -With enhanced ACL support, both SMB and WND evaluate the file attributes (whether the file is hidden or read-only) to decide what ownCloud permissions the file or folder should have in ownCloud. On top of this, WND can also evaluate the ACLs by using the `ocLdapPermissionManager` in the mount point configuration. This will bring more accurate permissions to ownCloud, especially when each user can have different permissions for the files in Windows. Consider when using CWND, only the default `nullPermissionManager` can be used. - -Collaborative WND (CWND):: -Compared to a standard WND mountpoint, a collaborative WND mount offers enhanced features. In a CWND, each user shares the same ownCloud internal information for files and folders based on its internal identification (file_id). This means that _comments_ and _tags_ can be shared with all users accessing files and folders of this mount without the need that users must be members of the mount from an ownCloud point of view. A CWND can only be set by an admin in menu:Settings[Admin > Storage] but not in the users section. With CWND, all accessing users have their own access to the mount with their own credentials but share additional information with other users accessing the same data. See the table below to compare the differences. -+ --- -{empty} - -.Collaborative WND Differences Based on the Mount Type -[cols=".^15%,.^35%,.^35%",options="header",caption=] -|=== -| -^| Windows Network Drive -^| Windows Network Drive (collaborative) - -h| Login Credentials -a| * User credentials + -* Credentials of the sharer -a| * `Log-in credentials, saved in session` + -* `Log-in credentials, saved in database` + -* `User entered, stored in database` - -h| File ID -| Unique per user or from the sharer -| Same for all users accessing this mount - -h| Access Rights -| From the accessing user or the sharer -| From the accessing user - -h| Activities + -Comments + -Tags -a| * No shared access + -** Visibility limited to the user + -* Shared access + -** Comments and tags are shared, access based on the sharer -| Comments and tags are shared, access based on the user -|=== --- - -.More WND Properties -Mounts to a Windows or Samba file server are labeled with a little four-pane Windows-style icon, and the left pane of your Files page includes a Windows Network Drive filter. - -Files are synchronized bidirectionally, and you can create, upload and delete files and folders. ownCloud server admins can create Windows Network Drive mounts and optionally allow users to set up their own personal Windows Network Drive mounts. - -Depending on the authentication method, passwords for each mount are encrypted and stored in the ownCloud database, using a long random secret key stored in `config.php`. This allows ownCloud to access the shares when the users who own the mounts are not logged in. This access will not work if the mount is session based, where passwords are not stored and are available only for the current active session. In case other users are granted access to this mount, they will see a red triangle with an exclamation mark on the bottom right of the mount icon identifying lack of access. - -== Installation - -Install the {oc-marketplace-url}/apps/windows_network_drive[External Storage: Windows Network Drives app] from the ownCloud Market App or ownCloud Marketplace. To make it work, a few dependencies have to be installed. - -* A Samba client. This is included in all Linux distributions. On Debian, Ubuntu, and other Debian derivatives it is called `smbclient`. On SUSE, Red Hat, CentOS, and other Red Hat derivatives it is `samba-client`. -* `php-smbclient` (version 0.8.0+). It should be included in most Linux distributions. You can use https://github.com/eduardok/libsmbclient-php#installation-from-pecl[Installation from PECL], if your distribution does not provide it or if you want to use a more updated version than the one provided by the OS. See xref:installation/manual_installation/server_prep_ubuntu_22.04.adoc#updating-pear[Updating pear] for a necessary prerequisite. -* `which` and `stdbuf`. These should be included in most Linux distributions. - -To install and configure the necessary packages, see the xref:installation/manual_installation/manual_installation.adoc#prepare-your-server[Prepare Your Server] section of the manual installation documentation. - -TIP: For more information on SMB/CIFS in ownCloud, refer to the xref:configuration/files/external_storage/smb.adoc[Samba file server configuration documentation]. - -TIP: If you encounter errors when using the WND app like `NT_STATUS_REVISION_MISMATCH`, please get in touch by {oc-support-url}[Opening a Service Request]. - -[IMPORTANT] -==== -ownCloud requires at least {samba-478-url}[Samba 4.7.8] or {samba-481-url}[Samba 4.8.1] on the ownCloud server, when: - -. The Windows Network Drive Listener is used; *and* -. The remote Windows/Samba file server requires at least {smb2-url}[version 2.0 of the SMB protocol]. - -The xref:wnd-listener-setup[Windows Network Drive Listener] only supports version 1 of the SMB protocol (SMB1) with _earlier_ Samba versions. - -*Background* - -A {samba-url}[Samba] server, often a Microsoft Windows Server, can enforce the minimum and maximum protocol versions used by connecting clients. However, in light of the {wannacry-ransomware-attack-url}[WannaCry ransomware attack], {msft-security-bulletin-ms17-010-url}[Microsoft patched Windows Server] to only allow SMB2 as minimum protocol by default, as SMB1 is insecure. - -The ownCloud windows network drive listener utilizes the SMB notification feature which works well with SMB1 in conjunction with most Samba versions. However, when the minimum protocol a server accepts is SMB2, ownCloud requires Samba 4.7.8+ (4.8+ etc.) to be able to properly work, as prior versions of Samba had a bug that broke this feature. -==== - -== Configuration - -=== Enabling External Storage - -To enable external storage, as the ownCloud administrator go to menu:Settings[Admin > Storage] and tick the checkbox `Allow users to mount external storage`. - -=== Creating a New Share - -When you create a new WND share, you need multiple things:: -+ --- -* the server name or address hosting the share, -* the login credentials for the share if required by the authentication method, -* the share name and -* optionally, a sub-folder of the share you want to connect to. - -[CAUTION] -==== -_Treat all the parameters as being case-sensitive._ Although some parts of the app might work properly regardless of casing, other parts might have problems if the case is not respected. -==== - -[IMPORTANT] -==== -. When using *Kerberos* authentication, read the following documentation first: - -.. xref:enterprise/authentication/kerberos.adoc[Kerberos Authentication]. + -This documentation is a necessary prerequisite to set up Kerberos for use with ownCloud. - -.. xref:special-settings-when-adding-a-kerberos-mountpoint[Kerberos Mountpoint]. + -There are additional settings required when adding a mount point using the Kerberos authentication. - -. When using *Credentials hardcoded in config file* authentication, read the following documentation first: - -.. xref:enterprise/authentication/enterprise_only_auth.adoc#notes-for-credentials-hardcoded-in-config-file[Notes for Credentials Hardcoded in Config File]. + -This documentation is a necessary prerequisite to set up this authentication type. - -.. xref:special-settings-when-using-credentials-hardcoded-in-config-file[Special Settings when using 'Credentials hardcoded in config file']. + -There are special settings required when adding a mount point using this authentication type. -==== --- - -Follow this procedure to create a new mount point based on WND:: -+ --- -. Enter the ownCloud mount point for your new WND share. This _must not_ be an existing folder. - -. Select your authentication method. See xref:enterprise/external_storage/enterprise_only_auth.adoc[Enterprise-Only Authentication Options] for complete information on the available authentication methods. - -. Enter the address of the server that contains the WND share. - -. Use the share name provided by Windows or Samba. - -. Optionally, the root folder of the share. This can be a subfolder name, or the `$user` variable when assigning the user's home directory. Note that the LDAP `Internal Username Attribute` must be set to the `samaccountname` for either the share or the root to work, and the user's home directory needs to match the `samaccountname`. -(See xref:configuration/user/user_auth_ldap.adoc[User Authentication with LDAP].) - -. Add the login credentials, if required, depending on the authentication method selected. - -. Sharing - -.. Admin only menu:Settings[Admin > Storage]: + -Admins can define that mount points can be shared to all (default), or be restricted to individuals or groups. Note that sharing is not available for all authorization methods. For details please see the -xref:enterprise/external_storage/enterprise_only_auth.adoc#authentication-option-details[Enterprise-Only Authentication Options]. In this case, you will also see the following on the mount point: -+ -image::enterprise/external_storage/windows_network_drive/wnd-available-for.png[WND Sharing Options,width=400] - -.. All menu:Settings[General > Storage]: + -If sharing of mounts is allowed by the admin via menu:Settings[Admin > Storage > Allow sharing on user-mounted external storages], users can share the mount via menu:Files[Mountpoint > Details > Sharing]. To avoid accidentally sharing resources, the user must allow sharing a mount in the mount points view upfront by clicking on the gear icon as shown below. btn:[Enable sharing] appears only if sharing is generally allowed by the admin, see above. - -. Click the gear icon for additional mount options. Previews are enabled by default, but when using large storages with many files, you may want to disable previews as this can significantly increase performance. -+ -image::enterprise/external_storage/windows_network_drive/wnd-gear-icon.png[WND Gear Icon,width=300] - -. Your changes are saved automatically. - -. Finally, the mount point is created and will look like this example if a user has set it up: -+ -image::enterprise/external_storage/windows_network_drive/wnd-username-pwd.png[WND mount point created,width=500] - -NOTE: When you create a new mountpoint using login credentials (session-based), you must log out of ownCloud and then log back in so you can access the share. You only have to do this the first time. --- - -=== Special Settings when using 'Credentials hardcoded in config file' - -The `Config key` to be entered as shown in the screen below, must be taken as described in xref:enterprise/authentication/enterprise_only_auth.adoc#value-to-be-entered-in-the-mount-point-config-key-field[Value to be entered in the mount point config key field]. - -image::enterprise/external_storage/windows_network_drive/wnd-config-key.png[WND mountpoint and hardcoded credentials, width=500] - -Note that this authentication method can only be used by ordinary users if the admin hands over the `Config key` created. This is secure, as no password is exposed. - -=== Special Settings when Adding a Kerberos Mountpoint - -NOTE: See the linked section for important information when planning to use xref:#collaborative-wnd[Collaborative WND]. - -When the xref:enterprise/authentication/kerberos.adoc[Kerberos Authentication] has been set up, a necessary config key xref:configuration/server/config_apps_sample_php_parameters.adoc#a-map-of-servers-with-the-required-kerberos-data[wnd.kerberos.servers] needs to be provided upfront in `config.php`. - -* `Kerberos Server ID` + -This ID can be chosen from the config paramater section `wnd.kerberos.servers` and defines required parameters for the WND Kerberos setup. Multiple ID's with different setups can be created. -* `ockeytab` + -This is the keytab file that has been described in xref:enterprise/authentication/kerberos.adoc#keytab-files[Keytab Files]. -* `ocservice` + -This is the SPN of the service user that has been described in xref:enterprise/authentication/kerberos.adoc#service-principal-name-spn[Service Principal Name (SPN)]. -* `usermapping` + -Define a usermapping if necessary or required. - -// do not remove - -The usermapping key:: -This key has several types where you can read more about in the xref:configuration/server/config_apps_sample_php_parameters.adoc#a-map-of-servers-with-the-required-kerberos-data[wnd.kerberos.servers] config section. The `noop` type is the one mostly used which does not map. The following type is described in more detail: -+ --- -Type EALdapAttr:: -+ -Note that `usermapping` with type `EALdapAttr` is only possible with the enabled and configured {oc-marketplace-url}/apps/user_ldap[LDAP Integration] app. WND will throw an error if not. -+ -The LDAP attribute for using the correct login information is defined during the LDAP Integration app setup. On the users first time login after the LDAP Integration app has been configured, the UID will be stored in the ownCloud database and is fixed from that time on. It can be possible, that the ownCloud UID might not be usable for Kerberos like when the `objectuid` attribute has been defined for the ownCloud UID. For this case, a mapping can be defined to use a different LDAP attribute for the UID to authenticate with Kerberos. To do so, go to the LDAP settings in ownCloud at menu:Settings[General > User Authentication > Advanced > Exposed User Attributes] and enter all possible LDAP attributes which you want to use for mapping. Usually these are `userPrincipalName` and `sAMAccountName` but any can be defined. See the Microsoft https://learn.microsoft.com/en-us/windows/win32/ad/naming-properties[User Naming Attributes] for more details. -+ -image:enterprise/external_storage/windows_network_drive/wnd-ldap-exposed-user-attributes.png[LDAP Exposed User Attributes, width=300] -+ -The following rules apply for the EALdapAttr type::: -* In the LDAP integration app settings, you can define more than one attribute allowed to map, where each attribute must be on its own line. -* Casing the attribute name matters. -* Each WND Kerberos Server ID block can hold exactly one `EALdapAttr`/ assignment, but you can define multiple Server ID's. -* Attributes defined at ownCloud must exist on the LDAP server and users must have that attribute assigned and configured. -* If a WND config mapping else than `noop` was defined, it will lookup the mapping first. --- - -Enter the `Kerberos Server ID` to define the server and Kerberos credentials as shown in the image below. - -image::enterprise/external_storage/windows_network_drive/wnd-kerberos-1.png[WND mountpoint and Kerberos credentials, width=500] - -Note that this authentication method can only be used by ordinary users if the admin hands over the `Kerberos Server ID` created. Consider this as a very sensitive information like a password. - -When the data has been entered correctly, the moint point will show up as follows: - -image::enterprise/external_storage/windows_network_drive/wnd-kerberos-2.png[WND mountpoint with Kerberos authorization,width=500] - -=== Permission Manager - -Starting with version 1.0.1 of the Windows Network Drives App, {acl-url}[Access Control Lists (ACLs)] are supported. To obtain the ACL information, two ACL providers can be selected: - -* xref:the-null-permission-manager[The Null Permission Manager] -* xref:the-owncloud-ldap-permission-manager[The ownCloud LDAP Permission Manager] - -image::enterprise/external_storage/windows_network_drive/acl-permissions-manager.png[Configuring ACL retrieval in the ownCloud Windows Network Drive app, width=500] - -On standard deployments, you don't need to change anything. Just leave the field empty and the default `nullPermissionManager` permission manager will be used. - -Regardless of which provider you choose, an ownCloud administrator should run a -xref:configuration/server/occ_command.adoc#file-operations[files:scan], manually, after changing the configuration, to update the permissions correctly. Otherwise, the permissions shown by ownCloud might be incorrect. - -NOTE: Permissions are only auto-updated if there has been a change in the files. - -==== The Null Permission Manager - -The `Null Permission Manager` is the default permission manager for ACLs and is used, if no other ACL manager is specified. This is also the case, when no permission is explicitly set. If you want to retain ownCloud's current behaviour, then use this permission manager. When in effect, the Windows Network Drive app uses the file's attributes (e.g., read-only, and hidden), to determine how the user can interact with the file. There are no usage restrictions. - -The value to select for this provider is: `nullPermissionManager`. - -==== The ownCloud LDAP Permission Manager - -The ownCloud LDAP Permission Manager evaluates ACLs in files along with file attributes to determine the permissions. In order to evaluate the ACLs, it needs access to the user and group membership information of the target Windows or Samba server. Therefore it uses ownCloud's {oc-marketplace-url}/apps/user_ldap[LDAP Integration app] for this. - -IMPORTANT: Both the Windows (or Samba) server and ownCloud's LDAP Integration app must connect to the same Active Directory server so that ownCloud can retrieve the same user and group information. - -The use of this provider requires two key things: - -* An Active Directory server which contains the standard user and group information that can be used by the {oc-marketplace-url}/apps/user_ldap[LDAP Integration app]. -* ownCloud's LDAP Integration app to be xref:configuration/user/user_auth_ldap.adoc[correctly configured] to retrieve user and group information from the same Active Directory / LDAP server as the one that the Windows or Samba server uses. - -IMPORTANT: The ownCloud LDAP Integration app must configure the `sAMAccountName` to be the ownCloud server's username. - -[TIP] -==== -Some groups, such as `everyone` might not be handled properly. This is because such groups don't exist in the LDAP server, or might not be found if the domain is different, such as `nt authority\system` or `builtin\domain-users`. -==== - -The value to select for this provider is: `ocLdapPermissionManager`. - -=== WND Notifications - -The SMB protocol supports registering for notifications of file changes on remote Windows SMB storage servers. Notifications are more efficient than polling for changes, as polling requires scanning the whole mounted SMB storage. While files changed through the ownCloud Web Interface or sync clients are automatically recognized by ownCloud, recognition is not possible when files are changed directly on remote SMB storage mounts. When using the _listener_, files changed on the SMB backend are recognized and a notification is stored in the database. The _process-queue_ job reads these stored notifications and initiates further actions. - -NOTE: The capability of the listener depends on the ability of the used SMB/CIFS storage backend to provide notifications. While Windows file servers have no limitations, some vendors may have restrictions. Please check these with your storage provider. It may be possible, that for example notifications for Samba only work for the target folder you're listening to, but not for any sub structures. If you're listening on the "/top" folder, you may not receive notifications for "/top/middle/bottom" folder. In this case, you have to set up listeners for every _existing_ folder and also for any _new_ folders that will be created. With Windows file servers, you will receive notifications for every file or subfolder inside the folder you're listening to. - -==== WND Listener Setup - -The WND listener for ownCloud Classic 10 includes two different commands that need to be executed: - -* xref:wndlisten[wnd:listen] Listen to changes and save them in the database -* xref:wndprocess-queue[wnd:process-queue] Process saved listener changes from the database - -===== wnd:listen - -This command listens to changes for each host and share configured and stores all notifications gathered in the database. _It is intended to run this command as a service_. The command requires the Windows/Samba account and the host/share the listener will listen to. The command does not produce any output by default, unless an error happens. Each stored notification will be further processed by the `wnd:process-queue` and will be removed from the database after processing. - -NOTE: You can increase the command's verbosity by using `-vvv`. Doing so displays the listeners activities including a timestamp and the notifications received. A _read-only_ permission for the used account should be enough, but may need to be increased. - -The simplest way, useful for initial testing is, to start the `wnd:listen` process manually, as follows: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen ----- - -The password is an optional parameter and you will be asked for it if you didn't provide it as in the example above. If necessary, the workgroup can be set together with the username as well. Use following syntax and set quotes, which is important to keep the backslash `'\'`. The whole example command looks like: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen '\' ----- - -In order to start `wnd:listen` without any user interaction like as service, provide the password from a password file. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen \ - --password-file=/my/secret/password/file \ - --password-trim ----- - -For additional options to provide the password, check xref:password-options[Password Options]. - -Note that the password must be in plain text inside the file. Neither spaces nor newline characters will be removed from the contents of the file by default, unless the `--password-trim` option is added. The password file must be readable by the apache user (or www-data). Also make sure that the password file is outside of any directory handled by apache (web-readable) for security reasons. You may use the same location when using flock in xref:execution-serialization[Execution Serialization] below. - -You should be able to run any of those commands, and/or wrap them into a systemd service or any other startup service, so that the `wnd:listen` command is automatically started post booting. - -===== wnd:process-queue - -This command processes the stored notifications for a given host and share. This process is intended to be run periodically as a Cron job, or via a similar mechanism. The command will process the notifications stored by the `wnd:listen` process, showing only errors by default. If you need more information, increase the verbosity by calling `wnd:process-queue -vvv`. - -As a simple example, you can check the following: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:process-queue ----- - -You can run that command, even if there are no notifications to be processed. - -Depending on your requirements, you can wrap that command in a Cron job so it's run every 5 minutes for example. - -==== WND Listener Service Configuration - -Create a service for `systemd` following the instructions below that checks for processable notifications: - -[NOTE] -==== -* Replace the all upper case words `SERVER`, `SHARE`, `USER` and `PASSWORD` in both, the **filename** and in the **contents** below with their respective values. -* Take care to also adjust the paths in `WorkingDirectory` and `ExecStart` according to your installation. -==== - -* For each WND mount point distinguished by a SERVER - SHARE pair: -** Replace the all upper case words `SERVER`, `SHARE`, `USER` and `PASSWORD` in both, the **filename** and in the **contents** below with their respective values. -** Place one copy of a file with the content from below under `/etc/systemd/system/owncloud-wnd-listen-SERVER-SHARE.service` + -To do so, enter following command and replace with `owncloud-wnd-listen-SERVER-SHARE`. For more details see https://www.digitalocean.com/community/tutorials/how-to-use-systemctl-to-manage-systemd-services-and-units#editing-unit-files[Editing Unit Files]. -+ -[source,bash] ----- -sudo systemctl edit --force --full .service ----- -+ -Reload the deamon to make it available: -+ -[source,bash] ----- -sudo systemctl daemon-reload ----- -** Take care to also adjust the paths in `WorkingDirectory` and `ExecStart` according to your installation. -** Password: Create a file readable only by the www-data user and outside the directories handled by Apache - (let's suppose in /tmp/mypass). The file must contain only the password for the share. In this example our - file is: "/tmp/mypass". The listener will read the contents of the file and use them as the password for -the account. This way, only root and the Apache user should have access to the password. -** `--password-trim` in directive `ExecStart` removes blank characters from the password file added by 3rdparty software or other services. - -* Content template for `owncloud-wnd-listen-SERVER-SHARE` -+ -[source,plaintext] ----- -[Unit] -Description=ownCloud WND Listener for SERVER SHARE -After=syslog.target -After=network.target -Requires=apache2.service -[Service] -User=www-data -Group=www-data -WorkingDirectory=/var/www/owncloud -ExecStart=./occ wnd:listen -vvv SERVER SHARE USER --password-file=/tmp/mypass --password-trim -Type=simple -StandardOutput=journal -StandardError=journal -SyslogIdentifier=%n -KillMode=process -RestartSec=3 -Restart=always -[Install] -WantedBy=multi-user.target ----- - -* Run the following command, once for each created file: -+ -[source,bash] ----- -sudo systemctl daemon-reload -sudo systemctl enable owncloud-wnd-listen-SERVER-SHARE.service -sudo systemctl start owncloud-wnd-listen-SERVER-SHARE.service ----- - -* To list all systemd wnd listeners for ownCloud run the following command, assuming you use the naming convention described above: -+ -[source,bash] ----- -systemctl list-units | grep owncloud-wnd-listen ----- - -* Please re-run the following commands if you are changing the contents of a particular listener service: -+ -[source,bash] ----- -sudo systemctl daemon-reload -sudo systemctl restart owncloud-wnd-listen-SERVER-SHARE.service ----- - -For more information about configuring services for systemd, read {manage-systemd-services-url}[How To Use Systemctl to Manage Systemd Services and Units] - -==== WND Process Queue Configuration - -Create or add a `crontab` file in `/etc/cron.d/oc-wnd-process-queue`. - -NOTE: The commands must be **strictly sequential**. This can be done by using `flock -n` and tuning the `-c` (chunk-size) parameter of `occ wnd:process-queue`, see the xref:configuration/server/occ_command.adoc#windows-network-drive-wnd[wnd occ commands] description and the xref:execution-serialization[Execution Serialization] below. - -* Make a `crontab` entry to run a script iterating over all `SERVER SHARE` pairs with an appropriate `occ wnd:process-queue` command. -+ -[source,bash] ----- -* * * * * sudo -u www-data /var/www/owncloud/occ wnd:process-queue ----- - -===== Execution Serialization - -Parallel runs of `wnd:process-queue` might lead to a user lockout. The reason for this is that several `wnd:process-queue` might use the same wrong password because it hasn't been updated by the time they fetch it. - -It's recommended to force the execution serialization of the `wnd:process-queue` command. You might want to use {anacron-examples}[Anacron], which seems to have an option for this scenario, or wrap the command with -{shell-flock-intro}[flock]. - -If you need to serialize the execution of the `wnd:process-queue`, check the following example with {shell-flock-intro}[flock] - -[source,bash,subs="attributes+"] ----- -flock -n /opt/my-lock-file {occ-command-example-prefix} wnd:process-queue ----- - -In that case, flock will try to get the lock of that file and won't run the command if it isn't possible. For our case, and considering that file isn't being used by any other process, it will run only one `wnd:process-queue` at a time. If someone tries to run the same command a second time while the previous one is running, the second will fail and won't be executed. - -The lock file `/opt/my-lock-file` itself will be created as an empty file by the `flock` command if it does not yet exist, but after it has been created the lock file doesn't change. Only an flock will be applied and removed. The file won't be removed after the script completes. - -You can use flock also in cron, see the example below: - -[source,bash,subs="attributes+"] ----- -* * * * * flock -n /opt/my-lock-file -c 'sudo -u www-data /var/www/owncloud/occ wnd:process-queue ' ----- - -Check {flock-docs-url}[flock's documentation] for details and more options. - -=== Activity Extension - -From version 2.0.0 the Windows Network Drive app includes an extension of the Activity app. This extension will allow the app to send events to the Activity app so the users know what happened in the Windows Network Drive storage. - -Please see the following figure how a notification can look like. In this example, one user accessing the same host/share has changed a file. Other users will now get an activity notification about this change. - -.Activity Notification for a Changed File -image::enterprise/external_storage/windows_network_drive/activity_file_change_notification.png[Activity notification for a Changed File,width=450] - -This extension requires the following components: - -* `wnd:listen` command set up and running in order to get the storage events -* `wnd:process-queue` command running periodically (or manually) over the event queues generated by the `wnd:listen` command -* The Activity app enabled - -For setting up the `wnd:listen` and `wnd:process-queue` commands, see their respective sections above. - -This extension is disabled by default. This means that no activity will reach the users. In order to enable this extension, you can edit the `config/config.php` file and add the following configuration: - -[source,php] ----- -'wnd.activity.registerExtension' => true, ----- - -NOTE: This configuration will affect all the WND mount points. - -The events that will be shown to the users are based on what the `wnd:process-queue` detects and changes in the ownCloud's FS. Since the command includes some optimizations, some events might be inaccurate in some scenarios. For example, if multiple files are added in the same folder, there won't be multiple "file added" events but only one "folder modified" in the parent folder. - -The events are expected to reach only to the affected users. This filters out the users who cannot access the mount point, and also the users who do not have enough permissions in the Network Drive (Windows, Samba) to access that file. - -As part of the Activity app configuration, users can decide which events they want to be notified about and how, in the activity stream or via email. - -Users who can access the Windows Network Drive storage via share won't receive activity notifications by default. You can add the following configuration in the `config/config.php` file to enable sending the activity notification to those users. - -[source,php] ----- -'wnd.activity.sendToSharees' => true, ----- - -NOTE: `wnd.activity.sendToSharees` key depends on the `wnd.activity.registerExtension` key to take effect. - -=== Collaborative WND - -Collaborative WND (CWND) can only be set by an admin in menu:Settings[Admin > Storage]. This mount type cannot be selected by users in the user section. To prepare access for your mount point using the CWND mount type, you must provide a _Service Account_ (SA) which is an ordinary SMB user granting read access to the share you want to mount. You can use one SA for all CWND mounts or separate ones. The SA is used to gather the contents of a share used by the WND Listener and provides a common `file_id` to all accessing users, while the accessing users can only access those files and folders for which they've been granted rights. - -NOTE: For obvious reasons, do not use the `$user` placeholder for the share name. It would map to the logged in users home directoy shared collaboratively. - -NOTE: For the time being, no CWND is possible with Kerberos because of a necessary service user which is currently not available for Kerberos. - -. As an admin, go to menu:Settings[Admin > Storage] and create a new CWND based mount point. -+ -.Add a Collaborative Windows Network Drive Mount -image:enterprise/external_storage/windows_network_drive/cwnd_add_storage.png[Add Collaborative Windows Network Drive Mount, width=350] -. Chose any name for the mount point that fits your needs. -. Select user login type. -+ -[IMPORTANT] -==== -The following three are sensible and working selections for CWND: -[loweralpha] -. `Log-in credentials, saved in session` -. `Log-in credentials, saved in database` -. `User entered, stored in database` ^[1]^ -+ -[1] Must be used if user authentication is made with OIDC -==== -+ -.Select How User Logs in to the Mount Point -image:enterprise/external_storage/windows_network_drive/cwnd_login_possibilities.png[Select How User Logs Into the Mount Point,width=450] -[loweralpha] -.. `Log-in credentials, saved in session` -+ -When the user logs in to ownCloud via a browser, the credentials to authenticate CWND are taken from this login. These credentials immediately end when the user logs out because the session has ended. -+ -* _This login type can not be set to `Enable Sharing`._ -* _This login type is by design not compatible with OIDC authentication._ -.. `Log-in credentials, saved in database` -+ -Similar to `Log-in credentials, saved in session`, the credentials to authenticate CWND are taken from the login but saved in the ownCloud database. Any re-login also updates the database entry. As the credentials to access CWND are taken from the database, a user logout will not stop CWND access and serving data is continued, e.g. for synchronization. -+ -* _This login type can be set to `Enable Sharing`._ -* _This login type is by design not compatible with OIDC authentication._ -.. `User entered, stored in database` -+ -User login to ownCloud and providing credentials to access the CWND mount are completely separated. After logging in to ownCloud, the user may see his CWND mounts marked inaccessible. To regain access, the user must enter his share credentials in menu:Settings[Personal > Storage] which are then stored into the ownCloud database. As the credentials to access CWND are taken from the database, a user logout will not stop CWND access and serving data is continued, e.g. for synchronization. -+ -* _This login type can be set to `Enable Sharing`._ -* _This login type is by design *the only one compatible with OIDC authentication*._ -+ -.Re-enter Mount Access Credentials -image:enterprise/external_storage/windows_network_drive/cwnd_regain_mount_access.png[Re-enter Mount Access Credentials,width=450] - -. Configure this mount point by adding required data into the corresponding fields -+ -.Enter Connection Info and the Service Account -image:enterprise/external_storage/windows_network_drive/cwnd_fields.png[Enter Connection Info and Service Account,width=450] - -. When everything has been entered correctly, the mount point gets a green button on the left. - -== Troubleshooting - -=== General or Connectivity Issues - -If you encounter issues using Windows network drive, then try the following troubleshooting steps: - -First check the connection to the share by using {smbclient-manpage-url}[smbclient] on the command line of the ownCloud server. Here is an example: - -[source,console,subs="attributes+"] ----- -smbclient -U Username -L //Servername ----- - -Take the example of attempting to connect to the host MyHost, the share named `MyData` using `occ wnd:listen` replacing user and password accordingly. Running the following command would work: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen MyHost MyData user password ----- - -NOTE: The command is case-sensitive, and that it must match the information from the mount point configuration. - -=== Kerberos Testing - -To test if Kerberos has been setup properly for the use with WND, check the following on the server running ownCloud, replace xref:enterprise/authentication/kerberos.adoc#keytab-files[keytab], xref:enterprise/authentication/kerberos.adoc#service-principal-name-spn[SPN], `` and `/` accordingly. The domain user is the user on behalf the Kerberos ticket will be requested. Note that the shell user you are testing with must have access to the keytab file: - -. {empty} -+ -[source,bash] ----- -kinit -k -t \ - /.keytab \ - HTTP/ ----- - -. {empty} -+ -[source,bash] ----- -kvno -U \ - \ - -P -c /tmp/krb5cc_0 -k \ - /.keytab \ - cifs/ ----- - -. {empty} -+ -[source,bash] ----- -smbclient \ - --use-krb5-ccache=/tmp/krb5cc_0 \ - --use-kerberos=required \ - /// ----- - -. Destroy the Kerberos ticket for security reasons: -+ -[source,bash] ----- -kdestroy ----- - -=== libsmbclient Issues - -If your Linux distribution ships with `libsmbclient 3.x`, which is included in the Samba client, you may need to set up the `HOME` variable in Apache to prevent a segmentation fault. If you have `libsmbclient 4.1.6` and higher, it doesn't seem to be an issue, so you won't have to change your `HOME` variable. To set up the `HOME` variable on Ubuntu, modify the `/etc/apache2/envvars` file: - -[source,bash] ----- -unset HOME -export HOME=/var/www ----- - -In Red Hat/CentOS, modify the `/etc/sysconfig/httpd` file and add the following line to set the HOME variable in Apache: - -[source,bash] ----- -export HOME=/usr/share/httpd ----- - -By default, CentOS has activated SELinux, and the `httpd` process can not make outgoing network connections. This will cause problems with the `curl`, `ldap` and `samba` libraries. You'll need to get around this to make this work. First, check the status: - -[source,bash] ----- -getsebool -a | grep httpd -httpd_can_network_connect --> off ----- - -Then enable support for network connections: - -[source,bash] ----- -setsebool -P httpd_can_network_connect 1 ----- - -In openSUSE, modify the `/usr/sbin/start_apache2` file: - -[source,bash] ----- -export HOME=/var/lib/apache2 ----- - -Restart Apache, open your ownCloud Admin page and start creating SMB/CIFS mounts. - -=== Basic Setup for One ownCloud Classic - -. Go to the admin settings and set up the required WND mounts. Be aware though, that there are some limitations. These are: -.. ownCloud needs access to the Windows account password for the mounts to update the file cache properly. This means that "__login credentials, saved in session__" won't work with the listener. ownCloud suggests to use "__login credentials, saved in DB__" as the best replacement instead. -.. The `$user` placeholder for the share name, such as `//host/$user/path/to/root`, providing a share which is accessible per/user won't work with the listener. This is because the listener won't scale, as you'll need to setup one listener per/share equals one listener per user. As a result, you'll end up with too many listeners. An alternative is, to provide a common share for the users and use the `$user` placeholder in the root, such as `//host/share/$user/folder`. -. Start the `wnd:listen` process if it's not already started, ideally running it as a service. If it isn't running, no notifications are stored. The listener stores the notifications. Any change in the mount point configuration, such as adding or removing new mounts, and logins by new users, won't affect the behavior, so there is no need to restart the listener in those cases. -+ -If you have several mount point configurations, note that each listener attaches to one host and share. If there are several mount configurations targeting different shares, you'll need to spawn one listener for each. For example, if you have one configuration with `10.0.0.2/share1` and another with `10.0.0.2/share2`, you'll need to spawn 2 listeners, one for the first configuration and another for the -second. -. Run the `wnd:process-queue` periodically, usually via xref:configuration/server/background_jobs_configuration.adoc#cron-jobs[a Cron job]. The command processes all the stored notifications for a specific host and share. If you have several, you could set up several Cron jobs, one for each host and share with different intervals, depending on the load or update urgency. As a simple example, you could run the command every 2 minutes for one server and every 5 minutes for another. - -As said, the command processes all the stored notifications, squeezes them and scans the resulting folders. The process might crash if there are too many notifications, or if it has too many storages to update. The `--chunk-size` option will help by making the command process all the notifications in buckets of that size. - -On the one hand the memory usage is reduced, on the other hand there is more network activity. We recommend using the option with a value high enough to process a large number of notifications, but not so large to crash the process. Between 200 and 500 should be fine, and we'll likely process all the notifications in one go. - -=== Password Options - -There are several ways to supply a password: - -. Interactively in response to a password prompt. -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen ----- -. Sent as a parameter to the command. -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen ----- -. Read from a file, using the `--password-file` switch to specify the file to read from. Note, that the password must be in plain text inside the file, and neither spaces nor newline characters will be removed from the file by default, unless the `--password-trim` option is added. The password file must be readable by the apache user (or www-data) -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen \ - --password-file=/my/secret/password/file ----- -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen \ - --password-file=/my/secret/password/file \ - --password-trim ----- -+ -NOTE: If you use the `--password-file` switch, the entire contents of the file will be used for the password, so please be careful with newlines. -+ -IMPORTANT: If using `--password-file` make sure that the file is only readable by the apache / www-data user and inaccessible from the web. This prevents tampering or leaking of the information. The password won't be leaked to any other user using `ps`. -. Using 3rd party software to store and fetch the password. When using this option, the 3rd party app needs to show the password as plaintext on standard output. -. Using the service account password, which is already stored in the database if you setup WND in collaborative mode. In this mode, you set the username and the option for the `occ` command to reuse the password stored in the database. The example command looks like: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen - --password-from-service-account ----- -+ -IMPORTANT: You need to ensure that the triple of ``, `` and `` (including any kind of workgroup if used) matches the configuration made for the WND collaborative share. The command will fail otherwise. - -=== Reduce WND Notifier Memory Usage - -The WND in-memory notifier for password changes provides the ability to notify all _affected_ WND storages to reset their passwords. This feature is intended to prevent a password lockout for the user in the backend. However, this functionality _can_ consume a significant amount of memory. To disable it, add the following configuration to your `config/config.php.`: - -[source,php] ----- -'wnd.in_memory_notifier.enable' => false, ----- - -NOTE: The password will be reset on the next request, regardless of the flag setting. - -=== 3rd Party Software Examples - -Third party password managers or processes can be integrated. The only requirement is that they have to provide the password in plain text somehow. If not, additional operations might be required to get the password as plain text and inject it in the listener. - -==== plainpass - -This provides a bit more security because the `/tmp/plainpass` password as shown below should be owned by root and only root should be able to read the file (0400 permissions); Apache, particularly, shouldn't be able to read it. It's expected that root will be the one to run this command. - -[source,bash,subs="attributes+"] ----- -cat /tmp/plainpass | {occ-command-example-prefix} wnd:listen --password-file=- ----- - -==== base64 - -Similar to plainpass, the content in this case gets encoded in the {base64-url}[Base64 format]. There's not much security, but it has additional obfuscation. - -[source,bash,subs="attributes+"] ----- -base64 -d /tmp/encodedpass | \ - {occ-command-example-prefix} wnd:listen --password-file=- ----- - -==== pass - -Example using "pass" - -* You can go through {pass-url}[manage passwords from the command line] to set up the keyring for whoever will fetch the password (probably root) and then use something like the following: - -[source,bash,subs="attributes+"] ----- -pass the-password-name | {occ-command-example-prefix} wnd:listen --password-file=- ----- - -==== HashiCorp Vault - -This example uses {vaultproject-url}[Vault] as the secrets store. See {hashicorp-url}[HCP Vault] on how to setup the secrets store. Then use something like the following: - -[source,bash,subs="attributes+"] ----- -vault kv get -field=password secret/samba | {occ-command-example-prefix} wnd:listen --password-file=- ----- - -Use Vault's ACLs to limit access to the token. Destroy the token after starting the service during boot with systemd. - -=== Password Option Precedence - -If both the argument and the option are passed, e.g., -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen --password-file=/opt/pass` ----- -then the `--password-file` option will take precedence. - -=== Optimizing wnd:process-queue - -NOTE: Do not use this option if the process-queue is fast enough. The option has some drawbacks, specifically regarding password changes in the backend. - -`wnd:process-queue` creates all the storages that need to be updated from scratch. To do so, we need to fetch all the users from all the backends (currently only the ones that have logged in at least once because the others won't have the storages that will need updates). - -To optimize this, `wnd:process-queue` make use of two switches: `–serializer-type` and `–serializer-param`. These serialize storages for later use, so that future executions don't need to fetch the users, saving precious time — especially for large organizations. - -{empty} - -[cols="30%,100%",options="header"] -|=== -| Switch -| Allowed Values - -| `--serializer-type` -| `file`. Other valid values may be added in the future, as more implementations are requested. - -| `--serializer-param` -| Depends on `--serializer-type`, because those will be the parameters that the chosen serializer will use. For the `file` serializer, you need to provide a file location in the host FS where the storages will be serialized. You can use `--serializer-param file=/tmp/file` as an example. -|=== - -While the specific behavior will depend on the serializer implementation, the overall behavior can be simplified as follows: - -If the serializer's data source (such as _a file_, _a database table_, or some _Redis keys_) has storage data, it uses that data to create the storages; otherwise, it creates the storages from scratch. - -After the storages are created, notifications are processed for the storages. If the storages have been created from scratch, those storages are written in the data source so that they can be read on the next run. - -NOTE: It's imperative to periodically clean up the data source to fetch fresh data, such as for new storages and updated passwords. There isn't a generic command to do this from ownCloud, because it depends on the specific serializer type. Though this option could be provided at some point if requested. - -=== The File Serializer - -The file serializer is a serializer implementation that can be used with the `wnd:process-queue` command. It requires an additional parameter where you can specify the location of the file containing the serialized storages. - -There are several things you should know about this serializer: - -* The generated file contains the encrypted passwords for accessing the backend. This is necessary in order to avoid re-fetching the user information, when next accessing the storages. -* The generated file is intended to be readable and writable *only* for the web server user. Other users shouldn't have access to this file. Do not manually edit the file. You can remove the file if it contains obsolete information. - -=== Usage Recommendations - -==== Number of Serializers - -Only one file serializer should be used per server and share, as the serialized file has to be per server and share. Consider the following usage scenario: - -* If you have three shares: `10.0.2.2/share1`, `10.0.2.2/share2`, and `10.0.10.20/share2`, then you should use three different calls to `wnd:process-queue`, changing the target file for the serializer for each one. - -Since the serialized file has to be per server and share, the serialized file has some checks to prevent misuse. Specifically, if we detect you're trying to read the storages for another server and share from the file, the contents of the file won't be read and will fallback to creating the storage from scratch. At this point, we'll then update the contents of that file with the new storage. - -Doing so, though, creates unneeded competition, where several process-queue will compete for the serializer file. For example, let's say that you have two process-queues targeting the same serializer file. After the first process creates the file the second process will notice that the file is no longer available. As a result, it will recreate the file with new content. - -At this point the first process runs again and notices that the file isn't available and recreates the file again. When this happens, the serializer file's purpose isn't fulfilled. As a result, we recommend the use of a different file per server and share. - -==== File Clean Up - -The file will need to cleaned up from time to time. The easiest way to do this is to remove the file when it is no longer needed. The file will be regenerated with fresh data the next execution if the serializer option is set. - -=== Interaction Between Listener and Windows Password Lockout - -Windows supports {password-lockout-policies-url}[password lockout policies]. If one is enabled on the server where an ownCloud share is located, and a user fails to enter their password correctly several times, they may be locked out and unable to access the share. - -//https://github.com/owncloud/Windows_network_drive/issues/94 [known issue] - -This is a known issue that prevents these two inter-operating correctly. Currently, the only viable solution is to ignore that feature and use the `wnd:listen` and `wnd:process-queue`, without the serializer options. - -=== Multiple Server Setup - -Setups with several servers might have some difficulties in some scenarios: - -* The `wnd:listen` component _might_ be duplicated among several servers. This shouldn't cause a problem, depending on the limitations of the underlying database engine. The supported database engines should be able to handle concurrent access and de-duplication. -* The `wnd:process-queue` _should_ also be able to run from any server, however limitations for concurrent executions still apply. As a result, you might need to serialize command execution of the `wnd:process-queue` among the servers (to avoid password lockout), which might not be possible or difficult to achieve. You might want to execute the command from just one specific server in this case. -* `wnd:process-queue` + serializer. First, check the above section to know the interactions with the password lockout. Right now, the only option you have to set up is to store the target file in a common location for all the servers. We might need to provide a specific serializer for this scenario (based on Redis or DB) - -=== Basic Command Execution Examples - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen host share username password - -{occ-command-example-prefix} wnd:process-queue host share - -{occ-command-example-prefix} wnd:process-queue host share -c 500 - -{occ-command-example-prefix} wnd:process-queue host share -c 500 \ - --serializer-type file \ - --serializer-param file=/opt/oc/store - -{occ-command-example-prefix} wnd:process-queue host2 share2 -c 500 \ - --serializer-type File \ - --serializer-param file=/opt/oc/store2 ----- - -To set it up, make sure the listener is running as a system service: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen host share username password ----- - -Setup a Cron job or similar with something like the following two commands: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:process-queue host share -c 500 \ - --serializer-type file \ - --serializer-param file=/opt/oc/store1 - -sudo rm -f /opt/oc/store1 # With a different schedule ----- - -The first run will create the `/opt/oc/store1` with the serialized storages, the rest of the executions will use that file. The second Cron job, the one removing the file, will force the `wnd:process-queue` to -refresh the data. - -It's intended to be run in a different schedule, so there are several executions of the `wnd:process-queue` fetching the data from the file. Note that the file can be removed manually at any time if it's needed (for example, in case the admin has reset some passwords or has been notified about password changes). - -=== Performance on High Number of ACL Targeting Users - -The WND app doesn’t know about the users or groups associated with ACLs. This means that an ACL containing "admin" might refer to a user called "admin" or a group called "admin". By default, the group membership component considers the ACLs to target groups, and as such, it will try to get the information for such a group. This works fine if the majority of the ACLs target groups. If the majority of the ACLs contain users, this might be problematic. The cost of getting information on a group is usually higher than getting information on a user. This option makes the group membership component assume the ACL contains a user and checks whether there is a user in ownCloud with such a name first. If the name doesn’t refer to a user, it will get the group information. Note that this will have performance implications if the group membership component can’t discard users in a large number of cases. It is recommended to enable this option only if there are a high number of ACLs targeting users. In order to enable this setting, you can edit the `config/config.php` file and add the following configuration: - -[source,php] ----- -'wnd.groupmembership.checkUserFirst' => true, ----- diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/wnd_quick_guide.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/wnd_quick_guide.adoc deleted file mode 100644 index 3346326..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/external_storage/wnd_quick_guide.adoc +++ /dev/null @@ -1,189 +0,0 @@ -= WND Configuration Quick Guide -:toc: right -:toclevels: 2 - -== Introduction - -This is a quick guide for installing and configuring the Windows Network Drive (WND) app. - -== Prerequisites - -To successfully use the Windows Network Drive app, you must meet the prerequisites which can be found in the xref:installation/manual_installation/server_prep_ubuntu_20.04.adoc[Server Preparation for Ubuntu 20.04]. In particular, these are the sections required which address `smbclient` ( -xref:installation/manual_installation/server_prep_ubuntu_20.04.adoc#clean-ubuntu-20-04-installation[Clean Ubuntu 20.04 Installation]) and `libsmbclient-php` ( -xref:installation/manual_installation/server_prep_ubuntu_20.04.adoc#libsmbclient-php-library[libsmbclient-php Library]). - -== Installation - -Install the WND app either via the Web Interface or the command line: - -WebUI:: -* The Windows Network Drive app has to be downloaded from the Market App. Navigate to the Market app, search for Windows Network Drive and install it. -* Post installing enable it via menu:Settings[Admin > Apps]. - -Command line:: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} market:install windows_network_drive ----- - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable windows_network_drive ----- - -== Configuration - -**WebUI** - -Enable external shares: - -* Navigate to menu:Settings[Admin > Storage] -* Enable the external storage -* Create a new share and choose Windows network Drives - -Configure external share: - -* Folder Name: A name for the WND Share -* Authentication: Choose **Log-in credentials, save in database** -* Host: domain name or IP address -* Share: name of the top share -* Remote Subfolder: enter `$user` for every user to get a home drive -* Permission Manager: leave empty to use the default one -* Domain: domain name of your server -* Available for: limit access to groups -* Settings: (gear wheel) enable the options you need - - -IMPORTANT: If you plan to use ownCloud **only** in the Web Browser - your setup of the WND is complete. - -If you plan to use a desktop client, you need to continue and configure the WND listener and WND process queue. - -**Commandline** - -Lastly, you need to setup the wnd listener and process queue to propagate the changes made directly on the storage of your share to the sync client. - -This can be done in 2 ways: - -* you configure a new systemd service for the listener and setup a process queue cron job -* you setup a cronjob for the wnd:listen command and process queue cron job - -=== WND Listener Configuration - -Create a service for systemd following the instructions below that checks the share for changes: - -* For each WND mount point distinguished by a SERVER - SHARE pair: -** Replace the all upper case words `SERVER`, `SHARE`, `USER` and `PASSWORD` in both, the **filename** and in the **contents** below with their respective values. -** Place one copy of a file with the content from below under `/etc/systemd/system/owncloud-wnd-listen-SERVER-SHARE.service` + -To do so, enter the following command and replace with `owncloud-wnd-listen-SERVER-SHARE`. For more details see https://www.digitalocean.com/community/tutorials/how-to-use-systemctl-to-manage-systemd-services-and-units#editing-unit-files[Editing Unit Files]. -+ -[source,bash] ----- -sudo systemctl edit --force --full .service ----- -+ -Reload the deamon to make it available: -+ -[source,bash] ----- -sudo systemctl daemon-reload ----- -** Take care to also adjust the paths in `WorkingDirectory` and `ExecStart` according to your installation. -** Password: Create a file readable only by the www-data user and outside the directories handled by Apache - (let's suppose in /tmp/mypass). The file must contain only the password for the share. In this example our - file is: "/tmp/mypass". The listener will read the contents of the file and use them as the password for -the account. This way, only root and the Apache user should have access to the password. -** `--password-trim` in directive `ExecStart` removes blank characters from the password file added by 3rdparty software or other services. - -* Content template for `owncloud-wnd-listen-SERVER-SHARE` -+ -[source,plaintext] ----- -[Unit] -Description=ownCloud WND Listener for SERVER SHARE -After=syslog.target -After=network.target -Requires=apache2.service -[Service] -User=www-data -Group=www-data -WorkingDirectory=/var/www/owncloud -ExecStart=/usr/bin/php ./occ wnd:listen -vvv SERVER SHARE USER --password-file=/opt/mypass --password-trim -Type=simple -StandardOutput=journal -StandardError=journal -SyslogIdentifier=%n -KillMode=process -RestartSec=3 -Restart=always -[Install] -WantedBy=multi-user.target ----- - -* Run the following command, once for each created file: -+ -[source,bash] ----- -sudo systemctl enable owncloud-wnd-listen-SERVER-SHARE.service -sudo systemctl start owncloud-wnd-listen-SERVER-SHARE.service ----- - -=== WND Process Queue Configuration - -Create or add a `crontab` file in `/etc/cron.d/oc-wnd-process-queue`. - -* Make a `crontab` entry to run a script iterating over all `SERVER SHARE` pairs with an - appropriate `occ wnd:process-queue` command. The commands must be **strictly sequential**. - This can be done by using `flock -n` and tuning the `-c` parameter of `occ wnd:process-queue` - -[source,bash] ----- -* * * * * sudo -u www-data /usr/bin/php /var/www/owncloud/occ wnd:process-queue ----- - -==== Execution Serialization - -Parallel runs of `wnd:process-queue` might lead to a user lockout. The reason for this, is that several -`wnd:process-queue` might use the same wrong password because it hasn’t been updated by the time they -fetch it. - -It’s recommended to force the execution serialization of the `wnd:process-queue` command. You might want to -use Anacron, which seems to have an option for this scenario, or wrap the command with flock. - -If you need to serialize the execution of the wnd:process-queue, check the following example with flock - -[source,bash] ----- -* * * * * flock -n /tmp/wnd001 occ wnd:process-queue server1 share1 -* * * * * flock -n /tmp/wnd002 occ wnd:process-queue server1 share2 -* * * * * flock -n /tmp/wnd003 occ wnd:process-queue server2 share3 ----- - -== Troubleshooting - -* The process queue will not work if there is a backslash in the share path configured in webui. -* The process queue will not work if the share name in the webui is configured starting with a forward slash `/`. - -If you encounter issues using Windows network drive, then try the following troubleshooting steps: - -Check the connection to the share by using smbclient on the command line of the ownCloud server. -Here is an example: - -[source,bash] ----- -smbclient -U Username -L //Servername ----- - -Take the example of attempting to connect to the share named MyData using occ wnd:listen. -Running the following command would work: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} wnd:listen MyHost MyData svc_owncloud password ----- - -The command is case-sensitive, and it must match the information from the mount point configuration. - -* When the output of the `occ process-queue ..` command shows `0 Storages found`, then this means, - that there was no corresponding external storage configuration found, because: - 1. The casing between calling the process queue and the web interface does not exactly match. - 2. The authentication method is not correctly configured, it needs to be **Log-in credentials, save in database** diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/file_management/files_lifecycle.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/file_management/files_lifecycle.adoc deleted file mode 100644 index 0675e12..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/file_management/files_lifecycle.adoc +++ /dev/null @@ -1,188 +0,0 @@ -= File Lifecycle Management -:toc: right - -== Introduction - -The File Lifecycle Management extension allows service providers to manage the lifecycle of files within ownCloud to - -- keep storage usage under control by limiting the time users can work with files before they are cleaned up automatically -- comply with regulations (like GDPR or company policies) by imposing automated retention and deletion policies for files that contain e.g., personal data and may only be stored in the company for a certain period of time. - -To impose a workflow of Use => Archive => Delete, the extension equips ownCloud with a dedicated archive and allows administrators to define rules for automated archiving (days passed since upload) and subsequent deletion of files (days passed since archiving). Only files are archived as folders do not consume storage space and existing folder structures should be kept available. The archiving and deletion processes are controlled by background jobs. - -Depending on the desired level of enforcement, the extension provides two policies to control the restoration of files from the archive if they are still needed: - -- xref:soft-policy[Soft policy]: Users can restore files in self-service -- xref:hard-policy[Hard policy]: Only administrators or group administrators can restore files on request - -Users can view the lifecycle status for a file and see when the file is scheduled for archiving or deletion. All lifecycle events of a file are displayed transparently. They can be tracked for individual files as well as for a whole user account using the {oc-marketplace-url}/apps/activity[Activity] stream. - -image:apps/files_lifecycle/file-lifecycle-events.png[File Lifecycle Events, width=30%] - -To stay informed, users can also receive regular Activity summaries by email. For auditing purposes, the extension integrates with the {oc-marketplace-url}/apps/admin_audit[Auditing] app to provide all events of interest in the logs. - -== Setup & Configuration - -See the xref:configuration/server/occ_command.adoc#file-lifecycle-management[lifecycle occ command set] for details when using the command line. - -=== Archive Location - -By default, archived files are stored within the ownCloud data directory but outside the users' files directories so that they are not accessible using the Web UI and other clients. - -[width="70%",cols="40%,80%",options="header"] -|=== -| Type -| Location -| User files -| `//$userid/files` -| Archived files -| `//$userid/archive/files/` -|=== - -=== Setting Upload Times for Existing Files - -File Lifecycle Management uses the _upload time_ of files (server time at which they first appeared on the ownCloud server) to determine when to archive them. As ownCloud Classic generally does not store this metadata, the File Lifecycle Management extension takes care of this when it is enabled. - -When File Lifecycle Management is set up on an existing ownCloud installation, you therefore have to set an _upload time_ for all files that existed before the extension has been enabled. The same applies if it was temporarily disabled. Only then can the archiving policies work. To set an upload time for all files that do not yet have one, you can use the _occ_ command `lifecycle:set-upload-time`. - -TIP: Files without an _upload time_ will not be considered for archiving. - -TIP: You only have to conduct this process once when setting up File Lifecycle Management on an installation with existing files or if it was temporarily disabled . Files added after enabling File Lifecycle Management will be tracked automatically. - -Example to set missing upload time values to November, 1st 2019: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:set-upload-time 2019-11-01 ----- - -TIP: The extension only considers files. Folder structures are kept available. - -=== Policy Configuration - -==== Overview - -File Lifecycle Management uses policies to determine which files to archive and when, as well as when to expire the files from archive. In addition, a soft and a hard policy are available to control whether users can restore archived files in self-service or not. - -Three options are available for controlling the archiving and expiration policies, all set via the `config:app:set` _occ_ command under the `files_lifecycle` app: - -- `archive_period` - The number of days passed after upload (or restore) that files will be archived -- `expire_period` - The number of days passed after archiving that files will be permanently deleted -- `excluded_groups` - Allows defining groups of users that are exempt from the Lifecycle policies (comma-separated group ids) - -Example to set the time passed since upload (or restore) for archiving files to 90 days: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle archive_period --value='90' ----- - -To query existing values, use this example command: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:get files_lifecycle archive_period ----- - -==== Restoration Policies for Users - -===== Soft Policy - -The _soft policy_ aims at use cases where users should be allowed to restore files from the archive in self-service if they are still needed. It imposes a soft archiving enforcement but on the other hand relieves IT departments when archived files need to be restored. -The _soft policy_ is used by default. To switch from the hard policy to the soft policy, use this _occ_ command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle policy --value='soft' ----- - -===== Hard Policy - -The _hard policy_ is designed to enforce strict controls on user data, forcing archiving after the defined time and requiring escalated permissions in order to restore. If the archived data is still needed, users need to get in contact with a privileged manager and request the restoration. - -TIP: When the _hard policy_ is in place only administrators (or also group administrators, depending on the configuration) are able to restore files from the archive by impersonating the respective users. The {oc-marketplace-url}/apps/impersonate[Impersonate app] has to be installed and enabled as a prerequisite. Apart from that, system administrators can also use _occ_ commands to restore data from the archive (see section xref:restoring-files[Restoring Files]). - -To put the _hard policy_ in place, use this _occ_ command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle policy --value='hard' ----- - -=== Archive and Expiration Background Jobs - -To put File Lifecycle Management into actual operation, there are two _occ_ commands for archiving files and for permanently deleting them from the archive. Scanning the database for files that are due for archiving or expiration, given the chosen policies, can take some time. For this reason, these jobs are delegated to specific _occ_ commands which should be executed using CRON on a daily schedule. - -==== Archiving Background Job -To move files scheduled for archiving (days since upload/restore > `archive_time`) into the archive, execute the following _occ_ command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:archive ----- - -TIP: There is a dry-run mode (append `-d`) that simulates the execution of this command to allow checking the configuration before putting the actual process in place. - -==== Archive Expiration Background Job -To permanently delete files from the archive that have met the policy rules (days since archiving > `expire_period`), execute the following _occ_ command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:expire ----- - -TIP: There is a dry-run mode (append `-d`) that simulates the execution of this command to allow checking the configuration before putting the actual process in place. - -=== Restoring Files - -If archived files are still needed, users can restore them in self-service (_soft policy_) or have to request the restoration via privileged managers (_hard policy_). - -TIP: When files have been restored, they can again be used for the same amount of time as they were initially available. - -Apart from that, system administrators can restore files from the archive using the _occ_ command `lifecycle:restore`: - -==== Restoration by Path -When a user `alice` requests to restore all files, e.g., in the folder `/work/projects/project1`, a system administrator can execute the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:restore /alice/archive/files/work/projects/project1 ----- - -==== Restoring All Files from All Archives -File Lifecycle Management provides a way to restore all files from all archives back to their owners' file directories. To do this, system administrators can use the `restore-all` _occ_ command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} lifecycle:restore-all ----- - -The command will restore all files from all users and report on the progress. - -TIP: There is a dry-run mode (append `-d`) that simulates the execution of this command to allow checking the configuration before putting the actual process in place. - -=== Enabling/Disabling the User Interface Components - -In some scenarios it can be desired to disable the whole user interface for this app. This can be done by setting the following configuration value: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set files_lifecycle disable_ui --value='yes' ----- - -To enable the user interface components again, this config value needs to be removed: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:delete files_lifecycle disable_ui ----- - -== Audit Events - -During archiving, restoring and expiration, Audit events are emitted. Logging those to the `audit.log` requires the minimum version 2.0.0 of the {oc-marketplace-url}/apps/admin_audit[Auditing] app. - -== Further Notes about Archived Files - -- File shares will disappear after archiving. When restoring archived files, shares will also be restored. -- Users' archives currently can't be transferred with the occ command `transfer-ownership` -- Files within a user's trash bin are not archived. The regular trash bin deletion policies have to be used to take care of those. -- Archived files count towards the user's quota diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/file_management/files_tagging.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/file_management/files_tagging.adoc deleted file mode 100644 index 4e559db..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/file_management/files_tagging.adoc +++ /dev/null @@ -1,90 +0,0 @@ -= Advanced File Tagging With the Workflow App -:toc: right -:page-aliases: enterprise/file_management/index.adoc - -== Introduction - -The {oc-marketplace-url}/apps/workflow[Workflow App] enables admins to specify rules and conditions (file size, file mimetype, group membership and more) to automatically assign tags to uploaded files. Based on those tags automated file operations ('Workflow actions') like File Retention (automated file retention periods) can be conducted. The app has three parts: - -* Tag Manager -* Automatic Tagging -* Retention - -The Workflow App should be enabled by default (Apps page), and the three configuration modules will be visible on your ownCloud Admin page. See -xref:classic_ui:files/webgui/tagging.adoc[Tagging Files] -in the ownCloud User manual to learn how to apply and filter tags on files. - -== Tag Manager - -TIP: To use tag management, administrators need to install and enable the {oc-marketplace-url}/apps/systemtags_management[Collaborative Tags Management] app. - -The Tag Manager is used for creating new tags, editing existing tags, and deleting tags. Tags may be marked as *Visible*, *Static*, *Restricted*, or *Invisible*. - -Visible:: -All users may see, rename, and apply these tags to files and folders. - -Static:: -Only users in the specified groups can assign and un-assign the tag to a file. However, only admins can rename and edit the tag. - -Restricted:: -Tags are assignable and editable only to the user groups that you select. Other users can filter files by restricted tags, but cannot tag files with them or rename them. The tags are marked (restricted). - -Invisible:: -Tags are visible only to ownCloud admins. - -To access this functionality, select menu:Settings[Admin > Workflow & Tags]. - -image:enterprise/file_management/workflow-1.png[Tag Manager] - -This is an example of what your tags look like in the *Tags* view on your files page. Non-admin users will not see invisible tags, but visible and restricted tags only. - -image:enterprise/file_management/workflow-5.png[Tag Manager] - -== Automatic Tagging - -The Automatic Tagging module operates on newly-uploaded files. Create a set of conditions, and then when a file or folder matches those conditions it is automatically tagged. The tag must already have been created with the Tag Manager. - -For example, you can assign the invisible tag *iOS Uploads* to all files uploaded from iOS devices. This tag is visible only to admins. - -image:enterprise/file_management/workflow-2.png[Automatic tagging] - -When files with this tag are shared with you, you can view them with the Tags filter on the Files page. - -image:enterprise/file_management/workflow-3.png[Viewing tagged files] - -Automatic Tagging is especially useful with the Retention module. - -The settings of a workflow can be fine-tuned post creation, see the example below: - -image:enterprise/file_management/update_workflow.png[Update Workflow, width=50%] - -== Retention - -The Retention module is your housecleaning power tool, because it automatically deletes files after a time period that you specify. Select which tag to set a time limit on, and then set your time limit. File age is calculated from the file mtime (modification time). - -NOTE: ownCloud does not preserve directory mtimes (modification time), though it does update file mtimes. - -image:enterprise/file_management/workflow-4.png[Setting retention times via tag] - -For best performance, retention tags should be applied high in your file hierarchy. If subfolders have the same tags as their parent folders, their tags must also be processed, so it will take a little longer. - -== Retention Engines - -There are two retention engines that further allow you to fine-tune your retention settings: - -TagBasedRetention:: -This is the default setting and checks files that have a particular tag assigned. Then it checks (depth-first) the children of the tagged item, before continuing with the other tagged items. Children that have already been checked will not be checked a second time. -+ -This is optimised for processing smaller numbers of files that have multiple retention tags. - -UserBasedRetention:: -Examines files per user. It first iterates over all files and folders (siblings first), then examines the tags for those -items and checks their respective retention periods. This is optimised for many files with few retention tags. - -You can define the way that the retention engine behaves by adding the following `config.php` setting. The value can be either -`tagbased` (default) or `userbased`. - -[source,php] ----- -'workflow.retention_engine' => 'userbased', ----- diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/firewall/file_firewall.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/firewall/file_firewall.adoc deleted file mode 100644 index 089126f..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/firewall/file_firewall.adoc +++ /dev/null @@ -1,202 +0,0 @@ -= File Firewall -:toc: right -:page-aliases: enterprise/firewall/index.adoc -:description: The File Firewall app lets you control access and sharing in fine detail by creating rules for allowing or denying access to files. - -:regex-info-url: http://www.regular-expressions.info/ -:supported-mimetype-list-url: https://github.com/owncloud/core/blob/master/resources/config/mimetypemapping.dist.json - -== Introduction - -{description} This is based on: _group_, _upload size_, _client devices_, _IP address_, _time of day_, as well as many more criteria. The File Firewall GUI enables you to manage the firewall rule sets. You can find it in your ownCloud admin page, under menu:Admin[Security]. - -In addition to these restriction options, the File Firewall app also supports rules based on {regex-info-url}[regular expressions]. - -== How the File Firewall Works - -Each firewall rule set consists of one or more conditions. If a request matches all of the conditions in at least one rule set, then the request is blocked by the firewall. Otherwise, the request is allowed by the firewall. - -NOTE: The File Firewall app cannot lock out administrators from the web interface when rules are misconfigured. - -== Using the File Firewall - -Figure 1 shows an empty firewall configuration panel. Set your logging level to *Blocked Requests Only* for debugging, and create a new rule set by clicking btn:[Add Group]. After setting up your rules you must click btn:[Save Rules]. - -image:enterprise/firewall/firewall-1.png[Figure 1: Empty File Firewall configuration panel] - -Figure 2 shows two rules. The first rule, *No Support outside office hours*, prevents members of the support group from logging into the ownCloud Web interface from 5pm-9am and also blocks client syncing. The second rule prevents members of the "qa-team" group from accessing the Web UI from IP addresses that are outside of the local network. - -image:enterprise/firewall/firewall-2.png[Figure 2: Two example rules that restrict logins per user group] - -All other users are not affected, and can log in anytime from anywhere. - -=== Available Conditions - -==== User Group - -The user (is|is not) a member of the selected group. - -==== User Agent - -The User-Agent of the request (matches|does not match) the given string. - -==== User Device - -A shortcut for matching all known (`android` | `ios` | `desktop`) sync clients by their User Agent string. - -==== Request Time - -The time of the request (has to|must not) be in a single range from beginning time to end time. - -==== Request URL - -The *full page URL* (has to contain) with a given string. - -==== Request Type - -The request (is a public link share|other) request. - -==== Request IP Range (IPv4) and IP Range (IPv6) - -The request’s `REMOTE_ADDR` header (is|is not) matching the given IP range. - -==== File Size Upload - -When a file is uploaded the size has to be (less|greater or equal) to the given size. - -==== File Mimetype Upload - -Block a request based on the mimetype of a file being uploaded. The match can be the complete mimetype, part of the mimetype from the start or end of the mimetype. Negative matches are also supported; i.e., all mimetypes that don’t match the supplied mimetype, or all mimetypes that don’t start or end with the partial mimetype supplied. - -The full list of conditions is (File mimetype upload): - -* is -* is not -* begins with -* doesn’t begin with -* ends with -* doesn’t end with - -NOTE: The complete list of available mimetypes which ownCloud supports is available {supported-mimetype-list-url}[in the ownCloud core source]. - -==== Common Mimetypes - -[cols=",",options="header"] -|=== -| suffix | mimetype -| avi | video/x-msvideo -| exe | application/x-ms-dos-executable -| flv | video/x-flv -| mp4 | video/mp4 -| mkv | video/x-matroska -| msi | application/x-msi -| php | application/x-php -|=== - -==== System File Tag - -One of the parent folders or the file itself (is|is not) tagged with a System tag. - -==== Regular Expression - -The File Firewall supports regular expressions, allowing you to create custom rules using the following conditions: - -* File mimetype upload -* Client IP Range (IPv4) -* Client IP Range (IPv6) -* Request URL -* User agent -* User group - -You can combine multiple rules into one rule, e.g., if a rule applies to both the support and the qa-team you could write your rule like this: - -[source,plaintext] ----- -Regular Expression > ^(support|qa-team)$ > is > User group ----- - -CAUTION: We do not recommend modifying the configuration values directly in your `config.php`. These use JSON encoding, so the values are difficult to read and a single typo will break all of your rules. - -=== Controlling Access to Folders - -The easiest way to block access to a folder, starting with ownCloud 9.0, is to use a system tag. A new rule type was added which allows you to block access to files and folders, where at least one of the parents has a given tag. - -Now you just need to add the tag to the folder or file, and then block the tag with the File Firewall. This example blocks access to any folder with the tag "Confidential" from outside access. - -Block by System Tag: - -[source,plaintext] ----- -System file tag: is "Confidential" -IP Range (IPv4): is not "192.168.1.0/24" ----- - -image:enterprise/firewall/firewall-3.png[Protecting files tagged with 'Confidential' from outside access] - -=== Logging - -Firewall logging can be set to **Off**, **Blocked Requests Only** or **All Requests** - -==== Off - -The firewall blocks requests according to the defined rules but does not log any of its actions. - -==== Blocked Requests Only - -The firewall logs blocked requests to the system log at **warning** level. To see these logs, the system log level must be set to a minimum level of **warning**. - -==== All Requests - -The firewall logs blocked and successful requests to the system log at **warning** and **info** levels respectively. To see all these logs, the system log level must be set to a minimum level of **info**. - -NOTE: Logging all requests can generate a large amount of log data. It is recommended to only select all requests for short-term checking of rule settings. - -=== Custom Configuration for Branded Clients - -If you are using branded ownCloud clients, you may define `firewall.branded_clients` in your `config.php` to identify your branded clients in the firewall *"User Device"* rule. - -The configuration is a `User-Agent` => `Device` map. `Device` must be one of the following: - -* android -* android_branded -* ios -* ios_branded -* desktop -* desktop_branded - -The `User-Agent` is always compared all lowercase. By default the agent is compared with `equals`. When a trailing or leading asterisk, `*`, is found, the agent is compared with `starts with` or `ends with`. If the agent has both a leading and a trailing `*`, the string must appear anywhere. For technical reasons the `User-Agent` string must be at least 4 characters, including wildcards. When you build your branded client you have the option to create a custom User Agent. - -In this example configuration you need to replace the example User Agent strings, for example `'android_branded'`, with your own User Agent strings: - -[source,php] ----- -// config.php - -'firewall.branded_clients' => array( - 'my ownbrander android user agent string' => 'android_branded', - 'my ownbrander second android user agent string' => 'android_branded', - 'my ownbrander ios user agent string' => 'ios_branded', - 'my ownbrander second ios user agent string' => 'ios_branded', - 'my ownbrander desktop user agent string' => 'desktop_branded', - 'my ownbrander second desktop user agent string' => 'desktop_branded', -), ----- - -The Web UI dropdown then expands to the following options: - -* Android Client - always visible -* iOS Client - always visible -* Desktop Client - always visible -* Android Client (Branded) - visible when at least one `android_branded` is defined -* iOS Client (Branded) - visible when at least one `ios_branded` is defined -* Desktop Client (Branded) - visible when at least one `desktop_branded` is defined -* All branded clients - visible when at least one of `android_branded`, `ios_branded` or `desktop_branded` is defined -* All non-branded clients - visible when at least one of `android_branded`, `ios_branded` or `desktop_branded` is defined -* Others (Browsers, etc.) - always visible - -Then these options operate this way: - -* The `* Client` options only match `android`, `ios` and `desktop` respectively. -* The `* Client (Branded)` options match the `*_branded` agents equivalent. -* `All branded clients` matches: `android_branded`, `ios_branded` and `desktop_branded` -* `All non-branded clients` matches: `android`, `ios` and `desktop` diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/installation/examples/configuration-file.php b/content/server/10.15/modules/admin_manual/pages/enterprise/installation/examples/configuration-file.php deleted file mode 100644 index 9ce7448..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/installation/examples/configuration-file.php +++ /dev/null @@ -1,15 +0,0 @@ - 'abcdefgh', - 'passwordsalt' => '01234567890123456789', - 'datadirectory' => '/var/data', - 'dbtype' => 'oci', - 'version' => '8.2.x.y', - 'dbname' => 'orcl', - 'dbhost' => '192.168.1.57', - 'dbtableprefix' => 'oc_', - 'dbuser' => 'owncloud1', - 'dbpassword' => '********', - 'installed' => true, -]; diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/installation/install.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/installation/install.adoc deleted file mode 100644 index 6e85785..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/installation/install.adoc +++ /dev/null @@ -1,74 +0,0 @@ -= Installing & Upgrading ownCloud Enterprise Edition -:toc: right -:page-aliases: go/admin-enterprise-license.adoc - -== Introduction - -After you have completed your initial installation of ownCloud as detailed in the README, -follow the instructions in xref:installation/installation_wizard.adoc[The Installation Wizard] -to finish setting up ownCloud. To upgrade your Enterprise server, refer to -xref:maintenance/upgrade.adoc[How to Upgrade Your ownCloud Classic]. - -== Manual Installation - -Download the ownCloud archive from your account at -https://customer.owncloud.com/owncloud, then follow the instructions at -xref:installation/manual_installation/manual_installation.adoc[Manual Installation on Linux]. - -=== SELinux - -Linux distributions that use SELinux need to take some extra steps so -that ownCloud will operate correctly under SELinux. Please see -xref:installation/selinux_configuration.adoc[SELinux Configuration] for some recommended -configurations. - -== License Keys - -=== Introduction - -You need to install a license key to use ownCloud Enterprise Edition. -There are two types of license keys: one is a free 30-day trial key. The -other is a full license key for Enterprise customers. - -You can https://owncloud.com/download/[download and try ownCloud Enterprise for 30 days for free], -which auto-generates a free 30-day key. When this key expires your ownCloud installation is not removed, so -if you become an Enterprise customer you can enter your new key to -regain access. See https://owncloud.com/how-to-buy-owncloud/[How to Buy ownCloud] -for sales and contact information. - -=== Configuration - -Once you get your Enterprise license key, it needs to be copied to your -ownCloud configuration file `config/config.php` like in this example: - -[source,php] ----- -'license-key' => 'test-20150101-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX-YYYYYY', ----- - -It is also possible to activate your Enterprise Edition on the webUI. Open owncloud and navigate to: -menu:Settings[Admin > General]. Copy your license key into the field `Enter a new license:` and click `Save` to confirm. - -Each running instance of ownCloud requires a license key. Keys will work -across upgrades without issue, so new keys will not be required when you -upgrade your ownCloud Enterprise to a new version. - -TIP: if you want to remove the current license, open ownCloud and navigate to menu:Settings[Admin > General] and click btn:[Remove current license key]. - -=== User Counting - -Your ownCloud Enterprise License Key is valid for the purchased amount of users, as per the ownCloud EULA - ownCloud Commercial License. -When you generate a config.report, you will get: - -* a counting of the enabled users, -* the ownCloud guest users -- if the guest app is enabled and -* the number of user directories created. - -The latter is the user number you will need licenses for. Guest users are currently counted with a fair use policy -- which means, that you can't have more guest users than you have licensed users. If you exceed the number of licensed users, please contact your account manager or ownCloud Partner and true-up as per your contract or EULA with us. -The user directories are created on first login. When a user is deleted, the user directories are deleted as well. Users which are disabled count. The last login is not relevant. - -== Supported ownCloud Enterprise Edition Apps - -See xref:installation/apps_supported.adoc[Supported Apps in ownCloud] for a list of supported apps. - -NOTE: 3rd party and unsupported apps must be disabled before performing a system upgrade. Then install the upgraded versions, and after the upgrade is complete re-enable them. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/installation/oracle_db_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/installation/oracle_db_configuration.adoc deleted file mode 100644 index 5d1f7a6..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/installation/oracle_db_configuration.adoc +++ /dev/null @@ -1,230 +0,0 @@ -= Oracle Database Setup & Configuration -:toc: right -:php_oci8_url: https://pecl.php.net/package/oci8 -:ubuntu_community_guide_url: https://help.ubuntu.com/community/Oracle%20Instant%20Client - -== Introduction - -This document will cover the setup and preparation of the ownCloud -server to support the use of Oracle as a backend database. - -== Outline of Steps - -This document will cover the following steps: - -* Setup of the ownCloud user in Oracle: This involves setting up a user -space in Oracle for setting up the ownCloud database. -* Installing the Oracle Instant Client on the Web server (facilitating -the connection to the Oracle Database). -* Compiling and installing the Oracle PHP Plugin oci8 module -* Pointing ownCloud at the Oracle database in the initial setup process - -The document assumes that you already have your Oracle instance running, -and have provisioned the needed resources. It also assumes that you have -installed ownCloud with all of the prerequisites. - -== Configuring Oracle - -=== Setting up the User Space for ownCloud - -Step one, if it has not already been completed by your -DBA (DataBase Administrator), provision a user space on the Oracle -instance for ownCloud. This can be done by logging in as a DBA and -running the script below: - -[source,sql] ----- -CREATE USER owncloud IDENTIFIED BY password; -ALTER USER owncloud DEFAULT TABLESPACE users TEMPORARY TABLESPACE temp QUOTA unlimited ON users; -GRANT create session, create table, create procedure, create sequence, create trigger, create view, create synonym, alter session TO owncloud; ----- - -Substitute an actual password for `password`. Items like _TableSpace_, -_Quota_ etc., will be determined by your DBA (database administrator). - -=== Add OCI8 Client Packages - -Installation of the OCI8 client is dependent on your distribution. Given -that, please use the relevant section below to find the relevant -instructions to install the client. - -==== Ubuntu - -If you’re using Ubuntu, we recommend that you use this very thorough guide to install the {ubuntu_community_guide_url}[Oracle Instant Client] (OCI8) extension from the Ubuntu Community Wiki. - -NOTE: This _should_ work for other Debian-based distributions too, however your mileage may vary. - -==== RedHat / Centos / Fedora - -To install the OCI8 extension on a RedHat-based distribution, you first -need to download two Oracle Instant Client packages: - -* Instant Client Package - Basic (`oracle-instantclient12.2-basic-12.2.0.1.0-1.x86_64.rpm`) -* Instant Client Package - SDK (`oracle-instantclient12.2-devel-12.2.0.1.0-1.x86_64.rpm`) - -Then, to install them, use the following commands: - -[source,bash] ----- -rpm --install oracle-instantclient12.2-basic-12.2.0.1.0-1.x86_64.rpm \ - oracle-instantclient12.2-devel-12.2.0.1.0-1.x86_64.rpm ----- - -=== Install the OCI8 PHP Extension - -With the Oracle packages installed you’re now ready to install PHP’s {php_oci8_url}[OCI8] extension, where you have to specify the correct OCI8 version. For PHP7.x use `oci8-2.2.0` - -NOTE: Provide: `instantclient,/usr/lib/oracle/12.2/client64/lib` when requested, or let it auto-detect the location, if possible. - -[source,bash] ----- -sudo pecl install oci8-2.2.0 ----- - -With the extension installed, you now need to configure it, by creating -a configuration file for it. You can do so using the command below, -substituting `FILE_PATH` with one from the list below the command. - -[source,bash] ----- -cat << EOF > FILE_PATH -; Oracle Instant Client Shared Object extension -extension=oci8.so -EOF ----- - -==== Configuration File Paths - -Debian & Ubuntu -+++++++++++++++ - -[cols=",",options="header",] -|=== -| PHP Version -| Filename -| {minimum-php-printed} -| `/etc/php/{minimum-php-version}/apache2/conf.d/20-oci.ini` -|=== - -RedHat, Centos, & Fedora -++++++++++++++++++++++++ - -[cols=",",options="header",] -|=== -| PHP Version -| Filename -| {minimum-php-printed} -|`/etc/opt/rh/rh-php{minimum-php-version-short-code}/php.d/20-oci8.ini` -|=== - -=== Validating the Extension - -With all that done, confirm that it’s been installed and available in -your PHP distribution, run the following command: - -[source,bash] ----- -php -m | grep -i oci8 ----- - -When the process has completed, assuming that you don’t encounter any -errors, restart Apache and the extension is ready to use. - -== Configure ownCloud - -The next step is to configure the ownCloud instance to point to the -Oracle Database, again this document assumes that ownCloud has -previously been installed. - -=== Configuration Wizard - -image:oracle-1.png[image,width=554,height=711] - -==== Database user - -This is the user space created in step 2.1. In our Example this would be -owncloud. - -==== Database password - -Again this is defined in the script from section 2.1 above, or -pre-configured and provided to you by your DBA. - -==== Database Name - -Represents the database or the service that has been pre-configured on -the TSN Listener on the Database Server. This should also be provided by -the DBA. In this example, the default setup in the Oracle install was -orcl (there is a TSN Listener entry for orcl on our database server). - -This is not like setting up with MySQL or SQL Server, where a database -based on the name you give is created. The oci8 code will call this -specific service and it must be active on the TSN Listener on your -Oracle Database server. - -==== Database Table Space - -Provided by the DBA. In this example the users table space (as is seen -in the user creation script above), was used. - -=== Configuration File - -Assuming all of the steps have been followed to completion, the first -run wizard should complete successfully, and an operating instance of -ownCloud should appear. - -The configuration file should look something like this: - -=== Useful SQL Commands - -*Is my Database Reachable?* - -On the machine where your Oracle database is installed, type: - -[source,bash] ----- -sqlplus username ----- - -[source,sql] ----- -SQL> select * from v$version; - -BANNER --------------------------------------------------------------------------------- -Oracle Database 11g Express Edition Release 11.2.0.2.0 - 64bit Production -PL/SQL Release 11.2.0.2.0 - Production -CORE 11.2.0.2.0 Production -TNS for Linux: Version 11.2.0.2.0 - Production -NLSRTL Version 11.2.0.2.0 - Production - -SQL> exit ----- - -*Show Database Users*: - -[source,sql] ----- -Oracle : SELECT * FROM all_users; ----- - -*Show available Databases*: - -[source,sql] ----- -Oracle : SELECT name FROM v$database; (requires DBA privileges) ----- - -*Show ownCloud Tables in Database*: - -[source,sql] ----- -Oracle : SELECT table_name FROM user_tables; ----- - -*Quit Database*: - -[source,sql] ----- -Oracle : quit ----- diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/logging/admin_audit.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/logging/admin_audit.adoc deleted file mode 100644 index 683b2a3..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/logging/admin_audit.adoc +++ /dev/null @@ -1,865 +0,0 @@ -= Auditing -:toc: right -:toclevels: 3 -:page-aliases: enterprise/logging/enterprise_logging_apps.adoc, enterprise/logging/index.adoc - -:splunk-url: https://splunkbase.splunk.com/app/5503/ - -== Introduction - -The {oc-marketplace-url}/apps/admin_audit[Auditing] app is an Enterprise only app and available on the marketplace. It traces user and admin actions, in particular the following events: - -* Login and logout events of users -* File system operations (create / delete / move; including actions on the trash bin and versioning) -* Sharing operations (user / group sharing, sharing via link, changing permissions, calls to sharing API from clients) -* Custom Groups events -* File tagging operations (add / remove tags) -* File commenting operations (create / update / delete) -* User management operations (creation / deletion / activation / deactivation of users, group management) -* User settings changes -* Impersonation events -* Enabling / disabling of ownCloud Apps -* Executions of OCC commands (CLI) - -TIP: You may also want to check out the {splunk-url}[_ownCloud App for Splunk_]. For more information, read this xref:configuration/integration/splunk.adoc[section]. - -== Installation and Enabling - -Download the {oc-marketplace-url}/apps/admin_audit[Auditing] app from the marketplace and enable it in the ownCloud app settings. - -.Figure 1 Auditing -image:enterprise/logging/admin_auditing.png[Auditing] - -== Configuration - -It is advised to redirect messages into a separate file. To do so, add these lines to `config.php` and adjust the target path accordingly. Otherwise make sure to adjust the server log level to 1 (or 0), or else the Auditing app won't log anything. Configuring a separate file circumvents the global log level. Note that the target path must be writable for the web server user: - -[source,php] ----- -'log.conditions' => [ - [ - 'apps' => ['admin_audit'], - 'logfile' => '/var/www/owncloud/data/admin_audit.log' - ] -] ----- - -NOTE: All messages regardless of log level will be logged there. - -To ignore all CLI triggered events (default is to include them), set the following option: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set admin_audit ignore_cli_events --value='yes' ----- - -== Grouped Logging - -With each log message, a number of users are calculated to be the 'audit context'. This is the list of users which are related to the log message. Additionally, each log message includes a list of groups that the users are a member of, to enable filtering / splitting of the log messages at a later date. In cases when users are members of many groups, to reduce the data output, the group list can be filtered by adding the following to your `config.php`. Change the groups needed accordingly: - -[source,php] ----- -'admin_audit.groups' => [ - 'group1', - 'group2' -] ----- - -When the filter is configured, only the filtered list of groups will be output in _auditGroups_, else, all groups that the _auditUsers_ are a member of are output. - -== View and Download Logs - -NOTE: If you have configured a different logfile than the default, you must download it manually. - -To download your logfile on your admin page. Click menu:Settings[Admin > Download logfile]. The default location for manually downloading the standard ownCloud log is `data/owncloud.log`. - -TIP: See xref:configuration/server/logging/logging_configuration.adoc[Logging Configuration] and xref:enterprise/file_management/files_tagging.adoc[File Tagging] for more information on logging and tagging. - -== Connect with Splunk Cloud - -=== Install the Universal Forwarder - -Connect to the deployment server, change `input-prd-your-server-here` according your setup: - -`splunk set deploy-poll input-prd-your-server-here.cloud.splunk.com:8089` - -=== Install the Splunk Cloud credentials - -`splunk install app path/to/splunkclouduf.spl -auth admin:changeme` - -=== Monitor the `admin_audit.log` - -To Monitor the ownCloud Splunk audit log, add this to `inputs.conf`, assuming you use the custom logging path/file from above: - -[source,plaintext] ----- -[monitor://var/www/owncloud/data/admin_audit.log] - disabled = false - sourcetype = _json - index = main ----- - -Finally, configure the following `props.conf` to ensure the time field is correctly used and the fields are extracted. - -[source,plaintext] ----- -[_json] - INDEXED_EXTRACTIONS = json - KV_MODE = json - TIMESTAMP_FIELDS = [Time] - category = Structured ----- - -=== Extra Fields - -The audit app listens for internal ownCloud events and hooks and produces a rich set of audit entries useful for reporting on usage of your ownCloud server. - -Log entries are based upon the internal ownCloud logging system, but utilise extra fields to hold relevant data fields related to the specific event. Each event will contain the following data at a minimum: - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `remoteAddr` | string | The remote client IP -| `user` | string | The UID of the user performing the action, + -or `IP x.x.x.x.`, `cron`, `CLI`, `unknown` -| `url` | string | The process request URI -| `method` | string | The HTTP request method -| `userAgent` | string | The HTTP request user agent -| `time` | string | The time of the event e.g.: `2018-05-08T08:26:00+00:00` -| `app` | string | Always `admin_audit` -| `message` | string | Sentence explaining the action -| `action` | string | Unique action identifier e.g.: + -`file_delete` or `public_link_created` -| `CLI` | boolean | If the action was performed from the CLI -| `level` | integer | The log level of the entry (usually `1` for audit events) -|=== - -=== Output - -==== Files - -===== file_create - -When a file is created. - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `path` | string | The full path to the create file -| `owner` | string | The UID of the owner of the file -| `fileId` | string | The newly created files identifier -|=== - -===== file_read - -When a file is read. - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `path` | string | The full path to the file -| `owner` | string | The UID of the owner of the file -| `fileId` | string | The files identifier -|=== - -===== file_update - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `path` | string | The full path to the updated file -| `owner`| string | The UID of the owner of the file -| `fileId` | string | The updated files identifier -|=== - -===== file_delete - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `path` | string | The full path to the updated file -| `owner` | string | The UID of the owner of the file -| `fileId` | string | The updated files identifier -|=== - -===== file_copy - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `oldPath` | string | The full path to the source file -| `path` | string | The full path to the new file -| `sourceOwner` | string | The UID of the owner of the source file -| `owner` | string | The UID of the owner of the file -| `sourceFileId` | string | The source files identifier -| `fileId` | string | The new files identifier -|=== - -===== file_rename - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `oldPath` | string | The original path file -| `path` | string | The new path file -| `fileId` | string | The files identifier -|=== - -===== file_trash_delete - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `owner` | string | The UID of the owner of the file -| `path` | string | The full path to the deleted file -|=== - -===== file_trash_restore - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `owner` | string | The UID of the owner of the file -| `fileId` | string | The restored files identifier -| `oldPath` | string | The original path to the file -| `newPath` | string | The new path to the file -| `owner` | string | The UID of the owner of the file -|=== - -===== file_version_delete - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `path` | string | The full path to the version file deleted -| `trigger` | string | The delete trigger reasoning -|=== - -===== file_version_restore - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `path` | string | The full path to the file being restored to the new version -| `revision` | string | The revision of the file restored -|=== - -==== Users - -===== user_created - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The UID of the created user -|=== - -===== user_password_reset - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The UID of the user -|=== - -===== group_member_added - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The UID of the user -| `group` | string | The GID of the group -|=== - -===== user_deleted - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The UID of the user -|=== - -===== group_member_removed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The UID of the user -| `group` | string | The GID of the group -|=== - -===== user_state_changed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The UID of the user -| `enabled` | boolean | If the user is enabled or not -|=== - -===== group_created - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `group` | string | The GID of the group -|=== - -===== group_deleted - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `group` | string | The GID of the group -|=== - -===== user_feature_changed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The UID of the user -| `group` | string | The GID of the group (or empty string) -| `feature` | string | The feature that was changed -| `value` | string | The new value -|=== - -==== Sharing - -Sharing events come with a default set of fields - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `fileId` | string | The file identifier for the item shared -| `owner` | string | The UID of the owner of the shared item -| `path` | string | The path to the shared item -| `shareId` | string | The sharing identifier + -(not available for public_link_accessed or when recipient unshares) -|=== - -===== file_shared - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | `file` or `folder` -| `expirationDate` | string | The text expiration date in format `yyyy-mm-dd` -| `sharePass` | boolean | If the share is password protected -| `permissions` | string | The permissions string e.g.: "READ" -| `shareType` | string | `group` `user` or `link` -| `shareWith` | string | The UID or GID of the share recipient + -(not available for public link) -| `shareOwner` | string | The UID of the share owner -| `shareToken` | string | For link shares the `unique token`, else `null` -|=== - -===== file_unshared - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | `file` or `folder` -| `shareType` | string | `group` `user` or `link` -| `shareWith` | string | The UID or GID of the share recipient -|=== - -===== share_permission_update - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | `file` or `folder` -| `shareType` | string | `group` `user` or `link` -| `shareOwner` | string | The UID of the share owner -| `permissions` | string | The new permissions string e.g.: "READ" -| `shareWith` | string | The UID or GID of the share recipient + -(not available for public link) -| `oldPermissions` | string | The old permissions string e.g.: "READ" -|=== - -===== share_name_updated - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `oldShareName` | string | The previous share name -| `shareName` | string | The updated share name -|=== - -===== share_password_updated - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | `file` or `folder` -| `shareOwner` | string | The UID of the share owner -| `permissions` | string | The full permissions string e.g.: "READ" -| `shareToken` | string | The share token -| `sharePass` | boolean | If the share is password protected -|=== - -===== share_expiration_date_updated - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | `file` or `folder` -| `shareType` | string | `group`, `user` or `link` -| `shareOwner` | string | The UID of the owner of the share -| `permissions` | string | The permissions string e.g.: "READ" -| `expirationDate` | string | The new text expiration date in format `yyyy-mm-dd` -| `oldExpirationDate` | string | The old text expiration date in format `yyyy-mm-dd` -|=== - -===== share_accepted - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | `file` or `folder` -| `path` | string | The path of the shared item -| `owner` | string | The UID of the owner of the shared item -| `fileId` | string | The file identifier for the item shared -| `shareId` | string | The sharing identifier (not available for public_link_accessed) -| `shareType` | string | `group` or `user` -|=== - -===== share_declined - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | `file` or `folder` -| `path` | string | The path of the shared item -| `owner` | string | The UID of the owner of the shared item -| `fileId` | string | The file identifier for the item shared -| `shareId` | string | The sharing identifier (not available for public_link_accessed) -| `shareType` | string | `group` or `user` -|=== - -===== federated_share_received - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `name` | string | The path of shared item -| `targetuser` | string | The target user who sent the item -| `shareType` | string | `remote` -|=== - -===== federated_share_accepted - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | The path of shared item -| `targetUser` | string | The target user who sent the item -| `shareType` | string | `remote` -|=== - -===== federated_share_declined - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `itemType` | string | The path of shared item -| `targetuser` | string | The target user who sent the item -| `shareType` | string | `remote` -|=== - -===== public_link_accessed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `shareToken` | string | The share token -| `success` | boolean | If the request was successful `tue` or `false` -|=== - -===== public_link_removed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `shareType` | string | `link` -|=== - -===== public_link_accessed_webdav - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `token` | string | The token used to access the url -|=== - -===== federated_share_unshared - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The user who initiated the unshare action -| `targetmount` | string | The file/folder unshared -| `shareType` | string | `remote` -|=== - -==== Custom Groups - -===== custom_group_member_removed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `removedUser` | string | The UID of the user that was removed from the group -| `group` | string | The custom group name -|=== - -===== custom_group_user_left - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `removedUser` | string | The UID of the user that left the group -| `group` | string | The custom group name -| `groupId` | integer | The custom group id -|=== - -===== custom_group_user_role_changed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetUser` | string | The UID of the user that changed role -| `group` | string | The custom group name -| `groupId` | integer | The custom group id -| `roleNumber` | integer | The new role number: 0 = member, 1= admin -|=== - -===== custom_group_renamed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `oldGroup` | string | The old custom group name -| `group` | string | The new custom group name -| `groupId` | integer | The custom group id -|=== - -===== custom_group_created - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `group` | string | The custom group name created -| `groupId` | string | The custom group id -| `addedUser` | string | The UID of the user added -| `admin` | boolean | `true` or `false` -|=== - -==== Comments - -All comment events have the same data: - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `commentId` | string | The comment identifier -| `path` | string | The path to the file that the comment is attached to -| `fileId` | string | The file identifier -|=== - -// ===== comment_created - -// ===== comment_deleted - -// ===== comment_updated - -==== Config - -===== config_set - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `settingName` | string | The key -| `settingValue` | string | The new value -| `oldValue` | string | The old value -| `created` | boolean | If the setting is created for the first time -|=== - -===== config_delete - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `settingName` | string | The key -|=== - -==== Console - -===== command_executed - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `command` | string | The exact command that was executed -|=== - -==== Tags - -===== tag_created - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `tagName` | string | The tag name -|=== - -===== tag_deleted - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `tagName` | string | The tag name -|=== - -===== tag_updated - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `oldTag` | string | The old tag name -| `tagName` | string | The new tag name -|=== - -===== tag_assigned - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `tagName` | string | The tag name -| `fileId` | string | The file identifier to which the tag was assigned -| `path` | string | The path to the file -|=== - -===== tag_unassigned - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `tagName` | string | The tag name -| `fileId` | string | The file identifier from which the tag was unassigned -| `path` | string | The path to the file -|=== - -==== Apps - -===== app_enabled - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetApp` | string | The app ID of the enabled app -| `groups` | string [] | Array of group IDs if the app was enabled for certain groups -|=== - -===== app_disabled - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `targetApp` | string | The app ID of the disabled app -|=== - -==== Auth - -===== user_login - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `success` | boolean | If the login was successful -| `login` | string | The attempted login value -|=== - -===== user_logout - -//==== Holding Period - -//(requires at least v0.1.3) - -==== File Lifecycle - -(requires at least v1.0.0) - -===== lifecycle_archived - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `path` | string | The path to the file that was archived -| `owner` | string | The UID of the owner of the file that was deleted -| `fileId` | integer | The file ID for the file that was archived -|=== - -===== lifecycle_restored - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `path` | string | The path to the file that was restored -| `fileId` | integer | The file ID for the file that was restored -|=== - -===== lifecycle_expired - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `fileId` | integer | The file id of the file that was expired -|=== - -===== update_user_preference_value - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `key` | string | The key -| `value` | string | The value associated with the key -| `appname` | string | The name of the app -| `user` | string | The UID of the user who has the preference key-value for the app -|=== - -===== user_preference_set - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `key` | string | The key -| `value` | string | The value associated with the key -| `appname` | string | The name of the app -| `user` | string | The UID of the user who has the preference key-value for the app -|=== - -===== remove_user_preference_key - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `key` | string | The key -| `appname` | string | The name of the app -| `user` | string | The UID of the user whose preference key is deleted for the app -|=== - -===== remove_preferences_of_user - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `user` | string | The UID of the user whose user preferences are deleted -|=== - -===== delete_all_user_preference_of_app - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `appname` | string | The name of the app whose user preferences are deleted -|=== - -==== Impersonate - -===== impersonated - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `user` | string | The current user who did an impersonate action -| `targetUser` | string | The user who is being impersonated -|=== - -===== impersonate_logout - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `user` | string | The user who performed impersonate action -|=== - -==== SMB ACL - -===== before_set_acl - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `user` | string | The user who is trying to set the ACL -| `ocPath` | string | The owncloud instance path -| `smbPath` | string | The SMB path -| `descriptor` | array | The descriptor array. It contains to following keys: -|=== - -[caption=] -.`descriptor[] keys` -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `revision` | integer | Always `1` -| `owner` | string | The SMB owner -| `group` | string | The SMB group -| `acl` | array | A list of ACEs. The list could be empty. Each ACE contains following keys: -|=== - -[caption=] -.`acl[] keys` -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `trustee` | string | The SMB user affected by this ACE -| `mode` | string | `allowed` or `denied` -| `flags` | string | Inheritance flags -| `mask` | string | Permission mask -| `flagsAsInt` | integer | The inheritance flags as integer value -| `maskAsInt` | integer | The permission mask as integer value -|=== - -===== after_set_acl - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `user` | string | The user who is trying to set the ACL -| `ocPath` | string | The owncloud instance path -| `smbPath` | string | The SMB path -| `descriptor` | array | The descriptor array. It contains to following keys: -|=== - -[caption=] -.`descriptor[] keys` -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `revision` | integer | Always `1` -| `owner` | string | The SMB owner -| `group` | string | The SMB group -| `acl` | array | A list of ACEs. The list could be empty. Each ACE contains following keys: -|=== - -[caption=] -.`acl[] keys` -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `trustee` | string | The SMB user affected by this ACE -| `mode` | string | `allowed` or `denied` -| `flags` | string | Inheritance flags -| `mask` | string | Permission mask -| `flagsAsInt` | integer | The inheritance flags as integer value -| `maskAsInt` | integer | The permission mask as integer value -|=== - -[width="100%",cols="25%,20%,100%",options="header"] -|=== -| Key | Type | Description -| `oldDescriptor` | array\|false | The previous descriptor array or false if the previous descriptor couldn't be fetched. The previous descriptor will have the same keys -|=== diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/reporting/config_report.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/reporting/config_report.adoc deleted file mode 100644 index da6f2c7..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/reporting/config_report.adoc +++ /dev/null @@ -1,7 +0,0 @@ -= Generate a Config Report -:toc: right -:description: Generating a config report when using an Enterprise version does not differ from the Community Edition. - -== Introduction - -{description} For more details see the documentation how to xref:troubleshooting/providing_logs_and_config_files.adoc#generate-a-config-report[Generate a Config Report]. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/reporting/metrics.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/reporting/metrics.adoc deleted file mode 100644 index 0db3710..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/reporting/metrics.adoc +++ /dev/null @@ -1,170 +0,0 @@ -= Metrics -:toc: right -:toclevel: 2 -:page-aliases: enterprise/reporting/index.adoc - -== Introduction - -The {oc-marketplace-url}/apps/metrics[Metrics App] provides a building block for reporting of ownCloud -Server. For simple use cases, it ships with an integrated dashboard that summarizes information -about users, storage as well as shares and allows exporting it to a CSV file. Additionally, it adds a -Metrics HTTP API endpoint to ownCloud Classic, which can be used to obtain the Metrics data in regular -intervals. Thus, more sophisticated analysis and visualizations can be conducted. - -The Metrics data are provided as snapshot values in the JSON format and are optimized to be consumed by -professional data analyzers (like Splunk, ELK or Prometheus/Grafana) to collect statistics, derive -visualizations and to set alerts for certain events of interest. They can be perfectly combined with the -ownCloud Audit Logs (provided by the {oc-marketplace-url}/apps/admin_audit[Auditing App]) to gather time -series data and to create a reporting engine for ownCloud. - -NOTE: Internet Explorer 11 is not compatible with Metrics, because new web technologies have been used that are not supported by IE 11. - -If you want to use Splunk in addition, check out xref:configuration/integration/splunk.adoc[ownCloud App for Splunk]. - -Specifically, the Metrics extension adds: - -- an API endpoint which allows querying snapshot values of the system data as well as per-user metrics -- API endpoints for downloading metrics as CSV files -- a dashboard that displays the snapshot data in the ownCloud Web UI and offers a CSV download in the system view and the user view. - -TIP: If you're operating very large instances with regard to users, files or shares, better use a -special setup so you won't put the production database under huge load when gathering the values. For -this, replicate your installation (application server and read-only database) and install and use the -Metrics app on the replica. - -The following screenshots give you an impression of the Metrics app. - -.Figure 1. Metrics System Overview -image:enterprise/reporting/metrics/metrics-system.png[Metrics System Overview] - -.Figure 2. Metrics User Overview -image:enterprise/reporting/metrics/metrics-user.png[Metrics User Overview] - -== Available Data - -The following data is available for analysis: - -.**System data** -* Date/Time stamp - Server time of the request -* Storage - ** Used storage (this includes both, data that count against user Quotas `usedQuota`, and `usedOther` like avatars, thumbnails and file versions) - ** Free storage - ** Total storage (used + free) - ** Number of files -* Number of users - ** registered (total number of known users) - ** active (number of users with `lastLogin` less than two weeks ago) - ** concurrent (number of users with at least one active session) -* Shares - ** Number of user shares - ** Number of group shares - ** Number of guest shares - ** Number of link shares - ** Number of federated shares - -.**Per-user data** -* User ID -* Display name -* User backend -* Last login -* Active sessions -* Quota - ** Quota limit - ** Quota usage -* Number of files -* Shares - ** Number of user shares - ** Number of group shares - ** Number of guest shares - ** Number of link shares - ** Number of federated shares - -== Usage - -=== Authorization - -To get started, you have to set a secret for authenticating requests at the endpoint. - -See the following occ command on how to set it. Make up a passphrase, referred to as `` in the example below. The Metrics secret is necessary to use the dashboard. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set "metrics_shared_secret" --value "" ----- - -TIP: This token gets stored in config.php as `metrics_shared_secret`, which could also be done manually -instead of using the occ command. - -=== Dashboard User Interface - -The dashboard is enabled by default. You can disable it with the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set metrics disable_dashboard --value=yes ----- - -=== Endpoints and Parameters - -==== Metrics Endpoint - -To query for the Metrics data, use the following endpoint: - -[source,plaintext] ----- -https:///ocs/v1.php/apps/metrics/api/v1/metrics ----- -* URL Parameters - ** `users=true` - ** `shares=true` - ** `quota=true` - ** `userData=true` - ** `format=json` -* Header `"OC-MetricsApiKey: "` - -Except for the header, all other parameters are optional. You can split the query into parts by setting the respective parameters to `false`. - -See the `curl` example to request the complete output: - -[source,bash] ----- -curl -H "OC-MetricsApiKey: " \ - "https:///ocs/v1.php/apps/metrics/api/v1/metrics?users=true&files=true&shares=true"a=true&userData=true&format=json" ----- - -TIP: Replace `` with your respective system config value and `` -with the URL of your ownCloud instance. - -==== CSV Download Endpoints - -Downloading the current user and system metrics as CSV files is possible via the Web UI. If you want to -set up cron jobs for downloading the metrics regularly without admin permissions, there are also public -endpoints that require the configured token instead of admin privileges. - -TIP: In the following `curl` examples, replace `` with your respective system config value and `` with the URL of your ownCloud instance. - -To receive user metrics, use: - -[source,bash] ----- -curl -H "Content-Type: application/csv" \ - -H "OC-MetricsApiKey: " \ - -X GET https:///index.php/apps/metrics/download-api/users > \ - /path/to/download/storage/user-metrics.csv ----- - -For system metrics, use: - -[source,bash] ----- -curl -H "Content-Type: application/csv" \ - -H "OC-MetricsApiKey: " \ - -X GET https:///index.php/apps/metrics/download-api/system > \ - /path/to/download/storage/system-metrics.csv ----- - -== Limitations - -The Metrics app was designed for ownCloud deployments up to 250 users. -On deployments with more than 250 users, it can take considerably longer to gather the requested data. -To reduce the time needed, exclude _userData_ and _quota_. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/security/ransomware-protection.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/security/ransomware-protection.adoc deleted file mode 100644 index 90cc29c..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/security/ransomware-protection.adoc +++ /dev/null @@ -1,221 +0,0 @@ -= Ransomware Protection -:toc: right -:page-aliases: enterprise/ransomware-protection/index.adoc, \ -configuration/server/security/ransomware-protection.adoc, \ -enterprise/security/ransomware-protection/index.adoc, \ -enterprise/security/index.adoc - -== Introduction - -Ransomware is -https://www.google.de/search?q=ransomware&source=lnms&tbm=nws&sa=X&ved=0ahUKEwiqmvL9rdfXAhWCyaQKHSkgDosQ_AUICigB&biw=1680&bih=908[an ever-present threat], -both for large enterprises as well as for individuals. Once infected, a whole hard disk (or just parts of it) can -become encrypted, leading to unrecoverable data loss. - -Once this happens, attackers usually ask victims to pay a ransom, often -via cryptocurrencies such as Bitcoin, in exchange for the decryption key -required to decrypt their data. - -While paying the ransom works in some cases, it is not recommended, as -there is no guarantee that the attackers will supply the key after -payment is made. To help mitigate such threats and ensure ongoing access -to user data, ownCloud provides the Ransomware Protection app. - -NOTE: It is essential to be aware that user data needs to be synchronized with you ownCloud Classic using the -ownCloud Desktop synchronization client. Data that is not synchronized and stored in ownCloud cannot be protected. - -== About Ransomware Protection - -The app is tasked with _detecting_, _preventing_, and _reverting_ -anomalies. Anomalies are file operations (including _create_, _update_, -_delete_, and _move_) not intentionally conducted by the user. It aims -to do so in two ways: xref:prevention-blocking-common-ransomware-file-extensions[prevention], and -xref:other-elements-of-ransomware-protection[protection]. - -== Prevention: Blocking Common Ransomware File Extensions - -Like other forms of cyberattack, ransomware has a range of diverse -characteristics. On the one hand it makes them hard to detect and on the -other it makes them even harder to prevent. Recent ransomware attacks -either encrypt a user’s files and add a specific file extension to them -(e.g., `.crypt`), or they replace the original files with an encrypted -copy and add a particular file extension. - -=== File Extension Blacklist - -The first line of defense against such threats is a blacklist that -blocks write access to file extensions known to originate from -ransomware. - -Ransomware Protection ships with https://fsrm.experiant.ca[a static extension list] -of more than 3,000 file extensions. As new extensions are -regularly created, this list also needs to be regularly reviewed and -updated. Future releases of Ransomware Protection will include an -updated list and the ability to update the list via syncing with -https://fsrm.experiant.ca/api/v1/combined[FSRM’s API] by using an -xref:configuration/server/occ_command.adoc[occ command] - -NOTE: Please check the provided ransomware blacklist! It is *strongly recommended* to check the provided ransomware blacklist to ensure that it fits your needs. In some cases, the patterns might be too generic and result in false positives. - -=== File Blocking - -The second line of defense is file blocking. As files are uploaded, they -are compared against the file extension blacklist. If a match is found, -the upload is denied. - -NOTE: File blocking is always enabled. - -=== Account Locking - -The third line of defense is account locking. If a client uploads a file -matching a pattern in the ransomware blacklist, the account is locked -(set as read-only) for client access (_create_, _change_, _move_, and -_delete_ operations). Doing this prevents further, malicious, changes. - -Following this, clients receive an error (403 Access Forbidden) which -notifies the user that the account is locked by Ransomware Protection. - -NOTE: Write access (e.g., moving and deleting files) is still possible for users when they log in with their web browser. - -When an account is locked, administrators can unlock the account using -the `occ ransomguard:unlock` command. Administrators can also manually -lock user accounts, using the `occ ransomguard:lock` command. - -NOTE: When an account is locked, it will still be fully usable from the ownCloud web UI. However, ownCloud clients (as well as other WebDAV clients) will see the account as set to read-only mode. - -Users will see a yellow notification banner in the ownCloud web UI -directing them to menu:Settings[Personal > Security] -(`__Ransomware detected: Your account is locked (read-only) for client access to -protect your data. Click here to unlock.__`), where additional -information is displayed and users can unlock their account when -ransomware issues are resolved locally. - -NOTE: Locking is enabled by default. If this is not desired, an administrator can disable it in the -menu:Settings[Admin > Security] panel. - -== Protection: Data Retention and Rollback - -While Ransomware Prevention mitigates risks of a range of ransomware -attacks, it is not a future-proof solution, because ransomware is -becoming ever-more sophisticated. There are known attacks that change -file extensions randomly or keep them unchanged which makes them harder -to detect. - -Ultimately there is a consensus that only one solution can provide -future-proof protection from ransomware attacks: retaining data and -providing the means to roll back to a particular point in time. - -ownCloud Ransomware Protection will, therefore, record all changes on an -ownCloud Classic and allow administrators to rollback user data to a -particular point in time, making use of ownCloud’s integrated Versioning -and Trash bin features. - -Doing so allows all user data that is synchronized with the server to be -rolled back to its state before the attack occurred. A combination of -Ransomware prevention and protection reduces risks to a minimum acceptable level. - -== Other Elements of Ransomware Protection - -[cols=",,",options="header",] -|=== -| Name -| Command (if applicable) -| Description - -| Ransomware Prevention (Blocker) -| -| First line of defense against ransomware attacks. Ransomware Protection uses a file name pattern blacklist to prevent uploading files that have file extensions associated with ransomware (e.g. `.crypt`) thereby preserving the original files on the ownCloud Classic server. - -| Ransomguard Scanner -| `occ ransomguard:scan ` -| A command to scan the ownCloud database for changes in order to discover anomalies in a user’s account and their origin. It enables an administrator to determine the point in time when undesired actions happened as a prerequisite for restoration. - -| Ransomguard Restorer -| `occ ransomguard:restore ` -| A command for administrators to revert all operations in a user account that occurred after a certain point in time. - -| Ransomguard Lock -| `occ ransomguard:lock ` -| Set a user account as read-only for ownCloud and other WebDAV clients. This prevents any further changes to the account. - -| Ransomguard Unlock -| `occ ransomguard:unlock ` -| Unlock a user account which was set to read-only. - -| Ransomguard Blacklist Set-File -| `occ ransomguard:blacklist:set-file ` -| Define the location of the required blacklist file. - -| Ransomguard Blacklist From-File -| `occ ransomguard:blacklist:update:from-file ` -| Update the blacklist file with content from another file. - -| Ransomguard Blacklist From-Site -| `occ ransomguard:blacklist:update:from-site ` -| Update the blacklist file with content from a URL. -|=== - -`` must be in the Linux timestamp format. - -== Requirements - -=== Mandatory - -1. *File Firewall rule (previous approach for ransomware protection).* -If you have configured the File Firewall rule which was provided as a -preliminary protection mechanism, please remove it. The functionality -(Blocking) is covered by Ransomware Protection in an improved way. -2. *Ransomware Protection.* Ransomware protection needs to be in -operation before an attack occurs, as it needs to record file operations -to be able to revert them, in case of an attack. -3. *ownCloud Versions App.* Required to restore older file versions. -The capabilities of Ransomware Protection depend on its configuration -regarding version retention. -4. *ownCloud Trash Bin App.* Required to restore deleted files. The -capabilities of Ransomware Protection depend on its configuration -regarding trash bin retention. - -=== Optional - -1. *Activity app.* For viewing activity logs. - -== Limitations - -* Ransomware Protection works with master-key based storage encryption. -With credential-based storage encryption, only Ransomware Prevention -(Blocking) works. -* Rollback is not based on snapshots: -** The -xref:admin_manual:configuration/server/config_sample_php_parameters.adoc#deleted-items-trash-bin[trash bin retention policy] -may delete files, making them unrecoverable. To -avoid this, set `trashbin\_retention\_obligation` to `disabled`, or -choose a conservative policy for trash bin retention. However, please be -aware that this may increase storage requirements. -** Trash bin items may be deleted by the user making them unrecoverable -by Ransomware Protection => Users need to know this. -** Versions have -xref:admin_manual:configuration/server/config_sample_php_parameters.adoc#file-versions[a built-in `thin-out` policy] -which makes it possible that required file -versions are unrecoverable by Ransomware Protection. To help avoid this, -set `versions\_retention\_obligation` to `disabled` or choose a -conservative policy for version retention. Please be aware that this -might increase your storage needs. -+ -* A specific version of a file that is needed for rollback might have -been manually restored, making this version potentially unrecoverable by -Ransomware Protection. Currently, after restoration the restored version -is not a version anymore, e.g., the version is not present in -versioning. -* Recovery capabilities in received shared folders are currently -limited. Changed file contents and deletions can be restored but MOVE -operations can’t. The case when a ransomware attack renames files in a -received shared folder is therefore not yet covered. -* Contents in secondary storages, such as _Windows network drives_, -_Dropbox_, and _Google Drive_, are unrecoverable by Ransomware -Protection, because they do not have versioning or trash bin enabled in -ownCloud. -* Rolling files forward is not _currently_ supported or tested. -Therefore it is vital to: -** Carefully decide the point in time to rollback to. -** To have proper backups to be able to conduct the rollback again, if -necessary. diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/user_management/saml_2.0_sso.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/user_management/saml_2.0_sso.adoc deleted file mode 100644 index 9496794..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/user_management/saml_2.0_sso.adoc +++ /dev/null @@ -1,265 +0,0 @@ -= SAML 2.0 Based SSO with Active Directory Federation Services (ADFS) and mod-shib -:toc: right -:toclevels: 1 -:page-aliases: enterprise/user_management/index.adoc - -:adfs-url: https://docs.microsoft.com/en-us/previous-versions/windows/server-2008/bb897402(v=msdn.10) -:adfs-step-by-step-url: https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2008-R2-and-2008/gg317734(v=ws.10) -:adfs-step-by-step-II-url: https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2008-R2-and-2008/gg317734(v=ws.10) -:adfs-shibboleth-url: https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2008-R2-and-2008/gg317734(v=ws.10) -:libapache2-mod-shib-url: https://packages.ubuntu.com/search?keywords=libapache2-mod-shib -:saml-chrome-panel-url: https://chrome.google.com/webstore/detail/saml-chrome-panel/paijfdbeoenhembfhkhllainmocckace -:saml-tracer-url: https://addons.mozilla.org/de/firefox/addon/saml-tracer/ -:ws-federation-url: https://social.technet.microsoft.com/wiki/contents/articles/1439.ad-fs-how-to-invoke-a-ws-federation-sign-out.aspx -:shibboleth-service-provider-url: https://blog.kloud.com.au/2014/10/29/shibboleth-service-provider-integration-with-adfs/ -:adfs2fed-python-script-url: https://github.com/rohe/pysfemma/blob/master/tools/adfs2fed.py -:shibboleth-basic-configuration-url: https://shibboleth.atlassian.net/wiki/spaces/SHIB2/pages/2577072249/NativeSPApplication#NativeSPApplication-BasicConfiguration(Version2.4andAbove) -:shibboleth-xml-metadata-provider-url: https://shibboleth.atlassian.net/wiki/spaces/SHIB2/pages/2577072307/NativeSPMetadataProvider -:shibboleth-nativespservicesso-url: https://shibboleth.atlassian.net/wiki/spaces/SHIB2/pages/2577072444/NativeSPServiceSSO - -== Preparation - -Before you can setup SAML 2.0 based Single Sign-On with -{adfs-url}[Active Directory Federation Services (ADFS)] -and mod-shib, ask your ADFS admin for the relevant server URLs. These are: - -- The SAML 2.0 single sign-on service URL, e.g., `\https:///ADFS/ls` -- The IdP metadata URL, e.g., `\https:///FederationMetadata/2007-06/FederationMetadata.xml` - -Then, make sure that the web server is accessible with a trusted certificate: - -[source,bash] ----- -sudo a2enmod ssl -sudo a2ensite default-ssl -sudo service apache2 restart ----- - -== Installation - -Firstly, install {libapache2-mod-shib-url}[mod-shib]. You can do this using the following command: - -[source,bash] ----- -sudo apt-get install libapache2-mod-shib2 ----- - -This will install packages needed for mod-shib, including `shibd`. -Then, generate certificates for the `shibd` daemon by running the following command: - -[source,bash] ----- -sudo shib-keygen ----- - -== Download and Filter the ADFS Metadata - -The metadata provided by ADFS cannot be automatically imported, and must be cleaned up before using it with the file based `MetadataProvider`. To do so, use `adfs2fed.php`, as in the following command: - -[source,bash] ----- -php apps/user_shibboleth/tools/adfs2fed.php \ - https:///FederationMetadata/2007-06/FederationMetadata.xml \ - > /etc/shibboleth/filtered-metadata.xml ----- - -== Configure shibd - -Next, you need to configure `shibd`. -To do this, in `/etc/shibboleth/shibboleth2.xml`: - -=== Define the ownCloud Instance - -Use the URL of the ownCloud instance as the `entityID` in the `ApplicationDefaults` - -[source,xml] ----- - ----- - -NOTE: `\https:///login/saml` is just an example. + -Adjust `` to the full qualified domain name of your server. - -=== Configure SSO - -Configure the SSO to use the `entityID` from the `filtered-metadata.xml` - -[source,xml] ----- - - SAML2 - ----- - -NOTE: Grab `//` from the filtered-metadata.xml. - -=== Configure XML - -Configure an XML `MetadataProvider` with the local `filtered-metadata.xml` file - -[source,xml] ----- - ----- - -== Metadata Available - -Under `\https:///Shibboleth.sso/Metadata` shibd exposes the metadata that is needed by ADFS to add the SP as a Relying party. - -== Active Directory Federation Services (ADFS) - -This part needs to be done by an ADFS administrator. -Let him do his job while you continue with the Apache configuration below. - -=== Add a Relying Party Using Metadata - -See step 2 in {adfs-step-by-step-url}[AD FS 2.0 Step-by-Step Guide]. - -=== Configure ADFS to Send the userPrincipalName in the SAML Token - -If you have control over ADFS make it send the `UPN` and `Group` by adding the following LDAP claim rule: - -- Map `User Principal Name` to `UPN` -- Map `Token Groups - Unqualified Names` and map it to `Group` - -Change shibd `attribute-map.xml` to: - -[source,xml] ----- - - - ----- - -That will make the `userPrincipalName` available as the environment variable `upn`. - -== Apache2 - -To protect ownCloud with shibboleth you need to protect the URL with a mod-shib based `auth`. Currently, -xref:admin_manual:enterprise/user_management/user_auth_shibboleth.adoc#the-apache-shibboleth-module[we recommend protecting only the login page]. - -=== user_shibboleth - -When the app is enabled and ownCloud is protected by mod-shib, due to the Apache 2 configuration, you should be forced to authenticate against an ADFS. After a successful authentication you will be redirected to the ownCloud login page, where you can login as the administrator. Double check you have a valid SAML session by browsing to `\https:///Shibboleth.sso/Session`. - -In the "User Authentication" settings for Shibboleth the `upn` environment variables will be filled with the authenticated user’s `userPrincipalName` in the "Server Environment" section. - -Use `upn` as `uid` and set the app mode to 'SSO Only' by running: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} shibboleth:mode ssoonly -{occ-command-example-prefix} shibboleth:mapping -u upn ----- - -`displayName` and email are only relevant for `autoprovisioning` mode. -Add Claims in ADFS and map them in the `attribute-map.xml` if needed. - -== Testing - -- Close the browser tab to kill the session. -- Then visit `\https://` again. -- You should be logged in automatically. -- Close the tab or delete the cookies to log out. -- To make the logout work see the Logout section in this document. - -== Configuring SSO - -- On the ADFS Server: - - - Add "Windows Authentication" to the "Service" -> "Authentication Methods" for "Intranet" - - Run the following Powershell script for Firefox: - -Save the list of currently supported browser user-agents to a variable -[source,console] ----- -$ browsers=Get-ADFSProperties | Select -ExpandProperty WIASupportedUseragents ----- - -Add Mozilla/5.0 user-agent to the list -[source,console] ----- -$ browsers+="Mozilla/5.0" ----- - -Apply the new list -[source,console] ----- -$ Set-ADFSProperties -WIASupportedUseragents $browsers ----- - -Turn off Extended Protection -[source,console] ----- -$ Set-ADFSProperties –ExtendedProtectionTokenCheck None ----- - -Restart the AD FS service -[source,console] ----- -$ Restart-Service ADFSsrv ----- - -- On the Windows client: - - - For Internet Explorer, Edge, and Chrome - - - In the "Internet Settings" -> "Security" -> "Local Intranet" - - Click on "Sites" - - Click on "Advanced" - - Add your ADFS machine with `\https:///` and click OK. - - Click on "customize level" - - Find "User Authentication" - - Check "Automatic login only for Intranet zone" - - - For Firefox - - - Open "about:config" - - Accept the warning - - Search for `network.negotiate-auth.trusted-uris` and set it to the FQDN of your ADFS server - - Search for `network.automatic-ntlm-auth.trusted-uris` and set it to the FQDN of your ADFS server - -Now if you logged into the domain and open your ownCloud server in the browser of your choice you should get directly to your ownCloud files without a login. - -== Debugging - -In `/etc/shibboleth/shibd.logger`, set the overall behavior to debug: - -[source,ini] ----- -# set overall behavior -log4j.rootCategory=DEBUG, shibd_log, warn_log -[...] ----- - -After a restart `/var/log/shibbloeth/shibd.log` will show the parsed SAML requests and also which claims / attributes were found and mapped, or why not. - -== Browsers - -- For Chrome there is a {saml-chrome-panel-url}[SAML Chrome Panel] that allows checking the SAML messages in the developer tools reachable via F12. -- For Firefox there is {saml-tracer-url}[SAML tracer] -- In the Network tab of the developer extension make sure that "preserve logs" is enabled in order to see the redirects without wiping the existing network requests - -== Logout - -In SAML scenarios the session is held on the SP as well as the IdP. Killing the SP session will redirect you to the IdP where you are still logged in, causing another redirect that creates a new SP session, making logout impossible. Killing only the IdP session will allow you to use the SP session until it expires. - -There are multiple ways to deal with this: - -1. By default ownCloud shows a popup telling the user to close the browser tab. That kills the SP session. If the whole browser is closed the IdP may still use a Kerberos-based authentication to provide SSO in effect making logout impossible. -2. Hide the logout action in the personal menu via CSS. This forces users to log out at the IdP. - -== OAuth2 - -In upcoming versions the clients will use OAuth2 to obtain a device specific token to prevent session expiry, making the old `/oc-shib/remote.php/nonshib-webdav` obsolete - -== Further Reading - -- {adfs-shibboleth-url}[ADFS 2.0 Step-by-Step Guide: Federation with Shibboleth 2 and the InCommon Federation] -- {ws-federation-url}[ADFS: How to Invoke a WS-Federation Sign-Out] -- {shibboleth-service-provider-url}[Shibboleth Service Provider Integration with ADFS] -- {adfs2fed-python-script-url}[adfs2fed Python Script] -- {adfs-step-by-step-II-url}[AD FS 2.0 Step-by-Step Guide: Federation with Shibboleth 2 and the InCommon Federation] -- {shibboleth-basic-configuration-url}[Shibboleth Basic Configuration (Version 2.4 and Above)] -- {shibboleth-xml-metadata-provider-url}[Shibboleth XML MetadataProvider] -- {shibboleth-nativespservicesso-url}[Shibboleth NativeSPServiceSSO] diff --git a/content/server/10.15/modules/admin_manual/pages/enterprise/user_management/user_auth_shibboleth.adoc b/content/server/10.15/modules/admin_manual/pages/enterprise/user_management/user_auth_shibboleth.adoc deleted file mode 100644 index 892234c..0000000 --- a/content/server/10.15/modules/admin_manual/pages/enterprise/user_management/user_auth_shibboleth.adoc +++ /dev/null @@ -1,159 +0,0 @@ -= Shibboleth Integration -:toc: right -:native-apache-integration-url: https://wiki.shibboleth.net/confluence/display/SHIB2/NativeSPApacheConfig -:shibboleth-nativesplinuxinstall-url: https://wiki.shibboleth.net/confluence/display/SHIB2/NativeSPLinuxInstall -:shibboleth-url: https://en.wikipedia.org/wiki/Shibboleth_(Shibboleth_Consortium) - -== Introduction - -The ownCloud Shibboleth user backend application integrates ownCloud with a {shibboleth-url}[Shibboleth] Service Provider (SP) and allows operations in federated and single-sign-on (SSO) infrastructures. -Setting up Shibboleth has two big steps: - -1. Enable and configure the Apache Shibboleth module. -2. Enable and configure the ownCloud Shibboleth app. - -== The Apache Shibboleth module - -Currently supported installations are based on the {native-apache-integration-url}[native Apache integration]. -The individual configuration of the service provider is highly dependent on the operating system, as well as on the integration with the Identity Providers (IdP), and require case-by-case analysis and installation. - -A good starting point for the service provider installation can be found in {shibboleth-nativesplinuxinstall-url}[the official Shibboleth Wiki]. - -A successful installation and configuration will populate Apache environment variables with at least a unique user id which is then used by the ownCloud Shibboleth app to login a user. - -=== Apache Configuration - -This is an example configuration as installed and operated on a Linux server running the Apache 2.4 Web server. These configurations are highly operating system specific and require a high degree of customization. - -The ownCloud instance itself is installed in `/var/www/owncloud/`. -Further Shibboleth specific configuration as defined in `/etc/apache2/conf.d/shib.conf`. - -[source,apache] ----- -include::example$enterprise/user_management/shibboleth/apache-2.4-configuration.conf[] ----- - -To allow users to login via the IdP, add a login alternative with the `login.alternatives` option in `config/config.php`. -Depending on the ownCloud Shibboleth app mode, you may need to revisit this configuration. - -== The ownCloud Shibboleth App - -After enabling the Shibboleth app on your Apps page, you need to choose the app mode and map the necessary Shibboleth environment variables to ownCloud user attributes on your Admin page. - -image:shib-gui5.png[figure 1: Enabling Shibboleth on the ownCloud Admin page] - -=== Choosing the App Mode - -After enabling the app it will be in *Not active* mode, which ignores a Shibboleth session and allows you to login as an administrator and inspect the currently available Apache environment variables. -Use this mode to set up the environment mapping for the other modes, and in case you locked yourself out of the system. -You can also change the app mode and environment mappings by using the `occ` command, like this example on Ubuntu Linux: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} shibboleth:mode notactive -{occ-command-example-prefix} shibboleth:mapping --uid login ----- - -In *Single sign-on only* mode the app checks if the environment variable for the Shibboleth session, by default *Shib-Session-Id*, is set. -If that is the case it will take the value of the environment variable as the `uid`, by default `eppn`, and check if a user is known by that `uid`. -In effect, this allows another user backend, e.g., the LDAP app, to provide the `displayname`, `email` and `avatar`. - -As an example the IdP can send the `userPrincipalName` which the Apache Shibboleth module writes to a custom Apache environment variable called `login`. -The ownCloud Shibboleth app reads that `login` environment variable and tries to find an LDAP user with that `username`. -For this to work `userPrincipalName` needs to be added to the *Additional Search Attributes* in the LDAP directory settings on xref:configuration/user/user_auth_ldap.adoc[the advanced tab]. -We recommend using a scoped login attribute like `userPrincipalName` or `mail` because otherwise the search might find multiple users and prevent login. - -In many scenarios Shibboleth is not intended to hide the user's password from the service provider, but only to implement SSO. -If that is the case it is sufficient to protect the ownCloud base URL with Shibboleth. -This will send Web users to the IdP but allow desktop and mobile clients to continue using username and password, preventing popups due to an expired Shibboleth session lifetime. - -In *Autoprovision Users* mode the app will not ask another user backend, but instead provision users on the fly by reading the two additional environment variables for display name and email address. - -image:shib-gui6.png[figure 2: Mapping Shibboleth environment configuration variables to ownCloud user attributes] - -[NOTE] -==== -In ownCloud 8.1 the Shibboleth environment variable mapping was stored in `apps/user_shibboleth/config.php`. -This file was overwritten on upgrades, preventing a seamless upgrade procedure. -In ownCloud 8.2+ the variables are stored in the ownCloud database, making Shibboleth automatically upgradeable. -==== - -=== Mapping ownCloud User IDs - -From 3.1.2 you can now specify a mapper that is used on inbound ownCloud user IDs, to adjust them before usage in ownCloud. You can set the mapper using `occ`: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:app:set user_shibboleth \ - uid_mapper --value="OCA\User_Shibboleth\Mapper\ADFSMapper" ----- - -You may view the currently configured mapper using: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} shibboleth:mapping ----- - -The following mappers are provided with the app: - -[cols="2",options="header"] -|=== -|Class |Description -|`OCA\User_Shibboleth\Mapper\NoOpMapper` |The default, does not alter the UID -|`OCA\User_Shibboleth\Mapper\ADFSMapper` |Splits the UID around a `;` character and takes the first piece -|`OCA\User_Shibboleth\Mapper\GUIDInMemoryMapper` |Maps in binary GUIDs to strings -|=== - -== Shibboleth with Desktop and Mobile Clients - -The ownCloud Desktop Client can interact with an ownCloud instance running inside a Shibboleth Service Provider by using OAuth2 tokens to authenticate. -The ownCloud Android and iOS mobile apps also work with OAuth2 tokens. - -== WebDAV Support - -Users of standard WebDAV clients can generate an App Password on the Personal settings page. -Use of App Passwords may be enforced with the `token_auth_enforced` option in `config/config.php`. - -== Known Limitations - -=== Encryption - -File encryption can only be used together with Shibboleth when xref:configuration/server/occ_command.adoc#encryption[master key-based encryption] is used because the per-user encryption requires the user's password to unlock the private encryption key. -Due to the nature of Shibboleth the user's password is not known to the service provider. - -=== PHP-FPM is incompatible - -The provided shibd, apache and ownCloud configuration only works with mod_php. Make sure that you have disable PHP-FPM and enabled mod_php on your server. -CentOS 8 now installs PHP-FPM by default, so make sure to swap. - -=== Other Login Mechanisms - -You can allow other login mechanisms (e.g., LDAP or ownCloud native) by creating a second Apache virtual host configuration; such as in the below example. - -[source,apache] ----- -include::example$enterprise/user_management/shibboleth/other-login-mechanisms-vhost.conf[] ----- - -NOTE: The second location in the above configuration is *not* protected by Shibboleth, and you can use your other ownCloud login mechanisms. - -NOTE: The above configuration can be used with multi-factor authentication as well. - -If you use the above configuration, after it's enabled, configure the alternative logins option with a button to point to `/login-shib`. -This will trigger the Shibboleth session and redirect the user back to `/login`. -At this point, the existing session will be picked up, continuing with the authentication process. - -=== Session Timeout - -Session timeout on Shibboleth is controlled by the IdP. -It is not possible to have a session length longer than the length controlled by the IdP. -In extreme cases this could result in re-login on mobile clients and desktop clients every hour. - -=== UID Considerations and Windows Network Drive Compatibility - -To log in LDAP users via SAML for Single Sign On the user in LDAP must be uniquely resolvable by searching for the username that was sent in the SAML token. -For this to work the LDAP attribute containing the username needs to be added to the *Additional Search Attributes* in the LDAP directory settings on xref:configuration/user/user_auth_ldap.adoc[the advanced tab]. -We recommend using a scoped login attribute like `userPrincipalName` or `mail` because otherwise the search might find multiple users and prevent login. - -`user_shibboleth` will do the authentication, and `user_ldap` will provide user details such as `email` and `displayname`. diff --git a/content/server/10.15/modules/admin_manual/pages/faq/index.adoc b/content/server/10.15/modules/admin_manual/pages/faq/index.adoc deleted file mode 100644 index 917eb31..0000000 --- a/content/server/10.15/modules/admin_manual/pages/faq/index.adoc +++ /dev/null @@ -1,39 +0,0 @@ -= Frequently Asked Questions -:toc: right -:client-sync-exclude-list-url: https://github.com/owncloud/client/blob/master/sync-exclude.lst - -== I want to upgrade from Community Version to Enterprise Version. What are the changes? - -In ownCloud Enterprise you will get access to new apps and features, mainly targeted towards enterprises; apps and features that ensure security, for example. - -You can upgrade to the Enterprise version without concern, as your existing files, shares, and users remain as they are. - -== How do I transfer files from one user to another? - -See xref:configuration/files/file_sharing_configuration.adoc#transferring-files-to-another-user[transferring files to another user]. - -== How do I deal with problems caused by using self-signed SSL certificates? - -See the xref:configuration/server/occ_command.adoc#security[security section of the OCC command]. - -== I’m the admin and I lost my password! What do I do now! - -See the xref:configuration/user/reset_admin_password.adoc[reset admin password documentation]. - -== What is a Federated System? - -A Federated System is another ownCloud or https://oc.owncloud.com/opencloudmesh.html[OpenCloudMesh] -supporting cloud service. - -== Platform-wide known limitations, excluded files - -There are known file names that can not be synced with ownCloud, these are: - -* Folders and files with a trailing space. -* .htaccess. -* `*.part` files. -* File names that exceed 253 characters. -* {client-sync-exclude-list-url}[client/sync-exclude.list]. -* Desktop.ini in the root directory. -* UNIX/Linux hidden files (files whose names have a leading dot, e.g., `.12345.pdf`). - Users must activate "_sync hidden files_" to sync them. diff --git a/content/server/10.15/modules/admin_manual/pages/found_a_mistake.adoc b/content/server/10.15/modules/admin_manual/pages/found_a_mistake.adoc deleted file mode 100644 index 055ac1d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/found_a_mistake.adoc +++ /dev/null @@ -1,4 +0,0 @@ -= Have You Found a Mistake In The Documentation? -:new-issue-url: https://github.com/owncloud/docs-server/issues/new - -If you have found a mistake in the documentation, no matter how large or small, please let us know by {new-issue-url}[creating a new issue in the docs repository]. diff --git a/content/server/10.15/modules/admin_manual/pages/gdpr.adoc b/content/server/10.15/modules/admin_manual/pages/gdpr.adoc deleted file mode 100644 index d86d248..0000000 --- a/content/server/10.15/modules/admin_manual/pages/gdpr.adoc +++ /dev/null @@ -1,19 +0,0 @@ -= General Data Protection Regulation (GDPR) -:toc: right - -:description: For ownCloud, privacy is the main focus when it comes to data protection. As a European company, ownCloud follows the GDPR framework to provide data protection for its customers. - -== Introduction - -{description} - -== GDPR in ownCloud - -GDPR is referenced in several locations throughout this documentation. Some of the more prominent sections are listed below for your convenience: - -* xref:configuration/server/legal_settings_configuration.adoc[Legal Settings Configuration] -* xref:configuration/user/user_management.adoc[User Management] -* xref:maintenance/export_import_instance_data.adoc[Data Exporter] -* xref:enterprise/document_classification/classification_and_policy_enforcement.adoc[Document Classification and Policy Enforcement] -* xref:enterprise/file_management/files_lifecycle.adoc[File Lifecycle Management] - diff --git a/content/server/10.15/modules/admin_manual/pages/index.adoc b/content/server/10.15/modules/admin_manual/pages/index.adoc deleted file mode 100644 index 927221d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/index.adoc +++ /dev/null @@ -1,28 +0,0 @@ -= Introduction -:owncloud-news-url: https://owncloud.com/news/ -:ownCloud-channel-url: https://www.youtube.com/channel/UC_4gez4lsWqciH-otOlXo5w - -Welcome to the ownCloud Classic Administration Guide. This guide describes administration tasks for ownCloud, the flexible open source file synchronization and sharing solution. ownCloud includes the ownCloud server, which runs on Linux, plus client applications for Microsoft Windows, Mac OS X, Linux, Android and Apple iOS operating systems. - -Current editions of ownCloud manuals are always available online at {docs-base-url}[doc.owncloud.com]. - -ownCloud server is available in three editions: - -* The free community-supported server. This is the core server for all editions. -* The Standard Subscription for customers who want paid support for the core Server, without Enterprise applications. -* The Enterprise Subscription provides paid support for the Enterprise Edition. This includes the core Server and Enterprise apps. - -== ownCloud Videos and Blogs - -See the -{ownCloud-channel-url}[official ownCloud channel] on YouTube for tutorials, overviews, and conference videos. Visit {owncloud-news-url}[News] to stay up to date. - -== Target Audience - -This guide is for administrators who want to install, administer, and optimize their ownCloud servers. To learn more about the ownCloud Web user interface, and desktop and mobile clients, please refer to their respective manuals. See the developer manual if you would like to contribute: - -* xref:classic_ui:index.adoc[ownCloud User Manual] -* xref:developer_manual:index.adoc[ownCloud Developer Manual] -* {docs-base-url}/desktop/[ownCloud Desktop Client] -* {docs-base-url}/ios-app/[ownCloud iOS App] -* {docs-base-url}/android/[ownCloud Android App] diff --git a/content/server/10.15/modules/admin_manual/pages/installation/apps/mediaviewer/index.adoc b/content/server/10.15/modules/admin_manual/pages/installation/apps/mediaviewer/index.adoc deleted file mode 100644 index e369da6..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/apps/mediaviewer/index.adoc +++ /dev/null @@ -1,36 +0,0 @@ -= Media Viewer App -:install-imagemagick-url: https://www.tecmint.com/install-imagemagick-on-debian-ubuntu/ -:gallery-link-share-redirect-url: https://github.com/owncloud/gallery#redirect-gallery-link-shares - -== Introduction - -The {oc-marketplace-url}/apps/files_mediaviewer[Media Viewer App] is a simple viewer for pictures and videos integrated into the files app, which supersedes the former Gallery and Video Player apps. - -[NOTE] -==== -* Before installing the Media Viewer app, the Gallery and Video Player apps need to be removed, or at the very least disabled. - When removing or disabling, ensure that any {gallery-link-share-redirect-url}[gallery link shares are redirected]. -* Gallery and Video Player are no longer supported and will not receive any further security or bug fixes. -* Users are strongly encouraged to switch to Media Player. -==== - -== Add Support For More Media Types - -To add support for additional media types, in addition to the default set, ensure that {install-imagemagick-url}[ImageMagick] and its {php-net-url}/manual/en/imagick.installation.php[PECL extension] are installed and enabled. Next, add new entries to the `enabledPreviewProviders` in `config/config.php`.Below, is an example of how to configure it. - -[source,php] ----- -'enabledPreviewProviders' => [ - 'OC\\Preview\\PNG', - 'OC\\Preview\\JPEG', - 'OC\\Preview\\GIF', - 'OC\\Preview\\Illustrator', - 'OC\\Preview\\Postscript', - 'OC\\Preview\\Photoshop', - 'OC\\Preview\\TIFF' -], ----- - -NOTE: Support for playing Apple QuickTime (*.mov) does not work in Chrome - however it is supported in Safari and Mozilla. - -TIP: Look at the sample configuration (`config.sample.php`) in your config folder, for more information about this configuration key. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/apps_management_installation.adoc b/content/server/10.15/modules/admin_manual/pages/installation/apps_management_installation.adoc deleted file mode 100644 index 26dc954..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/apps_management_installation.adoc +++ /dev/null @@ -1,110 +0,0 @@ -= Installing and Managing Apps -:toc: right - -== Introduction - -After installing ownCloud, you may provide added functionality by installing applications. - -== Installing and Managing Apps - -=== Installing Apps Via the ownCloud Marketplace - -image:installation/top_menu_showing_market_app.png[ownCloud top navigation menu showing the Market app] - -To add an app, use the _Market_ app, which is accessible from the top-level navigation bar, on the left-hand side of the page. -Once in the Market app, click an app's name to view more details about it. -Once you have done this, you can also install it by clicking btn:[Install]. -Clicking _Install_, downloads it from the ownCloud Marketplace, installs, and enables it. - -Sometimes the installation of a third-party app fails silently, possibly because `appcodechecker' => true,` is enabled in `config.php`. -When `appcodechecker` is enabled, it checks if third-party apps are using the private API, rather than the public API. -If they are, they are not installed. - -NOTE: If you would like to create or add (your own) ownCloud app, please refer to the xref:developer_manual:app/introduction.adoc[developer manual]. - -=== Installing Apps Manually - -To install an app manually, instead of by using the Market app, extract the app tarball into your ownCloud installation's default app folder (`/apps`) or, ideally, into xref:using-custom-app-directories[a custom app directory]. - -Once the tarball has been extracted into the default app folder. Enable the application, - -* by Navigating to menu:Settings[Admin > Apps] and clicking btn:[Enable]; or the -* xref:configuration/server/occ_command.adoc#app-commands[occ app command]. - -=== Managing Apps - -Some apps are installed and enabled during ownCloud installation, while other apps can be installed and enabled post-installation. - -[NOTE] -==== -*Supported Enterprise Apps* - -See xref:installation/apps_supported.adoc[supported apps] for a list of supported Enterprise edition apps. -==== - -==== View App Status - -image:oc_admin_apps.png[Apps page for enabling and disabling apps.] - -To see the status of your installation's applications, go to your Apps page, via menu:Settings[Admin > Apps]. -There, you will see which apps are currently: _enabled_, _not enabled_, and _recommended_. -You'll also see additional filters, such as _Multimedia_, _Productivity_, and _Tool_ for finding more apps quickly. - -==== Enabling and Disabling Apps - -On the Apps page (menu:Settings[Admin > Apps]), you can enable or disable applications. -Be default, enabled apps are displayed. -To disable an app, click btn:[Disable] under its details. - -To display disabled apps, click btn:[Show disabled apps]. -To enable an app, click btn:[Enable] under its details. - -==== Configuring Apps - -Some apps have configurable options on the Apps page, such as *Enable only for specific groups*. -However, this is the exception. -Apps are mainly configured from your ownCloud Personal or Admin settings page, or in `config.php`. - -== Using Custom App Directories - -There are several reasons for using custom app directories instead of ownCloud's default. -These are: - -. It separates ownCloud's core apps from user or admin downloaded apps. -Doing so distinguishes which apps are core and which aren't, simplifying upgrades. -. It eases manual upgrades. -Having non-core apps in a directory separate to the core app directory makes them simpler to manage. -. ownCloud may gain new core apps in newer versions. -Doing so orphans deprecated apps, but doesn't remove them. - -If you want to store apps in a custom directory, instead of ownCloud's default (`/app`), you need to modify the `apps_paths` element in `config/config.php`. -There, you need to add a new associative array that contains three elements. -These are: - -`path`:: The absolute file system path to the custom app folder. -`url`:: The request path to that folder relative to the ownCloud webroot, prefixed with `/`. -`writable`:: Whether users can install apps in that folder. - -After adding the configuration, ownCloud only installs apps in directories where `writable` is set to `true`. -The configuration example below shows how to add a second directory, called `apps-external`. - -[source,php] ----- -include::example$installation/custom-app-directory-configuration.php[] ----- - -After you add a new directory configuration, you can then move apps from the original app directory to the new one. -To do so, follow these steps: - -. xref:configuration/server/occ_command.adoc#maintenance-commands[Enable maintenance mode]. -. xref:configuration/server/occ_command.adoc#apps-commands[Disable the apps] that you want to move. -. Create a new apps directory and assign it the same user and group, and ownership permissions as the core apps directory. -. Move the apps from the old apps directory to the new apps directory. -. Add a new app directory in `config/config.php`. -. If you’re using a cache, such as xref:configuration/server/caching_configuration.adoc#clearing-the-redis-cache[Redis] or xref:configuration/server/caching_configuration.adoc#clearing-the-memcached-cache[Memcached], ensure that you clear the cache. -. xref:configuration/server/occ_command.adoc#apps-commands[Re-enable the apps]. -. xref:configuration/server/occ_command.adoc#maintenance-commands[Disable maintenance mode]. - -== Multiple Servers - -We recommend having your apps-external and your config directory on a network storage in order to prevent conflicts when installing or updating apps. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/apps_supported.adoc b/content/server/10.15/modules/admin_manual/pages/installation/apps_supported.adoc deleted file mode 100644 index 01655b7..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/apps_supported.adoc +++ /dev/null @@ -1,52 +0,0 @@ -= Supported Apps in ownCloud -:toc: right -:toclevels: 1 - -== AGPL Apps - -* {oc-marketplace-url}/apps/activity[Activity] -* {oc-marketplace-url}/apps/files_antivirus[Anti-Virus] -* Collaborative Tags -* Comments -* xref:configuration/files/encryption/encryption_configuration.adoc[Encryption] -* xref:configuration/server/external_sites.adoc[External Sites] -* xref:configuration/files/external_storage/index.adoc[External Storage] -* xref:configuration/files/federated_cloud_sharing_configuration.adoc[Federated File Sharing] (allows file sharing across ownCloud instances) -* Federation (allows username auto-complete across ownCloud instances) -* Files (cannot be disabled) -* xref:installation/apps/mediaviewer/index.adoc[Files Media Viewer] -+ -NOTE: Before Files Media Viewer 1.0.4, the _Gallery_ and _Files VideoPlayer_ apps need to be **uninstalled before installing** the Media Viewer app. Starting with Files Media Viewer 1.0.4, the _Gallery_ and _Files VideoPlayer_ apps need to be **disabled before using** the Files Media Viewer app. -* {oc-marketplace-url}/apps/pdf[Files PDF Viewer] -* xref:configuration/files/file_sharing_configuration.adoc[Files Sharing] -* {oc-marketplace-url}/apps/files_texteditor[Files TextEditor] -* xref:configuration/files/trashbin_options.adoc[Files Trashbin] -* xref:configuration/files/file_versioning.adoc[Files Versions] -* First Run Wizard -* {oc-marketplace-url}/apps/search_elastic[Full Text Search] -* xref:configuration/user/guests_app.adoc[Guests] -* {oc-marketplace-url}/apps/impersonate[Impersonate] -* Notifications -* {oc-marketplace-url}/apps/openidconnect[OpenID Connect] -* xref:configuration/files/external_storage/webdav.adoc[ownCloud WebDAV Endpoint] (handles old and new webdav endpoints) -* xref:configuration/user/user_provisioning_api.adoc[Provisioning API] -* Update Notifications -* xref:configuration/user/user_auth_ftp_smb_imap.adoc[User External] -* {oc-marketplace-url}/apps/user_ldap[User LDAP] - -== Enterprise-Only Apps - -* {oc-marketplace-url}/apps/admin_audit[Auditing] -* {oc-marketplace-url}/apps/files_classifier[Document Classification] -* {oc-marketplace-url}/apps/files_ldap_home[LDAP Home Connector] -* {oc-marketplace-url}/apps/firewall[File Firewall] -* {oc-marketplace-url}/apps/objectstore[Object Storage Support] -* {oc-marketplace-url}/apps/password_policy[Password Policy] -* {oc-marketplace-url}/apps/ransomware_protection[Ransomware Protection] -* {oc-marketplace-url}/apps/sharepoint[External Storage: SharePoint] -* {oc-marketplace-url}/apps/systemtags_management[Collaborative Tags Management] -* {oc-marketplace-url}/apps/user_shibboleth[SAML/Shibboleth User Backend] -* {oc-marketplace-url}/apps/windows_network_drive[Windows Network Drives (requires External Storage)] -* {oc-marketplace-url}/apps/wopi[Microsoft Office Online] -* {oc-marketplace-url}/apps/workflow[Workflows] -* {oc-marketplace-url}/themes/theme-enterprise[ownCloud X Enterprise Theme] diff --git a/content/server/10.15/modules/admin_manual/pages/installation/changing_the_web_route.adoc b/content/server/10.15/modules/admin_manual/pages/installation/changing_the_web_route.adoc deleted file mode 100644 index 8f6421a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/changing_the_web_route.adoc +++ /dev/null @@ -1,34 +0,0 @@ -= Changing Your ownCloud URL - -This admin manual assumes that the ownCloud server is already accessible -under the route `/owncloud` (which is the default, e.g. -`\https://example.com/owncloud`). If you like, you can change this in -your web server configuration, for example by changing it from -`\https://example.com/owncloud/` to `\https://example.com/`. - -To do so on Debian/Ubuntu Linux, you need to edit these files: - -* `/etc/apache2/sites-enabled/owncloud.conf` -* `/var/www/owncloud/config/config.php` - -Edit the `Alias` directive in `/etc/apache2/sites-enabled/owncloud.conf` -to alias your ownCloud directory to the Web server root: - -[source,apache] ----- -Alias / "/var/www/owncloud/" ----- - -Edit the `overwrite.cli.url` parameter in -`/var/www/owncloud/config/config.php`: - -[source,php] ----- -'overwrite.cli.url' => 'http://localhost/', ----- - -When the changes have been made and the file saved, restart Apache. Now -you can access ownCloud from either `\https://example.com/` or -`\https://localhost/`. - -NOTE: You will not be able to run any other virtual hosts, as ownCloud is aliased to your web root. On CentOS/Fedora/Red Hat, edit `/etc/httpd/conf.d/owncloud.conf` and `/var/www/html/owncloud/config/config.php`, then restart Apache. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/configuration_notes_and_tips.adoc b/content/server/10.15/modules/admin_manual/pages/installation/configuration_notes_and_tips.adoc deleted file mode 100644 index 1707730..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/configuration_notes_and_tips.adoc +++ /dev/null @@ -1,223 +0,0 @@ -= Configuration Notes and Tips -:toc: right -:toclevels: 1 -:tideways-url: https://tideways.io/profiler/blog/how-does-the-php-realpath-cache-work-and-how-to-configure-it -:page-aliases: go/admin-php-fpm.adoc - -== SELinux - -See the xref:installation/selinux_configuration.adoc[SELinux Configuration Guide] for -a suggested configuration for SELinux-enabled distributions such as Fedora and CentOS. - -== php.ini - -Several core PHP settings must be configured correctly, otherwise -ownCloud may not work properly. Known settings causing issues are listed -here. Please note that, there might be other settings which cause -unwanted behavior. In general, however, it is recommended to keep the -`php.ini` settings at their defaults, except when you know exactly why -the change is required, and its implications. - -NOTE: Keep in mind that, changes to `php.ini` may have to be configured in more than one ini file. -This can be the case, for example, for the `date.timezone` setting. - -=== php.ini - Used by the Web server - -For PHP version {minimum-php-printed} onward, replace `php_version` with the version number installed, e.g., `{minimum-php-version}` in the following examples. - -[source,plaintext] ----- -/etc/php/[php_version]/apache2/php.ini ----- - -or -[source,plaintext] ----- -/etc/php/[php_version]/fpm/php.ini ----- - -or - -=== php.ini - used by the php-cli and so by ownCloud CRON jobs - -[source,plaintext] ----- -/etc/php/[php_version]/cli/php.ini ----- - -=== session.auto_start && enable_post_data_reading - -Ensure that -{php-net-url}/manual/en/session.configuration.php#ini.session.auto-start[session.auto_start] -is set to `0` or `Off` and -{php-net-url}/manual/en/ini.core.php#ini.enable-post-data-reading[enable_post_data_reading] -to `1` or `On` in your configuration. If not, you may have issues -logging in to ownCloud via the WebUI, where you see the error: -"__Access denied. CSRF check failed__". - -=== session.save_path - -In addition to setting `session.auto_start` and -`enable_post_data_reading` correctly, ensure that, if -`session.save_handler` is set to `files`, that `session.save_path` is -set to a path on the filesystem which *only* the web server process (or -process which PHP is running as) can read from and write to. - -This is especially important if your ownCloud installation is using a -shared-hosting arrangement. In these situations, -https://en.wikipedia.org/wiki/Session_poisoning[session poisoning] can -occur if all of the session files are stored in the same location. -Session poisoning is where one web application can manipulate data in -the `$_SESSION` superglobal array of another. - -When this happens, the original application has no way of knowing that this -corruption has occurred and may not treat the data with any sense of suspicion. -You can read through a thorough discussion of -https://dl.packetstormsecurity.net/papers/attack/php-part1.pdf[local session poisoning] -if you’d like to know more. - -=== post_max_size - -Please ensure that you have `post_max_size` configured with _at least_ -the minimum amount of memory for use with ownCloud, which is 512 MB. - -NOTE: Please be careful when you set this value if you use the byte value shortcut as it is very specific. Use K for kilobyte, M for megabyte and G for gigabyte. KB, MB, and GB *do not work!* - -=== realpath_cache_size - -This determines the size of the realpath cache used by PHP. This value -should be increased on systems where PHP opens many files, to reflect -the number of file operations performed. For a detailed description see -{php-net-url}/manual/en/ini.core.php#ini.realpath-cache-size[realpath-cache-size]. -This setting has been available since PHP 5.1.0. Prior to PHP 7.0.16 and -7.1.2, the default was 16 KB. - -To see your current value, query your `phpinfo()` output for this key. -It is recommended to set the value if it is currently set to the default -of 16 KB. A good reading about the background can be found at {tideways-url}[tideways.io]. - -==== How to get a working value - -With the assumption of 112 bytes per file path needed, this would allow -the cache to hold around 37.000 items with a cache size of 4096K (4M), -but only about a hundred entries for a cache size of 16 KB. - -NOTE: It’s a good rule of thumb to always have a realpath cache that can hold entries for all your files paths in memory. If you use symlink deployment, then set it to double or triple the amount of files. - -The easiest way to get the quantity of PHP files is to use cloc, which -can be installed by running `sudo apt-get install cloc`. The cloc -package is available for nearly all distributions. - -[source,bash] ----- -sudo cloc /var/www/owncloud --exclude-dir=data --follow-links - 12179 text files. - 11367 unique files. - 73126 files ignored. ----- - -[source,plaintext] ----- -http://cloc.sourceforge.net v 1.60 T=1308.98 s (6.4 files/s, 1283.5 lines/s) --------------------------------------------------------------------------------- -Language files blank comment code --------------------------------------------------------------------------------- -PHP 4896 96509 285384 558135 -... ----- - -Taking the math from above and assuming a symlinked instance, using -factor 3. For example: `4896 * 3 * 112 = 1.6MB` This result shows that -you can run with the PHP setting of 4M two instances of ownCloud. - -Having the default of 16 KB means that only 1/100 of the existing PHP -file paths can be cached and need continuous cache refresh slowing down -performance. If you run more web services using PHP, you have to -calculate accordingly. - -== PHP-FPM - -Note that `mod_php` is used exclusively in the development and QA process of the ownCloud server. -It's highly recommended to use `mod_php` in your production environment for optimal performance and stability. -Any issues with the ownCloud server have to be reproducible with `mod_php`. - -SAML SSO with Shibboleth **will not work** with `php-fpm`. - -=== System Environment Variables - -When you are using `php-fpm`, system environment variables like `PATH`, -`TMP` or others are not automatically populated in the same way as when -using `php-cli`. A PHP call like `getenv('PATH');` can therefore return -an empty result. So you may need to manually configure environment -variables in the appropriate `php-fpm` ini/config file. - -Here are some example root paths for these ini/config files: - -[width="80%",cols="59%,41%",] -|=== -| Ubuntu/Mint | CentOS/Red Hat/Fedora -| `/etc/php/[php_version]/fpm/` | `/etc/php-fpm.d/` -|=== - -In both examples, the `ini/config` file is called `www.conf`, and -depending on the distribution or customizations which you have made, it -may be in a sub-directory. - -Usually, you will find some or all of the environment variables already -in the file, but commented out like this: - -[source,plaintext] ----- -;env[HOSTNAME] = $HOSTNAME -;env[PATH] = /usr/local/bin:/usr/bin:/bin -;env[TMP] = /tmp -;env[TMPDIR] = /tmp -;env[TEMP] = /tmp ----- - -Uncomment the appropriate existing entries. Then run `printenv PATH` to -confirm your paths, for example: - -[source,bash] ----- -printenv PATH -/home/user/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin: -/sbin:/bin:/ ----- - -If any of your system environment variables are not present in the file -then you must add them. - -When you are using shared hosting or a control panel to manage your -ownCloud virtual machine or server, the configuration files are almost -certain to be located somewhere else, for security and flexibility -reasons, so check your documentation for the correct locations. - -Please keep in mind that it is possible to create different settings for -`php-cli` and `php-fpm`, and for different domains and Web sites. The -best way to check your settings is with label-phpinfo. - -=== Maximum Upload Size - -If you want to increase the maximum upload size, you will also have to -modify your `php-fpm` configuration and increase the -`upload_max_filesize` and `post_max_size` values. You will need to -restart `php5-fpm` and your HTTP server in order for these changes to be -applied. - -=== .htaccess Notes for Apache - -ownCloud comes with its own `owncloud/.htaccess` file. Because `php-fpm` -can’t read PHP settings in `.htaccess` these settings and permissions -must be set in the `owncloud/.user.ini` file. - -=== No basic authentication headers were found - -This error is shown in your `data/owncloud.log` file. Some Apache -modules like `mod_fastcgi`, `mod_fcgid` or `mod_proxy_fcgi` are not -passing the needed authentication headers to PHP and so the login to -ownCloud via WebDAV, CalDAV and CardDAV clients is failing. Information -on how to correctly configure your environment can be found -{oc-central-url}/t/no-basic-authentication-headers-were-found-message/819[in -the forums] but we generally recommend not to use these modules -and recommend mod_php instead. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/deployment_considerations.adoc b/content/server/10.15/modules/admin_manual/pages/installation/deployment_considerations.adoc deleted file mode 100644 index e07d1df..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/deployment_considerations.adoc +++ /dev/null @@ -1,118 +0,0 @@ -= Deployment Considerations -:toc: right - -== Hardware - -* Solid-state drives (SSDs) for I/O. -* Separate hard disks for storage and database, SSDs for databases. -* Multiple network interfaces to distribute server synchronisation and -backend traffic across multiple subnets. - -=== Single Machine / Scale-Up Deployment - -The single-machine deployment is widely used in the community. - -Pros: - -* Easy setup: no session storage daemon, use tmpfs and memory caching to -enhance performance, local storage. -* No network latency to consider. -* To scale buy a bigger CPU, more memory, larger hard drive, or -additional hard drives. - -Cons: - -* Fewer high availability options. -* The amount of data in ownCloud tends to continually grow. Eventually a -single machine will not scale; I/O performance decreases and becomes a -bottleneck with multiple up- and downloads, even with solid-state -drives. - -=== Scale-Out Deployment - -Provider setup: - -* DNS round robin to HAProxy servers (2-n, SSL offloading, cache static -resources) -* Least load to Apache servers (2-n) -* Memcached/Redis for shared session storage (2-n) -* Database cluster with single primary, multiple replicas and proxy to -split requests accordingly (2-n) -* GPFS or Ceph via phprados (2-n, 3 to be safe, Ceph 10+ nodes to see -speed benefits under load) -* In case of clustering, your cluster nodes must have the same ownCloud configuration including an identical config.php to avoid any potential issues. - -Pros: - -* Components can be scaled as needed. -* High availability. -* Test migrations easier. - -Cons: - -* More complicated to setup. -* Network becomes the bottleneck (10GB Ethernet recommended). -* Currently DB filecache table will grow rapidly, making migrations -painful in case the table is altered. - -=== A Single primary DB is Single Point of Failure, Does Not Scale - -When primary fails another replica can become primary. However, the -increased complexity carries some risks: Multi-primary has the risk of -split brain, and deadlocks. ownCloud tries to solve the problem of -deadlocks with high-level file locking. - -== Software - -=== Operating System - -We are dependent on distributions that offer an easy way to install the -various components in up-to-date versions. ownCloud has a partnership -with RedHat and SUSE for customers who need commercial support. -Canonical, the parent company of Ubuntu Linux, also offers enterprise -service and support. Debian and Ubuntu are free of cost, and include -newer software packages. CentOS is the community-supported free-of-cost -Red Hat Enterprise Linux clone. openSUSE is community-supported, and -includes many of the same system administration tools as SUSE Linux -Enterprise Server. - -=== Web server - -Apache with mod_php is currently the best option. -Mod_php is recommended instead of PHP_FPM, because in scale-out deployments separate PHP pools are not necessary. - -=== Relational Database - -More often than not the customer already has an opinion on what database -to use. In general, the recommendation is to use what their database -administrator is most familiar with. Taking into account what we are -seeing at customer deployments, we recommend MySQL/MariaDB in a -primary-replica deployment with a MySQL proxy in front of them to send -updates to primary, and selects to the replica(s). - -The second-best option is PostgreSQL (alter table does not lock table, -which makes migration less painful) although we have yet to find a -customer who uses a primary-replica setup. - -What about the other DBMS? - -* Sqlite is adequate for simple testing, and for low-load single-user -deployments. It is not adequate for production systems. -* Microsoft SQL Server is not a supported option. -* Oracle DB is the de facto standard at large enterprises and is fully -supported with ownCloud Enterprise Edition only. - -== File Storage - -While many customers are starting with NFS, sooner or later that -requires scale-out storage. Currently the options are GPFS or GlusterFS, -or an object store protocol like S3. S3 also allows access to Ceph Storage. - -== Session Storage - -* Redis is required for transactional file locking xref:configuration/files/files_locking_transactional.adoc[Transactional File Locking], provides session persistence, and graphical inspection tools available. -* If you need to scale out Shibboleth you must use Memcached, as -Shibboleth does not provide an interface to Redis. Memcached can also be -used to scale-out shibd session storage (see -https://wiki.shibboleth.net/confluence/display/SHIB2/NativeSPStorageService#NativeSPStorageService-MemcacheStorageService[Memcache -StorageService]). diff --git a/content/server/10.15/modules/admin_manual/pages/installation/deployment_recommendations.adoc b/content/server/10.15/modules/admin_manual/pages/installation/deployment_recommendations.adoc deleted file mode 100644 index db87159..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/deployment_recommendations.adoc +++ /dev/null @@ -1,388 +0,0 @@ -= Deployment Recommendations -:toc: right -:toclevels: 2 -:owncloud-edition-url: https://owncloud.com/find-the-right-edition/ -:ibm-elastic-storage-server-url: https://www.ibm.com/us-en/marketplace/ibm-elastic-storage-server -:redhat-ceph-url: https://www.redhat.com/en/technologies/storage/ceph -:netapp-hybrid-flash-array-url: https://www.netapp.com/us/products/storage-systems/hybrid-flash-array/index.aspx -:netapp-nfs-bpg-url: https://www.netapp.com/us/media/tr-4067.pdf -:netapp-mysql-url: https://www.netapp.com/us/media/tr-4722.pdf -:setting-up-replication-url: https://mariadb.com/kb/en/setting-up-replication/ -:mariadb-monitor-url: https://mariadb.com/kb/en/mariadb-maxscale-22-automatic-failover-with-mariadb-monitor -:btrfs-url: https://en.wikipedia.org/wiki/Btrfs -:jira-mxs-220-url: https://jira.mariadb.org/browse/MXS-220 -:apache-ssl-howto-url: https://httpd.apache.org/docs/2.4/ssl/ssl_howto.html -:bigip-f5-url: https://f5.com/products/big-ip -:cloud-warm-hot-server-url: http://searchwindowsserver.techtarget.com/definition/cold-warm-hot-server -:mariadb-galera-cluster-url: http://galeracluster.com -:oc-core-issue-14757-url: https://github.com/owncloud/core/issues/14757#issuecomment-223492913 -:avoiding-deadlocks-in-galera-cluster-url: http://severalnines.com/blog/avoiding-deadlocks-galera-set-haproxy-single-node-writes-and-multi-node-reads -:galera-cluster-wsrep-docs-url: https://galeracluster.com/resources/ -:db-high-availability-url: http://www.severalnines.com/blog/become-mysql-dba-blog-series-database-high-availability -:bitnami-perf-enhancements-url: http://blog.bitnami.com/2014/06/performance-enhacements-for-apache-and.html -:haproxy-load-balancer-url: https://www.digitalocean.com/community/tutorials/an-introduction-to-haproxy-and-load-balancing-concepts -:haproxy-documentation-url: http://www.haproxy.org/#docs -:haproxy-and-load-balancing-url: https://www.digitalocean.com/community/tutorials/an-introduction-to-haproxy-and-load-balancing-concepts - -== Introduction - -This document is a guide for technical measures to size your physical environment regarding some general setups described in the scenarios below. It focuses on the software stack and may include some hardware recommendations. You can use any hardware as long the software is capable of running on it and delivers performance that meets your needs. - -NOTE: Independent of the technical measures, you can decide at any time the ownCloud licensing model - the {owncloud-edition-url}[ownCloud Edition]. - -== General Recommendations - -____ -What is the best way to install and maintain ownCloud? + -The answer to that is, as always: _'it depends'_. -____ - -This is because every ownCloud customer has their own particular needs and IT infrastructure. However, both ownCloud and the LAMP stack are highly configurable. Given that, in this document we present a set of general recommendations, followed by three typical scenarios, and finish up with making best-practice recommendations for both software and hardware. - -[NOTE] -==== -The recommendations presented here are based on a standard ownCloud installation, one without any particular _apps_, _themes_, or _code changes_. But, server load is dependent upon the number of _clients_, _files_, and _user activity_, as well as other usage patterns. Therefore, these recommendations are only rules of thumb based on our experience and customer feedback. -==== - -* Operating system: Linux. -* Web server: Apache 2.4. -* Database: MySQL/MariaDB with InnoDB storage engine (MyISAM is not supported, see: -xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB storage engine]) -* And a recent PHP Version. See xref:installation/system_requirements.adoc[System Requirements] -* Consider setting up a scale-out deployment, or using xref:classic_ui:files/federated_cloud_sharing.adoc[Federated Cloud Sharing] to keep individual ownCloud instances to a manageable size. - -NOTE: Whatever the size of your organization, always keep one thing in mind: + -*The amount of data stored in ownCloud will only grow - plan ahead.* - -== ownCloud Administrators Must Have Command Line or Cron Access - -We only recommend using hosts that provide the following _to ownCloud administrators_ - -* command-line access or -* Cron access -* ideally both of the above - -for three key reasons: - -1. Without command-line access, xref:configuration/server/occ_command.adoc[OCC commands], required for administrative tasks such as repairs and upgrades, are not available. -2. Without Crontab access, you cannot run background jobs reliably. -xref:configuration/server/background_jobs_configuration.adoc#ajax[ajax/cron.php] -is available, but it is not reliable enough, because it only runs when people are using the web UI. Additionally, ownCloud relies heavily on xref:developer_manual:app/fundamentals/backgroundjobs.adoc[background jobs] especially for long-running operations, which will likely cause PHP timeouts. -3. Default PHP timeout values are often low. Having low timeout settings can break long-running operations, such as moving a huge folder. - -== Scenario 1: Small Workgroups and Departments - -This recommendation applies if you meet the following criteria: - -[cols="30%,70%",options="header",] -|=== -| Option -| Value - -| Number of users -| Up to 150 users - -| Storage size -| 100 GB to 10TB - -| High availability level -a| * Zero-downtime backups via Btrfs snapshots -* Component failure leads to interruption of service -* Alternate backup scheme on other filesystems: nightly backups -* With service interruption -|=== - -=== Recommended System Requirements - -One machine running the application, web, and database server, as well as local storage. Authentication via an existing LDAP or Active Directory server. - -image:installation/deprecs-1.png[Network diagram for small enterprises.] - -==== Components - -One server with at least 2 CPU cores, 16GB RAM, and local storage as needed. - -==== Operating system - -Enterprise-grade Linux distribution with full support from an operating system vendor. We recommend Ubuntu 20.04, RedHat Enterprise Linux and SUSE Linux Enterprise Server 12+. - -==== SSL Configuration - -The SSL termination is done in Apache. A standard SSL certificate is required to be installed. See the {apache-ssl-howto-url}[official Apache documentation] or our xref:installation/letsencrypt/index.adoc[Let's Encrypt SSL Certificates] documentation. - -==== Load Balancer - -None. - -==== Database - -MySQL, MariaDB, or PostgreSQL. We currently recommend MySQL / MariaDB, as our customers have had good experiences when moving to a Galera cluster to scale the DB. If using either MySQL or MariaDB, you must use the InnoDB storage engine because MyISAM is not supported, see: xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB storage engine] - -IMPORTANT: If you are using MaxScale/Galera, then you need to use at least version 1.3.0. In earlier versions, there is a bug where the value of `last_insert_id` is not routed to the primary node. This bug can cause loops within ownCloud and corrupt database rows. You can find out more information {jira-mxs-220-url}[in the issue documentation]. - -==== Backup - -Install ownCloud, the ownCloud data directory, and database on {btrfs-url}[a Btrfs filesystem]. Make regular snapshots at desired intervals for zero downtime backups. Mount DB partitions with the "nodatacow" option to prevent fragmentation. - -Alternatively, you can make nightly backups — with service interruption — as follows: - -1. Shut down Apache. -2. Create database dump. -3. Push data directory to backup. -4. Push database dump to backup. -5. Start Apache. - -After these steps have been completed, then, optionally, rsync the backup to either an external backup storage or tape backup. See the xref:maintenance/backup_and_restore/backup.adoc[backup] and xref:maintenance/backup_and_restore/restore.adoc[restore] section of the Administration manual for tips on backups and restores. - -==== Authentication - -User authentication via one or several LDAP or Active Directory (AD) servers. See xref:admin_manual:configuration/user/user_auth_ldap.adoc[User Authentication with LDAP] for information on configuring ownCloud to use LDAP and AD. - -==== Session Management - -xref:configuration/server/caching_configuration.adoc#redis[Redis] is recommended and can be used for the session management storage. - -Alternatively you can use local session management, see xref:local-session-management[Local Session Management]. - -==== Memory Caching - -A memory cache speeds up server performance, and ownCloud supports a number of them. Refer to xref:admin_manual:configuration/server/caching_configuration.adoc[Configuring Memory Caching] for information on selecting and configuring a memory cache. - -==== Storage - -Local storage or Network File System (NFS) if already available. - -==== Recommended Licensing Model - -* Standard or Enterprise Edition -* See {owncloud-edition-url}[ownCloud Classic or Enterprise Edition] for comparisons of the ownCloud editions. - -== Scenario 2: Mid-Sized Enterprises - -These recommendations apply if you meet the following criteria: - -[cols="30%,70%",options="header",] -|=== -| Option -| Value - -| Number of users -| 150 to 5,000 users. - -| Storage size -| Up to 200TB. - -| High availability level -a| * Every component is fully redundant and can fail without service interruption -* Backups without service interruption -|=== - -=== Recommended System Requirements - -* 2 to 5 application servers. -* A cluster of two database servers. -* Storage on an NFS server. -* Authentication via an existing LDAP or Active Directory server. -* A Redis server for file locking - -image:installation/deprecs-2.png[Network diagram for a mid-sized enterprise.] - -==== Components - -* 2 to 4 application servers with four sockets and 32GB RAM. -* 2 DB servers with four sockets and 64GB RAM. -* 1 {haproxy-and-load-balancing-url}[HAproxy load balancer] with two sockets and 16GB RAM. -* NFS storage server as needed. - -==== Operating System - -Enterprise grade Linux distribution with full support from an operating system vendor. We recommend both RedHat Enterprise Linux and SUSE Linux Enterprise Server 12+. - -==== SSL Configuration - -The SSL termination is done in the {haproxy-load-balancer-url}[HAProxy load balancer]. A standard SSL certificate is needed, installed according to the {haproxy-documentation-url}[HAProxy documentation]. - -==== Load Balancer - -HAProxy running on a dedicated server in front of the application servers. Sticky session needs to be used because of local session management on the application servers. - -==== Database - -MySQL/MariaDB Galera cluster with {setting-up-replication-url}[primary-replica replication]. InnoDB storage engine, MyISAM is not supported, see: xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB storage engine]. For mariadb consider: {mariadb-monitor-url}[MariaDB Monitor] to configure your setup for a failover Scenario. - -==== Backup - -Minimum daily backup without downtime. All MySQL/MariaDB statements should be replicated to a backup MySQL/MariaDB replica instance. - -* Create a snapshot on the NFS storage server. -* At the same time stop the MySQL replication. -* Create a MySQL dump of the backup replica. -* Push the NFS snapshot to the backup. -* Push the MySQL dump to the backup. -* Delete the NFS snapshot. -* Restart MySQL replication. - -==== Authentication - -User authentication via one or several LDAP or Active Directory servers. See xref:admin_manual:configuration/user/user_auth_ldap.adoc[User Authentication with LDAP] for information on configuring ownCloud to use LDAP and AD. - -==== Session Management - -xref:configuration/server/caching_configuration.adoc#redis[Redis] is recommended and can be used for the session management storage. - -Alternatively you can use local session management, see xref:local-session-management[Local Session Management]. - -==== Memory Caching - -A memory cache speeds up server performance, and ownCloud supports a number of memory cache types. Refer to xref:admin_manual:configuration/server/caching_configuration.adoc[Configuring Memory Caching] for information on selecting and configuring a memory cache. - -==== Storage - -For accessing a backend storage system via NFS, you can use a dedicated storage system like {netapp-hybrid-flash-array-url}[NetApp Hybrid Flash Storage Systems], or other systems like {ibm-elastic-storage-server-url}[IBM Elastic Storage] based on their Power8 servers or {redhat-ceph-url}[RedHat Ceph] with their NFS-Ceph gateway. - -You may take a look on the {netapp-nfs-bpg-url}[NetApp NFS Best Practice and Implementation Guide] for best NFS configuring practices, especially section _9.4 Mount Option Best Practices with NFS_ on page 111 and {netapp-mysql-url}[MySQL Database on NetApp ONTAP] which also includes performance measurements. - -==== Recommended Licensing Model - -* Enterprise Edition -* See {owncloud-edition-url}[ownCloud Classic or Enterprise Edition] for comparisons of the ownCloud editions. - -== Scenario 3: Large Enterprises and Service Providers - -[cols="30%,70%",options="header",] -|=== -| Option -| Value - -| Number of users -| 5,000 to >100,000 users. - -| Storage size -| Up to 1 petabyte. - -| High availability level -a| * Every component is fully redundant and can fail without service interruption -* Backups without service interruption -|=== - -=== Recommended System Requirements - -* 4 to 20 application/Web servers. -* A cluster of two or more database servers. -* Storage is an NFS server or an object store that is S3 compatible. -* Cloud federation for a distributed setup over several data centers. -* Authentication via an existing LDAP or Active Directory server, or SAML. - -image:installation/deprecs-3.png[image] - -==== Components - -* 4 to 20 application servers with four sockets and 64GB RAM. -* 4 DB servers with four sockets and 128GB RAM. - 2 Hardware load balancer, for example, {bigip-f5-url}[BIG IP from F5]. -* NFS storage server as needed. - -==== Operating system - -RHEL 7+ with latest service packs. - -==== SSL Configuration - -The SSL termination is done in the load balancer. A standard SSL certificate is needed, installed according to the load balancer documentation. - -==== Load Balancer - -A redundant hardware load balancer with heartbeat, for example, {bigip-f5-url}[F5 Big-IP]. This runs two load balancers in front of the application servers. - -==== Database - -MySQL/MariaDB Galera Cluster with primary-replica replication. InnoDB storage engine, MyISAM is not supported, see: xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB storage engine]. For mariadb consider: {mariadb-monitor-url}[MariaDB Monitor] to configure your setup for a failover Scenario. - -==== Backup - -Minimum daily backup without downtime. All MySQL/MariaDB statements should be replicated to a backup MySQL/MariaDB replica instance. To do this, follow these steps: - -. Create a snapshot on the NFS storage server. -. At the same time stop the MySQL replication. -. Create a MySQL dump of the backup replica. -. Push the NFS snapshot to the backup. -. Push the MySQL dump to the backup. -. Delete the NFS snapshot. -. Restart MySQL replication. - -==== Authentication - -User authentication via one or several LDAP or Active Directory servers or SAML/Shibboleth. See xref:configuration/user/user_auth_ldap.adoc[User Authentication with LDAP] and xref:enterprise/user_management/user_auth_shibboleth.adoc[Shibboleth Integration]. - -==== LDAP - -Read-only replicas should be deployed on every application server for optimal scalability. - -==== Session Management - -xref:configuration/server/caching_configuration.adoc#redis[Redis] should be used for the session management storage. - -==== Caching - -xref:configuration/server/caching_configuration.adoc#redis[Redis] for distributed in-memory caching. - -==== Storage - -For accessing a backend storage system via NFS, you can use a dedicated storage system like {netapp-hybrid-flash-array-url}[NetApp Hybrid Flash Storage Systems] or other systems like {ibm-elastic-storage-server-url}[IBM Elastic Storage] based on their Power8 servers or {redhat-ceph-url}[RedHat Ceph] with their NFS-Ceph gateway. Optionally, an S3 compatible object store can also be used. - -You may take a look on the {netapp-nfs-bpg-url}[NetApp NFS Best Practice and Implementation Guide] for best NFS configuring practices, especially section _9.4 Mount Option Best Practices with NFS_ on page 111 and {netapp-mysql-url}[MySQL Database on NetApp ONTAP] which also includes performance measurements. - -==== Recommended Licensing Model - -* Enterprise Edition -* See {owncloud-edition-url}[ownCloud Classic or Enterprise Edition] for comparisons of the ownCloud editions. - -==== Redis Configuration - -Redis in a primary-replica configuration is {cloud-warm-hot-server-url}[a hot failover setup] and is usually sufficient. A replica can be omitted if high availability is provided via other means. If that's the case, restarting Redis typically happens fast enough in the event of a failure. Regarding Redis cluster, we don’t, usually, recommend it as it requires a greater level of both maintenance and management in the case of failure. A single Redis server, however, just needs to be rebooted in the event of failure. - -== Known Issues - -=== Deadlocks When Using MariaDB Galera Cluster - -If you’re using {mariadb-galera-cluster-url}[MariaDB Galera Cluster] with your ownCloud installation, you may encounter deadlocks when you attempt to sync a large number of files. You may also encounter database errors, such as this one: - -[source,plaintext] ----- -SQLSTATE[40001]: Serialization failure: 1213 Deadlock found when trying to get lock; try restarting transaction ----- - -The issue, {oc-core-issue-14757-url}[identified by Michael Roth], is caused when MariaDB Galera cluster sends write requests to all servers in the cluster; {avoiding-deadlocks-in-galera-cluster-url}[here is a detailed explanation]. The solution is to send all write requests to a single server, instead of all of them. - -=== Set wsrep_sync_wait to 1 on all Galera Cluster nodes - -==== What the parameter does - -When enabled, the node triggers causality checks in response to certain types of queries. During the check, the node blocks new queries while the database server catches up with all updates made in the cluster to the point where the check begun. Once it reaches this point, the node executes the original query. - -==== Why enable it - -A Galera Cluster write operation is sent to the primary while reads are retrieved from the replicas. Since Galera Cluster replication is, by default, not strictly synchronous it could happen that items are requested before the replication has actually taken place. - -NOTE: This setting is disabled by default. See the {galera-cluster-wsrep-docs-url}[Galera Cluster WSREP documentation] for more details. - -== General References - -* {db-high-availability-url}[Database High Availability] -* {bitnami-perf-enhancements-url}[Performance enhancements for Apache and PHP] - -== Local Session Management - -Local session management on the application server. PHP sessions are stored in a temporary filesystem, mounted at the operating system-specific session storage location. You can find out where that is by running - -[source,bash] ----- -grep -R 'session.save_path' /etc/php* ----- - -and then add it to the `/etc/fstab` file, for example: - -[source,bash,subs="attributes+"] ----- -include::example$installation/deployment_recommendations/set_session_path.sh[] ----- diff --git a/content/server/10.15/modules/admin_manual/pages/installation/deployment_recommendations/nfs.adoc b/content/server/10.15/modules/admin_manual/pages/installation/deployment_recommendations/nfs.adoc deleted file mode 100644 index f7bad0e..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/deployment_recommendations/nfs.adoc +++ /dev/null @@ -1,306 +0,0 @@ -= Network File System (NFS) Deployment Recommendations -:toc: right -:toclevels: 1 -:keywords: nfs, network file system, nfsv4, mtu, async, noasync -:description: This guide covers the official ownCloud NFS (Network File System) deployment recommendations. -:autofs-url: https://help.ubuntu.com/community/Autofs -:lockd-url: https://docs.oracle.com/cd/E19455-01/806-0916/rfsrefer-9/index.html -:mount-man-page-url: http://man7.org/linux/man-pages/man8/mount.8.html -:netplan-docs-url: https://netplan.io/reference -:networkmanager-url: https://help.ubuntu.com/community/NetworkManager -:networkworld-mtu-size-issues-url: https://www.networkworld.com/article/2224654/mtu-size-issues.html -:nfs-man-page-url: https://linux.die.net/man/5/nfs -:nfs-read-write-delegations-url: https://tools.ietf.org/html/rfc7530#section-1.4.6 -:nfs-strong-security-architecture-url: https://tools.ietf.org/html/rfc7530#section-3 -:nmcli-url: https://manpages.ubuntu.com/manpages/focal/man1/nmcli.1.html -:nmtui-url: https://manpages.ubuntu.com/manpages/focal/man1/nmtui.1.html -:rpc-statd-url: https://linux.die.net/man/8/rpc.statd -:man-nfs-ubuntu-url: http://manpages.ubuntu.com/manpages/focal/man5/nfs.5.html -:innodb_flush_method-url: https://mariadb.com/kb/en/library/innodb-system-variables/#innodb_flush_method - -ownCloud recommends using NFS for any scenario other than local storage. -It has solid performance and is very stable. -This document contains ownCloud's official deployment recommendations. - -There can be different scenarios where ownCloud's storage is located on an NFS mount (primary/secondary). -In some scenarios, multiple application servers can use the same NFS mount point. - -NOTE: It is advised to use network storage like NFS only in un-routed, switched Gigabit or higher environments. - -NOTE: This guide only covers the NFS client side where ownCloud runs. Follow the storage vendors recommendations to configure the NFS server (storage backend). - -[discrete] -== General Performance Considerations - -Please consider that a network stack runs in ranges of µs while a storage backend usually runs in ranges of ms. -Any tuning considerations should therefore first be attempted on the backend storage layout side, especially under high loads. - -== NFS Version Comparison Overview -[width="100%",cols="30%,70%",options="header",] -|=== - -| NFSv3 -| - -| Exports -| All exports are mounted separately - -| Protocol -| Numerous protocols for different aspects collected together. MOUNT, LOCK, STATUS… - -| Locking -| Permanent locks in yet another protocol - -| Security -| UNIX based. SecureNFS. Mode Bit Locking - -| Communication -| One operation per RPC - -| I18N -| All locales must match - -| Parallel high bandwidth access -| None native. (Addition such as MPFS) -|=== - -[width="100%",cols="30%,70%",options="header",] -|=== - -| NFSv4 -| - -| Exports -| All exports can be mounted together in a directory tree structure as part of a pseudo-filesystem - -| Protocol -| A single protocol with the addition of OPEN and CLOSE for security auditing - -| Locking -| Lease based locking in the same protocol - -| Security -| Kerberos and ACL based - -| Communication -| Multiple operations per RPC. (Improves performance) - -| I18N -| UTF-8 - -| Parallel high bandwidth access -| pNFS -|=== - -== NFSv4 - -ownCloud recommends using NFSv4 over previous versions for a number of key reasons. -These are: - -* *Improved Security:* It {nfs-strong-security-architecture-url}[mandates a strong security architecture]. It does not require {rpc-statd-url}[rpc.statd] or {lockd-url}[lockd]. As a result, it only uses port 2049. -* *Improved Reliability:* Uses TCP by default. -* *Improved Performance:* It uses Multi-Component Messages, which reduce network traffic. It is capable of using a 32KB page size, compared to the default, 1024 bytes. -* Use of {nfs-read-write-delegations-url}[Read/Write Delegations]. - -== NFS Mount Options - -See the {man-nfs-ubuntu-url}[Ubuntu man pages] for a detailed description of the NFS mount options. The following options are default for NFS except if explicitly set differently when mounting: `rw`, `suid`, `dev`, `exec`, `auto`, `nouser`, and `async`. - -Depending on the NFS version used, consider the following mount options: - -=== _netdev - -Use this option to ensure that the network is enabled, before NFS attempts to mount these filesystems. -This setting is essential when database files are located on an NFS storage. -The database could error or not start correctly, if the mount is not ready before attempting to access its data files. - -TIP: You can also use {autofs-url}[autofs], to ensure that mounts are always available before attempting to access them. - -=== nofail - -Using `nofail` allows the boot sequence to continue even if the drive fails to mount. This can happen if the NFS server accessed is down. The boot process will continue after the mount reaches timeout. The default device timeout is 90 seconds. If the option is not set, the boot process will wait until the NFS server is available but can be manually set using the option `x-systemd.mount-timeout=`. - -=== bg - -ownCloud recommends using this option. -Determines how the mount command behaves if an attempt to mount an export fails. -If the bg option is specified, a timeout or failure triggers the mount command to fork a child, which will continue to attempt mounting the export. -The parent immediately returns with a zero exit code. -This is known as a "background" mount. -This option is useful for continuous operation without manual intervention if the network connectivity is temporarily down or the storage backend must be rebooted. - -=== hard - -Default value is _hard_. -For business-critical NFS exports, ownCloud recommends using _hard_ mounts. -ownCloud strongly discourages the use of _soft_ mounts. - -=== retrans - -Default value is 3. -This option can be tuned when using option _soft_. - -=== timeo - -Default value is 600 (60 seconds). -This option can be tuned when using option _soft_. - -=== sync/async - -With the default value of _async_, the NFS client may delay sending application writes to the NFS server. -In other words, under normal circumstances, data written by an application may not immediately appear on the server that hosts the file. -**sync** provides greater data cache coherence among clients, but at a **significant performance cost**. -Having the database like MySQL or Mariadb on NFS, the default database option value for {innodb_flush_method-url}[innodb_flush_method] is _fsync_, even if it is not explicitly set. -This database option forces the mount to immediately write to the NFS server without generally setting the mount _sync_ option and avoiding this performance penalty. -You may consider further tuning when using clustered server environments. - -=== tcp - -ownCloud recommends using this option. -Force using TCP as transport protocol. -Alternatively you can use _proto=tcp_. - -=== Tune the Read and Write Block Sizes - -The allowed block sizes are the packet chunk sizes that NFS uses when reading and writing data. -The smaller the size, the greater the number of packets need to be sent to send or receive a file. -Conversely, the larger the size, the fewer the number of packets need to be sent to send or receive a file. -With NFS Version 3 and 4, you can set the `rsize` and `wsize` values as high as 65536, when the network transport is TCP. -The default value is 32768 and must be a multiple of 4096. - -NOTE: Read and write size must be identical on the NFS server and client. - -You can find the set values by working with the output of the `mount` command on a standard server, as in the example below. - -[source,console] ----- -root@server:~# mount | egrep -o rsize=[0-9]* ----- - -[source,plaintext] ----- -rsize=65536 ----- - -[source,console] ----- -root@server:~# mount | egrep -o wsize=[0-9]* ----- - -[source,plaintext] ----- -wsize=65536 ----- - -The information can also be retrieved using the command set of your dedicated storage backend. -Once you've determined the best sizes, set them permanently by passing the (`rsize` and `wsize`) options when mounting the share or in the share's mount configuration. - -.Specifying the read and write block sizes when calling mount -[source,bash] ----- -mount 192.168.0.104:/data /mnt -o rsize=65536,wsize=65536 ----- - -.Example for a set of NFS mount options: -[source,plaintext] ----- -bg,nfsvers=3,wsize=65536,rsize=65536,tcp,_netdev ----- - -== Ethernet Configuration Options - -=== MTU (Maximum Transmission Unit) Size - -The MTU size dictates the maximum amount of data that can be transferred in one Ethernet frame. -If the MTU size is too small, then regardless of the read and write block sizes, the data must still be fragmented across multiple frames. -Keep in mind that MTU = payload (`packetsize`) + 28. - -==== Get the Current Set MTU Size - -You can find the current MTU size for each interface using _netstat_, _ifconfig_, _ip_, and _cat_, as in the following examples: - -.Retrieve interface MTU size with netstat -[source,bash] ----- -netstat -i - -Kernel Interface table -Iface MTU RX-OK RX-ERR RX-DRP RX-OVR TX-OK TX-ERR TX-DRP TX-OVR Flg -lo 65536 363183 0 0 0 363183 0 0 0 LRU -eth0 1500 3138292 0 0 0 2049155 0 0 0 BMR ----- - -.Retrieve interface MTU size with ifconfig -[source,bash] ----- -ifconfig| grep -i MTU - -lo: flags=73 mtu 65536 -eth0: flags=4163 mtu 1500 ----- - -.Retrieve interface MTU size with ip -[source,bash] ----- -ip addr | grep mtu - -1: lo: mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000 -2: eth0: mtu 1500 qdisc mq state UP group default qlen 1000 ----- - -.Retrieve interface MTU size with cat -[source,bash] ----- -cat /sys/class/net//mtu ----- - -==== Check for MTU Fragmentation - -To check if a particular packet size will be fragmented on the way to the target, run the following command: - -[source,bash] ----- -ping -c 3 -M do -s ----- - -==== Get the Optimal MTU Size - -To get the optimal MTU size, run following command: - -[source,bash] ----- -tracepath ----- - -You can expect to see output like the following: - -[source,console] ----- - 1?: [LOCALHOST] pmtu 1500 <1> - 1: 0.263ms reached <2> - 1: 0.224ms reached <3> - Resume: pmtu 1500 hops 1 back 1 ----- -<1> The first line with localhost shows the given MTS size. -<2> The last line shows the optimal MTU size. -<3> If both are identical, nothing needs to be done. - -==== Change Your MTU Value - -In case you need or want to change the MTU size, under Ubuntu: - -* If {networkmanager-url}[NetworkManager] is managing all devices on the system, then you can use {nmtui-url}[nmtui] or {nmcli-url}[nmcli] to configure the MTU setting. -* If NetworkManager is not managing all devices on the system, you can set the MTU to 1280 with Netplan, as in the following example. -+ -[source,yaml] ----- -network: - version: 2 - ethernets: - eth0: - mtu: 1280 ----- -+ -Refer to {netplan-docs-url}[the Netplan documentation] for further information. - -TIP: NetworkWorld has {networkworld-mtu-size-issues-url}[an excellent overview of MTU size issues]. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/docker/index.adoc b/content/server/10.15/modules/admin_manual/pages/installation/docker/index.adoc deleted file mode 100644 index e67affc..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/docker/index.adoc +++ /dev/null @@ -1,440 +0,0 @@ -= Installing with Docker -:toc: right -:dockerhub-url: https://hub.docker.com/r/owncloud/server -:docker-compose-url: https://docs.docker.com/compose/ -:linux-server-doc-url: https://docs.linuxserver.io/faq -:docker-compose-build-url: https://docs.docker.com/compose/compose-file/build/ -:description: ownCloud can be installed using the official ownCloud Docker image. -// the image version documented on this branch. this is intentionally a literal -// and not an attribute, because the global -version attributes track the latest -// release of the product and not this branch. -:docker-image-version: 10.15.3 - -== Introduction - -{description} This {dockerhub-url}[official image] works standalone for a quick evaluation but is designed to be used in a docker compose setup. - -== Database Notes - -With the image provided, ownCloud has added database connectors for the following databases: - -* MySQL / MariaDB -* Postgres -* SQLite - -If you need a different connector or a different version of a connector, you have to manually create your own image based on the ownCloud image provided here. This could also be done directly in the {docker-compose-build-url}[docker compose file]. - -== Getting Started - -Grant docker command privileges to certain users by adding them to the group `docker`: - -[source,bash] ----- -sudo usermod -aG docker ----- - -NOTE: The changes via `usermod` only take effect after the docker users log in. So you may have to log out and log in again or possibly reboot before you can run docker commands. - -Users not added to the `docker` group can run docker commands with a preceding `sudo`. In this section `sudo` is generally omitted before docker commands since we assume you have created a docker user, which is also the only way to run ownCloud's command-line interface `occ` in a docker container. For more information on `occ`, see section xref:configuration/server/occ_command.adoc[Using the occ Command]. - -An example `occ` command looks like this: - -[source,docker] ----- -docker exec --user www-data occ ----- - -== Quick Evaluation - -NOTE: The commands and links provided in the following descriptions are intended to showcase basic docker usage, but we cannot take responsibility for their proper functioning. - -For testing purposes or a quick hands-on to get familiar with the look and feel, ownCloud provides a container using the SQLite database. Note that SQLite is not supported by ownCloud for production purposes. To set up such a testing instance, run the following command: - -[source,docker,subs="attributes+"] ----- -docker run --rm --name oc-eval -d -p{std-port-http}:{std-port-http} owncloud/server:{docker-image-version} ----- - -This starts a docker container with the name "oc-eval" in the background (option `-d`). `owncloud/server:{docker-image-version}` is the docker image downloaded from Docker Hub. Always name an explicit version tag, see the note on the `OWNCLOUD_VERSION` setting below. If you don't start the container with option `-d`, the logs will be displayed in the shell. If you are running it in the background as in the example above, you can display the logs with the command: - -[source,docker] ----- -docker logs oc-eval ----- - -With the command `docker ps` you can list your running docker containers and should see the entry for oc-eval. - -You can log in to your ownCloud instance via a browser at `pass:a[http://localhost:{std-port-http}]` with the preconfigured user `admin` and password `admin`. - -NOTE: Access only works locally with http, not https. - -If the outcome meets the expectations but a supported installation with MariaDB is targeted, remove the eval version before proceeding with the next section. - -[source,docker] ----- -docker kill oc-eval ----- - -This removes the container if you used the option `--rm` as suggested in the example above. If you omitted that option, you need to first run the command: - -[source,docker] ----- -docker rm oc-eval ----- - -When running `docker ps` again, the entry for `oc-eval` should be gone. - -== Docker Compose - -The configuration: - -* Exposes ports {std-port-http}, allowing for HTTP connections. -* Uses separate _MariaDB_ and _Redis_ containers. -* Mounts the data and MySQL data directories on the host for persistent storage. - -The following instructions assume you install locally. For remote access, the value of xref:configuration/server/config_sample_php_parameters.adoc#override-cli-url[OWNCLOUD_DOMAIN] and xref:configuration/server/config_sample_php_parameters.adoc#define-list-of-trusted-domains-that-users-can-log-into[OWNCLOUD_TRUSTED_DOMAINS] must be updated to represent the hostname(s) and/or IP addresses that the server is reachable at. - -. Create a new project directory. -+ --- -[source,bash] ----- -mkdir owncloud-docker-server -cd owncloud-docker-server ----- --- - -. Then copy and paste the sample `docker-compose.yml` as base to derive from: -+ --- -[source,yml] ----- -include::example$installation/docker/docker-compose.yml[] ----- --- - -. Create a `.env` configuration file, which contains the required configuration settings. -+ --- -[source,bash,subs="attributes+"] ----- -cat << EOF > .env -OWNCLOUD_VERSION={docker-image-version} -OWNCLOUD_DOMAIN=localhost:{std-port-http} -OWNCLOUD_TRUSTED_DOMAINS=localhost -ADMIN_USERNAME=admin -ADMIN_PASSWORD=admin -HTTP_PORT={std-port-http} -EOF ----- - -Only a few settings are required, these are: - -[width="100%",cols="45%,50%,80%",options="header"] -|=== -| Setting Name -| Description -| Example - -| `OWNCLOUD_VERSION` -| The ownCloud version. + -Always use an explicit version, never `latest`. -| `{docker-image-version}` - -| `OWNCLOUD_DOMAIN` -| The ownCloud domain -| `localhost:{std-port-http}` - -| `OWNCLOUD_TRUSTED_DOMAINS` -| The ownCloud trusted domains -| `localhost` - -| `ADMIN_USERNAME` -| The admin username -| `admin` - -| `ADMIN_PASSWORD` -| The admin user’s password -| `admin` - -| `HTTP_PORT` -| The HTTP port to bind to -| `{std-port-http}` -|=== - -NOTE: Pin `OWNCLOUD_VERSION` to a full version like `{docker-image-version}`. Do not use the `latest` tag: it does not necessarily point to the release line documented here, so a container restart can pull a different version than you expect. - -NOTE: `ADMIN_USERNAME` and `ADMIN_PASSWORD` will not change between deploys even if you change the -values in the .env file. To change them, you'll need to do `docker volume prune`, which -*will delete all your data*. --- - -. Then, you can build and start the container, using your preferred Docker _command-line tool_. -+ --- -The example below shows how to use {docker-compose-url}[Docker Compose]. - -[source,docker] ----- -docker compose up -d ----- --- - -. When the process completes: -+ --- -Check that all the containers have successfully started, by running `docker compose ps`. If they are all working correctly, you should see output similar to the one below: - -[width="100%",cols="30%,50%,30%,50%",options="header"] -|=== -| Name -| Command -| State -| Ports - -| owncloud_mariadb -| docker-entrypoint.sh --max ... -| Up (healthy) -| {std-port-mysql}/tcp - -| owncloud_redis -| docker-entrypoint.sh --dat ... -| Up (healthy) -| {std-port-redis}/tcp - -| owncloud_server -| /usr/bin/entrypoint /usr/b ... -| Up (healthy) -| 0.0.0.0:{std-port-http}->{std-port-http}/tcp -|=== - -In it, you can see that the database, ownCloud and Redis containers are running, and that ownCloud -is accessible via port {std-port-http} on the host machine. - -[IMPORTANT] -==== -All files stored in this setup are contained in Docker volumes rather than a physical filesystem tree. -It is the admin's responsibility to make the files persistent. - -To inspect the volumes run: -[source,docker] ----- -docker volume ls | grep files ----- - -The volume name depends on the project name which builds the first part of the volume and the name of the volume in the docker file. The naming pattern of the volume is `_`. An environment variable for `COMPOSE_PROJECT_NAME` can be set and also be defined in a `.env` file. If not specified, the directory in which docker compose is executed will be used as a name. - -To export the files of the project "owncloud-docker-server" as a tar archive run: -[source,docker] ----- -docker run -v :/mnt \ - ubuntu tar cf - -C /mnt . > files.tar ----- -==== - -[TIP] -==== -Although the containers are up and running, it may still take a few minutes until ownCloud is fully -functional. + -To inspect the log output: -[source,docker] ----- -docker compose logs --follow owncloud ----- -Wait until the output shows **Starting apache daemon...** before you access the web UI. -==== - -[IMPORTANT] -==== -Although all important data persists after: -[source,docker] ----- -docker compose down; docker compose up -d ----- -there are certain details that get lost, e.g., default apps may re-appear after they were uninstalled. -==== --- - -=== Logging In - -To log in to the ownCloud UI, open `pass:a[http://localhost:{std-port-http}]` in your browser -of choice, where you see the standard ownCloud login screen as in the -image below. - -image:docker/owncloud-ui-login.png[The ownCloud UI via Docker] - -The username and password are the credentials which you stored in `.env` earlier. -Note that these will not change between deploys even if you change the values in .env. - -=== Stopping the Containers - -Again we assume you used `docker compose` like in the previous example. + -To stop the containers use: -[source,docker] ----- -docker compose stop ----- - -To stop and remove containers along with the related networks, images and volumes: -[source,docker] ----- -docker compose down --rmi all --volumes ----- - -=== Running occ commands - -If you want to run an occ command, first go to the directory where your `.yaml` or `.env` file is located. -Here, you are able to run any command referring to -xref:configuration/server/occ_command.adoc[Using the occ Command] by entering: - -[source,docker] ----- -docker compose exec owncloud occ ----- - -[IMPORTANT] -==== -Don't use the `php` command prefix, this leads to several errors and is not intended to run in -docker environments. -==== - -=== Upgrading ownCloud on Docker - -When a new version of ownCloud gets released, you should update your instance. To do so, follow -these simple steps: - -. Go to your docker directory where your `.yaml` and `.env` files exist. -. Put ownCloud into maintenance mode with the following command: -+ -[source,docker] ----- -docker compose exec owncloud occ maintenance:mode --on ----- - -. Create a backup of the database in case something goes wrong during the upgrade process, using the following command: -+ -[source,docker] ----- -docker compose exec mariadb \ - /usr/bin/mysqldump \ - -u root \ - --password=owncloud \ - --single-transaction \ - owncloud > owncloud_$(date +%Y%m%d).sql ----- -+ -NOTE: You need to adjust the password and database name if you have changed it in your deployment. - -. Shutdown the containers: -+ -[source,docker] ----- -docker compose down ----- - -. Update the version number of ownCloud in your `.env` file. You can use sed -for it, as in the following example. -+ -Make sure that you adjust the example to match your installation. -+ -[source,bash] ----- -sed -i 's/^OWNCLOUD_VERSION=.*$/OWNCLOUD_VERSION=/' .env ----- - -. View the file to ensure the change has been implemented. -+ -[source,bash] ----- -cat .env ----- - -. Start your docker instance again. -+ -[source,docker] ----- -docker compose up -d ----- -+ -Now you should have the current ownCloud running with `docker compose`. Note that the container will -automatically run `occ upgrade` when starting up. If you notice the container starting over and over again, -you can check the update log with the following command: -+ -[source,docker] ----- -docker compose logs --timestamp owncloud ----- - -. If all went well, end maintenance mode: -+ -[source,docker] ----- -docker compose exec owncloud occ maintenance:mode --off ----- - -=== Docker Compose YAML File - -The file `docker-compose.yml` contains the configuration of your ownCloud container. - -[NOTE] -==== -Since ownCloud Classic 10.5, the dedicated enterprise docker image `registry.owncloud.com/owncloud/enterprise` is deprecated. All supported enterprise features and apps are now included in the public image `owncloud/server` available on Docker Hub. A login to our registry `registry.owncloud.com` is no longer required. -==== - -[source,yaml] ----- -include::example$installation/docker/docker-compose.yml[Example Docker Compose YAML configuration file for ownCloud Classic.] ----- - -== Troubleshooting - -=== Admin Settings - -When running under docker, the admin user cannot control certain settings in the WebUI, instead they are now controlled by environment variables. Changing these variables requires stopping and restarting the container with extra `docker -e ...` parameters or with new entries in the `.env` file for docker compose. - -==== Logging - -The loglevel is set to the fixed value 2: _"Warnings, errors, and fatal issues"_. - -.To get the highest log level "Everything" (including debug output), use: - -[source,plaintext] ----- -OWNCLOUD_LOGLEVEL=0 ----- - -=== Raspberry Pi - -If your container fails to start on Raspberry Pi or other ARM devices, you most likely have an old version of `libseccomp2` on your host. This should only affect distros based on Rasbian Buster 32 bit. Install a newer version with the following command: - -[source,bash] ----- -cd /tmp -wget http://ftp.us.debian.org/debian/pool/main/libs/libseccomp/libseccomp2_2.5.1-1_armhf.deb -sudo dpkg -i libseccomp2_2.5.1-1_armhf.deb ----- - -Alternatively you can add the backports repo for Debian Buster: - -[source,bash] ----- -sudo apt-key adv --keyserver keyserver.ubuntu.com \ - --recv-keys 04EE7237B7D453EC 648ACFD622F3D138 -echo "deb http://deb.debian.org/debian buster-backports main" | \ - sudo tee -a /etc/apt/sources.list.d/buster-backports.list -sudo apt update -sudo apt install -t buster-backports libseccomp2 ----- - -In any case, you should restart the container after confirming you have `libseccomp2.4.4` installed. - -For more information see: {linux-server-doc-url}[Linux Server Docs] - -=== Terminating containers - -If your container is terminating for whatever reason, you will not be able to run `docker(-compose) exec` to make investigations inside the container as there will be no running container. Instead you need to use `docker(-compose) run`. It's important that you prefix any command to be run by `/usr/bin/owncloud`, otherwise the container will not be initialized correctly. See the example command below: - -[source,bash] ----- -docker( compose) run /usr/bin/owncloud bash ----- diff --git a/content/server/10.15/modules/admin_manual/pages/installation/index.adoc b/content/server/10.15/modules/admin_manual/pages/installation/index.adoc deleted file mode 100644 index 3d45f85..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/index.adoc +++ /dev/null @@ -1,18 +0,0 @@ -= Installation Options -:page-aliases: go/admin-install.adoc - -== Introduction - -This is an overview about the possible installation options for ownCloud Classic. You can install ownCloud Classic manually or use a Docker-based installation. - -== Manual Installation - -* The xref:installation/manual_installation/manual_installation.adoc[Detailed Installation Guide] is a thorough guide for installing ownCloud, containing all the information needed for the prerequisites, the dependencies, the actual installation and the configuration afterwards. The example installation is based on Ubuntu Server. -+ -This guide covers Ubuntu server preparations like dependencies, required packages and other necessary components or configurations including Ubuntu upgrades if necessary, descriptions, explanations and easy copy and paste example commands where possible. You will also get directed to other necessary or recommended sections in the documentation to have a well working ownCloud Classic base ready for production. - -* The xref:installation/quick_guides/ubuntu_20_04.adoc[Quick Installation Guide] is a quick guide for installing ownCloud. This guide cannot go into details and has its limits by nature. If you experience issues like with dependencies of PHP or other relevant things like the operating system, web server or database, you have to use the xref:installation/manual_installation/manual_installation.adoc[Detailed Installation Guide]. - -== Using a Docker-Based Installation - -This guide shows you how to install xref:installation/docker/index.adoc[ownCloud with Docker] using Docker Compose with a YAML file provided by ownCloud. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/installation_wizard.adoc b/content/server/10.15/modules/admin_manual/pages/installation/installation_wizard.adoc deleted file mode 100644 index efee6d8..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/installation_wizard.adoc +++ /dev/null @@ -1,92 +0,0 @@ -= The Installation Wizard -:toc: right -:toclevels: 1 -:passwbasicauth_url: https://wiki.apache.org/httpd/PasswordBasicAuth -:access_control_url: https://httpd.apache.org/docs/2.4/howto/access.html -:page-aliases: go/admin-dir_permissions.adoc - -== Introduction - -When you have installed ownCloud physically, you can either finalize the installation from the command line or the installation wizard. This guide focuses on using the installation wizard. - -IMPORTANT: If you are planning to use the installation wizard, we *strongly* encourage you to protect it through some form of {passwbasicauth_url}[password authentication] or {access_control_url}[access control]. If the installer is left unprotected when exposed to the internet, there is the possibility that a malicious actor could finish the installation and block you out — or worse. So please ensure that only you — or someone from your organization — can access the web installer. - -== Quick Start - -When the ownCloud prerequisites are fulfilled and all ownCloud files are installed, run the Installation Wizard. This involves just three steps: - -1. Point your web browser to `\http://`. -2. Enter your desired administrator’s username and password. -3. Click btn:[Finish Setup]. - -image:installation/install-wizard-a.jpg[Installation Wizard, width=50%] - -Now you can start using your new ownCloud server. Of course, there is much more that you could do to set up your ownCloud server for best performance and security. In the following sections, we will cover important installation and post-installation steps. - -== Detailed Guide - -This section provides a more detailed guide to the installation wizard and the three main topics: - -1. xref:post-installation-steps[Post-Installation Steps] -2. xref:configuration-options[Configuration Options] -3. xref:database-setup-by-owncloud[Database Setup by ownCloud] - -=== Post-Installation Steps - -For hardened security and proper server operation, ownCloud recommends setting the permissions on your ownCloud directories as strictly as possible. This should be done immediately after the initial installation and before running the setup. - -Your HTTP user must own the directories `config/`, `data/`, `apps/` and, if applicable, `apps-external/` so that you can configure ownCloud, create, modify and delete your data files and install apps via the ownCloud Web interface. - -You can find your HTTP user in your HTTP server configuration files, or you can use label-phpinfo. Look for the *User/Group* line. - -* The HTTP user and group in Debian/Ubuntu is `www-data`. -* The HTTP user and group in Fedora/CentOS is `apache`. -* The HTTP user and group in Arch Linux is `http`. -* The HTTP user in openSUSE is `wwwrun`, and the HTTP group is `www`. - -NOTE: When using an NFS mount for the data directory, do not change its ownership from the default. The simple act of mounting the drive will set proper permissions for ownCloud to write to the directory. Changing ownership could cause problems if the NFS mount is lost. - -An easy way to set the correct permissions is to use the scripts provided in the -xref:installation/manual_installation/script_guided_install.adoc[Script-Guided Installation]. - -=== Configuration Options - -Click btn:[Storage and Database] to expose additional installation configuration options for your ownCloud data directory and to select the database and configure the access. - -image:installation/install-wizard-a1.jpg[Installation Configuration Options, width=50%] - -CAUTION: For security reasons, the `data` directory of your ownCloud should be located outside the webroot of your server. - -The location of the `data` directory can either be defined by entering the path here or when installing the ownCloud files. For more information on the latter, see the -xref:installation/manual_installation/script_guided_install.adoc[Script-Guided Installation]. - -If you define the path here, the respective setting in your config.php file will be adjusted. Alternatively, you can create a link `data` pointing to the directory containing the actual files. In this case, the config.php setting for the data directory remains unchanged. - -IMPORTANT: ownCloud’s data directory *must be exclusive to ownCloud* and not be modified manually by any other process or user. - -It is best to configure your data directory location at installation, as it is difficult to move after installation. You may put it anywhere; in this example is it located in `/var/oc_data`. This directory must already exist and must be owned by your webserver user. - -=== Database Setup by ownCloud - -IMPORTANT: Your database and PHP connectors must be installed **before** you run the Installation Wizard. - -After you enter your administrative login for your database, the installer creates a special database user with privileges limited to the ownCloud database. - -Afterward, ownCloud only needs this special ownCloud database user and drops the administrative database login you used before. This new user's name is based on your ownCloud admin user with an `oc_` prefix and given a random password. The ownCloud database user and password are written into `config.php`: - -For MySQL/MariaDB: - ----- -'dbuser' => 'oc_dbadmin', -'dbpassword' => 'pX65Ty5DrHQkYPE5HRsDvyFHlZZHcm', ----- - -For PostgreSQL: - ----- -'dbuser' => 'oc_postgres', -'dbpassword' => 'pX65Ty5DrHQkYPE5HRsDvyFHlZZHcm', ----- - -Click btn:[Finish setup], and you’re ready to start using your new ownCloud server. - diff --git a/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/apache.adoc b/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/apache.adoc deleted file mode 100644 index 4a593fb..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/apache.adoc +++ /dev/null @@ -1,209 +0,0 @@ -= Configure Apache with Let's Encrypt -:toc: right -:toclevels: 1 -:description: Learn how to configure Apache with Let's Encrypt, using Ubuntu Linux with ownCloud. -:keywords: LetsEncrypt, Apache, SSL, OpenSSL -:diffie-hellman-url: https://en.wikipedia.org/wiki/Diffie–Hellman_key_exchange -:sslopensslconfcmd-url: https://httpd.apache.org/docs/trunk/mod/mod_ssl.html#sslopensslconfcmd -:forward-secrecy-1-url: https://www.thesslstore.com/blog/perfect-forward-secrecy-explained/ -:forward-secrecy-2-url: https://scotthelme.co.uk/perfect-forward-secrecy/ -:sslusestapling-url: https://httpd.apache.org/docs/trunk/mod/mod_ssl.html#sslusestapling -:sslstaplingcache-url: https://httpd.apache.org/docs/trunk/mod/mod_ssl.html#sslstaplingcache -:virtual-host-url: https://httpd.apache.org/docs/2.4/vhosts/examples.html -:letsencrypt-url: https://letsencrypt.org/getting-started/ -:ssl-configuration-generator-url: https://ssl-config.mozilla.org/#server=apache&version=2.4.41&config=intermediate&openssl=1.1.1k&guideline=5.6 - -== Introduction - -This guide shows how to configure Apache with Let's Encrypt. - -== Dependencies - -To follow this guide, your server needs to have the following dependencies installed: - -- Apache 2.4.8 or later -- OpenSSL 1.0.2 or later -- {letsencrypt-url}[Let's Encrypt] - -== Assumptions - -This guide assumes these things: - -. That you are using Ubuntu. + - If you are not using Ubuntu, please adjust the instructions to suit your distribution or operating system. -. That your ownCloud installation is configured using a {virtual-host-url}[VirtualHost (vhost)] configuration instead of being configured in the main Apache configuration. -. That the vhost configuration file is stored under `/etc/apache2/sites-available/`. + - Not all distributions use this location, however. Refer to your distribution's Apache documentation, to know where to store yours. - -NOTE: See the {ssl-configuration-generator-url}[SSL Configuration Generator] for setup details depending on your environment, especially the different results based on the selected _Mozilla Configurations_. - -== Create and Configure a Diffie-Hellman Params File - -NOTE: A Diffie-Hellman (DH) params file is necessary for Forward Secrecy and for securing your TLS setup. Read {forward-secrecy-1-url}[Perfect Forward Secrecy Explained] or {forward-secrecy-2-url}[Perfect Forward Secrecy - An Introduction] for more details. - -When using Apache 2.4.8 or later and OpenSSL 1.0.2 or later, you can generate and specify a {diffie-hellman-url}[Diffie-Hellman] (DH) params file. If not already present in your VirtualHost (vhost) file, add an {sslopensslconfcmd-url}[SSLOpenSSLConfCmd] directive and a new certificate with stronger keys, which improves Forward Secrecy. - -TIP: The following OpenSSL command may take quite a while to complete, so be patient. - -You can place the generated SSL certificate into any directory of your choice by running the following command and changing the value supplied to the `-out` option. We recommend storing it in `/etc/apache2/` in this guide, solely for simplicity. - -[source,bash] ----- -sudo openssl dhparam -out /etc/apache2/dh4096.pem 4096 ----- - -Once the command completes, add the following directive to your common SSL configuration: - -[source,apache] ----- -SSLOpenSSLConfCmd DHParameters /etc/apache2/dh4096.pem ----- - -== Let's Encrypt ACME-Challenge - -After that, add an Alias directive for the `/.well-known/acme-challenge` location in your HTTP VirtualHost configuration, as in line four in the following example. - -[source,apache] ----- - - ServerName mydom.tld - - Alias /.well-known/acme-challenge/ /var/www/letsencrypt/.well-known/acme-challenge/ - - Options None - AllowOverride None - ForceType text/plain - RedirectMatch 404 "^(?!/\.well-known/acme-challenge/[\w-]{43}$)" - - - # ... remaining configuration - ----- - -== Create an SSL VirtualHost Configuration - -We recommend creating a separate file for storing the `SSL` directives for each site. If these directives already exist on the virtual host for the site, delete them and include the file instead. This way, after the certificate has been created, you can use the file in any virtual host configuration with SSL enabled for which the certificate is valid without reissuing the SSL certificate. It also eases the management for the web site certificate files, as you can easily include or exclude the file in the virtual config with a single remark and it keeps the files' contents compact. - -[source,bash] ----- -cd /etc/apache2/ -sudo mkdir ssl_rules -touch ssl_rules/ssl_mydom.tld ----- - -./etc/apache2/ssl_rules/ssl_mydom.tld -[source,apache] ----- -# Eases letsencrypt initial cert issuing - -SSLEngine on -SSLCertificateChainFile /etc/letsencrypt/live/mydom.tld/fullchain.pem -SSLCertificateKeyFile /etc/letsencrypt/live/mydom.tld/privkey.pem -SSLCertificateFile /etc/letsencrypt/live/mydom.tld/cert.pem ----- - -[TIP] -==== -To improve SSL performance, we recommend that you use the {sslusestapling-url}[SSLUseStapling] and {sslstaplingcache-url}[SSLStaplingCache] directives. -Here's an example configuration: - -[source,apache] ----- -SSLUseStapling on -SSLStaplingCache shmcb:/tmp/stapling_cache(2097152) ----- -==== - -With the files created and filled-out, update your HTTPS VirtualHost configuration: - -[source,apache] ----- - - ServerName mydom.tld - - # ssl letsencrypt - # Include /etc/apache2/ssl_rules/ssl_mydom.tld - - #... - ----- - -IMPORTANT: For the moment, comment out the `Include` directive, as the certificate files do not, currently, exist. - -== Test and Enable the Apache Configuration - -If not already done, enable the Apache2 ssl module necessary for the ssl configuration. Use the following command to enable it: - -[source,bash] ----- -sudo a2enmod ssl ----- - -With the configuration created, test it by running one of the following two commands: - -[source,bash] ----- -sudo apache2ctl configtest -sudo apache2ctl -t ----- - -It should not display any errors. If it doesn't, load your new Apache configuration by running the following command: - -[source,bash] ----- -sudo apache2ctl graceful ----- - -=== Create the SSL Certificates - -See the Let’s Encrypt xref:installation/letsencrypt/using_letsencrypt.adoc#create-an-ssl-certificate[Create an SSL Certificate] -documentation for how to create the SSL certificates. - -See the Let’s Encrypt xref:installation/letsencrypt/using_letsencrypt.adoc#listing-existing-certificates[Listing Existing Certificates] -documentation for how to list the SSL certificates. - -As the certificate files exist, you can uncomment the `Include` directive in your HTTPS VirtualHost configuration to use them. - -[source,apache] ----- - - ServerName mydom.tld - - # ssl letsencrypt - Include /etc/apache2/ssl_rules/ssl_mydom.tld - - #... - ----- - -== Reload the Apache Configuration - -Finally, reload (or restart) Apache. - -It is now ready to serve HTTPS request for the given domain using the issued certificates. - -[source,bash] ----- -sudo service apache2 reload ----- - -== Add a Redirect Directive - -Now that SSL has been configured and enabled, a redirection of all traffic to the encrypted ssl site needs to be added. Reload the Apache configuration to activate it. - -[source,apache] ----- - - ServerName mydom.tld - Redirect permanent / https:/// - Alias /.well-known/acme-challenge/ /var/www/letsencrypt/.well-known/acme-challenge/ - - Options None - AllowOverride None - ForceType text/plain - RedirectMatch 404 "^(?!/\.well-known/acme-challenge/[\w-]{43}$)" - - - # ... remaining configuration - ----- diff --git a/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/index.adoc b/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/index.adoc deleted file mode 100644 index c8aef69..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/index.adoc +++ /dev/null @@ -1,7 +0,0 @@ -:section-title: Let's Encrypt SSL Certificates -:section-preamble-ender: to configure ownCloud with Let's Encrypt - -include::partial$section_page.adoc[] - -* xref:installation/letsencrypt/using_letsencrypt.adoc[Using Let’s Encrypt SSL Certificates] -* xref:installation/letsencrypt/apache.adoc[Configure Apache with Let's Encrypt] \ No newline at end of file diff --git a/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/using_letsencrypt.adoc b/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/using_letsencrypt.adoc deleted file mode 100644 index 3e52ac9..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/letsencrypt/using_letsencrypt.adoc +++ /dev/null @@ -1,383 +0,0 @@ -= Using Let’s Encrypt SSL Certificates -:toc: right -:toclevels: 1 -:letsencrypt-url: https://letsencrypt.org -:a-record-url: https://support.dnsimple.com/articles/a-record/ -:raymii-ssl-url: https://raymii.org/s/tutorials/Strong_SSL_Security_On_Apache2.html -:certbot-url: https://certbot.eff.org -:certbot-docs-url: https://eff-certbot.readthedocs.io/en/stable/ -:ssl-labs-url: https://www.ssllabs.com/ssltest/ -:crontab-guru-url: https://crontab.guru -:snapcraft-url: https://snapcraft.io/docs/getting-started -:certbot-sudo-url: https://certbot.eff.org/glossary#sudo - -== Introduction - -This page covers how to configure your web server to use {letsencrypt-url}[Let’s Encrypt] as the certificate authority for your ownCloud server. Note that Let’s Encrypt is _not officially supported_, and this page is _community-maintained_. - -* For ease of handling, SSL-specific directives have been moved into a separate file to be included. This can help with first-time certificate issuance as well as with reusing configurations. -* Read the {certbot-docs-url}[Certbot user guide] for details of the commands. -* Let’s Encrypt CA issues short-lived certificates valid for 90 days. Make sure you renew the certificates at least once in this period, because expired certificates need reissuing. A certificate is due for renewal at the earliest 30 days before expiring. Certbot can be forced to renew via options at any time as long as the certificate is valid. - -TIP: Raymii.org provides raymii-ssl-url[an excellent introduction to strong SSL security measures with Apache], if you would like to know more. - -== Requirements & Dependencies - -You require a domain name with a valid {a-record-url}[A-Record] pointing back to your server's IP address. In case your server is behind a firewall, ensure that your server is accessible from the internet by adding the required firewall and port forwarding rules. - -== Install Let’s Encrypt’s Certbot Client - -NOTE: certbot has updated the prerequisites and the way to install the certbot script. You can find how to install it on {certbot-url}/instructions[certbot instructions]. Follow one of the possible ways and continue when ready. - -NOTE: If you have used `certbot-auto` before, read how to upgrade in the {certbot-docs-url}/install.html#certbot-auto[certbot-auto] section. - -In general, to run Certbot, use the following command: - -[source,bash] ----- -sudo certbot ----- - -== Updating Certbot - -Because certbot is using snap for Ubuntu, there is no need to manually check for updates. Snap checks this automatically and does not require admin intervention, although you can configure the update behavior. For details see the {snapcraft-url}[Snap getting started] documentation. - -== Register Your Email Address - -=== First Time Registration - -Now that Certbot is installed, register your email address for urgent renewal and security notifications. This command also prepares Certbot’s environment if it’s not already installed. To do this, run the following command: - -[source,bash] ----- -sudo certbot register --agree-tos --email ----- - -When it executes, you’ll see a question similar to the following, which you can answer "Yes" or "No": - -[source,plaintext] ----- -Saving debug log to /var/log/letsencrypt/letsencrypt.log - -------------------------------------------------------------------------------- -Would you be willing to share your email address with the Electronic Frontier -Foundation, a founding partner of the Let's Encrypt project and the non-profit -organization that develops Certbot? We'd like to send you email about EFF and -our work to encrypt the web, protect its users and defend digital rights. -------------------------------------------------------------------------------- -(Y)es/(N)o: ----- - -When that completes, you’ll see a message similar to the following: - -[source,plaintext] ----- -IMPORTANT NOTES: - 1. Your account credentials have been saved in your Certbot - configuration directory at /etc/letsencrypt. You should make a - secure backup of this folder now. This configuration directory will - also contain certificates and private keys obtained by Certbot so - making regular backups of this folder is ideal. ----- - -Please, *strongly*, consider following its recommendation. - -=== Update Your Registration - -In case you want to update your registered email address use following command: - -NOTE: This will affect all the certificates issued using this account. - -[source,bash] ----- -sudo certbot register --update-registration --email ----- - -When that completes, you’ll see a message similar to the following: - ----- -Saving debug log to /var/log/letsencrypt/letsencrypt.log - -------------------------------------------------------------------------------- -Would you be willing to share your email address with the Electronic Frontier -Foundation, a founding partner of the Let's Encrypt project and the non-profit -organization that develops Certbot? We'd like to send you email about EFF and -our work to encrypt the web, protect its users and defend digital rights. -------------------------------------------------------------------------------- -(Y)es/(N)o: y - -IMPORTANT NOTES: - - Your e-mail address was updated to ----- - -== Create Let’s Encrypt’s Config Files - -Because remembering all the possible options for certbot is difficult, the following scripts ease the use for common tasks because of their self-descriptive name. - -* Create the following files in the Let’s Encrypt directory which can usually be found in `/etc/letsencrypt`. Rename .sh with the name of the domain(s) you want to issue a certificate for. -+ -[source,bash] ----- -cd /etc/letsencrypt -sudo touch cli.ini list.sh renew.sh renew-cron.sh delete.sh .sh ----- - -* Make all files created executable _except_ `cli.ini` by running -+ -[source,bash] ----- -sudo chmod +x *.sh ----- - -* Use `sudo` when running the scripts (unless you are already logged in as the root user) -+ -[NOTE] -==== -All scripts have to be executed with `sudo` as certbot {certbot-sudo-url}[requires enhanced privileges]. -____ -If you're logged in to your server as a user other than root, you'll likely need to put sudo before your Certbot commands so that they run as root (for example, sudo certbot instead of just certbot) -____ -==== - -=== cli.ini - -This file defines some default settings used by Certbot. Use the email address you registered with. Comment or uncomment the post-hook parameter depending on if you want to run post hooks. Running post hooks will reload the web server configuration automatically if a certificate has been renewed. - -[source,ini] ----- -include::example$installation/lets_encrypt/cli.ini[] ----- - -[NOTE] -==== -For the following scripts, replace the path to Certbot and the Certbot script name based on your installation. You can find it by running: - -[source,plaintext] ----- -which certbot ----- -==== - -=== list.sh - -This script lists all your issued certificates. - -[source,bash] ----- -include::example$installation/lets_encrypt/list.sh[] ----- - -=== renew.sh - -This script: - -* Renews all your issued certificates. -* In case you have enabled the post hook for your web server in `cli.ini`, it will reload the web server configuration automatically if a certificate has been renewed. - -[source,bash] ----- -include::example$installation/lets_encrypt/renew.sh[] ----- - -=== renew-cron.sh - -This script: - -* Renews all your issued certificates but does not upgrade Certbot. -* In case you have enabled the post hook for your web server in `cli.ini`, it will reload the web server configuration automatically if a certificate has been renewed. - -NOTE: This script is intended for use via Cron. - -[source,bash] ----- -include::example$installation/lets_encrypt/renew-cron.sh[] ----- - -=== delete.sh - -This script deletes an issued certificate. + -Use the `list.sh` script to list issued certificates. - -[source,bash] ----- -include::example$installation/lets_encrypt/delete.sh[] ----- - -=== .sh - -The following example script creates a certificate for a domain or sub-domains, which can be added or removed as necessary. Replace (sub-domain.)example.com with your domain or sub-domain names. The first (sub)domain name in the script is used for naming the directories created by Certbot. - -[NOTE] -==== -You can create different certificates for different sub-domains, such as `example.com`, `www.example.com`, and `subdomain.example.com` by creating different scripts. -==== - -[source,bash] ----- -include::example$installation/lets_encrypt/your-domain-name.sh[] ----- - -NOTE: You can enable the `--dry-run` option which does a test run of the client only. - -== Create an SSL Certificate - -With all the scripts created, to create an SSL certificate, run the -following command: - -[source,bash] ----- -sudo /etc/letsencrypt/.sh ----- - -After you run the script, you will see output similar to the following: - ----- -Saving debug log to /var/log/letsencrypt/letsencrypt.log -Obtaining a new certificate -Performing the following challenges: -http-01 challenge for your-domain-name.com -Using the webroot path /var/www/html for all unmatched domains. -Waiting for verification... -Cleaning up challenges -Running post-hook command: service apache2 reload - -IMPORTANT NOTES: - 1. Congratulations! Your certificate and chain have been saved at: - /etc/letsencrypt/live/your-domain-name.com/fullchain.pem - Your key file has been saved at: - /etc/letsencrypt/live/your-domain-name.com/privkey.pem - Your cert will expire on 2018-06-18. To obtain a new or tweaked - version of this certificate in the future, simply run certbot - again. To non-interactively renew *all* of your certificates, run - "certbot renew" - 2. If you like Certbot, please consider supporting our work by: - - Donating to ISRG / Let's Encrypt: https://letsencrypt.org/donate - Donating to EFF: https://eff.org/donate-le ----- - -You can see that the SSL certificate has been successfully created and that it will expire on 2018-06-18. - -== Listing Existing Certificates - -If you want to list (view) existing SSL certificates, use `list.sh`, which can be run as follows: - -[source,bash] ----- -sudo /etc/letsencrypt/list.sh ----- - -Depending on the number of certificates, you can expect to see output similar to the following: - ----- -------------------------------------------------------------------------------- -Found the following certs: - Certificate Name: your-domain-name.com - Domains: your-domain-name.com - Expiry Date: 2018-06-18 10:57:18+00:00 (VALID: 82 days) - Certificate Path: /etc/letsencrypt/live/your-domain-name.com/fullchain.pem - Private Key Path: /etc/letsencrypt/live/your-domain-name.com/privkey.pem -------------------------------------------------------------------------------- ----- - -== Web Server Setup - -Refer to the xref:installation/letsencrypt/apache.adoc[Apache setup guide], to set up your web server and issue a certificate. - -== Test the Setup - -After you have setup and configured the web server and installed the SSL certificate using Certbot, you should now test the security of your new configuration. To do so, you can use the free service of {ssl-labs-url}[SSL Labs]. See an example screenshot of a test run below. - -image:installation/ssllabs.png[ssllabs] - -== Renewing SSL Certificates - -As Let’s Encrypt certificates expire every 90 days, ensure you renew them before that time. + -There are two ways to do so: -xref:manual-renewal[manually] and xref:automatic-renewal-via-crontab[automatically]. - -=== Manual Renewal - -If you have provided your email address, you will receive reminder notifications. - -[source,bash] ----- -sudo /etc/letsencrypt/renew.sh ----- - -If the certificate is not yet due for renewal, you can expect to see output similar to that below: - ----- -------------------------------------------------------------------------------- -Processing /etc/letsencrypt/renewal/your-domain-name.com.conf -------------------------------------------------------------------------------- -Cert not yet due for renewal - -The following certs are not due for renewal yet: - /etc/letsencrypt/live/your-domain-name.com/fullchain.pem (skipped) -No renewals were attempted. -No hooks were run. ----- - -=== Automatic Renewal via Crontab - -Certificates are only renewed if they are due, so you can schedule Cron -jobs to renew your SSL certificates on a more frequent basis. However, a -weekly check is sufficient. - -To add a new Cron job to auto-renew your certificates, firstly run the -following command to edit the job list. - -[source,bash] ----- -sudo crontab -e ----- - -IMPORTANT: It is essential to use `sudo` to derive proper permissions. - -Then, add the following at the end of the existing configuration: - ----- -30 03 * * 6 /etc/letsencrypt/renew-cron.sh ----- - -After you save and exit the file, the new job will have been added to the Cron job scheduler. - -NOTE: If you want to use different values, you can check them e.g. at {crontab-guru-url}[crontab.guru] and modify the script with your preferred options. - -== Add Extra Domains to the Certificate - -If you want to add an extra domain, like `subdomain.example.com`, to your certificate, add the domain in the domain shell script above, re-run it and reload the web server config. This can be useful when migrating from -a sub-directory for your ownCloud instance to sub-domain access. - -NOTE: This means you need to comment the `include` directive (see the relevant xref:web-server-setup[web server setup]) and follow the steps afterwards. - -== Deleting SSL Certificates - -If you want to delete an SSL certificate, use the delete.sh script, running it as follows: - -[source,bash] ----- -sudo /etc/letsencrypt/delete.sh ----- - -It will start off by displaying a list of the currently available SSL certificate domain names, as in the example below, and then prompt you to supply the certificate you want to delete. - ----- -Available Certificates: - -1. your-domain-name.com - -Which certificate do you want to delete: ----- - -Provide the SSL certificate name that you want to delete and click -btn:[enter], and the certificate and all of its related files will be deleted. -After that you should expect to see a confirmation, as in the example -output below. - ----- -------------------------------------------------------------------------------- -Deleted all files relating to certificate your-domain-name.com. -------------------------------------------------------------------------------- ----- diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/compile_samba.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/compile_samba.adoc deleted file mode 100644 index df857d7..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/compile_samba.adoc +++ /dev/null @@ -1,280 +0,0 @@ -= Compile Samba From Source -:toc: right -:toclevels: 2 -:samba_home_url: https://www.samba.org -:samba_req_pack_url: https://wiki.samba.org/index.php/Package_Dependencies_Required_to_Build_Samba -:samba_download_url: https://download.samba.org/pub/samba/stable/ -:samba_fromsource_url: https://wiki.samba.org/index.php/Build_Samba_from_Source -:samba_conf_options_url: https://vapour-apps.com/build-samba-4-9-from-source-on-debian-9-or-ubuntu-18-04/ -:bugzilla: https://bugzilla.samba.org - -== Introduction - -This guide helps you to compile a particular {samba_home_url}[Samba] version from source which -includes `smbclient`. This may be necessary if the provided version of your OS can not connect to -a file server, in particular to older non Microsoft file servers serving SMB only with NT1. - -NOTE: The guide has been tested, is at it is and comes without any warranty. - -== Prerequisites - -WARNING: It is highly recommended to stop your Web Server and if configured `php-fpm` services. - -=== Uninstalling `samba` - -If you have already installed `smbclient` provided by your OS and you installed the `smbclient` -extension from PECL (to support smbclient in PHP) you need to uninstall them first. Follow the -steps described below to do so. - -NOTE: Copy your smb.conf or other configurations files you may want to keep to reuse them later on. -Purging deletes the config files and helps to make a clean basis. - -[source,bash] ----- -sudo phpdismod smbclient -sudo pecl uninstall smbclient -sudo apt purge smbclient -sudo apt autoremove ----- - -=== Preparing the Installation Environment - -To compile Samba, you need to install necessary packages. Copy the {samba_req_pack_url}[Bootstrap Dependencies Script] from Samba for Ubuntu 20.04. You will find it in section _Verified Package Dependencies_. Post downloading, make the script executable and execute it, which will install all required packages for a successful samba compilation. For your convenience, you can directly download the -xref:attachment$/installation/manual_installation/bootstrap.sh[bootstrap samba master] shell script here. - -[source,bash] ----- -sudo ./bootstrap.sh ----- - -== Prepare Compiling Samba - -=== Download Your Copy of Samba - -The latest version of Samba, which had support for protocol `NT1` as client was version 4.10.18. In all -versions above, the client support was dropped and is not available anymore. If you need `NT1` support -as client, download this version. You can choose any version that fits your needs. A search on -{bugzilla}[bugzilla] may help finding a particular version that fixes the issue you are facing, which is not -provided by the OS delivered version. Keep the downloaded (and later configured) version at a location for -later reuse. This will be necessary if you would like to uninstall it properly. The example uses `/opt`. - -[source,bash] ----- -cd /opt -sudo wget https://download.samba.org/pub/samba/stable/samba-4.10.18.tar.gz ----- - -=== Extract Samba Sources - -[source,bash] ----- -sudo tar -xvf samba-4.10.18.tar.gz -cd samba-4.10.18 ----- - -== Compile Samba - -To compile Samba, you need three steps which are described in detail at -{samba_fromsource_url}[Build Samba from Source]. The complete process may take some time. - -. `sudo ./configure` -. `sudo make` -. `sudo make install` - -=== Configuring the Installation - -The settings for the configuration options are important, so that Samba will be located and setup -for Ubuntu properly. If you are planning to use Samba in your installation where your server -_will act_ as domain controller and not only as a client, you can safely remove `--without-ad-dc` -from the options below. Read more on details {samba_conf_options_url}[config options] for Ubuntu. -For your convenience, you can directly download a -xref:attachment$/installation/manual_installation/compile_samba.sh[compile samba] shell script here. - -[source,bash] ----- -sudo ./configure \ - --prefix=/usr \ - --enable-fhs \ - --sysconfdir=/etc \ - --localstatedir=/var \ - --with-privatedir=/var/lib/samba/private \ - --with-smbpasswd-file=/etc/samba/smbpasswd \ - --with-piddir=/var/run/samba \ - --with-pammodulesdir=/lib/x86_64-linux-gnu/security \ - --libdir=/usr/lib/x86_64-linux-gnu \ - --with-modulesdir=/usr/lib/x86_64-linux-gnu/samba \ - --datadir=/usr/share \ - --with-lockdir=/var/run/samba \ - --with-statedir=/var/lib/samba \ - --with-cachedir=/var/cache/samba \ - --with-socketpath=/var/run/ctdb/ctdbd.socket \ - --with-logdir=/var/log/ctdb \ - --systemd-install-services \ - --without-ad-dc ----- - -=== Start the Compilation - -Start the compilation with following command. Even not mandatory, you can set options to run -multiple jobs in parallel by adding `-j `. This optimizes the CPU utilisation and reduces -the time needed. In the example below, four jobs are enabled to utilize the 4 available cores -of the CPU. - -[source,bash] ----- -sudo make -j 4 ----- - -=== Install the Compiled Software - -To install the compiled software run following command: - -[source,bash] ----- -sudo make install -j 4 ----- - -=== Create a Default `smb.conf` File - -If you do not have an existing or already configured `smb.conf` file, you can create a default one. -The following command creates a new `smb.conf` if it does not exist, but does not overwrite an existing one. - -[source,bash] ----- -sudo cp -n examples/smb.conf.default /etc/samba/smb.conf ----- - -=== Uninstall the Compiled Software - -Uninstalling can be necessary, if you want to have a clean base. This is useful if you want to compile a -different version or the version provided by the OS. To uninstall the compiled software run following command: - -[source,bash] ----- -sudo make uninstall -j 4 ----- - -== Testing - -=== Connection Test to Foreign Host - -When the installation has completed, test your result. If you have used a `smb.conf` file before, -copy it back to its original location (`/etc/samba/`). - -[source,bash] ----- -sudo smbclient --version -Version 4.10.18 ----- - -[source,bash] ----- -sudo smbclient -L -U / ----- - -You now should get a proper response with a directory listing. - -=== Connection Test as Standalone Fileserver - -If you want that this server acts as simple standalone smb fileserver, e.g. for testing, you need to -prepare and set some settings. Following tasks are necessary to start and stop smb as service via systemd. -The smbd service is necessary that your server can act as simple smb file server. - -First create a link to the smb service. - -[source,bash] ----- -sudo ln -s /lib/systemd/system/smb.service /etc/systemd/system/smbd.service ----- - -Then, change some startup parameters. These will not be overwritten on the source file, but be added -via a separate non-destructive process. - -[source,bash] ----- -sudo systemctl edit smbd.service ----- - -Add the following content and save the result. The location and naming will be done automatically. -Just say save. - -[source,plaintext] ----- -[Unit] -After= -After=network.target remote-fs.target nss-lookup.target - -[Service] -Type= -Type=forking -ExecStart= -ExecStart=/usr/sbin/smbd --configfile=/etc/samba/smb.conf ----- - -When finished, reload the daemon to recognize the update: - -[source,bash] ----- -sudo systemctl daemon-reload ----- - -Finally, you can start (stop, reload ect), the smbd service with: - -[source,bash] ----- -sudo service smbd start ----- - -When this is done and the service has started successfully, adopt your smb.conf according your needs as -stand-alone fileserver, test the content by invoking the command `testparm` on the command line and restart -the smbd service. You should then be able to connect to this standalone samba server. - -== Reinstalling Pecl smbclient - -If you had removed `pecl smbcient` before, you can reinstall it now with: - -[source,bash] ----- -sudo pecl channel-update pecl.php.net -sudo pecl install smbclient -sudo phpenmod smbclient ----- - -== Restart Services - -Restart your Web Server and/or `php-fpm` when everything is finished. - -== Scripting the Compiling Procedure - -If you want to automate the compiling procedure, you can perform the following steps. -Prepare a directory structure like in the example below where `opt/` and Samba version `samba-4.10.18` are used: - ----- -opt/ - bootstrap.sh - compile_samba.sh - install_samba.sh - samba-4.10.18 ----- - -Download the scripts: - -* xref:attachment$/installation/manual_installation/bootstrap.sh[bootstrap.sh] -* xref:attachment$/installation/manual_installation/compile_samba.sh[compile_samba.sh] -* xref:attachment$/installation/manual_installation/install_samba.sh[install_samba.sh] - -Make the scripts executable: - -[source,bash] ----- -sudo chmod +x ----- - -Change into the extracted samba directory you want to compile, e.g. `samba-4.10.18`, and run the following command: - -[source,bash] ----- -sudo ../install_samba.sh ----- - -Creating a default `smb.conf` file, testing, uninstalling etc. remain a manual task as described in the above sections. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_imagick7.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_imagick7.adoc deleted file mode 100644 index 3f5251d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_imagick7.adoc +++ /dev/null @@ -1,312 +0,0 @@ -= Install an Updated ImageMagick Version -:toc: right -:imei-url: https://github.com/SoftCreatR/imei/ -:checkinstall-url: https://en.wikipedia.org/wiki/CheckInstall - -ImageMagick shipped for Ubuntu 20.04 is based on version 6, the corresponding `php-imagick` wrapper on version 3.4 which does not have additional capabilities to render particular image types like HEIC or SVG. To install the latest version with many additional image and video capabilities for use with PHP, you must first uninstall and remove the former version of ImageMagick-6 and the old php wrapper and install ImageMagick-7 and the new php-imagick wrapper version +3.5. - -== Backup the ImageMagick Configuration Files - -In case you have made any changes to the configuration files for ImageMagick-6, we recommend to back them up for easy transition to ImageMagick-7 with the following command: - -[source,bash] ----- -sudo cp -rp /etc/ImageMagick-6 /etc/ImageMagick-6.backup ----- - -NOTE: After installing ImageMagick-7 and if you do not define the configuration location, the default configuration files can be found at `/usr/local/etc/ImageMagick-7`. See also the output of the installation script used regarding the various directories set. Use the backup files as base to update them. - -== Remove the Old ImageMagick-6 Installation - -=== Remove php-imagick - -. Check if `php-imagick` is installed: -+ --- -[source,bash] ----- -dpkg -l | grep php | awk '{print $2}' | tr "\n" " " | grep php-imagick ----- - -You will see the name printed if it is installed. --- - -. Check if the `imagick.so` library is installed: -+ -[source,bash] ----- -ls `php -i | grep "^extension_dir" | sed -e 's/.*=> //'` | sort | grep imagick ----- - -. Check the installed `php-imagick` version: -+ --- -[source,bash] ----- -php --ri imagick | grep -i "module version" ----- - -If both the `php-imagick` library and the `imagick.so` binary is installed, proceed with the next steps. --- - -. Disable `php-imagick`: -+ -[source,bash] ----- -sudo phpdismod imagick ----- - -. Remove php-imagick: -+ -[source,bash] ----- -sudo apt remove php-imagick ----- - -. Depending on the installation, restart Apache or php-fpm: -+ -[source,bash] ----- -sudo service apache2 restart ----- -+ -or -+ -[source,bash] ----- -sudo service php7.4-fpm restart ----- - -=== Remove ImageMagick-6 - -. Check which ImageMagick version is installed. The version may differ from our example output. -+ -[source,bash] ----- -convert -version | grep -i version - -Version: ImageMagick 6.9.7-4 ----- - -. Remove the old `imagemagick-6` version: -+ -[source,bash] ----- -sudo apt remove imagemagick-6-common ----- - -== Install ImageMagick 7 - -=== Install the Latest ImageMagick-7 Binary - -To install ImageMagick-7, a script is used. Alternatively, you can copy&paste all installation commands step by step from {imei-url}[IMEI - ImageMagick Easy Install]. See the README description for more information on options and parameters. IMEI uses {checkinstall-url}[Checkinstall] for ease of removing/uninstalling ImageMagick 7 and its components. - -. Change to the /tmp directory: -+ -[source,bas] ----- -cd /tmp ----- -. Download and check the signature of the installation script which is done in four steps: -.. Download the IMEI script -.. Download signature file -.. Download public key -.. Verify the installer -// the following blank line is intended to put the block aligned to the parent item - -+ --- -Run this example to do all steps in one chained command: - -[source,bash] ----- -wget https://dist.1-2.dev/imei.sh && \ -wget https://dist.1-2.dev/imei.sh.sig && \ -wget https://dist.1-2.dev/imei.sh.pem && \ -openssl dgst -sha512 -verify imei.sh.pem -signature imei.sh.sig imei.sh ----- --- - -. If you get a `Verified OK` message, make the script executable: -+ -[source,bash] ----- -sudo chmod +x imei.sh ----- -. Install the latest ImageMagick-7 release: -+ --- -NOTE: For Ubuntu, ImageMagick uses `/etc` as base for the config directory, see the backup information above. This installation example uses the same base set by an option. Change it according your needs. - -NOTE: Depending on your environment, this may take a while (+25min). - -[source,bash] ----- -sudo ./imei.sh --config-dir "/etc" ----- --- - -. Check if ImageMagic-7 and its libraries have been properly installed -+ -[source,bash] ----- -dpkg -l | grep imei ----- - -. Remove the downloaded script and verification files: -+ -[source,bash] ----- -rm imei.* ----- - -=== Check the Installed ImageMagick-7 Version - -Check the version installed. The version printed may be different than in the example output. - -[source,bash] ----- -convert -version | grep -i version ----- -[source,plaintext] ----- -Version: ImageMagick 7.1.0-2 ... ----- - -=== Get a List of Supported Formats - -Type the following commands to get a list of supported formats: - -[source,bash] ----- -convert identify -list format ----- - -[source,plaintext] ----- - Format Module Mode Description ----------------------------------------------------- - 3FR DNG r-- Hasselblad CFV/H3D39II - 3G2 VIDEO r-- Media Container - 3GP VIDEO r-- Media Container - AAI* AAI rw+ AAI Dune image -... ----- - -=== Reuse Changed Configuration Settings - -If you have changed configuration settings, you can reuse them for ImageMagick 7. Copy either the changed contend of the files in question or the complete files from `/etc/ImageMagick-6.backup` to `/etc/ImageMagick-7`. You may want to keep a backup of the original configuration files. - -=== Secure ImageMagick - -[IMPORTANT] -==== -Make sure to disable ImageMagick's scripting language in + -`/etc/ImageMagick-7/policy.xml` + -by adding or uncommenting this policy: -[source,plaintext] ----- - ----- - -See https://imagetragick.com[ImageTragick] for more information and context. -==== - -=== Install the New ImageMagick PHP Wrapper - -The new `php-imagick` wrapper is installed via PECL and uses the recently installed ImageMagick-7 version as base. - -NOTE: If you have installed the php-wrapper via PECL before and want to reinstall it, you will get a warning that it is already installed. You must remove it first with `sudo pecl uninstall imagick`. - -. Install `php-imagick` -+ --- -The `printf` command auto-accepts the question for using defaults. - -[source,bash] ----- -sudo pecl channel-update pecl.php.net -printf "\n" | sudo pecl install imagick ----- --- - -. Check if file `imagick.ini` is present in `mods-available`. -+ --- -Use your php version in the path of the example command below: - -[source,bash] ----- -ll /etc/php/7.4/mods-available/imagick.ini ----- -If the file is not present, create one: - -[source,bash] ----- -sudo nano /etc/php/7.4/mods-available/imagick.ini ----- - -with following content: - -[source,plaintext] ----- -; configuration for php imagick module -extension=imagick.so ----- --- - -== Enable the php-imagick wrapper - -. After ImageMagick-7 and the php wrapper have been installed, enable the php wrapper: -+ -[source,bash] ----- -sudo phpenmod imagick ----- - -. Depending on the installation, restart Apache or php-fpm: -+ -[source,bash] ----- -sudo service apache2 restart -or -sudo service php7.4-fpm restart ----- - -. Print supported `php-imagick` formats: -+ -[source,bash] ----- -php -r 'phpinfo();' | grep -i "ImageMagick supported formats" ----- - -== TIPS - -=== Reinstall or upgrade ImageMagick-7 and the php wrapper. - -To reinstall or upgrade ImageMagick-7, follow the principle steps described above by disabling and removing the php wrapper first, rerun the imei.sh installation script with the options of choice. The script checks if components need an upgrade and, if that's the case, installs them. Then reinstall the php wrapper, enable it and restart your web server or php-fpm. - -=== Uninstall ImageMagic-7 or components - -If you want to uninstall ImageMagick-7 only, run: - -[source,bash] ----- -sudo apt remove imei-imagemagick ----- - -If you want to completely remove ImageMagic-7 and all of its installed components, run: - -[source,bash] ----- -sudo apt remove imei-imagemagick,imei-libaom,imei-libheif,imei-libjxl ----- - -=== Change Configuration Settings of ImageMagick-7 - -You can change configuration settings of ImageMagick-7 at any time according to your needs. In case you do so, restart your web server of the php-fpm service post changing the settings so they can take effect for web services. - - -=== Previews Configuration Rules - -If you need to configure or enable previews for formats not enabled by default, see xref:configuration/files/previews_configuration.adoc#notes-for-pdf-preview-generation[Notes for PDF Preview Generation] which can serve as a template. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation.adoc deleted file mode 100644 index 09a976c..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation.adoc +++ /dev/null @@ -1,228 +0,0 @@ -= Detailed Installation Guide -:toc: right -:mod_headers-url: https://httpd.apache.org/docs/current/mod/mod_headers.html#page-header -:download_oc_url: https://owncloud.com/download-server/ -:page-aliases: installation/source_installation.adoc - -== Introduction - -This document describes: - -* How to prepare your server -* Prerequisites and how to download ownCloud -* Installation of ownCloud - -The following descriptions focus on the Ubuntu distribution. Even if we try to make these steps -as easy as possible by offering ready to use commands and scripts, you need to have sufficient -knowledge about administrating a server environment which provides web services. - -IMPORTANT: This document does not offer proposals about how to secure your server. Therefore, we strongly recommend checking out the xref:configuration/server/harden_server.adoc[Hardening and Security Guidance] before the installation and to keep it on hand throughout. - -== Prepare Your Server - -For more information on the requirements of your server, read the -xref:installation/manual_installation/manual_installation_prerequisites.adoc[general prerequisites guide]. -The following sections describe the procedures in detail. - -=== Ubuntu 20.04 LTS Server - -To prepare your Ubuntu 20.04 server for the use with ownCloud, follow the -xref:installation/manual_installation/server_prep_ubuntu_20.04.adoc[Ubuntu 20.04 preparation guide]. -This guide installs PHP 7.4 - -=== Ubuntu 22.04 LTS Server - -To prepare your Ubuntu 22.04 server for the use with ownCloud, follow the -xref:installation/manual_installation/server_prep_ubuntu_22.04.adoc[Ubuntu 22.04 preparation guide]. - -NOTE: Ubuntu 22.04 only provides PHP 8.x which is currently not supported by ownCloud. Therefore PHP 7.4 is installed via PPA. - -=== Install a Database - -If you do not already have a supported database installed, follow the -xref:installation/manual_installation/manual_installation_db.adoc[Manual Database Installation guide]. - -=== Configure the Web Server - -To configure your Apache web server for use with ownCloud, follow the -xref:installation/manual_installation/manual_installation_apache.adoc[Apache preparation guide]. - -== Installation of ownCloud Binaries - -To install ownCloud binaries, you have to download the required package. After doing so, -you can perform the following steps manually or use the provided scripts. These scripts are convenient -since they can also be used for upgrading which eases the process a lot. - -=== Download ownCloud - -Before downloading ownCloud, change to a directory where you want to save -the file temporarily. This can be, for example `/tmp`. In further examples, we use tar archives or the complete ownCloud bundle. The name for the complete archive looks like this: -`owncloud-complete-yyyymmdd.archive_type`. - -Download the archive of the latest ownCloud version: - -. Go to the {download_oc_url}[ownCloud Download Page] and select the package that fits your needs. - You can download either the `.tar.bz2` or `.zip` archive. Based on the example below, copy the - link of the selected file and run the following command to download it: + -+ -[source,bash,subs="attributes+"] ----- -wget {oc-complete-base-url}/{oc-complete-name}.tar.bz2 ----- - -. Download the corresponding checksum file like: -+ -[source,bash,subs="attributes+"] ----- -wget {oc-complete-base-url}/{oc-complete-name}.tar.bz2.md5 - or -wget {oc-complete-base-url}/{oc-complete-name}.tar.bz2.sha256 ----- - -. Verify the MD5 or SHA256 sum: -+ -[source,bash,subs="attributes+"] ----- -sudo md5sum -c {oc-complete-name}.tar.bz2.md5 < {oc-complete-name}.tar.bz2 - or -sudo sha256sum -c {oc-complete-name}tar.bz2.sha256 < {oc-complete-name}.tar.bz2 ----- - -. You can also verify the PGP signature: -+ -[source,bash,subs="attributes+"] ----- -wget {oc-complete-base-url}/{oc-complete-name}.tar.bz2.asc - -gpg --verify {oc-complete-name}.tar.bz2.asc {oc-complete-name}.tar.bz2 ----- - -=== Script-Guided Installation - -Use the xref:installation/manual_installation/script_guided_install.adoc[Script-Guided Installation] -if you want to easily **install** or **upgrade** ownCloud or **manage ownership and permissions**. The page -contains detailed instructions about downloading and usage. - -TIP: Using the _Script Guided Installation_, you can handle many useful installation and update -options automatically. - -=== Command Line Installation - -Use the following commands if you want to do the basic setup without any changes and physical installation options. -Consider using the xref:installation/manual_installation/script_guided_install.adoc[Script-Guided Installation] -if you plan to improve your setup from step one. - -* Extract the archive contents and run the unpacking command for your tar archive: -+ -[source,bash,subs="attributes+"] ----- -tar -xjf {oc-complete-name}.tar.bz2 ----- - -* tar unpacks to a single `owncloud` directory. - Copy the ownCloud directory to its final destination. - If you are running the Apache HTTP server, you may safely install ownCloud in your Apache document root. - Assuming your document root is in `/var/www`. -+ -[source,bash] ----- -cp -r owncloud /var/www ----- - -After the installation, set the correct ownership and permissions according to the needs of your environment. While you can do that manually, we suggest using the scripts from the -xref:installation/manual_installation/script_guided_install.adoc[Script-Guided Installation] which ease the process a lot. - -== Complete the Installation - -After restarting Apache, you must complete your installation by running either the -Graphical Installation Wizard or on the command line with the `occ` command. - -After finalizing the installation, re-run the script provided in -xref:installation/manual_installation/script_guided_install.adoc[Script-Guided Installation] -to secure your `.htaccess` files. Your ownCloud instance is now ready to use. - -=== Finalize Using the Graphical Installation Wizard - -To finalize the installation using the graphical installation wizard, refer to the -xref:installation/installation_wizard.adoc[Graphical Installation Wizard]. - -=== Finalize Using the Command Line - -If you want to finalize the installation via the command line, use the following example -command. The command assumes that you have unpacked the source to `/var/www/owncloud/`. -Replace all the parameters according to your needs. - -[source,bash,subs="attributes+"] ----- -cd /var/www/owncloud/ -{occ-command-example-prefix} maintenance:install \ - --database "mysql" \ - --database-name "owncloud" \ - --database-user "root"\ - --database-pass "password" \ - --admin-user "admin" \ - --admin-pass "password" ----- - -On how to use `occ`, refer to the xref:configuration/server/occ_command.adoc[occ command reference]. + - -NOTE: Admins of SELinux-enabled distributions may need to write new SELinux rules to complete -their ownCloud installation; see the -xref:installation/selinux_configuration.adoc[SELinux Configuration Guide] -for a suggested configuration. - -== Post Installation Configuration - -After installing ownCloud successfully, ownCloud recommends that you perform some post -installation tasks. These tasks help configure background jobs or improve performance -by caching. - -NOTE: At this point, we'd also like to remind you to consult the xref:configuration/server/harden_server.adoc[Hardening and Security Guidance] section. - -=== Background Jobs - -To read more about background jobs and how to configure them, read the -xref:configuration/server/background_jobs_configuration.adoc[Background Job Configuration] guide. - -=== Configure Caching - -It is recommended to install and enable caching (PHP opcode cache and/or data cache), which -significantly improves performance. For more information, read the -xref:configuration/server/caching_configuration.adoc[Caching Configuration] guide. - -== Notes - -=== Headers - -NOTE: ownCloud has a mechanism to set headers programmatically. -These headers are set with the `always` directive to avoid errors when there are additional -headers set in the web server's configuration file like `http.conf`. -More information on headers can be found in the {mod_headers-url}[`mod_headers`] documentation. - -=== Managing Trusted Domains - -All URLs used to access your ownCloud server must be white-listed in your `config.php` file -under the `trusted_domains` setting. Users are allowed to log in to ownCloud only when they -point their browsers to a URL that is listed in the `trusted_domains` setting. - -NOTE: This setting is important when changing or moving to a new domain name. -You may use IP addresses and domain names. - -A typical configuration may look like this: - -[source,php] ----- -'trusted_domains' => [ - 0 => 'localhost', - 1 => 'server1.example.com', - 2 => '192.168.1.50', -], ----- - -The loopback address, `127.0.0.1`, is automatically white-listed, so as long as you have access to the physical server you can always log in. -In the event that a load-balancer is in place, there will be no issues as long as it sends the correct `X-Forwarded-Host` header. - -NOTE: For further information on improving the quality of your ownCloud installation, see xref:installation/configuration_notes_and_tips.adoc[the configuration notes and tips guide]. - -NOTE: Admins of SELinux-enabled distributions such as _CentOS_, _Fedora_, and _Red Hat Enterprise Linux_ may need to set new rules to enable installing ownCloud. -See xref:installation/selinux_configuration.adoc[SELinux Configuration Guide] for a suggested configuration. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_apache.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_apache.adoc deleted file mode 100644 index 41e6e61..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_apache.adoc +++ /dev/null @@ -1,141 +0,0 @@ -= Configure Apache for Manual Installation on Linux -:toc: right -:toclevels: 3 -:mod_headers_url: http://httpd.apache.org/docs/current/mod/mod_headers.html -:mod_unique_id_url: http://httpd.apache.org/docs/current/mod/mod_unique_id.html -:prefork_url: https://httpd.apache.org/docs/2.4/mod/prefork.html -:apache_doc_url: https://httpd.apache.org/docs/current/en/ - -== Introduction - -This document describes the basic configuration of your Apache webserver for the use with -ownCloud. It assumes that you already have successfully installed the Apache Webserver. -Please read the {apache_doc_url}[Apache Documentation] for more or enhanced configuration options. - -== Configure Apache - -On Debian, Ubuntu, and their derivatives, Apache installs with a useful configuration. -All you have to do is create an `/etc/apache2/sites-available/owncloud.conf` file with these lines in it, -replacing the *Directory* and other file paths with your own file paths: - -[source,apache] ----- -Alias /owncloud "/var/www/owncloud/" - - - Options +FollowSymlinks - AllowOverride All - - - Dav off - - ----- - -Then create a symlink to /etc/apache2/sites-enabled: - ----- -sudo ln -s /etc/apache2/sites-available/owncloud.conf /etc/apache2/sites-enabled/owncloud.conf ----- - -== Additional Apache Configurations - -* For ownCloud to work correctly, you need the module `mod_rewrite`. Enable it by running: `a2enmod rewrite`. Additionally recommended modules are `mod_headers`, `mod_env`, `mod_dir`, `mod_mime`, and `mod_unique_id`. To enable them, run the following commands: -+ -[source,bash] ----- -sudo a2enmod headers -sudo a2enmod env -sudo a2enmod dir -sudo a2enmod mime -sudo a2enmod unique_id ----- -+ -NOTE: If you want to use the {oc-marketplace-url}/apps/oauth2[OAuth2 app], then {mod_headers_url}[mod_headers] must be installed and enabled. - -* You must disable any server-configured authentication for ownCloud since it uses basic authentication internally for DAV services. If you have turned on authentication on a parent folder (e.g. via an `AuthType Basic` directive), you can disable the authentication specifically for the ownCloud entry. As in the above example configuration file, add the following line in the `Directory` section: -+ -[source,apache] ----- -Satisfy Any ----- - -* When using SSL, take special note of the `ServerName`. You should specify one in the server configuration as well as in the `CommonName` field of the certificate. If you want your ownCloud to be reachable via the internet, set both of these to the domain for your ownCloud server. - -* Now restart Apache -+ -[source,bash] ----- -sudo service apache2 restart ----- - -* If you’re running ownCloud in a sub-directory and want to use CalDAV or CardDAV clients, make sure you have configured the correct -xref:configuration/general_topics/general_troubleshooting.adoc#service-discovery[Service Discovery] URLs. - -=== Apache Mod_Unique_Id Configuration - -The use of `mod_unique_id` enables an administrator to trace requests via logfiles. - -NOTE: {mod_unique_id_url}[mod_unique_id] provides a magic token for each request which is guaranteed to be unique across "all" requests under very specific conditions. - -If you enable the module, there is nothing else you have to do as ownCloud automatically includes the `UNIQUE_ID` environment variable, provided by the module, in ownCloud's log file. - -To confirm that it's working, check that the `UNIQUE_ID` environment variable is being set by running `phpinfo()` (like in the screenshot below). - -image:installation/webservers/apache/mod_unique_id/phpinfo.png[phpinfo() showing that Apache -is sending the UNIQUE_ID value from mod_unique_id] - -Next, compare the value set for `UNIQUE_ID` in the output of `phpinfo()` with the value in ownCloud's log file to ensure that they're the same. In the example below, you can see an example log entry, where ownCloud is logging the unique id provided by Apache as the value for the first key `reqId` in the record. - -[source,json] ----- -include::example$installation/webservers/apache/log-entry.json[] ----- - -=== Using SSL - -You can use ownCloud over plain HTTP, but we strongly encourage you to use SSL/TLS to encrypt all of your server traffic and to protect users’ logins and data in transit. - -==== Use a Professional Certificate - -You can install any purchased or free certificate like the ones via Let's Encrypt. - -Read -xref:installation/letsencrypt/index.adoc[Using Let's Encrypt SSL Certificates] -if you want to use free of charge certificates for Apache. - -==== Use the Default Simple Self-Signed Certificate - -Apache installed on an Ubuntu system comes already set up with a simple self-signed certificate. - -NOTE: Self-signed certificates have their drawbacks - especially when you plan to make your ownCloud server publicly accessible. You may want to consider getting a certificate signed by a commercial signing authority or a free certificate like the ones from Let's Encrypt. - -Using the simple self-signed certificate provided by the Apache installation, all you have to do is to enable the `ssl` module and the default site. Open a terminal and run: - -[source,bash] ----- -sudo a2enmod ssl -sudo a2ensite default-ssl -sudo service apache2 reload ----- - -=== Multi-Processing Module (MPM) - -{prefork_url}[Apache prefork] has to be used. Don’t use a threaded `MPM` like `event` or -`worker` with `mod_php`, because PHP is currently {php-net-url}/manual/en/install.unix.apache2.php[not thread safe]. - -If you want to use a threaded MPM, look at a FastCGI configuration where PHP is running -in its own memory space. ownCloud limits its support to Apache prefork only. - -[NOTE] -==== -In case you have enabled `mpm_event` during an earlier setup of Apache, you may get conflict notes from Apache. Use the following commands to solve this issue. The order of commands is recommended to ensure a smooth transition. - -[source,bash] ----- -sudo a2dismod mpm_event -sudo systemctl restart apache2 -sudo a2enmod mpm_prefork -sudo systemctl restart apache2 ----- -==== diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_db.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_db.adoc deleted file mode 100644 index eee39ce..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_db.adoc +++ /dev/null @@ -1,72 +0,0 @@ -= Manual Installation Databases -:toc: right -:page-partial: - -== Introduction - -This document gives you an overview of databases supported by ownCloud. It describes some basic installation steps and how to create an administrative user for the database. This administrative user is necessary so that the ownCloud database and user who further manages the ownCloud database can be created The ownCloud database user has no access -to other databases! - -== Possible Databases - -When installing ownCloud Classic & ownCloud Enterprise editions, the administrator may choose one of four supported database products. These are: - -* SQLite -* MYSQL/MariaDB (recommended) -* PostgreSQL -* Oracle 11g (Enterprise-edition only) - -IMPORTANT: After selecting and installing a database as described below, read the xref:configuration/database/linux_database_configuration.adoc[Database Configuration on Linux] -documentation for more information regarding database engine configuration. - -== SQLite - -NOTE: SQLite is not supported by the ownCloud Enterprise edition. - -IMPORTANT: SQLite should **only** be used for testing and lightweight single user setups. - -SQLite has no client synchronization support, so other devices will not be able to synchronize with the data stored in an ownCloud SQLite database. - -== MYSQL/MariaDB - -MariaDB is the ownCloud recommended database. It may be used with either ownCloud Classic or ownCloud Enterprise editions. Please look for additional configuration parameters in the xref:configuration/database/linux_database_configuration.adoc[Database Configuration on Linux] guides. - -Once the database installation is complete, refer to the Database section in the xref:configuration/server/harden_server.adoc#database[Hardening and Security Guidance] guide for additional important information. - -include::partial$installation/manual_installation/mariadb.adoc[leveloffset=+1] - -== PostgreSQL - -To install postgres, use the following command (or that of your preferred package manager): - -[source,bash] ----- -sudo apt-get install postgresql php-pgsql ----- - -In order to allow ownCloud access to the database, create an `ownlcoud` user who owns the `owncloud` database. The user and the database name can be any name that fits your needs. - -Create the `owncloud` PostgreSQL user account. Note that the default admin account post installing PostgreSQL is `postgres`. If you have created another postgres admin user and disabled the default one, use the new one instead. -[source,bash] ----- -sudo -u postgres -c "createuser -e -P owncloud" ----- - -Define a password for the `owncloud` user. Note to remember this password to access the database later on: -[source,plaintext] ----- -Enter new password: -Enter it again: ----- - -Create the `owncloud` database owned by the `owncloud` user: -[source,bash] ----- -sudo -u postgres -c "createdb -e -O owncloud owncloud" ----- - -== Oracle 11g - -Oracle 11g is **only** supported for the ownCloud Enterprise edition. Please see the -xref:enterprise/installation/oracle_db_configuration.adoc[Oracle Database Setup & Configuration] -in the Enterprise documentation section. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_prerequisites.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_prerequisites.adoc deleted file mode 100644 index 1e7861d..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/manual_installation_prerequisites.adoc +++ /dev/null @@ -1,303 +0,0 @@ -= Prerequisites for Manual Installation on Linux -:toc: right -:description: This document guides you through the prerequisites for a manual ownCloud Classic installation on Linux. - -:avconv-url: https://libav.org/ -:ffmpeg-url: https://ffmpeg.org/ -:openoffice-url: https://www.openoffice.org/ -:libreoffice-url: https://www.libreoffice.org/ -:pecl-package-url: https://pecl.php.net/package -:sabre-url: http://sabre.io/ -:gnu-make-url: https://www.gnu.org/software/make/ - -== Introduction - -{description} - -The ownCloud tar archive contains all of the required third-party PHP libraries. As a result, no extra ones are strictly necessary. However, ownCloud does require that PHP has a set of extensions installed, enabled and configured. - -This section lists both the required and optional PHP extensions. If you need further information about a particular extension, please consult the relevant section of the {php-net-url}/manual/en/extensions.php[extensions section of the PHP manual]. - -If you are using a Linux distribution, it should have packages for all the required extensions. You can check the presence of a module by typing `php -m | grep -i `. If you get a result, the module is present. - -== Required Prerequisites - -=== openSSL Version - -ownCloud requires that you have openSSL version 1.1.x installed. With the release change of openSSL v1.x to openSSL version 3.x in December 2021, some ciphers which were valid in version 1.x, have been retired with immediate effect. This impacts the ownCloud xref:configuration/files/encryption/encryption_configuration.adoc[encryption app]. - -[IMPORTANT] -==== -If you plan to: - -* upgrade the openSSL version of your server to v3 **or** -* install or upgrade your server where the server upgrade delivers the new openSSL v3 version **and** -* you have enabled and use encryption - -your encryption environment will break due to openSSL v3 retired (legacy) ciphers. As a result, encrypted files cant be accessed. As a _temporary solution_, you have to manually reenable in the openSSL v3 config the legacy ciphers. To do so, see the example in the https://wiki.openssl.org/index.php/OpenSSL_3.0#Providers[OpenSSL 3.0 Wiki,window=_blank] at section **6.2 Providers**. -==== - -How to implement the fix for the above mentioned issue: - -. Find the openssl config directory with -+ --- -[source,bash] ----- -openssl version -d ----- - -Output example: - -`OPENSSLDIR: "/usr/lib/ssl"` --- - -. Go in to that directory and open the config file `openssl.cnf` -+ --- -Look for: - -[source,plaintext] ----- -[openssl_init] -providers = provider_sect ----- - -and add this line below - -`legacy = legacy_sect` - -then look for - -[source,plaintext] ----- -[default_sect] -# activate = 1 ----- - -remove the "#" before "activate" and add the following lines below: - -[source,plaintext] ----- -[legacy_sect] -activate = 1 ----- --- - -. The file should now look like this: -+ -[source,plaintext] ----- -openssl_conf = openssl_init - -[openssl_init] -providers = provider_sect - -[provider_sect] -default = default_sect -legacy = legacy_sect - -[default_sect] -activate = 1 - -[legacy_sect] -activate = 1 ----- - -. Save the file and you have enabled OpenSSL legacy support. - -=== PHP Version - -ownCloud can run with following PHP versions: {supported-php-versions} - -[IMPORTANT] -==== -PHP 7.4 *must* be used for all installations. Sites currently using a different PHP version *must* migrate to PHP 7.4. -==== - -[IMPORTANT] -==== -Note that PHP 8.x is currently not supported. -==== - -==== PHP Extensions - -[width="100%",cols="28%,72%",options="header",] -|==== -| Name -| Description - -| {php-net-url}/manual/en/book.ctype.php[Ctype] -| For character type checking - -| {php-net-url}/manual/en/book.curl.php[cURL] -| Used for aspects of HTTP user authentication - -| {php-net-url}/manual/en/book.dom.php[DOM] -| For operating on XML documents through the DOM API - -| {php-net-url}/manual/en/book.image.php[GD] -| For creating and manipulating image files in a variety of different image formats, including GIF, PNG, JPEG, WBMP, and XPM - -| {php-net-url}/manual/en/function.hash.php[HASH Message] {php-net-url}/manual/en/function.hash.php[Digest Framework] -| For working with message digests (hash) - -| {php-net-url}/manual/en/book.iconv.php[iconv] -| For working with the iconv character set conversion facility - -| {php-net-url}/manual/en/book.intl.php[intl] -| Increases language translation performance and fixes sorting of non-ASCII characters - -| {php-net-url}/manual/en/book.json.php[JSON] -| For working with the JSON data-interchange format - -| {php-net-url}/manual/en/book.libxml.php[libxml] -| This is required for the -{php-net-url}/manual/en/book.dom.php[DOM], -{php-net-url}/manual/en/book.libxml.php[libxml], -{php-net-url}/manual/en/book.simplexml.php[SimpleXML], and -{php-net-url}/manual/en/book.xmlwriter.php[XMLWriter] extensions to work. -It requires that libxml2, version 2.7.0 or higher, is installed - -| {php-net-url}/manual/en/book.mbstring.php[Multibyte String] -| For working with multibyte character encoding schemes - -| {php-net-url}/manual/en/book.openssl.php[OpenSSL] -| For symmetric and asymmetric encryption and decryption, PBKDF2, PKCS7, PKCS12, X509 and other crypto operations - -| {php-net-url}/manual/en/book.pdo.php[PDO] -| This is required for the pdo_msql function to work - -| {php-net-url}/manual/en/book.phar.php[Phar] -| For working with PHP Archives (.phar files) - -| {php-net-url}/manual/en/book.posix.php[POSIX] -| For working with UNIX POSIX functionality - -| {php-net-url}/manual/en/book.simplexml.php[SimpleXML] -| For working with XML files as objects - -| {php-net-url}/manual/en/book.xmlwriter.php[XMLWriter] -| For generating streams or files of XML data - -| {php-net-url}/manual/en/book.zip.php[Zip] -| For reading and writing ZIP compressed archives and the files inside them. - -| {php-net-url}/manual/en/book.zlib.php[Zlib] -| For reading and writing gzip (.gz) compressed files -|==== - -NOTE: The _Phar_, _OpenSSL_, and _cUrl_ extensions are mandatory if you want to use {gnu-make-url}[Make] xref:developer_manual:general/devenv.adoc[to setup your ownCloud environment], prior to running either the web installation wizard, or the command line installer. - -==== Database Extensions - -[cols=",",options="header",] -|==== -| Name -| Description - -| {php-net-url}/manual/en/set.mysqlinfo.php[mysql] -| For working with MySQL & MariaDB - -| {php-net-url}/manual/en/book.pgsql.php[pgsql] -| For working with PostgreSQL. It requires PostgreSQL 9.0 or above - -| {php-net-url}/manual/en/book.sqlite3.php[sqlite] -| For working with SQLite. It requires SQLite 3 or above. This is, usually, not recommended for performance reasons -|==== - -=== Required For Specific Apps - -[cols=",",options="header",] -|==== -| Name -| Description - -| {php-net-url}/manual/en/book.ftp.php[ftp] -| For working with FTP storage - -| {php-net-url}/manual/de/book.ssh2.php[sftp] -| For working with SFTP storage - -| {php-net-url}/manual/en/book.imap.php[imap] -| For IMAP integration - -| {php-net-url}/manual/en/book.ldap.php[ldap] -| For LDAP integration - -| {pecl-package-url}/smbclient[smbclient] -| For SMB/CIFS integration -|==== - -NOTE: SMB/Windows Network Drive mounts require the PHP module smbclient version 0.8.0+. See xref:configuration/files/external_storage/smb.adoc[SMB/CIFS]. - -=== Optional - -[cols=",",options="header",] -|==== -| Extension -| Reason - -| {php-net-url}/manual/en/book.bzip2.php[Bzip2] -| Required for extraction of applications - -| {php-net-url}/manual/en/book.fileinfo.php[Fileinfo] -| Highly recommended, as it enhances file analysis performance - -| {php-net-url}/manual/en/book.mcrypt.php[Mcrypt] -| Increases file encryption performance - -| {php-net-url}/manual/en/book.openssl.php[OpenSSL] -| Required for accessing HTTPS resources - -| {php-net-url}/manual/en/book.imagick.php[imagick] -| Required for creating and modifying images and preview thumbnails -|==== - -== Recommended Prerequisites - -=== For Specific Apps - -[cols=",",options="header",] -|==== -| Extension -| Reason - -| {php-net-url}/manual/en/book.exif.php[Exif] -| For image rotation in the pictures app - -| {php-net-url}/manual/en/book.gmp.php[GMP] -| For working with arbitrary-length integers -|==== - -==== For Server Performance - -For enhanced server performance consider installing one of the following cache extensions: - -* {php-net-url}/manual/en/book.apcu.php[apcu] -* {php-net-url}/manual/en/book.memcached.php[memcached] -* {pecl-package-url}/redis[redis] (>= 2.2.6+, required for transactional file locking) - -See xref:configuration/server/caching_configuration.adoc[Caching Configuration] to learn how to select and configure Memcache. - -==== For Preview Generation - -* {avconv-url}[avconv] or {ffmpeg-url}[ffmpeg] -* {openoffice-url}[OpenOffice] or {libreoffice-url}[LibreOffice] - -==== For Command Line Processing - -[cols=",",options="header",] -|==== -| Extension -| Reason - -| {php-net-url}/manual/en/book.pcntl.php[PCNTL] -| Enables command interruption by pressing `ctrl-c` -|==== - -NOTE: You don’t need the WebDAV module for your Web server (i.e., Apache’s `mod_webdav`), as ownCloud has a built-in WebDAV server of its own, {sabre-url}[SabreDAV]. If `mod_webdav` is enabled, you must disable it for ownCloud. See the xref:installation/manual_installation/manual_installation_apache.adoc[Apache preparation guide] for more details. - -=== For MySQL/MariaDB - -The InnoDB storage engine is required, and MyISAM is not supported, see xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB storage engine] for more information. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/script_guided_install.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/script_guided_install.adoc deleted file mode 100644 index faa5a84..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/script_guided_install.adoc +++ /dev/null @@ -1,236 +0,0 @@ -= Scripts for the Script-Guided Installation -:toc: right -:toclevels: 1 -:apache_docs: https://httpd.apache.org/docs/2.4/ -:description: The purpose of the provided scripts is to ease installation or upgrades of ownCloud instances. Using these scripts, you can also reapply ownership and access rights on linked directories if needed. - -== Introduction - -{description} - -== General Info - -It is important to understand how these scripts work and why things are done to process all the steps for a successful, smooth and secure installation or upgrade. - -Installation:: -When you do a fresh installation using this set of scripts, consider using links for the `data/` and `apps-external/` directories. Any copying or moving big directories can cause issues which can be avoided by using links. When doing an upgrade after an installation, the scripts can re-link those directories but will not "migrate" standard ones. If standard directories are used, the admin has to select a suitable method to migrate those directories as part of the upgrade process. You will get notified about this task if necessary. - -Migrating from standard to linked directories:: -You can at any time relocate your `data/` and `apps-external/` directories and link them to the old location using symlinks. This does not impact the functionality but eases upgrade steps a lot. In such a case, parametrize the instance script with the proper values to be prepared for the next upgrade. See some details at the xref:configuration[configuration section] below. -+ -Do not try to use the script to migrate between directory types. Your environment will break and data loss can occur. Any migration from one type to another must be done manually and before using the script. - -Upgrading:: -When upgrading, the scripts rename the current ownCloud directory (usually `owncloud`) to `owncloud-timestamp`. A new and fresh owncloud directory will be created where the files from the tar archive get extracted to. By doing so, nothing gets deleted, overwritten or moved and the existing instance is secured to go back to in case it is needed. Note that the script does not take care of the database. You have to manage a xref:maintenance/backup_and_restore/backup.adoc#backup-the-database[database backup] yourself. When you have decided to use links for `data/` and `apps-external/`, the script will re-link these directories. Nothing gets moved. You can also (re)run the scrips on linked directories to set correct ownership and permissions. When using standard directories, you have to manually migrate them according to your environment and also manually check for correct ownership and permissions. -+ -The scripts take care of your configuration. The relevant files are _copied_ from the backup. -+ -If the upgrade was successful, you can delete the backup or keep it based on your requirements. - -Scripts:: -There are two scripts available. The instance script defines the environment for your ownCloud while the preparation script called by the instance script performs the main tasks. Note that the preparation script asks a couple of questions to decide what you want to achieve. -+ -If you administrate more than one ownCloud instance, you still only need the one `owncloud_prep.sh` script. This script is doing the main job. Have as many instance scripts as you have instances to maintain. Only the instance scripts need configuration, like the respective target directory and other predefined information. The `instance.sh` script (or however you will name it) calls `owncloud_prep.sh` with the configuration you defined for the respective instance. - -The scripts are written for the `bash` shell. After you copy and pasted them, save both in a location for easy access. - -WARNING: Use the following scripts at your own risk. They may not work as expected if not properly configured. - -NOTE: The scripts are only working with tar archives as sources for installations and upgrades. - -TIP: You can also use these scripts if you want to set or reapply strong permissions on linked drectories. - -== Configuration - -* This is a brief overview of main directories in case you use linking. Note that `/mnt/owncloud_data` can be for example nfs mounted. The script takes care of proper linking the source to the target. -+ -[source,plaintext] ----- -/mnt/owncloud_data - └ apps-external - └ data - -/var/www/owncloud - └ apps - └ apps-external -> /mnt/owncloud_data/apps-external - └ data -> /mnt/owncloud_data/data - .. ----- - -* This is a brief overview of main directories in case you use standard directories -+ -[source,plaintext] ----- -/var/www/owncloud - └ apps - └ apps-external - └ data - .. ----- - -While this makes no difference for an installation, upgrading is much easier as you do not need to take care of migrating directories as they are simply re-linked. - -NOTE: You only need to edit the `instance.sh` script (or however you name it), if you want to change the default settings. - -The following table illustrates the variables to be configured and what they mean. - -[width="90%",cols="20%,80%",options="header"] -|=== -|Variable | Description -|ocname | The name of your directory containing the owncloud files (default is owncloud) -|ocroot | The path to ocname, usually /var/www (no trailing slash, default is /var/www) -|linkroot | The path to your source directory for linking **data** and **apps-external** (default /mnt/owncloud_data). You have to prepare this directory in advance and give it proper ownership and r/w permissions for the webserver user. Note that the **apps** directory is always part of the tar archive and therefore be extracted at its default location without being linked. -|htuser | The webserver user (default www-data) -|htgroup | The webserver group (default www-data) -|rootuser | The root user (default root). Necessary to run some commands in the script. Note that the script is not intended to run as superuser for security reasons. -|=== - -. `ocname` + -This is the _directory name_ where your ownCloud files will be saved. Suggestion: Use `owncloud` for a single instance but feel free to pick any name you like. Do not use slashes (`/`). -+ -NOTE: With only one site to serve, use `html` as it requires no additional settings to maintain on the Apache webserver after the installation. If you use any other name like `owncloud`, you need to set the correct directory in the Apache configuration. For more information, see the {apache_docs}[Apache documentation]. If you are hosting additional websites on the same server, better use a name different from the Apache default (html). - -. `ocroot` + -This is the _path_ where `ocname` will be created, for example `/var/www`. + -The path must be resolvable! Do not use trailing slashes (`/`). + -`ocroot`/`ocname` is the path/directory where your webserver points to (document root). + -The script resolves this for example to `/var/www/owncloud`. - -. `linkroot` + -Although not mandatory, it is highly recommended that you use symbolic links for the `data` and `apps-external` directories. The `data` directory can grow very large and any copy or move process might take a long time on upgrades. Therefore this directory is often put on external drives or on NFS mounts. The `apps-external` directory is used for all apps not provided by the ownCloud installation. With any physical upgrade you perform, manual intervention like copying may be necessary before finalizing and upgrade if you are not using links. The use of symbolic links makes the administration much easier and less error-prone. -+ -The script uses `linkroot` as base for both the `data` and `apps-external` directories. If not already present, it creates the directories from scratch and links them, both for the installation and on upgrades. -+ -If you consider using symbolic links, create a base directory at the location of choice (for example: `/mnt/oc_data`) and let that directory be owned by your webserver's user or group. Use this directory as your `linkroot`. Do not use trailing slashes (`/`). - -. `htuser` and `htgroup` + -This is the user and group the webserver uses, usually `www-data`. - -. `rootuser` + -This is the name of the root user, usually `root`. - -== Usage - -It is mandatory to run this script with root privileges, because files and directories will be created and ownership and permissions will be set. Call the instance script like: - -[source,bash] ----- -sudo ./instance.sh ----- - -The script asks you a couple of questions which follow a logical path. Default answers are capitalized. - -.When installing -the script extracts the files with tar and automatically extracts them to the target location without copying. - -.In case of an upgrade -the old instance path is backed up by _renaming and adding a time stamp_. A new target folder with the old name is created. This ensures that in case of extracting and preparation issues, you can easily go back to the previous version. After a successful upgrade, you must manually remove the backup folder. - -The complete script based procedure might look like this (logged in as root user): - -* copy paste from below both scripts, and place them both in the current folder. -* `wget https://download.owncloud.com/server/stable/owncloud-latest.tar.bz2 -O /tmp/owncloud-latest.tar.bz2` -* `sudo -u www-data /var/www/owncloud/occ maintenance:mode --on` -* `bash ./instance.sh` - - Do you want to secure your .htaccess files post installing/upgrade (y/N)? → `n` + - You must choose `n` here, in order to continue. - - Do you want to install a new instance (y/N)? → `n` - - Do you want to upgrade an existing installation (y/N)? → `y` - - Use links for data and apps-external directories (Y/n)? → `n` + - Depending on the setup, a default standard install does not use "links". - - Is the instance in maintenance mode? (y/N)? → `y` + - You must choose `y` here, in order to continue. - - Please specify the tar file to extract with full path: `/tmp/owncloud-latest.tar.bz2` - -+ -[...] (many lines scroll by) -* `ls -ld /var/www/owncloud_*` + - `drwxr-xr-x 12 www-data www-data 4096 Aug 20 16:04 /var/www/owncloud_2024-08-20-15.50.56` -* `backup=/var/www/owncloud_2024-08-20-15.50.56` + - Note the exact numbers as printed with the `ls` command above. -* `rmdir /var/www/owncloud/data/ /var/www/owncloud/apps-external/` -* `mv $backup/data /var/www/owncloud/` -* `mv $backup/apps-external /var/www/owncloud/` -* `sudo -u www-data /var/www/owncloud/occ maintenance:mode --off` -* `sudo -u www-data /var/www/owncloud/occ upgrade` - -TIP: If you do not install or upgrade, the script sets ownership and permissions on linked directories only. - -NOTE: In case of upgrading, if you have customized the `.htaccess` or `.user.ini` file in the ownCloud webroot, you have to manually restore any changes made after the script has finished from the backup folder. Take care to only restore the changes made but not the complete file as this file will be recreated on upgrades by the tar source and may contain different settings provided by ownCloud. Customizing `.htaccess` can be necessary when you e.g. xref:configuration/integration/ms-teams.adoc[Integrate ownCloud into Microsoft Teams]. - -NOTE: In case of upgrading, if you have created links to the apps-external/ and data/ directory, the script will re-link these directories. If you used standard directories, you have to manually migrate any content of these directories back after the script has run. Check that ownership and permissions are correct after migration and in doubt, let the scrips set the correct ones when using linked directories or set them manually - which can take a while depending on the size of the data/ directory. Take care not to overwrite new app versions with older ones. - -=== Script Questions - -* **Do you want to secure your .htaccess files post installing/upgrade (y/N)?** + - Use this if you have configured or upgraded your instance successfully to protect - your .htaccess files. - -* **Do you want to install a new instance (y/N)?** + - Self explaining - -* **Do you want to upgrade an existing installation (y/N)?** + - Use this if you already have a running instance. Prepare your instance by enabling - maintenance mode. For security reasons, you will be asked before the script continues! - -* **Use links for data and apps-external directories (Y/n)?** + - The script uses respectively checks if links or local directories will be / are used. - -* **Do you want to chmod/chown these links (y/N)?** + - This question is only asked when you use links. If you are not installing or upgrading, - answering with yes, you can e.g. re-apply ownership and permissions to the linked `data` and - `apps-external` directories. As written above, the data directory can be very large - and may take long to complete. Note, by design, there is no progressbar... - -* **Please specify the tar file to extract with full path:** + - Used when installing or upgrading only. Enter the full path/filename to the tar source - file, downloaded from ownCloud. - -== Final Steps - -After running the script, you will see success messages when it finishes. - -.When installing -Enter the URL of your ownCloud instance in a browser and continue the setup via the graphical installation wizard. For more information, see xref:installation/installation_wizard.adoc[The Installation Wizard]. -The URL you need to enter in the browser depends on the webserver setup and is either an external URL or, if you installed locally, you should be able to access your ownCloud instance via a browser at `\http://127.0.0.1/owncloud/` or `\http://localhost/owncloud/`. - -.When upgrading -Follow the steps printed on the screen, especially when using standard directories where you have to migrate the `data/` and `apps-external/` directories manually before finalizing the upgrade. Do not forget to reapply manually made changes made to `.htaccess` and `.user.ini` in your owncloud root directory. - -.How to see the difference between two files quickly -The following example command shows you the difference between two files, which is helpful for reapplying manual changes to `.htaccess` and `.user.ini`. Change the paths, directories and files accordingly. -[source,bash] ----- -diff -y -W 70 --suppress-common-lines owncloud/.user.ini owncloud_2022-02-15-09.18.48/.user.ini ----- -[source,plaintext] ----- -post_max_size=513M | post_max_size=1G ----- - -== Creating the scripts - -Save both scripts together in a directory of your choice. Name the `instance.sh` script according to your needs, so you can easily identify to which ownCloud installation it applies. However, the script `owncloud_prep.sh` is called with exactly that name by the instance script, therefore you must save it with exactly that name. - -Edit your version of the `instance.sh` script with the parameters that apply to your environment. - -Next, make both scripts executable (use the correct script names instead of the placeholder): - -[source,bash] ----- -sudo chmod +x scriptname.sh ----- - -. The `instance.sh` script -+ -[source,bash] ----- -include::example$installation/manual_installation/instance.sh[] ----- - -. The `owncloud_prep.sh` script -+ -[source,bash] ----- -include::example$installation/manual_installation/owncloud_prep.sh[] ----- diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/server_prep_ubuntu_20.04.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/server_prep_ubuntu_20.04.adoc deleted file mode 100644 index fc91873..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/server_prep_ubuntu_20.04.adoc +++ /dev/null @@ -1,453 +0,0 @@ -= Server Preparation for Ubuntu 20.04 -:toc: right -:toclevels: 1 -:page-partial: -:ubuntu_upgrade_url: https://www.cyberciti.biz/faq/upgrade-ubuntu-18-04-to-20-04-lts-using-command-line/ -:remove_ppa_url: https://itsfoss.com/how-to-remove-or-delete-ppas-quick-tip/ -:php-common: https://tecadmin.net/enable-disable-php-modules-ubuntu/ -:ondrej-php-url: https://launchpad.net/~ondrej/+archive/ubuntu/php -:libsmbclient-php_url: https://github.com/eduardok/libsmbclient-php -:update-alternatives_url: https://manpages.ubuntu.com/manpages/focal/en/man1/update-alternatives.1.html -:smbclient_url: https://packages.ubuntu.com/search?keywords=smbclient -:pecl_url: https://pecl.php.net/package/smbclient -:phpmyadmin_latest_url: https://www.phpmyadmin.net/downloads/ -:pear-package_url: https://pear.php.net/package/PEAR/ -:page-aliases: installation/manual_installation/server_prep_ubuntu_18.04.adoc -:phpseclib-url: https://phpseclib.com/docs/why - -:description: This guide gives you detailed information on preparing your Ubuntu 20.04 server for the use with ownCloud. - -== Introduction - -{description} - -The target audience for this document are experienced admins with additional needs and setup scenarios. Ubuntu 20.04 by default only provides PHP 7.4. In case you are running a PHP version lower than 7.4, your PHP version is already EOL. Consider upgrading to PHP 7.4. For more information see {php-supported-versions-url}[Currently Supported PHP Versions]. This document considers two basic scenarios. You have/plan to upgrade from 18.04 LTS to 20.04 LTS or you have a fresh Ubuntu 20.04 LTS installation. - -IMPORTANT: PHP 8.0 is not currently supported by the ownCloud server. - -IMPORTANT: Read the xref:installation/manual_installation/manual_installation_prerequisites.adoc#openssl-version[openSSL Version] notes which are important when planning to use encryption. - -NOTE: The commands and links provided in this description should give you proper hints but we cannot take any responsibility. - -== Upgrading from Ubuntu 18.04 to 20.04 - -Without going into the upgrade details, you can now upgrade directly from Ubuntu 18.04 LTS to 20.04 LTS without using the _development_ (`-d`) option when using the `do-release-upgrade` command. For more details see an example description at {ubuntu_upgrade_url}[Upgrade Ubuntu 18.04 to 20.04 LTS using command line] - -[source,bash] ----- -sudo apt update ----- - -[source,bash] ----- -sudo apt upgrade ----- - -[source,bash] ----- -sudo apt dist-upgrade ----- - -[source,bash] ----- -sudo apt autoremove ----- - -[source,bash] ----- -sudo apt install update-manager-core ----- - -[source,bash] ----- -sudo do-release-upgrade ----- - -If you have upgraded successfully and had previously installed any versions of PHP, better uninstall all PHP versions and ALL extensions and perform a fresh PHP 7.4 native installation. This is especially true when using the `ondrej php` PPA as it installs all available PHP versions, which are either no longer needed or supported. To do so, stop any services which depend on or use PHP like your Web Server. Then get a list of all PHP related programs and extensions by typing: - -[source,bash] ----- -dpkg -l | grep php | awk '{print $2}' | tr "\n" " " ----- - -Disable all extensions listed (see the section -xref:useful-commands-for-managing-php-extensions[Useful Commands For Managing PHP Extensions]) - -Then purge them step by step - -[source,bash] ----- -sudo apt purge ----- - -Alternatively, if you are fine removing all packages listed, you can run: - -[source,bash] ----- -sudo apt purge `dpkg -l | grep php | awk '{print $2}' | tr "\n" " "` ----- - -NOTE: Keep a copy of your relevant `php.ini` and other configuration files as reference _before_ you start purging, to quickly reconfigure your PHP 7.4 installation afterwards. - -If you had installed the `ondrej php` PPA, remove it, else it will reinstall PHP from this source again. To do so run: - -[source,bash] ----- -sudo apt install ppa-purge ----- - -[source,bash] ----- -sudo ppa-purge ppa:ondrej/php ----- - -[source,bash] ----- -sudo rm -i /etc/apt/sources.list.d/ondrej-ubuntu-php-* ----- - -[source,bash] ----- -sudo apt update ----- - -You can also follow this guide to remove PPAs: {remove_ppa_url}[How to Remove or Delete PPA in Ubuntu]. - -WARNING: If you have not cleanly removed that ppa you may get conflicts when installing PHP. - -After deinstallation of all versions and extensions of PHP and cleaning up all remnants, you should have an empty `/etc/php` directory. You can proceed like on a fresh installation of Ubuntu 20.04 LTS. - -== Clean Ubuntu 20.04 Installation - -After you have installed your Ubuntu 20.04 LTS server from scratch, use the following commands to -install PHP 7.4 and necessary extensions: - -[source,bash] ----- -sudo apt install php-fpm php-cgi ----- - -[source,bash] ----- -sudo apt install php ----- - -[source,bash] ----- -sudo apt install php-mysql php-mbstring php-intl php-imagick \ - php-redis php-apcu php-igbinary php-gmp php-bcmath \ - php-curl php-gd php-zip php-imap php-ldap php-bz2 \ - php-ssh2 php-phpseclib php-common php-json php-xml \ - php-dev libsmbclient-dev php-pear ----- - -Note that the `php-phpseclib` package is a {phpseclib-url}[pure PHP implementation] for handling various ciphers and not dependent to the php source. - -Use the following commands to install some common prerequisites: - -[source,bash] ----- -sudo apt install smbclient ----- - -[source,bash] ----- -sudo apt install redis-server ----- - -[source,bash] ----- -sudo apt install unzip ----- - -[source,bash] ----- -sudo apt install openssl ----- - -[source,bash] ----- -sudo apt install rsync ----- - -[source,bash] ----- -sudo apt install imagemagick ----- - -The following step is necessary to upgrade PEAR because of a change in PHP 7.4.1+ Note that you should always use the {pear-package_url}[latest stable PEAR release]. - -[source,bash] ----- -pear version ----- - -[source,bash] ----- -sudo mkdir -p /tmp/pear/cache ----- - -[source,bash] ----- -sudo pear upgrade --force \ - --alldeps http://pear.php.net/get/PEAR-1.10.13 ----- - -[source,bash] ----- -sudo pear clear-cache ----- - -[source,bash] ----- -sudo pear update-channels ----- - -[source,bash] ----- -sudo pear upgrade --force ----- - -[source,bash] ----- -sudo pear upgrade-all ----- - -[source,bash] ----- -pear version ----- - -If you get any notices containing `You should add "extension=...`, check if the extension is listed in `/etc/php/7.4/mods-available`. If it is not present, add the `.ini` file manually and xref:useful-commands-for-managing-php-extensions[enable it]. - -Post upgrading pear, you can safely remove the directory `/tmp/pear/cache`. - -Please see the xref:php-imagick-library[php-imagick Library] section for reason to install an updated version of ImageMagick. - -== Important Note on `smbclient` - -On Ubuntu 18.04, the default `smbclient` version was 4.7.6. With Ubuntu 20.04 the version provided is 4.11.6, the actual compilable version is 4.15.x. If you have successfully configured and connected `smbclient` under Ubuntu 18.04 to a Windows Server, you may now get issues connecting to older NAS systems. Some requirements are now stricter than before or have changed. - -If you needed to set `client max protocol = NT1` before in `smb.conf` to connect, with Samba 4.11+ you may get a response like `Max protocol NT1 is less than min protocol SMB2_02` which highlights a disabled former connectivity. Starting with Samba version 4.11, the NT1 protocol has been removed completely. - -To check if you are affected connecting to a particular file server, do tests with the Ubuntu provided version like: - -[source,bash] ----- -host -t SRV _ldap._tcp. ----- - -If you do not get SRV records printed, your dns settings may need a change. The first DNS server must be able to resolve your LDAP Active Directory request properly. If not, `smbclient` can not find a KDC to check credentials. - -[source,bash] ----- -sudo smbclient -L -U / ----- - -Any other output than a list of shares, like the error message - -[source,bash] ----- -tree connect failed: NT_STATUS_INVALID_PARAMETER ----- - -shows, that this target server is affected. This may impact your onwCloud installation when using SMB shares with that file server. - -The only solution is to compile a working Samba version yourself. -This xref:installation/manual_installation/compile_samba.adoc[Compact Samba Compiling Guide] -helps how to do that. - -== Apache Web Server - -The following command installs the Apache Web Server. - -[source,bash] ----- -sudo apt install libapache2-mod-php apache2 ----- - -See the important note on using the correct xref:installation/manual_installation/manual_installation_apache.adoc#multi-processing-module-mpm[Multi-Processing Module (MPM)]. - -Although it's not supported by ownCloud, you can configure Apache to use `php-fpm`, the FastCGI Process Manager, which is a non-standard setup and not covered by this document. - -== Multiple Concurrent PHP Versions - -If you have multiple concurrent PHP versions installed, which will happen when using the {ondrej-php-url}[ondrej/php] PPA, you must tell your Web Server and your CLI environment which one to use. Using the `ondrej/php` PPA may be needed if you want to test or prepare for the latest PHP version like PHP 8. Please note that `ondrej/php` installs _ALL_ versions of PHP. To list all available versions installed and choose one from them, use the following command: - -[source,bash] ----- -sudo update-alternatives --config php ----- - -Here is an example output: - -[source,plaintext] ----- -There are 2 choices for the alternative php (providing /usr/bin/php). - - Selection Path Priority Status ------------------------------------------------------------- -* 0 /usr/bin/php7.4 74 auto mode - 1 /usr/bin/php7.4 74 manual mode - 2 /usr/bin/php8.0 80 manual mode - -Press to keep the current choice[*], or type selection number: ----- - -You can also directly set the required PHP version: - -[source,bash] ----- -sudo update-alternatives --set php /usr/bin/php7.4 ----- - -WARNING: After selecting your PHP version, it is **highly** recommended to switch to the correct compiling environment which is essential e.g. when using PECL! - -[source,bash] ----- -sudo update-alternatives --set phar /usr/bin/phar7.4 ----- - -[source,bash] ----- -sudo update-alternatives --set phar.phar /usr/bin/phar.phar7.4 ----- - -[source,bash] ----- -sudo update-alternatives --set phpize /usr/bin/phpize7.4 ----- - -[source,bash] ----- -sudo update-alternatives --set php-config /usr/bin/php-config7.4 ----- - -When using Apache PHP-FPM, you have to configure your PHP version in an Apache config file manually. In any case, the PHP version used must always be the same. - -You can read more about `update-alternatives` command on the {update-alternatives_url}[man page]. - -WARNING: Please be advised, when switching a php version, you **MUST** also configure the corresponding php.ini files and extensions used accordingly! Extension binaries are **not** shared! - -WARNING: You may get completely unexpected behaviour or a broken environment if the PHP version for the Web Server and for CLI are different! - -=== Avoiding a Nasty Pitfall - -If you are using a PECL install later on, check the output of the installation command soon after it has started. You will find a text like: - -[source,plaintext] ----- -... -PHP Api Version: 20190902 -Zend Module Api No: 20190902 -... ----- - -Then do a test by just entering the following command: - -[source,bash] ----- -php -i | grep extension_dir ----- - -If the output is different than the style below, there is a problem that needs fixing: - -[source,plaintext] ----- -extension_dir => /usr/lib/php/20180731 => /usr/lib/php/20180731 ----- - -This is the output that shows a fix is needed: - -[source,plaintext] ----- -PHP Warning: PHP Startup: smbclient: Unable to initialize module -Module compiled with module API=20190902 -PHP compiled with module API=20180731 -These options need to match ----- - -As you see above, the API modules do not match and have been compiled with different versions and therefore will not work. To fix this, uninstall the PECL module with `pecl uninstall `, set the correct `update-alternatives` as described above and reinstall it. - -== libsmbclient-php Library - -`libsmbclient-php` is a PHP extension that uses Samba's libsmbclient library to provide Samba-related functions to PHP programs. You need to install it if you have installed `smbclient` as described above. `smbclient` is e.g. necessary if you are using the -xref:enterprise/external_storage/windows-network-drive_configuration.adoc[Windows Network Drives app] -from ownCloud's Enterprise Edition. To install it, run the commands described below. You can find more information about `smbclient` and the latest version on {pecl_url}[PECL]. - -[source,bash] ----- -sudo pecl channel-update pecl.php.net ----- - -[source,bash] ----- -sudo pecl install smbclient ----- - -When the commands complete, you then have to (assuming you use PHP 7.4): - -- Create `/etc/php/7.4/mods-available/smbclient.ini` with following content `extension=smbclient.so`. -- Enable the module by running `phpenmod smbclient`. -- Restart PHP and your web server by running the following command: -+ -[source,bash] ----- -sudo service apache2 restart ----- - -NOTE: Do not get confused by the name `smbclient`. It is on the one hand a {smbclient_url}[command-line SMB/CIFS client for Unix], and on the other hand the package name for the {pecl_url}[PECL smbclient] PHP extension - -NOTE: Alternatively you can install `smbclient` from {libsmbclient-php_url}[source]. - -== php-imagick Library - -When using new or extended formats for previews like HEIC or SVG, the standard installation of ImageMagick 6 and its php-imagick wrapper version 3.4 lacks this functionality. You have to manually install ImageMagick 7 and an updated php wrapper. To do so, follow the xref:installation/manual_installation/manual_imagick7.adoc[Install an Updated ImageMagick Version] guide. See the xref:configuration/files/previews_configuration.adoc[Previews Configuration] guide how to enable preview providers for various file types. - -== Useful Commands For Managing PHP Extensions - -=== List Enabled PHP Extensions - -If you want to retrieve a list of enabled PHP extensions run following command: - -[source,bash] ----- -ls `php -i | grep "^extension_dir" | sed -e 's/.*=> //'` | sort ----- - -=== Enabling and Disabling PHP Extensions - -To enable or disable a PHP extension for CLI, FPM or Apache, use the commands `phpenmod` or `phpdismod`. - -Example: -[source,bash] ----- -sudo phpenmod php-ldap ----- - -or - -[source,bash] ----- -sudo phpdismod php-ldap ----- - -Type the command without parameters or see this {php-common}[guide] to read more about the commands in the php-common package. - -== Notes for PHP Library phpseclib - -phpseclib's BigInteger uses the php-gmp (GNU Multiple Precision Arithmetic Library), php-bcmath and OpenSSL extensions, if they're available, for speed, but doesn't require them to maintain maximum compatibility. The GMP library uses an internal resource type, while the BCMath library uses strings as datatype. The most salient difference is that GMP works on _arbitrary precision integer values_ whereas BCMath allows _arbitrary precision] decimal / float-like values_. - -== Database Installation - -To install a database, see the -xref:installation/manual_installation/manual_installation_db.adoc[Manual Installation Databases guide]. - -NOTE: Follow the procedure described in xref:useful-tips[Useful Tips], if you want to `Disable Transparent Huge Pages (THP),Transparent Huge Pages` - -You may want to use the latest version of phpmyadmin as the OS default versions lags behind the {phpmyadmin_latest_url}[latest available stable] version a lot and may report PHP errors with PHP 7.4. Follow this -xref:installation/manual_installation/upgrade_install_phpmyadmin.adoc[quick upgrade guide] to install it. - -== Useful Tips - -include::partial$installation/manual_installation/useful_tips.adoc[leveloffset=+1] diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/server_prep_ubuntu_22.04.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/server_prep_ubuntu_22.04.adoc deleted file mode 100644 index a24dbc8..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/server_prep_ubuntu_22.04.adoc +++ /dev/null @@ -1,385 +0,0 @@ -= Server Preparation for Ubuntu 22.04 -:toc: right -:toclevels: 1 -:page-partial: -:ubuntu_upgrade_url: https://linuxconfig.org/how-to-upgrade-ubuntu-to-22-04-lts-jammy-jellyfish -:php-common: https://tecadmin.net/enable-disable-php-modules-ubuntu/ -:ondrej-php-url: https://launchpad.net/~ondrej/+archive/ubuntu/php -:libsmbclient-php_url: https://github.com/eduardok/libsmbclient-php -:update-alternatives_url: https://manpages.ubuntu.com/manpages/focal/en/man1/update-alternatives.1.html -:phpmyadmin_latest_url: https://www.phpmyadmin.net/downloads/ -:pear-package_url: https://pear.php.net/package/PEAR/ -:phpseclib-url: https://phpseclib.com/docs/why - -:description: This guide gives you detailed information on preparing your Ubuntu 22.04 server for the use with ownCloud. - -== Introduction - -{description} - -The target audience for this document are experienced admins with additional needs and setup scenarios. Ubuntu 22.04 by default only provides PHP 8.1. However, PHP versions 8.0 and 8.1 are currently not supported, therefore this guide describes how to install PHP version 7.4 on Ubuntu 22.04 by the means of the {ondrej-php-url}[ondrej/php] PPA. For more information, see {php-supported-versions-url}[Currently Supported PHP Versions]. This document considers two basic scenarios. You plan to upgrade from 20.04 LTS to 22.04 LTS or you have a fresh Ubuntu 22.04 LTS installation. - -IMPORTANT: PHP 8.x is currently **not** supported by ownCloud server. - -IMPORTANT: Read the xref:installation/manual_installation/manual_installation_prerequisites.adoc#openssl-version[openSSL Version] notes which are important when planning to use encryption. - -NOTE: The commands and links provided in this description should give you proper hints but we cannot take any responsibility. - -== Upgrading from Ubuntu 20.04 to 22.04 - -Without going into the upgrade details, you can now upgrade directly from Ubuntu 20.04 LTS to 22.04 LTS when using the do-release-upgrade command. For more details see an example description at {ubuntu_upgrade_url}[Upgrade Ubuntu 20.04 to 22.04 LTS using command line] - -[source,bash] ----- -sudo apt update ----- - -[source,bash] ----- -sudo apt upgrade ----- - -[source,bash] ----- -sudo apt dist-upgrade ----- - -[source,bash] ----- -sudo apt autoremove - ----- -[source,bash] ----- -sudo apt install update-manager-core ----- - -[source,bash] ----- -sudo do-release-upgrade ----- - -If you have upgraded successfully and had previously installed any versions of PHP, better uninstall all PHP versions and ALL extensions and perform a fresh PHP 7.4 native installation. To do so, stop any services which depend on or use PHP like your Web Server. Then get a list of all PHP related programs and extensions by typing: - -[source,bash] ----- -dpkg -l | grep php | awk '{print $2}' | tr "\n" " " ----- - -Disable all extensions listed (see the section -xref:useful-commands-for-managing-php-extensions[Useful Commands For Managing PHP Extensions]). - -Then purge them step by step: - -[source,bash] ----- -sudo apt purge ----- - -Alternatively, if you are fine removing all packages listed, you can run: - -[source,bash] ----- -sudo apt purge `dpkg -l | grep php | awk '{print $2}' | tr "\n" " "` ----- - -NOTE: Keep a copy of your relevant `php.ini` and other configuration files as reference _before_ you start purging, to quickly reconfigure your PHP 7.4 installation afterwards. - -After deinstallation of all versions and extensions of PHP and cleaning up all remnants, you should have an empty `/etc/php` directory. You can proceed like on a fresh installation of Ubuntu 22.04 LTS. - -== Clean Ubuntu 22.04 Installation - -After you have installed your Ubuntu 22.04 LTS server from scratch, use the following commands to first add the {ondrej-php-url}[ondrej/php] PPA and then install PHP 7.4 and all necessary extensions: - -[source,bash] ----- -sudo add-apt-repository ppa:ondrej/php -y ----- - -[source,bash] ----- -sudo apt update && sudo apt upgrade ----- - -[source,bash] ----- -sudo apt install php7.4 php7.4-intl php7.4-mysql php7.4-mbstring \ - php7.4-imagick php7.4-igbinary php7.4-gmp php7.4-bcmath \ - php7.4-curl php7.4-gd php7.4-zip php7.4-imap php7.4-ldap \ - php7.4-bz2 php7.4-ssh2 php7.4-common php7.4-json \ - php7.4-xml php7.4-dev php7.4-apcu php7.4-redis \ - libsmbclient-dev php-pear php-phpseclib ----- - -Note that the `php-phpseclib` package is a {phpseclib-url}[pure PHP implementation] for handling various ciphers and not dependent to the php source. - -Use the following commands to install some common prerequisites: - -[source,bash] ----- -sudo apt install smbclient ----- - -[source,bash] ----- -sudo apt install redis-server ----- - -[source,bash] ----- -sudo apt install unzip ----- - -[source,bash] ----- -sudo apt install openssl ----- - -[source,bash] ----- -sudo apt install rsync ----- - -[source,bash] ----- -sudo apt install imagemagick ----- - -== Multiple Concurrent PHP Versions - -If you have multiple concurrent PHP versions installed, which will happen when using the {ondrej-php-url}[ondrej/php] PPA, you must tell your Web Server and your CLI environment which one to use. Please note that `ondrej/php` installs _ALL_ versions of PHP. To list all available versions installed and choose one of them, use the following command: - -[source,bash] ----- -sudo update-alternatives --config php ----- - -Here is an example output: - -[source,plaintext] ----- -There are 2 choices for the alternative php (providing /usr/bin/php). - - Selection Path Priority Status ------------------------------------------------------------- -* 0 /usr/bin/php7.4 74 auto mode - 1 /usr/bin/php7.4 74 manual mode - 2 /usr/bin/php8.0 80 manual mode - -Press to keep the current choice[*], or type selection number: ----- - -You can also directly set the required PHP version: - -[source,bash] ----- -sudo update-alternatives --set php /usr/bin/php7.4 ----- - -WARNING: After selecting your PHP version, it is **highly** recommended to switch to the correct compiling environment which is essential e.g. when using PECL! - -[source,bash] ----- -sudo update-alternatives --set phar /usr/bin/phar7.4 ----- - -[source,bash] ----- -sudo update-alternatives --set phar.phar /usr/bin/phar.phar7.4 ----- - -[source,bash] ----- -sudo update-alternatives --set phpize /usr/bin/phpize7.4 ----- - -[source,bash] ----- -sudo update-alternatives --set php-config /usr/bin/php-config7.4 ----- - -When using Apache PHP-FPM, you have to configure your PHP version in an Apache config file manually. In any case, the PHP version used must always be the same. - -You can read more about the `update-alternatives` command in the {update-alternatives_url}[man page]. - -WARNING: When switching a PHP version, you **MUST** also configure the corresponding php.ini files and extensions accordingly! Extension binaries are **not** shared! - -WARNING: You may get completely unexpected behaviour or a broken environment if the PHP version for the Web Server and for CLI are different! - -=== Avoiding a Nasty Pitfall - -If you are using a PECL install later on, check the output of the installation command soon after it has started. You will find a text like: - -[source,plaintext] ----- -... -PHP Api Version: 20190902 -Zend Module Api No: 20190902 -... ----- - -Then do a test by just entering the following command: - -[source,bash] ----- -php -i | grep extension_dir ----- - -If the output is different than the style below, there is a problem that needs fixing: - -[source,plaintext] ----- -extension_dir => /usr/lib/php/20180731 => /usr/lib/php/20180731 ----- - -This is the output that shows a fix is needed: - -[source,plaintext] ----- -PHP Warning: PHP Startup: smbclient: Unable to initialize module -Module compiled with module API=20190902 -PHP compiled with module API=20180731 -These options need to match ----- - -As you see above, the API modules do not match and have been compiled with different versions and therefore will not work. To fix this, uninstall the PECL module with `pecl uninstall `, set the correct `update-alternatives` as described above and reinstall it. - -== Updating pear - -The following step is necessary to upgrade PEAR because of a change in PHP 7.4.1+ Note that you should always use the {pear-package_url}[latest stable PEAR release]. - -[source,bash] ----- -pear version ----- - -[source,bash] ----- -sudo mkdir -p /tmp/pear/cache ----- - -[source,bash] ----- -sudo pear upgrade --force \ - --alldeps http://pear.php.net/get/PEAR-1.10.13 ----- - -[source,bash] ----- -sudo pear clear-cache ----- - -[source,bash] ----- -sudo pear update-channels ----- - -[source,bash] ----- -sudo pear upgrade --force ----- - -[source,bash] ----- -sudo pear upgrade-all ----- - -[source,bash] ----- -pear version ----- - -If you get any notices containing `You should add "extension=...`, check if the extension is listed in `/etc/php/7.4/mods-available`. If it is not present, add the `.ini` file manually and xref:useful-commands-for-managing-php-extensions[enable it]. - -Post upgrading pear, you can safely remove the directory `/tmp/pear/cache`. - -See the xref:php-imagick-library[php-imagick Library] section if you are interested why an updated version of ImageMagick is necessary. - -== Apache Web Server - -The following command installs the Apache Web Server. - -[source,bash] ----- -sudo apt install libapache2-mod-php7.4 apache2 ----- - -See the important note on using the correct xref:installation/manual_installation/manual_installation_apache.adoc#multi-processing-module-mpm[Multi-Processing Module (MPM)]. - -Although it's not supported by ownCloud, you can configure Apache to use `php-fpm`, the FastCGI Process Manager, which is a non-standard setup and not covered by this document. - -== libsmbclient-php Library - -`libsmbclient-php` is a PHP extension that uses Samba's libsmbclient library to provide Samba-related functions to PHP programs. You need to install it if you have installed `smbclient` as described above. `smbclient` is e.g. necessary if you are using the -xref:enterprise/external_storage/windows-network-drive_configuration.adoc[Windows Network Drives app] -from ownCloud's Enterprise Edition. To install it, run the following command: - -[source,bash] ----- -sudo apt install php7.4-smbclient ----- - -When the command completes, perform the following tasks: - -- Create `/etc/php/7.4/mods-available/smbclient.ini` with the following content: `extension=smbclient.so`. -- Enable the module by running `phpenmod smbclient`. -- Restart PHP and your web server by running the following command: -+ -[source,bash] ----- -sudo service apache2 restart ----- - -NOTE: Alternatively you can install `smbclient` from {libsmbclient-php_url}[source]. - -== php-imagick Library - -When using new or extended formats for previews like HEIC or SVG, the standard installation of ImageMagick 6 lacks this functionality. You have to manually install ImageMagick 7 (while the php wrapper version should be 3.7.0, which is fine, when following the install instructions above). To do so, follow the xref:installation/manual_installation/manual_imagick7.adoc[Install an Updated ImageMagick Version] guide. See the xref:configuration/files/previews_configuration.adoc[Previews Configuration] guide how to enable preview providers for various file types. - -== Useful Commands For Managing PHP Extensions - -=== List Enabled PHP Extensions - -If you want to retrieve a list of enabled PHP extensions run the following command: - -[source,bash] ----- -ls `php -i | grep "^extension_dir" | sed -e 's/.*=> //'` | sort ----- - -=== Enabling and Disabling PHP Extensions - -To enable or disable a PHP extension for CLI, FPM or Apache, use the commands `phpenmod` or `phpdismod`. - -Example: -[source,bash] ----- -sudo phpenmod php-ldap ----- - -or - -[source,bash] ----- -sudo phpdismod php-ldap ----- - -Type the command without parameters or see this {php-common}[guide] to read more about the commands in the php-common package. - -== Notes for PHP Library phpseclib - -phpseclib's BigInteger uses the php-gmp (GNU Multiple Precision Arithmetic Library), php-bcmath and OpenSSL extensions, if they're available, for speed, but doesn't require them to maintain maximum compatibility. The GMP library uses an internal resource type, while the BCMath library uses strings as datatype. The most salient difference is that GMP works on _arbitrary precision integer values_ whereas BCMath allows _arbitrary precision] decimal / float-like values_. - -== Database Installation - -To install a database, see the -xref:installation/manual_installation/manual_installation_db.adoc[Manual Installation Databases] guide. - -NOTE: Follow the procedure described in xref:useful-tips[Useful Tips] if you want to `Disable Transparent Huge Pages (THP),Transparent Huge Pages`. - -You may want to use the latest version of phpmyadmin as the OS default versions lags behind the {phpmyadmin_latest_url}[latest available stable] version a lot and may report PHP errors with PHP 7.4. Follow this -xref:installation/manual_installation/upgrade_install_phpmyadmin.adoc[quick upgrade guide] to install it. - -== Useful Tips - -include::partial$installation/manual_installation/useful_tips.adoc[leveloffset=+1] diff --git a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/upgrade_install_phpmyadmin.adoc b/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/upgrade_install_phpmyadmin.adoc deleted file mode 100644 index 1d06a5b..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/manual_installation/upgrade_install_phpmyadmin.adoc +++ /dev/null @@ -1,185 +0,0 @@ -= Upgrade phpmyadmin -:toc: right -:toclevels: 2 -:phpmyadmin_home_url: https://www.phpmyadmin.net -:phpmyadmin_dl_url: https://www.phpmyadmin.net/downloads/ - -:description: This guide helps you to upgrade an existing and configured installation of {phpmyadmin_home_url}[phpmyadmin] from source. - -== Introduction - -{description} This may be necessary if the provided version of your OS lags behind the available version and/or you see PHP errors when using it and you need an updated version. - -NOTE: `phpmyadmin` gets rarely updated as an Ubuntu package - usually only with Ubuntu LTS upgrades. If you have manually upgraded the installation but Ubuntu _downgrades_ your local version because of updating the package, just redo the procedure described below. - -NOTE: The guide has been tested but comes as it is without any warranty. - -== Prerequisites - -NOTE: You must already have an _existing_, _configured_ and _working_ `phpmyadmin` installation. - -If you have installed `phpmyadmin` with the packagemanager, check your existing version with the following command: - -[source,bash] ----- -sudo apt-cache policy phpmyadmin ----- - -When using `phpmyadmin`, post login, look at the bottom right side to see the actual version running. - -image::installation/manual_installation/phpmyadmin_v4.9.5deb2.png[width=300] - -You will find the binaries of your installation in the directory: `/usr/share/phpmyadmin`. - -== Upgrade Methods - -=== PPA Upgrade - -// see: https://github.com/phpmyadmin/phpmyadmin/wiki/DebianUbuntu - -You can upgrade `phpmyadmin` most easily to a later, but also most likely not to the latest, version when adding a PPA provided by the phpmyadmin team. To do so, type the following commands: - -[source,bash] ----- -sudo add-apt-repository ppa:phpmyadmin/ppa ----- - -[source,bash] ----- -sudo apt update ----- - -[source,bash] ----- -sudo apt install phpmyadmin ----- - -Note: if you do not want to continue with the PPA solution, just remove it by invoking the following command. This will keep your existing phpmyadmin installation, but will not update it anymore: - -[source,bash] ----- -sudo add-apt-repository --remove ppa:phpmyadmin/ppa ----- - -=== Manual Upgrade - -To download `phpmyadmin`, see the {phpmyadmin_dl_url}[phpmyadmin download page] and select the latest stable version or a version that fits your needs. Then start downloading, extracting and putting the files to the correct location. - -==== Download and Move - -The following example uses `phpMyAdmin-5.2.0-all-languages` as the example for upgrading. The old installation location will be renamed, because we need to keep some basic configuration settings. - -[source,bash] ----- -cd /tmp ----- - -[source,bash] ----- -sudo wget https://files.phpmyadmin.net/phpMyAdmin/5.2.0/phpMyAdmin-5.2.0-all-languages.tar.gz ----- - -[source,bash] ----- -sudo tar -xvf phpMyAdmin-5.2.0-all-languages.tar.gz ----- - -[source,bash] ----- -sudo mv /usr/share/phpmyadmin /usr/share/phpmyadmin.old ----- - -[source,bash] ----- -sudo mkdir -p /usr/share/phpmyadmin ----- - -[source,bash] ----- -sudo cp -r phpMyAdmin-5.2.0-all-languages/. \ - /usr/share/phpmyadmin ----- - -[source,bash] ----- -sudo rm -r phpMyAdmin-5.2.0-all-languages* ----- - -==== Recreate Basic Configuration Settings - -Because the upgrade has some default basic configuration settings, it is necessary to recreate them based on the former settings coming from the Ubuntu installation. The file to change can be found in `/usr/share/phpmyadmin/libraries/vendor_config.php`. + -To keep a copy of the original file from the download, create a backup with: - -[source,bash] ----- -sudo cp /usr/share/phpmyadmin/libraries/vendor_config.php \ - /usr/share/phpmyadmin/libraries/vendor_config.php.orig ----- - -NOTE: The transformation of values may differ depending on the phpmyadmin version compared. Especially starting with version 5.2.0, the definitions have changed from constants to array. In addition, keys have the same name but different casing and the definition of `CONFIG_DIR`, which defines the path to the configuration files, has been removed completely and needs to be set manually. - -As rule of thumb, create a copy of the line that will be changed and make it a remark by adding `#` in front to keep a safe copy. - -Open two editors of your choice in parallel with the following files: - -(1) - `/usr/share/phpmyadmin/libraries/vendor_config.php` + -(2) - `/usr/share/phpmyadmin.old/libraries/vendor_config.php` - -and transfer the values coming from (2) to (1) as described below, check the path values and make sure they fit your environment: - -TEMP_DIR or tempDir:: -+ -[source,plaintext] ----- -'tempDir' => '/var/lib/phpmyadmin/tmp/', ----- -+ -or -+ -[source,plaintext] ----- -define('TEMP_DIR', '/var/lib/phpmyadmin/tmp/'); ----- - -CONFIG_DIR:: -Only if `define('CONFIG_DIR'...` exists, -+ -[source,plaintext] ----- -define('CONFIG_DIR', '/etc/phpmyadmin/'); ----- - -configFile:: -+ -[source,plaintext] ----- -'configFile' => '/etc/phpmyadmin/' . 'config.inc.php', ----- - -customHeaderFile:: -+ -[source,plaintext] ----- -'customHeaderFile' => '/etc/phpmyadmin/' . 'config.header.inc.php', ----- - -customFooterFile:: -+ -[source,plaintext] ----- -'customFooterFile' => '/etc/phpmyadmin/' . 'config.footer.inc.php', ----- - -== Testing - -When the upgrade has finished, test it by logging in and checking the actual version -displayed at the bottom right of the screen. - -image::installation/manual_installation/phpmyadmin_v5.2.0.png[width=300] - -When you are fine with your upgrade, you can safely delete the old installation files with: - -[source,bash] ----- -sudo rm -r /usr/share/phpmyadmin.old ----- diff --git a/content/server/10.15/modules/admin_manual/pages/installation/quick_guides/ubuntu_20_04.adoc b/content/server/10.15/modules/admin_manual/pages/installation/quick_guides/ubuntu_20_04.adoc deleted file mode 100644 index 3510c79..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/quick_guides/ubuntu_20_04.adoc +++ /dev/null @@ -1,323 +0,0 @@ -= Install ownCloud on Ubuntu 20.04 -:toc: right -:page-aliases: installation/quick_guides/ubuntu_18_04.adoc - -== Introduction - -This is a short guide to installing ownCloud on a fresh installation of Ubuntu 20.04. Run the following commands in your terminal to complete the installation. - -This guide can not go into details and has its limits by nature. If you experience issues like with dependencies of PHP or other relevant things like the operating system, web server or database, look at the xref:installation/manual_installation/manual_installation.adoc#ubuntu-20-04-lts-server[Detailed Installation Guide] for more information. - -== Prerequisites and Notes - -* A fresh installation of https://www.ubuntu.com/download/server[Ubuntu 20.04] with SSH enabled. -* This guide assumes that you are working as the root user. -* Your ownCloud directory will be located in `/var/www/owncloud/`. -* php 7.4 is the default version installable with Ubuntu 20.04. -* Use the correct xref:installation/manual_installation/manual_installation_apache.adoc#multi-processing-module-mpm[Multi-Processing Module (MPM)]. -* Read the xref:installation/manual_installation/manual_installation_prerequisites.adoc#openssl-version[openSSL Version] notes which are important when planning to use encryption. - -== Preparation - -=== Set Your Domain Name - -[source,bash] ----- -my_domain="Your.Domain.tld" -echo $my_domain - -hostnamectl set-hostname $my_domain -hostname -f ----- - -=== Update Your System - -First, ensure that all the installed packages are entirely up to date and that PHP is available in the APT repository. -To do so, follow the instructions below: - -[source,bash] ----- -apt update && \ - apt upgrade -y ----- - -=== Create the occ Helper Script - -Create a helper script to simplify running xref:configuration/server/occ_command.adoc[occ commands]: - -[source,bash] ----- -FILE="/usr/local/bin/occ" -cat <$FILE -#! /bin/bash -cd /var/www/owncloud -sudo -E -u www-data /usr/bin/php /var/www/owncloud/occ "\$@" -EOM ----- - -Make the helper script executable: - -[source,bash] ----- -chmod +x $FILE ----- - -=== Install the Required Packages - -[source,bash] ----- -apt install -y \ - apache2 libapache2-mod-php \ - mariadb-server openssl redis-server wget php-imagick \ - php-common php-curl php-gd php-gmp php-bcmath php-imap \ - php-intl php-json php-mbstring php-mysql php-ssh2 php-xml \ - php-zip php-apcu php-redis php-ldap php-phpseclib ----- - -=== Install smbclient php Module - -If you want to connect to external storage via SMB you need to install the smbclient php module. - -First install the required packages: - -[source,bash] ----- -apt-get install -y libsmbclient-dev php-dev php-pear ----- - -Then install smblclient php module using pecl: - -[source,bash] ----- -pecl channel-update pecl.php.net -mkdir -p /tmp/pear/cache -pecl install smbclient-stable -echo "extension=smbclient.so" > /etc/php/7.4/mods-available/smbclient.ini -phpenmod smbclient -systemctl restart apache2 ----- - -Check if it was successfully activated: - -[source,bash] ----- -php -m | grep smbclient ----- - -This should show the following output: - -[source,plaintext] ----- -libsmbclient -smbclient ----- - -=== Install the Recommended Packages - -Additional useful tools helpful for debugging: - -[source,bash] ----- -apt install -y \ - unzip bzip2 rsync curl jq \ - inetutils-ping ldap-utils\ - smbclient ----- - -=== Configure Apache - -==== Create a Virtual Host Configuration - -[source,apache] ----- -FILE="/etc/apache2/sites-available/owncloud.conf" -cat <$FILE - -# uncommment the line below if variable was set -#ServerName $my_domain -DirectoryIndex index.php index.html -DocumentRoot /var/www/owncloud - - Options +FollowSymlinks -Indexes - AllowOverride All - Require all granted - - - Dav off - - - SetEnv HOME /var/www/owncloud - SetEnv HTTP_HOME /var/www/owncloud - - -EOM ----- - -==== Enable the Virtual Host Configuration - -[source,bash] ----- -a2dissite 000-default -a2ensite owncloud.conf ----- - -=== Configure the Database - -IMPORTANT: It's recommended to execute `mysql_secure_installation` to secure the mariadb installation and set a strong password for the database user. - -Ensure transaction-isolation level is set and performance_schema on. - -[source,bash] ----- -sed -i "/\[mysqld\]/atransaction-isolation = READ-COMMITTED\nperformance_schema = on" /etc/mysql/mariadb.conf.d/50-server.cnf -systemctl start mariadb -mysql -u root -e \ - "CREATE DATABASE IF NOT EXISTS owncloud; \ - CREATE USER IF NOT EXISTS 'owncloud'@'localhost' IDENTIFIED BY 'password'; \ - GRANT ALL PRIVILEGES ON *.* TO 'owncloud'@'localhost' WITH GRANT OPTION; \ - FLUSH PRIVILEGES;" ----- - -It is recommended to run mysqltuner script to analyse database configuration after running with load for several days. - -Once the database installation is complete, refer to the Database section in the xref:configuration/server/harden_server.adoc#database[Hardening and Security Guidance] guide for additional important information. - -==== Enable the Recommended Apache Modules - -[source,bash] ----- -a2enmod dir env headers mime rewrite setenvif -systemctl restart apache2 ----- - -== Installation - -=== Download ownCloud - -[source,bash,subs="attributes+"] ----- -cd /var/www/ -wget {oc-complete-base-url}/{oc-complete-name}.tar.bz2 && \ -tar -xjf {oc-complete-name}.tar.bz2 && \ -chown -R www-data. owncloud ----- - -=== Install ownCloud - -IMPORTANT: We recommend to set a strong password for your owncloud admin user and the database user. - -[source,bash] ----- -occ maintenance:install \ - --database "mysql" \ - --database-name "owncloud" \ - --database-user "owncloud" \ - --database-pass "password" \ - --data-dir "/var/www/owncloud/data" \ - --admin-user "admin" \ - --admin-pass "admin" ----- - -=== Configure ownCloud's Trusted Domains - -[source,bash] ----- -my_ip=$(hostname -I|cut -f1 -d ' ') -occ config:system:set trusted_domains 1 --value="$my_ip" -occ config:system:set trusted_domains 2 --value="$my_domain" ----- - -=== Configure the cron Jobs - -Set your background job mode to cron: - -[source,bash] ----- -occ background:cron ----- - -Configure the execution of the cron job to every 15 min and the cleanup of chunks every night at 2 am: - -[source,bash] ----- -echo "*/15 * * * * /var/www/owncloud/occ system:cron" \ - | sudo -u www-data -g crontab tee -a \ - /var/spool/cron/crontabs/www-data -echo "0 2 * * * /var/www/owncloud/occ dav:cleanup-chunks" \ - | sudo -u www-data -g crontab tee -a \ - /var/spool/cron/crontabs/www-data ----- - -[NOTE] -==== -If you need to sync your users from an LDAP or Active Directory Server, add this additional xref:configuration/server/background_jobs_configuration.adoc[Cron job]. Every 4 hours this cron job will sync LDAP users in ownCloud and disable the ones who are not available for ownCloud. Additionally, you get a log file in `/var/log/ldap-sync/user-sync.log` for debugging. -==== - -[source,bash] ----- -echo "1 */6 * * * /var/www/owncloud/occ user:sync \ - 'OCA\User_LDAP\User_Proxy' -m disable -vvv >> \ - /var/log/ldap-sync/user-sync.log 2>&1" \ - | sudo -u www-data -g crontab tee -a \ - /var/spool/cron/crontabs/www-data -mkdir -p /var/log/ldap-sync -touch /var/log/ldap-sync/user-sync.log -chown www-data. /var/log/ldap-sync/user-sync.log ----- - -=== Configure Caching and File Locking - -[source,bash,subs="attributes+"] ----- -occ config:system:set \ - memcache.local \ - --value '\OC\Memcache\APCu' -occ config:system:set \ - memcache.locking \ - --value '\OC\Memcache\Redis' -occ config:system:set \ - redis \ - --value '{"host": "{oc-examples-server-ip}", "port": "{std-port-redis}"}' \ - --type json ----- - -=== Configure Log Rotation - -[source,bash] ----- -FILE="/etc/logrotate.d/owncloud" -sudo cat <$FILE -/var/www/owncloud/data/owncloud.log { - size 10M - rotate 12 - copytruncate - missingok - compress - compresscmd /bin/gzip -} -EOM ----- - -==== Finalize the Installation - -Make sure the permissions are correct: - -[source,bash] ----- -cd /var/www/ -chown -R www-data. owncloud ----- - -**ownCloud is now installed. You can confirm that it is ready to enable HTTPS xref:installation/letsencrypt/using_letsencrypt.adoc[(for example using Let's Encrypt)] by pointing your web browser to your ownCloud installation.** - -To check if you have installed the correct version of ownCloud and that the occ command is working, execute the following: - -[source,bash] ----- -occ -V -echo "Your ownCloud is accessable under: "$my_ip -echo "Your ownCloud is accessable under: "$my_domain -echo "The Installation is complete." ----- - -IMPORTANT: We recommend you check out the section xref:configuration/server/harden_server.adoc[Hardening and Security Guidance] next. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/quick_guides/ubuntu_22_04.adoc b/content/server/10.15/modules/admin_manual/pages/installation/quick_guides/ubuntu_22_04.adoc deleted file mode 100644 index 7179bab..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/quick_guides/ubuntu_22_04.adoc +++ /dev/null @@ -1,341 +0,0 @@ -= Install ownCloud on Ubuntu 22.04 -:toc: right - -== Introduction - -This is a short guide to installing ownCloud on a fresh installation of Ubuntu 22.04. Run the following commands in your terminal to complete the installation. - -This guide can not go into details and has its limits by nature. If you experience issues like with dependencies of PHP or other relevant things like the operating system, web server or database, look at the xref:installation/manual_installation/manual_installation.adoc#ubuntu-22-04-lts-server[Detailed Installation Guide] for more information. - -== Prerequisites and Notes - -* A fresh installation of https://www.ubuntu.com/download/server[Ubuntu 22.04] with SSH enabled. -* This guide assumes that you are working as the root user. -* Your ownCloud directory will be located in `/var/www/owncloud/`. -* php 7.4 from the ondrej/php PPA is going to be installed on Ubuntu 22.04. -* Use the correct xref:installation/manual_installation/manual_installation_apache.adoc#multi-processing-module-mpm[Multi-Processing Module (MPM)]. -* Read the xref:installation/manual_installation/manual_installation_prerequisites.adoc#openssl-version[openSSL Version] notes which are important when planning to use encryption. - -== Preparation - -=== Set Your Domain Name - -[source,bash] ----- -my_domain="Your.Domain.tld" -echo $my_domain - -hostnamectl set-hostname $my_domain -hostname -f ----- - -=== Update Your System - -First, ensure that all the installed packages are entirely up to date and that PHP is available in the APT repository. -To do so, follow the instructions below: - -[source,bash] ----- -apt update && \ - apt upgrade -y ----- - -=== Create the occ Helper Script - -Create a helper script to simplify running xref:configuration/server/occ_command.adoc[occ commands]: - -[source,bash] ----- -FILE="/usr/local/bin/occ" -cat <$FILE -#! /bin/bash -cd /var/www/owncloud -sudo -E -u www-data /usr/bin/php /var/www/owncloud/occ "\$@" -EOM ----- - -Make the helper script executable: - -[source,bash] ----- -chmod +x $FILE ----- - -=== Install the Required Packages - -[source,bash] ----- -sudo add-apt-repository ppa:ondrej/php -y -sudo apt update && sudo apt upgrade - -apt install -y \ - apache2 \ - libapache2-mod-php7.4 \ - mariadb-server openssl redis-server wget \ - php7.4 php7.4-imagick php7.4-common php7.4-curl \ - php7.4-gd php7.4-imap php7.4-intl php7.4-json \ - php7.4-mbstring php7.4-gmp php7.4-bcmath php7.4-mysql \ - php7.4-ssh2 php7.4-xml php7.4-zip php7.4-apcu \ - php7.4-redis php7.4-ldap php-phpseclib ----- - -=== Install smbclient php Module - -If you want to connect to external storage via SMB you need to install the smbclient php module. - -[source,bash] ----- -apt-get install -y php7.4-smbclient -echo "extension=smbclient.so" > /etc/php/7.4/mods-available/smbclient.ini -phpenmod smbclient -systemctl restart apache2 ----- - -Check if it was successfully activated: - -[source,bash] ----- -php -m | grep smbclient ----- - -This should show the following output: - -[source,plaintext] ----- -libsmbclient -smbclient ----- - -=== Install the Recommended Packages - -Additional useful tools helpful for debugging: - -[source,bash] ----- -apt install -y \ - unzip bzip2 rsync curl jq \ - inetutils-ping ldap-utils\ - smbclient ----- - -=== Configure Apache - -==== Create a Virtual Host Configuration - -[source,apache] ----- -FILE="/etc/apache2/sites-available/owncloud.conf" -cat <$FILE - -# uncommment the line below if variable was set -#ServerName \$my_domain -DirectoryIndex index.php index.html -DocumentRoot /var/www/owncloud - - Options +FollowSymlinks -Indexes - AllowOverride All - Require all granted - - - Dav off - - - SetEnv HOME /var/www/owncloud - SetEnv HTTP_HOME /var/www/owncloud - - -EOM ----- - -==== Test the Configuration - -[source,bash] ----- -apachectl -t ----- - -At this point, the following output is expected: - -[source,bash] ----- -apachectl -t -AH00112: Warning: DocumentRoot [/var/www/owncloud] does not exist -AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1. Set the 'ServerName' directive globally to suppress this message -Syntax OK ----- - -The first warning will be resolved after ownCloud is installed. The second message can be resolved with following command. Check that the entry is only present once in the `apache2.conf` file: - -[source,bash] ----- -echo "ServerName $my_domain" >> /etc/apache2/apache2.conf ----- - -==== Enable the Virtual Host Configuration - -[source,bash] ----- -a2dissite 000-default -a2ensite owncloud.conf ----- - -=== Configure the Database - -IMPORTANT: It's recommended to execute `mysql_secure_installation` to secure the mariadb installation and set a strong password for the database user. - -Ensure transaction-isolation level is set and performance_schema on. - -[source,bash] ----- -sed -i "/\[mysqld\]/atransaction-isolation = READ-COMMITTED\nperformance_schema = on" /etc/mysql/mariadb.conf.d/50-server.cnf -systemctl start mariadb -mysql -u root -e \ - "CREATE DATABASE IF NOT EXISTS owncloud; \ - CREATE USER IF NOT EXISTS 'owncloud'@'localhost' IDENTIFIED BY 'password'; \ - GRANT ALL PRIVILEGES ON *.* TO 'owncloud'@'localhost' WITH GRANT OPTION; \ - FLUSH PRIVILEGES;" ----- - -It is recommended to run the mysqltuner script to analyze the database configuration after running with load for several days. - -Once the database installation is complete, refer to the Database section in the xref:configuration/server/harden_server.adoc#database[Hardening and Security Guidance] guide for additional important information. - -==== Enable the Recommended Apache Modules - -[source,bash] ----- -a2enmod dir env headers mime rewrite setenvif -systemctl restart apache2 ----- - -== Installation - -=== Download ownCloud - -[source,bash,subs="attributes+"] ----- -cd /var/www/ -wget {oc-complete-base-url}/{oc-complete-name}.tar.bz2 && \ -tar -xjf {oc-complete-name}.tar.bz2 && \ -chown -R www-data. owncloud ----- - -=== Install ownCloud - -IMPORTANT: We recommend to set a strong password for your owncloud admin user and the database user. - -[source,bash] ----- -occ maintenance:install \ - --database "mysql" \ - --database-name "owncloud" \ - --database-user "owncloud" \ - --database-pass "password" \ - --data-dir "/var/www/owncloud/data" \ - --admin-user "admin" \ - --admin-pass "admin" ----- - -=== Configure ownCloud's Trusted Domains - -[source,bash] ----- -my_ip=$(hostname -I|cut -f1 -d ' ') -occ config:system:set trusted_domains 1 --value="$my_ip" -occ config:system:set trusted_domains 2 --value="$my_domain" ----- - -=== Configure the cron Jobs - -Set your background job mode to cron: - -[source,bash] ----- -occ background:cron ----- - -Set the execution of the cron job to every 15 minutes and the cleanup of chunks every night at 2 am: - -[source,bash] ----- -echo "*/15 * * * * /var/www/owncloud/occ system:cron" \ - | sudo -u www-data -g crontab tee -a \ - /var/spool/cron/crontabs/www-data -echo "0 2 * * * /var/www/owncloud/occ dav:cleanup-chunks" \ - | sudo -u www-data -g crontab tee -a \ - /var/spool/cron/crontabs/www-data ----- - -[NOTE] -==== -If you need to sync your users from an LDAP or Active Directory Server, add this additional xref:configuration/server/background_jobs_configuration.adoc[cron job]. Every 6 hours this cron job will sync LDAP users in ownCloud and disable the ones who are not available for ownCloud. Additionally, you get a log file in `/var/log/ldap-sync/user-sync.log` for debugging. -==== - -[source,bash] ----- -echo "1 */6 * * * /var/www/owncloud/occ user:sync \ - 'OCA\User_LDAP\User_Proxy' -m disable -vvv >> \ - /var/log/ldap-sync/user-sync.log 2>&1" \ - | sudo -u www-data -g crontab tee -a \ - /var/spool/cron/crontabs/www-data -mkdir -p /var/log/ldap-sync -touch /var/log/ldap-sync/user-sync.log -chown www-data. /var/log/ldap-sync/user-sync.log ----- - -=== Configure Caching and File Locking - -[source,bash,subs="attributes+"] ----- -occ config:system:set \ - memcache.local \ - --value '\OC\Memcache\APCu' -occ config:system:set \ - memcache.locking \ - --value '\OC\Memcache\Redis' -occ config:system:set \ - redis \ - --value '{"host": "{oc-examples-server-ip}", "port": "{std-port-redis}"}' \ - --type json ----- - -=== Configure Log Rotation - -[source,bash] ----- -FILE="/etc/logrotate.d/owncloud" -sudo cat <$FILE -/var/www/owncloud/data/owncloud.log { - size 10M - rotate 12 - copytruncate - missingok - compress - compresscmd /bin/gzip -} -EOM ----- - -==== Finalize the Installation - -Make sure the permissions are correct: - -[source,bash] ----- -cd /var/www/ -chown -R www-data. owncloud ----- - -**ownCloud is now installed. You can confirm that it is ready to enable HTTPS xref:installation/letsencrypt/using_letsencrypt.adoc[(for example using Let's Encrypt)] by pointing your web browser to your ownCloud installation.** - -To check if you have installed the correct version of ownCloud and that the occ command is working, execute the following: - -[source,bash] ----- -occ -V -echo "Your ownCloud is accessable under: "$my_ip -echo "Your ownCloud is accessable under: "$my_domain -echo "The Installation is complete." ----- - -IMPORTANT: We recommend you check out the section xref:configuration/server/harden_server.adoc[Hardening and Security Guidance] next. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/selinux_configuration.adoc b/content/server/10.15/modules/admin_manual/pages/installation/selinux_configuration.adoc deleted file mode 100644 index ad9b550..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/selinux_configuration.adoc +++ /dev/null @@ -1,210 +0,0 @@ -= SELinux Configuration -:toc: right -:toclevels: 1 -:selinux-url: https://selinuxproject.org/page/Main_Page - -== Introduction - -{selinux-url}[Security-Enhanced Linux (SELinux)] is a Linux kernel security module that provides a mechanism -for supporting access control security policies, including mandatory access controls (MAC). - -== Preparation - -When you have SELinux enabled on your Linux distribution, you may run -into permissions problems after a new ownCloud installation, and see -`permission denied` errors in your ownCloud logs. - -The following settings should work for most SELinux systems that use the -default distro profiles. Run these commands as root, and remember to -adjust the filepaths in these examples for your installation - -[source,console] ----- -semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud/data(/.*)?' -semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud/config(/.*)?' -semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud/apps(/.*)?' -semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud/apps-external(/.*)?' -semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud/.htaccess' -semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud/.user.ini' - -restorecon -Rv '/var/www/html/owncloud/' ----- - -If you uninstall ownCloud you need to remove the ownCloud directory -labels. To do this execute the following commands as root after -uninstalling ownCloud - -[source,console] ----- -semanage fcontext -d '/var/www/html/owncloud/data(/.*)?' -semanage fcontext -d '/var/www/html/owncloud/config(/.*)?' -semanage fcontext -d '/var/www/html/owncloud/apps(/.*)?' -semanage fcontext -d '/var/www/html/owncloud/apps-external(/.*)?' -semanage fcontext -d '/var/www/html/owncloud/.htaccess' -semanage fcontext -d '/var/www/html/owncloud/.user.ini' - -restorecon -Rv '/var/www/html/owncloud/' ----- - -If you have customized SELinux policies and these examples do not work, -you must give the HTTP server write access to these directories: - -[source,plaintext] ----- -/var/www/html/owncloud/data -/var/www/html/owncloud/config -/var/www/html/owncloud/apps -/var/www/html/owncloud/apps-external ----- - -== Enable updates via the web interface - -To enable updates via the ownCloud web interface, you may need this to -enable writing to the ownCloud directories: - -[source,console] ----- -setsebool httpd_unified on ----- - -When the update is completed, disable write access: - -[source,console] ----- -setsebool -P httpd_unified off ----- - -== Disallow write access to the whole web directory - -For security reasons it’s suggested to disable write access to all -folders in /var/www/ (default): - -[source,console] ----- -setsebool -P httpd_unified off ----- - -== Allow access to a remote database - -An additional setting is needed if your installation is connecting to a -remote database: - -[source,console] ----- -setsebool -P httpd_can_network_connect_db on ----- - -== Allow access to LDAP server - -Use this setting to allow LDAP connections: - -[source,console] ----- -setsebool -P httpd_can_connect_ldap on ----- - -== Allow access to remote network - -ownCloud requires access to remote networks for functions such as -Server-to-Server sharing, external storages or the ownCloud Marketplace. -To allow this access use the following setting: - -[source,console] ----- -setsebool -P httpd_can_network_connect on ----- - -== Allow access to network memcache - -This setting is not required if `httpd_can_network_connect` is already -on: - -[source,console] ----- -setsebool -P httpd_can_network_memcache on ----- - -== Allow access to SMTP/sendmail - -If you want to allow ownCloud to send out e-mail notifications via -sendmail you need to use the following setting: - -[source,console] ----- -setsebool -P httpd_can_sendmail on ----- - -== Allow access to CIFS/SMB - -If you have placed your datadir on a CIFS/SMB share use the following -setting: - -[source,console] ----- -setsebool -P httpd_use_cifs on ----- - -== Allow access to FuseFS - -If your owncloud data folder resides on a Fuse Filesystem (e.g. EncFS -etc.), this setting is required as well: - -[source,console] ----- -setsebool -P httpd_use_fusefs on ----- - -== Allow access to GPG for Rainloop - -If you use the rainloop webmail client app which supports GPG/PGP, you -might need this: - -[source,console] ----- -setsebool -P httpd_use_gpg on ----- - -== Troubleshooting - -=== General Troubleshooting - -For general Troubleshooting of SELinux and its profiles try to install -the package `setroubleshoot` and run: - -[source,console] ----- -sealert -a /var/log/audit/audit.log > /path/to/mylogfile.txt ----- - -to get a report which helps you to configure your SELinux profiles. - -Another tool for troubleshooting is to enable a single ruleset for your -ownCloud directory: - -[source,console] ----- -semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud(/.*)?' -restorecon -RF /var/www/html/owncloud ----- - -It is much stronger security to have a more fine-grained ruleset as in -the examples at the beginning, so use this only for testing and -troubleshooting. It has a similar effect to disabling SELinux, so don’t -use it on production systems. - -See this https://github.com/owncloud/documentation/pull/2693[discussion on GitHub] -to learn more about configuring SELinux correctly for ownCloud. - -=== Redis on RHEL 7 & Derivatives - -On RHEL 7 and its derivatives, if you are using Redis for both local -server cache and file locking and Redis is configured to listen on a -Unix socket instead of a TCP/IP port (_which is recommended if Redis is -running on the same system as ownCloud_) you must instruct SELinux to -allow daemons to enable cluster mode. You can do this using the -following command: - -[source,console] ----- -setsebool -P daemons_enable_cluster_mode 1 ----- diff --git a/content/server/10.15/modules/admin_manual/pages/installation/system_requirements.adoc b/content/server/10.15/modules/admin_manual/pages/installation/system_requirements.adoc deleted file mode 100644 index adf8cf3..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/system_requirements.adoc +++ /dev/null @@ -1,136 +0,0 @@ -= System Requirements -:toc: right -:toclevels: 1 -:ppa-guide-url: https://itsfoss.com/ppa-guide/ -:desktop-system-requirements-url: https://doc.owncloud.com/desktop/installing.html#system-requirements -:ios-system-requirements-url: https://doc.owncloud.com/ios-app/ios_faq.html -:android-system-requirements-url: https://doc.owncloud.com/android/faq.html - -:description: Read this documentation for a recommended or supported environment for your ownCloud Classic server. This documentation applies to both a new installation or upgrade of an existing installation. - -== Introduction - -{description} - -== General Note - -There is an important note about a xref:installation/manual_installation/manual_installation_prerequisites.adoc#openssl-version[prerequisite of openSSL]. We highly recommend checking this prerequisite as it needs to be checked regardless of the Operating System chosen. - -== Officially Recommended Environment - -For _best performance_, _stability_, _support_ and _full functionality_, we officially recommend and support: - -[width="60%"cols="30%,60%a",options="header"] -|=== -| Platform -| Options - -| Operating System -| Ubuntu 20.04 LTS - -| Database -| xref:#database-requirements[MariaDB] 10.11 ^1^ - -| Redis -| >= 6 - -| Web server -| Apache 2.4 with xref:installation/manual_installation/manual_installation.adoc#configure-the-web-server[`prefork and mod_php`] - -| PHP Runtime -| {recommended-php-version} -|=== - -(1) MariaDB 10.6 and later is *only supported* with ownCloud release 10.9 and upwards. See the xref:installation/manual_installation/manual_installation.adoc#install-a-database[Install a Database] guide and xref:maintenance/upgrading/database_upgrade.adoc[Database Upgrade] guide. - -== Officially Supported Environments - -For _best performance_, _stability_, _support_, and _full functionality_ we officially support: - -=== Server - -[width="90%"cols=".^ 30%,90%a",options="header"] -|=== -| Platform -| Options - -| Operating System (64bit) -| * Debian 10 -* Red Hat Enterprise Linux 7, 8 and 9 + -including all 100% compatible derivatives (please note Red Hat Enterprise Linux 9 support is Enterprise only. Contact ownCloud support for more information) -* SUSE Linux Enterprise Server 12 with SP4/5 and 15 -* Ubuntu 20.04 and 22.04 -* openSUSE Leap 15.2 - -| Database -| * xref:#database-requirements[MySQL] 8+ or xref:#database-requirements[MariaDB] 10.2 through 10.11 ^1^ (*Recommended*) -* Oracle 11 and 12 can be run in Oracle 19c with compatibility mode (*Enterprise only*) -* PostgreSQL 9, 10, 11, 12, 13 or 14 -* SQLite (*Not for production*) - -| Redis -| * >= 6 - -|Web server -|* Apache 2.4 with xref:installation/manual_installation/manual_installation.adoc#configure-the-web-server[`prefork` and `mod_php`] - -| PHP Runtime -|* {supported-php-versions} -|=== - -(1) MariaDB 10.6 and later is *only supported* with ownCloud release 10.9 and upwards. See the xref:installation/manual_installation/manual_installation.adoc#install-a-database[Install a Database] guide and xref:maintenance/upgrading/database_upgrade.adoc[Database Upgrade] guide. - -[NOTE] -==== -For Linux distributions, we support, if technically feasible, the latest two versions per platform and the previous LTS Version. -==== - -=== Hypervisors - -* Hyper-V -* VMware ESX - ownCloud must run without overcommitment of cores or RAM for larger installations (1000+ users). -* Xen -* KVM - -=== Web Browser - -* Edge (current version on Windows 10) -* IE11 or newer (except Compatibility Mode) -* Firefox 60 ESR+ -* Chrome 66+ -* Safari 10+ - -=== Desktop Sync Client - -We always recommend to use the newest sync client with the latest server release. - -You can find {desktop-system-requirements-url}[detailed system requirements] in the documentation for the Desktop Synchronization Client. - -=== Mobile Apps - -We always recommend to use the newest mobile apps with the latest server release. - -You can find detailed system requirements in the documentation for the mobile apps. - -* {ios-system-requirements-url}[iOS system requirements] -* {android-system-requirements-url}[Android system requirements] - -[TIP] -==== -You can find out more in the https://owncloud.com/changelog[changelog]. -==== - -== Database Requirements - -The following database settings are currently required if you’re running ownCloud together with a MySQL or MariaDB database: - -* Disabled or `BINLOG_FORMAT = MIXED` or `BINLOG_FORMAT = ROW` configured Binary Logging (See: xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB with Binary Logging Enabled]) -* InnoDB storage engine (The MyISAM storage engine is *not supported*, see: -xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB storage engine]) -* `READ COMMITTED` transaction isolation level (See: -xref:configuration/database/linux_database_configuration.adoc#set-read-committed-as-the-transaction-isolation-level[MySQL / MariaDB `READ COMMITTED` transaction isolation level]) - -== Memory Requirements - -Memory requirements for running an ownCloud server are greatly variable, depending on the numbers of users and files, and volume of server activity. ownCloud officially requires a minimum of 128MB RAM. -But, we recommend a minimum of 512MB. diff --git a/content/server/10.15/modules/admin_manual/pages/installation/troubleshooting.adoc b/content/server/10.15/modules/admin_manual/pages/installation/troubleshooting.adoc deleted file mode 100644 index 9b13374..0000000 --- a/content/server/10.15/modules/admin_manual/pages/installation/troubleshooting.adoc +++ /dev/null @@ -1,11 +0,0 @@ -= Troubleshooting - -If your ownCloud installation fails and you see the following error in -your ownCloud log please refer to -xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB with Binary Logging Enabled] -for how to resolve it. - -[source,plaintext] ----- -An unhandled exception has been thrown: exception ‘PDOException’ with message 'SQLSTATE[HY000]: General error: 1665 Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED.' ----- diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/backup_and_restore/backup.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/backup_and_restore/backup.adoc deleted file mode 100644 index 949b943..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/backup_and_restore/backup.adoc +++ /dev/null @@ -1,146 +0,0 @@ -= Backing up ownCloud -:toc: right -:description: Depending on how the ownCloud instance has been installed, you may need slightly different steps to do a backup. -:page-aliases: go/admin-backup.adoc, \ -maintenance/backup.adoc, \ -maintenance/backup_and_restore/index.adoc - -== Introduction - -{description} You may also use different methods as the data directory can be huge. This document is intended as a guideline, but the way you implement it depends on your setup. - -In any case, you need the following components to be backed up: - -. The `config/` directory. -. The `data/` directory. + -Note that the `data/` directory may not only contain user files but also keys for encryption. -. The `apps/` directory. + -Note that this is only necessary if you are not using the `apps-external/` directory and have added own apps or themes. -. The `apps-external/` directory. + -Note that this is only necessary if it exists and is in use. -. The ownCloud database. -. The custom theme files, if you had any. See xref:developer_manual:core/theming.adoc[Theming ownCloud]. + -Note that theme files are usually located in either the `apps/` or `apps-external/` directory. - -IMPORTANT: If you have customized user home directories or a custom location for encryption keys, you have to manually take care of backing them up and restoring them to the same location. - -== Prerequisites - -To ensure a consistent backup, stop your web server to prevent users from trying to access ownCloud via the web. As an alternative, you can stop serving the virtual host for ownCloud: - -[source,bash,subs="attributes+"] ----- -sudo service apache2 stop ----- - -== Backup Scenarios - -Tarball Installation:: -. If you have installed ownCloud from a tarball, you can safely backup the entire installation, with the exception of your ownCloud database. Databases cannot be copied, instead you must use the database tools to make a correct backup. - -. You can also back up only the directories mentioned above and the database. To avoid issues, you have to use the same tarball version as the ownCloud version when restoring. - -Package Installation:: -If you have installed your ownCloud server from our deprecated Open Build Service and not from our new {oc-install-package-url}[package repository site], *do not back up your ownCloud server files*, which are the other files in your `owncloud/` directory such as `core/`, `3rdparty/`, `lib/`, etc. If you restore these files from backup they may not be in sync with the current package versions and in that case will fail the code integrity check and may also cause other errors. - -//missing docker... -//If you are running ownCloud in a docker container, refer to //xref:installation/docker/index.adoc#upgrading-owncloud-on-docker[Upgrading ownCloud on docker]. - -=== Backup Directories - -If possible, simply copy the directories from your ownCloud installation to your backup location, for example by running the following command from the owncloud directory. The following example command copies all directories mentioned above: - -[source,bash] ----- -rsync -Aax config data apps apps-external /oc-backupdir/ ----- - -You can also back up the full ownCloud directory which eases the restore as you do not need to install ownCloud first. - -There are many ways to backup normal files. Use whatever method you are accustomed to. - -== Backup the Database - -You can't just copy a database, but must use the database tools to make a correct database dump. - -Before backing up the database, set your ownCloud instance into maintenance mode: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --on ----- - -NOTE: This guide uses a backup file name like `owncloud-dbbackup_.bak`. - -=== MySQL/MariaDB - -Depending on the database version and the setup, username and password may not be necessary. The general command to back up MySQL/MariaDB looks like this: - -[source,bash] ----- -sudo mysqldump \ - --single-transaction \ - -h [server] \ - -u [username] \ - -p [password] \ - [db_name] > owncloud-dbbackup_`date +"%Y%m%d"`.bak ----- - -Example, replace username and password according your setup: - -[source,bash] ----- -sudo mysqldump \ - --single-transaction \ - -h localhost \ - -u username \ - -p password \ - owncloud > owncloud-dbbackup_`date +"%Y%m%d"`.bak ----- - -=== SQLite - -[source,bash] ----- -sqlite3 data/owncloud.db .dump > owncloud-dbbackup_`date +"%Y%m%d"`.bak ----- - -=== PostgreSQL - -[source,postgresql] ----- -PGPASSWORD="password" \ - pg_dump [db_name] \ - -h [server] \ - -U [username] \ - -F tar \ - -f owncloud-dbbackup_`date +"%Y%m%d"`.bak ----- - -== Backup Cron Jobs - -Use this if you want to protect against an accidental deletion of cron entries, plan to restore to a different server like a physical migration or you need to set up a server from scratch. - -[source,bash] ----- -sudo crontab -u www-data -l > www-data_crontab.bak ----- - -== Final Tasks - -=== Reactivate Your Instance - -Perform the following tasks to reactivate your ownCloud instance: - -.Bring back ownCloud into normal operation mode -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -.Enable browser access -Start your web server, or alternatively enable the virtual host serving ownCloud: -[source,bash] ----- -sudo service apache2 start ----- diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/backup_and_restore/restore.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/backup_and_restore/restore.adoc deleted file mode 100644 index cd94653..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/backup_and_restore/restore.adoc +++ /dev/null @@ -1,214 +0,0 @@ -= Restoring ownCloud -:toc: right -:page-aliases: maintenance/restore.adoc -:description: Depending how the ownCloud instance has been installed, you may need slightly different steps to restore it from a backup. - -== Introduction - -{description} - -In any case, you need the following components from your backup: - -. The `config/` directory. -. The `data/` directory. + -Note that the `data/` directory may not only contain user files, but also keys for encryption. -. The `apps/` directory. + -Note that this is only necessary if you are not using the `apps-external/` directory and have added own apps or themes. -. The `apps-external/` directory. + -Note that this is only necessary if it exists and is in use. -. The ownCloud database. -. The custom theme files, if you had any. See xref:developer_manual:core/theming.adoc[Theming ownCloud]. + -Note that theme files are usually located in either the `apps/` or `apps-external/` directory. - -IMPORTANT: If you have customized user home directories or a custom location for encryption keys, you have to manually take care of backing them up and restoring them to the same location. - -== Prerequisites - -To ensure a secure restore process, stop your web server to prevent users from accessing ownCloud via the web. As an alternative, you can stop serving the virtual host for ownCloud: - -[source,bash] ----- -sudo service apache2 stop ----- - -== Restore Scenarios - -Tarball Installation:: -. If you have installed ownCloud from a tarball, you can safely restore the entire installation from the backup, with the exception of your ownCloud database. Databases cannot be copied, instead you must use the database tools to make a correct restoration. - -. You may also install a new instance from a tarball and restore the directories named above and the database. To avoid issues, use the same tarball version as the ownCloud version from the backup. - -Package Installation:: -If you have installed ownCloud from packages, start with a fresh ownCloud package installation in a new, empty directory. Then restore the above items from your xref:maintenance/backup_and_restore/backup.adoc[Backup]. -+ -NOTE: Only copy those files and folders from the `apps/` backup directory which are NOT present after the installation. Do not overwrite items of the `apps/` directory in the new installation. This will prevent a failing code integrity check and other errors. - -After you have completed restoring files, see how to xref:installation/manual_installation/manual_installation.adoc#script-guided-installation[Set Correct Permissions]. - -//missing docker... - -=== Restore Directories - -If possible, simply copy the directories from your backup to your new ownCloud environment, for example by running the following command from the backup directory. The following example command copies all directories mentioned above: - -[source,bash] ----- -sudo rsync -Aax config data apps apps-external /var/www/owncloud/ ----- - -There are many ways to restore normal files from backup. Use whatever method you are accustomed to. - -== Restore the Database - -Before restoring the database, set your ownCloud instance into maintenance mode: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --on ----- - -NOTE: This guide assumes that your previous backup is called `owncloud-dbbackup.bak`, though the file may have a timestamp added in the filename. - -=== MySQL/MariaDB - -Depending on the database version and the setup, username and password may not be necessary. To restore MySQL/MariaDB: - -[source,bash,subs="attributes+"] ----- -sudo mysql -h [server] -u [username] -p[password] [db_name] < owncloud-dbbackup.bak ----- - -=== SQLite - -[source,bash] ----- -sudo rm data/owncloud.db -sudo sqlite3 data/owncloud.db < owncloud-dbbackup.bak ----- - -=== PostgreSQL - -[source,plaintext] ----- -PGPASSWORD="password" pg_restore -c -d owncloud -h [server] -U [username] owncloud-dbbackup.bak ----- - -== Restoring Files From a Backup When Encryption Is Enabled - -If you need to restore files from a backup during which encryption was enabled, proceed as follows with caution. - -WARNING: This is *not officially supported*. ownCloud officially supports either restoring the full backup or restoring nothing — not restoring individual parts of it. - -* Restore the file from backup. -* Restore the file's encryption keys from your backup. -* Run `occ files:scan`, which makes the scanner find it. - -[NOTE] -==== -In the DB it will: - -- Have the "size" set to the encrypted size, which is wrong (and bigger). -- The "encrypted" flag will be set to 0. -==== - -* Retrieve the encrypted flag value -* Update the encrypted flag. - -NOTE: There's no need to update the encrypted flag for files in either `files_versions` or `files_trashbin` -because these aren't scanned or found by `occ files:scan`. - -* Download the file once as the user; the file's size will be corrected automatically. - -This process might not be suitable across all environments. -If it's not suitable for yours, you might need to run an OCC command that does the scanning. - -=== Retrieve the Encrypted Flag Value - -1. In the backup database, retrieve the `numeric_id` value for https://github.com/owncloud/core/wiki/Storage-IDs[the storage] - where the file was located from the `oc_storages` table and store the value - for later reference. - For example, if you have the following in your `oc_storages` table, the - `numeric_id` you should use is `3` if you need to restore a file for `user1`. - - +--------------------------------+------------+-----------+--------------+ - | id | numeric_id | available | last_checked | - +--------------------------------+------------+-----------+--------------+ - | home::admin | 1 | 1 | NULL | - | local::/var/www/owncloud/data/ | 2 | 1 | NULL | - | home::user1 | 3 | 1 | NULL | - +--------------------------------+------------+-----------+--------------+ - -2. In the live database instance, find the `fileid` of the file to restore by - running the query below, substituting the placeholders for the retrieved - values, and store the value for later reference. -+ -[source,sql] ----- -SELECT fileid -FROM oc_filecache -WHERE path = 'path/to/the/file/to/restore' - AND storage = ----- - -3. Retrieve the backup, which includes the data folder and database. - -4. Retrieve the required file from your backup and copy it to the real instance. - -5. In the backup database, retrieve the file's `encrypted` value by running - the query below and store the value for later reference. - The example query assumes the storage was the same and the file was in the same location. - If not, you will need to track down where the file was before. -+ -[source,sql] ----- -SELECT encrypted -FROM oc_filecache -WHERE path = 'path/to/the/file/to/restore' - AND storage = ----- - -6. Update the live database instance with the retrieved information, by running the - following query, substituting the placeholders with the retrieved values: -+ -[source,sql] ----- -UPDATE oc_filecache - SET encrypted = - WHERE fileid = . ----- - -== Final Tasks - -=== Update ETag information - -When a backup has been restored, the ETag information, which is necessary when accessing ownCloud with clients, has been changed. -Run the following command to tell desktop and mobile clients that a server backup has been restored. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:data-fingerprint ----- - -=== Bring back ownCloud into normal operation mode - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -=== Enable browser access - -Start your web server, or alternatively enable the virtual host serving ownCloud: -[source,bash] ----- -sudo service apache2 start ----- - -=== Restore Cron Jobs - -This is only necessary if you accidentally deleted the crontab entries, or you're restoring to a different server to carry out a physical migration or you need to set up a server from scratch. - -[source,bash,subs="attributes+"] ----- -sudo crontab -u www-data < www-data_crontab.bak ----- diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/enable_maintenance.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/enable_maintenance.adoc deleted file mode 100644 index 892586f..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/enable_maintenance.adoc +++ /dev/null @@ -1,39 +0,0 @@ -= Maintenance Mode Configuration - -== Introduction - -You must put your ownCloud server into maintenance mode before performing upgrades. The same applies to performing troubleshooting and maintenance tasks. See xref:configuration/server/occ_command.adoc#maintenance-commands[Using the occ Command] to learn how to put your server into the various maintenance modes (`maintenance:mode, maintenance:singleuser`, and `maintenance:repair`) with the `occ` command. You can also use the `config.php` file for setting maintenance modes. - -`maintenance:mode` locks the sessions of logged-in users and prevents new logins. This is the mode to use for upgrades. - -== Enable Maintenance Mode - -To enable maintenance mode, run the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --on ----- - -You may also put your server into this mode by editing config/config.php. - -[source,php] ----- -'maintenance' => true, ----- - -== Disable Maintenance Mode - -To disable maintenance mode, run the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -You may also put your server into this mode by editing config/config.php. + - -[source,php] ----- -'maintenance' => false, ----- diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/encryption/migrating-from-user-key-to-master-key.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/encryption/migrating-from-user-key-to-master-key.adoc deleted file mode 100644 index 5c2a9ef..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/encryption/migrating-from-user-key-to-master-key.adoc +++ /dev/null @@ -1,118 +0,0 @@ -= Migrating User Key Encryption to Master Key Encryption -:toc: right -:announcementcenter_url: {oc-marketplace-url}/apps/announcementcenter -:page-aliases: maintenance/encryption/index.adoc - -== Introduction - -IMPORTANT: User Key Encryption has been deprecated with ownCloud Classic 10.7, see the corresponding https://doc.owncloud.com/server_release_notes.html#deprecation-note-for-user-key-storage-encryption[release notes] for details. Though you can continue to use this solution, it is no longer selectable and existing User Key Encryption must be migrated to Master Key Encryption. - -The reason disabling User key-based encryption is because of some disadvantages. It blocks some additional functions such as the integration of an online editor like LibreOffice or OnlyOffice into ownCloud and can cause problems when sharing files with groups. -See xref:configuration/files/encryption/encryption_configuration.adoc#limitations-of-user-key-based-encryption[Limitations of User-Key Based Encryption] for more details. Master-key-based encryption is therefore now the recommended and only available setup for all new installations. - -== Pre-Conditions - -The decryption workflow described here will only work with the following pre-conditions: - -* The admin recovery key password is activated and available to the ownCloud administrator -* Users have opted-in to enable the admin recovery key password -* The recovery key password has been supplied by the admin on the users page - -Please see xref:configuration/files/encryption/encryption_configuration.adoc#enable-users-file-recovery-keys[How To Enable Users File Recovery Keys] for more details. - -NOTE: A notification to the users (e.g. through the {announcementcenter_url}[announcement app]) -prior to the migration process is recommended, as the instance will not be available during this task. - -== Steps to Migrate from User Key-based to Master Key-based Encryption - -There are several steps you need to follow to ensure a smooth and complete transition: - -. xref:disable-user-key-based-encryption[Disable User Key-based encryption] -. xref:remove-the-encryption-records-from-the-owncloud-database[Remove the encryption records from the ownCloud database] -. xref:remove-the-files_encryption-directory[Remove the `files_encryption` directory] -. xref:encrypt-the-filesystem-using-master-key-based-encryption[Encrypt the filesystem using Master Key-based encryption] - -=== Disable User Key-based Encryption - -The first part of the migration process is to decrypt all files and to disable encryption in ownCloud, which requires three commands to be executed. These commands are: - -. xref:configuration/server/occ_command.adoc#encryption[`occ encryption:decrypt-all`], -. xref:configuration/server/occ_command.adoc#encryption[`occ encryption:disable`] and -. xref::configuration/server/occ_command.adoc#apps-commands[`occ app:disable`]. - -You can see an example of calling the commands listed below, configured to require no user interaction. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} encryption:decrypt-all --continue=yes && \ - {occ-command-example-prefix} encryption:disable --no-interaction && \ - {occ-command-example-prefix} app:disable --no-interaction encryption ----- - -NOTE: The decryption of the files by the ownCloud administrator requires the current passwords of all users! This only works when users have enabled password recovery and if an admin recovery password is available. - -=== Remove the Encryption Records from the ownCloud Database - -Once your ownCloud files are unencrypted, and encryption has been disabled, you need to remove the encryption records from the database. There is, currently, no `occ` command to handle this, so it has to be done manually. Specifically, you need to remove all records from the `oc_appconfig` table where the `appid` column is set to `encryption`. - -In the examples below, you can see how to do this using MySQL. If you are not using MySQL, please use the commands specific to your database vendor. - -[source,sql] ----- -SELECT * FROM `oc_appconfig` WHERE `appid` LIKE 'encryption' ----- - -=== Remove the files_encryption Directory - -With the database updated, next, the `files_encryption` directory needs to be removed. Below is an example of how to do so, to save you time. - -[source,bash] ----- -cd -find ./data* -name files_encryption -exec rm -rvf {} \; ----- - -=== Encrypt the Filesystem Using Master Key-based Encryption - -Now, your ownCloud files can be encrypted using Master Key-based encryption. This requires the following steps: - -. The encryption app needs to be enabled -. Encryption needs to be enabled -. The encryption type needs to be set to Master Key -. Re-encryption of the ownCloud filesystem. - -The following example shows how to do this on the command line. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable encryption && \ - {occ-command-example-prefix} encryption:enable && \ - {occ-command-example-prefix} encryption:select-encryption-type masterkey -y && \ - {occ-command-example-prefix} encryption:encrypt-all --yes ----- - -== Verify the Encrypted Files - -With the files encrypted using Master Key-based encryption, you should now verify that everything worked properly. To do so, run a `SELECT` query in your database which returns all files from the `oc_appconfig` table where the `appid` column is set to `encryption`. You should see a number of records, as in the output of the example below. - -[source,sql] ----- -select * from `oc_appconfig` where appid='encryption'; ----- - -[source,plaintext] ----- -encryption|recoveryKeyId|recoveryKey_73facda6 -encryption|publicShareKeyId|pubShare_73facda6 -encryption|masterKeyId|master_73facda6 -encryption|installed_version|1.3.1 -encryption|types|filesystem -encryption|enabled|yes -encryption|useMasterKey|1 ----- - -include::partial$/configuration/server/disable-single-user-mode.adoc[leveloffset=+1] - -== Post Note - -NOTE: It is possible, that after migration, some or all users see a re-synchronisation of their data from the server to the desktop client - especially for shared folders. diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/export_import_instance_data.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/export_import_instance_data.adoc deleted file mode 100644 index eb600ff..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/export_import_instance_data.adoc +++ /dev/null @@ -1,118 +0,0 @@ -= Data Exporter -:toc: right - -== Important Information - -WARNING: This app is currently in beta stage, the functionality is officially not supported. + -Please file any issues https://github.com/owncloud/data_exporter/issues[here]. - -WARNING: The app is not available on the marketplace. + -To use this app, you must https://github.com/owncloud/data_exporter.git[git clone] it from the -`data_exporter` repository and run `make all` in the apps root directory to install all dependencies. - -== Introduction - -A set of `occ command line` tools to export and import users with their shares -from one ownCloud instance in to another. Please see -xref:what-is-exported[What is Exported] for export details and -xref:known-limitations[Known Limitations] for limitation details. -Please see the xref:configuration/server/occ_command.adoc#data-exporter[Data Exporter Commands] -description for details using the occ commands. - -NOTE: To use data exporter, you must install and enable the `data_exporter` app on both, -the source and the target instance first. - -== Use Cases - -- Manual zero-downtime migration of users and their shares from one instance in to another. -- Migrate from instances with different storages (POSIX to S3). -- Service GDPR-Requests by providing all files and metadata of a user in a single package. -- Merge users from different instances. - -== Usage Example - -Export `user1` from a `source instance` to a `target instance` while preserving all shares -with users on the source instance. For this example, both instances must be able to reach each -other via federation. - -NOTE: Test if you can create remote shares before starting this process. - -=== Export the User on the Source Instance - -This will create a folder `/tmp/export/user1` which contains all the files and metadata of the user. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} instance:export:user user1 /tmp/export ----- - -=== Copy the Export to the Target Instance - -Copy the created export to the target instance, for example, using `scp`: - -[source,bash] ----- -scp -rp /tmp/export root@newinstance.com:/tmp/export ----- - -=== Import the User on the Target Instance - -This imports the user in to the target instance while converting all their outgoing-shares -to federated shares pointing to the source instance: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} instance:import:user /tmp/export/user1 ----- - -NOTE: A new user's last login timestamp on the target instance will be set to the current time. The import command sets up the user's file system and the system does not need to do any further "first login" processing when the user first logs in to the target instance. - -=== Recreate all Shares to Point to the Target Instance - -`user1` now lives on a target instance, therefore, it is necessary to recreate all shares so that -they point to the target instance. To do so, run this command on the source instance: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} instance:export:migrate:share user1 https://newinstance.com ----- - -=== Delete the User on the Source Instance - -Finally delete `user1` on the source instance: - -NOTE: This can not be undone! - -NOTE: If the user is stored in the ownCloud database, you need to manually reset their password -on the target instance. See xref:known-limitations[Known Limitations] for further information. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} user:delete user1 ----- - -== What is Exported - -- Files (Local) -- Meta-data (Username, Email, Personal Settings) -- Shares (Local, Link-shares, Group-Shares) -- Versions -- Trashbin - -== Known Limitations - -- External storages, comments and tags are not exported -- If a user is stored in the ownCloud database (not-LDAP etc.) the password - must be manually reset by the admin as passwords cannot be migrated. -- Versions import in to S3 does not preserve the version timestamp. -- Import alias (import using another username) currently does not work and breaks share-import. -- Shares import requires federation to be correctly setup between both servers and share-api to be enabled. -- A share's state will always be "accepted" regardless of the state in the old server. -- Remote shares from both directions need to be manually accepted. -- Federated shares from other servers are not migrated. -- Password protected link-shares are not imported correctly, user needs to reset the password. -- Group shares require the group to be present on the target-system or else the share will be ignored silently. -- If link-shares require a password on the new server but do not on the old, the import process will crash. - -As this is an early version, some limitations might be fixed in the future while others -cannot be circumvented. diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/manually-moving-data-folders.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/manually-moving-data-folders.adoc deleted file mode 100644 index 91069ee..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/manually-moving-data-folders.adoc +++ /dev/null @@ -1,189 +0,0 @@ -= Manually Move the Data Directory -:toc: right -:description: Use these instructions if you intend to move your ownCloud's data directory from its current location to another without using a symbolic link. - -:mysql-string-replace-function-url: http://www.mysqltutorial.org/mysql-string-replace-function.aspx - -== Introduction - -{description} - -Though using symbolic links to relocate the data directory can be beneficial, it can be necessary to hard relocate it. -If a hard relocation is required, not only the physical location but also the database has to be updated. - -This guide assumes that: - -* The current folder is: `/var/www/owncloud/data` -* The new folder is: `/mnt/owncloud/data` -* You’re using Apache as your webserver -* ownCloud's database name is `owncloud` - -Please change the paths above to reflect your environment. - -== Summary - -The following steps are necessary to move the data directory. - -. Stop the web server -. Enable maintenance mode -. Sync your Data directory -. Adjust ownCloud's configuration -. Check permissions -. Disable maintenance mode -. Start the web server - -Look at each section below for a detailed description. - -== Stop the Web Server - -Stopping the web server makes sure there are no active connections to your server. - -[source,bash] ----- -sudo service apache2 stop ----- - -== Enable Maintenance Mode - -It is necessary to enable maintenance mode to avoid running cron jobs. -To enable maintenance mode, run the following command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --on ----- - -== Sync your Data Directory - -[source,bash] ----- -sudo rsync -avz /var/www/owncloud/data /mnt/owncloud ----- - -Make sure that `.ocdata` and `.htaccess` were synced to the new directory. - -[source,bash] ----- -ls -a | grep -i "^\.[A-Z]" ----- - -== Adjust ownCloud's configuration - -=== Adjust oc_storages table - -Connect to your database and enter following commands: - -[source,sql] ----- -use owncloud; ----- - -=== Update the oc_storages Table - -Run the SQL below: - -[source,sql] ----- -UPDATE oc_storages - SET id='local::/mnt/owncloud/data/' - WHERE id='local::/var/www/owncloud/data/'; ----- - -=== Update the oc_accounts Table - -You next need to update the `home` column in the `oc_accounts` table. -This column contains the absolute path for user folders, e.g., `/mnt/owncloud/data/my_user`. - -If a user does not have the path already set, you have to identify the users `id` and set the path with the following command, user by user. -This example assumes the user name is `my_user` and their id is `1`. Note that id's are incremental, meaning the account you created first will have id `1` and so on. - -Run the SQL below: - -[source,sql] ----- -UPDATE oc_accounts SET home='/mnt/owncloud/data/my_user' - WHERE id=1; ----- - -For all users who already have a path like `/var/www/owncloud/data/` in your database, you can use the `REPLACE` command: - -[source,sql] ----- -UPDATE oc_accounts - SET home = REPLACE( - home, - '/var/www/owncloud/data/', - '/mnt/owncloud/data/' - ); ----- - -For more information follow the complete MySQL {mysql-string-replace-function-url}[REPLACE] command syntax. - -CAUTION: Please don’t copy and paste this example verbatim — nor any of the others. They are examples only. - -=== Update the oc_jobs table - -The next area to check is the `oc_jobs` table. -The logrotate process may have hard-coded a non-standard (or old) value for the data path. -To check it, run the SQL below and see if any results are returned: - -[source,sql] ----- -SELECT * FROM oc_jobs - WHERE class = 'OC\Log\Rotate'; ----- - -If results are returned, run the SQL below to update them, changing the id value as appropriate. - -[source,sql] ----- -UPDATE oc_jobs - SET argument = REPLACE( - argument, - '\\/var\\/www\\/owncloud\\/data\\/', - '\\/mnt\\/owncloud/data\\/' - ) - WHERE id = ; ----- - -CAUTION: The old data path will be written with `\/`. -Therefore you must add one, additional, backslash, like this: `\\/`. - -== Fix the config.php Settings - -To fix the config.php settings: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} config:system:set --value /mnt/owncloud/data datadirectory ----- - -=== Adjust config.php - -. Change the `datadirectory` key in your `config.php` to the new path. - To do so, start an editor of your choice and open `/var/www/owncloud/config/config.php` - -. Change the value of the key from `'datadirectory' => '/var/www/owncloud/data',` to `'datadirectory' => '/mnt/owncloud/data',`. - -== Disable Maintenance Mode - -To disable maintenance mode of your instance run the following command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -== Start the Web Server - -[source,bash] ----- -sudo service apache2 start ----- - -== Scan the Files - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:scan --all ----- diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/migrating.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/migrating.adoc deleted file mode 100644 index eedecc4..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/migrating.adoc +++ /dev/null @@ -1,267 +0,0 @@ -= Migrating to a Different Server -:toc: right -:toclevels: 1 -:page-aliases: go/admin-untrusted-domains.adoc - -== Introduction - -If the need arises, ownCloud can be migrated to a different server. -A typical use case would be a hardware change to a physical server. -All migrations have to be performed with ownCloud in maintenance mode. -Online migration is supported by ownCloud only when implementing -industry-standard clustering and high-availability solutions *before* -ownCloud is installed for the first time. - -To start, let’s work through a potential use case. A configured ownCloud -instance runs reliably on one machine, but for some reason the instance -needs to be moved to a new machine. Depending on the size of the -ownCloud instance the migration might take several hours. - -For the purpose of this use case, it is assumed that: - -1. The end users reach the ownCloud instance via a virtual hostname -(such as a DNS `CNAME` record) which can be pointed at the new location. -2. The authentication method (e.g., LDAP) remains the same after the -migration. - -IMPORTANT: During the migration, do not make any changes to the original system, except for putting it into -maintenance mode. This ensures, should anything unforeseen happen, that you can go back to your existing -installation and resume availability of your installation while debugging the problem. - -== How to Migrate - -Firstly, set up the new machine with your desired Linux distribution. At this point, you can install xref:installation/manual_installation/manual_installation.adoc[ownCloud manually] via the -compressed archive. - -Then, on the original machine turn on maintenance mode and then stop ownCloud. -After waiting 6 - 7 minutes for all sync clients to register that the server is in maintenance mode, stop the web server that is serving ownCloud. - -After that, xref:maintenance/backup_and_restore/backup.adoc[create a database dump] from the database, copy it to the new machine and xref:maintenance/backup_and_restore/restore.adoc[import it] into the new database. -Then, copy only your data, configuration, and database files from your original ownCloud instance to the new machine. - -IMPORTANT: You must keep the `data/` directory’s original file path during the migration. -However, xref:maintenance/manually-moving-data-folders.adoc[you can change it] before you begin the migration, or after the migration’s completed. - -The data files should keep their original timestamp otherwise the -clients will re-download all the files after the migration. This step -might take several hours, depending on your installation. This can be -done on a number of sync clients, such as by using `rsync` with `-t` -option - -With ownCloud still in maintenance mode and before changing the DNS -`CNAME` record, start up the database and web server on the new machine. -Then point your web browser to the migrated ownCloud instance and -confirm that: - -1. You see the maintenance mode notice -2. That a log file entry is written by both the web server and ownCloud -3. That no error messages occur. - -If all of these things occur, then take ownCloud out of maintenance mode -and repeat. After doing this, log in as an admin and confirm that -ownCloud functions as normal. - -At this point, change the DNS `CNAME` entry to point your users to the -new location. And with the `CNAME` entry updated, you now need to update -the trusted domains. - -== Managing Trusted Domains - -All URLs used to access your ownCloud server must be white-listed in your -`config.php` file, under the `trusted_domains` setting. Users are -allowed to log into ownCloud only when they point their browsers to a -URL that is listed in the `trusted_domains` setting. - -NOTE: This setting is important when changing or moving to a new domain name. You may use IP addresses and domain names. - -A typical configuration looks like this: - -[source,php] ----- -'trusted_domains' => [ - 0 => 'localhost', - 1 => 'server1.example.com', - 2 => '192.168.1.50', -], ----- - -The loopback address, `127.0.0.1`, is automatically white-listed, so as -long as you have access to the physical server you can always log in. In -the event that a load-balancer is in place, there will be no issues as -long as it sends the correct `X-Forwarded-Host` header. - -In case of a docker based setup, the trusted_domains setting is controlled by the environment variables `OWNCLOUD_TRUSTED_DOMAINS` or `OWNCLOUD_DOMAIN`. The latter only takes effect, if `OWNCLOUD_TRUSTED_DOMAINS` is undefined and can provide one IP-address or hostname. `OWNCLOUD_TRUSTED_DOMAINS` can specify multiple values as a comma-separated list. - -Here is an example of how this can be used from within a docker-compose.yml file to allow access to ownCloud under two different names, and one IP-address, in addition to localhost and 127.0.0.1: - -[source,yaml,subs="attributes+"] ----- -services: - owncloud: - image: "owncloud/server:{latest-server-version}" - environment: - OWNCLOUD_TRUSTED_DOMAINS: "myowncloud.mydomain.com, myowncloud, 12.23.34.45" -... ----- - -== Example Migration - -The following is an example migration with assumptions to make -this migration work: - -* Ubuntu 20.04+ -* SSH with `PermitRootLogin` set to `yes` -* Database used is MySQL / MariaDB - -=== Preparation - -If not already available on the new server, make sure SSH is installed: - -[source,bash] ----- -sudo apt install ssh -y ----- - -Next, edit ssh-config and enable root ssh login. - -[source,bash] ----- -nano /etc/ssh/sshd_config -PermitRootLogin yes ----- - -And then restart SSH. - -[source,bash] ----- -sudo service ssh restart ----- - -Lastly, install ownCloud on the new server. - -=== Migration - -==== Enable Maintenance Mode - -The first step is to enable maintenance mode. To do that, use the -following commands: - -[source,bash,subs="attributes+"] ----- -cd /var/www/owncloud/ -{occ-command-example-prefix} maintenance:mode --on ----- - -After that’s done, then wait a few minutes and stop your web server, in this case Apache: - -[source,bash] ----- -sudo service apache2 stop ----- - -==== Transfer the Database - -Now, you have to transfer the database from the old server to the new -one. To do that, first backup the database. - -[source,bash] ----- -cd /var/www/owncloud/ -mysqldump --single-transaction -h localhost \ - -u admin -ppassword owncloud > owncloud-dbbackup.bak ----- - -Then, export the database to the new server. - -[source,bash] ----- -rsync -v owncloud-dbbackup.bak root@new_server_address:/var/www/owncloud ----- - -With that completed, import the database on new server. - -[source,bash] ----- -mysql -h localhost -u admin -ppassword owncloud < owncloud-dbbackup.bak ----- - -NOTE: You can find the values for the mysqldump command in your config.php, in your owncloud root directory. `[server]= dbhost, [username]= dbuser, [password]= dbpassword, and [db_name]= dbname`. - -[NOTE] -==== -.For InnoDB tables only -The –single-transaction flag will start a transaction before running. -Rather than lock the entire database, this will let `mysqldump` read the database in the current state at the time of the transaction, making for a consistent data dump. -==== - -[NOTE] -==== -.For Mixed MyISAM / InnoDB tables -Either dumping your MyISAM tables separately from InnoDB tables or use `--lock-tables` instead of `--single-transaction` to guarantee the database is in a consistent state when using `mysqldump`. -==== - -==== Transfer Data and Configure the New Server - -The following ownCloud directories will be synced to the target instance: -`apps`, `config` and `data`. - -[source,bash] ----- -rsync -avt apps config data root@new_server_address:/var/www/owncloud ----- - -NOTE: If you have an additional apps directory like `apps-external`, this directory needs -to be added to the sync list above. - -IMPORTANT: If you want to move your data directory to another location on the target server, -it is advised to do this as a second step. Please see -xref:maintenance/manually-moving-data-folders.adoc[the data directory migration document] for more details. - -==== Finish the Migration - -Now it’s time to finish the migration. To do that, on the new server, -first verify that ownCloud is in maintenance mode. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode ----- - -Next, start up the database and web server on the new machine. - -[source,bash] ----- -sudo service mysql start -sudo service apache2 start ----- - -With that done, point your web browser to the migrated ownCloud -instance, and confirm that you see the maintenance mode notice, and that -no error messages occur. If both of these occur, take ownCloud out of -maintenance mode. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -And finally, log in as admin and confirm normal function of ownCloud. If -you have a domain name, and you want an SSL certificate, we recommend -https://certbot.eff.org/[certbot]. - -==== Reverse the Changes to ssh-config - -Now you need to reverse the change to ssh-config. Specifically, set `PermitRootLogin` -to `no` and restart ssh. To do that, run the following command: - -NOTE: This is a security measure and improves SSH security. - -[source,bash] ----- -sudo service ssh restart ----- - -==== Update DNS and Trusted Domains - -Finally, update the DNS’ `CNAME` entry to point to your new server. -If you have not only migrated physically from server to server but have also changed your ownCloud server’s domain name, you also need to update the domain in xref:managing-trusted-domains[the Trusted Domain setting] in `config.php`, on the target server. diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/migrating_to_kiteworks.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/migrating_to_kiteworks.adoc deleted file mode 100644 index 8aaddfd..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/migrating_to_kiteworks.adoc +++ /dev/null @@ -1,497 +0,0 @@ -= Migrating to Kiteworks Private Data Network -:toc: right -:toclevels: 3 -:description: Kiteworks offers a great software stack keeping your shared data completely fenced, secured and monitored. It offers additional features ownCloud does not provide. This guide describes how to migrate an ownCloud instance to a https://www.kiteworks.com[Kiteworks Private Data Network (PDN)]. - -== Introduction - -{description} - -See the image below to get an overview of the building blocks of both sides. - -{empty} + - -image::maintenance/migrate_kiteworks/kiteworks-migration.drawio.svg[Migrate to Kiteworks Overview, width=500] - -== Overview - -The migration works with an app to be installed on the ownCloud side. The app is provided by ownCloud as part of the guided migration. Please contact {oc-support-url}[ownCloud support] to get it. Both sides need to be fully configured and running, have a defined minimum release installed and are reachable from each other. If release requirements are not satisfied, you MUST upgrade first. - -The migration process consists of these steps: - -* Prepare the environment. -* Verify upcoming migration steps. -* Run the migration. - -For the planning, the ownCloud instance can stay productive during the migration process. Migration can be interrupted and restarted. For the last step, which is migrating shares, you must put the instance into maintenance mode to have a clean final transfer. Afterwards you can finally shut down the ownCloud instance. - -=== Migrated Items - -The following items will be migrated. In some cases, special rules apply as noted: - -* Ordinary users: + -At Kiteworks, the email address will be used as the user name. If the user data already exists in Kiteworks, it will not be overwritten. - -* Guest users: + -Will be translated into Kiteworks user profile `restricted`. - -* Disabled users: + -Disabled users cant login, but may contain shares to be migrated. - -* The content of the users home directory: + -The data of the home directory can be encrypted. In that case, data will be gathered, decrypted and transferred via a secured channel to the Kiteworks instance. - -* User shares received: + -As long as they reference content from another user's home. - -* User shares granted: + -As long as they reference content from the user's home. A share where all permissions are already granted thru a parent folder are considered redundant and are not created. - -* Share permissions: + -Will be translated into Kiteworks predefined roles. - -=== Items Excluded from the Migration - -The following items are NOT migrated. These items need to be migrated manually: - -* External mounts such as: + -`WND`, `SMB`, `Google Drive`, etc. + -This includes admin mounts and user created mounts. See the xref:external-mount-points[ownCloud prerequisites] section for a special note. - -* S3 primary object store (S3 for the users home) cannot be migrated for the time being: -+ --- -IMPORTANT: If you have configured S3 primary as your storage location for the users home, get in touch with {oc-support-url}[ownCloud support]. --- - -* Federated shares: + -Federated shares are, in terms of data migration, like special external mounts, see above. - -* Public links: + -They are not supported on Kiteworks and skipped during the migration process. - -* Passwords: + -User passwords will not be migrated. Newly created users must reset their passwords after the migration to create new ones. - -== Limitations - -The following limitations impact the migration process: - -* The ownCloud migration app is only functional on `amd64` platforms. - -* While ownCloud fully respects letter casing for file and folder names, Kiteworks does not distinguish casing. If case conflicts happen during the migration process, a migration log file describing rclone responses and casing conflicts for files or directories is created. The ownCloud admin must resolve the conflicts to finalize the migration. For details see the xref:migration[Migration] description. - -* When group shares have been defined, groups will not get created in Kiteworks. Instead, each member of the group will get an individual user share to the object shared. - -* In ownCloud, users can login either using their display name, login name or email address. Kiteworks only allows login using the email address. The presence of the users email address in ownCloud, which must be unique, is therefore a mandatory requirement. - -== Conceptual Differences - -There are some conceptual differences between the products. See the list below for important ones _affecting the migration_ where the difference to ownCloud, if not otherwise stated, is highlighted. This list will help to identify topics addressing files, folders and shares after the migration. Note that this section does not cover using the Kiteworks instance. - -* Kiteworks cannot have files in the top level of a user's home, only folders. + -The migration process will therefore copy the entire hierarchy of the ownClouds user home into a folder named `ownCloud` on the Kiteworks users top level data structure. - -* Kiteworks handles expiry dates for shares created differently. During a migration, expiry dates for ownCloud shares are ignored. - -* Shares on the ownCloud side that have been rejected by the share receiver are still potential active shares as they can be accepted at any time. This means that these shares are also migrated and the receiving share user will see them on the Kiteworks side. - -* In Kiteworks, received shares are shown at: -** *Individually shared files*: + -in the `Shared with me` sidebar, not in the main file view. -** *Folders*: + -in the main files view (outside of the ownCloud folder tree), but not in the `Shared with me` sidebar. - -* The filesystem on the Kiteworks side is _case-insensitive_. -** Filename conflicts can happen during migration, and a migration log will list issues that must be solved by the admin. - -* Kiteworks has the following files and folder naming rules: -** File and folder names cannot contain the following characters: `*?:"/\|<>`. -** Folder names can't begin or end with a period. - -+ -These rules are ineffective during the migration and this helps to complete it. But it may result in syncing issues to Windows clients. Affected files and folders can be renamed by the user. Naming rules will then be enforced. - -== Prerequisites - -To be prepared for the migration, both sides need to match the prerequisites. Please read this section carefully. - -=== ownCloud - -[IMPORTANT] -==== -* As a major prerequisite, the ownCloud instance *must* be running on release 10.14 or higher. If this requirement is not met, migration cannot be started as the necessary app checks the minimum version. - -* For all migration steps, the ownCloud instance must run in normal operation mode. Migration is not possible if ownCloud is in maintenance mode. - -* *Shell/SSH access to your server running ownCloud* is required. + -`occ` commands need to be issued. - -* The *ownCloud-provided _migrate-to-kiteworks_ app must be installed* at the ownCloud instance: -** This app comes bundled with its own and independent copy of rclone. -** See the xref:installation/apps_management_installation.adoc[Installing and Managing Apps] documentation for more details respecively the section xref:installing-required-components[Installing Required Components] below. - -* All users must have an email address and they must be unique. + -The `occ migrate:to-kiteworks:verify` step will point out missing email addresses. These must be rectified before any migration can start. - -* The ownCloud config setting xref:configuration/server/config_sample_php_parameters.adoc#override-cli-url[overwrite.cli.url] must exist and have a value. This config key is typically added and configured during setup. The `occ migrate:to-kiteworks:verify` step will check for this config setting. The value must match the ownCloud installation. - -* We recommend installing and enabling, if not already present and enabled, the {oc-marketplace-url}/apps/impersonate[Impersonate] app. This app can be used for example to solve file and folder case conflicts that can be reported during the migration process. -==== - -==== Installing Required Components - -In all examples using the `occ` command we assume, that ownCloud is installed at `/var/www/owncloud`. Adapt the path according to your environment. - -* You must install and enable the migration app. -** First, copy the app into the ownClouds `apps` or `apps-external` folder, preferably the latter, if it exists. -** Set the correct user and group permissions according to your environment. -** Finally, enable it with the following command: -+ -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - app:enable migrate_to_kiteworks ----- - -==== External Mount Points - -External mount points are not part of the automatic migration. See the following notes for a manual migration: - -* To migrate any external mount, the https://www.kiteworks.com/enterprise-connect/[Kiteworks Enterprise Connect] license is required. -* If an external mount is encrypted, it must be decrypted first. -* Follow the Kiteworks instructions to (re)connect an external mount. -* Federated shares need, by their nature, individual treatment, no general advice can be given. - -For ease of migrating external mounts, the admin should: - -* For admin created mounts, make a list of mounts with their settings and their sharing configuration. -* For user created external mounts, the administrator is responsible to instruct users how to migrate, including how to re-setup sharing. - -=== Kiteworks - -* The following major prerequisites apply: - -** The Kiteworks instance *must* be running version 8.6 or higher. -** Kiteworks requires a `Data migrator` license. - -* You need to login into the Kiteworks appliance as role *System Admin*. -// The kiteworks satellite service must be activated and available to the system admin user account. - -* The Kiteworks system must provide sufficient disk space for the data to be migrated. The ownCloud xref:migration-verification[occ migrate:to-kiteworks:verify] step will report the estimated disk space needed. - -* Ensure quota is set to unlimited in the Kiteworks user profiles. - -* The restricted user profile, or the user profile which shall be used _to map guest users to_, has to enable the btn:[Collaborator] role for menu:File Sharing Roles That Can Be Assigned to Users in This Profile[]. Click the image for more details. -+ -image:maintenance/migrate_kiteworks/kiteworks-users-collaboration.png[Kiteworks File Sharing Roles That Can Be Assigned to Users in This Profile, width=100] - -* Set the web application firewall (WAF) to `report only` so that file uploads are not blocked during migration. Kiteworks support will help to configure the WAF. - -* If it is planned to integrate Kiteworks into LDAP: -+ --- -IMPORTANT: We recommend having the Kiteworks PDN connected and configured to an LDAP server _before_ starting the migration. This will avoid conflicting user entries that will exist in the local database additionally to the LDAP server connected. -// New user accounts will be created during the migration, as needed. Existing user accounts will be used. --- - -* If it is planned to use a virus scanner in Kiteworks: -+ --- -IMPORTANT: We recommend having the Kiteworks PDN configured using a virus scanner _before_ starting the migration. This way, infected files that have not been covered by ownCloud will be put under quarantine already during migration. --- - -* In the Kiteworks Admin Console, navigate to menu:Application Setup[Client and Plugins > API]. Then click btn:[Create Custom Application]: -+ -image:maintenance/migrate_kiteworks/kiteworks-api-settings.png[Kiteworks create a new custom application, width=300] -+ -For the settings, use the following: - -** Use a speaking name -** Check btn:[Authorization Code] -** The btn:[Access Token Lifetime] can be set to the default value. -** Set the btn:[Redirect URI] to the default example value as shown when clicking into the field. + -Note, the redirect URI is not used, entering the default example is therefore ok. -* On the next page, API Scopes are all grayed out by default. -** Enable CREATE, READ, UPDATE, DELETE for the entities `Files` and `Folders`. -** Now click the btn:[Add Application] -* You will get a: -** Client application ID -** Secret key + -Note that you only see the secret once, remember it! - -+ -These two values are needed to initialize the xref:migration-initialization[ownCloud migration app]. - -Finally, you have the following Kiteworks values that are needed for the next steps. In the upcoming examples, the following names represent the corresponding values: - -* Host name or IP address + -`KW_HOST` - -* Admin users email address + -`KW_ADMIN_USER` - -* Client application ID + -`KW_APPLICATION_ID` - -* Secret key + -`KW_SECRET` - -NOTE: Consider saving `KW_ADMIN_USER` as shell variable for ease of use in the following commands. - -== Migration Steps - -After the above prerequisites have been met, the migration process can be started. The process has the following steps: - -* Initialization -* Verification -* Migration -** Migrate users -** Migrate files -** Migrate shares -** Disable users - -NOTE: Both the verification and migration commands need the initialisation step upfront to properly communicate with the Kiteworks instance. - -Details for commands used can be found in the xref:configuration/server/occ_command.adoc#migrate-to-kiteworks[Migrate to Kiteworks] occ command description. - -=== Migration Initialization - -The migration initialization is a mandatory step and will generate required data to create a so-called "Satellite" - a trusted partner - on the Kiteworks instance. Use the following command to start migration initialization: - -[source,bash] ----- -sudo -u www-data php \ - /var/www/owncloud/occ \ - migrate:to-kiteworks:init \ - KW_HOST \ - KW_APPLICATION_ID \ - "KW_SECRET" ----- - -There are two possible outputs, and each one is printed on the console: - -* A JSON file with the printed name is generated in the ownCloud root folder. You can use it directly for the required steps on the Kiteworks side, or -* If the file cannot be generated due to write restrictions on the file system, the content of the JSON file is printed. Then, you must generate the file manually, adapt the file name as required: -+ --- -Copy the output from the `occ` command and: - -[source,plaintext] ----- -open an editor of choice -paste the content copied -save the file such as 'kw-satellite.json' -exit the editor ----- --- - -Use this file to create a new satellite on the Kiteworks instance now. The satellite must be switched to STATUS btn:[ON] to enabled it. - -{empty} + - -[.center,width=80%,cols="^.^50%,^.^50%",options="header"] -|=== -a| Navigate to menu:System Setup[Satellite Servers] -a| Add a new Satellite - -a| image::maintenance/migrate_kiteworks/kiteworks-satellite.png[Kiteworks Satellites, width=300] -a| image::maintenance/migrate_kiteworks/kiteworks-new-satellite.png[Kiteworks add new Satellite, width=300] -|=== - -=== Migration Verification - -A migration *must* be verified upfront with a positive ready message as response. This command will also output a rough estimate of the required space capacity needed on the Kiteworks side. The verify command currently cannot report problematic file or folder names. These are reported only during the migration process. Note that any issue reported must be solved and a verification needs to be redone before the migration can start. - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-kiteworks:verify \ - $KW_ADMIN_USER ----- - -Here are some possible verification output examples: - -Example 1 - ready to migrate:: -+ -[source,plaintext] ----- -Activating the Kiteworks satellite .... -Verifying users ... - -Total disk storage: 13.4 MB - -Congratulations - this instance is ready to be migrated to Kiteworks! ----- - -Example 2 - failure:: -+ -[source,plaintext] ----- -Activating the Kiteworks satellite .... -Verifying users ... -No email for user alex - it cannot be migrated to Kiteworks! -Please make sure all users meet the requirements. -This instance is NOT ready to be migrated to Kiteworks! ----- - -=== Migration - -After all prerequisites, installations, configurations and the verification has passed, you can initiate the migration process. The migration is split into four parts which are: - -[,subs="+callouts,macros,attributes+"] ----- -1. Migrate users <1> -2. Migrate files <1> -3. Migrate shares <2> -4. Disable users <3> ----- -<1> These steps migrate all ordinary, guest and disabled users and files. You can rerun these steps to migrate any items that did not exist, or failed to migrate when the respective step was called. Note that the steps must be made in that order. -<2> This step is a *breaking change* and migrates all shares. When this step has run, the former steps cant be run again. -<3> This step finalizes the migration by disabling all users on Kiteworks that are disabled on ownCloud. - -The migration step transferring files will naturally take its time depending on the amount of data and bandwidth available. All other steps will complete relative quickly as only metadata is transferred. - -NOTE: All migration steps, especially files, can be interrupted harmlessly at any time. Starting a new migration run will continue where the previous one stopped. - -==== Migrate Users - -Issue the following command to start migrating users: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-kiteworks:users \ - $KW_ADMIN_USER \ - KW_PROFILE_GUEST (optional) ----- - -Note that you can optionally add a Kiteworks guest user profile that will be assigned to guest users defined in ownCloud when migrating. If this is not assigned, the default `restricted` will be used. - -The command does not require user interaction. It can be run e.g. as a screen session so that reported issues can be seen directly or as a background job. - -==== Migrate Files - -Issue the following command to start migrating files: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-kiteworks:files \ - $KW_ADMIN_USER ----- - -// For a possible improvement of transfer performance when migrating files, read the xref:tuning-transfer-performance[Tuning Transfer Performance] section below. - -The command does not require user interaction. It can be run e.g. as a screen session so that reported issues can be seen directly or as a background job. During the migration process, a log file named `migrate-kiteworks-files.csv` is created in the ownCloud root folder. This file contains: - -* General `rclone` responses and errors, -* `rclone` responses for user migration, -* File name case conflicts that an ownCloud admin must solve. - -If `rclone` errors at one point, it tries to finish running transfers but will stop afterwards. - -Example for migration issues reported:: -+ -[source,plaintext] ----- -Issues did arise when migrating files and folders. -Please review migrate-kiteworks-1712241364.csv and fix any issues which have been reported. - -Once resolved please re-run the migration process again. - -Migration will stop here now until no more conflicts exist. ----- - -Examples for case conflicts noted in the migration log file:: -+ -[source,plaintext] ----- -NOTICE,user1,user1@example.com,"2024/04/03 15:20:27 - NOTICE: Photos: Duplicate directory found in source - ignoring" - -NOTICE,user2,user2@example.com,"2024/04/03 15:20:32 - NOTICE: Documents/Example.odt: Duplicate object found in source - ignoring" ----- - -As you can see above, there is `Duplicate` notice for a file and another one for a directory name. `Duplicate` notices are logged for case conflicts. A conflict takes place because a file or directory that has been migrated earlier is in conflict with the name of the reported object. The conflicts for the particular users need to be resolved within ownCloud. When this is done, the migration can be restarted. `rclone` will compare both sides to identify already migrated objects and will continue with those objects that have not been migrated yet. - -==== Migrate Shares - -IMPORTANT: When running this command, you cant run the `migrate:files|users` command anymore! - -Issue the following command to start migrating shares: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-kiteworks:shares \ - $KW_ADMIN_USER ----- - -The command does not require user interaction. It can be run e.g. as a screen session so that reported issues can be seen directly or as a background job. During the migration process, a log file named `migrate-kiteworks-shares.csv` is created in the ownCloud root folder. - -==== Disable Users - -The migrate users step migrates all users as enabled users even they were disabled ownCloud users. This is needed so that a disabled user can provide shares. As a final step, run this command to disable users at Kiteworks that are disabled at ownCloud. - -Issue the following command to start disable users: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-kiteworks:disable-users \ - $KW_ADMIN_USER ----- - -The command does not require user interaction. It can be run e.g. as a screen session so that reported issues can be seen directly or as a background job. - -==== Solving Case Conflicts - -If there are case conflicts reported in the shell and/or the migration log, the ownCloud admin must solve them to continue the migration. - -For reported conflicts, the admin should impersonate the user with the conflict and solve it by renaming the file or directory according to the Kiteworks naming rules. After fixing all open issues, the migration can be restarted and all formerly conflicted files or folders will get migrated. - -//// -== Tuning Transfer Performance - -By default, rclone transfers 4 files in parallel. This creates little load on the target system, but may take a longer time to complete. This is especially true when anticipating mostly small files with sizes of about 10KB instead of large files with sizes of 10 MB or above. - -Performance can be tuned with the environment variable `RCLONE_TRANSFERS` which defines the number of concurrent file uploads. - -The following example command is using 16 parallel transfers: - -[source,bash] ----- -sudo -u www-data \ - RCLONE_TRANSFERS=16 \ - php /var/www/owncloud/occ \ - migrate:to-kiteworks:files \ - $KW_ADMIN_USER ----- - -Such a setting can greatly speed up the transfer of many small files, but can also lead to substantial load on the network and the target system. As a Kiteworks System Admin, it is recommended to monitor the menu:System[Status > Performance Details] pages: - -{empty} + - -[.center,width=80%,cols="^.^50%,^.^50%",options="header"] -|=== -| Data IO System Utilization -| CPU System Utilization - -a| image::maintenance/migrate_kiteworks/kiteworks-system-load-dataio.png[Kiteworks Performance Details DataIO, width=300] -a| image::maintenance/migrate_kiteworks/kiteworks-system-load-cpu.png[Kiteworks Performance Details CPU, width=300] -|=== - -The graphs show results from a test system. - -* The left half of the graphs show the default setting with 4 parallel transfers. -* The right half of the graphs first show `RCLONE_TRANSFERS=10`, then close to the end using `RCLONE_TRANSFERS=16` with peaking CPU usage at near 100%. -* During the last section, as shown in the graphs, 100 files (total of 8 MB) were uploaded per minute. The default setting would achieve only about 20 files per minute. -//// diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/migrating_to_ocis.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/migrating_to_ocis.adoc deleted file mode 100644 index cc51f28..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/migrating_to_ocis.adoc +++ /dev/null @@ -1,347 +0,0 @@ -= Migrating to ownCloud Infinite Scale -:toc: right -:toclevels: 3 -:description: This guide describes how to migrate an ownCloud Classic instance to ownCloud Infinite Scale (oCIS) using the migrate-to-ocis app and its occ commands. - -== Introduction - -{description} - -The migration transfers users, groups, files, and shares from an ownCloud Classic instance to a target oCIS instance in a series of sequential steps. The ownCloud Classic server is not modified by the migration — it remains operational throughout most of the process. - -== Overview - -The migration works with an app to be installed on the ownCloud Classic side. The app is provided by ownCloud as part of the guided migration. Please contact {oc-support-url}[ownCloud support] to get it. - -Both instances need to be fully configured and running, and they must be reachable from each other. - -The migration process consists of these steps: - -. User and Group Migration -. Preparing Data Migration -. Migrate Files and Shares - -The migration moves forward through these steps in order. Once a step has completed successfully, it cannot be repeated without deleting created data beforehand. If you need to start over, you can reset the migration with the `--force` flag on the `migrate:to-ocis:init` command. Note that data already migrated to the target oCIS instance will remain there, so the oCIS instance should be fresh and clean before resetting. - -=== What Is Migrated - -The following items are migrated: - -* Users and groups with their membership + -Either automatically or manually depending on the LDAP server used -* Files of enabled users from in each user's home directory (using rclone, which is bundled with the app) + -The data transferred is added to the users personal Space -* User shares, group shares, and link shares - -=== What Is Not Migrated - -The following items are NOT migrated: - -* Disabled users (the migration will skip them and continue) -* Files owned by disabled users -* Shares created by or targeting disabled users (an error is shown but the migration continues) -* Passwords — migrated users will have an unknown password and will need a password reset or onboarding process -* External mounts — this includes: -** Drives added by users -** Drives created by the admin and shared with users -** Shares pointing to external mount locations + -External mount data is excluded by the file migration step. These mounts must be recreated and their data migrated manually after the migration. - -== Notes - -* *User passwords*: Migrated users are created with an unknown password and cannot log in normally after migration. The admin must set up a temporary password or onboarding process for each user. - -* *Share link passwords*: Passwords for migrated share links will be unknown and will not match the original ownCloud Classic passwords. Users should change the passwords of all their share links after the migration. - -* *Passwordless share links*: By default, oCIS requires a password for share links. Passwordless links from ownCloud Classic will fail to migrate unless the oCIS policy is changed. Set the environment variable `OCIS_SHARING_PUBLIC_SHARE_MUST_HAVE_PASSWORD=false` on the oCIS instance before migration if you need to migrate passwordless links. - -== Prerequisites - -=== ownCloud Classic - -[IMPORTANT] -==== -* *Shell/SSH access to the ownCloud server* is required. All migration steps use `occ` commands. - -* The *ownCloud-provided _migrate-to-ocis_ app must be installed* on the ownCloud Classic instance: -** This app comes bundled with its own copy of rclone. -** See the xref:installation/apps_management_installation.adoc[Installing and Managing Apps] documentation for details. - -* All *enabled* users must have a valid email address, and email addresses must be unique across all enabled users. + -The `occ migrate:to-ocis:verify` step will report any users with missing or duplicate emails. These must be resolved before migration can proceed. - -* *Disabled users will not be migrated.* They will be skipped during the migration steps. -==== - -==== Installing Required Components - -In all examples using the `occ` command we assume that ownCloud is installed at `/var/www/owncloud`. Adapt the path according to your environment. - -* Install and enable the migration app: -** Copy the app into the ownCloud `apps` or `apps-external` folder. -** Set correct user and group permissions for your environment. -** Enable the app: -+ -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - app:enable migrate_to_ocis ----- - -=== oCIS - -See the https://doc.owncloud.com/[ownCloud Documentation] for how to setup an oCIS instance and more configuration details. - -[IMPORTANT] -==== -* The `auth-app` service must be enabled with _impersonation_ active. To do so, set the following environment variables for the oCIS instance: -+ -[source,plaintext] ----- -OCIS_ADD_RUN_SERVICES: "auth-app" -PROXY_ENABLE_APP_AUTH: true -AUTH_APP_ENABLE_IMPERSONATION: true ----- - -* An *app token must be created for the oCIS admin user* using the auth-app. This token, together with the admin username, is used as the username and password for all oCIS operations during the migration. - -* The oCIS instance should be *fresh and clean* before starting the migration. If the target instance already contains data, it may cause conflicts. -==== - -== User and Group Migration - -No data migration can be initiated until users and groups are available on the oCis side. To avoid a failing data migration step, no user or group changes, such as adding, deleting or changing, must be applied after this migration step. - -Different steps are required for the migration of users and groups, depending on their location in ownCloud Classic, to make them accessible to oCIS. - -Consider that the https://doc.owncloud.com/ocis/next/deployment/services/s-list/idm.html[internal IDM] provided by oCIS, which is a mini LDAP, has a very limited scope and is mainly targeted at small Infinite Scale installations or testing. It should therefore not be used in production environments. For larger setups or production environments, it is highly recommended to use a “real” LDAP server or to switch to an external Identity Management Solution instead. - -To address these different requirements, migrating users and groups are divided into separate sections. A combination of local and LDAP-based users is not supported. - -=== Migrate With Local Users - -These steps describe the migration of local ownCloud Classic users and groups to an external LDAP or to the embedded oCIS IDM - where no external LDAP is used. - -==== Migrate Local Users to LDAP - -If you have local users and groups in ownCloud Classic and wish to use an external LDAP server that oCIS is connected to — which is highly recommended for production environments — you must migrate these users and groups manually before proceeding to the xref:#migrate-files-and-shares[Migrate Files and Shares] section. Please note that user and group names must match. Check the additional requirements in xref:#migration-with-ldap-users[Migration With LDAP Users]. - -As the next step, continue with xref:#preparing-data-migration[Preparing Data Migration]. - -==== Migrate Local Users to IDM - -Migrate ownCloud Classic users and groups to oCIS internal IDM, no extrernal LDAP server used. As a prerequisite, run the steps in xref:#preparing-data-migration[Preparing Data Migration] first. - -Migrate Users:: -+ --- -The admin password is asked interactively: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:migrate:users admin ----- - -New users are created in oCIS to match the ownCloud Classic users. If a user already exists in oCIS (for example the `admin` account), the existing account will be reused. --- - -Assign a Role:: -+ --- -Assign a role to all migrated users. Available roles are fetched from the oCIS instance and the role to assign is selected interactively: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:assign-role admin ----- - -The same role is assigned to all migrated ownCloud Classic users, except the oCIS admin. ownCloud Classic roles are not preserved during migration — all users receive a single role regardless of their original ownCloud Classic role. For most installations the `User` role is the appropriate choice. - -NOTE: ownCloud Classic admin users who are members of the ownCloud Classic `admin` group will have that group membership migrated to oCIS, but they will not receive oCIS admin privileges unless the assigned role grants them. The oCIS admin must manually set the appropriate oCIS role for any user that should have elevated permissions after migration. + -ownCloud Classic subadmin privileges have no equivalent role in oCIS and are not migrated. - -This step is mandatory and cannot be skipped. --- - -Migrate Groups:: -+ --- -Migrate the ownCloud Classic groups and their user memberships to oCIS. The admin password is asked interactively: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:migrate:groups admin ----- - -If a group already exists in oCIS, the existing group will be reused. Users not found in oCIS (for example because they were disabled and not migrated) will be skipped, but this will not stop the migration. --- - -As the final step, continue with xref:#migrate-files-and-shares[Migrate Files and Shares]. - -=== Migration With LDAP Users - -In general, users and groups must be accessible to oCIS. This can be achieved either connecting oCIS to the same LDAP server, or by migrating users and groups from the LDAP server that ownCloud Classic is connected to to a different backend for oCIS. - -The following procedures are necessary for the data migration to be possible. - -ownCloud Classic Requirements:: -+ --- -In addition to the regular requirements: - -* LDAP users *must* have the email attribute set (LDAP wizard -> Advanced tab -> Email field; usually `mail`). -* The username attribute should be set to the `uid` or `samAccountName` attribute. By default, the internal username attribute (usually `entryUUID` / `objectGUID`) is used, which is typically incorrect for migration. + -Run the following to change the attribute to `uid` and re-sync users afterwards: -+ -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - ldap:set-config '' ldapUserName uid ----- --- - -oCIS Requirements:: -+ --- -In addition to the `auth-app` requirements, verify the following oCIS environment variables: - -* `OCIS_LDAP_USER_ENABLED_ATTRIBUTE` + -The environment variable must exist and not be false. The default value uses the ownCloud schema which is unlikely to be present in your LDAP. -* `OCIS_LDAP_USER_SCHEMA_ID` and `OCIS_LDAP_GROUP_SCHEMA_ID` + -These environment variables should be set appropriately (for example `entryUUID`). -* `OCIS_ADMIN_USER_ID` + -The ID of the user that should receive admin privileges. - -The following environment variables serve as a configuration template: - -[source,plaintext] ----- -OCIS_LDAP_INSECURE: "true" - -OCIS_LDAP_URI: ldap://10.0.2.27:14141 -OCIS_LDAP_BIND_DN: "cn=admin,dc=owncloudqa,dc=com" -OCIS_LDAP_BIND_PASSWORD: owncloud123 - -OCIS_LDAP_GROUP_BASE_DN: "ou=groups,dc=owncloudqa,dc=com" -OCIS_LDAP_GROUP_FILTER: "(objectclass=groupOfNames)" -OCIS_LDAP_GROUP_OBJECTCLASS: "groupOfNames" - -OCIS_LDAP_USER_BASE_DN: "ou=people,dc=owncloudqa,dc=com" -OCIS_LDAP_USER_FILTER: "(objectclass=inetOrgPerson)" -OCIS_LDAP_USER_OBJECTCLASS: "inetOrgPerson" - -OCIS_LDAP_USER_ENABLED_ATTRIBUTE: "employeeType" -IDP_LDAP_LOGIN_ATTRIBUTE: "uid" - -OCIS_LDAP_GROUP_SCHEMA_ID: "entryUUID" -OCIS_LDAP_USER_SCHEMA_ID: "entryUUID" -OCIS_ADMIN_USER_ID: "a73c6ea6-6e7c-103f-8110-dd19ecb0bb36" - -GRAPH_ASSIGN_DEFAULT_USER_ROLE: "true" ----- - -Verify LDAP access is working before starting the migration by logging in with some LDAP users. --- - -As the next step, continue with xref:#preparing-data-migration[Preparing Data Migration]. - -== Preparing Data Migration - -After the user, group and role prerequisites are met, the migration can be started. Details for the occ command can be found in the xref:configuration/server/occ_command.adoc#migrate-to-ocis[Migrate to oCIS] occ command reference. - -Initialize:: -+ --- -Initialize the migration by pointing to the target oCIS instance. The host and the `--insecure` flag (if used) are stored and reused for all subsequent steps: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:init \ - ocis.server.example ----- - -Use `-k` or `--insecure` to ignore the SSL certificate of the oCIS instance if required: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:init -k \ - ocis.server.example ----- - -Use `-f` or `--force` to reset a previous migration and start from the beginning. Ensure the target oCIS instance is clean before resetting: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:init -f \ - ocis.server.example ----- --- - -Verify:: -+ --- -Verify that the ownCloud Classic installation is ready for migration. This checks that all enabled users have valid, non-duplicate email addresses: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:verify ----- - -Disabled users will be shown in the verification output but will not stop the migration. If a disabled user needs to be migrated, enable them before running this step — or reset the migration and re-verify. - -You can skip this step with `--skip`, but you take full responsibility for any email-related problems during migration. --- - -== Migrate Files and Shares - -=== Migrate Files - -Migrate each user's files to oCIS using the rclone binary bundled with the app. oCIS impersonation is used to access each user's account. The admin password is asked interactively: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:migrate:files admin ----- - -Each user's home directory contents are migrated into that user's *personal Space* in oCIS. External mounts and received shares are excluded — only files owned by the user in their ownCloud Classic home are transferred. - -The following users are skipped and will not cause the migration to stop: - -* Users that have never logged in (they have no files to migrate). -* Users not found in oCIS (typically disabled users that were not migrated). - -=== Migrate Shares - -Migrate all user shares, group shares, and link shares. oCIS impersonation is used to access each user's account. The admin password is asked interactively: - -[source,bash] ----- -sudo -u www-data \ - php /var/www/owncloud/occ \ - migrate:to-ocis:migrate:shares admin ----- - -The same users are skipped as in the file migration step. The following share errors will be reported but will not stop the migration: - -* Shares pointing to missing users or groups (that were not migrated). -* Link shares that fail due to password restrictions. - -For password-protected link shares: the share will be migrated with a new password that does not match the original ownCloud Classic password. Users should change the passwords of all their share links after migration. diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/database_upgrade.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/database_upgrade.adoc deleted file mode 100644 index e526f03..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/database_upgrade.adoc +++ /dev/null @@ -1,90 +0,0 @@ -= Database Upgrade -:toc: right -:upgrade-mariadb-url: https://mariadb.com/kb/en/upgrading/ -:compressed-row-format-url: https://mariadb.com/kb/en/innodb-compressed-row-format/#read-only - -== Introduction - -Usually, when upgrading a database, follow the guides the vendor provides. You may also take a look at the xref:installation/manual_installation/manual_installation.adoc#install-a-database[Install a Database] section for general notes. - -This document supports an upgrade in case there are prerequisites and/or special steps to be taken to upgrade to a particular database version. - -== Upgrading to MariaDB 10.6+ - -ownCloud runs fine when using a MariaDB version lower than 10.6. You can upgrade ownCloud as usual without special considerations regarding the database. - -When planning to upgrade to MariaDB 10.6, some prerequisites have to be met and upgrade steps have to be taken. - -This is mostly due to the fact that, unlike before, in MariaDB 10.6 _tables of the COMPRESSED row format are read-only by default_. For more information see the {compressed-row-format-url}[InnoDB COMPRESSED Row Format] document. - -NOTE: This process only needs to be carried out once. - -=== Overview - -. You must have upgraded your ownCloud installation to version 10.9 or above. To do so, follow the -xref:maintenance/upgrading/manual_upgrade.adoc[Manual ownCloud Upgrade] guide. - -. Backup your ownCloud installation, especially the database to rollback in case of issues. To do so, follow the -xref:maintenance/backup_and_restore/backup.adoc[Backing up ownCloud] guide. - -. Prepare the database for the upgrade with an xref:configuration/server/occ_command.adoc#restore-the-table-format[occ command]. - -. Follow the respective {upgrade-mariadb-url}[Upgrading MariaDB] guide to upgrade MariaDB. - -=== Detailed Upgrade Steps - -. If not already done, upgrade the xref:maintenance/upgrading/manual_upgrade.adoc[ownCloud installation] to version 10.9 or above. - -. Set ownCloud in maintenance mode -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --on ----- - -. Prevent browser access + -+ -Stop your web server to prevent users from trying to access ownCloud via the web. As an alternative, you can stop serving the virtual host for ownCloud. -+ -Stop the web server: -+ -[source,bash] ----- -sudo service apache2 stop ----- - -. Run an occ command to prepare the database for the upgrade -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} db:restore-default-row-format ----- - -. Upgrade MariaDB to version 10.6+ -+ --- -Follow the instructions in the respective {upgrade-mariadb-url}[Upgrading MariaDB] guide to upgrade MariaDB. + -If required, run the `mysql_upgrade` command when using a binary installation or as example - -[source,bash] ----- -docker-compose exec owncloud mysql_upgrade -uroot -p ----- - -when using a dockerized environment as part of the upgrade procedure. --- - -. Set ownCloud back to normal operation mode: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -. Enable browser access + -Start your web server, Alternatively, enable the virtual host serving ownCloud again: -+ -[source,bash] ----- -sudo service apache2 start ----- diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/manual_upgrade.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/manual_upgrade.adoc deleted file mode 100644 index c5a33b3..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/manual_upgrade.adoc +++ /dev/null @@ -1,350 +0,0 @@ -= Manual ownCloud Upgrade -:toc: right -:toclevels: 2 -:description: This document describes how to manually upgrade your ownCloud installation. Because installations can vary, this guide can only give an overview of methods and examples. -:page-aliases: maintenance/manual_upgrade.adoc - -== Introduction - -{description} These examples need to be adapted according your needs and your environment. - -NOTE: This guide assumes that you have basic knowledge about Unix terminology, commands and concepts. In case you are not familiar with these, ownCloud highly recommends that you create a playground first to try the steps and/or get in touch with ownCloud support to avoid breaking your system or losing data. - -NOTE: This guide covers the upgrade of the ownCloud instance only. When planning to update/upgrade your server environment or server packages, read the xref:installation/manual_installation/manual_installation.adoc[Detailed Installation Guide] first to match the prerequisites. - -After preparing the upgrade, you can decide between two ways of upgrading your instance: - -.Script-Guided Upgrade -This upgrade automates most of the tasks to be done including setting the correct ownership and permissions. - -.Manual Step-by-Step Upgrade -Using this type of upgrade, you have to do all the steps manually but you can also handle special setups. - -NOTE: In this description we assume that your ownCloud installation was located in the default directory: `/var/www/owncloud` and the new release will reside there as well. The path might differ, depending on your installation. - -== General Preparation - -There are several steps necessary before you can start with upgrading your ownCloud instance. - -=== Enable Maintenance Mode - -Put your server in xref:maintenance/enable_maintenance.adoc[maintenance mode] and *disable* xref:configuration/server/background_jobs_configuration.adoc#cron-jobs[Cron jobs]. -Doing so prevents new logins, locks the sessions of logged-in users, and displays a status screen so that users know what is happening. - -TIP: In a clustered environment, check that all nodes are in maintenance mode. - -=== Prevent Browser Access - -With those steps completed, stop your webserver to prevent users trying to access ownCloud via the web. As an alternative, you can stop serving the virtual host for ownCloud. - -Stop the web server: -[source,bash] ----- -sudo service apache2 stop ----- - -=== Backup the Database - -First, backup ownCloud and the server database as described in section xref:maintenance/backup_and_restore/backup.adoc[Backing up ownCloud]. This is independent of the next upgrade steps but important in case something goes wrong. - -=== Review Third-Party Apps - -Review any installed third-party apps for compatibility with the new ownCloud release. -Ensure that they are all disabled before beginning the upgrade. -Third party apps are all apps that are not distributed by {oc-marketplace-url}/publishers/owncloud[ownCloud] -or not listed in xref:installation/apps_supported.adoc[Supported Apps in ownCloud]. - -. Disable Apps via Command Line -+ -This command lists all apps by and app version: -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:list ----- -+ -This command disables the app with the given : -+ -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:disable ----- - -. Disable via Browser + -Go to menu:Settings[Admin > Apps] and disable all third-party apps. - -=== Backup Manual Changes in `.htaccess` - -If you have made changes in `.htaccess` located at the webroot of ownCloud, you must backup these changes. Only backup the changes made but not the complete file as this file will be recreated on upgrades and may contain different settings provided by ownCloud. Manual changes in `.htaccess` can be necessary when you e.g. xref:configuration/integration/ms-teams.adoc[Integrate ownCloud into Microsoft Teams] or fixing WebDav connection errors as xref:troubleshooting/general_troubleshooting.adoc#error-0x80070043-the-network-name-cannot-be-found-while-adding-a-network-drive[The network name cannot be found] on Windows. - -=== Backup Manual Changes in `.user.ini` - -If you have made changes in `.user.ini` located at the webroot of ownCloud, you must backup these changes. - -=== Download the Latest Release - -Download the latest {oc-complete-base-url}/{oc-complete-name}.tar.bz2[ownCloud Classic release] to the same location where your previous instance is located, in this example the default directory `/var/www/`. - -[source,bash,subs="attributes+"] ----- -cd /var/www/ -sudo wget {oc-complete-base-url}/{oc-complete-name}.tar.bz2 ----- - -== Script-Guided Upgrade - -When using the script-guided upgrade, the script from the xref:installation/manual_installation/manual_installation.adoc#script-guided-installation[Script-Guided Installation] is used. This script can not only **install** a new instance of ownCloud, but also **upgrade** an existing one or can **manage ownership and permissions**. When using the script for upgrading, the script renames the current instance and creates a new instance, copies `config.php` set ownership and permissions etc. - -The script xref:installation/manual_installation/script_guided_install.adoc#script-questions[asks questions] and beside other parameters, the *upgrade an existing installation* question is selected. - -Follow the script documentation for details on how to install and use it. - -NOTE: The script is most convenient if you use links for your `apps-external` and your `data` directory, as it takes care of recreating the links. You will be asked about this when you run the script. If you're using regular directories, these are created, but content must be moved or copied manually before finalizing the upgrade. If you aren't using the `apps-external` directory, you must manually take care of copying only those apps which are not part of the new source. - -When the script has finished, continue with the xref:finalize-the-upgrade[Finalize the Upgrade] step described below. - -NOTE: When using the script, any manual changes in `.htaccess` or `.user.ini` must be manually transferred from the backup directory the script created to the actual instance directory. - -After the upgrade is finished, you can re-run this script to secure the `.htaccess` files. - -== Manual Step-by-Step Upgrade - -Note that this procedure is not an in-place upgrade but an upgrade to a new directory identically named as originally set. This ensures that no code or settings can get orphaned or overwritten. - -=== Move Current ownCloud Directory - -Although you have already made a backup, move your current ownCloud directory to a different location for easy later access: - -This example assumes Ubuntu Linux and MariaDB, rename the ownCloud directory: -[source,bash] ----- -sudo mv /var/www/owncloud /var/www/backup_owncloud ----- - -=== Extract the New Source - -Extract the new server release in the location where your previous ownCloud installation used to be. - -[source,bash,subs="attributes+"] ----- -sudo tar -xf {oc-complete-name}.tar.bz2 ----- - -=== Copy the data/ Directory - -If you keep your `data/` directory _inside_ your `owncloud/` directory and you have not linked it, move it from your old version of ownCloud to your new version: - -[source,bash] ----- -sudo mv /var/www/backup_owncloud/data /var/www/owncloud/data ----- - -If you have linked the data directory, for ownCloud it is still inside the `owncloud` directory and you have to re-link it. - -If you keep your `data` **outside** of your `owncloud` directory, then you don’t have to do anything with it, because its location is configured in your original `config.php`, and none of the upgrade steps touch it. - -=== Copy Relevant config.php Content - -With the new source files now in place of where the old ones used to be, copy all `\*config.php` and `*.json` files (if any exist) from your old ownCloud directory to your new ownCloud directory: - -[source,bash] ----- -sudo cp /var/www/backup_owncloud/config/*config.php \ - /var/www/owncloud/config/ ----- - -[source,bash] ----- -sudo cp /var/www/backup_owncloud/config/*.json \ - /var/www/owncloud/config/ ----- - -=== Market and Marketplace App Upgrades - -Before getting too far into the upgrade process, consider how the Market app and its configuration options affect the upgrade process. The Market app — and other apps from the Marketplace — will not be updated when you upgrade ownCloud if `upgrade.automatic-app-update` is set to `false` in config.php. - -In addition, if there are installed apps (whether compatible or incompatible with the next version, or missing source code) and the Market app is enabled but there is no internet connection available, these apps will need to be manually updated once the upgrade is finished. - -=== Copy Old Apps - -If you are using third party or enterprise applications, look in your new `/var/www/owncloud/apps/` or `/var/www/owncloud/apps-external/` directory to see if they are present. If not, copy them from your old instance to your new one. - -NOTE: Make sure that all app directories that are defined in the `apps_paths` section of your `config.php` file do exist in your new `/var/www/owncloud/` directory. Also, make sure, that all app directories listed in `apps_path` actually exist. If `occ` complains about missing `apps-external` then try: - -[source,bash] ----- -sudo mkdir /var/www/owncloud/apps-external ----- - -=== Permissions - -To finalize the preparation of the upgrade, you need to set the correct ownership and permissions of the new ownCloud files and folders. - -.Set correct ownership -Set the ownership for all files and folders to `root:www-data` **except** the `config` and `data` directory: - -[source,bash] ----- -sudo find -L /var/www/owncloud \ - \( -path ./data -o -path ./config \) -prune -o \ - -type d -print0 | sudo xargs -0 chown root:www-data ----- - -[source,bash] ----- -sudo find -L /var/www/owncloud \ - \( -path ./data -o -path ./config \) -prune -o \ - -type f -print0 | sudo xargs -0 chown root:www-data ----- - -Set the ownership for all files and folders to `www-data:www-data` for the `config`, `data` and `apps` directories. Note that it is not mandatory to set the ownership of the `data/` directory as it should already have the correct ownership and it can take a while to finish, depending on the size: - -[source,bash] ----- -sudo chown -R www-data:www-data /var/www/owncloud/config -sudo chown -R www-data:www-data /var/www/owncloud/data -sudo chown -R www-data:www-data /var/www/owncloud/apps* ----- - -.Set correct permissions -Use `chmod` on files and directories with different permissions: - -* For all files use `0640` -+ -[source,bash] ----- -sudo find -L /var/www/owncloud -type f -print0 | sudo xargs -0 chmod 640 ----- - -* For all directories use `0750` -+ -[source,bash] ----- -sudo find -L /var/www/owncloud -type d -print0 | sudo xargs -0 chmod 750 ----- - -* Set the occ command to executable: -+ -[source,bash] ----- -sudo chmod +x /var/www/owncloud/occ ----- - -If you have configured a script for xref:installation/manual_installation/script_guided_install.adoc[guided installations], you can use it for this step as well as it automates it. - -== Finalize the Upgrade - -=== Start the Upgrade - -With the apps disabled and ownCloud in maintenance mode, start the xref:configuration/server/occ_command.adoc#command-line-upgrade[upgrade process] from the command line. Note that the example is based on Ubuntu Linux. Execute this within the ownCloud root folder. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} upgrade ----- - -The upgrade operation can take anywhere from a few minutes to a few hours, depending on the size of your installation. When it is finished you will see either a success message or an error message that indicates why the process did not complete successfully. - -== Reapply Manual Changes - -Reapply any manual changes made to `.htaccess` files and the `.user.ini` file located in the owncloud webroot. - -The following example command eases to find the differences of two files, which is helpful for reapplying manually added changes to `.htaccess` and `.user.ini`. Replace that paths, directories and files accordingly. - -[source,bash] ----- -diff -y -W 70 --suppress-common-lines owncloud/.user.ini owncloud_2022-02-15-09.18.48/.user.ini ----- - -[source,plaintext] ----- -post_max_size=513M | post_max_size=1G ----- - -=== Strong Permissions - -* Check that `chmod` with `0640` for `.htaccess` and `.user.ini` files has been applied. - -If you have configured a script for xref:installation/manual_installation/script_guided_install.adoc[guided installations], you can use it for this step as well as it automates it. - -=== Disable Maintenance Mode - -Assuming your upgrade succeeded, disable maintenance mode using the occ command. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -=== Enable Browser Access - -With all that done, restart your web server, or alternatively re-enable the virtual host serving ownCloud: - -[source,bash] ----- -sudo service apache2 start ----- - -=== Check the Upgrade - -With maintenance mode disabled and the web server running, log in via the web interface and perform the following steps: - -. Check that the version number reflects the new installation. + -It can be reviewed at the bottom of menu:Settings[Admin > General]. -. Check that your other settings are correct. -. Go to the menu:Settings[Admin > Apps] page and review the core apps to make sure the right ones are enabled. -. After the upgrade is complete, re-enable any third-party apps that are compatible with the new release. Use `occ app:enable ` or go to menu:Settings[Admin > Apps > "Show disabled apps"] and enable all compatible third-party apps. - -WARNING: Install or enable unsupported apps at your own risk. - -== Rollback - -If you need to rollback your upgrade, see the xref:maintenance/backup_and_restore/restore.adoc[Restoring ownCloud] documentation. - -== Troubleshooting - -When upgrading ownCloud and you are running MySQL or MariaDB with binary logging enabled, your upgrade may fail with these errors in your MySQL/MariaDB log: - ----- -An unhandled exception has been thrown: -exception 'PDOException' with the message 'SQLSTATE[HY000]: General error: 1665 -Cannot execute statement: impossible to write to binary log since -BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to -row-based logging. InnoDB is limited to row-logging when transaction isolation level -is READ COMMITTED or READ UNCOMMITTED.' ----- - -Please refer to xref:configuration/database/linux_database_configuration.adoc#mysql-mariadb[MySQL / MariaDB ] on how to correctly configure your environment. - -In the unlikely case that files do not show up in the web-ui after the upgrade, use the xref:configuration/server/occ_command.adoc#the-filesscan-command[files:scan command] to make them visible again. -Here is an example of how to do so: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} files:scan --all ----- - -See the {oc-help-url}[Docs & Guides page] for further resources for both home and enterprise users. - -Sometimes, ownCloud can get _stuck in an upgrade_. -This is usually due to the process taking too long and running into a PHP time-out. -Stop the upgrade process this way: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:mode --off ----- - -Then start the manual process: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} upgrade ----- - -If this does not work properly, try the repair function: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:repair ----- diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/marketplace_apps.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/marketplace_apps.adoc deleted file mode 100644 index 9cd54ff..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/marketplace_apps.adoc +++ /dev/null @@ -1,28 +0,0 @@ -= Upgrade Marketplace Applications -:toc: right -:page-aliases: go/admin-marketplace-apps.adoc, upgrading/marketplace_apps.adoc - -== Introduction - -To upgrade Marketplace applications, please refer to the documentation -below, as applicable for your ownCloud setup. - -== Single-Server Environment - -To upgrade Marketplace applications when running ownCloud in a single server environment, you can use xref:configuration/server/occ_command.adoc#apps-commands[the Market app], specifically by running `market:upgrade`. -This will install new versions of your installed apps if updates are available in the marketplace. - -NOTE: The user running the update command, which will likely be your webserver user, needs write permission for the `/apps` folder. If they don’t have write permission, the command may report that the update was successful, however it may silently fail. - -== Clustered / Multi-Server Environment - -xref:configuration/server/occ_command.adoc#market[The Market app], both the UI and command line, are not, _currently_, designed to operate on clustered installations. -Given that, you will have to update the applications on each server in -the cluster individually. There are several ways to do this. But here is -a concise approach: - -1. Download the latest server release from the https://owncloud.com/download-server/[Download Server Packages] page. -2. Download your installed apps from the ownCloud marketplace. -3. Combine them together into one installation source, such as _a -Docker or VM image_, or _an Ansible script_, etc. -4. Apply the combined upgrade across all the cluster nodes in your ownCloud setup. diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/upgrade.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/upgrade.adoc deleted file mode 100644 index 60e4f40..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/upgrade.adoc +++ /dev/null @@ -1,35 +0,0 @@ -= How to Upgrade Your ownCloud Classic -:toc: right -:page-aliases: maintenance/upgrade.adoc, maintenance/upgrading/index.adoc - -== Introduction - -We recommend that you keep your ownCloud server up to date. When an update or upgrade is available for your ownCloud server, you will see a notification at the top of your ownCloud Web interface. When you click the btn:[notification], it will bring you here. - -Before beginning an upgrade, please keep the following points in mind: - -* Review the https://doc.owncloud.com/docs_main/next/server_release_notes.html[release notes] for important information about the needed migration steps during that upgrade to help ensure a smooth upgrade process. - -* Check ownCloud's xref:installation/manual_installation/manual_installation_prerequisites.adoc[mandatory requirements] (such as PHP versions and extensions), which can change from one version to the next. Ensure that you review them and update or upgrade your server, if required, before upgrading ownCloud. - -* Upgrading is disruptive, as your ownCloud server will be put into xref:configuration/server/occ_command.adoc#maintenance-commands[maintenance mode]. - -* Large installations may take several hours to complete the upgrade. - -* Review any installed xref:maintenance/manual_upgrade.adoc#review-third-party-apps[third-party apps] for compatibility with the new ownCloud release. - -* Downgrading *is not supported* as it risks corrupting your data. If you want to revert to an older ownCloud version, make a new, fresh installation and then restore your data from backup. Before attempting this, file a support ticket (if you have paid support) or ask for help in the ownCloud forums to resolve your issue without downgrading. - -include::partial$maintenance/major_release_note.adoc[] - -== Prerequisites - -We strongly recommend that you always maintain xref:maintenance/backup_and_restore/backup.adoc[regular backups] as well as make a fresh backup before every upgrade. We also recommend that you review any installed xref:maintenance/manual_upgrade.adoc#review-third-party-apps[third-party apps] for compatibility with the new ownCloud release. Ensure that they are all disabled before beginning the upgrade. After the upgrade is complete, enable all those that are compatible with the new release again. - -CAUTION: Unsupported apps may disrupt your upgrade. - -== Upgrade Options - -Perform a xref:maintenance/manual_upgrade.adoc[manual upgrade], using the https://owncloud.com/download-server/[latest ownCloud release]. - -NOTE: Enterprise customers: refer to xref:enterprise/installation/install.adoc[Installing & Upgrading ownCloud Enterprise Edition] for more information. diff --git a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/upgrade_php.adoc b/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/upgrade_php.adoc deleted file mode 100644 index b18c554..0000000 --- a/content/server/10.15/modules/admin_manual/pages/maintenance/upgrading/upgrade_php.adoc +++ /dev/null @@ -1,26 +0,0 @@ -= Upgrade PHP on RedHat 7 and CentOS 7 -:toc: right -:toclevels: 1 -:keywords: upgrade, red hat, centos -:description: Upgrade PHP to one of the supported PHP versions ({supported-php-versions}) on Red Hat and CentOS so that you can make the most out of your ownCloud installations. - -== Introduction - -You should almost always upgrade to the latest version of PHP supported by ownCloud, if and where possible. -And if you're on a version of PHP older than {minimum-php-printed} you *must* upgrade. -This guide takes you through upgrading your installation of PHP to one of the supported PHP versions ({supported-php-versions}) on Red Hat or CentOS 7. - -:from-version: 5.6 -:to-version: 7.4 -:to-pkg-version: 74 - -include::partial$/maintenance/upgrading/upgrade_steps.adoc[leveloffset=+1] - -== Restart Apache - -Finally, you need to restart Apache to make the changes permanent, as in the command below. - -[source,bash] ----- -service httpd restart ----- diff --git a/content/server/10.15/modules/admin_manual/pages/troubleshooting/general_troubleshooting.adoc b/content/server/10.15/modules/admin_manual/pages/troubleshooting/general_troubleshooting.adoc deleted file mode 100644 index 3a63e4a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/troubleshooting/general_troubleshooting.adoc +++ /dev/null @@ -1,376 +0,0 @@ -= General Troubleshooting -:toc: right -:page-aliases: issues/general_troubleshooting.adoc, \ -configuration/general_topics/general_troubleshooting.adoc, \ -go/admin-setup-well-known-URL.adoc, \ -go/admin-logfiles.adoc - -:description: This page gives an overview of general troubleshooting topics and can help to sort out paths addressing your topics. - -== Introduction - -{description} - -If you have trouble installing, configuring or maintaining ownCloud, please refer to our community support channel: - -* The {oc-central-url}[ownCloud Forum] - -NOTE: The ownCloud forum have a https://owncloud.com/faq/[FAQ category] -where each topic corresponds to typical errors or frequently occurring issues. - -Please understand that this channel essentially consist of users -like you helping each other. Consider helping others when you -can in return for the help you get. This is the only way to -keep a community like ownCloud healthy and sustainable! - -If you are using ownCloud in a business or otherwise large scale -deployment, note that ownCloud GmbH offers the -https://owncloud.com/find-the-right-edition/[Enterprise Edition] -with commercial support options. - -== Bugs - -If you think you have found a bug in ownCloud, please: - -* Search for a solution (see the options above) -* Double-check your configuration - -If you can’t find a solution, please use our -xref:developer_manual:bugtracker/index.adoc[bugtracker]. -You can generate a configuration report with the -xref:configuration/server/occ_command.adoc#config-commands[occ config command], -with passwords automatically obscured. - -== General Troubleshooting - -Check the ownCloud xref:installation/system_requirements.adoc[System Requirements], especially supported browser versions. -When you see warnings about `code integrity`, refer to xref:configuration/general_topics/code_signing.adoc[Code Signing]. - -=== Disable Third-Party Apps - -Third-party apps may cause problems during upgrades. -To avoid this happening, we strongly encourage administrators to always disable xref:maintenance/manual_upgrade.adoc#review-third-party-apps[third-party apps] before upgrades, and for troubleshooting purposes. - -=== ownCloud Logfiles - -In a standard ownCloud installation the log level is set to `Normal`. -To find any issues you need to raise the log level to `All` in your `config.php` file, or to *Everything* on your ownCloud Admin page. -Please see xref:configuration/server/logging/logging_configuration.adoc[Logging Configuration] for more information on these log levels. - -Some logging - for example JavaScript console logging - needs debugging -enabled. Edit config/config.php and change `'debug' => false,` to -`'debug' => true,` Be sure to change it back when you are finished. - -For JavaScript issues you will also need to view the javascript console. -All major browsers have developer tools for viewing the console. Usually you can access them by pressing F12. - -For more information on developer tools for Mozilla Firefox, refer to: -https://developer.mozilla.org/en-US/docs/Tools - -To learn more about Chrome or Chromium developer tools, go to: -https://developer.chrome.com/docs/devtools/ - -NOTE: The logfile of ownCloud is located in the data directory `owncloud/data/owncloud.log`. - -=== PHP Version and Information - -You will need to know your PHP version and configuration details. -There are two ways to retrieve this information: using PHP's phpinfo function and using a set of options to PHP on the command-line. - -==== Using PHP's phpinfo Function - -Create a plain-text file named "_phpinfo.php_" and place it in your webserver's root directory, for example `/var/www/html/phpinfo.php`. - -TIP: Your webserver's root directory may be in a different location; your Linux distribution's documentation will tell you where it is located. - -This file contains the following line: - -[source,php] ----- - ----- - -Open this file in a web browser, by pointing your browser to `localhost/phpinfo.php`: - -image:phpinfo.png[image] - -Your PHP version is at the top, and the rest of the page contains abundant system information such as active modules, active `.ini` files, and much more. -When you are finished reviewing your information you must delete `phpinfo.php`, or move it outside of your Web directory, because it is a security risk to expose such sensitive data. - -==== Using the Command-Line - -To retrieve your PHP version, run the following command: - -[source,bash] ----- -php -v ----- - -To retrieve a list of PHP's active modules, run the following command. - -[source,bash] ----- -php -m ----- - -You will see output similar to the following displayed in the terminal. ----- -[PHP Modules] -ast -calendar -Core -ctype -curl -date -dom -exif -fileinfo ----- - -To obtain information about PHP's configuration, you can either retrieve it all at once, by running `php -i` or retrieve information about individual modules, by running `php --ri` followed by the module's name, such as `php --ri curl`. - -=== Debugging Sync Issues - -IMPORTANT: The data directory on the server is exclusive to ownCloud and must not be modified manually. - -Disregarding this can lead to unwanted behaviours like: - -* Problems with sync clients -* Undetected changes due to caching in the database - -If you need to directly upload files from the same server please use a -WebDAV command line client like `cadaver` to upload files to the WebDAV -interface at: - -`\https://example.com/owncloud/remote.php/dav` - -=== Common problems / error messages - -Some common problems / error messages found in your logfiles as -described above: - -* `SQLSTATE[HY000] [1040] Too many connections` -> You need to increase the connection limit of your database, please refer to the manual of your database for more information. -* `SQLSTATE[HY000]: General error: 5 database is locked` -> You’re using `SQLite` which can’t handle a lot of parallel requests. Please consider converting to another database like described in xref:configuration/database/db_conversion.adoc[converting Database Type]. -* `SQLSTATE[HY000]: General error: 2006 MySQL server has gone away` -> Please refer to xref:configuration/database/linux_database_configuration.adoc#troubleshooting[Troubleshooting] for more information. -* `SQLSTATE[HY000] [2002] No such file or directory` -> There is a problem accessing your SQLite database file in your data directory (`data/owncloud.db`). Please check the permissions of this folder/file or if it exists at all. If you’re using MySQL please start your database. -* `Connection closed / Operation cancelled` or `expected filesize 4734206 got 458752` -> This could be caused by wrong -`KeepAlive` settings within your Apache config. Make sure that `KeepAlive` is set to `On` and also try to raise the -limits of `KeepAliveTimeout` and `MaxKeepAliveRequests`. On Apache with `mod_php` using a xref:installation/manual_installation/manual_installation.adoc#configure-the-web-server[multi-processing module] other than `prefork` could be another reason. -Further information is available {oc-central-url}/t/expected-filesize-xxx-got-yyy-0/816[in the forums]. -* `No basic authentication headers were found` -> This error is shown in your `data/owncloud.log` file. -Some Apache modules like `mod_fastcgi`, `mod_fcgid` or `mod_proxy_fcgi` are not passing the needed authentication -headers to PHP and so the login to ownCloud via WebDAV, CalDAV and CardDAV clients is failing. -More information on how to correctly configure your environment can be found -{oc-central-url}/t/no-basic-authentication-headers-were-found-message/819[at the forums]. - -== OAuth2 - -=== ownCloud clients cannot connect to the ownCloud server - -If ownCloud clients cannot connect to your ownCloud server, check to see -if PROPFIND requests receive `HTTP/1.1 401 Unauthorized` responses. If -this is happening, more than likely your webserver configuration is -stripping out https://tools.ietf.org/html/rfc6750[the bearer authorization header]. - -If you’re using the Apache web server, add the following `SetEnvIf` -directive to your Apache configuration, whether in the general Apache -config, in a configuration include file, or in ownCloud’s .htaccess -file. - -[source,apache] ----- -SetEnvIf Authorization "(.*)" HTTP_AUTHORIZATION=$1 ----- - -== Missing Data Directory - -During the normal course of operations, the ownCloud data directory may -be temporarily unavailable for a variety of reasons. These can include -network timeouts on mounted network disks, unintentional unmounting of -the partition on which the directory sits, or a corruption of the RAID -setup. If you have experienced this, here’s how ownCloud works and what -you can expect. - -During normal operation, ownCloud’s data directory contains a hidden -file, named `.ocdata`. The purpose of this file is for setups where the -data folder is mounted (such as via NFS) and for some reason the mount -disappeared. If the directory isn’t available, the data folder would, in -effect, be completely empty and the `.ocdata` would be missing. When -this happens, ownCloud will return a -https://en.wikipedia.org/wiki/List_of_HTTP_status_codes#5xx_Server_Error[503 Service not available] -error, to prevent clients believing that the files are gone. - -== Troubleshooting Web server and PHP problems - -=== Logfiles - -When having issues the first step is to check the logfiles provided by -PHP, the Web server and ownCloud itself. - -NOTE: In the following the paths to the logfiles of a default Debian installation running Apache2 with mod_php is assumed. On other Web servers, Linux distros or operating systems they can differ. - -* The logfile of Apache2 is located in `/var/log/apache2/error.log`. -* The logfile of PHP can be configured in your -`/etc/php/7.4/apache2/php.ini`. You need to set the directive `log_errors` -to `On` and choose the path to store the logfile in the `error_log` -directive. After those changes you need to restart your Web server. -* The logfile of ownCloud is located in the data directory -`/var/www/owncloud/data/owncloud.log`. - -=== Web Server and PHP Modules - -NOTE: https://www.lighttpd.net/[Lighttpd] is not supported with ownCloud — and some ownCloud features -may not work _at all_ on Lighttpd. - -There are some Web server or PHP modules which are known to cause -various problems like broken up-/downloads. The following shows a draft -overview of these modules: - -==== Apache - -* libapache2-mod-php7.4 (or a lower supported version if necessary) -* mod_dav -* mod_deflate -* mod_evasive -* mod_pagespeed -* mod_proxy_html (can cause broken PDF downloads) -* mod_reqtimeout -* mod_security -* mod_spdy together with libapache2-mod-php7.4 (see above) / mod_php (use fcgi or php-fpm instead) -* mod_xsendfile / X-Sendfile (causing broken downloads if not configured correctly) - -==== PHP - -* eAccelerator - -== Troubleshooting WebDAV - -=== General troubleshooting - -ownCloud uses SabreDAV, and the SabreDAV documentation is comprehensive and helpful. - -See: - -* http://sabre.io/dav/faq/[SabreDAV FAQ] -* http://sabre.io/dav/webservers[Web servers] (Lists lighttpd as not recommended) -* http://sabre.io/dav/large-files/[Working with large files] -(Shows a PHP bug in older SabreDAV versions and information for mod_security problems) -* http://sabre.io/dav/0bytes[0 byte files] (Reasons for empty files on the server) -* http://sabre.io/dav/clients/[Clients] -(A comprehensive list of WebDAV clients, and possible problems with each one) -* http://sabre.io/dav/clients/finder/[Finder, OS X’s built-in WebDAV client] -(Describes problems with Finder on various Web servers) - -There is also a well maintained FAQ thread available at the -{oc-central-url}/t/how-to-fix-caldav-carddav-webdav-problems/852[ownCloud Forums] -which contains various additional information about WebDAV problems. - -=== Error 0x80070043 `The network name cannot be found.` while adding a network drive - -The windows native WebDAV client might fail with the following error message: - ----- -Error 0x80070043 "The network name cannot be found." while adding a network drive ----- - -A known workaround for this issue is to update your web server -configuration. - -*Apache* - -You need to add the following rule set to your main web server or -virtual host configuration, or the `.htaccess` file in your document -root. - -NOTE: Please keep in mind that the `.htaccess` file in the ownCloud directory will be overwritten on update. Post upgrading ownCloud, you need to manually restore these changes. See the section xref:maintenance/upgrading/manual_upgrade.adoc#backup-manual-changes-in-htaccess[Backup Manual Changes in .htaccess] for details. - -[source,apache] ----- -# Fixes Windows WebDav client error 0x80070043 "The network name cannot be found." -RewriteEngine On -RewriteCond %{HTTP_USER_AGENT} ^(DavClnt)$ -RewriteCond %{REQUEST_METHOD} ^(OPTIONS)$ -RewriteRule .* - [R=401,L] ----- - -== Troubleshooting Contacts & Calendar - -=== Service Discovery - -Some clients - especially on iOS/Mac OS X - have problems finding the -proper sync URL, even when explicitly configured to use it. - -If you want to use CalDAV or CardDAV clients together with ownCloud it -is important to have a correct working setup of the following URLs: - -[verse] --- -`\https://example.com/.well-known/carddav` -`\https://example.com/.well-known/caldav` - --- - -Those need to be redirecting your clients to the correct DAV endpoints. -If running ownCloud at the document root of your Web server the correct -URL is: - -`\https://example.com/remote.php/dav` - -and if running in a subfolder like `owncloud`: - -`\https://example.com/owncloud/remote.php/dav` - -For the first case the .htaccess file shipped with ownCloud should do -this work for your when running Apache. You only need to make sure that -your Web server is using this file. - -If your ownCloud instance is installed in a subfolder called `owncloud` -and you’re running Apache create or edit the .htaccess file within the -document root of your Web server and add the following lines: - -[source,apache] ----- -Redirect 301 /.well-known/carddav /owncloud/remote.php/dav -Redirect 301 /.well-known/caldav /owncloud/remote.php/dav ----- - -Now change the URL in the client settings to just use: - -`\https://example.com` - -instead of e.g. - -`\https://example.com/owncloud/remote.php/dav/principals/username`. - -There are also several techniques to remedy this, which are described -extensively at the http://sabre.io/dav/service-discovery/[Sabre DAV website]. - -=== Unable to update Contacts or Events - -If you get an error like: - -`PATCH \https://example.com/remote.php/dav HTTP/1.0 501 Not Implemented` - -it is likely caused by one of the following reasons: - -Using Pound reverse-proxy/load balancer:: - Check if your Pound installation supports the HTTP/1.1 verb. If it does not, update to the latest version. - -Misconfigured Web server:: - Your Web server is misconfigured and blocks the needed DAV methods. - Please refer to xref:troubleshooting-webdav[Troubleshooting WebDAV] above for troubleshooting steps. - -== Client Sync Stalls - -One known reason is stray locks. These should expire automatically after an hour. -If stray locks don’t expire (identified by e.g. repeated `file.txt is locked` and/or `Exception\\\\FileLocked` messages in your data/owncloud.log), make sure that you are running system cron and not Ajax cron (See xref:configuration/server/background_jobs_configuration.adoc[Background Jobs]). -See https://github.com/owncloud/core/issues/22116 and -{oc-central-url}/t/file-is-locked-how-to-unlock/985 -for some discussion and additional info of this issue. - -== Other issues - -Some services like _Cloudflare_ can cause issues by minimizing -JavaScript and loading it only when needed. When having issues like a -not working login button or creating new users make sure to disable such -services first. diff --git a/content/server/10.15/modules/admin_manual/pages/troubleshooting/path_filename_length.adoc b/content/server/10.15/modules/admin_manual/pages/troubleshooting/path_filename_length.adoc deleted file mode 100644 index 48119c1..0000000 --- a/content/server/10.15/modules/admin_manual/pages/troubleshooting/path_filename_length.adoc +++ /dev/null @@ -1,102 +0,0 @@ -= Path and Filename Length Limitations -:toc: right -:fs-limits-url: https://en.wikipedia.org/wiki/Comparison_of_file_systems#Limits -:enable-long-paths-url: https://docs.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation?tabs=cmd#enable-long-paths-in-windows-10-version-1607-and-later -:getconf-url: http://manpages.ubuntu.com/manpages/focal/man1/getconf.1.html - -== Introduction - -Depending on the underlying filesystem of a mount point, the maximum length of a path component and the file name can differ. This is important if you start copying or moving single files or even complete paths from one mount to another where the target mount has a more restrictive length rule than the source. This can also be an issue when using a synchronization client running on an Operating System (OS) with a different filesystem than the source mount filesystem. The following table gives you a brief overview as a guideline. - -== Limitations - -See the {fs-limits-url}[comparison of file systems] for in depth details on various filesystem path and file name limitations. - -NOTE: While a filesystem can handle the limits as described in the table below, applications like Explorer, Finder, the Shell or other apps may have issues handling these limits. See the special notes below the table. - -NOTE: The ownCloud database has a size limit storing a path/file string with 4000 bytes. This must not be exceeded. - -[caption=] -.File Name and Path Length Limitations -[cols="30%,80%,80%",options="header",] -|=== -| Filesystem -| max. Path Length -| max. Filename Length - -| (*) Btrfs -| No limit defined -| 255 bytes - -| (*) ext2 -| No limit defined -| 255 bytes - -| (*) ext3 -| No limit defined -| 255 bytes - -| (*) ext4 -| No limit defined -| 255 bytes - -| (*) XFS -| No limit defined -| 255 bytes - -| (*) ZFS -| No limit defined -| 255 bytes - -| APFS -| Unknown (**) -| 255 UTF-8 characters - -| FAT32 -a| 32,760 Unicode characters with *each* path component no more than 255 characters -| 8.3 (255 UCS-2 code units with VFAT LFNs) - -| exFAT -a| 32,760 Unicode characters with *each* path component no more than 255 characters -| 255 UTF-16 characters - -| NTFS -a| 32,767 Unicode characters with *each* path component (directory or filename) up to 255 characters long (MAX_PATH). - -==== -Starting in Windows 10, version 1607, MAX_PATH limitations have been removed from common Win32 file and directory functions. However, you must opt-in to the new behavior. For more details see {enable-long-paths-url}[Enable Long Paths in Windows 10, Version 1607, and Later] -==== -| 255 characters -|=== - -(*):: -In Unix environments, PATH_MAX with 4096 bytes and NAME_MAX with 255 bytes are very common limitations for applications including the Shell. You can get the current limitations by typing the following example commands, see the {getconf-url}[getconf manpage] for details: -+ -[source,plaintext] ----- -getconf NAME_MAX / -255 ----- -+ -[source,plaintext] ----- -getconf PATH_MAX / -4096 ----- - -(**):: -Although not officially documented, when searching on the internet there is a limit with path names exceeding 1024 bytes. Users report warnings in Finder, the Shell or apps about this behavior. This can be verified with: -+ -[source,plaintext] ----- -getconf NAME_MAX / -255 ----- -+ -[source,plaintext] ----- -getconf PATH_MAX / -1024 ----- -+ -Note that these limits are true for macOS as well as for iOS because both are using APFS. diff --git a/content/server/10.15/modules/admin_manual/pages/troubleshooting/providing_logs_and_config_files.adoc b/content/server/10.15/modules/admin_manual/pages/troubleshooting/providing_logs_and_config_files.adoc deleted file mode 100644 index 49dd23a..0000000 --- a/content/server/10.15/modules/admin_manual/pages/troubleshooting/providing_logs_and_config_files.adoc +++ /dev/null @@ -1,73 +0,0 @@ -= Retrieve Log Files and Configuration Settings -:toc: right -:page-aliases: configuration/server/logging/providing_logs_and_config_files.adoc - -:description: Generating configreports and preparing log files are essential to support identifying the cause of a problem. Here are instructions for how to collect them. - -== Introduction - -{description} - -When you report a problem to {oc-support-url}[ownCloud Support] or our {oc-central-url}/latest[Forum (ownCloud Central)] you will be asked to provide certain log files or configurations for our engineers or other supporting staff. This information is necessary in better understanding your issue, your specific configuration, and for further support. - -== Generate a Config Report - -You can use the webUI or the command line to generate a config report. The webUI includes the web server environment, while the command line generated one doesn't as it can't access it. Therefore, if possible, always generate it through the webUI. The configreport app is always part of bundled apps, but it may need to be enabled before it can be used. - -Check if it is disabled: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:list --disabled configreport ----- - -Enable it if it was formerly disabled: -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable configreport ----- - -=== Generate via webUI - -To generate a config report using the webUI, navigate to: + -menu:Settings[Admin > General > "Generate Config report" > "Download ownCloud config report"]. - -=== Generate via Command Line - -To generate a config report from the command line, run the following command from the root directory of your ownCloud installation: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} configreport:generate > config_report.txt ----- - -== ownCloud Classic Log File - -=== Generate via webUI - -You can use the webUI to download your ownCloud Classic log file. To do so, navigate to: + -menu:Settings[Admin > General > Log > "Download logfile"]. - -=== Generate via Command Line - -If the log file is too big, you will need to transfer it from the command line. The location of the log file can be found in your config.php. By default it is in your data directory. Note that you may need to compress the logfile before uploading: - -[source,php] ----- -'datadirectory' => '/var/www/owncloud/data', ----- - -When not using the default location for the logfile, it can be specified via: - -[source,php] ----- -'logfile' => '/owncloud.log', ----- - -== LDAP Config - -If LDAP is used, viewing the LDAP configuration is important when checking for errors between your ownCloud instance and your LDAP server. To get the output file, execute this command: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} ldap:show-config > ldap_config.txt ----- diff --git a/content/server/10.15/modules/admin_manual/pages/troubleshooting/remove_non_existent_bg_jobs.adoc b/content/server/10.15/modules/admin_manual/pages/troubleshooting/remove_non_existent_bg_jobs.adoc deleted file mode 100644 index b938086..0000000 --- a/content/server/10.15/modules/admin_manual/pages/troubleshooting/remove_non_existent_bg_jobs.adoc +++ /dev/null @@ -1,82 +0,0 @@ -= Remove Non-Existent Background Jobs -:toc: right - -== Introduction - -During the lifecycle of ownCloud, some background jobs may get removed as they are either superseded by another job or completely obsolete. It can also happen, that an app providing a background job was removed and the job therefore is no longer present. These jobs can be removed manually. - -== Identification - -If the ownCloud log files contain errors like: - -[source,plaintext] ----- -"Exception: {"Exception":"OCP\AppFramework\QueryException","Message":"Could not resolve OCA\User_LDAP\Jobs\UpdateGroups! Class OCA\User_LDAP\Jobs\UpdateGroups does not exist","Code":0,"Trace":" - -"Exception: {"Exception":"OCP\AppFramework\QueryException","Message":"Could not resolve OCA\User_LDAP\Jobs\CleanUp! Class OCA\User_LDAP\Jobs\CleanUp does not exist","Code":0,"Trace":" - -"Exception: {"Exception":"OCP\AppFramework\QueryException","Message":"Could not resolve OCA\Federation\SyncJob! Class OCA\Federation\SyncJob does not exist","Code":0,"Trace":" ----- - -these background jobs can safely be removed as they no longer exist. - -== Removal Process - -There is an xref:configuration/server/occ_command.adoc#managing-background-jobs[occ command set] for managing background jobs _triggered by ownCloud_. The following steps are necessary to remove a background job: - -. Identify the `Job-ID` of the background job to be removed -. Remove the background job based on the `Job-ID` - -It is also possible that a background job is triggered manually by the admin when the job has been added to eg. `crontab`. - -=== Identify the Job-ID of the Background Job to Be Removed - -Use the following command to list all active background jobs triggered by ownCloud: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:queue:status --display-invalid-jobs ----- - -The output may look like the following: - -[source,plaintext] ----- -+----+---------------------------------------------------+---------------------------+---------------+---------+ -| Id | Job | Last run | Job Arguments | Status | -+----+---------------------------------------------------+---------------------------+---------------+---------+ -| 1 | OCA\Files\BackgroundJob\ScanFiles | 2022-01-23T14:00:02+00:00 | | | -| 2 | OCA\Files\BackgroundJob\DeleteOrphanedItems | 2022-01-23T14:00:02+00:00 | | | -| 3 | OCA\Files\BackgroundJob\CleanupFileLocks | 2022-01-23T14:00:02+00:00 | | | -| 4 | OCA\DAV\CardDAV\SyncJob | 2022-01-23T14:00:02+00:00 | | | -| 23 | OCA\Files_Antivirus\Cron\Task | 2022-01-23T14:00:02+00:00 | | invalid | -... -+----+---------------------------------------------------+---------------------------+---------------+---------+ ----- - -=== Remove the Background Job - -When you have identified the `ID` of the background job to be removed, run following command to remove it, replace `ID` with the job number of the list: - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} background:queue:delete ID ----- - -WARNING: Deleting a job cannot be undone. Be sure that you want to delete the job before doing so. - -=== Remove Jobs Manually Added via Crontab - -If an erroring job as been added manually in `crontab`, remove the job from the crontab queue list. First, list the entries of crontab for the web server user: - -[source,bash] ----- -sudo -uwww-data crontab -l ----- - -Then edit the crontab job list to remove the job by invoking following command: - -[source,bash] ----- -sudo -uwww-data crontab -e ----- diff --git a/content/server/10.15/modules/admin_manual/pages/useful_pages.adoc b/content/server/10.15/modules/admin_manual/pages/useful_pages.adoc deleted file mode 100644 index ec63f59..0000000 --- a/content/server/10.15/modules/admin_manual/pages/useful_pages.adoc +++ /dev/null @@ -1,20 +0,0 @@ -= Useful Pages -:toc: right - -:description: When new to ownCloud Classic, the following list of useful pages may help getting up and running quickly. - -== Introduction - -{description} - -== Page List - -Note that this section always points to the latest server version available. In case you need a different version, select your topic and manually switch to one of the available ones. - -// note that these targets must use the page paths of the *latest* server -// version, not this branch's: the latest version is a docker-only release and -// has reorganized its installation and upgrading pages accordingly. -* xref:{latest-server-version}@server:admin_manual:installation/installing_with_docker.adoc[Installation with Docker] -* xref:{latest-server-version}@server:admin_manual:configuration/server/occ_command.adoc[OCC Commands] -* xref:{latest-server-version}@server:admin_manual:configuration/server/caching_configuration.adoc#small-organization-single-server-setup[File Locking and Caching Configuration] -* xref:{latest-server-version}@server:admin_manual:maintenance/upgrading/manual_upgrade.adoc[Manual Upgrade] diff --git a/content/server/10.15/modules/admin_manual/partials/configuration/files/encryption/not-encrypted-files.adoc b/content/server/10.15/modules/admin_manual/partials/configuration/files/encryption/not-encrypted-files.adoc deleted file mode 100644 index 0c0712d..0000000 --- a/content/server/10.15/modules/admin_manual/partials/configuration/files/encryption/not-encrypted-files.adoc +++ /dev/null @@ -1,25 +0,0 @@ -== Which Data Is Encrypted and When - -=== The following data *is* encrypted: - -* Users' _files_ in their home directory trees _if enabled_ by the admin. + -Location: `data//files`, see the: xref:admin_manual:configuration/server/occ_command.adoc#encryption[occ encryption command set] -* External storage _if enabled_ either by the user or by the admin - -=== The following is *never* encrypted: - -* File names or folder structures -* Existing files in the trash bin -* Existing files in Versions -* Image thumbnails -* Previews from the Files app -* The search index from the full text search app -* Third-party app data - -Note that there may be other not mentioned files that are not encrypted. - -=== When are files encrypted - -If not otherwise decided by the admin, only new and changed files after enabling encryption are encrypted. - -NOTE: An admin can encrypt existing files post enabling encryption via an xref:configuration/server/occ_command.adoc#encryption[occ encryption command]. diff --git a/content/server/10.15/modules/admin_manual/partials/configuration/server/disable-single-user-mode.adoc b/content/server/10.15/modules/admin_manual/partials/configuration/server/disable-single-user-mode.adoc deleted file mode 100644 index 3e7a3d3..0000000 --- a/content/server/10.15/modules/admin_manual/partials/configuration/server/disable-single-user-mode.adoc +++ /dev/null @@ -1,8 +0,0 @@ -= Disable Single User Mode - -With encryption migrated from User Key-based encryption to Master Key-based, disable single user mode, if you xref:configuration/server/occ_command.adoc#maintenance-commands[enabled it] before beginning the migration. - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:singleuser --off ----- diff --git a/content/server/10.15/modules/admin_manual/partials/configuration/server/occ_command/config-list-report.json b/content/server/10.15/modules/admin_manual/partials/configuration/server/occ_command/config-list-report.json deleted file mode 100644 index 24e2d53..0000000 --- a/content/server/10.15/modules/admin_manual/partials/configuration/server/occ_command/config-list-report.json +++ /dev/null @@ -1,127 +0,0 @@ -{ - "system": { - "passwordsalt": "***REMOVED SENSITIVE VALUE***", - "secret": "***REMOVED SENSITIVE VALUE***", - "trusted_domains": [ - "localhost", - ], - "datadirectory": "\/var\/www\/localhost\/data", - "overwrite.cli.url": "http:\/\/localhost", - "dbtype": "mysql", - "version": "10.3.0.4", - "dbname": "owncloud", - "dbhost": "localhost", - "dbtableprefix": "oc_", - "dbuser": "***REMOVED SENSITIVE VALUE***", - "dbpassword": "***REMOVED SENSITIVE VALUE***", - "logtimezone": "UTC", - "shareapi_allow_public_notification": "yes", - "apps_paths": [ - { - "path": "\/var\/www\/localhost\/apps", - "url": "\/apps", - "writable": false - }, - { - "path": "\/var\/www\/localhost\/apps-external", - "url": "\/apps-external", - "writable": true - } - ], - "installed": true, - "instanceid": "ocfp00rezy80", - "loglevel": 2, - "maintenance": false - }, - "apps": { - "backgroundjob": { - "lastjob": "13" - }, - "comments": { - "enabled": "yes", - "installed_version": "0.3.0", - "types": "logging,dav" - }, - "core": { - "backgroundjobs_mode": "cron", - "enable_external_storage": "yes", - "first_install_version": "10.3.0.2", - "installedat": "1569845065.1792", - "lastcron": "1571930489", - "lastupdateResult": "[]", - "lastupdatedat": "1572536814", - "oc.integritycheck.checker": "{\"systemtags\":{\"EXCEPTION\":{\"class\":\"OC\\\\IntegrityCheck\\\\Exceptions\\\\MissingSignatureException\",\"message\":\"Signature data not found.\"}},\"comments\":{\"EXCEPTION\":{\"class\":\"OC\\\\IntegrityCheck\\\\Exceptions\\\\MissingSignatureException\",\"message\":\"Signature data not found.\"}}}", - "public_files": "files_sharing\/public.php", - "public_webdav": "dav\/appinfo\/v1\/publicwebdav.php", - "shareapi_allow_mail_notification": "yes", - "umgmt_set_password": "false", - "umgmt_show_backend": "true", - "umgmt_show_email": "true", - "umgmt_show_is_enabled": "true", - "umgmt_show_last_login": "true", - "umgmt_show_password": "false", - "umgmt_show_quota": "true", - "umgmt_show_storage_location": "false", - "vendor": "owncloud" - }, - "dav": { - "enabled": "yes", - "installed_version": "0.5.0", - "types": "filesystem" - }, - "federatedfilesharing": { - "enabled": "yes", - "installed_version": "0.5.0", - "types": "filesystem" - }, - "federation": { - "enabled": "yes", - "installed_version": "0.1.0", - "types": "authentication" - }, - "files": { - "cronjob_scan_files": "500", - "enabled": "yes", - "installed_version": "1.5.2", - "types": "filesystem" - }, - "files_external": { - "allow_user_mounting": "yes", - "enabled": "yes", - "installed_version": "0.7.1", - "types": "filesystem", - "user_mounting_backends": "googledrive,owncloud,sftp,smb,dav,\\OC\\Files\\Storage\\SFTP_Key,\\OC\\Files\\Storage\\SMB_OC" - }, - "files_sharing": { - "enabled": "yes", - "installed_version": "0.12.0", - "types": "filesystem" - }, - "files_trashbin": { - "enabled": "yes", - "installed_version": "0.9.1", - "types": "filesystem" - }, - "files_versions": { - "enabled": "yes", - "installed_version": "1.3.0", - "types": "filesystem" - }, - "provisioning_api": { - "enabled": "yes", - "installed_version": "0.5.0", - "types": "prevent_group_restriction" - }, - "systemtags": { - "enabled": "yes", - "installed_version": "0.3.0", - "types": "logging" - }, - "updatenotification": { - "enabled": "yes", - "installed_version": "0.2.1", - "types": "" - } - } -} - diff --git a/content/server/10.15/modules/admin_manual/partials/configuration/user/update-password-note.adoc b/content/server/10.15/modules/admin_manual/partials/configuration/user/update-password-note.adoc deleted file mode 100644 index 39cd34a..0000000 --- a/content/server/10.15/modules/admin_manual/partials/configuration/user/update-password-note.adoc +++ /dev/null @@ -1 +0,0 @@ -NOTE: Password changes automatically log out *all* connected browsers/devices. diff --git a/content/server/10.15/modules/admin_manual/partials/installation/manual_installation/mariadb.adoc b/content/server/10.15/modules/admin_manual/partials/installation/manual_installation/mariadb.adoc deleted file mode 100644 index ba1fb01..0000000 --- a/content/server/10.15/modules/admin_manual/partials/installation/manual_installation/mariadb.adoc +++ /dev/null @@ -1,130 +0,0 @@ -:install-mariadb-latest-url: https://downloads.mariadb.org/mariadb/repositories/# -:auth-unix-socket-url: https://mariadb.com/kb/en/library/authentication-plugin-unix-socket/ -:upgrade-mariadb-url: https://mariadb.com/kb/en/upgrading/ - -== Standard Installation - -Use these commands to install MariaDB provided by Ubuntu and secure its installation. - -[NOTE] -==== -At the time of writing, the following MariaDB Server versions will be installed, which may change when the corresponding package gets updated: - -* With Ubuntu 20.04: `mariadb-server` version `10.4.21` -* With Ubuntu 22.04, `mariadb-server` version `10.6.12` -==== - -[source,bash] ----- -sudo apt install mariadb-server -sudo mysql_secure_installation ----- - -Check access and the version of MariaDB, replace `` as either defined during `mysql_secure_installation` above or use e.g. `root`. - -[source,bash] ----- -sudo mysqladmin -u -p version ----- - -If you get output like below, your database is up and running and ready to serve requests. - -[source,text] ----- -mysqladmin Ver 9.1 Distrib 10.4.21-MariaDB, for debian-linux-gnu on x86_64 -Copyright (c) 2000, 2021, Oracle, MariaDB Corporation Ab and others. - -Server version 10.4.21-MariaDB-1:10.4.21+maria~bionic -Protocol version 10 -Connection Localhost via UNIX socket -UNIX socket /var/run/mysqld/mysqld.sock -Uptime: 59 min 51 sec - -Threads: 16 Questions: 891020 Slow queries: 0 Opens: 119 Flush tables: 1 Open tables: 113 Queries per second avg: 248.125 ----- - -== Higher Stable Release - -For information on how to install a higher stable release of MariaDB than the one provided by Ubuntu, refer to the {install-mariadb-latest-url}[MariaDB installation documentation]. - -WARNING: The installation and use of MariaDB 10.6 and later is *only* supported and functional with ownCloud release 10.9 or above if it is a *new* ownCloud installation. Using an existing older version of ownCloud is not supported with MariaDB 10.6 and later. The necessary manual migration steps are only available with ownCloud release 10.9 or above. - -== Upgrading an Existing Release - -When upgrading from one minor version of MariaDB to another, e.g. from 10.4 to 10.5, follow the respective {upgrade-mariadb-url}[Upgrading MariaDB] guide. - -WARNING: Do not upgrade a running ownCloud installation to MariaDB 10.6 and later until ownCloud release 10.9 or above is installed. ownCloud release 10.9 or above runs well with MariaDB lower than 10.6 and has special instructions for upgrading to MariaDB 10.6 and later. - -WARNING: You must not skip minor releases of MariaDB when upgrading like from 10.4 -> 10.6, you have to upgrade to each minor version in between step by step. - -[NOTE] -==== -If you have an existing installation of MariaDB and upgrade to a higher version, do not forget to run the following command to handle the new setup for admin users — especially when running an older version of MariaDB and upgrading to MariaDB 10.4.3 upwards: - -[source,bash] ----- -sudo mysql_upgrade ----- -==== - -== Notes For MariaDB Lower Than 10.4.3 - -[NOTE] -==== -For MariaDB server releases lower than 10.4.3, you will be prompted during the installation to create a root password. Be sure to remember your password, as you will need it during the ownCloud database setup. -==== - -To install an ownCloud database, you need an administrative user who can log in, has rights to create/modify databases and users. If this user does not exist, like on MariaDB server releases higher than 10.4.3, or if you want to create a temporary user for this task, you manually have to create one. You will be asked for the mysql root user's password: - -[source,bash] ----- -sudo mysql --user=root -p - - CREATE USER 'dbadmin'@'localhost' IDENTIFIED BY 'password'; - GRANT ALL PRIVILEGES ON *.* TO 'dbadmin'@'localhost' WITH GRANT OPTION; - FLUSH PRIVILEGES; -exit ----- - -== Notes For MariaDB Higher Than 10.4.3 - -[NOTE] -==== -From MariaDB 10.4.3 onwards, the authentication method has changed to UNIX sockets. For details, please refer to: {auth-unix-socket-url}[MariaDB: Authentication Plugin - Unix Socket]. The unix_socket authentication plugin allows the user to use operating system credentials when connecting to MariaDB via a local UNIX socket. Follow the procedure below to create an admin user for non-socket login, giving ownCloud access to create its database for phpMyAdmin. - -_This is not the ownCloud user!_ + -_Don't forget to change the username and password according to your needs_. - -[source,bash] ----- -sudo mysql - - CREATE USER IF NOT EXISTS 'dbadmin'@'localhost' IDENTIFIED BY 'password'; - GRANT ALL PRIVILEGES ON *.* TO 'dbadmin'@'localhost' WITH GRANT OPTION; - FLUSH PRIVILEGES; - SHOW GRANTS FOR 'dbadmin'@'localhost'; -exit ----- -==== - -== phpmyadmin - -If you want to install phpMyAdmin as a graphical interface for administering the database, run the following command: - -[source,bash] ----- -sudo apt install phpmyadmin ----- - -After the installation, you need to configure your web server to access `phpmyadmin`. This is a manual task, depending on what your setup looks like and is not part of this documentation. - -[NOTE] -==== -You can run -[source,bash] ----- -sudo dpkg-reconfigure phpmyadmin ----- -to reconfigure phpmyadmin. -==== - diff --git a/content/server/10.15/modules/admin_manual/partials/installation/manual_installation/useful_tips.adoc b/content/server/10.15/modules/admin_manual/partials/installation/manual_installation/useful_tips.adoc deleted file mode 100644 index 9938793..0000000 --- a/content/server/10.15/modules/admin_manual/partials/installation/manual_installation/useful_tips.adoc +++ /dev/null @@ -1,168 +0,0 @@ -:iscsi_initiator-url: https://ubuntu.com/server/docs/service-iscsi -:overriding-vendor-settings-url: https://www.freedesktop.org/software/systemd/man/systemd.unit.html -:transport-huge-pages-url: https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/6/html/performance_tuning_guide/s-memory-transhuge -:disabling-thp-url: https://stackoverflow.com/questions/48743100/why-thp-transparent-huge-pages-are-not-recommended-for-databases-like-oracle-a - -== Start a Service After a Resource is Mounted - -If you have network resources, such as NFS or iSCSI based mounts, and you want to make -sure that the database or web server only starts _after_ the resource is mounted, -then consider the following example setup when configuring your system. - -The example below is based on an NFS mount which you want to be available _before_ the service -with starts. The same procedure can be used for iSCSI. For details setting up an -iSCSI mount see the {iscsi_initiator-url}[Ubuntu iSCSI Initiator] guide. - -The name in could be any valid service, including `apache2`, `mysql` or `mariadb`. - -* Add `_netdev` to the list of NFS mount point options in `/etc/fstab`. -+ --- -This option ensures, that the mount happens _after_ the network is up: - -[source,console] ----- -resource:foreign_path local_path nfs (),_netdev ----- --- - -* Make sure that all mounts in `/etc/fstab` are mounted by running: -+ --- -[source,bash] ----- -sudo mount -a ----- --- - -* Run the following command to list mounts which must be up first: -+ --- -[source,bash] ----- -systemctl list-units | grep -nP "\.mount" ----- - -You should see lines printed to the console. -Look for the mount you want to be up in the command's output. - -[source,console] ----- - - loaded active mounted ----- -where `` and `` are examples! --- - -* Edit the service you want to change: -+ --- -[source,bash] ----- -sudo systemctl edit .service ----- - -Add the following directive in the editor opened, using your chosen `folder.mount` from above: - -[source,text] ----- -[Unit] -After=folder.mount ----- - -You can add more than one dependency if needed by separating them with spaces. This procedure -keeps `.service` in its original state but makes it possible to override the current -setup with new parameters. This is necessary, because on updates, the original service data will -be overwritten. It automatically creates a directory in `/etc/systemd/system`, named -`.service.d`, and a file in that directory called `override.conf`. In the example -above, the parameter is added to the existing list of parameters of the `After` directive. - -For more details please read section {overriding-vendor-settings-url}[Example 2. Overriding vendor settings] - -Please keep the following points in mind, regarding if `.service` is linked or not: - -** If the file is linked from `/lib/systemd/system`, it is for packaged unit files. -They are overwritten when Systemd (or whatever package provides them) is upgraded. - -** If the file originates in `/etc/systemd/system`, it is for your own and customised unit files. -Unit files you place in here override the package-provided file and will not be replaced on upgrade. - -It is recommended to keep things simple and future-proof by creating an override file via `systemctl edit` For more details see https://www.digitalocean.com/community/tutorials/how-to-use-systemctl-to-manage-systemd-services-and-units#editing-unit-files[Editing Unit Files]. --- - -* Run the following command to apply your changes: -+ --- -[source,bash] ----- -sudo systemctl daemon-reload ----- --- - -* Check if `.service` has been properly added: -+ --- -[source,bash] ----- -sudo systemctl show .service | grep "After=" ----- -`folder.mount` should be part of the parameter list. --- - -* Restart your service by invoking: -+ --- -[source,bash] ----- -sudo system restart ----- --- - -== Disable Transparent Huge Pages (THP) - -{transport-huge-pages-url}[Transparent Huge Pages] should be disabled when using databases. -This is applicable when using Redis, as well as MariaDB. For more information read: -{disabling-thp-url}[Why THP (Transparent Huge Pages) are not recommended for Databases]. - -To disable Transparent Huge Pages, follow these steps: - -* Create in `/etc/systemd/system` a file like `disable-thp.service` add the following content: -+ --- -[source,text] ----- -[Unit] -Description=Disable Transparent Huge Pages -DefaultDependencies=no -After=sysinit.target local-fs.target -Before=basic.target - -[Service] -Type=oneshot -ExecStart=/bin/sh -c '/bin/echo never > /sys/kernel/mm/transparent_hugepage/enabled' -ExecStart=/bin/sh -c '/bin/echo never > /sys/kernel/mm/transparent_hugepage/defrag' - -[Install] -WantedBy=basic.target ----- --- - -* Run the following command to apply and activate your changes and start it automatically at boot time: -+ --- -[source,bash] ----- -sudo systemctl daemon-reload ----- - -[source,bash] ----- -sudo systemctl enable disable-thp ----- - -[source,bash] ----- -sudo service disable-thp start ----- --- - diff --git a/content/server/10.15/modules/admin_manual/partials/maintenance/major_release_note.adoc b/content/server/10.15/modules/admin_manual/partials/maintenance/major_release_note.adoc deleted file mode 100644 index 673d595..0000000 --- a/content/server/10.15/modules/admin_manual/partials/maintenance/major_release_note.adoc +++ /dev/null @@ -1,56 +0,0 @@ -[IMPORTANT] -==== -When upgrading, also check the minimum and maximum supported PHP version of the ownCloud target release. An ownCloud release may require a particular minimum and/or maximum PHP version. Check that the PHP version provided by the Operating System meets the requirements. For details see the https://doc.owncloud.com/docs_main/next/server_release_notes.html[Server Release Notes] and the xref:{latest-server-version}@server:admin_manual:installation/system_requirements.adoc[System Requirements] for the latest Release. -==== - -[TIP] -==== -If required, you can skip major releases when upgrading your ownCloud installation. However, we recommend that you first upgrade to the latest point release of your respective minor version, e.g., _10.15.0_. - -If you are on ownCloud 8.2.11, 9.0.9, 9.1.X, or 10.X.Y you can go directly to the latest server version. - -Here are some examples: - -[cols=">10%,^25%,65%",options="header",stripes=even] -|=== -|Version -|Can Upgrade to {latest-server-download-version} ? -|Requirements (always check the xref:{latest-server-version}@server:admin_manual:installation/system_requirements.adoc[System Requirements] too) - -|10.X.Y -|Yes -| PHP 7.2 to 7.4 - -| 9.1.8 -| Yes -| PHP 7.0 - -| 9.1.0 -| Yes -| PHP 7.0 - -| 9.0.9 -| Yes -| PHP 7.0 - -| 9.0.8 -| *No* -| PHP 7.0, must upgrade to 9.0.9 first - -| 8.2.11 -| Yes -| PHP 5.6 or 7.0 - -| 8.2.10 -| *No* -| PHP 5.6, must upgrade to 8.2.11 first - -| 7.0.15 -| *No* -| PHP 5.6, must upgrade to 8.0.16, then to 8.1.12, and then to 8.2.11 first. - -| 7.0.10 -| *No* -| PHP 5.6, must upgrade to 7.0.15, then to 8.0.16, then to 8.1.12, and then to 8.2.11 first. -|=== -==== diff --git a/content/server/10.15/modules/admin_manual/partials/maintenance/upgrading/upgrade_steps.adoc b/content/server/10.15/modules/admin_manual/partials/maintenance/upgrading/upgrade_steps.adoc deleted file mode 100644 index f8481a1..0000000 --- a/content/server/10.15/modules/admin_manual/partials/maintenance/upgrading/upgrade_steps.adoc +++ /dev/null @@ -1,79 +0,0 @@ -= Upgrade PHP to Version {to-version} -:redhat-software-collections-overview-url: https://developers.redhat.com/products/softwarecollections/overview - -To upgrade to PHP {to-version} you first need to subscribe to {redhat-software-collections-overview-url}[the Red Hat Software Collections] channel repository to download and install the PHP {to-version} package in RHEL 7 (if you've not done this already). -This documentation uses the same command as you will find there. - -[IMPORTANT] -==== -Ensure that you have `subscription-manager` installed. -If you don't, yet, have it installed, do so with the following command: - -Install subscription manager -[source,bash] ----- -yum install --assumeyes subscription-manager ----- - -Add the required repositories for the PHP packages -[source,bash] ----- -subscription-manager repos --enable rhel-server-rhscl-7-rpms ----- -==== - -== Install the Required Packages - -Then, proceed by installing the required PHP {to-version} packages. -You can use the command below to save you time. - -[source,bash,subs="attributes+"] ----- -yum install \ - rh-php{to-pkg-version} \ - rh-php{to-pkg-version}-php \ - rh-php{to-pkg-version}-php-cli \ - rh-php{to-pkg-version}-php-curl \ - rh-php{to-pkg-version}-php-devel \ - rh-php{to-pkg-version}-php-gd \ - rh-php{to-pkg-version}-php-intl \ - rh-php{to-pkg-version}-php-ldap \ - rh-php{to-pkg-version}-php-mbstring \ - rh-php{to-pkg-version}-php-mysqlnd \ - rh-php{to-pkg-version}-php-opcache - rh-php{to-pkg-version}-php-pdo \ - rh-php{to-pkg-version}-php-pear \ - rh-php{to-pkg-version}-php-xml \ - rh-php{to-pkg-version}-php-xmlrpc \ - rh-php{to-pkg-version}-php-zip ----- - -== Enable PHP {to-version} and Disable PHP {from-version} - -Next, you need to enable PHP {to-version} and disable PHP {from-version} system-wide. -To enable PHP {to-version} system-wide, run the following command: - -[source,bash,subs="attributes+"] ----- -cp /opt/rh/rh-php{to-pkg-version}/enable /etc/profile.d/rh-php{to-pkg-version}.sh source /opt/rh/rh-php{to-pkg-version}/enable ----- - -Then, you need to disable loading of the PHP {from-version} Apache modules. -You can do this either by changing their names, as in the example below, or deleting the files. - -[source,bash,subs="attributes+"] ----- -mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php56.off -mv /etc/httpd/conf.modules.d/10-php.conf /etc/httpd/conf.modules.d/10-php56.off ----- - -== Update the Apache Configuration Files - -With that done, you next need to copy the PHP {to-version} Apache modules into place; that being the two Apache configuration files and the shared object file. - -[source,bash,subs="attributes+"] ----- -cp /opt/rh/httpd24/root/etc/httpd/conf.d/rh-php{to-pkg-version}-php.conf /etc/httpd/conf.d/ -cp /opt/rh/httpd24/root/etc/httpd/conf.modules.d/15-rh-php{to-pkg-version}-php.conf /etc/httpd/conf.modules.d/ -cp /opt/rh/httpd24/root/etc/httpd/modules/librh-php{to-pkg-version}-php7.so /etc/httpd/modules/ ----- diff --git a/content/server/10.15/modules/admin_manual/partials/nav.adoc b/content/server/10.15/modules/admin_manual/partials/nav.adoc deleted file mode 100644 index 065e4c3..0000000 --- a/content/server/10.15/modules/admin_manual/partials/nav.adoc +++ /dev/null @@ -1,184 +0,0 @@ -// note that the module reference post xref is now a mandatory element -* Admin Manual -** xref:admin_manual:index.adoc[Introduction] -** xref:admin_manual:useful_pages.adoc[Useful Pages] -** xref:admin_manual:faq/index.adoc[FAQ] -** xref:admin_manual:gdpr.adoc[GDPR] - -** Installation -*** xref:admin_manual:installation/deployment_considerations.adoc[Deployment Considerations] -*** xref:admin_manual:installation/deployment_recommendations.adoc[Deployment Recommendations] -**** xref:admin_manual:installation/deployment_recommendations/nfs.adoc[NFS] -*** xref:admin_manual:installation/system_requirements.adoc[System Requirements] -*** xref:admin_manual:installation/configuration_notes_and_tips.adoc[Configuration Notes and Tips] -*** xref:admin_manual:installation/index.adoc[Installation Options] -**** xref:admin_manual:installation/docker/index.adoc[Installing With Docker] -**** Manual Installation on Linux -***** Detailed Installation Guide -****** xref:admin_manual:installation/manual_installation/manual_installation.adoc[Detailed Installation on Ubuntu (various versions)] -***** Quick Installation Guide -****** xref:admin_manual:installation/quick_guides/ubuntu_20_04.adoc[On Ubuntu 20.04] -****** xref:admin_manual:installation/quick_guides/ubuntu_22_04.adoc[On Ubuntu 22.04] -***** Linux Package Manager -**** xref:admin_manual:installation/installation_wizard.adoc[The Installation Wizard] -*** xref:admin_manual:installation/troubleshooting.adoc[Troubleshooting] -*** xref:admin_manual:installation/changing_the_web_route.adoc[Changing Your ownCloud URL] -*** xref:admin_manual:installation/apps_management_installation.adoc[Installing and Managing Apps] -*** xref:admin_manual:installation/apps_supported.adoc[Supported Apps] -**** xref:admin_manual:installation/apps/mediaviewer/index.adoc[Media Viewer] -*** xref:admin_manual:installation/selinux_configuration.adoc[SELinux Configuration] -*** xref:admin_manual:installation/letsencrypt/index.adoc[Using Let's Encrypt SSL Certificates] -**** xref:admin_manual:installation/letsencrypt/using_letsencrypt.adoc[Using Letsencrypt] -**** xref:admin_manual:installation/letsencrypt/apache.adoc[Apache] - -** Configuration -*** xref:admin_manual:configuration/database/index.adoc[Database] -**** xref:admin_manual:configuration/database/db_conversion.adoc[Database Conversion] -**** xref:admin_manual:configuration/database/linux_database_configuration.adoc[Database Configuration] - -*** xref:admin_manual:configuration/files/encryption/index.adoc[Encryption] -**** xref:admin_manual:configuration/files/encryption/encryption_configuration.adoc[Encryption Configuration] -**** xref:admin_manual:configuration/files/encryption/encryption_configuration_quick_guide.adoc[Encryption Configuration Quick Guide] - -*** xref:admin_manual:configuration/files/external_storage/index.adoc[External Storage] -**** xref:admin_manual:configuration/files/external_storage/configuration.adoc[External Storage Configuration] -**** xref:admin_manual:configuration/files/external_storage/auth_mechanisms.adoc[External Storage Authentication Mechanisms] -**** xref:admin_manual:configuration/files/external_storage/amazons3.adoc[AmazonS3] -**** xref:admin_manual:configuration/files/external_storage/dropbox.adoc[Dropbox] -**** xref:admin_manual:configuration/files/external_storage/ftp.adoc[FTP] -**** xref:admin_manual:configuration/files/external_storage/google.adoc[Google] -**** xref:admin_manual:configuration/files/external_storage/local.adoc[Local] -**** xref:admin_manual:configuration/files/external_storage/owncloud.adoc[ownCloud] -**** xref:admin_manual:configuration/files/external_storage/s3_compatible_object_storage_as_primary.adoc[S3 as Primary] -**** xref:admin_manual:configuration/files/external_storage/sftp.adoc[SFTP] -**** xref:admin_manual:configuration/files/external_storage/smb.adoc[SMB] -**** xref:admin_manual:configuration/files/external_storage/webdav.adoc[WebDAV] - -*** xref:admin_manual:configuration/files/index.adoc[Files and Sharing] -**** xref:admin_manual:configuration/files/big_file_upload_configuration.adoc[Big File Upload Configuration] -**** xref:admin_manual:configuration/files/manual_file_locking.adoc[Manual File Locking] -**** xref:admin_manual:configuration/files/default_files_configuration.adoc[Default Files Configuration] -**** xref:admin_manual:configuration/files/federated_cloud_sharing_configuration.adoc[Federated Cloud Sharing Configuration] -**** xref:admin_manual:configuration/files/file_sharing_configuration.adoc[File Sharing Configuration] -**** xref:admin_manual:configuration/files/file_versioning.adoc[File Versioning] -**** xref:admin_manual:configuration/files/files_locking_transactional.adoc[Transactional File Locking] -**** xref:admin_manual:configuration/files/previews_configuration.adoc[Preview Configuration] -**** xref:admin_manual:configuration/files/mimetypes.adoc[Mimetypes] -**** xref:admin_manual:configuration/files/trashbin_options.adoc[Managing the Trashbin] - -*** xref:admin_manual:configuration/integration/index.adoc[Integration] -**** xref:admin_manual:configuration/integration/ms-teams.adoc[Microsoft Teams] -**** xref:admin_manual:configuration/integration/splunk.adoc[ownCloud App for Splunk] - -*** xref:admin_manual:configuration/general_topics/index.adoc[General Topics] -**** xref:admin_manual:configuration/general_topics/code_signing.adoc[Code Signing] -**** xref:admin_manual:configuration/general_topics/impersonate_users.adoc[Impersonate Users] -**** xref:admin_manual:configuration/general_topics/search.adoc[Full Text Search] - -*** xref:admin_manual:configuration/server/index.adoc[Server] -**** xref:admin_manual:configuration/server/activity_configuration.adoc[Activity Configuration] -**** xref:admin_manual:configuration/server/background_jobs_configuration.adoc[Background Jobs Configuration] -**** xref:admin_manual:configuration/server/caching_configuration.adoc[Caching Configuration] -**** xref:admin_manual:configuration/server/config_sample_php_parameters.adoc[Config Sample PHP Parameters] -**** xref:admin_manual:configuration/server/config_apps_sample_php_parameters.adoc[Config Apps Sample PHP Parameters] -**** xref:admin_manual:configuration/server/custom_client_repos.adoc[Custom Client Repos] -**** xref:admin_manual:configuration/server/email_configuration.adoc[Email Configuration] -**** xref:admin_manual:configuration/server/excluded_blacklisted_files.adoc[Excluded Blacklisted Files] -**** xref:admin_manual:configuration/server/external_sites.adoc[External Sites] -**** xref:admin_manual:configuration/server/harden_server.adoc[Harden Server] -**** xref:admin_manual:configuration/server/import_ssl_cert.adoc[Import SSL Cert] -**** xref:admin_manual:configuration/server/index_php_less_urls.adoc[Index PHP Less URLs] -**** xref:admin_manual:configuration/server/occ_command.adoc[OCC Command] -**** xref:admin_manual:configuration/server/language_configuration.adoc[Language Configuration] -**** xref:admin_manual:configuration/server/legal_settings_configuration.adoc[Legal Settings Configuration] -**** Logging -***** xref:admin_manual:configuration/server/logging/logging_configuration.adoc[Logging Configuration] -***** xref:admin_manual:configuration/server/logging/request_tracing.adoc[Request Tracing] -**** xref:admin_manual:configuration/server/reverse_proxy_configuration.adoc[Reverse Proxy Configuration] -**** xref:admin_manual:configuration/server/security/index.adoc[Security] -***** xref:admin_manual:configuration/server/security/brute_force_protection.adoc[Brute-Force Protection] -***** xref:admin_manual:configuration/server/security/oauth2.adoc[OAuth2] -***** xref:admin_manual:configuration/server/security/password_policy.adoc[Password policy] -***** xref:admin_manual:configuration/server/security_setup_warnings.adoc[Security Setup Warnings] -***** xref:admin_manual:configuration/server/security/hsmdaemon/index.adoc[The HSM (Hardware Security Module) Daemon] -***** xref:admin_manual:configuration/server/security/dependency_notes.adoc[Dependency Notes] -**** xref:admin_manual:configuration/server/oc_server_tuning.adoc[Server Tuning] -**** xref:admin_manual:configuration/server/thirdparty_php_configuration.adoc[Third Party PHP Configuration] -**** xref:admin_manual:configuration/server/virus-scanner-support.adoc[Virus Scanner Support] -**** xref:admin_manual:configuration/server/ui-configuration.adoc[UI Configuration] - -*** User -**** xref:admin_manual:configuration/user/user_management.adoc[User Management] -**** xref:admin_manual:configuration/user/user_roles.adoc[User Roles] -**** xref:admin_manual:configuration/user/reset_admin_password.adoc[Reset Admin Password] -**** xref:admin_manual:configuration/user/reset_user_password.adoc[Reset User Password] -**** xref:admin_manual:configuration/user/user_auth_ftp_smb_imap.adoc[User Auth FTP SMB IMAP] -**** xref:admin_manual:configuration/user/user_auth_ldap.adoc[User Auth LDAP] -**** xref:admin_manual:configuration/user/user_auth_twofactor.adoc[User Auth Two-Factor] -**** xref:admin_manual:configuration/user/user_oauth2.adoc[User Auth OAuth2] -**** xref:admin_manual:configuration/user/user_provisioning_api.adoc[User Provisioning API] -**** xref:admin_manual:configuration/user/custom_groups_app.adoc[Custom Groups App] -**** xref:admin_manual:configuration/user/guests_app.adoc[Guests App] -**** xref:admin_manual:configuration/user/oidc/oidc.adoc[OpenID Connect (OIDC)] -**** xref:admin_manual:configuration/user/login_policies.adoc[Login Policies] - -** Maintenance -*** xref:admin_manual:maintenance/upgrading/upgrade.adoc[Upgrading] -**** xref:admin_manual:maintenance/upgrading/manual_upgrade.adoc[Manual Upgrade] -**** xref:admin_manual:maintenance/upgrading/database_upgrade.adoc[Database Upgrade] -**** xref:admin_manual:maintenance/upgrading/upgrade_php.adoc[Upgrading PHP] -**** xref:admin_manual:maintenance/upgrading/marketplace_apps.adoc[Marketplace Apps] -*** Backup and Restore -**** xref:admin_manual:maintenance/backup_and_restore/backup.adoc[Backup] -**** xref:admin_manual:maintenance/backup_and_restore/restore.adoc[Restore] -*** xref:admin_manual:maintenance/enable_maintenance.adoc[Maintenance Mode] -*** xref:admin_manual:maintenance/export_import_instance_data.adoc[Export and Import Instance Data] -*** xref:admin_manual:maintenance/manually-moving-data-folders.adoc[Manually Moving Data Folders] -*** Encryption -**** xref:admin_manual:maintenance/encryption/migrating-from-user-key-to-master-key.adoc[Migrating from User Key to Master Key Encryption] -*** xref:admin_manual:maintenance/migrating.adoc[Migrating to a Different Server] -*** xref:admin_manual:maintenance/migrating_to_kiteworks.adoc[Migrating to Kiteworks PDN] -*** xref:admin_manual:maintenance/migrating_to_ocis.adoc[Migrating to ownCloud Infinite Scale] - -** Enterprise -*** Authentication -**** xref:admin_manual:enterprise/authentication/enterprise_only_auth.adoc[Enterprise Only Authentication] -**** xref:admin_manual:enterprise/authentication/kerberos.adoc[Kerberos Authentication] -*** Clients -**** xref:admin_manual:enterprise/clients/custom_client_repos.adoc[Custom Client Repos] -*** Collaboration -**** xref:admin_manual:enterprise/collaboration/collabora_secure_view.adoc[Collabora Online / Secure View] -**** xref:admin_manual:enterprise/collaboration/msoffice-wopi-integration.adoc[Microsoft Office Online / WOPI Integration] -*** Document Classification -**** xref:admin_manual:enterprise/document_classification/classification_and_policy_enforcement.adoc[Classify Documents and Enforce Policies] -*** External Storage -**** xref:admin_manual:enterprise/external_storage/ldap_home_connector_configuration.adoc[LDAP Home Connector Configuration] -**** xref:admin_manual:enterprise/external_storage/sharepoint-integration_configuration.adoc[Sharepoint integration Configuration] -**** xref:admin_manual:enterprise/external_storage/windows-network-drive_configuration.adoc[Windows Network Drive Configuration] -**** xref:admin_manual:enterprise/external_storage/wnd_quick_guide.adoc[WND Configuration Quick Guide] -*** File Management -**** xref:admin_manual:enterprise/file_management/files_tagging.adoc[File Tagging] -**** xref:admin_manual:enterprise/file_management/files_lifecycle.adoc[File Lifecycle Management] -*** Firewall -**** xref:admin_manual:enterprise/firewall/file_firewall.adoc[File Firewall] -*** Installation -**** xref:admin_manual:enterprise/installation/install.adoc[Installing & Upgrading ownCloud Enterprise Edition] -**** xref:admin_manual:enterprise/installation/oracle_db_configuration.adoc[Oracle DB Setup & Configuration] -*** Logging -**** xref:admin_manual:enterprise/logging/admin_audit.adoc[Auditing] -*** Reporting -**** xref:admin_manual:enterprise/reporting/metrics.adoc[Metrics] -**** xref:admin_manual:enterprise/reporting/config_report.adoc[Generate a Config Report] -*** Security -**** xref:admin_manual:enterprise/security/ransomware-protection.adoc[Ransomware Protection] -*** User Management -**** xref:admin_manual:enterprise/user_management/user_auth_shibboleth.adoc[Shibboleth Integration] -**** xref:admin_manual:enterprise/user_management/saml_2.0_sso.adoc[SAML 2.0 Based SSO] - -** Troubleshooting -*** xref:admin_manual:troubleshooting/general_troubleshooting.adoc[General Troubleshooting] -*** xref:admin_manual:troubleshooting/path_filename_length.adoc[Path and Filename Length Limitations] -*** xref:admin_manual:troubleshooting/providing_logs_and_config_files.adoc[Retrieve Log Files and Configuration Settings] -*** xref:admin_manual:troubleshooting/remove_non_existent_bg_jobs.adoc[Remove Non-Existent Background Jobs] - -** xref:admin_manual:found_a_mistake.adoc[Found a Mistake?] diff --git a/content/server/10.15/modules/admin_manual/partials/section_page.adoc b/content/server/10.15/modules/admin_manual/partials/section_page.adoc deleted file mode 100644 index f764675..0000000 --- a/content/server/10.15/modules/admin_manual/partials/section_page.adoc +++ /dev/null @@ -1,3 +0,0 @@ -= {section-title} - -In this section you will find all the details you need {section-preamble-ender}. diff --git a/content/server/10.15/modules/classic_ui/attachments/.gitkeep b/content/server/10.15/modules/classic_ui/attachments/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/content/server/10.15/modules/classic_ui/examples/.gitkeep b/content/server/10.15/modules/classic_ui/examples/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/content/server/10.15/modules/classic_ui/images/apps/activity/activity-menu.png b/content/server/10.15/modules/classic_ui/images/apps/activity/activity-menu.png deleted file mode 100644 index 49e3211..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/activity/activity-menu.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/activity/activity-settings-limit-to-favorites.png b/content/server/10.15/modules/classic_ui/images/apps/activity/activity-settings-limit-to-favorites.png deleted file mode 100644 index a68cd04..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/activity/activity-settings-limit-to-favorites.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/activity/activity-settings.png b/content/server/10.15/modules/classic_ui/images/apps/activity/activity-settings.png deleted file mode 100644 index 0869525..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/activity/activity-settings.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/activity/all-activity.png b/content/server/10.15/modules/classic_ui/images/apps/activity/all-activity.png deleted file mode 100644 index 4ace265..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/activity/all-activity.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/activity/comment-activity.png b/content/server/10.15/modules/classic_ui/images/apps/activity/comment-activity.png deleted file mode 100644 index bbd581b..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/activity/comment-activity.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/market/login-step-1.png b/content/server/10.15/modules/classic_ui/images/apps/market/login-step-1.png deleted file mode 100644 index f9f21b4..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/market/login-step-1.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/market/login-step-2.png b/content/server/10.15/modules/classic_ui/images/apps/market/login-step-2.png deleted file mode 100644 index a7f2213..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/market/login-step-2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/market/login-step-3.png b/content/server/10.15/modules/classic_ui/images/apps/market/login-step-3.png deleted file mode 100644 index f5e0d64..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/market/login-step-3.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/market/login-step-4.png b/content/server/10.15/modules/classic_ui/images/apps/market/login-step-4.png deleted file mode 100644 index b8be1b3..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/market/login-step-4.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/apps/market/top-level-navigation-bar-highlighting-the-market-app.png b/content/server/10.15/modules/classic_ui/images/apps/market/top-level-navigation-bar-highlighting-the-market-app.png deleted file mode 100644 index ed6d34b..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/apps/market/top-level-navigation-bar-highlighting-the-market-app.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/collaboration/secure-view/access-denied.png b/content/server/10.15/modules/classic_ui/images/collaboration/secure-view/access-denied.png deleted file mode 100644 index e254112..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/collaboration/secure-view/access-denied.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/collaboration/secure-view/secure-view-share-configuration-options.png b/content/server/10.15/modules/classic_ui/images/collaboration/secure-view/secure-view-share-configuration-options.png deleted file mode 100644 index c59fe42..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/collaboration/secure-view/secure-view-share-configuration-options.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/contact_thunderbird-Symbol_Gear.jpg b/content/server/10.15/modules/classic_ui/images/contact_thunderbird-Symbol_Gear.jpg deleted file mode 100755 index d9f6041..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/contact_thunderbird-Symbol_Gear.jpg and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/contact_thunderbird-Symbol_Impeller.jpg b/content/server/10.15/modules/classic_ui/images/contact_thunderbird-Symbol_Impeller.jpg deleted file mode 100755 index a3e7fe5..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/contact_thunderbird-Symbol_Impeller.jpg and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/contact_thunderbird-URL_config.jpg b/content/server/10.15/modules/classic_ui/images/contact_thunderbird-URL_config.jpg deleted file mode 100755 index 9ab48fa..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/contact_thunderbird-URL_config.jpg and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/create_public_share-10.png b/content/server/10.15/modules/classic_ui/images/create_public_share-10.png deleted file mode 100644 index 2654449..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/create_public_share-10.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/create_public_share-6.png b/content/server/10.15/modules/classic_ui/images/create_public_share-6.png deleted file mode 100644 index 363a3c8..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/create_public_share-6.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/create_public_share-8.png b/content/server/10.15/modules/classic_ui/images/create_public_share-8.png deleted file mode 100644 index 66eee60..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/create_public_share-8.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/create_public_share-9.png b/content/server/10.15/modules/classic_ui/images/create_public_share-9.png deleted file mode 100644 index f53e451..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/create_public_share-9.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/direct-share-1.png b/content/server/10.15/modules/classic_ui/images/direct-share-1.png deleted file mode 100644 index 653ca7e..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/direct-share-1.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/download.png b/content/server/10.15/modules/classic_ui/images/download.png deleted file mode 100644 index 0f71a5a..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/download.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/encryption1.png b/content/server/10.15/modules/classic_ui/images/encryption1.png deleted file mode 100644 index d818d84..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/encryption1.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/encryption2.png b/content/server/10.15/modules/classic_ui/images/encryption2.png deleted file mode 100644 index 8a83bcc..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/encryption2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/encryption3.png b/content/server/10.15/modules/classic_ui/images/encryption3.png deleted file mode 100644 index 6cb152f..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/encryption3.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/access-denied.png b/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/access-denied.png deleted file mode 100644 index e254112..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/access-denied.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/collabora-online-administration.png b/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/collabora-online-administration.png deleted file mode 100644 index 8499c15..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/collabora-online-administration.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/secure-view-share-configuration-options.png b/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/secure-view-share-configuration-options.png deleted file mode 100644 index c59fe42..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/enterprise/collaboration/secure-view/secure-view-share-configuration-options.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/explorer_webdav.png b/content/server/10.15/modules/classic_ui/images/explorer_webdav.png deleted file mode 100644 index 23cd8f4..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/explorer_webdav.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/file_menu_comments_2.png b/content/server/10.15/modules/classic_ui/images/file_menu_comments_2.png deleted file mode 100644 index af40f3a..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/file_menu_comments_2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/file_popup-menu.png b/content/server/10.15/modules/classic_ui/images/file_popup-menu.png deleted file mode 100644 index f72b9e4..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/file_popup-menu.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/access_webdav/advanced-sharing-settings.png b/content/server/10.15/modules/classic_ui/images/files/access_webdav/advanced-sharing-settings.png deleted file mode 100644 index b1ee109..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/access_webdav/advanced-sharing-settings.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/access_webdav/dolphin-add-network-folder.png b/content/server/10.15/modules/classic_ui/images/files/access_webdav/dolphin-add-network-folder.png deleted file mode 100644 index 6a0ac2e..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/access_webdav/dolphin-add-network-folder.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/access_webdav/dolphin-network-folder-wizard.png b/content/server/10.15/modules/classic_ui/images/files/access_webdav/dolphin-network-folder-wizard.png deleted file mode 100644 index f942beb..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/access_webdav/dolphin-network-folder-wizard.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-discovery.png b/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-discovery.png deleted file mode 100644 index 2ff8dd8..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-discovery.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-internet.png b/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-internet.png deleted file mode 100644 index fae03fe..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-internet.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-sharing-center.png b/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-sharing-center.png deleted file mode 100644 index 6d8f265..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/access_webdav/network-sharing-center.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/activity-pane.png b/content/server/10.15/modules/classic_ui/images/files/activity-pane.png deleted file mode 100644 index d8bf8cd..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/activity-pane.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/lifecycle-1.png b/content/server/10.15/modules/classic_ui/images/files/lifecycle-1.png deleted file mode 100644 index 01b8595..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/lifecycle-1.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/lifecycle-2.png b/content/server/10.15/modules/classic_ui/images/files/lifecycle-2.png deleted file mode 100644 index efb8e52..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/lifecycle-2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/lifecycle-3.png b/content/server/10.15/modules/classic_ui/images/files/lifecycle-3.png deleted file mode 100644 index da07223..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/lifecycle-3.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-details.png b/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-details.png deleted file mode 100644 index 1719816..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-details.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-hint.png b/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-hint.png deleted file mode 100644 index e8e0417..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-hint.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-symbol.png b/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-symbol.png deleted file mode 100644 index cfde1fb..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-symbol.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-unlock-symbol.png b/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-unlock-symbol.png deleted file mode 100644 index 63d1b76..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/file-locked-unlock-symbol.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/lock-file-not-visible.png b/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/lock-file-not-visible.png deleted file mode 100644 index e22e397..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/lock-file-not-visible.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/lock-file-visible.png b/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/lock-file-visible.png deleted file mode 100644 index c8ee3d9..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/lock-file-visible.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/manual-file-locking-without-lock-breaker.png b/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/manual-file-locking-without-lock-breaker.png deleted file mode 100644 index d5434e3..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/manual_file_locking/manual-file-locking-without-lock-breaker.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/webgui/files_page-2.png b/content/server/10.15/modules/classic_ui/images/files/webgui/files_page-2.png deleted file mode 100644 index 91b40b5..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/webgui/files_page-2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/webgui/files_page-5.png b/content/server/10.15/modules/classic_ui/images/files/webgui/files_page-5.png deleted file mode 100644 index 7f0aa59..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/webgui/files_page-5.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/webgui/files_share-options.png b/content/server/10.15/modules/classic_ui/images/files/webgui/files_share-options.png deleted file mode 100644 index 14e9dc1..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/webgui/files_share-options.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files/webgui/share-with-multiple-users.png b/content/server/10.15/modules/classic_ui/images/files/webgui/share-with-multiple-users.png deleted file mode 100644 index 78253e3..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files/webgui/share-with-multiple-users.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_file-controls.png b/content/server/10.15/modules/classic_ui/images/files_file-controls.png deleted file mode 100644 index 336f4d9..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_file-controls.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_mark-as-favorite.png b/content/server/10.15/modules/classic_ui/images/files_mark-as-favorite.png deleted file mode 100644 index 6139e1c..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_mark-as-favorite.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_page-3.png b/content/server/10.15/modules/classic_ui/images/files_page-3.png deleted file mode 100644 index d145d67..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_page-3.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_page-4.png b/content/server/10.15/modules/classic_ui/images/files_page-4.png deleted file mode 100644 index a26bd60..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_page-4.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_page-6.png b/content/server/10.15/modules/classic_ui/images/files_page-6.png deleted file mode 100644 index d88afd9..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_page-6.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_page-7.png b/content/server/10.15/modules/classic_ui/images/files_page-7.png deleted file mode 100644 index 6dcf178..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_page-7.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_page-8.png b/content/server/10.15/modules/classic_ui/images/files_page-8.png deleted file mode 100644 index c8c57f6..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_page-8.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_page.png b/content/server/10.15/modules/classic_ui/images/files_page.png deleted file mode 100644 index bffcfb6..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_page.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_versioning/concious-persistent-major-versions.png b/content/server/10.15/modules/classic_ui/images/files_versioning/concious-persistent-major-versions.png deleted file mode 100644 index b0ef927..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_versioning/concious-persistent-major-versions.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_view_mouseover.png b/content/server/10.15/modules/classic_ui/images/files_view_mouseover.png deleted file mode 100644 index d26140d..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_view_mouseover.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/files_view_select_all.png b/content/server/10.15/modules/classic_ui/images/files_view_select_all.png deleted file mode 100644 index fbd0aaa..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/files_view_select_all.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/gallery-1.png b/content/server/10.15/modules/classic_ui/images/gallery-1.png deleted file mode 100644 index ecefaaf..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/gallery-1.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/gallery-2.png b/content/server/10.15/modules/classic_ui/images/gallery-2.png deleted file mode 100644 index ccf48f8..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/gallery-2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/guest-users/content-shared-with-guest-user.png b/content/server/10.15/modules/classic_ui/images/guest-users/content-shared-with-guest-user.png deleted file mode 100644 index 76a49cc..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/guest-users/content-shared-with-guest-user.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/guest-users/share-with-guest-users.png b/content/server/10.15/modules/classic_ui/images/guest-users/share-with-guest-users.png deleted file mode 100644 index 63c1be7..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/guest-users/share-with-guest-users.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/hidden_files.png b/content/server/10.15/modules/classic_ui/images/hidden_files.png deleted file mode 100644 index b328aeb..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/hidden_files.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/integration/ms-teams/login-to-owncloud-with-azure-ad.png b/content/server/10.15/modules/classic_ui/images/integration/ms-teams/login-to-owncloud-with-azure-ad.png deleted file mode 100644 index ca2c94b..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/integration/ms-teams/login-to-owncloud-with-azure-ad.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/integration/ms-teams/owncloud-teams-app.png b/content/server/10.15/modules/classic_ui/images/integration/ms-teams/owncloud-teams-app.png deleted file mode 100644 index 7ce9322..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/integration/ms-teams/owncloud-teams-app.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes.png b/content/server/10.15/modules/classic_ui/images/kdes.png deleted file mode 100644 index ade0878..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes1.png b/content/server/10.15/modules/classic_ui/images/kdes1.png deleted file mode 100644 index 81bea21..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes1.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes2.png b/content/server/10.15/modules/classic_ui/images/kdes2.png deleted file mode 100644 index 61fd09c..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes3.png b/content/server/10.15/modules/classic_ui/images/kdes3.png deleted file mode 100644 index 24739d0..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes3.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes4.png b/content/server/10.15/modules/classic_ui/images/kdes4.png deleted file mode 100644 index 02a5ce1..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes4.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes5.png b/content/server/10.15/modules/classic_ui/images/kdes5.png deleted file mode 100644 index aa6065b..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes5.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes6.png b/content/server/10.15/modules/classic_ui/images/kdes6.png deleted file mode 100644 index 29b928b..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes6.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes7.png b/content/server/10.15/modules/classic_ui/images/kdes7.png deleted file mode 100644 index 8cf9bb1..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes7.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/kdes9.png b/content/server/10.15/modules/classic_ui/images/kdes9.png deleted file mode 100644 index ca0812c..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/kdes9.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/media-viewer-app/app-overview.png b/content/server/10.15/modules/classic_ui/images/media-viewer-app/app-overview.png deleted file mode 100644 index 1c916f4..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/media-viewer-app/app-overview.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/oc_connect.jpg b/content/server/10.15/modules/classic_ui/images/oc_connect.jpg deleted file mode 100644 index 4728781..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/oc_connect.jpg and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/oc_documents_edit.odg b/content/server/10.15/modules/classic_ui/images/oc_documents_edit.odg deleted file mode 100644 index b684f5e..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/oc_documents_edit.odg and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/osx_webdav1.png b/content/server/10.15/modules/classic_ui/images/osx_webdav1.png deleted file mode 100644 index c2f27c1..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/osx_webdav1.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/osx_webdav2.png b/content/server/10.15/modules/classic_ui/images/osx_webdav2.png deleted file mode 100644 index 26248e4..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/osx_webdav2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/owncloud_webinterface.kra b/content/server/10.15/modules/classic_ui/images/owncloud_webinterface.kra deleted file mode 100644 index 0d45414..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/owncloud_webinterface.kra and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/manage-group-members.png b/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/manage-group-members.png deleted file mode 100644 index 117edcf..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/manage-group-members.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/rename-custom-group.png b/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/rename-custom-group.png deleted file mode 100644 index 1f4a807..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/rename-custom-group.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/share-to-custom-group.png b/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/share-to-custom-group.png deleted file mode 100644 index e79601f..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/share-to-custom-group.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/user_settings_custom_groups.png b/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/user_settings_custom_groups.png deleted file mode 100644 index 11d4e4f..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/custom-groups/user_settings_custom_groups.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/account-related-settings.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/account-related-settings.png deleted file mode 100644 index 3f6bc8b..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/account-related-settings.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/auto-save-fullname.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/auto-save-fullname.png deleted file mode 100644 index b7fdcd6..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/auto-save-fullname.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/cannot-change-fullname.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/cannot-change-fullname.png deleted file mode 100644 index 594f78e..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/cannot-change-fullname.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/choose-profile-picture-button.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/choose-profile-picture-button.png deleted file mode 100644 index 2184573..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/choose-profile-picture-button.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/general.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/general.png deleted file mode 100644 index 4334f85..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/general.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/other.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/other.png deleted file mode 100644 index 952c12d..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/other.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/profile-picture-overview-annotated.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/profile-picture-overview-annotated.png deleted file mode 100644 index 8bea5c6..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/profile-picture-overview-annotated.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/profile-picture-overview.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/profile-picture-overview.png deleted file mode 100644 index a44daa1..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/profile-picture-overview.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/remove-profile-picture-button.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/remove-profile-picture-button.png deleted file mode 100644 index cffd376..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/remove-profile-picture-button.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/select-profile-picture.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/select-profile-picture.png deleted file mode 100644 index 4b28074..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/select-profile-picture.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/set-profile-picture.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/set-profile-picture.png deleted file mode 100644 index 789d84d..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/set-profile-picture.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-email-successfully.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-email-successfully.png deleted file mode 100644 index c2f0a26..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-email-successfully.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-language.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-language.png deleted file mode 100644 index a5dce35..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-language.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-password.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-password.png deleted file mode 100644 index 91faa77..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/update-password.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/general/upload-profile-picture.png b/content/server/10.15/modules/classic_ui/images/personal-settings/general/upload-profile-picture.png deleted file mode 100644 index 2629f03..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/general/upload-profile-picture.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/oc_personal_settings_dropdown.png b/content/server/10.15/modules/classic_ui/images/personal-settings/oc_personal_settings_dropdown.png deleted file mode 100644 index 9627226..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/oc_personal_settings_dropdown.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/personal-settings-menu.png b/content/server/10.15/modules/classic_ui/images/personal-settings/personal-settings-menu.png deleted file mode 100644 index 00f9710..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/personal-settings-menu.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/activate-2fa-totp.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/activate-2fa-totp.png deleted file mode 100644 index 56b4061..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/activate-2fa-totp.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/app-password-tokens-section.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/app-password-tokens-section.png deleted file mode 100644 index 6be8b65..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/app-password-tokens-section.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/confirm-cors-white-listed-domain-removal.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/confirm-cors-white-listed-domain-removal.png deleted file mode 100644 index 907d8f6..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/confirm-cors-white-listed-domain-removal.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/cors-section-with-white-listed-domains.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/cors-section-with-white-listed-domains.png deleted file mode 100644 index cbcb991..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/cors-section-with-white-listed-domains.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/cors-section.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/cors-section.png deleted file mode 100644 index 2d7faf7..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/cors-section.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/create-new-app-password-token.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/create-new-app-password-token.png deleted file mode 100644 index 5da7e9d..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/create-new-app-password-token.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/disconnect-button.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/disconnect-button.png deleted file mode 100644 index 89caf90..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/disconnect-button.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/enable-2fa-totp.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/enable-2fa-totp.png deleted file mode 100644 index cde078f..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/enable-2fa-totp.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/security/sessions-section.png b/content/server/10.15/modules/classic_ui/images/personal-settings/security/sessions-section.png deleted file mode 100644 index 532ff2f..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/security/sessions-section.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/sharing/sharing.png b/content/server/10.15/modules/classic_ui/images/personal-settings/sharing/sharing.png deleted file mode 100644 index 813d554..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/sharing/sharing.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/personal-settings/storage/external-storage.png b/content/server/10.15/modules/classic_ui/images/personal-settings/storage/external-storage.png deleted file mode 100644 index 2018a25..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/personal-settings/storage/external-storage.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/public-link/create-public-link.png b/content/server/10.15/modules/classic_ui/images/public-link/create-public-link.png deleted file mode 100644 index 7690b6a..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/public-link/create-public-link.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/public-link/private-link.png b/content/server/10.15/modules/classic_ui/images/public-link/private-link.png deleted file mode 100644 index b80f65b..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/public-link/private-link.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-ee-file.png b/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-ee-file.png deleted file mode 100644 index 55f4ad5..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-ee-file.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-file.png b/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-file.png deleted file mode 100644 index 730198e..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-file.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-folder.png b/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-folder.png deleted file mode 100644 index f33bd00..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/public-link/public-link-settings-folder.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/quota1.png b/content/server/10.15/modules/classic_ui/images/quota1.png deleted file mode 100644 index 84f9b4d..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/quota1.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/session_management/app_passwords.png b/content/server/10.15/modules/classic_ui/images/session_management/app_passwords.png deleted file mode 100644 index 88a5f3c..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/session_management/app_passwords.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/session_management/sessions.png b/content/server/10.15/modules/classic_ui/images/session_management/sessions.png deleted file mode 100644 index 2031c6d..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/session_management/sessions.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/session_management/settings_sessions.png b/content/server/10.15/modules/classic_ui/images/session_management/settings_sessions.png deleted file mode 100644 index b10ad49..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/session_management/settings_sessions.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/settings_devices.png b/content/server/10.15/modules/classic_ui/images/settings_devices.png deleted file mode 100644 index 2407ead..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/settings_devices.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/settings_devices_add.png b/content/server/10.15/modules/classic_ui/images/settings_devices_add.png deleted file mode 100644 index 96e40c7..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/settings_devices_add.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/share.png b/content/server/10.15/modules/classic_ui/images/share.png deleted file mode 100644 index fdacbba..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/share.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/sharing/create-drop-folder.png b/content/server/10.15/modules/classic_ui/images/sharing/create-drop-folder.png deleted file mode 100644 index 9fffe47..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/sharing/create-drop-folder.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/sharing/restore-files.png b/content/server/10.15/modules/classic_ui/images/sharing/restore-files.png deleted file mode 100644 index 03996c7..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/sharing/restore-files.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/sharing/use-drop-folders.png b/content/server/10.15/modules/classic_ui/images/sharing/use-drop-folders.png deleted file mode 100644 index af3aaa0..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/sharing/use-drop-folders.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/video_player_2.png b/content/server/10.15/modules/classic_ui/images/video_player_2.png deleted file mode 100644 index 1f5bf49..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/video_player_2.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/webdav_dolphin.png b/content/server/10.15/modules/classic_ui/images/webdav_dolphin.png deleted file mode 100644 index 8213d2d..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/webdav_dolphin.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/images/webdav_gnome3_nautilus.png b/content/server/10.15/modules/classic_ui/images/webdav_gnome3_nautilus.png deleted file mode 100644 index bf55d9a..0000000 Binary files a/content/server/10.15/modules/classic_ui/images/webdav_gnome3_nautilus.png and /dev/null differ diff --git a/content/server/10.15/modules/classic_ui/notes_for_the_navigation_file_nav.txt b/content/server/10.15/modules/classic_ui/notes_for_the_navigation_file_nav.txt deleted file mode 100644 index f86388b..0000000 --- a/content/server/10.15/modules/classic_ui/notes_for_the_navigation_file_nav.txt +++ /dev/null @@ -1,13 +0,0 @@ -The navigation files have been relocated and are accessed differently now. - -The main nav.adoc file is in ROOT and includes all nav.adoc files from the modules. To do so, the modules nav.adoc files needed to be relocated from: - -{modulesdir}/nav.adoc -to -{modulesdir}/partials/nav.adoc - -This is due to the fact that "Antora does not classify files located at the root of the module or in the modules folder" which means, there is no access path to a nav.adoc file which is located in the root of a module. - -As a result, the antora.yml file only contains the main ROOT/nav.adoc file. - -This is beneficial, as we now can structure products and their content in a better way. diff --git a/content/server/10.15/modules/classic_ui/pages/apps/activity.adoc b/content/server/10.15/modules/classic_ui/pages/apps/activity.adoc deleted file mode 100644 index 42af8d4..0000000 --- a/content/server/10.15/modules/classic_ui/pages/apps/activity.adoc +++ /dev/null @@ -1,59 +0,0 @@ -= The Activity App -:toc: right -:description: The ownCloud Activity app gathers all your file or folder related actions in one place for you to review and can notify you about them via email as well. - -== Introduction - -{description} You can decide, in detail, which file and folder actions are listed in the Activity stream, and for which file or folder actions to receive email notifications. By using the app, you can ensure that you never miss an important event related to content in ownCloud and always be up-to-date on all activities of your files and folders. - -[TIP] -==== -The Activity App is shipped and enabled by default. If it is not enabled, contact your ownCloud administrator to have it enabled. -==== - -== Viewing Notifications - -To view notifications, click the hamburger menu, in the top left-hand corner of the WebUI, and then click "_Activity_", as you can see in the screenshot below. - -image::apps/activity/activity-menu.png[View activity in ownCloud's WebUI.] - -By default, you see all activity related to your files and folders. However, by using the left-hand navigation menu, you can filter activities by: - -* Activities by you -* Activities by others -* Favorites -* Comments -* Shares - -image::apps/activity/comment-activity.png[View comment activity in ownCloud's WebUI.] - -== Configuring the Activity App - -To configure your Activity preferences, navigate to menu:Settings[Personal > General > Activity]. You can configure notifications for events like: - -* Files and folders are created, changed, deleted, restored (from the trash bin), and shared. -* Files and folders are shared from another server. -* A publicly shared file or folder was downloaded. -* Comments are added to a file. -* System tags for a file have been modified. - -To do so, enable or disable the relevant checkboxes in the Activity settings panel, as in the screenshot below. - -image::apps/activity/activity-settings.png[Configure activity settings in ownCloud's WebUI.] - -TIP: Sharing actions are only visible to the sharer and recipient. - -=== Limiting Notifications - -For users with lots of activity, it is possible to limit the Activity stream to 'Favorites' to avoid noise. - -image::apps/activity/activity-settings-limit-to-favorites.png[Limit activity settings to Favorites only in ownCloud's WebUI.] - -=== Configuring the Email Notification Interval - -In addition to enabling and disabling email notifications, bulk email notifications can be configured to be sent out: _As soon as possible_ (during the next cron execution), _Hourly_, _Daily_, and _Weekly_. To do so, pick the interval in the "_Send emails:_" drop-down field at the bottom of the Activity configuration panel. - -== Time Base - -* An admin can define a default date for shares to expire, which you can change if needed. Whenever a date is set for expiring shares (e.g. after 7 days), the share expires at the end of that day. The time base is the time of the ownCloud server, not the time of the client accessing the ownCloud server. -* When a client receives an expiry notification for a share, the expiry is effective at the end of the day based on the time of the ownCloud server and not the time of the client accessing ownCloud server. diff --git a/content/server/10.15/modules/classic_ui/pages/apps/calendar.adoc b/content/server/10.15/modules/classic_ui/pages/apps/calendar.adoc deleted file mode 100644 index 568505b..0000000 --- a/content/server/10.15/modules/classic_ui/pages/apps/calendar.adoc +++ /dev/null @@ -1,4 +0,0 @@ -= Using the Calendar App -:description: The Calendar app is not enabled by default in ownCloud and needs to be enabled separately. You can download it via {oc-marketplace-url}/apps/market[the market app]. - -{description} diff --git a/content/server/10.15/modules/classic_ui/pages/apps/contacts.adoc b/content/server/10.15/modules/classic_ui/pages/apps/contacts.adoc deleted file mode 100644 index bac1ca1..0000000 --- a/content/server/10.15/modules/classic_ui/pages/apps/contacts.adoc +++ /dev/null @@ -1,5 +0,0 @@ -= Using the Contacts App -:description: The Contacts app is not enabled by default in ownCloud and needs to be enabled separately. You can download it via {oc-marketplace-url}/apps/market[the market app]. - -{description} - diff --git a/content/server/10.15/modules/classic_ui/pages/apps/index.adoc b/content/server/10.15/modules/classic_ui/pages/apps/index.adoc deleted file mode 100644 index 53ed39d..0000000 --- a/content/server/10.15/modules/classic_ui/pages/apps/index.adoc +++ /dev/null @@ -1,4 +0,0 @@ -:section-title: Apps -:section-preamble-ender: on some of the core apps available with ownCloud - -include::partial$section_page.adoc[] diff --git a/content/server/10.15/modules/classic_ui/pages/apps/market.adoc b/content/server/10.15/modules/classic_ui/pages/apps/market.adoc deleted file mode 100644 index 7788dc6..0000000 --- a/content/server/10.15/modules/classic_ui/pages/apps/market.adoc +++ /dev/null @@ -1,28 +0,0 @@ -= The Market App -:keywords: ownCloud Marketplace, ownCloud Market, apps -:description: Here you will find out all you need to know about working with ownCloud's Market app. - -== Log in to the Marketplace From the Market App - -{description} To log in to {oc-marketplace-url}[the ownCloud Marketplace] from the Market app, open the Market app by clicking on the Market app icon in the top-level ownCloud navigation menu, which you can see above. - -image:apps/market/top-level-navigation-bar-highlighting-the-market-app.png[The Market app in the ownCloud top-level navigation menu] - -Once on the Market app, click btn:[LOGIN], located at the bottom of the left-hand side navigation menu. - -image:apps/market/login-step-1.png[Log in to the Marketplace from the Market App, step 1] - -You are next asked to grant the Market app access to your Marketplace account. -Enter your Marketplace username and password and click btn:[LOGIN]. - -image:apps/market/login-step-2.png[Log in to the Marketplace from the Market App, step 2] - -Next, confirm your request to grant the Market app access to your Marketplace account. -To give this confirmation, click btn:[GRANT ACCESS]. - -image:apps/market/login-step-3.png[Log in to the Marketplace from the Market App, step 3] - -Once you've done this, you are redirected back to the Market app in your ownCloud installation. -The original "_LOGIN_" button is now greyed out and labelled "_LOGGED IN_". - -image:apps/market/login-step-4.png[Log in to the Marketplace from the Market App, step 4] diff --git a/content/server/10.15/modules/classic_ui/pages/apps/media_viewer_app.adoc b/content/server/10.15/modules/classic_ui/pages/apps/media_viewer_app.adoc deleted file mode 100644 index 55437f0..0000000 --- a/content/server/10.15/modules/classic_ui/pages/apps/media_viewer_app.adoc +++ /dev/null @@ -1,44 +0,0 @@ -= The Media Viewer App -:browser-image-support-url: https://en.wikipedia.org/wiki/Comparison_of_web_browsers#Image_format_support -:webm-url: https://www.webmproject.org/ -:ogg-url: https://xiph.org/vorbis/ -:mp4-url: https://en.wikipedia.org/wiki/MPEG-4_Part_14 -:media-viewer-app-url: {oc-marketplace-url}/apps/files_mediaviewer -:description: The {media-viewer-app-url}[Media Viewer app] is a lightweight viewer for pictures and videos which integrates with the files app, and is released under the GPLv2. - - -== Introduction - -{description} It replaces the gallery and files_videoplayer apps, which have now been deprecated, and supports the same basic feature set as the deprecated apps. - -It supports the following functionality: - -* *Image*: _preview_, _zoom_, _rotation_, and _download_ -* *Video*: _playback_ and _download_ - -NOTE: The app will support paginating through all media files in the current directory, even if only one media file was chosen to be previewed. - -image:media-viewer-app/app-overview.png[] - -== Features - -* Support for a large selection of image and video formats (depending on server setup) -* Fullscreen, zoomable slideshow view integrated with the Files view and Public Links -* Image rotation -* Sort images by name or date -* Image and video download straight from the slideshow -* Native SVG support -* Mobile support - -== Supported File Formats - -* The supported video formats depend on the user's browser. However, the app supports _MP4_, _Ogg_, and _WebM_. -* The supported image formats depend on the server capabilities - -=== Use Redis for Files Locking - -Using Redis for files locking improves app performance by a factor of 10, when loading an album. - -== Unsupported File Formats - -* Support for playing Apple QuickTime (*.mov) does not work in Chrome - however it is supported in Safari and Mozilla. diff --git a/content/server/10.15/modules/classic_ui/pages/external_storage/external_storage.adoc b/content/server/10.15/modules/classic_ui/pages/external_storage/external_storage.adoc deleted file mode 100644 index 0b00f0b..0000000 --- a/content/server/10.15/modules/classic_ui/pages/external_storage/external_storage.adoc +++ /dev/null @@ -1,6 +0,0 @@ -= Configuring External Storage -:description: The External Storage application allows you to mount external storage services, such as Google Drive, Dropbox, Amazon S3, SMB/CIFS fileservers, and FTP servers in ownCloud. Your ownCloud server administrator controls which of these are available to you. - -{description} Please see -xref:{latest-server-version}@server:admin_manual:configuration/files/external_storage/configuration.adoc[External Storage Configuration] in the ownCloud -Administrator’s manual for configuration howtos and examples. diff --git a/content/server/10.15/modules/classic_ui/pages/external_storage/sharepoint_connecting.adoc b/content/server/10.15/modules/classic_ui/pages/external_storage/sharepoint_connecting.adoc deleted file mode 100644 index 5cf9331..0000000 --- a/content/server/10.15/modules/classic_ui/pages/external_storage/sharepoint_connecting.adoc +++ /dev/null @@ -1,61 +0,0 @@ -= Connecting to SharePoint (Enterprise only) -:toc: right -:description: Native SharePoint support has been added to ownCloud Enterprise Subscription as a secondary storage location for SharePoint 2007, 2010 and 2013. To the user, these appear as normal ownCloud mounts, with bi-directional updates in any ownCloud client: desktop, mobile, or Web. - -== Introduction - -{description} - -There is one difference, and that is ownCloud sharing is intentionally -disabled for SharePoint mountpoints in order to preserve SharePoint -access controls, and to ensure that content is properly accessed as per -SharePoint rules. Your ownCloud admin may optionally allow users to mount their own -SharePoint libraries. - -== Accessing SharePoint Folders - -When you first log in to ownCloud, the Web interface shows a gray bar -behind all SharePoint folders. The gray bar disappears when the -mountpoint is verified by the server. If you see a red error bar, you’ll -see either an hourglass that indicates a connection error, or a key to -indicate that authentication is required. - -Your ownCloud admin has the option to configure SharePoint credentials -so that you are authenticated automatically, or you may be required to -enter your credentials. If you have to enter your credentials, click the -btn:[red bar] and you’ll get a login window. You should only have to do this -once, as ownCloud will store your credentials. - -If your SharePoint login ever changes, go to your Personal page to -update it in the `Sharepoint Personal Configuration` section. - -== Personal Page - -You can manage your SharePoint connections in the -`Sharepoint Personal Configuration` section of your ownCloud Personal -page. You’ll see two sections: the `Admin added mount points` section -lists SharePoint mounts controlled by your ownCloud admin. If users have -permissions to mount their own SharePoint libraries you’ll also see a -`Personal mount points` section. - -There are two types of authentication available to you. If you have -multiple SharePoint libraries that use the same authentication, enter -your credentials in `Sharepoint Personal Configuration`. Then follow -these steps to add your libraries: - -* Enter the name of your local mountpoint in the `Local Folder Name` -column. -* Enter your SharePoint server URL. -* Click the little refresh icon to the left of the `Document Library` -field. If your credentials and URL are correct you’ll get a dropdown -list of SharePoint libraries to choose from. -* Select the document library you want to mount. -* Select "Use user credentials". -* Click the btn:[Save] button, and you’re done - -You may elect to use different authentication credentials for some of -your SharePoint libraries. For these, you must first select -`use custom credentials`, and then fill in the mountpoint and -SharePoint site URL. Then ownCloud can authenticate you, and you can -click the btn:[refresh] icon to see your libraries. Then select the library -you want to mount and click the btn:[Save] button. diff --git a/content/server/10.15/modules/classic_ui/pages/files/access_webdav.adoc b/content/server/10.15/modules/classic_ui/pages/files/access_webdav.adoc deleted file mode 100644 index c93f228..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/access_webdav.adoc +++ /dev/null @@ -1,631 +0,0 @@ -= Accessing ownCloud Files Using WebDAV -:toc: right -:description: ownCloud fully supports the WebDAV protocol, and you can connect and synchronize with your ownCloud files over WebDAV. In this chapter you will learn how to connect Linux, Mac OS X, Windows and mobile devices to your ownCloud server via WebDAV. - -:ocsmount-url: https://apps.apple.com/de/app/ocsmount/id1411490371 -:webdav-navigator-url: http://seanashton.net/webdav/ -:schimera-url: https://play.google.com/store/apps/details?id=com.schimera.webdavnavlite -:ios-webdav-navigator-url: https://itunes.apple.com/app/webdav-navigator/id382551345 -:sabre-finder-url: http://sabre.io/dav/clients/finder/ -:windows7-dav-url: https://docs.microsoft.com/en-us/troubleshoot/windows-client/networking/cannot-automatically-reconnect-dav-share -:office-opens-blank-url: https://docs.microsoft.com/en-us/office/troubleshoot/powerpoint/office-opens-blank-from-sharepoint -:support-1-url: https://support.microsoft.com/kb/2123563 -:support-2-url: https://support.microsoft.com/kb/2668751 - -== Introduction - -{description} Before we get into configuring WebDAV, let’s take a quick look at the recommended way of connecting client devices to your ownCloud servers. - -== ownCloud Desktop and Mobile Clients - -The recommended method for keeping your desktop PC synchronized with -your ownCloud server is by using the -https://owncloud.com/desktop-app/[ownCloud Desktop Client]. -You can configure the ownCloud client to save files in any local -directory you want, and you choose which directories on the ownCloud -server to sync with. The client displays the current connection status -and logs all activity, so you always know which remote files have been -downloaded to your PC, and you can verify that files created and updated -on your local PC are properly synchronized with the server. - -The recommended method for syncing your ownCloud server with Android and -Apple iOS devices is by using the -https://owncloud.com/mobile-apps/[ownCloud Mobile apps]. - -To connect to your ownCloud server with the *ownCloud* mobile apps, use -the base URL and folder only: - ----- -example.com/owncloud ----- - -In addition to the mobile apps provided by ownCloud, you can use other -apps to connect to ownCloud from your mobile device using WebDAV. -{webdav-navigator-url}[WebDAV Navigator] is a good (proprietary) app for {schimera-url}[Android devices] and {ios-webdav-navigator-url}[iPhones]. The URL to use on these is: - ----- -example.com/owncloud/remote.php/webdav ----- - -== WebDAV Configuration - -If you prefer, you may also connect your desktop PC to your ownCloud -server by using the WebDAV protocol rather than using a special client -application. Web Distributed Authoring and Versioning (WebDAV) is a -Hypertext Transfer Protocol (HTTP) extension that makes it easy to -create, read, and edit files on Web servers. With WebDAV you can access -your ownCloud shares on Linux, Mac OS X and Windows in the same way as -any remote network share, and stay synchronized. - -NOTE: In the following examples, You must adjust *example.com/* to the URL of your ownCloud server installation. - -== Accessing Files Using Linux - -You can access files in Linux operating systems using the following -methods. - -=== Nautilus File Manager - -Use the `davs://` protocol to connect the Nautilus file manager to your -ownCloud share: - -[source,plaintext] ----- -davs://example.com/owncloud/remote.php/webdav ----- - -NOTE: If your server connection is not HTTPS-secured, use `dav://` instead of `davs://`. - -image:webdav_gnome3_nautilus.png[screenshot of configuring Nautilus file manager to use WebDAV,width=500] - -=== Accessing Files with KDE and Dolphin File Manager - -To access your ownCloud files using the Dolphin file manager in KDE, use the `webdav://` protocol: - -[source,plaintext] ----- -webdav://example.com/owncloud/remote.php/webdav ----- - -image:webdav_dolphin.png[screenshot of configuring Dolphin file manager to use WebDAV,width=400] - -You can create a permanent link to your ownCloud server: - -. Open Dolphin and click btn:[Network] in the left-hand column. -+ -image:files/access_webdav/dolphin-add-network-folder.png[Dolphin File Explorer,width=400] -. Click on the icon labeled btn:[Add a Network Folder]. + -The resulting dialog should appear with WebDAV already selected. -. If WebDAV is not selected, select it. -. Click btn:[Next]. -. Enter the following settings: -** *Name:* The name you want to see in the *Places* bookmark, for example ownCloud. -** *User:* The ownCloud username you used to log in, for example admin. -** *Server:* The ownCloud domain name, for example *example.com* (without **https://** or **http://**). -** *Folder:* Enter the path `owncloud/remote.php/webdav`. -+ -image:files/access_webdav/dolphin-network-folder-wizard.png[Dolphin Network Folder Wizard,width=500] -. (Optional) Check the btn:[create] icon checkbox for a bookmark to appear in the menu:Places[] column. -. (Optional) Provide any special settings or an SSL certificate in the btn:[Port & Encrypted] checkbox. - -== Creating WebDAV Mounts on the Linux Command Line - -You can create WebDAV mounts from the Linux command line. This is useful -if you prefer to access ownCloud the same way as any other remote -filesystem mount. The following example shows how to create a personal -mount and have it mounted automatically every time you log in to your -Linux computer. - -. Install the `davfs2` WebDAV filesystem driver, which allows you to -mount WebDAV shares just like any other remote filesystem. Use this -command to install it on Debian/Ubuntu: -+ -[source,bash] ----- -sudo apt-get install davfs2 ----- -. Use this command to install it on CentOS, Fedora, and openSUSE: -+ -[source,bash] ----- -sudo yum install davfs2 ----- -. Add yourself to the `davfs2` group (this will be effective after the next login): -+ -[source,bash] ----- -sudo usermod -aG davfs2 ----- -. Then create an `owncloud` directory in your home directory for the -mountpoint, and `.davfs2/` for your personal configuration file: -+ -[source,bash] ----- -mkdir ~/owncloud ----- -+ -[source,bash] ----- -mkdir ~/.davfs2 ----- -. Copy `/etc/davfs2/secrets` to `~/.davfs2`: -+ -[source,bash] ----- -sudo cat /etc/davfs2/secrets > ~/.davfs2/secrets ----- -. Make the permissions read-write owner only: -+ -[source,bash] ----- -chmod 600 ~/.davfs2/secrets ----- -. Add your ownCloud login credentials to the end of the `secrets` -file, using your ownCloud server URL and your ownCloud username and -password: -+ -[source,plaintext] ----- -/home//owncloud ----- -. Add the mount information to `/etc/fstab`: -+ -[source,plaintext] ----- -https://example.com/owncloud/remote.php/webdav /home//owncloud davfs user,rw,auto 0 0 ----- -. Then test that it mounts and authenticates by running the following command. - If you set it up correctly you won’t need root permissions: -+ -[source,bash] ----- -mount ~/owncloud ----- -. You should also be able to unmount it: -+ -[source,bash] ----- -umount ~/owncloud ----- - -Now every time you login to your Linux system your ownCloud share should -automatically mount via WebDAV in your `~/owncloud` directory. If you -prefer to mount it manually, change `auto` to `noauto` in `/etc/fstab`. - -== Known Issues - -=== Problem: Resource Temporarily Unavailable - -==== Solution - -If you experience trouble when you create a file in the directory, edit -`/etc/davfs2/davfs2.conf` and add: - -[source,plaintext] ----- -use_locks 0 ----- - -=== Problem: Certificate Warnings - -==== Solution - -If you use a self-signed certificate, you will get a warning. To change -this, you need to configure `davfs2` to recognize your certificate. Copy -`mycertificate.pem` to `/etc/davfs2/certs/`. Then edit -`/etc/davfs2/davfs2.conf` and uncomment the line `servercert`. Now add -the path of your certificate as in this example: - -[source,plaintext] ----- -servercert /etc/davfs2/certs/mycertificate.pem ----- - -== Accessing Files Using Mac OS X - -NOTE: The Mac OS X Finder suffers from a {sabre-finder-url}[series of implementation problems] -and should only be used if the ownCloud server runs on *Apache* and *mod_php*. -You can use a tool like {ocsmount-url}[ocsmount] to mount without those issues. - -To access files through the Mac OS X Finder: - -. Choose menu:Go[Connect to Server]. + -The "Connect to Server" window opens. -. Specify the address of the server in the *Server Address* field. + -image:osx_webdav1.png[Screenshot of entering your ownCloud server address on Mac OS X,width=400] + -+ -For example, the URL used to connect to the ownCloud server from the Mac OS X Finder is: + -+ ----- -https://example.com/owncloud/remote.php/webdav ----- -+ -image:osx_webdav2.png[image,width=400] -. Click btn:[Connect]. + -The device connects to the server. + -+ -For added details about how to connect to an external server using Mac OS X, check the -https://www.wikihow.com/Connect-to-a-Server-on-a-Mac[wikihow documentation] - -== Accessing Files Using Microsoft Windows - -It is best to use a suitable WebDAV client from the -http://www.webdav.org/projects/[WebDAV Project page] . - -If you have to use the native Windows implementation, you can map ownCloud -to a new drive. Mapping to a drive enables you to browse files stored on -an ownCloud server the way you would files stored in a mapped network drive. - -Using this feature requires network connectivity. If you want to store -your files offline, use the ownCloud Desktop Client to sync all files on -your ownCloud to one or more directories of your local hard drive. - -NOTE: If you encounter any issues during the connection please also check the -xref:known-problems[troubleshooting section] below. - -[NOTE] -==== -Prior to mapping your drive, you must permit the use of _Basic Authentication_ in the -Windows Registry when using HTTP without SSL encryption. The procedure is documented in: - -* {windows7-dav-url}[Windows 7 cannot automatically reconnect a DAV share when Basic Authentication is used] -and -* {office-opens-blank-url}[Office applications open blank from SharePoint WebDAV or sites]. - -Please follow the Knowledge Base article before proceeding. -==== - -=== Mapping Drives With the Command Line - -The following example shows how to map a drive using the command line. -To map the drive: - -. Open a command prompt in Windows. -. Enter the following line in the command prompt to map to the computer Z drive, -where is the URL to your ownCloud server: + -+ ----- -net use Z: https:///remote.php/webdav /user:youruser yourpassword ----- -+ -**Example:** -+ -`net use Z: \https://example.com/owncloud/remote.php/webdav /user:youruser yourpassword` -+ -[quote] -____ -The computer maps the files of your ownCloud account to the drive letter Z. -____ -+ -NOTE: Though not recommended, you can also mount the ownCloud server using HTTP, leaving the connection unencrypted. -If you plan to use HTTP connections on devices while in a public place, we strongly recommend using a -VPN tunnel to provide the necessary security. -+ -An alternative command syntax is: -+ ----- -net use Z: \\example.com@ssl\owncloud\remote.php\dav /user:youruser yourpassword ----- - -=== Mapping Drives With Windows Explorer - -To map a drive using the Microsoft Windows Explorer: - -. Migrate to your computer in Windows Explorer. -. Right-click on btn:[Computer] entry and select btn:[Map network drive…] from the drop-down menu. -. Choose a local network drive to which you want to map ownCloud. -. Specify the address to your ownCloud instance, followed by */remote.php/webdav*. -+ -For example: -+ ----- -https://example.com/owncloud/remote.php/webdav ----- -+ -NOTE: For SSL protected servers, check *Reconnect at logon* to ensure that the mapping is persistent upon subsequent reboots. If you want to connect to the ownCloud server as a different user, check *Connect using different credentials*. -+ -image:explorer_webdav.png[image,width=500] -. Click the btn:[Finish] button. + -Windows Explorer maps the network drive, making your ownCloud instance available. - -== Accessing Files Using Cyberduck - -https://cyberduck.io/?l=en[Cyberduck] is an open source FTP and SFTP, -WebDAV, and Amazon S3 browser designed for file transfers on Mac OS X and Windows. - -NOTE: This example uses Cyberduck version 4.2.1. - -To use Cyberduck: - -. Specify a server without any leading protocol information. For example: -+ ----- -example.com ----- -. Specify the appropriate port. The port you choose depends on whether -or not your ownCloud server supports SSL. Cyberduck requires that you -select a different connection type if you plan to use SSL. For example: -+ ----- -80 (for WebDAV) -443 (for WebDAV (HTTPS/SSL)) ----- -. Use the `More Options` drop-down menu to add the rest of your WebDAV -URL into the `Path' field. For example: -+ ----- -remote.php/webdav ----- - -Now Cyberduck enables file access to the ownCloud server. - -== Accessing public link shares over WebDAV - -ownCloud provides the possibility to access public link shares over WebDAV. - -To access the public link share, open: - ----- -https://example.com/owncloud/public.php/webdav ----- - -in a WebDAV client, use the share token as username and the (optional) -share password as password. - -NOTE: menu:Settings[Administration > Sharing > Allow users on this server -to send shares to other servers] needs to be enabled in order to make this feature work. - -== Known Problems - -=== Problem: Windows Does Not Connect Using HTTPS. - -==== Solution 1 - -The Windows WebDAV Client might not support Server Name Indication (SNI) -on encrypted connections. If you encounter an error mounting an -SSL-encrypted ownCloud instance, contact your provider about assigning a -dedicated IP address for your SSL-based server. - -==== Solution 2 - -The Windows WebDAV Client might not support TLSv1.1 / TLSv1.2 -connections. If you have restricted your server config to only provide -TLSv1.1 and above the connection to your server might fail. Please refer to the -https://docs.microsoft.com/en-us/windows/win32/winhttp/about-winhttp[WinHTTP] -documentation for further information. - -=== Problem: The File Size Exceeds the Limit Allowed and Cannot be Saved - -You receive the following error message: + -*Error 0x800700DF: The file size exceeds the limit allowed and cannot be saved.* - -==== Solution - -Windows limits the maximum size a file transferred from or to a WebDAV -share may have. You can increase the value `FileSizeLimitInBytes` in -`HKEY_LOCAL_MacHINE\SYSTEM\CurrentControlSet\Services\WebClient\Parameters` -by clicking on btn:[Modify]. - -To increase the limit to the maximum value of 4GB, select *Decimal*, enter a value of -`4294967295`, and reboot Windows or restart the `WebClient` service. - -=== Problem: Accessing your files from Microsoft Office via WebDAV fails - -==== Solution - -Known problems and their solutions are documented in the {support-1-url}[KB2123563] article. - -=== Problem: WebDAV Drive in Windows Using Self-Signed Certificate - -Cannot map ownCloud as a WebDAV drive in Windows using self-signed certificate. - -==== Solution - -. Go to your ownCloud instance via your favorite Web browser. -. Click through until you get to the certificate error in the browser status line. -. View the cert, then from the Details tab, select Copy to File. -. Save to the desktop with an arbitrary name, for example `myOwnCloud.cer`. -. Start, Run, MMC. -. menu:File[Add/Remove Snap-In]. -. Select menu:Certificates[Add > My User Account > Finish > OK]. -. Dig down to Trust Root Certification Authorities, Certificates. -. Right-Click menu:Certificate[Select All Tasks > Import]. -. Select btn:[Save Cert] from the Desktop. -. Select Place all Certificates in the following Store, click btn:[Browse], -. Check the Box that says menu:Show Physical Stores[]. + -Expand out *Trusted Root Certification Authorities*. + -select *Local Computer*, click btn:[OK] to complete the Import. -. Check the list to make sure it shows up. + -You will probably need to Refresh before you see it. + -Exit MMC. -. Open Browser, select Tools, Delete Browsing History. -. Select all but In Private Filtering Data, complete. -. Go to Internet Options, Content Tab, Clear SSL State. -. Close browser, then re-open and test. - -=== Problem: Upload Large Files or Upload Takes Long - -You cannot download more than 50 MB or upload large Files when the -upload takes longer than 30 minutes using Web Client in Windows 7. - -==== Solution - -Workarounds are documented in the {support-2-url}[KB2668751] article. - -=== Problem: The Network Name Cannot be Found - -Error 0x80070043 "The network name cannot be found." while adding a network drive. - -==== Solution - -Make Windows service *WebClient* start automatically: - -. Open menu:Control Panel[Administrative Tools > Services]. -. Find *WebClient* service. -. Right-click on it and choose *Properties*. -. Select *Startup type*: *Automatic*. -. Click btn:[OK] button. - -Or in command prompt (as Admin): - ----- -sc config "WebClient" start=auto -sc start "WebClient" ----- - -// documentation is archived and link is out of date -// More details can be found https://github.com/owncloud/documentation/pull/2668[here]. - -=== Problem: Network Discovery - -On Windows 10, you need to turn on the _Network Discovery_ to make webdav access work. In newer versions of Windows 10 it is enabled by default. - -==== Solution - - The following steps need to be done: - -. Go to the Windows Settings -. Select "Network & Internet" -+ -image:files/access_webdav/network-internet.png[width=500] - -. Select "Network and Sharing Center" -+ -image:files/access_webdav/network-sharing-center.png[width=500] - -. Select "Change advanced sharing settings" -+ -image:files/access_webdav/advanced-sharing-settings.png[width=500] - -. Select "Turn on network discovery" -+ -image:files/access_webdav/network-discovery.png[width=500] - -== Accessing Files Using cURL - -Since WebDAV is an extension of HTTP cURL can be used to script file operations. - -To create a folder with the current date as name: - -[source,bash] ----- -curl -u user:pass -X MKCOL \ - "https://example.com/owncloud/remote.php/dav/files/USERNAME/$(date '+%d-%b-%Y')" ----- - -To upload a file `error.log` into that directory: - -[source,bash] ----- -curl -u user:pass -T error.log \ - "https://example.com/owncloud/remote.php/dav/files/USERNAME/$(date '+%d-%b-%Y')/error.log" ----- - -To move a file: - -[source,bash] ----- -curl -u user:pass -X MOVE --header 'Destination: https://example.com/owncloud/remote.php/dav/files/USERNAME/target.jpg' https://example.com/owncloud/remote.php/dav/files/USERNAME/source.jpg ----- - -To get the properties of files in the root folder: - -[source,bash] ----- -curl -X PROPFIND -H "Depth: 1" -u user:pass https://example.com/owncloud/remote.php/dav/files/USERNAME/ | xml_pp - - - - /owncloud/remote.php/webdav/ - - - Tue, 13 Oct 2015 17:07:45 GMT - - - - 163 - 11802275840 - "561d3a6139d05" - - HTTP/1.1 200 OK - - - - /owncloud/remote.php/webdav/welcome.txt - - - Tue, 13 Oct 2015 17:07:35 GMT - 163 - - "47465fae667b2d0fee154f5e17d1f0f1" - text/plain - - HTTP/1.1 200 OK - - - ----- - -To get the file id of a file, regardless of location, you need to make a -PROPFIND request. This request requires two things: - -. A PROPFIND XML element in the body of the request method. -. The path to the file that you want to find out more about - -Here’s an example PROPFIND XML element, which we’ll store as `propfind-fileid.xml`. - -[source,xml] ----- - - - - - ----- - -NOTE: You could pass this directly to the Curl request. However, it can often be easier to create, -maintain, and to share, if it’s created in a standalone file. - -With the file created, make the request by running the following Curl command: - -[source,xml] ----- -curl -u username:password -X PROPFIND \ - -H "Content-Type: text/xml" \ - --data-binary "@propfind-fileid.xml" \ - 'http://localhost/remote.php/dav/files/admin/Photos/San%20Francisco.jpg' ----- - -This will return an XML response payload similar to the following -example. It contains the relative path to the file and the fileid of the file. - -[source,xml] ----- - - - - /remote.php/dav/files/admin/Photos/San%20Francisco.jpg - - - 4 - - HTTP/1.1 200 OK - - - ----- - -NOTE: The example above’s been formatted for readability, using -http://vim.wikia.com/wiki/Format_your_xml_document_using_xmllint[xmllint], -which is part of libxml2. To format it as it is listed above, pipe the previous command to `xmllint --format -`. - -== Uploading Files to a Public Link (File Drop) Using cURL - -To upload a file named `file.txt` to a public link with token `70mX9s7KOZwfmdi` like `\https://example.com/s/70mX9s7KOZwfmdi` having no password: - -[source,bash] ----- -curl -k -T file.txt -u "70mX9s7KOZwfmdi:" \ - -H 'X-Requested-With: XMLHttpRequest' \ - https://example.com/public.php/webdav/file.txt ----- diff --git a/content/server/10.15/modules/classic_ui/pages/files/deleted_file_management.adoc b/content/server/10.15/modules/classic_ui/pages/files/deleted_file_management.adoc deleted file mode 100644 index 27d70aa..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/deleted_file_management.adoc +++ /dev/null @@ -1,55 +0,0 @@ -= Managing Deleted Files -:toc: right -:description: When you delete a file in ownCloud, it is not immediately deleted permanently. Instead, it is moved into the trash bin. It is not permanently deleted until you manually delete it, or when the Deleted Files app deletes it to make room for new files. - -== Introduction - -{description} - -Find your deleted files by clicking on the btn:[Deleted files] button on the -Files page of the ownCloud Web interface. You’ll have options to either -restore or permanently delete files. - -== Quotas - -Deleted files are not counted against your storage quota. Only files -that originate with users count against their quotas, not files shared -with them that originate from other users. (See webgui/quota to learn -more about quotas.) - -== What Happens When Shared Files Are Deleted - -Deleting files gets a little complicated when they are shared files, as -this scenario illustrates: - -1. User1 shares a folder "test" with User2 and User3 -2. User2 (the recipient) deletes a file/folder "sub" inside of -"test" -3. The folder "sub" will be moved to the trashbin of both User1 -(owner) and User2 (recipient) -4. But User3 will not have a copy of "sub" in her trash bin - -When User1 deletes "sub" then it is moved to User1’s trash bin. It is -deleted from User2 and User3, but not placed in their trash bins. - -When you share files, other users may copy, rename, move, and share them -with other people, just as they can for any computer files; ownCloud -does not have magic powers to prevent this. - -== How the Deleted Files app Manages Storage Space - -To ensure that users do not run over their storage quotas, the Deleted -Files app allocates a maximum of 50% of their currently available -storage quota to deleted files. If your deleted files exceed this limit, -ownCloud deletes the oldest files (files with the oldest timestamps from -when they were deleted) until it meets the memory usage limit again. - -ownCloud checks the age of deleted files every time new files are added -to the deleted files. By default, deleted files stay in the trash bin -for 30 days. The ownCloud server administrator can adjust this value in -the `config.php` file by setting the `trashbin_retention_obligation` -value. Files older than the `trashbin_retention_obligation` value will -be deleted permanently. Additionally, ownCloud calculates the maximum -available space every time a new file is added. If the deleted files -exceed the new maximum allowed space ownCloud will expire old deleted -files until the limit is met once again. diff --git a/content/server/10.15/modules/classic_ui/pages/files/desktop_mobile_sync.adoc b/content/server/10.15/modules/classic_ui/pages/files/desktop_mobile_sync.adoc deleted file mode 100644 index 9eef63e..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/desktop_mobile_sync.adoc +++ /dev/null @@ -1,26 +0,0 @@ -= Desktop and Mobile Synchronization -:description: Syncronizing files with your desktop computer is easiest with the Desktop Synchronisation Client. While it is not mandatory, it eases keeping files in sync a lot. - -== Introduction - -{description} See the download link https://owncloud.com/desktop-app/[ownCloud Sync Client] for Windows, Mac OS X and Linux clients. - -The ownCloud Desktop Sync Client enables you to connect to your private -ownCloud Classic. You can create folders in your home directory, and keep -the contents of those folders synced with your ownCloud server. Simply -copy a file into the directory and the ownCloud desktop client does the -rest. Make a change to the files on one computer, it will flow across -the others using these desktop sync clients. You will always have your -latest files with you wherever you are. - -Its usage is documented separately in the -https://doc.owncloud.com/desktop/latest/[ownCloud Desktop Client Manual]. - -== Mobile Clients - -Visit your Personal page in your ownCloud Web interface to find download -links for Android and iOS mobile sync clients. Or, visit the -https://owncloud.com/mobile-apps/[ownCloud download Mobile page]. - -Visit the https://doc.owncloud.com/[ownCloud documentation page] to read -the mobile apps user manuals. diff --git a/content/server/10.15/modules/classic_ui/pages/files/encrypting_files.adoc b/content/server/10.15/modules/classic_ui/pages/files/encrypting_files.adoc deleted file mode 100644 index 90cff9e..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/encrypting_files.adoc +++ /dev/null @@ -1,94 +0,0 @@ -= Encrypting Your ownCloud Files -:toc: right -:description: ownCloud includes an Encryption app, and when it is enabled by your ownCloud administrator, all of your ownCloud data files are automatically encrypted. - -== Introduction - -{description} Encryption is server-wide, so when it is enabled you cannot choose to keep your files unencrypted. You don’t have to do anything special, as it uses your ownCloud login as the password for your unique private encryption key. Just log in and out and manage and share your files as you normally do, and you can still change your password whenever you want. - -Its main purpose is to encrypt files on remote storage services that are -connected to your ownCloud server, such as Dropbox and Google Drive. -This is an easy and seamless way to protect your files on remote -storage. You can share your remote files through ownCloud in the usual -way, however you cannot share your encrypted files directly from -Dropbox, Google Drive, or whatever remote service you are using, because -the encryption keys are stored on your ownCloud server, and are never -exposed to outside service providers. - -If your ownCloud server is not connected to any remote storage services, -then it is better to use some other form of encryption such as -file-level or whole disk encryption. Because the keys are kept on your -ownCloud server, it is possible for your ownCloud admin to snoop in your -files, and if the server is compromised the intruder may get access to -your files. (Read -https://owncloud.com/news/how-owncloud-uses-encryption-to-protect-your-data/[How ownCloud uses encryption to protect your data] to learn more.) - -== Using Encryption - -ownCloud encryption is pretty much set it and forget it, but you have a -few options you can use. - -When your ownCloud admin enables encryption for the first time, you must -log out and then log back in to create your encryption keys and encrypt -your files. When encryption has been enabled on your ownCloud server you -will see a yellow banner on your Files page warning you to log out and -then log back in. - -image:encryption1.png[image] - -When you log back in it takes a few minutes to work, depending on how -many files you have, and then you are returned to your default ownCloud page. - -image:encryption2.png[image] - -NOTE: You must never lose your ownCloud password, because you will lose access -to your files. However, there is an optional recovery option that your ownCloud administrator -may enable; see the Recovery Key Password section (below) to learn about this. - -//// -Section: Files Which Are Never Encrypted -is also used in the admin guide, therefore included -//// - -include::partial$/configuration/files/encryption/not-encrypted-files.adoc[] - -== Sharing Encrypted Files - -Only users who have private encryption keys have access to shared encrypted files and folders. -Users who have not yet initialized their private encryption keys will not have access to encrypted shared files; -they will see folders and filenames, but will not be able to open or download the files. -They will see a yellow warning banner that says: - -"" -Encryption App is enabled but your keys are not initialized, please log-out and log-in again.` -"" - -Share owners may need to re-share files after encryption is enabled; -users trying to access the share will see a message advising them to ask -the share owner to re-share the file with them. For individual shares, -un-share and re-share the file. For group shares, share with any -individuals who can’t access the share. This updates the encryption, and -then the share owner can remove the individual shares. - -=== Recovery Key Password - -If your ownCloud administrator has enabled the recovery key feature, you -can choose to use this feature for your account. If you enable -"Password recovery" the administrator can read your data with a -special password. This feature enables the administrator to recover your -files in the event you lose your ownCloud password. If the recovery key -is not enabled, then there is no way to restore your files if you lose -your login password. - -image:encryption3.png[image] - -=== Change Private Key Password - -This option is only available if your log-in password, but not your -encryption password, was changed by your administrator. This can occur -if your ownCloud provider uses an external user back-end (for example, -LDAP) and changed your login password using that back-end configuration. -In this case, you can set your encryption password to your new login -password by providing your old and new login password. The Encryption -app works only if your login password and your encryption password are -identical. diff --git a/content/server/10.15/modules/classic_ui/pages/files/federated_cloud_sharing.adoc b/content/server/10.15/modules/classic_ui/pages/files/federated_cloud_sharing.adoc deleted file mode 100644 index 46682a2..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/federated_cloud_sharing.adoc +++ /dev/null @@ -1,83 +0,0 @@ -= Using Federation Shares -:toc: right -:description: Federation Sharing allows you to mount file shares from remote ownCloud -servers, in effect creating your own cloud of ownClouds. - -== Introduction - -{description} You can create direct share links with users on other ownCloud servers. - -IMPORTANT: xref:{latest-server-version}@server:admin_manual:configuration/files/federated_cloud_sharing_configuration.adoc[Federated Sharing] has to be configured by the administrator. - -== How Federated Sharing Works - -Federated sharing, conceptually, is not that sophisticated a concept. -Here’s how it works. - -Say we have three users: _James_, _Mary_, and _Paul_. James has a folder -(Majorca-Holiday-Pics) which he shares with Mary, who’s on a separate -ownCloud instance. Mary, in turn, (re)shares the folder with Paul, who’s -on the same ownCloud instance as Mary. - -You might think that there are two — even three — copies of the shared -folder. In reality, there’s only one. _In effect_, there are three — all -owned by the original sharer (James). - -The key point to keep in mind is that when a share is re-shared, it’s -shared, internally, on behalf of the original owner. To keep track of -all this, during the share process references are created between the -shares, that show: - -* James was the original owner of the shared resource -* James shared a copy with Mary and Mary re-shared a copy with Paul. - -== Creating a New Federation Share - -Federation sharing is enabled on new or upgraded ownCloud installations by default. -Follow these steps to create a new share with other ownCloud 9 servers: - -. Go to your menu:Files[] page and click the btn:[share] icon on the file or -directory you want to share. In the sidebar enter the username and URL -of the remote user in this form: `@`. In this -example, that is `layla@remote-server/owncloud`. The form automatically -echoes the address that you type and labels it as "remote". Click on the label. -+ -image:direct-share-1.png[image] -. When your local ownCloud server makes a successful connection with the remote -ownCloud server you’ll see a confirmation. Your only share option is *Can edit*. - -Click the Share button anytime to see who you have shared your file -with. Remove your linked share anytime by clicking the trash can icon. -This only unlinks the share, and does not delete any files. - -== Creating a New Federated Cloud Share via Email - -Use this method when you are sharing with users on ownCloud 8.x and older. - -What if you do not know the username or URL? Then you can have ownCloud -create the link for you and email it to your recipient. - -image:create_public_share-6.png[image] - -When your recipient receives your email they will have to take a number -of steps to complete the share link. First they must open the link you -sent them in a Web browser, and then click the btn:[Add to your ownCloud] -button. - -image:create_public_share-8.png[image] - -The *Add to your ownCloud* button changes to a form field, and your -recipient needs to enter the URL of their ownCloud server in this field -and press the return key, or click the arrow. - -image:create_public_share-9.png[image] - -Next, they will see a dialog asking to confirm. All they have to do is -click the btn:[Add remote share] button and they’re finished. - -Remove your linked share anytime by clicking the btn:[trash can] icon. This -only unlinks the share, and does not delete any files. - -== Limitations - -Sharing to groups from federated ownCloud instances is not supported. diff --git a/content/server/10.15/modules/classic_ui/pages/files/files_lifecycle.adoc b/content/server/10.15/modules/classic_ui/pages/files/files_lifecycle.adoc deleted file mode 100644 index 167ec6d..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/files_lifecycle.adoc +++ /dev/null @@ -1,36 +0,0 @@ -= File Lifecycle Management -:toc: right -:description: With File Lifecycle Management, ownCloud provides a toolset for administrators to automatically move user files into a dedicated archive a certain time after they were uploaded. - -== Introduction - -{description} Unless they are restored, archived files will be permanently deleted once they exceed a certain time in the archive. The following sections provide guidance for users on ownCloud installations that have File Lifecycle Management policies enabled. - -TIP: Only files will be archived, folder structures are kept available. - -== Archiving Process - -To see when and if files are scheduled for archiving, a user may select a file within the files list to open the detail view in the sidebar. In the sidebar, they can see the remaining days until it will be automatically archived. Archiving usually takes place once a day. When a file is due to be archived, it will show 'Scheduled for archive today!'. - -image:files/lifecycle-2.png[Details for uploaded file] - -Depending on the policy configuration, users may be able to restore their own files using a file action in the file list. - -Whilst a file is in the archive, it cannot be used in the Web interface or with the ownCloud Clients, but can be located using the archive browser. Existing metadata including shares, comments and tags are preserved, but will not be available for archived files. - -== Browsing the Archive - -Users can browse the archive in a similar fashion to the 'Deleted Files', using the 'Archived Files' file list available on the bottom left of the files view. Folder structures are recreated showing the paths that were present at the time a file was archived. - -image:files/lifecycle-1.png[The Archive Browser] - -== Restoring Files - -Depending on the policy configuration, users may be able to restore files on their own in 'Archived Files' by clicking the 'Restore' action on the file or folder row. Specific policies may require different permissions to access this option, or permanently disable it. -Restored files can be used for the same amount of time as if they were uploaded before they will be archived again. - -== Activities - -File Lifecycle Management events (like archiving/restoring a file) are added to the Activity history. These can be viewed within the 'Activity' tab in the sidebar or within the Activity Stream. Within the personal settings page, users can choose to receive e-mails related to these events. - -image:files/lifecycle-3.png[Lifecycle Activities] diff --git a/content/server/10.15/modules/classic_ui/pages/files/index.adoc b/content/server/10.15/modules/classic_ui/pages/files/index.adoc deleted file mode 100644 index b1aed08..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/index.adoc +++ /dev/null @@ -1,3 +0,0 @@ -= Files - -This section covers how to work with and user files when using ownCloud. diff --git a/content/server/10.15/modules/classic_ui/pages/files/large_file_upload.adoc b/content/server/10.15/modules/classic_ui/pages/files/large_file_upload.adoc deleted file mode 100644 index 69b7461..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/large_file_upload.adoc +++ /dev/null @@ -1,12 +0,0 @@ -= Large File Uploads -:description: When uploading files through the web client, ownCloud is limited by the server configuration. We recommend that your ownCloud admin updates the server environment to sizes appropriate for users. - -{description} - -Modifying certain ownCloud variables requires administrative access. If -you require larger upload limits than have been provided by the default -(or already set by your administrator): - -* Contact your administrator to request an increase in these variables -* Refer to the section in the -xref:{latest-server-version}@server:admin_manual:configuration/files/big_file_upload_configuration.adoc[Admin Documentation] that describes how to manage file upload size limits. diff --git a/content/server/10.15/modules/classic_ui/pages/files/manual_file_locking.adoc b/content/server/10.15/modules/classic_ui/pages/files/manual_file_locking.adoc deleted file mode 100644 index 2bc104e..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/manual_file_locking.adoc +++ /dev/null @@ -1,38 +0,0 @@ -= Manual File Locking -:toc: right -:description: If enabled by the ownCloud administrator, manual file locking allows users to lock files in shared areas while working on them in order to prevent concurrent changes from other users (check-in/check-out). - -== Introduction - -{description} - -All storages are supported as locking takes place on the WebDAV level. The locks will only be available via ownCloud, not when a user works directly on the storage. Every user who has access can lock them via the context menu of files. Users can recognize locked files by the means of a new lock indicator. While a file is locked, users can still access it but they cannot make any changes. Locked files can manually be unlocked by the lock owner (the user who locked the file; exclusive locking) using the "Locks" tab in the file details view (right sidebar). - -== Using Manual File Locking - -NOTE: The _user-facing_ components in the web interface are disabled by default and must be enabled by the ownCloud administrator, because this feature allows users to lock other users' files *exclusively*. Lock releasing can only be done by the locking user, a user who is a member of a lock breaking group (if defined by the ownCloud administrator) or until the lock expires. - -By default, locks set by the user in the web interface will expire after 30 minutes, the maximum lock time by default is 24 hours. Both values can be changed by the ownCloud administrator. - -If the ownCloud administrator has enabled _Manual File Locking_, the user will see additional menu items and icons in the files view. - -[width="100%",cols="50%,50%",options="header"] -|=== -^| Manual Locking Disabled -^| Manual Locking Enabled - -a|image::files/manual_file_locking/lock-file-not-visible.png[File locking not visible] -a|image::files/manual_file_locking/lock-file-visible.png[File locking visible] -|=== - -If manual locking is enabled, the following additional user-facing components are present. - -[width="100%",cols="50%,50%"] -|=== -a|image::files/manual_file_locking/file-locked-symbol.png[File locked symbol] -a|image::files/manual_file_locking/file-locked-hint.png[File locking hint] - -a|image::files/manual_file_locking/file-locked-details.png[File locking details] -a|image::files/manual_file_locking/file-locked-unlock-symbol.png[File unlocking] - -|=== diff --git a/content/server/10.15/modules/classic_ui/pages/files/public_link_shares.adoc b/content/server/10.15/modules/classic_ui/pages/files/public_link_shares.adoc deleted file mode 100644 index bf97a9c..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/public_link_shares.adoc +++ /dev/null @@ -1,86 +0,0 @@ -= Public Link Shares -:description: With ownCloud X (10.0), the ability to create multiple public links per file or folder was introduced. -This offers a lot of flexibility for creating different - -== Introduction - -{description} kinds of share links for a single file or folder, such as _different passwords_, _expiry dates_, and _permissions_. - -As of ownCloud version 10.0.2 you can xref:files/webgui/sharing.adoc#creating-drop-folders[create Drop Folders], where users can upload files to a central location, but not be able to change any existing ones, nor see other files which already have been uploaded. - -== Creating Public Link Shares - -To create a public link share, first view the Sharing Panel of the file or folder for which you want to create a public link share. Then click the btn:[Public Links] button and then click btn:[Create public link]. Afterwards the public link share dialog will appear, which you can see below. - -image::public-link/create-public-link.png[Create a public link,width=250] - -As with other shares, provide the name in the *"Link Name"* field and fill out the options that suit you purposes for the link share. - -The following dialog has dependencies, see the xref:share-settings-explained[Share Settings Explained] for details on the items available: - -* When using the ownCloud community edition, the following options are available: -+ -[width=100%,cols="50%,50%",options="header"] -|=== -^| Share Folder -^| Share File - -a| image::public-link/public-link-settings-folder.png[Assign folder permissions,width=300] -a| image::public-link/public-link-settings-file.png[Assign file permissions,width=250] -|=== - -* The share permissions for files are different compared to the community version when using: -+ --- -** The ownCloud Enterprise Edition **and** -** a Collabora Online Document Server **and** -** a configured xref:{current-server-version}@server:admin_manual:enterprise/collaboration/collabora_secure_view.adoc[Collabora Online App] (ownCloud's Collabora Online / Richdocuments App) **and** -** xref:{current-server-version}@server:admin_manual:enterprise/collaboration/collabora_secure_view.adoc#configure-owncloud-for-collabora-online-secure-view[Secure View] has been enabled and configured by your administrator -+ -NOTE: Additional permission items may be available for files depending on the administrator's secure view configuration. --- -+ -[width=100%,cols="50%,50%",options="header"] -|=== -^| Share Folder -^| Share File - -a| image::public-link/public-link-settings-folder.png[Assign permissions,width=300] -a| image::public-link/public-link-settings-ee-file.png[Assign file permissions,width=250] -|=== - -Finally, click the btn:[Save] button to complete creation of the share. Now that the share is created, you can: - -* Copy the link to the share and distribute it -* Update the share’s settings -* Share the link via social media and email -* Delete the public link - -=== Share Settings Explained - -[cols="30%,80%",options="header"] -|=== -| Setting -| Description - -//// -// Not existing yet. Will likely be implemented in owncloud server 10.13.0. -| Preview -| When set, a recipient can only preview the document via Collabora Online. Note that previews are only available for office documents and implemented in most recent versions of ownCloud. Compared to secure view, watermarking is not used. -//// - -| Download / View -| Allows recipients to view or download the public link's contents. - -| Download / View / Edit -| Allows recipients to view, download, edit, and delete the public link's contents. Note that the capability to _Edit_ is only implemented and available in most recent versions of ownCloud. - -| Download / View / Upload -| Allows recipients to view, download and upload the public link's contents. - -| Upload only (File Drop) -| Allows users to create xref:files/webgui/sharing.adoc#creating-drop-folders[a drop folder], which can receive files from multiple recipients without revealing the contents of the folder. - -| Password | Sets a password for protecting the link. -| Expiration | Sets an expiry date for the link. The public link expires at the end of the specified day. Note that the administrator can set a default expiration duration you can overwrite. -|=== diff --git a/content/server/10.15/modules/classic_ui/pages/files/version_control.adoc b/content/server/10.15/modules/classic_ui/pages/files/version_control.adoc deleted file mode 100644 index fa31741..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/version_control.adoc +++ /dev/null @@ -1,34 +0,0 @@ -= Version Control -:tab-type-text: versions -:tab-type-link: versions -:description: ownCloud provides a simple version control system for files. Versioning creates backups of files which are accessible via the Versions tab on the Details sidebar. - -== Introduction - -{description} - -== The Versions Tab - -This tab contains the history of the file where you can roll back a file to any previous version. Changes made at intervals greater than two minutes are saved as versions. - -image::files_versioning/concious-persistent-major-versions.png[width=250] - -* To restore a specific version of a file, click the btn:[circular arrow] to the -left. -* Click on the btn:[timestamp] to download it. -* If the Admin has enabled to show the author of a version in the versions history, ownCloud can automatically generate version numbers. Based on this feature, the user can define the actual version to be a major version which gets a major version number and all new upcoming versions start counting from this major number. The user has to click on the btn:[check mark] on the left of the actual version to publish it as major version. -* If you want to make a former version a major version, restore the former version first and make it a major version afterwards. - -The versioning app expires old versions automatically to make sure that the user doesn’t run out of space. The following pattern is used to delete old versions: - -* For the first second we keep one version -* For the first 10 seconds ownCloud keeps one version every 2 seconds -* For the first minute ownCloud keeps one version every 10 seconds -* For the first hour ownCloud keeps one version every minute -* For the first 24 hours ownCloud keeps one version every hour -* For the first 30 days ownCloud keeps one version every day -* After the first 30 days ownCloud keeps one version every week - -The versions are adjusted along this pattern every time a new version gets created. - -The version app never uses more that 50% of the user’s currently available free space. If the stored versions exceed this limit, ownCloud deletes the oldest versions until it meets the disk space limit again. diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/activity.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/activity.adoc deleted file mode 100644 index 1656908..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/activity.adoc +++ /dev/null @@ -1,9 +0,0 @@ -= Activity -:toc: right -:tab-type-text: sharing -:tab-type-link: share -:description: Clicking the Activity tab in the Details view in the web browser shows all activities for a file. Activities can include when a file was created, renamed, and deleted. - -{description} - -image:files/activity-pane.png[The Activity tab of of the Details view in ownCloud] diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/comments.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/comments.adoc deleted file mode 100644 index b0c61b0..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/comments.adoc +++ /dev/null @@ -1,35 +0,0 @@ -= Comments -:toc: right -:tab-type-text: comments -:tab-type-link: comments -:description: In ownCloud, you can add one or more comments on both files and folders. This section describes how to add, edit, and delete comments. - -== Introduction - -{description} - -== Add Comments - -Use the Details view, in xref:files/webgui/overview.adoc#the-overflow-menu[The Overflow Menu], -to add and read comments on any file or folder. Comments are visible to -everyone who has access to the file or folder. To add a comment, as in -the example below, click the btn:[Comments] tab in the Details view, write a -comment in the New Comment field, and click btn:[Post]. - -image:file_menu_comments_2.png[Creating and viewing comments.] - -== Edit Comments - -To edit an existing comment on a file or folder, hover the mouse over -the comment and you will see a pencil icon appear. By clicking on the -pencil, the btn:[Edit Comment] field will appear, pre-filled with the -comment text. Change the text as necessary and click btn:[Save]. -If you change your mind, just click btn:[Cancel]. - -== Delete Comments - -To delete an existing comment on a file or folder, as with editing -comments, hover the mouse over the comment and you will see a pencil -icon appear. Click the pencil, and a rubbish bin icon appears on the far -right-hand side of the comment author’s name, above the btn:[Edit Comment] -text field. Click the btn:[rubbish bin], and the comment will be deleted after a few seconds. diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/details.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/details.adoc deleted file mode 100644 index a4e349f..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/details.adoc +++ /dev/null @@ -1,12 +0,0 @@ -= Details -:toc: right -:tab-type-text: sharing -:tab-type-link: share -:description: The Details view shows all information for a file, split up into four sections: - -{description} - -* xref:files/webgui/activity.adoc[Activities] -* xref:files/webgui/comments.adoc[Comments] -* xref:files/webgui/sharing.adoc[Sharing] -* xref:files/version_control.adoc[Versions] diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/navigating.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/navigating.adoc deleted file mode 100644 index 6a90ac6..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/navigating.adoc +++ /dev/null @@ -1,82 +0,0 @@ -= Navigating the WebUI -:toc: right -:toclevels: 1 -:moz-browser-compatibility-guide-url: https://developer.mozilla.org/en-US/docs/Web/Media/Formats#Browser_compatibility -:description: Navigating through folders in ownCloud is as simple as clicking on a folder to open it and using the back button on your browser to move to a previous level. This section walks you through how to navigate the ownCloud UI. - -== Introduction - -{description} - -== Create and Upload Files and Directories - -At the top of the Files view is a navigation bar. This contains links to uploading and creating new files and folders. - -image:files_page-6.png[The New file/folder/upload menu.] - -To upload or create new files or folders directly in an ownCloud folder, click on the btn:[New] button in the navigation bar (this is the `+` button). There, as in the image above, you can see links to: - -* btn:[Upload a new file] This uploads files from your computer into ownCloud. You can also upload files by dragging and dropping them from your file manager. -* btn:[Create a new text file] This creates a new text file and adds the file to your current folder. -* btn:[Create a new folder] This creates a new folder in the current folder. - -== Select Files or Folders - -image:files_view_mouseover.png[The files view.] - -You can select one or more files or folders by hovering over them (as in the image below) and clicking on their checkboxes. To select all files in the current directory, click on the checkbox located at the top of the files listing. - -image:files_view_select_all.png[The files view with all files selected.] - -When you select multiple files, you can delete all of them, or download them as a ZIP file by using the btn:[Delete] or btn:[Download] buttons that appear at the top. - -NOTE: If the btn:[Download] button is not visible, the administrator has disabled this feature. - -== Filter the Files View - -The left sidebar on the Files page contains several filters for quickly -sorting and managing your files. - -[cols="20%,70%",options="header",] -|======================================================================= -| Option | Description -| All files | The default view; displays all files that you have access to - -| Favorites | Files or folders marked with the yellow star - -| Shared with you | Displays all files shared with you by another user or group - -| Shared with others | Displays all files that you have shared with other users or groups - -| Shared by link | Displays all files that are shared by you via public link - -| External Storage | Files that you have access to on external storage devices - and services such as Dropbox, Google, and Amazon S3 -|======================================================================= - -== Move Files - -You can move files and folders by dragging and dropping them into any directory. - -=== Play Videos - -You can play videos in ownCloud with the Media Viewer app by clicking once on the file. Please note, video streaming by the ownCloud Media Viewer depends on your web browser and the video’s format. - -image:video_player_2.png[Watching a movie.] - -[NOTE] -==== -If your ownCloud administrator has enabled video streaming, but it doesn't work in your Web browser, it may be a browser-related issue. See {moz-browser-compatibility-guide-url}[Mozilla’s Browser Compatibility Guide] for supported multimedia formats in Web browsers. -==== - -=== Settings - -The *Settings* gear icon in the lower left-hand corner of the ownCloud window allows you to show or hide hidden files in your ownCloud Web interface. These are also called dotfiles, because they are prefixed with a dot, e.g. `.mailfile`. - -The dot tells your operating system to hide these files in your file browsers, unless you choose to display them. Usually, these are configuration files, so having the option to hide them reduces clutter. - -image:hidden_files.png[Hiding or displaying hidden files.] - -=== Preview Files - -ownCloud can display thumbnail previews for _images_, _MP3 covers_, and _text files_, if this is enabled by your ownCloud administrator. You can also display _uncompressed text_, _OpenDocument_, _videos_, and _image_ files in the ownCloud embedded viewers by clicking on the file name. There may be other file types you can preview if your ownCloud administrator has enabled them. If ownCloud cannot display a file, it will start a download process and downloads the file to your computer. diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/overview.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/overview.adoc deleted file mode 100644 index e0c5aa4..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/overview.adoc +++ /dev/null @@ -1,92 +0,0 @@ -= WebUI Overview -:toc: right -:toclevels: 1 -:description: You can access your files with the ownCloud Web interface, as well as: create, preview, edit, delete, share, and re-share files. - -== Introduction - -{description} - -IMPORTANT: Your ownCloud administrator has the option to disable these features. If any of them are missing on your system ask your server administrator. - -image:files_page.png[The Files view screen.] - -== File Controls - -When you mouseover, or hover over, a file in the Files view, as in the -image below, ownCloud displays three file controls. These are: - -1. xref:marking-favorites[Marking Favorites] -2. xref:sharing-files[Sharing Files] -3. xref:the-overflow-menu[The Overflow Menu] - -image:files_file-controls.png[File controls] - -=== Marking Favorites - -Click the star to the left of the file icon to mark it as a favorite. -You can quickly find all of your favorites with the Favorites filter on the -left sidebar. - -image:files_mark-as-favorite.png[Marking files as favorites.] - -=== Sharing Files - -The sharing files control is a shortcut to the file and folder sharing -functionality within ownCloud. ownCloud sharing supports: - -* Sharing files and folders with users or groups -* Creating public link shares with hyperlinks -* Listing recipients of existing shares -* Deleting existing shares - -=== The Overflow Menu - -The _Overflow Menu_ allows you to: - -* xref:display-file-details[Display File Details] -* xref:rename-files[Rename Files] -* xref:download-files[Download Files] -* xref:delete-files[Delete Files] - -image:files_page-3.png[Overflow menu.] - -==== Display File Details - -When you display details about a file, by clicking btn:[Details] in the -Overflow Menu, a set of tabs (or views) are available. These are: - -[cols="15%,70%",options="header",] -|====================================================================== -| View | Description -| Details | This shows details about a file, such as its name, size, - and when it was created or last updated. To know more, refer to - the xref:files/webgui/details.adoc[Details] section. -| Activity | This shows a history of activity on the file, such as when - it was created, updated, and shared. To know more, refer to - the xref:files/webgui/activity.adoc[Activity] section. -| Sharing | It’s here that shares are managed. To know more, refer to - the xref:files/webgui/sharing.adoc[Sharing Files] section. -| Version | This shows a history of all the versions of the file. This is - not available for folders. To know more, refer to - the xref:files/version_control.adoc[Version Control] section. -|====================================================================== - -You can see an example of the Activity view in the image below. - -image:files_page-4.png[Details screen] - -==== Rename Files - -To rename a file, click menu:Rename[] in the _Overflow Menu_. -The file's current name will be displayed in an editable text box. -Change the name, click kbd:[Enter], and the file will be renamed. -If you don’t want to rename it, click kbd:[esc] and the file name will be left as is. - -==== Download Files - -To download a file, click menu:Download[] in the _Overflow Menu_. - -==== Delete Files - -To delete a file, click menu:Delete[] in the _Overflow Menu_. diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/quota.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/quota.adoc deleted file mode 100644 index ee34516..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/quota.adoc +++ /dev/null @@ -1,52 +0,0 @@ -= Storage Quotas -:toc: right -:description: Your ownCloud admin has the option to set a storage quota on users. Look -at the top of your Personal page to see what your quota is, and how much -you have used. - -== Introduction - -{description} - -image:quota1.png[image] - -It may be helpful to understand how your quota is calculated. Metadata -(_thumbnails_, _temporary files_, _cache_, and _encryption keys_) takes -up about 10% of disk space, but is not counted against user quotas. Some -apps store information in the database, such as the Calendar and -Contacts apps. This data is excluded from your quota. - -When other users share files with you, the shared files count against -the original share owner’s quota. When you share a folder and allow -other users or groups to upload files to it, all uploaded and edited -files count against your quota. When you re-share files shared with you, -the re-share still counts against the quota of the original share owner. - -Encrypted files are a little larger than unencrypted files; the -unencrypted size is calculated against your quota. Deleted files that -are still in the trash bin do not count against quotas. The trash bin is -set at 50% of quota. Deleted file aging is set at 30 days. When deleted -files exceed 50% of quota then the oldest files are removed until the -total is below 50%. - -When version control is enabled, the older file versions are not counted -against quotas. If you create a public link share via URL, and allow uploads, -any uploaded files count against your quota. - -== Quotas Are Neither Hard Nor Soft - -Quotas are not strictly hard quotas, but nor are they soft quotas -either. They’re more hard quotas with the exception of always being able -to restore deleted files. - -Why? Well, say that a user’s Trash bin contains one or more files. The -user uploads several files and in the process reaches their quota limit. - -If hard quotas were enforced, the user would be prevented from being -able to restore any deleted file. However, with the Trash bin exception -in place, files can always be restored, but no new files can be -uploaded, once a quota has been reached. - -This user workflow may sound peculiar, but not allowing a user to -restore files would make for a poor user experience. Given that, this -exception is allowed. diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/search.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/search.adoc deleted file mode 100644 index e05caa5..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/search.adoc +++ /dev/null @@ -1,39 +0,0 @@ -= Search & Full Text Search -:toc: right -:description: ownCloud comes with a regular search function allowing you to find files by their file name or parts of their names. Click on the magnifier icon in the upper right-hand corner of the web interface. In addition, a Full Text Search app can be enabled by your administrator. - -== Introduction - -{description} Refer to the xref:{latest-server-version}@server:admin_manual:configuration/general_topics/search.adoc[Full Text Search] app in the ownCloud Admin Manual for more information about how to deploy it. - -== Regular Search - -The regular search function provided as base functionality in the ownCloud web interface offers a simple search for *file names* only. Note that no file content will be part of any search result. - -=== Rules for Regular Search - -* Search is not case-sensitive, capital letters are treated the same as lower case characters. You can type Spain or spain and will get the same results. -* When you start typing, search also starts. -* The search term is taken as it is and not interpreted to refine search results. -* When entering the pattern to search for, you get results for *any filenames* that contain that pattern. -* When starting at the top level of your files, which is "All files", you will also see results in subfolders. -* When changing into a directory, search starts in this folder, displays the results, and continues to search in subsequent folders. -* A click on one of the results takes you either to the location of the file, if you are not already in that folder, or the item is opened. - -== Full Text Search - -The Full Text Search app enables you to search not only for file names but also for content inside files. The most common file formats are supported. - -=== Rules for Full Text Search - -* Like with the regular search, you can enter only the first part of a string and it matches all occurrences of words starting with the search string. - -* *OR case:* When using more than one search term _without_ any quotes, separated by a blank, each term is treated with a logical OR, case insensitive. Searching for _Desktop_ _Sync_ will return all results that contain _Desktop_ or _Sync_. - -* *AND / NOT case:* When using more than one search term _prefixed_ either by a plus (\+) or minus (-) symbol, separated by a blank, each term that is prefixed with a `+` is treated with a logical AND, terms that are prefixed with a `-` are treated as a logical NOT. All checks are case insensitive. Searching for +_Desktop_ +_Sync_ -MSI will return all results that contain _Desktop_ AND _Sync_ but not NOT _MSI_. - -* *Exact case:* When using more than one search term _enclosed_ with quotes, separated by a blank, the complete term is the search pattern. Searching for "_Desktop_ _Sync_" will return all results that contain _Desktop Sync_. Note that beside any match, all existing file names are additionally listed as matches. - -* *Wildcards:* When looking for all terms containing a specific string like "pain", wildcards can be used. Using an `asterisk` like `*ain` gives you results like braine, pain, Spain and painful. Using a `question mark` like `?ain` limits the preceding characters to exactly one, only pain and painful would show up. -+ -TIP: Using the asterisk within a word will ignore everything that follows after the asterisk. A trailing asterisk is always assumed in the search. diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/sharing.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/sharing.adoc deleted file mode 100644 index d54f95f..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/sharing.adoc +++ /dev/null @@ -1,169 +0,0 @@ -= Sharing Files -:toc: right -:tab-type-text: sharing -:tab-type-link: share -:description: Clicking the share icon on any file or folder opens the Details view on the right, where the Share tab has focus. - -== Introduction - -{description} - -== Sharing Status Icons - -Any folder that has been shared is marked with the `Shared` overlay icon. Public link shares are marked with a chain link. Unshared folders are blank. - -image::files/webgui/files_page-5.png[Share status icons,width=350] - -If your ownCloud server is the Enterprise edition, you may also have access to Sharepoint and Windows Network Drive file shares. These have special status icons. An icon with a red plugin and background means you have to login to get access to the share. - -image::files/webgui/files_share-options.png[image,width=350] - -== Creating Shares - -* For sharing a file or folder, there is a text field below the Share tab. In this sharing dialog, you can enter multiple users at once using their identifiers (e.g., display name, user ID, email address, federated cloud ID) as a comma-separated list (e.g., `alice,bob@example.org,carol`. -+ -image::files/webgui/share-with-multiple-users.png[] -+ -Based on the input, ownCloud will decide how to create the shares (e.g., share with an internal user, invite a new guest, create a federated share). This way, users can easily invite many recipients at once. - -* If username auto-completion is enabled, ownCloud will try to complete it for you when you start typing the user or group name. - -[NOTE] -==== -From 10.0.8, user and group name search results are dependent on a new -xref:{latest-server-version}@server:admin_manual:configuration/server/config_sample_php_parameters.adoc[configuration setting], called `user.search_min_length` (it is set to 4 by default). This setting enhances the search performance but requires that search terms contain at least the defined number of characters. Consequently, search terms shorter than the defined number of characters will not return a list of matches. However, they will return an existing user or group with a name of the same length as the search term. -==== - -After a file or folder has been shared, xref:share-permissions[Share Permissions] can be set for it. In the image below, you can see that the directory "event-Photos" is shared with the user "pierpont", who can share, edit, create, change, and delete the directory. - -image::files/webgui/files_page-2.png[Sharing files,width=450] - -=== What Happens When Share Recipients Move Files and Folders? - -If a share recipient has "**can edit**" privileges and moves files or folders out of the share, ownCloud stores a backup copy of the moved file/folder in the Deleted Files (Trash) of the share’s owner. The user who moved the file/folder out of the share still has the original copy there, along with its attached metadata. - -That way, the files/folders are not permanently lost. By clicking the btn:[Restore] link, next to the respective file or folder, ownCloud will restore these files/folders to their original location. - -image::sharing/restore-files.png[Restore (backup) files from the Deleted Files directory,width=450] - -NOTE: Restoring files restores the backup copy for *all users*, including the user that originally moved them, into the original folder. - -=== Sharing Files with Guest Users - -Users can also share files and folders with guest users. To do so, your ownCloud administrator will need to have installed the {oc-marketplace-url}/apps/guests[Guest application]. - -If it’s already installed, in the `**User and Groups**` field of the `**Sharing**` panel type the email address of a user who is not already a user in your ownCloud installation. Note that the ownCloud admin can exclude domains. A popup with the suffix `(guest)` will appear as in the screenshot below. - -image::guest-users/share-with-guest-users.png[Sharing with guest users,width=350] - -After you do that, the content will be shared with the user with all permissions applied, except for the ability to share with other users. - -image::guest-users/content-shared-with-guest-user.png[Content shared with a guest user,width=400] - -NOTE: Guest users can also use the **Desktop/IOS/Android Sync Clients** to access synced files locally. - -== Updating Shares - -To change any of the properties of a share, you need to open the Share tab again. From there, you can: - -* Delete a user’s access to a share -* Give more users access to a share -* Change a user’s share permissions -* Add or remove password protection -* Set or remove a share’s expiration date - -This functionality is already described in other parts of this documentation and won’t be covered in more detail here. - -== Deleting Shares - -Despite the name of this section, the content of shares is not really deleted, but access of users revoked. When all users' access to a shared resource has been removed, the resource is no longer shared. - -To do that, you need to click on the btn:[rubbish bin] icon, on the far right-hand side of the name of each user it’s been shared with, who should no longer have access to it. - -== Renaming Shares - -Both the sharer _and_ all share recipients can rename a share at any time. However, when one user renames a share, it only renames their version; other users don't see the new share name but the original one. - -In case that's a little unclear, step through the following scenario: - -____ -User Jenny creates a directory called "_Growth Projects 2019_" and shares it with James, Peter, and Sarah. -A week later, James renames the share to "_Growth Projects 2019 — Draft!_". -James sees the share with the new name, but Jenny, Peter, and Sarah continue seeing the share with its original name ("_Growth Projects 2019_"). -____ - -This feature may seem a little strange; however, it provides flexibility for all users to manage their files and folders as they see fit. - -== Password Protecting Files - -It’s also possible to password protect shared files and folders. If you want to do so, then you need to enable this functionality. Click the checkbox labeled btn:[Password protect] under the "_Share Link_" section. - -A password field appears. Enter the password that the user will need to access the shared resource and press the return key. - -== Using Private Links - -Another way to access a file or folder is via a private link. It’s a convenient way of creating a permanent link for yourself or to point others to a file or folder within a share. To access the private link, in the Sharing Panel for a file or folder next to its name you’ll see a small link icon (1) as in the screenshot below. - -image::public-link/private-link.png[Obtaining a private link for a shared file or folder,width=350] - -If you click it, a new textbox will appear above the "**Collaborative tags**" field, populated with the link’s URI (2). - -NOTE: Only people who have access to the file or folder can use the link. - -== Changing The Share Expiration Date - -You can set an expiration date on any user, group, federated and public link shares. The administrator may have set a default expiration for shares. If so, then new shares will have the default expiration. You may adjust or remove the expiration date. - -The administrator may have enforced the default expiration to be the maximum expiration. In that case, you must set an expiration date less than or equal to the maximum. - -The share will expire at the end of the specified expiration date. Recipients of the share will no longer be able to access it. - -== Creating or Connecting to Federation Share Links - -Federated Cloud Sharing allows you to mount file shares from remote ownCloud servers, and manage them just like a local share. See xref:files/federated_cloud_sharing.adoc[Using Federation Shares] to learn how to create and connect to new Federated Cloud shares. - -== Share Permissions - -Shares can have a combination of the following five permission types: - -[cols="15%,70%",options="header",] -|=== -| Permission -| Definition - -| can share -| Allows the users you share with to re-share - -| can edit -| Allows the users you share with to edit your shared files and to collaborate using the Documents app - -| create -| Allows the users you share with to create new files and add them to the share - -| change -| Allows uploading a new version of a shared file and replacing it - -| delete -| Allows the users you share with to delete shared files -|=== - -== Creating Drop Folders - -As of ownCloud version 10.0.2, users can create upload-only, public shares (otherwise known as "Drop Folders"). Drop Folders allow users to upload files to a central location, but don’t allow them to either see or change any existing files, which have already been uploaded. - -image::sharing/create-drop-folder.png[Create a Drop Folder,width=350] - -To create one: - -1. View the sharing panel of the folder that you want to share as a drop folder, select menu:Public Links[Create public link]. -2. As with other shares, provide the name in the *"Link Name"* field. -3. Check btn:[Allow editing], un-check btn:[Show file listing], and then un-check btn:[Allow editing]. -4. Finally, click btn:[Save] to complete creation of the share. - -Now, as with other public links, you can copy the link to the share and pass it on as necessary. - -== Using Drop Folders - -image::sharing/use-drop-folders.png[Using Drop Folders,width=350] - -When users open the share link, they will see a page where they can either click to select files to share, or drag-and-drop files directly to share them. After a file has been successfully uploaded, a preview of the file will be displayed (if possible). diff --git a/content/server/10.15/modules/classic_ui/pages/files/webgui/tagging.adoc b/content/server/10.15/modules/classic_ui/pages/files/webgui/tagging.adoc deleted file mode 100644 index 91b717c..0000000 --- a/content/server/10.15/modules/classic_ui/pages/files/webgui/tagging.adoc +++ /dev/null @@ -1,78 +0,0 @@ -= Tagging Files -:toc: right -:description: ownCloud provides via the webinterface the ability to assign one or more tags to files and folders. - -== Introduction - -{description} To do so, go to the "**Details**" view in the -xref:files/webgui/overview.adoc#the-overflow-menu[The Overflow Menu] and enter the "**Tags**" tab. - - -image:file_popup-menu.png[Files popup menu.] - -There, you’ll see a text field with the placeholder text "**Collaborative tags**" -if no tags have been added yet. - -In that field, type the tag’s name. If you want to use multiple words, -there is no need to use single or double quotes. Type as many words as -you want for the tag name. When you press the return key, your tag will -be saved. - -NOTE: All tags are collaborative tags, so they are shared by all users on your ownCloud server. - -image:files_page-7.png[Creating file tags.] - -When you place the cursor inside the tags field and as you type the tag -name, a list of the collaborative tags will appear. If you type a new tag name, -the visible tags list will be filtered based on the text you’ve -entered. - -If you see a tag in the list which is what you had intended to type or -is a better fit than what you had in mind, click on it, and it will be -added to the file or folder’s tag list. This can save you a lot of time -and effort. - -NOTE: The assigned tags are also visible in the "**Details**" view under the file name. When you click on a tag, the "**Tags**" tab will open. - -== Untag a File or Folder - -If a file or folder is already tagged, the tags assigned will have a check mark in the dropdown list, -to the left of the tag’s name. To remove that tag -from the file or folder, click the tag’s name. You will see that the -check mark disappears. - -== Edit Tags - -To edit a tag, click the pencil icon on the right-hand side of the -tag’s name in the tags list. This will display a text box -containing the tag’s name. Be sure that you want to change the tag’s -name since it will be updated for all users. - -== Delete Tags - -To delete a tag, click the trash can icon on the far right-hand -side of the tag in the dropdown list. This removes the tag from the collaborative tags list. As with -renaming a tag, keep in mind that deleting a tag removes it for all users. -So be sure that you want to do this. - -== Filter by Tag - -To filter by tag, use the *Tags* filter on the left sidebar of the Files -page. There are three types of tags: - -[cols="15%,70%",options="header",] -|=== -| Tag | Description -| Visible | All users may see, rename, and apply these tags to files and folders -| Restricted | Tags are assignable to and editable by only the users and groups which -have permission to use them. Other users can filter files by -restricted tags, but cannot tag files with them or rename them. -The tags are marked (restricted) -| Invisible | Visible only to ownCloud admins -|=== - -When you use the *Tag* filter on your Files page, you’ll see something -like the following image. If you do not have Admin rights, you will -not see any invisible tags. - -image:files_page-8.png[Viewing file tags.] diff --git a/content/server/10.15/modules/classic_ui/pages/found_a_mistake.adoc b/content/server/10.15/modules/classic_ui/pages/found_a_mistake.adoc deleted file mode 100644 index a227a6d..0000000 --- a/content/server/10.15/modules/classic_ui/pages/found_a_mistake.adoc +++ /dev/null @@ -1,7 +0,0 @@ -= Have You Found a Mistake In The Documentation? -:description: If you have found a mistake in the documentation, no matter how large or small, please let us know. - -:new-issue-url: https://github.com/owncloud/docs/issues/new - -{description} You can {new-issue-url}[create a new issue] in the docs repository. - diff --git a/content/server/10.15/modules/classic_ui/pages/index.adoc b/content/server/10.15/modules/classic_ui/pages/index.adoc deleted file mode 100644 index b33a428..0000000 --- a/content/server/10.15/modules/classic_ui/pages/index.adoc +++ /dev/null @@ -1,16 +0,0 @@ -= Introduction -:description: ownCloud is an open source file sync and share software for everyone from individuals operating the free ownCloud Classic edition, to large enterprises and service providers operating the ownCloud Enterprise Subscription. - -*Welcome to ownCloud: your self-hosted file sync and share solution.* - -{description} ownCloud provides a safe, secure, and compliant file synchronization and sharing solution on servers that you control. - -You can share one or more files and folders on your computer, and synchronize them with your ownCloud server. -Place files in your local shared directories, and those files are immediately synchronized to the server and to other devices using the ownCloud Desktop Sync Client, Android app, or iOS app. -To learn more about the ownCloud desktop and mobile clients, please refer to their respective manuals: - -* https://doc.owncloud.com/desktop/latest/[ownCloud Desktop Client] -* https://doc.owncloud.com/android/latest[ownCloud Android App] -* https://doc.owncloud.com/ios-app/latest[ownCloud iOS App] - -NOTE: This user guide covers the latest ownCloud version and the latest app versions only. This is because there would be too many dependencies and possibilities to cover. If you are using older versions, some items may not be present or look different. diff --git a/content/server/10.15/modules/classic_ui/pages/integration/index.adoc b/content/server/10.15/modules/classic_ui/pages/integration/index.adoc deleted file mode 100644 index b13fc1f..0000000 --- a/content/server/10.15/modules/classic_ui/pages/integration/index.adoc +++ /dev/null @@ -1,6 +0,0 @@ -= Integration - -This section is dedicated to integrating ownCloud with other products, for now only Microsoft Teams, but more to come. - -- xref:integration/ms-teams.adoc[Microsoft Teams] - diff --git a/content/server/10.15/modules/classic_ui/pages/integration/ms-teams.adoc b/content/server/10.15/modules/classic_ui/pages/integration/ms-teams.adoc deleted file mode 100644 index 195f1f6..0000000 --- a/content/server/10.15/modules/classic_ui/pages/integration/ms-teams.adoc +++ /dev/null @@ -1,27 +0,0 @@ -= Integrate ownCloud into Microsoft Teams -:toc: right -:description: You can access your ownCloud via Microsoft Teams if your administrator has created an app available in your organization's app catalog. It is possible that the admin already has enabled the app for the users, in this case you do not need to search for it in your organization's app catalog as it is already pinned. - -== Introduction - -{description} - -== Access the App - -To access the app, perform the following steps: - -. Log in to Teams. - -. Click on the overflow menu, select Apps and search for *ownCloud for Teams* or the name provided by your admin. -+ -image:integration/ms-teams/owncloud-teams-app.png[,width=60%] -+ -TIP: You can pin the app to your left sidebar permanently. Right-click on the icon and select "Pin". - -. Log in to ownCloud by clicking on *Login to ownCloud with Azure AD*. -+ -image:integration/ms-teams/login-to-owncloud-with-azure-ad.png[,width=80%] - -. For security reasons, you need to repeat the login process after a certain idle time. - -. Repeat the steps if there is more than one ownCloud for Teams app available accessing different ownCloud hosts. diff --git a/content/server/10.15/modules/classic_ui/pages/online_collaboration.adoc b/content/server/10.15/modules/classic_ui/pages/online_collaboration.adoc deleted file mode 100644 index a8697fa..0000000 --- a/content/server/10.15/modules/classic_ui/pages/online_collaboration.adoc +++ /dev/null @@ -1,39 +0,0 @@ -= Online Collaboration -:toc: right -:description: Collabora Online is a powerful LibreOffice based online office that supports all major document, spreadsheet and presentation file formats, and is integrable with ownCloud. - -:collabora-online-url: https://www.collaboraoffice.com/collabora-online/ -:libreoffice-url: https://www.libreoffice.org/ -:secure-view-label: Secure View (with watermarks) - -== Collabora Online - -{description} See the {collabora-online-url}[Collabora Online] and {libreoffice-url}[LibreOffice] for more details. - -=== Secure View - -Secure View is a way to securely distribute information, without that information being able to leave your organisation. It provides the ability to restrict access to documents, in _read-only_ shares, so that recipients cannot copy, download, or edit shared files. - -When enabled, documents will be viewed through Collabora Online with a watermark. In addition, the ability to print and export files (with watermarks) is available, once Secure View is enabled. - -NOTE: This feature is *not* available in the community edition, or for Public Links. - -==== How to Use Secure View - -image::enterprise/collaboration/secure-view/collabora-online-administration.png[Configure Secure View in ownCloud Classic.,align="center"] - -To enable Secure View for an existing, or new, share: - -* enable btn:[{secure-view-label}] -* enable btn:[can print / export PDF] (_optional_). This allows documents to be printed and exported through Collabora Online. - -[IMPORTANT] -==== -"_can edit_" and "_{secure-view-label}_" are mutually exclusive. -If "_can edit_" is enabled and a user enables "_{secure-view-label}_", then "_can edit_" is automatically disabled. -==== - -When "_{secure-view-label}_" is enabled, any attempts to download the file will be blocked, as exemplified in the screenshot below. -Additionally, select, copy, and paste are disabled. - -image::enterprise/collaboration/secure-view/access-denied.png[Access denied to a document when it is protected by Secure View] diff --git a/content/server/10.15/modules/classic_ui/pages/personal_settings/custom_groups.adoc b/content/server/10.15/modules/classic_ui/pages/personal_settings/custom_groups.adoc deleted file mode 100644 index 5fdb9cb..0000000 --- a/content/server/10.15/modules/classic_ui/pages/personal_settings/custom_groups.adoc +++ /dev/null @@ -1,74 +0,0 @@ -= Custom Groups -:toc: right -:description: With custom groups, users are able to define their own groups and manage contributing users themselves. - -== Introduction - -{description} To use custom groups, the administrator has to enable this feature. - -== Notes - -Note that the admins can: - -* Restrict the management of custom groups to admins -* Define that admins do not have access to custom groups -* Define that global groups can not use the custom groups feature - -For details contact your administrator. - -== Creating Custom Groups - -To configure custom groups, go to menu:Settings[Personal > Custom Groups] - -image::personal-settings/custom-groups/user_settings_custom_groups.png[The Custom Groups administration panel] - -To create a new custom group: - -* in the text field at the top where you see the placeholder text: btn:[Group name] -* enter the group name and click btn:[Create group]. - -You will see the new custom group appear in the groups list. - -[NOTE] -==== -Please be aware of two things: - -. Custom groups are visible *only* to members of the group, but *not* to anyone outside the group. -. By default, ownCloud administrators can see and modify all custom groups but this setting can be changed by the admin. -==== - -== Managing Custom Groups - -You can _add users_, _remove users_ or _change a user's role_. Click on the group name and a new frame will appear as shown in the image below. Changes can only be made if you are either ownCloud admin with custom group permission or group admin. - -image::personal-settings/custom-groups/manage-group-members.png[Manage members in a custom group, width=300] - -* When adding a user, just start typing the username and suggestions will get listed. -* If the ownCloud admin has enabled the Guests app, you can also invite external guests to this group. To do so, just type the email address of the guest to invite. It is not sufficient to add an external user to a custom group to grant him access to your ownCloud. The custom group must be member of a share that is created. The external user will then be able to access the shares granted to the custom groups he is member of. -+ -NOTE: An ownCloud administrator can create a domain blocklist for guest user invitation. - -* You can share with multiple users at once by entering their identifiers (e.g., display name, user ID, email address, federated cloud ID) as a comma-separated list in the sharing dialog (e.g., `alice,bob@example.org,carol`. Based on the inputs, ownCloud will decide how to create the shares (e.g., share with an internal user, invite a new guest, create a federated share). This way, users can easily invite many recipients at once. -* When removing a user, click on the btn:[Waste bin] symbol on the right side of the user. -* Click on the btn:[Pen] symbol to change the users role. -* With the button _Leave this group_, you can remove yourself from the group. -* Via the buttons _Export as CSV_ and _Import as CSV_ you can export or import your group members and their roles. - -NOTE: Members can only use a group for sharing, whereas group owners can manage group membership, change a group’s name, change members’ roles and delete groups. You can add as many group owners as you like. - -== Changing Group Names - -If you want to change the name of a custom group, move the mouse over the group’s name in the custom groups list, and a pencil will appear to the right of the current name. Click on it, and a text field will appear with the existing name. Change the name and click enter. - -image::personal-settings/custom-groups/rename-custom-group.png[Rename a custom group,width=300] - -== Sharing With the Group - -Sharing a file or folder with your custom group works like xref:files/webgui/sharing.adoc[sharing files and folders] with other users: - -* Open the btn:[Sharing] panel in your files view. -* Then, in the btn:[User and Groups] field, type part of the name of the custom group. - -The name of the group should be displayed in a popup list, which you can see in the screenshot below. Click on it, and the file or folder will then be shared with your custom group with all permissions initially set. - -image::personal-settings/custom-groups/share-to-custom-group.png[Sharing files and folders with custom groups,width=600] diff --git a/content/server/10.15/modules/classic_ui/pages/personal_settings/general.adoc b/content/server/10.15/modules/classic_ui/pages/personal_settings/general.adoc deleted file mode 100644 index 7752eac..0000000 --- a/content/server/10.15/modules/classic_ui/pages/personal_settings/general.adoc +++ /dev/null @@ -1,113 +0,0 @@ -= General Settings -:toc: right -:toclevels: 2 -:description: In general settings, some of the features you will see include the following: - -== Introduction - -{description} - -* Usage and available quota -* Manage your profile picture -* Full name + -You can make this anything you want, as it is separate from your ownCloud login name, which is unique and cannot be changed -* Email address -* List your group memberships -* Manage your password -* Choose the language for your ownCloud interface -* Account related settings -* Links to desktop and mobile apps -* Manage your activity stream and notifications -* Default folder to save new documents to -* Your federated sharing ID -* Social sharing links -* ownCloud version - -The following image is an example screen of the General section: - -image::personal-settings/general/general.png[General settings page,width=400] - -== Managing Your Profile Picture - -image::personal-settings/general/profile-picture-overview-annotated.png[width=350] - -=== Changing Your Profile Picture - -There are two options to set your profile picture: - -* You can upload an image; or -* Select an existing profile picture - -==== Upload a Profile Picture - -To upload an image from your device, click the "_Upload new_" image:personal-settings/general/upload-profile-picture.png[] button, which opens a file browser with which you can choose an image to upload. After you’ve chosen an image, you will then be able to crop the uploaded image, if required, to just the segment of the image that you want to use for your profile picture. You can see an example in the screenshot below. - -.Crop the new profile picture -image::personal-settings/general/set-profile-picture.png[width=300] - -When you’re happy with the image, click btn:[Choose as profile picture], and the image will be set as your profile picture. - -TIP: The image can be a maximum of 20MB in size. - -==== Select a Profile Picture - -To select a profile picture from images in your ownCloud, click the _Select from Files_ image:personal-settings/general/choose-profile-picture-button.png[] button and the profile picture chooser will open. From there, pick the profile picture that you want and click btn:[Choose]. - -.Choose a new profile picture -image::personal-settings/general/select-profile-picture.png[width=400] - -=== Remove Your Profile Picture - -To remove a custom profile picture, click the _Remove Profile_ image:personal-settings/general/remove-profile-picture-button.png[] button. -After that, the image will revert to the default image, present when you first logged in. - -== Update Your Full Name - -To update (or change) your full name, amend the existing text in the text box below “Full name”. -After a few seconds, your full name will be auto-saved. - -.Successfully updated full name -image::personal-settings/general/auto-save-fullname.png[] - -If the full name cannot be changed, you will see a notification, as in the example below. - -.Problem updating full name -image::personal-settings/general/cannot-change-fullname.png[] - -== Update Your Email Address - -To update your email address, change the address in the text box below “Email” and click btn:[Set email]. - -== Update Your Password - -.Update current password. -image::personal-settings/general/update-password.png[] - -To change your password, under Password, enter your current password in the first password field (with the placeholder text “Current password”) and your new password in the second password field (with the placeholder text “New password”), and then click btn:[Change password]. - -include::partial$configuration/user/update-password-note.adoc[] - -== Set the Language - -.Change profile’s language -image::personal-settings/general/update-language.png[] - -To change the language for your user account, pick the desired language from the drop-down menu under Language. -The new language will be auto-saved shortly after you select it. - -== Account Related Settings - -In the Account section, you will see the following buttons: - -image::personal-settings/general/account-related-settings.png[width=450] - -* To comply with article 15 of the GDPR framework, ownCloud provides the following buttons to: -+ --- -** Request data export -** Request account deletion --- -+ -When a user clicks on one of these buttons, the admin group will receive an email with the users request for further processing. - -* If users need to change their role, they need to click the btn:[Request new role] button, enter the request and send it to the admin group for further processing. A possible change can be that the user needs to be a group admin for a particular custom group. diff --git a/content/server/10.15/modules/classic_ui/pages/personal_settings/index.adoc b/content/server/10.15/modules/classic_ui/pages/personal_settings/index.adoc deleted file mode 100644 index d08ddab..0000000 --- a/content/server/10.15/modules/classic_ui/pages/personal_settings/index.adoc +++ /dev/null @@ -1,12 +0,0 @@ -= Personal Settings -:description: As a user, you can manage your personal settings. To access them: Click on your username in the top, right-hand corner of the WebUI of your ownCloud instance. - -{description} The Personal Settings Menu opens. - -image:personal-settings/oc_personal_settings_dropdown.png[screenshot of user menu at top-right of ownCloud Web GUI] - -When clicked, the *Personal* list on the top left on the screen appears: - -image:personal-settings/personal-settings-menu.png[screenshot of user menu at top-right of ownCloud Web GUI] - -TIP: The options listed in the Personal Settings page depend on the applications that are enabled by the administrator. diff --git a/content/server/10.15/modules/classic_ui/pages/personal_settings/security.adoc b/content/server/10.15/modules/classic_ui/pages/personal_settings/security.adoc deleted file mode 100644 index 9f41025..0000000 --- a/content/server/10.15/modules/classic_ui/pages/personal_settings/security.adoc +++ /dev/null @@ -1,120 +0,0 @@ -= Security -:toc: right - -:cors-url: https://en.wikipedia.org/wiki/Cross-origin_resource_sharing -:gps-ms-auth-url: https://play.google.com/store/apps/details?id=com.azure.authenticator&hl=en&gl=US -:ios-ms-auth-url: https://apps.apple.com/us/app/microsoft-authenticator/id983156458 -:gps-google-auth-url: https://play.google.com/store/apps/details?id=com.google.android.apps.authenticator2&hl=en&gl=US -:ios-2fas-url: https://apps.apple.com/app/2fa-authenticator-2fas/id1217793794 -:gps-2fas-url: https://play.google.com/store/apps/details?id=com.twofasapp&hl=en&gl=US - -== Introduction - -The security settings page allows for: - -* Managing Two-Factor Authentication (if enabled by the administrator) -* Managing CORS white-listed domains -* Viewing and deleting user sessions -* Creating new app passcodes - -== Settings - -=== Two-Factor Authentication - -Two-Factor Authentication appears only if enabled by the administrator. It is never enabled by default and as a user you can opt-in and also stop this kind of additional security measure. When enabled and set up, you have to enter, in addition to your password, a second factor which is a time-based one-time password (TOTP) provided via another device during the web login. This device can be a mobile phone or another device providing the second factor, e.g. via an app or SMS. - -In the setup example below, an app on the mobile phone will be used to provide the second factor. For your convenience, some example apps are listed: - -iOS App Store:: -{ios-ms-auth-url}[Microsoft Authenticator] + -{ios-2fas-url}[2FA Authenticator (2FAS)] - -Google Play Store:: -{gps-ms-auth-url}[Microsoft Authenticator] + -{gps-google-auth-url}[Google Authenticator] + -{gps-2fas-url}[2FA Authenticator (2FAS)] - -.Enable Two-Factor Authentication -image::personal-settings/security/enable-2fa-totp.png[] - -After enabling Two-Factor Authentication via the btn:[Activate TOTP] check mark, the image changes and you can proceed with finalizing the setup. - -.Activated Two-Factor Authentication -image::personal-settings/security/activate-2fa-totp.png[] - -To finalize the setup, follow the app's directions to scan the QR code. The number displayed (2nd factor) needs to be entered in the browser dialog in the btn:[Authentication code] field. - -Log out and after your next regular login with username and password, you will be asked to enter the number that the app provides. The number changes after some time and usually a counter is shown how much time is remaining after the next number appears. - -==== Disable Two-Factor Authentication - -You can disable the two-factor authentication at any time by unchecking btn:[Activate TOTP] - -==== Lost or Defect Device - -If the device providing the second factor gets lost or is defect, the administrator can temporarily disable the two-factor authentication for the account in question. A login can then be made without providing the second factor. If the issue is solved, the administrator can re-enable two-factor authentication. - -=== CORS White-listed Domains - -.CORS (Cross-origin Resource Sharing) configuration section -image::personal-settings/security/cors-section.png[] - -The {cors-url}[CORS (Cross-origin resource sharing)] white-listed domains section lists zero or more domains which the ownCloud instance is allowed to request resources from, in addition to the current domain, for your user account. - -By default, as in the screenshot above, no domains will be listed. -If you want to add one, or more, add them, one at a time, in the Domain text field, and click btn:[Add]. -You will then see them listed, as in the screenshot below. - -[IMPORTANT] -.Valid records: -==== -[width="70%",cols="45%,60%",options="header"] -|=== -| Record Scheme | Example -| protocol + domain | \https://example.com -| protocol + domain + port | \https://example.com:80 -| protocol + ip | \http://127.0.0.1 -| protocol + ip + port | \http://127.0.0.1:8080 -|=== - -_CORS entries follow strict rules, only *http* and *https* protocols are allowed._ -==== - -To remove one, or more, click the trashbin icon next to the relevant domain name. - -.CORS Configuration Section with white-listed domains -image::personal-settings/security/cors-section-with-white-listed-domains.png[] - -You will then be prompted to confirm if you want to remove the domain. -If you do, click btn:[Yes]. -If you do not, click btn:[No]. - -=== Sessions - -.Sessions section -image::personal-settings/security/sessions-section.png[] - -The sessions section, which you can see an example of below, lists all your current user sessions, across web, desktop, and mobile clients. -Specifically, it lists the browser user agent string and the time of the most recent activity. -If you want to log a session out, then click the Disconnect button at the far right of the relevant session. - -=== App Passwords / Tokens - -.App password / tokens section -image::personal-settings/security/app-password-tokens-section.png[] - -This section lets you give an app or device permissions to access your ownCloud account. -App passwords are a security measure which let you hide your actual password. -To create one, insert the app name in the text field and click btn:[Create new app passcode]. - -.Create new app password / token -image::personal-settings/security/create-new-app-password-token.png[] - -As you can see in the screenshot above, a username and password/token will be generated, and the app will be listed in the apps list in this section. - -IMPORTANT: Make sure you either securely store the username and password / token or ensure that the receiver does, because once you click btn:[Done] the username and password / token will longer be discoverable. - -If you want to revoke access for a device or app, click the trash bin icon next to its name in the apps list. - -IMPORTANT: No confirmation of revocation is requested. -Once you click the trash bin icon, the apps access is revoked. diff --git a/content/server/10.15/modules/classic_ui/pages/personal_settings/sharing.adoc b/content/server/10.15/modules/classic_ui/pages/personal_settings/sharing.adoc deleted file mode 100644 index 713e189..0000000 --- a/content/server/10.15/modules/classic_ui/pages/personal_settings/sharing.adoc +++ /dev/null @@ -1,17 +0,0 @@ -= Sharing - -== Introduction - -This section allows you to set whether or not you want to: - -* Automatically accept new incoming local user shares -* Allow finding you via autocomplete in share dialog. - -== Settings - -To enable either, check the respective checkbox. This section also allows for configuring -xref:files/federated_cloud_sharing.adoc[Federated Cloud Sharing]. - -.User Sharing Settings -image::personal-settings/sharing/sharing.png[] - diff --git a/content/server/10.15/modules/classic_ui/pages/personal_settings/storage.adoc b/content/server/10.15/modules/classic_ui/pages/personal_settings/storage.adoc deleted file mode 100644 index e846724..0000000 --- a/content/server/10.15/modules/classic_ui/pages/personal_settings/storage.adoc +++ /dev/null @@ -1,13 +0,0 @@ -= External Storage -:description: If your ownCloud administrator has enabled *External Storage* for users, you will be able to add one or multiple external storages depending on the allowed storage types. - -== Introduction - -{description} - -.User Storage Settings -image::personal-settings/storage/external-storage.png[] - -== Configuration - -To configure one or more external storages, please refer to the xref:{latest-server-version}@server:admin_manual:configuration/files/external_storage/index.adoc[External Storage documentation]. diff --git a/content/server/10.15/modules/classic_ui/pages/pim/index.adoc b/content/server/10.15/modules/classic_ui/pages/pim/index.adoc deleted file mode 100644 index cf87df8..0000000 --- a/content/server/10.15/modules/classic_ui/pages/pim/index.adoc +++ /dev/null @@ -1,4 +0,0 @@ -= Contacts & Calendar -:description: The Contacts, Calendar, and Mail apps can be installed from the ownCloud Marketplace in the menu:Market[Productivity] category and can be installed by clicking btn:[Install] on their respective entries but are not with official support. - -{description} diff --git a/content/server/10.15/modules/classic_ui/pages/pim/sync_ios.adoc b/content/server/10.15/modules/classic_ui/pages/pim/sync_ios.adoc deleted file mode 100644 index 546754a..0000000 --- a/content/server/10.15/modules/classic_ui/pages/pim/sync_ios.adoc +++ /dev/null @@ -1,44 +0,0 @@ -= iOS - Synchronize iPhone/iPad -:toc: right - -== Calendar - -1. Open the settings application. -2. Select menu:Mail[Contacts > Calendars]. -3. Select btn:[Add Account]. -4. Select btn:[Other] as account type. -5. Select btn:[Add CalDAV] account. -6. For server, type `example.com/remote.php/dav/principals/users/USERNAME/` -7. Enter your username and password. -8. Select Next. -9. If your server does not support SSL, a warning will be displayed. Select btn:[Continue]. -10. If the iPhone is unable to verify the account information perform the following steps: -* Select btn:[OK]. -* Select btn:[Advanced Settings]. -* If your server does not support SSL, make sure Use SSL is set to OFF. -* Change port to 80. -* Go back to account information and click btn:[Save]. - -Your calendar will now be visible in the Calendar application - -== Address book - -1. Open the settings application. -2. Select menu:Mail[Contacts > Calendars]. -3. Select btn:[Add Account]. -4. Select Other as account type. -5. Select btn:[Add CardDAV] account. -6. For server, type `example.com/remote.php/dav/principals/users/USERNAME/` -7. Enter your username and password. -8. Select Next. -9. If your server does not support SSL, a warning will be displayed. Select btn:[Continue]. -10. If the iPhone is unable to verify the account information perform the following: -* Select btn:[OK]. -* Select advanced settings. -* If your server does not support SSL, make sure Use SSL is set to OFF. -* Change port to 80. -* Go back to account information and click btn:[Save]. - -Now should now find your contacts in the address book of your iPhone. -If it’s still not working, have a look at the -xref:{latest-server-version}@server:admin_manual:configuration/general_topics/general_troubleshooting.adoc#troubleshooting-contacts-calendar[Troubleshooting Contacts & Calendar] guides. diff --git a/content/server/10.15/modules/classic_ui/pages/pim/sync_kde.adoc b/content/server/10.15/modules/classic_ui/pages/pim/sync_kde.adoc deleted file mode 100644 index 6b5b67d..0000000 --- a/content/server/10.15/modules/classic_ui/pages/pim/sync_kde.adoc +++ /dev/null @@ -1,39 +0,0 @@ -= Synchronizing with KDE SC - -image:kdes1.png[image] - -From KDE SC 4.8 and forward setting up ownCloud is very easy. Note that -the KDE calendar needs to have the ownCloud Calendar and Contacts apps -enabled on the ownCloud server. You need both and not just the Calendar. -From System Settings Personal Information/Akonadi Resources -Configuration select DAV Groupware resource. - -image:kdes2.png[image] - -Enter your ownCloud username and password and click btn:[Next]. - -image:kdes3.png[image] - -Select ownCloud in the drop-down list and click btn:[Next]. - -image:kdes4.png[image] - -Enter the host name and installation path. If you do not use SSL remember to de-select "Use secure connection". - -image:kdes5.png[image] - -Test the connection. If everything went well you should see a message like the one below. - -image:kdes6.png[image] - -Click "Finish" and you will be able to change the display name and refresh interval. - -image:kdes7.png[image] - -Now you should see the Akonadi resource doing the first synchronization. - -You can find the Contacts and Calendars in Kontact (or KOrganizer/KAddressbook if you run the programs separately.) - -image:kdes9.png[image] - -image:kdes.png[image] diff --git a/content/server/10.15/modules/classic_ui/pages/pim/sync_osx.adoc b/content/server/10.15/modules/classic_ui/pages/pim/sync_osx.adoc deleted file mode 100644 index 492ad8a..0000000 --- a/content/server/10.15/modules/classic_ui/pages/pim/sync_osx.adoc +++ /dev/null @@ -1,48 +0,0 @@ -= Synchronizing with OS X - -To use ownCloud with iCal you will need to use the following URL: - -[source,plaintext] ----- -https://example.com/remote.php/dav/principals/users/USERNAME/ ----- - -The setup is basically the same as with iOS using the path -`\https://example.com/remote.php/dav/principals/users/USERNAME/` to sync -with ownCloud. For OS X 10.7 Lion and 10.8 Mountain Lion everything -works fine, but OS X 10.6 (Snow Leopard) and older needs some fiddling -to work. A user contributed the following: - -. Make sure, addressbook is not running. If it is, select the windows and press kbd:[Command+Q] to terminate it. -. Navigate to menu:Users[YOUR_USERNAME > Library > Application Support > AddressBook > Sources]. -If you already have some kind of addressbook setup, it is likely you -will see some folders named like this -*BEA92826-FBF3-4E53-B5C6-ED7C2B454430*. Note down what folders there are -now and leave the window open. -. Open addressbook and try to add a new CardDav addressbook. At this point, it does not matter -what information you enter. It will come up with the same error message you mentioned -before when you click btn:[Create]. Ignore it and click btn:[Create] again. -A non-functional addressbook will be added. -. Close addressbook again using kbd:[Command+Q] -. Go back to the folder window from step 2. You will now see a newly created folder with another -long string as its name. -. Navigate to the newly created folder and edit the *Configuration.plist* -with your favorite text editor. -. Search for a section looking like this: -+ ----- -servername https://:0(null) username Whatever_you_entered_before ----- - -. Make it look like this. Please note that the :443 after -*example.com* is important: -+ ----- -servernamehttps://example.com:443/owncloud/remote.php/dav/principals/users/USERNAME usernameusername ----- -. Save the file and open addressbook again. It will not work yet. -. Open the preferences for your ownCloud CardDAV-Account and enter your password. -. You may have to restart addressbook once more. After this, it should work. - -If it’s still not working, have a look at the -xref:{latest-server-version}@server:admin_manual:configuration/general_topics/general_troubleshooting.adoc#troubleshooting-contacts-calendar[Troubleshooting Contacts & Calendar] guides. diff --git a/content/server/10.15/modules/classic_ui/pages/pim/sync_thunderbird.adoc b/content/server/10.15/modules/classic_ui/pages/pim/sync_thunderbird.adoc deleted file mode 100644 index 3b70697..0000000 --- a/content/server/10.15/modules/classic_ui/pages/pim/sync_thunderbird.adoc +++ /dev/null @@ -1,48 +0,0 @@ -= Thunderbird - Synchronize Addressbook - -As someone who is new to ownCloud, new to SoGo Connector, and new to -Thunderbird Addressbook, here is what you need in excruciating pithy -detail to make this work (for all the other lost souls out there): - -1. https://www.thunderbird.net/en-US/[Thunderbird] for your OS -unless it comes with your OS distribution (Linux) -2. https://www.sogo.nu/download.html#/frontends[Sogo Connector] (latest release) - -With an installed Thunderbird mail tool, an installed SoGo Connector add-on: - -1. Thunderbird Addressbook is in the Thunderbird "Tools" Menu -2. In the Thunderbird Addressbook application: -* menu:File[New > Remote Addressbook] (SoGo Connector added this) -* "**Name:**" is the name you want to give your Addressbook in the Thunderbird addressbook bar area -* "**URL:**" is found in your ownCloud Contacts area, click the little btn:[gear symbol] - -image:contact_thunderbird-Symbol_Gear.jpg[image] - -in the -bottom left- of the Contacts View (same symbol as found in the --top right- in the Calendar view). Then look for a little impeller symbol - -image:contact_thunderbird-Symbol_Impeller.jpg[image] - -which will display the URL you need for your installation to work. - -image:contact_thunderbird-URL_config.jpg[image] - -Once installed, synchronize (right-click on your newly made remote -address book and select btn:[Synchronize]). You’ll see your address book -populate from ownCloud! **Don’t** click btn:[read only] above unless you don’t -want to modify your ownCloud server addressbook, like it contains a -listing of corporate contacts and is shared with lots of people, and you -don’t want a new user dragging it somewhere unintended. - -The rest of the details of dealing with Thunderbird addressbook are left -to the reader… First thing I learned is dragging a contact to a -different addressbook is a move operation. If you are worried about -losing the contact, save it to a VCF file using ownCloud (Or LDIF using -Thunderbird Addressbook) first! Like dragging from the ownCloud Addressbook -to the Personal Address Book removes the contact from -ownCloud Classic (_deleting it from all the other synchronized -installations_) and puts it in your Local Machine -only-Address Book. So -be careful or you’ll have unintended consequences where you might have -intended a copy operation. - -Contact Pictures are also sync'ed! diff --git a/content/server/10.15/modules/classic_ui/pages/session_management.adoc b/content/server/10.15/modules/classic_ui/pages/session_management.adoc deleted file mode 100644 index 2c6fb63..0000000 --- a/content/server/10.15/modules/classic_ui/pages/session_management.adoc +++ /dev/null @@ -1,34 +0,0 @@ -= Session Management -:toc: right -:description: The personal settings page allows you to have an overview of the connected browsers and clients. - -== Introduction - -{description} It is accessed by selecting the menu:Settings[Personal > Security]. - -== Sessions - -image:session_management/sessions.png[Managing sessions in ownCloud] - -The sessions list shows which browsers and clients were recently, and are actively connected to your ownCloud installation. -You can use the trash icon, at the far right-hand side of any session, to terminate it. - -*Please Be Aware of Two Things* - -. If you want to lock out a user, you need to change their password *before* you terminate their session. -. The currently logged-in user cannot terminate their own session from the sessions list. - -== App Passwords - -image:session_management/app_passwords.png[Managing app passwords and tokens in ownCloud] - -Underneath the "_App passwords / tokens_" list is a button to create a new app or device-specific username and password. -The username will be pre-filled to the currently logged-in user, and a random password will be generated. -You can change both of these, if so desired. -When you're happy with the username and password, click the btn:[done] button. -You can use the trash icon, at the far right-hand side of any password, to delete it - - -IMPORTANT: Once the password / token is created, *it cannot be changed*; it can only be deleted. - -TIP: We recommend that you generate tokens for every device you want to connect to your ownCloud instance, as this will allow you to disconnect connections individually, if necessary. diff --git a/content/server/10.15/modules/classic_ui/pages/troubleshooting.adoc b/content/server/10.15/modules/classic_ui/pages/troubleshooting.adoc deleted file mode 100644 index 99a12c4..0000000 --- a/content/server/10.15/modules/classic_ui/pages/troubleshooting.adoc +++ /dev/null @@ -1,46 +0,0 @@ -= Troubleshooting -:toc: right -:description: Listed here are the most common errors you may encounter while attempting to upload files, along with what they mean and possible workarounds. - -== Introduction - -{description} - -== Error while copying file to target location (copied bytes: xxx, expected filesize: yyy) - -This error is most likely due to an issue with the target storage -location. During file uploads the file data is read from PHP input and -copied into a part file on the target storage. - -If the target storage is not local (e.g.: FTP) and that storage is slow, not available, or broken -it is likely that the operation will fail either at the beginning, or in -the middle of the copy. Other reasons for this message can be that, when -writing to external storage, the connection took too long to respond or -the network connection was flaky. - -== Sharing sidebar does not show `Shared with you by …` for remote shares - -In some scenarios, when users share folders and files with each other -they cannot be scanned. There are a variety of reasons why this happens, -which can include firewalls and broken servers. - -In these situations, when the initial scan did not complete successfully, the mount point -cannot appear in the ownCloud web UI. This is because ownCloud was not -able to generate a matching file cache entry, nor retrieve any metadata -about whether it’s a folder or file (mime type), etc. - -== PIM Troubleshooting - -BlackBerry OS up to 10.2.2102 does not accept a URL with protocol -`https://` in front of the server address. It will always tell you that -it cannot login on your server. So instead of writing: - ----- -https://example.com/remote.php/dav/principals/users/USERNAME/ ----- - -in the server address field, you have to write: - ----- -example.com/remote.php/dav/principals/users/USERNAME/ ----- diff --git a/content/server/10.15/modules/classic_ui/pages/webinterface.adoc b/content/server/10.15/modules/classic_ui/pages/webinterface.adoc deleted file mode 100644 index 9322f20..0000000 --- a/content/server/10.15/modules/classic_ui/pages/webinterface.adoc +++ /dev/null @@ -1,72 +0,0 @@ -= The Web Interface -:description: You can connect to your ownCloud server using any Web browser; just point it to your ownCloud server and enter your username and password. Supported Web browsers are: - -== Introduction - -{description} - -* Edge (current version on Windows 10) -* IE11 or newer (except Compatibility Mode) -* Firefox 60 ESR or newer -* Chrome 66 or newer -* Safari 10 or newer -+ -image:oc_connect.jpg[ownCloud login screen, width=50%] - -NOTE: Some apps like `files_external` or `encryption` will disable the *Stay logged in* checkbox. - -== Navigating the Main User Interface - -By default, the ownCloud Web interface opens to your Files page. You can -add, remove, share files and make changes based on the access -privileges set by you (if you are administering the server) or by your -server administrator. - -image:files_page.png[scale="75%", "The main Files view."] - -NOTE: The file size values differ depending on the client you are using. Some operating systems like iOS and macOS use the decimal system (power of 10) where 1kB or one kilobyte consists of 1000 bytes, while Linux, Android and Windows use the binary system (power of 2) where 1KB consists of 1024 bytes and is called a kibibyte. So no reason to worry if you see different file sizes in ownCloud Web and your mobile device. - - -The ownCloud user interface contains the following fields and functions: - -* *Apps Selection Menu*: Located in the upper left corner, click the -arrow to open a dropdown menu to navigate to your various available -apps. -* *Apps Information Field*: Located in the left sidebar, this provides -filters and tasks associated with your selected app. For example, when -you are using the Files apps you have a special set of filters for -quickly finding your files, such as files that have been shared with -you, and files that you have shared with others. You’ll see different -items for other apps. -* *Application View*: The main central field in the ownCloud user -interface. This field displays the contents or user features of your -selected app. -* *Navigation Bar*: Located over the main viewing window (the -Application View), this bar provides a type of breadcrumbs navigation -that enables you to migrate to higher levels of the folder hierarchy up -to the root level (home). -* *New Button*: Located in the Navigation Bar, the btn:[New] button enables -you to create new files, new folders, or upload files. - -NOTE: You can also drag and drop files from your file manager into the ownCloud Files Application View to upload them to ownCloud. Currently, the only Web browsers that support drag-and-drop folders are Chrome and Chromium. - -* *Search Field*: Click on the btn:[magnifier] in the upper right-hand corner -of to search for files. -* *Personal Settings Menu*: Click on your ownCloud btn:[username], located to -the right of the Search field, to open your Personal Settings dropdown -menu. Your Personal page provides the following settings and features: -** Links to download desktop and mobile apps -** Re-run the First Run Wizard -** Server usage and space availability -** Password management -** Name, email, and profile picture settings -** Manage connected browsers and devices -** Group memberships -** Interface language settings -** Manage notifications -** Federated Cloud ID -** Social media sharing buttons -** SSL certificate manager -** ownCloud Version information - -See userpreferences section to learn more about these settings. diff --git a/content/server/10.15/modules/classic_ui/partials/configuration/files/encryption/not-encrypted-files.adoc b/content/server/10.15/modules/classic_ui/partials/configuration/files/encryption/not-encrypted-files.adoc deleted file mode 100644 index 0b9e5c1..0000000 --- a/content/server/10.15/modules/classic_ui/partials/configuration/files/encryption/not-encrypted-files.adoc +++ /dev/null @@ -1,25 +0,0 @@ -== Which Data Is Encrypted and When - -=== The following data *is* encrypted: - -* Users' _files_ in their home directory trees _if enabled_ by the admin. + -Location: `data//files`, see the: xref:{latest-server-version}@server:admin_manual:configuration/server/occ_command.adoc#encryption[occ encryption command set] -* External storage _if enabled_ either by the user or by the admin - -=== The following is *never* encrypted: - -* File names or folder structures -* Existing files in the trash bin -* Existing files in Versions -* Image thumbnails -* Previews from the Files app -* The search index from the full text search app -* Third-party app data - -Note that there may be other not mentioned files that are not encrypted. - -=== When are files encrypted - -If not otherwise decided by the admin, only new and changed files after enabling encryption are encrypted. - -NOTE: An admin can encrypt existing files post enabling encryption via an xref:{latest-server-version}@server:admin_manual:configuration/server/occ_command.adoc#encryption[occ encryption command]. diff --git a/content/server/10.15/modules/classic_ui/partials/configuration/user/update-password-note.adoc b/content/server/10.15/modules/classic_ui/partials/configuration/user/update-password-note.adoc deleted file mode 100644 index 39cd34a..0000000 --- a/content/server/10.15/modules/classic_ui/partials/configuration/user/update-password-note.adoc +++ /dev/null @@ -1 +0,0 @@ -NOTE: Password changes automatically log out *all* connected browsers/devices. diff --git a/content/server/10.15/modules/classic_ui/partials/nav.adoc b/content/server/10.15/modules/classic_ui/partials/nav.adoc deleted file mode 100644 index 75337bd..0000000 --- a/content/server/10.15/modules/classic_ui/partials/nav.adoc +++ /dev/null @@ -1,47 +0,0 @@ -// note that the module reference post xref is now a mandatory element -* ownCloud Classic UI -** xref:classic_ui:index.adoc[Introduction] -** xref:classic_ui:files/webgui/overview.adoc[The WebUI] -*** xref:classic_ui:webinterface.adoc[Web Interface] -*** xref:classic_ui:files/webgui/navigating.adoc[Navigating the WebUI] -*** xref:classic_ui:personal_settings/index.adoc[Personal Settings] -**** xref:classic_ui:personal_settings/general.adoc[General] -**** xref:classic_ui:personal_settings/storage.adoc[Storage] -**** xref:classic_ui:personal_settings/sharing.adoc[Sharing] -**** xref:classic_ui:personal_settings/security.adoc[Security] -**** xref:classic_ui:personal_settings/custom_groups.adoc[Custom Groups] -*** xref:classic_ui:files/index.adoc[Files] -**** xref:classic_ui:files/access_webdav.adoc[Access WebDAV] -**** xref:classic_ui:files/webgui/sharing.adoc[Sharing Files] -**** xref:classic_ui:files/webgui/search.adoc[Search & Full Text Search] -**** xref:classic_ui:files/webgui/tagging.adoc[Tagging Files] -**** xref:classic_ui:files/webgui/comments.adoc[Comments] -**** xref:classic_ui:files/version_control.adoc[Version Control] -**** xref:classic_ui:files/encrypting_files.adoc[Encrypting Files] -**** xref:classic_ui:files/deleted_file_management.adoc[Managing Deleted Files] -**** xref:classic_ui:files/large_file_upload.adoc[Large File Uploads] -**** xref:classic_ui:files/manual_file_locking.adoc[Manual File Locking] -**** xref:classic_ui:files/files_lifecycle.adoc[File Lifecycle Management] -*** xref:classic_ui:files/public_link_shares.adoc[Public Link Shares] -*** xref:classic_ui:files/federated_cloud_sharing.adoc[Federated Cloud Sharing] -*** xref:classic_ui:session_management.adoc[Managing Connected Browsers and Devices] -*** xref:classic_ui:online_collaboration.adoc[Online Collaboration] -*** xref:classic_ui:files/webgui/quota.adoc[Storage Quotas] -*** xref:classic_ui:external_storage/external_storage.adoc[External Storage] -*** xref:classic_ui:external_storage/sharepoint_connecting.adoc[Connecting to SharePoint] -*** xref:classic_ui:files/desktop_mobile_sync.adoc[Desktop Mobile Sync] -** xref:classic_ui:apps/index.adoc[Apps] -*** xref:classic_ui:apps/activity.adoc[Activity] -*** xref:classic_ui:apps/calendar.adoc[Calendar] -*** xref:classic_ui:apps/contacts.adoc[Contacts] -*** xref:classic_ui:apps/market.adoc[Market] -*** xref:classic_ui:apps/media_viewer_app.adoc[Media Viewer App] -** xref:classic_ui:integration/index.adoc[Integration] -*** xref:classic_ui:integration/ms-teams.adoc[Microsoft Teams] -** xref:classic_ui:pim/index.adoc[Synchronization Clients] -*** xref:classic_ui:pim/sync_ios.adoc[Sync iOS] -*** xref:classic_ui:pim/sync_kde.adoc[Sync KDE] -*** xref:classic_ui:pim/sync_osx.adoc[Sync OSX] -*** xref:classic_ui:pim/sync_thunderbird.adoc[Sync Thunderbird] -** xref:classic_ui:troubleshooting.adoc[Troubleshooting] -** xref:classic_ui:found_a_mistake.adoc[Found a Mistake?] diff --git a/content/server/10.15/modules/classic_ui/partials/section_page.adoc b/content/server/10.15/modules/classic_ui/partials/section_page.adoc deleted file mode 100644 index f764675..0000000 --- a/content/server/10.15/modules/classic_ui/partials/section_page.adoc +++ /dev/null @@ -1,3 +0,0 @@ -= {section-title} - -In this section you will find all the details you need {section-preamble-ender}. diff --git a/content/server/10.15/modules/developer_manual/attachments/.gitkeep b/content/server/10.15/modules/developer_manual/attachments/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/content/server/10.15/modules/developer_manual/attachments/core/Makefile.example b/content/server/10.15/modules/developer_manual/attachments/core/Makefile.example deleted file mode 100644 index d911c1c..0000000 --- a/content/server/10.15/modules/developer_manual/attachments/core/Makefile.example +++ /dev/null @@ -1,149 +0,0 @@ -SHELL := /usr/bin/env bash - -COMPOSER_BIN := $(shell command -v composer 2> /dev/null) -ifndef COMPOSER_BIN - $(error composer is not available on your system, please install composer) -endif - -# directories -app_name=$(notdir $(CURDIR)) -build_dir=$(CURDIR)/build -dist_dir=$(build_dir)/dist -doc_files=README.md LICENSE -src_dirs=appinfo css img js l10n lib templates -all_src=$(src_dirs) $(doc_files) - -acceptance_test_deps=vendor-bin/behat/vendor - -# bin file definitions -PHPUNIT=php -d zend.enable_gc=0 "$(PWD)/../../lib/composer/bin/phpunit" -PHPUNITDBG=phpdbg -qrr -d memory_limit=4096M -d zend.enable_gc=0 "$(PWD)/../../lib/composer/bin/phpunit" -PHP_CS_FIXER=php -d zend.enable_gc=0 vendor-bin/owncloud-codestyle/vendor/bin/php-cs-fixer -PHP_CODESNIFFER=vendor-bin/php_codesniffer/vendor/bin/phpcs -PHAN=php -d zend.enable_gc=0 vendor-bin/phan/vendor/bin/phan -PHPSTAN=php -d zend.enable_gc=0 vendor-bin/phpstan/vendor/bin/phpstan -BEHAT_BIN=vendor-bin/behat/vendor/bin/behat - -# start with displaying help -.DEFAULT_GOAL := help - -help: - @fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//' | sed -e 's/ */ /' | column -t -s : - -.PHONY: clean -clean: clean-composer-deps - -.PHONY: clean-composer-deps -clean-composer-deps: - rm -Rf vendor-bin/**/vendor vendor-bin/**/composer.lock - -##--------------------- -## Build targets -##--------------------- - -.PHONY: dist -dist: ## Build distribution -dist: distdir package - -.PHONY: distdir -distdir: - rm -rf $(build_dir) - mkdir -p $(dist_dir)/$(app_name) - cp -R $(all_src) $(dist_dir)/$(app_name) - -.PHONY: package -package: - tar -czf $(dist_dir)/$(app_name).tar.gz -C $(dist_dir) $(app_name) - -##--------------------- -## Tests -##--------------------- - -.PHONY: test-php-unit -test-php-unit: ## Run php unit tests -test-php-unit: ../../lib/composer/bin/phpunit - $(PHPUNIT) --configuration ./phpunit.xml --testsuite unit - -.PHONY: test-php-unit-dbg -test-php-unit-dbg: ## Run php unit tests using phpdbg -test-php-unit-dbg: ../../lib/composer/bin/phpunit - $(PHPUNITDBG) --configuration ./phpunit.xml --testsuite unit - -.PHONY: test-php-style -test-php-style: ## Run php-cs-fixer and check owncloud code-style -test-php-style: vendor-bin/owncloud-codestyle/vendor vendor-bin/php_codesniffer/vendor - $(PHP_CS_FIXER) fix -v --diff --diff-format udiff --allow-risky yes --dry-run - $(PHP_CODESNIFFER) --runtime-set ignore_warnings_on_exit --standard=phpcs.xml tests/acceptance - -.PHONY: test-php-style-fix -test-php-style-fix: ## Run php-cs-fixer and fix code style issues -test-php-style-fix: vendor-bin/owncloud-codestyle/vendor - $(PHP_CS_FIXER) fix -v --diff --diff-format udiff --allow-risky yes - -.PHONY: test-php-phan -test-php-phan: ## Run phan -test-php-phan: vendor-bin/phan/vendor - $(PHAN) --config-file .phan/config.php --require-config-exists - -.PHONY: test-php-phpstan -test-php-phpstan: ## Run phpstan -test-php-phpstan: vendor-bin/phpstan/vendor - $(PHPSTAN) analyse --memory-limit=4G --configuration=./phpstan.neon --no-progress --level=5 appinfo lib - -.PHONY: test-acceptance-api -test-acceptance-api: ## Run API acceptance tests -test-acceptance-api: $(acceptance_test_deps) - BEHAT_BIN=$(BEHAT_BIN) ../../tests/acceptance/run.sh --remote --type api - -.PHONY: test-acceptance-cli -test-acceptance-cli: ## Run CLI acceptance tests -test-acceptance-cli: $(acceptance_test_deps) - BEHAT_BIN=$(BEHAT_BIN) ../../tests/acceptance/run.sh --remote --type cli - -.PHONY: test-acceptance-webui -test-acceptance-webui: ## Run webUI acceptance tests -test-acceptance-webui: $(acceptance_test_deps) - BEHAT_BIN=$(BEHAT_BIN) ../../tests/acceptance/run.sh --remote --type webUI - -# -# Dependency management -#---------------------- - -composer.lock: composer.json - @echo composer.lock is not up to date. - -vendor: composer.lock - composer install --no-dev - -vendor/bamarni/composer-bin-plugin: composer.lock - composer install - -vendor-bin/owncloud-codestyle/vendor: vendor/bamarni/composer-bin-plugin vendor-bin/owncloud-codestyle/composer.lock - composer bin owncloud-codestyle install --no-progress - -vendor-bin/owncloud-codestyle/composer.lock: vendor-bin/owncloud-codestyle/composer.json - @echo owncloud-codestyle composer.lock is not up to date. - -vendor-bin/php_codesniffer/vendor: vendor/bamarni/composer-bin-plugin vendor-bin/php_codesniffer/composer.lock - composer bin php_codesniffer install --no-progress - -vendor-bin/php_codesniffer/composer.lock: vendor-bin/php_codesniffer/composer.json - @echo php_codesniffer composer.lock is not up to date. - -vendor-bin/phan/vendor: vendor/bamarni/composer-bin-plugin vendor-bin/phan/composer.lock - composer bin phan install --no-progress - -vendor-bin/phan/composer.lock: vendor-bin/phan/composer.json - @echo phan composer.lock is not up to date. - -vendor-bin/phpstan/vendor: vendor/bamarni/composer-bin-plugin vendor-bin/phpstan/composer.lock - composer bin phpstan install --no-progress - -vendor-bin/phpstan/composer.lock: vendor-bin/phpstan/composer.json - @echo phpstan composer.lock is not up to date. - -vendor-bin/behat/vendor: vendor/bamarni/composer-bin-plugin vendor-bin/behat/composer.lock - composer bin behat install --no-progress - -vendor-bin/behat/composer.lock: vendor-bin/behat/composer.json - @echo behat composer.lock is not up to date. diff --git a/content/server/10.15/modules/developer_manual/examples/app/advanced/notifications/intro-notification.php b/content/server/10.15/modules/developer_manual/examples/app/advanced/notifications/intro-notification.php deleted file mode 100644 index f109a41..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/advanced/notifications/intro-notification.php +++ /dev/null @@ -1,34 +0,0 @@ -notificationManager->createNotification(); - -// Populate the notification object -$notification - ->setApp('customgroups') - ->setDateTime(new \DateTime()) - ->setObject( - 'customgroup', - $memberInfo['group_id'] - ) - ->setSubject( - 'changed_member_role', - [ - $user->getDisplayName(), - $groupInfo['display_name'], - $memberInfo['role'] - ] - ) - ->setMessage( - 'changed_member_role', - [ - $user->getDisplayName(), - $groupInfo['display_name'], - $memberInfo['role'] - ] - ) - ->setUser($targetUserId) - ->setLink($link); - -// Send the notification -$this->notificationManager->notify($notification); diff --git a/content/server/10.15/modules/developer_manual/examples/app/advanced/notifications/notification-with-object.php b/content/server/10.15/modules/developer_manual/examples/app/advanced/notifications/notification-with-object.php deleted file mode 100644 index 67fe457..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/advanced/notifications/notification-with-object.php +++ /dev/null @@ -1,34 +0,0 @@ -notificationManager->createNotification(); -$action = $notification->createAction(); -$action->setLabel(....) - ->setLink(...) -$notification->setApp('customgroups') - ->setDateTime(new \DateTime()) - ->setObject( - 'customgroup', - $memberInfo['group_id'] - ) - ->setSubject( - 'changed_member_role', - [ - $user->getDisplayName(), - $groupInfo['display_name'], - $memberInfo['role'] - ] - ) - ->setMessage( - 'changed_member_role', - [ - $user->getDisplayName(), - $groupInfo['display_name'], - $memberInfo['role'] - ] - ) - ->setUser($targetUserId) - ->setLink($link) - ->addAction($action); -$this->notificationManager->notify($notification); - diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/cron/SomeTask.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/cron/SomeTask.php deleted file mode 100644 index 6a88db1..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/cron/SomeTask.php +++ /dev/null @@ -1,15 +0,0 @@ -getContainer() - ->query('SomeService') - ->run(); - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/author-access-attributes.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/author-access-attributes.php deleted file mode 100644 index 69a833c..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/author-access-attributes.php +++ /dev/null @@ -1,15 +0,0 @@ -setId(3); -$author->getPhoneNumber() // null diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/author.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/author.php deleted file mode 100644 index 81274d2..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/author.php +++ /dev/null @@ -1,18 +0,0 @@ -addType('stars', 'integer'); - } -} - diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/authormapper.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/authormapper.php deleted file mode 100644 index 795013a..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/authormapper.php +++ /dev/null @@ -1,41 +0,0 @@ -findEntity($sql, [$id]); - } - - - public function findAll($limit=null, $offset=null) { - $sql = 'SELECT * FROM `*PREFIX*myapp_authors`'; - return $this->findEntities($sql, $limit, $offset); - } - - - public function authorNameCount($name) { - $sql = 'SELECT COUNT(*) AS `count` FROM `*PREFIX*myapp_authors` ' . - 'WHERE `name` = ?'; - $stmt = $this->execute($sql, [$name]); - - $row = $stmt->fetch(); - $stmt->closeCursor(); - return $row['count']; - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/create-migration-step.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/create-migration-step.php deleted file mode 100644 index 6f1b6dd..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/create-migration-step.php +++ /dev/null @@ -1,18 +0,0 @@ -db = $db; - } - - public function find($id) { - $sql = 'SELECT * FROM `*PREFIX*myapp_authors` WHERE `id` = ?'; - $stmt = $this->db->prepare($sql); - $stmt->bindParam(1, $id, \PDO::PARAM_INT); - $stmt->execute(); - $row = $stmt->fetch(); - $stmt->closeCursor(); - - return $row; - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/migrations.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/migrations.php deleted file mode 100644 index 0eb6d2d..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/migrations.php +++ /dev/null @@ -1,45 +0,0 @@ -prefix = $options['tablePrefix']; - - if (!$schema->hasTable("{$this->prefix}mytable")) { - $table = $schema->createTable("{$this->prefix}mytable"); - $table->addColumn('id', 'integer', [ - 'autoincrement' => true, - 'unsigned' => true, - 'notnull' => true, - 'length' => 11, - ]); - $table->addColumn('stringfield', 'string', [ - 'length' => 255, - 'notnull' => false, - ]); - $table->addColumn('intfield', 'integer', [ - 'unsigned' => true, - 'notnull' => true, - 'default' => 1, - ]); - $table->setPrimaryKey(['id']); - $table->addUniqueIndex(['stringfield'], 'mytable_index'); - } - } -} - diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/schema-migration-step.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/schema-migration-step.php deleted file mode 100644 index be553aa..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/schema-migration-step.php +++ /dev/null @@ -1,15 +0,0 @@ - - - *dbname* - true - false - utf8 - - *dbprefix*yourapp_items - - - id - integer - 0 - true - 1 - 4 - - - user - text - true - 64 - - - name - text - true - 100 - - - path - clob - true - - -
-
- diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/slug.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/slug.php deleted file mode 100644 index 5ff9c24..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/slug.php +++ /dev/null @@ -1,5 +0,0 @@ -setName('Some*thing'); -$author->slugify('name'); // Some-thing - diff --git a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/sql-migration-step.php b/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/sql-migration-step.php deleted file mode 100644 index 0a5a179..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/fundamentals/database/sql-migration-step.php +++ /dev/null @@ -1,20 +0,0 @@ -getMountProviderCollection()->getMountCache(); - -$mounts = $mountCache->getMountsForFileId($fileId); -$userWithAccessToFile = array_map(function(ICachedMountInfo $mount) { - return $mount->getUser(); -}, $mounts); - -$mounts = $mountCache->getMountsForFileId($fileId); -if (count($mounts) > 0) { - $node = $mounts[0]->getMountPointNode(); - $owner = $node->getOwner(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/app/storage-backend/OCA/MyStorageApp/AppInfo/Application.php b/content/server/10.15/modules/developer_manual/examples/app/storage-backend/OCA/MyStorageApp/AppInfo/Application.php deleted file mode 100644 index a467276..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/storage-backend/OCA/MyStorageApp/AppInfo/Application.php +++ /dev/null @@ -1,35 +0,0 @@ -getContainer(); - - // retrieve the backend service - $backendService = $container->getServer()->getStoragesBackendService(); - - // register this class as backend provider - $backendService->registerBackendProvider($this); - } - - /** - * Return a list of backends to register - */ - public function getBackends() { - $container = $this->getContainer(); - $backends = [ - $container->query('OCA\MyStorageApp\Backend\MyStorageBackend'), - ]; - return $backends; - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/app/storage-backend/appinfo/info.xml b/content/server/10.15/modules/developer_manual/examples/app/storage-backend/appinfo/info.xml deleted file mode 100644 index e6280bc..0000000 --- a/content/server/10.15/modules/developer_manual/examples/app/storage-backend/appinfo/info.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - mystorageapp - My storage app - ... - - - - ... - diff --git a/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/given-step.php b/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/given-step.php deleted file mode 100644 index ce54b19..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/given-step.php +++ /dev/null @@ -1,21 +0,0 @@ -/** - * @Given the administrator has changed the password of user :user to :password - * - * @param string $user - * @param string $password - * - * @return void - * @throws \Exception - */ -public function adminHasChangedPasswordOfUserTo( - $user, $password -) { - $this->adminChangesPasswordOfUserToUsingTheProvisioningApi( - $user, $password - ); - $this->theHTTPStatusCodeShouldBe( - 200, - "could not change password of user $user" - ); -} - diff --git a/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/then-step-with-actions.php b/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/then-step-with-actions.php deleted file mode 100644 index a3df3fe..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/then-step-with-actions.php +++ /dev/null @@ -1,19 +0,0 @@ -/** - * @Then /^as "([^"]*)" (file|folder|entry) "([^"]*)" should exist$/ - * - * @param string $user - * @param string $entry - * @param string $path - * - * @return void - * @throws \Exception - */ -public function asFileOrFolderShouldExist($user, $entry, $path) { - $path = $this->substituteInLineCodes($path); - $this->responseXmlObject = $this->listFolder($user, $path, 0); - PHPUnit\Framework\Assert::assertTrue( - $this->isEtagValid(), - "$entry '$path' expected to exist but not found" - ); -} - diff --git a/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/then-step.php b/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/then-step.php deleted file mode 100644 index f19df0e..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/then-step.php +++ /dev/null @@ -1,12 +0,0 @@ -/** - * @Then /^the groups returned by the API should include "([^"]*)"$/ - * - * @param string $group - * - * @return void - */ -public function theGroupsReturnedByTheApiShouldInclude($group) { - $respondedArray = $this->getArrayOfGroupsResponded($this->response); - PHPUnit\Framework\Assert::assertContains($group, $respondedArray); -} - diff --git a/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/when-step.php b/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/when-step.php deleted file mode 100644 index 5543dc0..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/acceptance-tests/when-step.php +++ /dev/null @@ -1,22 +0,0 @@ -/** - * @When the administrator changes the password of user :user to :password using the provisioning API - * - * @param string $user - * @param string $password - * - * @return void - * @throws \Exception - */ -public function adminChangesPasswordOfUserToUsingTheProvisioningApi( - $user, $password -) { - $this->response = UserHelper::editUser( - $this->getBaseUrl(), - $user, - 'password', - $password, - $this->getAdminUsername(), - $this->getAdminPassword() - ); -} - diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs-capabilities/list-capabilities-response.json b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs-capabilities/list-capabilities-response.json deleted file mode 100644 index 7f8ca7e..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs-capabilities/list-capabilities-response.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "ocs" : { - "data" : { - "capabilities" : { - "notifications" : { - "ocs-endpoints" : [ - "list", - "get", - "delete" - ] - }, - "files" : { - "blacklisted_files" : [ - ".htaccess" - ], - "bigfilechunking" : true, - "privateLinks" : true, - "privateLinksDetailsParam": true, - "undelete" : true, - "versioning" : true - }, - "checksums" : { - "preferredUploadType" : "SHA1", - "supportedTypes" : [ - "SHA1" - ] - }, - "files_sharing" : { - "default_permissions" : 31, - "user" : { - "send_mail" : false - }, - "federation" : { - "incoming" : true, - "outgoing" : true - }, - "resharing" : true, - "user_enumeration" : { - "enabled" : true, - "group_members_only" : false - }, - "api_enabled" : true, - "group_sharing" : true, - "share_with_group_members_only" : true, - "public" : { - "enabled" : true, - "password" : { - "enforced" : { - "read_only" : true, - "read_write" : true, - "upload_only" : true - }, - "enforced" : true - }, - "multiple" : true, - "social_share" : true, - "send_mail" : false, - "upload" : true, - "expire_date" : { - "enabled" : false - }, - "supports_upload_only" : true - } - }, - "dav" : { - "chunking" : "1.0" - }, - "core" : { - "webdav-root" : "remote.php/webdav", - "status" : { - "edition" : "Community", - "installed" : "true", - "needsDbUpgrade" : "false", - "versionstring" : "10.0.3", - "productname" : "ownCloud", - "maintenance" : "false", - "version" : "10.0.3.3" - }, - "pollinterval" : 30000 - } - } - } - }, - "meta": { - "itemsperpage": "", - "message": "OK", - "status": "ok", - "statuscode": 200, - "totalitems": "" - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-server-capabilities-response.json b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-server-capabilities-response.json deleted file mode 100644 index cf2b51f..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-server-capabilities-response.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "ocs": { - "data": { - "capabilities": { - "notifications": { - "ocs-endpoints": [ - "list", - "get", - "delete" - ] - } - } - } - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-server-capabilities-response.xml b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-server-capabilities-response.xml deleted file mode 100644 index 5f95184..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-server-capabilities-response.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - - - - list - get - delete - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-user-notifications-no-notifications-response.json b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-user-notifications-no-notifications-response.json deleted file mode 100644 index 05317fd..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-user-notifications-no-notifications-response.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "ocs": { - "meta": { - "status": "ok", - "statuscode": 200, - "message": null, - "totalitems": "", - "itemsperpage": "" - }, - "data": [] - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-user-notifications-response.json b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-user-notifications-response.json deleted file mode 100644 index f658857..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/notifications/get-user-notifications-response.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "ocs": { - "meta": { - "itemsperpage": "", - "message": "OK", - "status": "ok", - "statuscode": 200, - "totalitems": "" - }, - "data": [{ - "notification_id": 61, - "app": "files_sharing", - "user": "admin", - "datetime": "2004-02-12T15:19:21+00:00", - "object_type": "remote_share", - "object_id": "13", - "subject": "You received admin@localhost as a remote share from test", - "message": "", - "link": "http://localhost/index.php/apps/files_sharing/pending", - "actions": [{ - "label": "Accept", - "link": "http:\/\/localhost\/ocs\/v1.php\/apps\/files_sharing\/api\/v1\/remote_shares\/13", - "type": "POST", - "primary": true - }, { - "label": "Decline", - "link": "http:\/\/localhost\/ocs\/v1.php\/apps\/files_sharing\/api\/v1\/remote_shares\/13", - "type": "DELETE", - "primary": false - }] - }] - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/roles/responses/success.json b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/roles/responses/success.json deleted file mode 100644 index 8a40531..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/roles/responses/success.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "ocs": { - "meta": { - "status": "ok", - "statuscode": 100, - "message": "OK", - "totalitems": "", - "itemsperpage": "" - }, - "data": [ - { - "id": "core.viewer", - "displayName": "Download / View", - "context": { - "publicLinks": { - "displayDescription": "Recipients can view or download contents.", - "order": 10, - "resourceTypes": [ - "*" - ], - "permissions": { - "ownCloud": { - "read": true - } - } - } - } - }, - { - "id": "core.contributor", - "displayName": "Download / View / Upload", - "context": { - "publicLinks": { - "displayDescription": "Recipients can view, download and upload contents.", - "order": 20, - "resourceTypes": [ - "httpd/unix-directory" - ], - "permissions": { - "ownCloud": { - "create": true, - "read": true - } - } - } - } - }, - { - "id": "core.editor", - "displayName": "Download / View / Edit", - "context": { - "publicLinks": { - "displayDescription": "Recipients can view, download, edit, delete and upload contents.", - "order": 30, - "resourceTypes": [ - "httpd/unix-directory" - ], - "permissions": { - "ownCloud": { - "create": true, - "read": true, - "update": true, - "delete": true - } - } - } - } - }, - { - "id": "core.uploader", - "displayName": "Upload only (File Drop)", - "context": { - "publicLinks": { - "displayDescription": "Receive files from multiple recipients without revealing the contents of the folder.", - "order": 40, - "resourceTypes": [ - "httpd/unix-directory" - ], - "permissions": { - "ownCloud": { - "create": true - } - } - } - } - } - ] - } -} - diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/roles/responses/success.xml b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/roles/responses/success.xml deleted file mode 100644 index e6923c3..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/roles/responses/success.xml +++ /dev/null @@ -1,88 +0,0 @@ - - - - ok - 100 - OK - - - - - - core.viewer - Download / View - - - Recipients can view or download contents. - 10 - - * - - - - 1 - - - - - - - core.contributor - Download / View / Upload - - - Recipients can view, download and upload contents. - 20 - - httpd/unix-directory - - - - 1 - 1 - - - - - - - core.editor - Download / View / Edit - - - Recipients can view, download, edit, delete and upload contents. - 30 - - httpd/unix-directory - - - - 1 - 1 - 1 - 1 - - - - - - - core.uploader - Upload only (File Drop) - - - Receive files from multiple recipients without revealing the contents of the folder. - 40 - - httpd/unix-directory - - - - 1 - - - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-is-invalid.json b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-is-invalid.json deleted file mode 100644 index 165e20f..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-is-invalid.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "ocs": { - "meta": { - "status": "ok", - "statuscode": 100, - "message": "OK", - "totalitems": "", - "itemsperpage": "" - }, - "data": { - "result": false - } - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-is-valid.json b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-is-valid.json deleted file mode 100644 index bbee847..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-is-valid.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "ocs": { - "meta": { - "status": "ok", - "statuscode": 100, - "message": "OK", - "totalitems": "", - "itemsperpage": "" - }, - "data": { - "result": true - } - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-user-is-not-found.json b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-user-is-not-found.json deleted file mode 100644 index 4cbc1b3..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/json/totp-user-is-not-found.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "ocs": { - "meta": { - "status": "failure", - "statuscode": 404, - "message": "OK", - "totalitems": "", - "itemsperpage": "" - }, - "data": { - "result": false - } - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-is-invalid.xml b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-is-invalid.xml deleted file mode 100644 index c74bf89..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-is-invalid.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - ok - 100 - OK - - - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-is-valid.xml b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-is-valid.xml deleted file mode 100644 index 93e07b3..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-is-valid.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - ok - 100 - OK - - - - - 1 - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-user-is-not-found.xml b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-user-is-not-found.xml deleted file mode 100644 index f4efca4..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/totp-validation/responses/xml/totp-user-is-not-found.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - failure - 404 - OK - - - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/user-sync/successful-response.xml b/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/user-sync/successful-response.xml deleted file mode 100644 index 72c2089..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/apis/ocs/user-sync/successful-response.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - ok - 200 - - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/accept-pending-share.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/accept-pending-share.sh deleted file mode 100644 index fcb1a9f..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/accept-pending-share.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -base_uri={oc-examples-server-url} -API_PATH=ocs/v1.php/apps/files_sharing/api/v1 - -curl -X POST \ - --user {oc-examples-username}:{oc-examples-password} \ - "$base_uri/$API_PATH/shares/pending/" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/create-share.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/create-share.sh deleted file mode 100644 index 2f05cc5..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/create-share.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -base_uri={oc-examples-server-url} -API_PATH=ocs/v1.php/apps/files_sharing/api/v1/shares - -# Create a public link share of a single file with read permissions, named "paris photo" -curl --user {oc-examples-username}:{oc-examples-password} "$base_uri/$API_PATH" \ - --data 'path=/Photos/Paris.jpg&shareType=3&permissions=3&name=paris%20photo' - -# Create a public link share of a single file with read and write permissions, named "Notes" -curl --user {oc-examples-username}:{oc-examples-password} "$base_uri/$API_PATH" \ - --data 'path=/Documents/notes.txt&shareType=3&permissions=15&name=Notes' - -# Create a user share with read permissions, named "welcome.txt" that has read -# and share permissions set. -curl --silent --user {oc-examples-username}:{oc-examples-password} \ - "$base_uri/$API_PATH/" \ - --data 'path=/welcome.txt' \ - --data 'shareType=3' \ - --data 'name=welcome.txt' \ - --data 'attributes[0][scope]=ownCloud&attributes[0][key]=read&attributes[0][value]=true' diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/public_files/view_public_link.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/public_files/view_public_link.sh deleted file mode 100644 index 0cb9d85..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/public_files/view_public_link.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/env bash - -## -## Variable Declaration -## -API_PATH="/remote.php/dav/public-files/" -SERVER_URI="{oc-examples-server-url}" -REQUEST_BODY=$(cat < - - - - - - - - - -EOF -) - -curl "$SERVER_URI/$API_PATH" \ - -H 'Content-Type: application/xml; charset=UTF-8' \ - -H 'Depth: 1' \ - -X PROPFIND \ - --data-binary "$REQUEST_BODY" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/delete-file-from-trashbin.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/delete-file-from-trashbin.sh deleted file mode 100644 index 4e5987b..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/delete-file-from-trashbin.sh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -FILE_ID=11111 -USERNAME={oc-examples-username} -PASSWORD={oc-examples-password} -API_PATH="remote.php/dav/trash-bin/$USERNAME/$FILE_ID" -SERVER_URI="{oc-examples-server-url}" - -curl "$SERVER_URI/$API_PATH/" \ - -X DELETE \ - --user "$USERNAME:$PASSWORD" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/list-files-in-trashbin.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/list-files-in-trashbin.sh deleted file mode 100644 index a7a0274..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/list-files-in-trashbin.sh +++ /dev/null @@ -1,29 +0,0 @@ -#!/usr/bin/env bash - -## -## Variable Declaration -## -USERNAME={oc-examples-username} -PASSWORD={oc-examples-password} -API_PATH="remote.php/dav/trash-bin/" -SERVER_URI="{oc-examples-server-url}" -REQUEST_BODY=$(cat < - - - - - - - - - -EOF -) - -curl "$SERVER_URI/$API_PATH/" \ - -H 'Content-Type: application/xml; charset=UTF-8' \ - -H 'Depth: 1' \ - -X PROPFIND \ - --data-binary "$REQUEST_BODY" \ - --user "$USERNAME:$PASSWORD" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/restore-file-to-trashbin.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/restore-file-to-trashbin.sh deleted file mode 100644 index 028c45b..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/dav/trashbin_api/restore-file-to-trashbin.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -FILE_ID=11111 -USERNAME={oc-examples-username} -PASSWORD={oc-examples-password} -API_PATH="remote.php/dav/trash-bin/$USERNAME/$FILE_ID" -SERVER_URI="{oc-examples-server-url}" - -curl "$SERVER_URI/$API_PATH/" \ - -H 'Overwrite: F' \ - -H 'Destination: $SERVER_URI/remote.php/dav/files/$USERNAME/' \ - -X MOVE \ - --user "$USERNAME:$PASSWORD" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/decline-pending-share.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/decline-pending-share.sh deleted file mode 100755 index 39d8328..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/decline-pending-share.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -base_uri={oc-examples-server-url} -API_PATH=ocs/v1.php/apps/files_sharing/api/v1 - -curl -X DELETE \ - --user {oc-examples-username}:{oc-examples-password} \ - "$base_uri/$API_PATH/shares/pending/" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/delete-share.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/delete-share.sh deleted file mode 100644 index 64ed46e..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/delete-share.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -base_uri={oc-examples-server-url} -API_PATH=ocs/v1.php/apps/files_sharing/api/v1 - -curl --user {oc-examples-username}:{oc-examples-password} \ - "$base_uri/$API_PATH/shares/115470" \ - --request DELETE - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/get-share-info.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/get-share-info.sh deleted file mode 100644 index ad5cfb2..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/get-share-info.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -base_uri={oc-examples-server-url} -API_PATH=ocs/v1.php/apps/files_sharing/api/v1 - -curl --user {oc-examples-username}:{oc-examples-password} \ - "$base_uri/$API_PATH/shares/115464" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/list-share-details.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/list-share-details.sh deleted file mode 100644 index 5076ab7..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/list-share-details.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -base_uri={oc-examples-server-url} -API_PATH=ocs/v1.php/apps/files_sharing/api/v1 - -curl --user {oc-examples-username}:{oc-examples-password} \ - "$base_uri/$API_PATH/shares?path=/Photos/Paris.jpg&reshares=true" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notifications/get-server-capabilities.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notifications/get-server-capabilities.sh deleted file mode 100644 index 0ecf0ba..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notifications/get-server-capabilities.sh +++ /dev/null @@ -1,14 +0,0 @@ -#!/usr/bin/env bash - -USERNAME=admin -PASSWORD={oc-examples-password} -API_PATH="ocs/v2.php/cloud/capabilities" -SERVER_URI="{oc-examples-server-url}" - -# Get server capabilities in XML format -curl "$SERVER_URI/$API_PATH/" \ - --user "$USERNAME:$PASSWORD" - -# Get server capabilities in JSON format -curl "$SERVER_URI/$API_PATH?format=json" \ - --user "$USERNAME:$PASSWORD" | jq diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notifications/get-user-notifications.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notifications/get-user-notifications.sh deleted file mode 100644 index dedaa28..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notifications/get-user-notifications.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env bash - -USERNAME=admin -PASSWORD={oc-examples-password} -API_PATH="ocs/v2.php/apps/notifications/api/v1/notifications" -SERVER_URI="{oc-examples-server-url}" - -# Get response in XML format -curl "$SERVER_URI/$API_PATH/" \ - --user "$USERNAME:$PASSWORD" - -# Get response in JSON format -curl "$SERVER_URI/$API_PATH?format=json" \ - --user "$USERNAME:$PASSWORD" | jq - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notify-public-link-by-email.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notify-public-link-by-email.sh deleted file mode 100644 index 9341b16..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/notify-public-link-by-email.sh +++ /dev/null @@ -1,14 +0,0 @@ -#!/usr/bin/env bash - -USERNAME={oc-examples-username} -PASSWORD={oc-examples-password} -API_PATH="ocs/v1.php/apps/files_sharing/api/v1/notification/notify-public-link-by-email" -SERVER_URI="{oc-examples-server-url}" - -curl "$SERVER_URI/$API_PATH/" \ - -X POST \ - --data "recipients[]=user@example.com" \ - --data "link=$SERVER_URI/index.php/s/sfU97LuwePm5omD" \ - --data "personalNote=A personal note." \ - --user "$USERNAME:$PASSWORD" - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/user-sync.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/user-sync.sh deleted file mode 100644 index 30feb35..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/user-sync.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env bash - -## -## Variable Declaration -## -USERNAME={oc-examples-username} -PASSWORD={oc-examples-password} -API_PATH="ocs/v2.php/cloud/user-sync/" -SERVER_URI="{oc-examples-server-url}" - -curl "$SERVER_URI/$API_PATH/" \ - -H 'Content-Type: application/xml; charset=UTF-8' \ - -X POST \ - --user "$USERNAME:$PASSWORD" - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/validate-totp.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/validate-totp.sh deleted file mode 100644 index 0f923b2..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/ocs/validate-totp.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env bash - -USERNAME=admin -PASSWORD={oc-examples-password} -API_PATH="ocs/v1.php/apps/twofactor_totp/api/v1/validate//" -SERVER_URI="{oc-examples-server-url}" - -curl "$SERVER_URI/$API_PATH/" \ - --user "$USERNAME:$PASSWORD" diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/update-share.sh b/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/update-share.sh deleted file mode 100644 index 0894626..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/curl/update-share.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash - -## -## Variable Declaration -## -base_uri={oc-examples-server-url} -API_PATH=ocs/v1.php/apps/files_sharing/api/v1 - -curl --user {oc-examples-username}:{oc-examples-password} \ - "$base_uri/$API_PATH/shares/115470" \ - --request PUT \ - --data 'expireDate=2017-01-02&name=paris%20photo' - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/accept-pending-share.go b/content/server/10.15/modules/developer_manual/examples/core/scripts/go/accept-pending-share.go deleted file mode 100644 index b9e581c..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/accept-pending-share.go +++ /dev/null @@ -1,33 +0,0 @@ -package main - -import ( - "fmt" - "io/ioutil" - "log" - "net/http" - "os" -) - -func main() { - base_uri := "{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1" - username := "{oc-examples-username}" - passwd := "{oc-examples-password}" - - client := &http.Client{} - - req, err := http.NewRequest("POST", fmt.Sprintf("%s/%s", base_uri, "shares/pending/"), nil) - if err != nil { - log.Print(err) - os.Exit(1) - } - - req.SetBasicAuth(username, passwd) - - resp, err := client.Do(req) - if err != nil { - log.Fatal(err) - } - - bodyText, err := ioutil.ReadAll(resp.Body) - fmt.Println(string(bodyText)) -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/create-share.go b/content/server/10.15/modules/developer_manual/examples/core/scripts/go/create-share.go deleted file mode 100644 index 8fe578b..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/create-share.go +++ /dev/null @@ -1,43 +0,0 @@ -package main - -import ( - "fmt" - "io/ioutil" - "log" - "net/http" - "net/url" - "strconv" - "strings" -) - -func main() { - base_uri := "{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1" - username := "your.username" - passwd := "your.password" - - client := &http.Client{} - - // Set the form POST body - form := url.Values{} - form.Add("path", "/Photos/Paris.jpg") - form.Add("shareType", "3") - form.Add("permissions", "1") - - // Build the core request object - req, _ := http.NewRequest( - "POST", - fmt.Sprintf("%s/%s", base_uri, "shares"), - strings.NewReader(form.Encode()), - ) - req.Header.Add("Content-Type", "application/x-www-form-urlencoded") - req.Header.Add("Content-Length", strconv.Itoa(len(form.Encode()))) - req.SetBasicAuth(username, passwd) - - resp, err := client.Do(req) - if err != nil { - log.Fatal(err) - } - - bodyText, err := ioutil.ReadAll(resp.Body) - fmt.Println(string(bodyText)) -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/decline-pending-share.go b/content/server/10.15/modules/developer_manual/examples/core/scripts/go/decline-pending-share.go deleted file mode 100644 index b01dcbb..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/decline-pending-share.go +++ /dev/null @@ -1,33 +0,0 @@ -package main - -import ( - "fmt" - "io/ioutil" - "log" - "net/http" - "os" -) - -func main() { - base_uri := "{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1" - username := "admin" - passwd := "admin" - - client := &http.Client{} - - req, err := http.NewRequest("DELETE", fmt.Sprintf("%s/%s", base_uri, "shares/pending/"), nil) - if err != nil { - log.Print(err) - os.Exit(1) - } - - req.SetBasicAuth(username, passwd) - - resp, err := client.Do(req) - if err != nil { - log.Fatal(err) - } - - bodyText, err := ioutil.ReadAll(resp.Body) - fmt.Println(string(bodyText)) -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/delete-share.go b/content/server/10.15/modules/developer_manual/examples/core/scripts/go/delete-share.go deleted file mode 100644 index b5a3e2d..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/delete-share.go +++ /dev/null @@ -1,32 +0,0 @@ -package main - -import ( - "fmt" - "io/ioutil" - "log" - "net/http" -) - -func main() { - base_uri := "{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1" - username := "your.username" - passwd := "your.password" - - client := &http.Client{} - - // Build the core request object - req, _ := http.NewRequest( - "DELETE", - fmt.Sprintf("%s/%s", base_uri, "shares/115470"), - nil, - ) - req.SetBasicAuth(username, passwd) - - resp, err := client.Do(req) - if err != nil { - log.Fatal(err) - } - - bodyText, err := ioutil.ReadAll(resp.Body) - fmt.Println(string(bodyText)) -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/get-share-info.go b/content/server/10.15/modules/developer_manual/examples/core/scripts/go/get-share-info.go deleted file mode 100644 index 157dce6..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/get-share-info.go +++ /dev/null @@ -1,33 +0,0 @@ -package main - -import ( - "fmt" - "io/ioutil" - "log" - "net/http" - "os" -) - -func main() { - base_uri := "{oc-examples-server-url}ocs/v1.php/apps/files_sharing/api/v1" - username := "your.username" - passwd := "your.password" - - client := &http.Client{} - - req, err := http.NewRequest("GET", fmt.Sprintf("%s/%s", base_uri, "shares/115464"), nil) - if err != nil { - log.Print(err) - os.Exit(1) - } - - req.SetBasicAuth(username, passwd) - - resp, err := client.Do(req) - if err != nil { - log.Fatal(err) - } - - bodyText, err := ioutil.ReadAll(resp.Body) - fmt.Println(string(bodyText)) -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/list-share-details.go b/content/server/10.15/modules/developer_manual/examples/core/scripts/go/list-share-details.go deleted file mode 100644 index 92abbdd..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/list-share-details.go +++ /dev/null @@ -1,39 +0,0 @@ -package main - -import ( - "fmt" - "io/ioutil" - "log" - "net/http" - "os" -) - -func main() { - base_uri := "{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1" - username := "your.username" - passwd := "your.password" - - client := &http.Client{} - - req, err := http.NewRequest("GET", fmt.Sprintf("%s/%s", base_uri, "shares"), nil) - if err != nil { - log.Print(err) - os.Exit(1) - } - - // Add on some, relevant, query parameters - q := req.URL.Query() - q.Add("path", "/Photos/Paris.jpg") - q.Add("reshares", "true") - req.URL.RawQuery = q.Encode() - - req.SetBasicAuth(username, passwd) - - resp, err := client.Do(req) - if err != nil { - log.Fatal(err) - } - - bodyText, err := ioutil.ReadAll(resp.Body) - fmt.Println(string(bodyText)) -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/update-share.go b/content/server/10.15/modules/developer_manual/examples/core/scripts/go/update-share.go deleted file mode 100644 index f3ca1b6..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/go/update-share.go +++ /dev/null @@ -1,41 +0,0 @@ -package main - -import ( - "fmt" - "io/ioutil" - "log" - "net/http" - "net/url" - "strconv" - "strings" -) - -func main() { - base_uri := "{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1" - username := "your.username" - passwd := "your.password" - - client := &http.Client{} - - // Set the form POST body - form := url.Values{} - form.Add("expireDate", "2017-01-03") - - // Build the core request object - req, _ := http.NewRequest( - "PUT", - fmt.Sprintf("%s/%s", base_uri, "shares/115470"), - strings.NewReader(form.Encode()), - ) - req.Header.Add("Content-Type", "application/x-www-form-urlencoded") - req.Header.Add("Content-Length", strconv.Itoa(len(form.Encode()))) - req.SetBasicAuth(username, passwd) - - resp, err := client.Do(req) - if err != nil { - log.Fatal(err) - } - - bodyText, err := ioutil.ReadAll(resp.Body) - fmt.Println(string(bodyText)) -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/java/get-share-info.java b/content/server/10.15/modules/developer_manual/examples/core/scripts/java/get-share-info.java deleted file mode 100644 index 475dfb6..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/java/get-share-info.java +++ /dev/null @@ -1,40 +0,0 @@ -import okhttp3.Credentials; -import okhttp3.OkHttpClient; -import okhttp3.Request; -import okhttp3.Response; - -import java.io.IOException; - -public class GetShareInfo { - OkHttpClient client = new OkHttpClient(); - - String run(String url, String credentials) throws IOException { - Request request = new Request.Builder() - .url(url) - .header("Authorization", credentials) - .build(); - - try (Response response = client.newCall(request).execute()) { - if (response.isSuccessful()) { - String responseBody = (response.body().string() != null) ? response.body().string() : "empty"; - return "Request was successful. Response was: " + responseBody; - } - - } catch (IOException e) { - return "Request was not successful. Reason: " + e.toString(); - } - - return "Request was not successful."; - } - - public static void main(String[] args) throws IOException { - GetShareInfo info = new GetShareInfo(); - - String credentials = Credentials.basic("your.username", "your.password"); - String ownCloudDomain = "{oc-examples-server-url}"; - String url = ownCloudDomain + "/ocs/v1.php/apps/files_sharing/api/v1/shares/'"; - - String response = info.run(url, credentials); - System.out.println(response); - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/kotlin/get-share-info.kt b/content/server/10.15/modules/developer_manual/examples/core/scripts/kotlin/get-share-info.kt deleted file mode 100644 index 820048d..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/kotlin/get-share-info.kt +++ /dev/null @@ -1,30 +0,0 @@ -package main - -import okhttp3.Credentials -import okhttp3.OkHttpClient -import okhttp3.Request -import java.io.IOException - -fun main(args: Array) { - val ownCloudDomain = "{oc-examples-server-url}" - var client = OkHttpClient() - val credentials = Credentials.basic("your.username", "your.password"); - - var builder = Request.Builder() - .url("$ownCloudDomain/ocs/v1.php/apps/files_sharing/api/v1/shares/'") - .header("Authorization", credentials) - .build() - - try { - var response = client.newCall(builder).execute() - - when { - response.isSuccessful -> println( - "Request was successful. Response was: ${response.body()?.string()}" - ) - else -> println("Request was not successful.") - } - } catch (e: IOException) { - println("Request failed. Reason: ${e.toString()}") - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/accept-pending-share.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/accept-pending-share.php deleted file mode 100644 index 93d2f0b..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/accept-pending-share.php +++ /dev/null @@ -1,24 +0,0 @@ - '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/', -]); - -try { - $response = $client->request( - 'POST', - 'shares/pending/1', - [ - 'auth' => ['{oc-examples-username}', '{oc-examples-password}'], - 'debug' => true, - ] - ); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/create-share.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/create-share.php deleted file mode 100644 index c596583..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/create-share.php +++ /dev/null @@ -1,25 +0,0 @@ - '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/', -]); - -try { - $response = $client->post('shares', [ - 'auth' => ['your.username', 'your.password'], - 'debug' => true, - 'form_params' => [ - 'path' => 'Photos/Paris.jpg', - 'shareType' => 3, - 'permissions' => 1 - ] - ]); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/dav/public_files/view_public_link.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/dav/public_files/view_public_link.php deleted file mode 100644 index 588d7e0..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/dav/public_files/view_public_link.php +++ /dev/null @@ -1,23 +0,0 @@ - '{oc-examples-server-url}/remote.php/dav/', -]); - -$share_token = ''; - -try { - $response = $client->request('PROPFIND', "public-files/$\{share_token\}", [ - 'headers' => [ - 'Content-Type'=> 'text/xml', - ], - ]); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/decline-pending-share.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/decline-pending-share.php deleted file mode 100644 index 61d4b65..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/decline-pending-share.php +++ /dev/null @@ -1,24 +0,0 @@ - '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/', -]); - -try { - $response = $client->request( - 'DELETE', - 'shares/pending/', - [ - 'auth' => ['{oc-examples-username}', '{oc-examples-password}'], - 'debug' => true, - ] - ); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/delete-share.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/delete-share.php deleted file mode 100644 index 45fb23c..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/delete-share.php +++ /dev/null @@ -1,20 +0,0 @@ - '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/', -]); - -try { - $response = $client->delete('shares/115468', [ - 'auth' => ['your.username', 'your.password'], - 'debug' => true, - ]); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/get-share-info.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/get-share-info.php deleted file mode 100644 index a716fb8..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/get-share-info.php +++ /dev/null @@ -1,20 +0,0 @@ - '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/', -]); - -try { - $response = $client->get('shares/115464', [ - 'auth' => ['your.username', 'your.password'], - 'debug' => true, - ]); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/list-share-details.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/list-share-details.php deleted file mode 100644 index a9e50dc..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/list-share-details.php +++ /dev/null @@ -1,20 +0,0 @@ - '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/', -]); - -try { - $response = $client->get('shares?path=/Photos/Paris.jpg&reshares=true', [ - 'auth' => ['your.username', 'your.password'], - 'debug' => true, - ]); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/notify-public-link-by-email.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/notify-public-link-by-email.php deleted file mode 100644 index 8362eb4..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/notify-public-link-by-email.php +++ /dev/null @@ -1,32 +0,0 @@ - $basePath, -]); - -try { - $response = $client->post($requestPath, [ - 'auth' => [$username, $password], - 'form_params' => [ - 'recipients' => [ - 'user@example.com', - ], - 'link' => '{oc-examples-server-url}/index.php/s/sfU97LuwePm5omD', - 'personalNote' => 'A personal note.', - ] - ]); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} \ No newline at end of file diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/ocs/user-sync.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/ocs/user-sync.php deleted file mode 100644 index cbad023..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/ocs/user-sync.php +++ /dev/null @@ -1,26 +0,0 @@ - $basePath, -]); - -try { - $response = $client->post($requestPath, [ - 'auth' => [$username, $password], - 'debug' => true, - ]); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/update-share.php b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/update-share.php deleted file mode 100644 index 16e1eaa..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/update-share.php +++ /dev/null @@ -1,23 +0,0 @@ - '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/', -]); - -try { - $response = $client->put('shares/115470', [ - 'auth' => ['your.username', 'your.password'], - 'debug' => true, - 'form_params' => [ - 'expireDate' => '2017-01-01' - ] - ]); - print $response->getBody()->getContents(); -} catch (\GuzzleHttp\Exception\ClientException $e) { - print $e->getMessage(); -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/vendor/guzzlehttp/promises/.gitignore b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/vendor/guzzlehttp/promises/.gitignore deleted file mode 100644 index 83ec41e..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/vendor/guzzlehttp/promises/.gitignore +++ /dev/null @@ -1,11 +0,0 @@ -phpunit.xml -composer.phar -composer.lock -composer-test.lock -vendor/ -build/artifacts/ -artifacts/ -docs/_build -docs/*.pyc -.idea -.DS_STORE diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/vendor/guzzlehttp/psr7/.gitignore b/content/server/10.15/modules/developer_manual/examples/core/scripts/php/vendor/guzzlehttp/psr7/.gitignore deleted file mode 100644 index 83ec41e..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/php/vendor/guzzlehttp/psr7/.gitignore +++ /dev/null @@ -1,11 +0,0 @@ -phpunit.xml -composer.phar -composer.lock -composer-test.lock -vendor/ -build/artifacts/ -artifacts/ -docs/_build -docs/*.pyc -.idea -.DS_STORE diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/not-authorised-response.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/not-authorised-response.xml deleted file mode 100644 index 8bb9dc0..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/not-authorised-response.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - failure - 997 - Unauthorised - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/recipients/response-success.json b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/recipients/response-success.json deleted file mode 100644 index d49af01..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/recipients/response-success.json +++ /dev/null @@ -1,60 +0,0 @@ -{ - "ocs": { - "data": { - "exact": { - "groups": [], - "remotes": [], - "users": [ - { - "label": "admin", - "value": { - "shareType": 0, - "shareWith": "admin" - } - } - ] - }, - "groups": [ - { - "label": "group1", - "value": { - "shareType": 1, - "shareWith": "group1" - } - }, - { - "label": "group2", - "value": { - "shareType": 1, - "shareWith": "group2" - } - } - ], - "remotes": [], - "users": [ - { - "label": "user1", - "value": { - "shareType": 0, - "shareWith": "user1", - "shareWithAdditionalInfo": "user1@user1.com" - } - }, - { - "label": "user2", - "value": { - "shareType": 0, - "shareWith": "user2" - } - } - ] - }, - "meta": { - "itemsperpage": "", - "message": "OK", - "status": "ok", - "statuscode": 200, - "totalitems": "" - } - } -} \ No newline at end of file diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/recipients/response-success.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/recipients/response-success.xml deleted file mode 100644 index 2541aa6..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/recipients/response-success.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - - ok - 200 - OK - - - - - - - - - - 0 - admin - - - - - - - - - - - 0 - user1 - user1@user1.com - - - - - - 0 - user2 - - - - - - - - 1 - group1 - - - - - - 1 - group2 - - - - - - \ No newline at end of file diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/accept-pending-share-failure.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/accept-pending-share-failure.xml deleted file mode 100644 index f7cc748..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/accept-pending-share-failure.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - failure - 404 - Wrong share ID, share doesn't exist - - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/accept-pending-share-success.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/accept-pending-share-success.xml deleted file mode 100644 index 87a50d5..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/accept-pending-share-success.xml +++ /dev/null @@ -1,41 +0,0 @@ - - - - ok - 100 - - - - - - - 1 - 0 - testuser - test user - 19 - 1564484858 - - - - testuser - test user - 0 - /ownCloud Manual.pdf - file - application/pdf - shared::/ownCloud Manual.pdf - 3 - 97 - 97 - 6 - /ownCloud Manual.pdf - admin - admin - - 0 - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/create-share-failure.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/create-share-failure.xml deleted file mode 100644 index 3f5619d..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/create-share-failure.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - failure - 400 - unknown share type - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/create-share-success.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/create-share-success.xml deleted file mode 100644 index 8904a43..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/create-share-success.xml +++ /dev/null @@ -1,35 +0,0 @@ - - - - ok - 100 - - - - 115468 - 3 - auser - A User - 1 - 1481537775 - - - MMqyHrR0GTepo4B - auser - A User - /Photos/Paris.jpg - file - image/jpeg - home::auser - 993 - 3994486 - 3994486 - 3994485 - /Shared/Paris.jpg - - - https://your.owncloud.install.com/owncloud/index.php/s/MMqyHrR0GTepo4B - 0 - paris photo - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/delete-share-failure.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/delete-share-failure.xml deleted file mode 100644 index 4cfa779..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/delete-share-failure.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - failure - 404 - wrong share ID, share doesn't exist. - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/delete-share-success.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/delete-share-success.xml deleted file mode 100644 index 40d301d..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/delete-share-success.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - ok - 100 - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-all-shares-success-no-shares.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-all-shares-success-no-shares.xml deleted file mode 100644 index dbb6dcc..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-all-shares-success-no-shares.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - ok - 100 - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-share-info-failure.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-share-info-failure.xml deleted file mode 100644 index 4cfa779..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-share-info-failure.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - failure - 404 - wrong share ID, share doesn't exist. - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-share-info-success.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-share-info-success.xml deleted file mode 100644 index 4748303..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/get-share-info-success.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - ok - 100 - - - - - 115464 - 6 - auser - A User - 3 - 1481535991 - - - l5h8JYPb455oFkv - auser - A User - /ownCloud Manual.pdf - file - application/pdf - home::auser - 993 - 3994491 - 3994491 - 3994484 - - user@example.com - user@example.com - ownCloud Manual - 0 - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-failure.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-failure.xml deleted file mode 100644 index aa7bd05..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-failure.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - failure - 404 - wrong path, file/folder doesn't exist - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-success.json b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-success.json deleted file mode 100644 index 0fdc8fc..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-success.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "ocs": { - "meta": { - "status": "ok", - "statuscode": 100, - "message": null, - "totalitems": "", - "itemsperpage": "" - }, - "data": [ - { - "id": "1", - "share_type": 0, - "uid_owner": "testuser", - "displayname_owner": "test user", - "permissions": 19, - "stime": 1564484858, - "parent": null, - "expiration": null, - "token": null, - "uid_file_owner": "testuser", - "displayname_file_owner": "test user", - "state": 1, - "path": "/ownCloud Manual.pdf", - "item_type": "file", - "mimetype": "application/pdf", - "storage_id": "home::testuser", - "storage": 3, - "item_source": 97, - "file_source": 97, - "file_parent": 57, - "file_target": "/ownCloud Manual.pdf", - "share_with": "admin", - "share_with_displayname": "admin", - "share_with_additional_info": null, - "mail_send": 0, - "attributes": null - } - ] - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-success.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-success.xml deleted file mode 100644 index 77acc2c..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/list-share-details-success.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - ok - 100 - - - - - 115468 - 3 - auser - A User - 1 - 1481537775 - - - MMqyHrR0GTepo4B - auser - A User - /Photos/Paris.jpg - file - image/jpeg - home::auser - 993 - 3994486 - 3994486 - 3994485 - /Shared/Paris.jpg - - - https://your.owncloud.install.com/owncloud/index.php/s/MMqyHrR0GTepo4B - 0 - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/update-share-failure.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/update-share-failure.xml deleted file mode 100644 index 121bb1c..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/update-share-failure.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - failure - 400 - can't change permission for public link share - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/update-share-success.xml b/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/update-share-success.xml deleted file mode 100644 index 0fb9cad..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/responses/shares/update-share-success.xml +++ /dev/null @@ -1,35 +0,0 @@ - - - - ok - 100 - - - - 115470 - 3 - auser - A User - 1 - 1481552410 - - 2017-01-01 00:00:00 - 11CUiVe0l7iaIwM - auser - A User - /Photos/Paris.jpg - file - image/jpeg - home::auser - 993 - 3994486 - 3994486 - 3994485 - /Shared/Paris.jpg - - - https://your.owncloud.install.com/owncloud/index.php/s/11CUiVe0l7iaIwM - 0 - paris photo - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/accept-pending-share.rb b/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/accept-pending-share.rb deleted file mode 100644 index 138631f..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/accept-pending-share.rb +++ /dev/null @@ -1,14 +0,0 @@ -require 'net/http' -require 'uri' - -base_uri = '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/' -uri = URI(base_uri + "shares/pending/1") - -Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http| - req = Net::HTTP::Post.new uri - req.basic_auth '{oc-examples-username}', '{oc-examples-password}' - res = http.request req - - puts res.body -end - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/create-share.rb b/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/create-share.rb deleted file mode 100644 index 4366ab0..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/create-share.rb +++ /dev/null @@ -1,13 +0,0 @@ -require 'net/http' -require 'uri' - -base_uri = '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/' -uri = URI(base_uri + "shares") - -Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http| - req = Net::HTTP::Get.new uri - req.basic_auth 'your.username', 'your.password' - res = http.request req - - puts res.body -end diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/decline-pending-share.rb b/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/decline-pending-share.rb deleted file mode 100644 index 6259f4a..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/decline-pending-share.rb +++ /dev/null @@ -1,14 +0,0 @@ -require 'net/http' -require 'uri' - -base_uri = '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/' -uri = URI(base_uri + "shares/pending/") - -Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http| - req = Net::HTTP::Delete.new uri - req.basic_auth 'your.username', 'your.password' - res = http.request req - - puts res.body -end - diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/delete-share.rb b/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/delete-share.rb deleted file mode 100644 index 2b28b2a..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/delete-share.rb +++ /dev/null @@ -1,13 +0,0 @@ -require 'net/http' -require 'uri' - -base_uri = '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/' -uri = URI(base_uri + "shares/115468") - -Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http| - req = Net::HTTP::Delete.new uri - req.basic_auth 'your.username', 'your.password' - res = http.request req - - puts res.body -end diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/get-share-info.rb b/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/get-share-info.rb deleted file mode 100644 index 6547eb7..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/get-share-info.rb +++ /dev/null @@ -1,13 +0,0 @@ -require 'net/http' -require 'uri' - -base_uri = '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/' -uri = URI(base_uri + "shares/115464") - -Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http| - req = Net::HTTP::Get.new uri - req.basic_auth 'your.username', 'your.password' - res = http.request req - - puts res.body -end diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/list-share-details.rb b/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/list-share-details.rb deleted file mode 100644 index 182f494..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/list-share-details.rb +++ /dev/null @@ -1,13 +0,0 @@ -require 'net/http' -require 'uri' - -base_uri = '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/' -uri = URI(base_uri + "shares?path=/Photos/Paris.jpg&reshares=true") - -Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http| - req = Net::HTTP::Get.new uri - req.basic_auth 'your.username', 'your.password' - res = http.request req - - puts res.body -end diff --git a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/update-share.rb b/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/update-share.rb deleted file mode 100644 index ddeb579..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/scripts/ruby/update-share.rb +++ /dev/null @@ -1,14 +0,0 @@ -require 'net/http' -require 'uri' - -base_uri = '{oc-examples-server-url}/ocs/v1.php/apps/files_sharing/api/v1/' -uri = URI(base_uri + "shares/115470") - -Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http| - req = Net::HTTP::Put.new uri - req.basic_auth 'your.username', 'your.password' - req.set_form_data('expireDate' => '2017-01-03') - res = http.request req - - puts res.body -end diff --git a/content/server/10.15/modules/developer_manual/examples/core/unit-testing/MyClass.php b/content/server/10.15/modules/developer_manual/examples/core/unit-testing/MyClass.php deleted file mode 100644 index 1da041c..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/unit-testing/MyClass.php +++ /dev/null @@ -1,9 +0,0 @@ -myClass = new MyClass(); - } - - public function testAddTwo(){ - $this->assertEquals(5, $this->testMe->addTwo(3)); - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/files_versions/successful-response-which-contains-multiple-versions.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/files_versions/successful-response-which-contains-multiple-versions.xml deleted file mode 100644 index 7a87c3f..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/files_versions/successful-response-which-contains-multiple-versions.xml +++ /dev/null @@ -1,95 +0,0 @@ - - - - /remote.php/dav/meta/13/v/ - - - - - - - HTTP/1.1 200 OK - - - - /remote.php/dav/meta/13/v/1585557207 - - - Mon, 30 Mar 2020 08:33:27 GMT - 13313 - - "44daf1a8e9f196de0e8f8af3d5a7b6c6" - application/vnd.oasis.opendocument.text - - HTTP/1.1 200 OK - - - - - - - HTTP/1.1 404 Not Found - - - - /remote.php/dav/meta/13/v/1585557036 - - - Mon, 30 Mar 2020 08:30:36 GMT - 13055 - - "cee399c154e4e9191a664bf4e427be39" - application/vnd.oasis.opendocument.text - - HTTP/1.1 200 OK - - - - - - - HTTP/1.1 404 Not Found - - - - /remote.php/dav/meta/13/v/1585556860 - - - Mon, 30 Mar 2020 08:27:40 GMT - 13091 - - "03993a29446093772f771ce1f1aae555" - application/vnd.oasis.opendocument.text - - HTTP/1.1 200 OK - - - - - - - HTTP/1.1 404 Not Found - - - - /remote.php/dav/meta/13/v/1584946264 - - - Mon, 23 Mar 2020 06:51:04 GMT - 36227 - - "807a85ee203444f3a678137156590273" - application/vnd.oasis.opendocument.text - - HTTP/1.1 200 OK - - - - - - - HTTP/1.1 404 Not Found - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/files_versions/successful-response-which-contains-one-version.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/files_versions/successful-response-which-contains-one-version.xml deleted file mode 100644 index af3bb12..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/files_versions/successful-response-which-contains-one-version.xml +++ /dev/null @@ -1,15 +0,0 @@ - - - - /remote.php/dav/meta/44/v/ - - - - - - - HTTP/1.1 200 OK - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/list-custom-group-members.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/list-custom-group-members.xml deleted file mode 100644 index 712bd4e..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/list-custom-group-members.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/list-custom-groups.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/list-custom-groups.xml deleted file mode 100644 index f036a9f..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/list-custom-groups.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/rename-custom-group.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/rename-custom-group.xml deleted file mode 100644 index 5d0de15..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/request/rename-custom-group.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - test_group - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-group-members-successful-response.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-group-members-successful-response.xml deleted file mode 100644 index a3b4c77..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-group-members-successful-response.xml +++ /dev/null @@ -1,24 +0,0 @@ - - - - /remote.php/dav/customgroups/groups/testgroup2/ - - - - - HTTP/1.1 404 Not Found - - - - /remote.php/dav/customgroups/groups/testgroup2/admin - - - admin - - HTTP/1.1 200 OK - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-group-memberships-of-a-given-user-successful-response.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-group-memberships-of-a-given-user-successful-response.xml deleted file mode 100644 index fcdef59..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-group-memberships-of-a-given-user-successful-response.xml +++ /dev/null @@ -1,41 +0,0 @@ - - - - /remote.php/dav/customgroups/users/settermjd/ - - - - - - - - HTTP/1.1 200 OK - - - - /remote.php/dav/customgroups/users/settermjd/testgroup2/ - - - - - - - - HTTP/1.1 200 OK - - - - - - - - - - - HTTP/1.1 404 Not Found - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-missing-group-response.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-missing-group-response.xml deleted file mode 100644 index 991d196..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-missing-group-response.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - Sabre\DAV\Exception\NotFound - Group with uri "testgroup" not found - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-no-results-response.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-no-results-response.xml deleted file mode 100644 index 2cf118b..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-no-results-response.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - /remote.php/dav/customgroups/groups/ - - - - - - - - HTTP/1.1 200 OK - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-successful-response.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-successful-response.xml deleted file mode 100644 index 60fc1eb..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/group/response/list-groups-successful-response.xml +++ /dev/null @@ -1,41 +0,0 @@ - - - - /remote.php/dav/customgroups/groups/ - - - - - - - - HTTP/1.1 200 OK - - - - /remote.php/dav/customgroups/groups/testgroup/ - - - - - - - - HTTP/1.1 200 OK - - - - - - - - - - - HTTP/1.1 404 Not Found - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/meta-files-filter.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/meta-files-filter.xml deleted file mode 100644 index 7ec604a..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/meta-files-filter.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/response-failure.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/response-failure.xml deleted file mode 100644 index 2bfb84b..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/response-failure.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - Sabre\DAV\Exception\NotFound - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/response-success.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/response-success.xml deleted file mode 100644 index b0600cf..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/meta/response-success.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - /remote.php/dav/meta/7/ - - - /Photos/San Francisco.jpg - - HTTP/1.1 200 OK - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/public_files/response/listing-members-is-disabled.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/public_files/response/listing-members-is-disabled.xml deleted file mode 100644 index 38603f2..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/public_files/response/listing-members-is-disabled.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - Sabre\DAV\Exception\MethodNotAllowed - Listing members of this collection is disabled - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/public_files/response/public-link-is-available.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/public_files/response/public-link-is-available.xml deleted file mode 100644 index f6b36de..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/public_files/response/public-link-is-available.xml +++ /dev/null @@ -1,35 +0,0 @@ - - - - /remote.php/dav/public-files/GbgdLgcoqYv8RF5/ - - - - - - - HTTP/1.1 200 OK - - - - /remote.php/dav/public-files/GbgdLgcoqYv8RF5/welcome.txt - - - Mon, 30 Sep 2019 12:13:02 GMT - 0 - - "a28785e285ce0de0738676814705c4e1" - text/plain - - HTTP/1.1 200 OK - - - - - - - HTTP/1.1 404 Not Found - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/minimal_filter_files_report_request_body.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/minimal_filter_files_report_request_body.xml deleted file mode 100644 index 48adf88..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/minimal_filter_files_report_request_body.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - 1 - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/search_body_filtering_by_system_tag_ids.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/search_body_filtering_by_system_tag_ids.xml deleted file mode 100644 index 597ea85..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/search_body_filtering_by_system_tag_ids.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - 1 - 1 - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/search_body_requesting_all_properties.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/search_body_requesting_all_properties.xml deleted file mode 100644 index bcdefd3..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/filter_files/search_body_requesting_all_properties.xml +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - 1 - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/limit_number_of_results.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/limit_number_of_results.xml deleted file mode 100644 index cdb4230..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/limit_number_of_results.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - 100 - - 200 - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/minimal_request_body.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/minimal_request_body.xml deleted file mode 100644 index 766287b..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/minimal_request_body.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - web - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/search_body_with_properties.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/search_body_with_properties.xml deleted file mode 100644 index 0debe87..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/request/search_files/search_body_with_properties.xml +++ /dev/null @@ -1,24 +0,0 @@ - - - - - - - - - - - - - - - - - - - - site - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/common/failure/incorrect_payload_or_parse_failure.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/common/failure/incorrect_payload_or_parse_failure.xml deleted file mode 100644 index 3501c84..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/common/failure/incorrect_payload_or_parse_failure.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - Sabre\Xml\ParseException - This should never happen (famous last words) - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/common/failure/request_non_existent_property.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/common/failure/request_non_existent_property.xml deleted file mode 100644 index 1952a64..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/common/failure/request_non_existent_property.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - /remote.php/dav/files/admin/Test/Sub-test/Website%20Plan.md - - - 00000065oc21s4c9iej2 - 65 - RDNVW - 423 - admin - admin - Fri, 28 Jul 2017 05:51:07 GMT - "0286fcdabf5b4f5ef84788d86c37e245" - text/markdown - - HTTP/1.1 200 OK - - - - - - HTTP/1.1 404 Not Found - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/filter_files/success.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/filter_files/success.xml deleted file mode 100644 index c36d2ad..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/filter_files/success.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - /remote.php/dav/files/admin/welcome.txt - - - 28 - RDNVW - 163 - admin - admin - Mon, 05 Nov 2018 10:52:58 GMT - "91b08390250f5294390c4fc92b6b0138" - text/plain - - HTTP/1.1 200 OK - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/search_files/success/search_response.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/search_files/success/search_response.xml deleted file mode 100644 index 1cb09e2..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/search/response/search_files/success/search_response.xml +++ /dev/null @@ -1,25 +0,0 @@ - - - - /remote.php/dav/files/admin/Test/Sub-test/Site-Plan.md - - - 00000065oc21s4c9iej2 - - 65 - RDNVW - 423 - admin - admin - Fri, 28 Jul 2017 05:51:07 GMT - "0286fcdabf5b4f5ef84788d86c37e245" - text/markdown - - HTTP/1.1 200 OK - - - - diff --git a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/trashbin/list-files-in-trashbin-success-response.xml b/content/server/10.15/modules/developer_manual/examples/core/webdav_api/trashbin/list-files-in-trashbin-success-response.xml deleted file mode 100644 index f003c19..0000000 --- a/content/server/10.15/modules/developer_manual/examples/core/webdav_api/trashbin/list-files-in-trashbin-success-response.xml +++ /dev/null @@ -1,122 +0,0 @@ - - - - /remote.php/dav/trash-bin/admin/ - - - - - - - HTTP/1.1 200 OK - - - - - - - - - HTTP/1.1 404 Not Found - - - - /remote.php/dav/trash-bin/admin/255/ - - - Level 1 - Level 1 - Tue, 09 Jul 2019 08:26:38 GMT - - - - - HTTP/1.1 200 OK - - - - - - HTTP/1.1 404 Not Found - - - - /remote.php/dav/trash-bin/admin/255/256/ - - - Level 2 - Level 1/Level 2 - Tue, 09 Jul 2019 08:26:38 GMT - - - - - HTTP/1.1 200 OK - - - - - - HTTP/1.1 404 Not Found - - - - /remote.php/dav/trash-bin/admin/255/256/257/ - - - Level 3 - Level 1/Level 2/Level 3 - Tue, 09 Jul 2019 08:26:38 GMT - - - - - HTTP/1.1 200 OK - - - - - - HTTP/1.1 404 Not Found - - - - /remote.php/dav/trash-bin/admin/255/256/257/263 - - - test.txt - Level 1/Level 2/Level 3/test.txt - Tue, 09 Jul 2019 08:26:38 GMT - 34 - - - HTTP/1.1 200 OK - - - - /remote.php/dav/trash-bin/admin/123 - - - git-image-one.png - git-image-one.png - Tue, 09 Jul 2019 08:15:55 GMT - 1067792 - - - HTTP/1.1 200 OK - - - - /remote.php/dav/trash-bin/admin/119 - - - git-image-one.png - git-image-one.png - Tue, 09 Jul 2019 08:17:54 GMT - 1517914 - - - HTTP/1.1 200 OK - - - diff --git a/content/server/10.15/modules/developer_manual/examples/scripts/backport.sh b/content/server/10.15/modules/developer_manual/examples/scripts/backport.sh deleted file mode 100755 index 24bd954..0000000 --- a/content/server/10.15/modules/developer_manual/examples/scripts/backport.sh +++ /dev/null @@ -1,202 +0,0 @@ -#!/bin/bash -# version 2024.06.05 - -if ! [ -x "$(command -v jq)" ]; then - echo - echo 'Error: jq is not installed.' >&2 - echo 'Please install package "jq" before using this script' - echo - exit 1 -fi - -if ! [ -x "$(command -v curl)" ]; then - echo - echo 'Error: curl is not installed.' >&2 - echo 'Please install package "curl" before using this script' - echo - exit 1 -fi - -if [ "$#" -lt 2 ]; then - echo - echo "Illegal number of parameters" - echo " $0 " - echo " For example: $0 1234567 10.8" - echo - exit 1 -fi - -commit=$1 -targetBranch=$2 -sourceBranch=$(git rev-parse --abbrev-ref HEAD) - -# check if the target branch exists on remote to avoid backporting to a non existing remote branch -exists_in_remote=$(git ls-remote --heads origin ${targetBranch}) -if [ -z "${exists_in_remote}" ]; then - echo - echo "Branch ${targetBranch} does not exist on remote. Create it first. Exiting" - echo - exit 1 -fi - -# check if the target branch already exists locally -exists_in_local=$(git branch --list ${targetBranch}) -if [ -z "${exists_in_local}" ]; then - echo - echo "Branch ${targetBranch} does not exist locally. Make it available first. Exiting" - echo - exit 1 -fi - -# check if the given merge commit exists in the actual checked out branch -is_merged=$(git branch --contains $1 2>/dev/null | grep -oP '(?<=\*).*') -if [ -z "${is_merged}" ]; then - echo - echo "${commit} does not exist because:" - echo "- the PR has not been merged yet or" - echo "- your actual backporting base branch ${sourceBranch} is not pulled/rebased." - echo "Exiting" - echo - exit 1 -fi - -# get the PR number from the merge commit -# there can be a PR reference text in the commit like "fixes #1234". -# we only need to take the last line which is then the real PR # the commit belongs to -pullId=$(git log $1^! --oneline 2>/dev/null | tail -n 3 | grep -oP '(?<=#)[0-9]*' | tail -n 1) - -# get the repository from the given commit -# remove prefix and suffix from the full url returned -repository=$(git config --get remote.origin.url 2>/dev/null) -repository=${repository#"https://github.com/"} -repository=${repository%".git"} - -# get the list of commits in PR without any merge commit -# $1^ means the first parent of the merge commit (that is passed in as $1). -# because $1 is a "magically-generated" merge commit, it happily "jumps back" -# to the point on the main branch just before where the PR was merged. -# the commits from that point are exactly the list of individual -# commits in the original PR. -# --no-merges leaves out the merge commit itself, and we get just what we want -commitList=$(git log --no-merges --reverse --format=format:%h $1^..$1) - -# get the request reset time window from github in epoch -rateLimitReset=$(curl -iks https://api.github.com/users/zen 2>&1 | grep -im1 'X-Ratelimit-Reset:' | grep -o '[[:digit:]]*') - -# get the remaining requests in window from github -rateLimitRemaining=$(curl -iks https://api.github.com/users/zen 2>&1 | grep -im1 'X-Ratelimit-Remaining:' | grep -o '[[:digit:]]*') - -# time remaining in epoch -now=$(date +%s) -((remaining=rateLimitReset-now)) - -# time remaining in HMS -remaining=$(date -u -d @${remaining} +%H:%M:%S) - -# echo one time for a good rendering -echo - -# check if there are commits to cherry pick and list them if present -if [[ -z "${commitList}" ]]; then - echo "There are no commit(s) to cherry pick. Exiting" - echo - exit 1 -else - lineCount=$(echo "${commitList}" | grep '' | wc -l) - echo "${lineCount} commit(s) to be cherry picked:" - echo - echo "${commitList}" - echo -fi - -if [ ${rateLimitRemaining} -le 0 ]; then - # do not continue if there are no remaining github requests available - echo - echo "You do not have enough github requests available to backport" - echo "The current rate limit window resets in ${remaining}" - echo - exit 1 -else - # get the PR title, this is the only automated valid way to get the title - pullTitle=$(curl https://api.github.com/repos/"${repository}"/pulls/"${pullId}" 2>/dev/null | jq '.title' | sed 's/^.//' | sed 's/.$//') - # remove possible line breaks on any location in the string - pullTitle=${pullTitle//$'\n'/} -fi - -# build variables for later use -newBranch="${targetBranch}-${commit}-${pullId}" -message="[${targetBranch}] [PR ${pullId}] ${pullTitle}" - -# first check, if the source branch is clean and has no uncommitted changes -# in case this is true, checkout does not succeed and nothing needs to be done/switched -# xargs removes any possible leading and trailing whitespaces -is_source_branch_clean=$(git status --porcelain=v1 2>/dev/null | xargs) -if [[ ! -z "${is_source_branch_clean}" ]]; then - echo "Source branch ${sourceBranch} has probably uncommitted changes. Aborting." - echo - exit 1 -fi - -# exit the script if any statement returns a non-true return value -# means that all commands from now on must run successfully -set -e - -# fetch branches and/or tags from one or more other repositories, along with the -# objects necessary to complete their histories -git fetch -p --quiet - -# checkout and rebase the target branch -git checkout "${targetBranch}" --quiet - -# if everything is ok, then rebase the target branch -git pull --rebase --quiet - -# create a new branch based on the target branch -# the new branch name equals the new commit name -git checkout -b "${newBranch}" "${targetBranch}" - -echo - -# cherry pick all commits from commitList -lC=1 -echo "${commitList}" | while IFS= read -r line; do - # start cherry-picking - echo "Cherry picking commit ${lC}: ${line}" - - # check if the commit to be cherry picked is already in the branch - # this only works if the commit was cherry picked before! - # else it will just try and continue. - is_cherry_picked=$(git log --grep "${line}" 2>/dev/null) - if [[ ! -z "${is_cherry_picked}" ]]; then - echo - echo "Commit ${line} has already been cherry picked, abort backporting." - # go back to the base branch and delete the new branch with all its contents. - git checkout --quiet "${sourceBranch}" - git branch -D --quiet "${newBranch}" - echo - exit 1 - fi - - # pull this commit into the new branch - # --allow-empty is required if an empty commit is present like when when retriggering the CI. - # if you do not want to use a default conflict resolution to take theirs - # (help fix missing cherry picked commits or file renames) - #git cherry-pick --allow-empty ${line} > /dev/null - git cherry-pick --allow-empty -Xtheirs "${line}" > /dev/null - lC=$(( ${lC} + 1 )) -done - -echo -echo "Committing changes" -echo - -## rewrite the most recent commit message -## the first -m creates the PR headline text -## the second -m creates the PR message text -git commit --allow-empty --quiet --amend -m "${message}" -m "Backport of PR #${pullId}" - -echo "Pushing: ${message}" -echo - -git push --quiet -u origin "${newBranch}" -git checkout --quiet "${sourceBranch}" diff --git a/content/server/10.15/modules/developer_manual/examples/scripts/read-config.php b/content/server/10.15/modules/developer_manual/examples/scripts/read-config.php deleted file mode 100755 index f58a104..0000000 --- a/content/server/10.15/modules/developer_manual/examples/scripts/read-config.php +++ /dev/null @@ -1,103 +0,0 @@ -#!/usr/bin/php - & Martin Mattel - * @copyright Copyright (c) 2018, ownCloud GmbH - * @license AGPL-3.0 - * - * This code is free software: you can redistribute it and/or modify - * it under the terms of the GNU Affero General Public License, version 3, - * as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Affero General Public License for more details. - * - * You should have received a copy of the GNU Affero General Public License, version 3, - * along with this program. If not, see - * - */ - -/** - * Class SimpleConfigReader - * @package ConfigReader - */ -class SimpleConfigReader -{ - /** - * @var array - */ - private $config = []; - - /** - * String returned to the user. - * @var string - */ - private $output = ''; - - /** - * SimpleConfigReader constructor. - * @param string $config - */ - public function __construct($config = '') - { - $this->config = $config; - } - - /** - * Find a writable app directory path that is either defined by key 'apps_paths' - * or use the default owncloud_root/apps path if the key is not set - * - * @return string - * @throws \Exception - */ - function findPath($ocAppsPath) { - - // default path = /apps - if (!array_key_exists('apps_paths', $this->config)) { - $this->output = $ocAppsPath; - return $this->output; - } - - foreach ($this->config['apps_paths'] as $path) { - if ($path['writable'] == true && is_writable($path['path'])) { - $this->output = $path['path']; - return $this->output; - } - } - return "Key 'apps_paths' found, but no writable path defined or path found not writeable"; - } -} - -/* - * As per the PHP manual: The first argument $argv[0] is always the name that - * was used to run the script. So we need at least two to access the new app's - * name, as well as the running script's name. - * @see https://www.php.net/manual/en/reserved.variables.argv.php - */ -if (count($argv) != 2) { - echo "Command usage: read-config.php \n"; - echo "Please provide the path to the ownCloud directory. \n"; - exit(1); -} - -// create a realpath and remove trailing "/" from argument if present -$ocRoot = rtrim( (string) $argv[1], "/"); -$ownCloudConfigFile = sprintf("%s/config/config.php", $ocRoot); - -if (!realpath($ownCloudConfigFile)) { - // if path/file does not exist, return an error message - echo 'File not found: ' . $ownCloudConfigFile . PHP_EOL; -} else { - // return the path, identified by a leading "/" and no new line character at the end - require_once($ownCloudConfigFile); - $result = (new SimpleConfigReader($CONFIG))->findPath($ocRoot . '/apps'); - if (!strpos($result, '/')) { - // return an error string which does not start with a leading "/" - echo $result . PHP_EOL; - } else { - // return the path, identified by a leading "/" and no new line character at the end - echo $result; - } -} diff --git a/content/server/10.15/modules/developer_manual/examples/scripts/theme-bootstrap.sh b/content/server/10.15/modules/developer_manual/examples/scripts/theme-bootstrap.sh deleted file mode 100755 index 0ea2e17..0000000 --- a/content/server/10.15/modules/developer_manual/examples/scripts/theme-bootstrap.sh +++ /dev/null @@ -1,130 +0,0 @@ -#!/bin/bash -# theme-bootstrap.sh -# Invoke this script with two arguments, the new theme's name and the path to ownCloud root. -# Written by Dmitry Mayorov , Matthew Setter & Martin Mattel -# Copyright (c) ownCloud 2018. -set -e - -# Clone a copy of the ownCloud example theme -# It won't override an existing app directory of the same name. -function clone_example_theme -{ - local APP_NAME="$1" - local INSTALL_BASE_DIR="$2" - local MAINFILE=master.zip - local UNZIPDIR=/tmp - local MASTERNAME=theme-example-master - local DOWNLOAD_FILE=$UNZIPDIR/$MAINFILE - local THEME_ARCHIVE_URL=https://github.com/owncloud/theme-example/archive/master.zip - - # check if the app name already exists - if [ -d "$INSTALL_BASE_DIR/$APP_NAME" ] - then - echo "An app with name ('$INSTALL_BASE_DIR/$APP_NAME') already exists." - echo "Please remove or rename it before running this script again." - return 1 - fi; - - # delete an existing downloaded zip file - if [ -e "$DOWNLOAD_FILE" ] - then - rm "$DOWNLOAD_FILE" - fi - - echo "Downloading ownCloud example theme." - - # getting the example theme from git - if ! wget --output-document="$DOWNLOAD_FILE" --tries=3 --continue \ - --timeout=3 --dns-timeout=3 --connect-timeout=3 --read-timeout=3 \ - "$THEME_ARCHIVE_URL" >/dev/null 2>&1 - then - echo "Download error, exiting" - return 1 - fi - - # first test if unzip would error then extract - if unzip -t "$DOWNLOAD_FILE" >/dev/null 2>&1 - then - # unzip with overwriting existing files and directories and suppressed output - echo "Unzipping download" - unzip -oq "$DOWNLOAD_FILE" -d "$UNZIPDIR" - echo "Moving to target location" - mv "$UNZIPDIR/$MASTERNAME" "$INSTALL_BASE_DIR/$APP_NAME" - echo "Removing download" - rm "$DOWNLOAD_FILE" - else - echo "Cannot complete setup of the ownCloud example theme as it is corrupted." - return 1 - fi -} -E_BADARGS=85 - -# Remembers the directory where this script was called from -SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )" - -# Check if run as sudo (root), needed for sub script calling and changing file permissions -if (( $EUID != 0 )); then - echo "Please run this script with sudo or as root" - exit -fi - -# Check if enough parameters have been applied -if (( $# != 2 )) -then - echo "Not enough arguments provided." - echo "Usage: $( basename "$0" ) [new theme name] [owncloud root directory]" - exit $E_BADARGS -fi - -# Check if read-config.php file exists in the same directory -if [ ! -f $SCRIPT_DIR/read-config.php ] -then - echo "File read-config.php not found! Must be in the same dir as this script" - exit -fi - -# Check if php file is set to be executable, script will else not work -if [ ! -x $SCRIPT_DIR/read-config.php ] -then - echo "File read-config.php is not set executable" - exit -fi - -app_name="$1" -owncloud_root="$2" -apps=$(php "$SCRIPT_DIR/read-config.php" "$owncloud_root") - -# Check if the php script returned an error message. This is when the string does not start with / -if [[ ! $apps = '/'* ]] -then - echo $apps - echo "Script read-config.php returned no usable app path" - exit -fi - -if clone_example_theme "$app_name" "$apps" -then - # Remove the default signature, which will cause a code integrity violation - [ -f "$apps/$app_name/appinfo/signature.json" ] && rm "$apps/$app_name/appinfo/signature.json" - - # Replace the default theme id / theme name - echo "Updating theme id / theme name" - sed -i "s#theme-example<#$app_name<#" "$apps/$app_name/appinfo/info.xml" - - # Set the appropriate permissions - echo "Setting new theme file permissions" - chown -R www-data:www-data "$apps/$app_name" - - # Enable the new theme app - if [ -e "$owncloud_root/occ" ] - then - echo "Enabling new theme in ownCloud" - php "$owncloud_root/occ" app:enable "$app_name" - else - echo - echo "occ command not found, please enable the app manually" - fi - - echo - echo "Finished bootstrapping the new theme." -fi diff --git a/content/server/10.15/modules/developer_manual/images/app/app-tile-enterprise.jpg b/content/server/10.15/modules/developer_manual/images/app/app-tile-enterprise.jpg deleted file mode 100644 index 4b554b6..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/app/app-tile-enterprise.jpg and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/app/app-tile-verified.jpg b/content/server/10.15/modules/developer_manual/images/app/app-tile-verified.jpg deleted file mode 100644 index 23a7874..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/app/app-tile-verified.jpg and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/app/fundamentals/controllers/display-the-csrf-token.jpg b/content/server/10.15/modules/developer_manual/images/app/fundamentals/controllers/display-the-csrf-token.jpg deleted file mode 100755 index 83b8a19..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/app/fundamentals/controllers/display-the-csrf-token.jpg and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/core/theming/2_ow_login.png b/content/server/10.15/modules/developer_manual/images/core/theming/2_ow_login.png deleted file mode 100644 index afa4879..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/core/theming/2_ow_login.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/core/theming/3_cu_login.png b/content/server/10.15/modules/developer_manual/images/core/theming/3_cu_login.png deleted file mode 100644 index 103cc48..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/core/theming/3_cu_login.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/core/theming/4_oc_header.png b/content/server/10.15/modules/developer_manual/images/core/theming/4_oc_header.png deleted file mode 100644 index 172770d..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/core/theming/4_oc_header.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/core/theming/5_cu_header.png b/content/server/10.15/modules/developer_manual/images/core/theming/5_cu_header.png deleted file mode 100644 index 25cafda..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/core/theming/5_cu_header.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/add.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/add.png deleted file mode 100644 index 8ae17cf..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/add.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/caret-dark.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/caret-dark.png deleted file mode 100644 index 215af33..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/caret-dark.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/caret.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/caret.png deleted file mode 100644 index 7066b76..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/caret.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/checkmark-white.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/checkmark-white.png deleted file mode 100644 index 27f1720..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/checkmark-white.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/checkmark.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/checkmark.png deleted file mode 100644 index 8b4c8dd..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/checkmark.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/clock.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/clock.png deleted file mode 100644 index 5023cf4..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/clock.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/close.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/close.png deleted file mode 100644 index 096ffb5..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/close.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/confirm.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/confirm.png deleted file mode 100644 index 3021d4c..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/confirm.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/delete.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/delete.png deleted file mode 100644 index e891b37..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/delete.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/download.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/download.png deleted file mode 100644 index 1f8e1a4..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/download.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/history.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/history.png deleted file mode 100644 index ec2bbd0..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/history.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/info.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/info.png deleted file mode 100644 index 9ebfe9c..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/info.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/lock.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/lock.png deleted file mode 100644 index 2013eba..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/lock.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/logout.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/logout.png deleted file mode 100644 index 5b94147..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/logout.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/mail.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/mail.png deleted file mode 100644 index 6d06259..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/mail.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/more.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/more.png deleted file mode 100644 index 880d5dc..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/more.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/password.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/password.png deleted file mode 100644 index 3619fab..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/password.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/pause-big.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/pause-big.png deleted file mode 100644 index 054281c..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/pause-big.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/pause.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/pause.png deleted file mode 100644 index d4b865e..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/pause.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/play-add.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/play-add.png deleted file mode 100644 index ccf77d2..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/play-add.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/play-big.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/play-big.png deleted file mode 100644 index 7d4916c..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/play-big.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/play-next.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/play-next.png deleted file mode 100644 index 50cd91d..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/play-next.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/play-previous.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/play-previous.png deleted file mode 100644 index c380e96..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/play-previous.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/play.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/play.png deleted file mode 100644 index 7994424..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/play.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/public.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/public.png deleted file mode 100644 index 077bb75..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/public.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/rename.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/rename.png deleted file mode 100644 index 975bd2d..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/rename.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/search.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/search.png deleted file mode 100644 index 49b6175..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/search.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/settings.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/settings.png deleted file mode 100644 index f6eb6ce..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/settings.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/share.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/share.png deleted file mode 100644 index fdacbba..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/share.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/shared.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/shared.png deleted file mode 100644 index 83ec1a0..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/shared.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/sound-off.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/sound-off.png deleted file mode 100644 index 0457de8..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/sound-off.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/sound.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/sound.png deleted file mode 100644 index e849b4d..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/sound.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/star.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/star.png deleted file mode 100644 index 6a04282..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/star.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/starred.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/starred.png deleted file mode 100644 index 22e68c7..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/starred.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/toggle.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/toggle.png deleted file mode 100644 index 45f9407..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/toggle.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-e.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-e.png deleted file mode 100644 index 8abe23a..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-e.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-n.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-n.png deleted file mode 100644 index 0f37e95..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-n.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-s.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-s.png deleted file mode 100644 index 81f623e..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/triangle-s.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/upload-white.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/upload-white.png deleted file mode 100644 index a3b233e..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/upload-white.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/upload.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/upload.png deleted file mode 100644 index 22d1f69..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/upload.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/user.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/user.png deleted file mode 100644 index 5f2fddc..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/user.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-close.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/view-close.png deleted file mode 100644 index c21f6ee..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-close.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-next.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/view-next.png deleted file mode 100644 index 8a23452..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-next.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-pause.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/view-pause.png deleted file mode 100644 index 1de1fb4..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-pause.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-play.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/view-play.png deleted file mode 100644 index c506815..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-play.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-previous.png b/content/server/10.15/modules/developer_manual/images/img/7/actions/view-previous.png deleted file mode 100644 index 79dcb23..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/actions/view-previous.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/breadcrumb.png b/content/server/10.15/modules/developer_manual/images/img/7/breadcrumb.png deleted file mode 100644 index 5556920..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/breadcrumb.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/filetypes/folder.png b/content/server/10.15/modules/developer_manual/images/img/7/filetypes/folder.png deleted file mode 100644 index bffa01f..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/filetypes/folder.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/filetypes/text.png b/content/server/10.15/modules/developer_manual/images/img/7/filetypes/text.png deleted file mode 100644 index 73080fb..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/filetypes/text.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/loading-dark.png b/content/server/10.15/modules/developer_manual/images/img/7/loading-dark.png deleted file mode 100644 index b83534e..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/loading-dark.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/loading-small.png b/content/server/10.15/modules/developer_manual/images/img/7/loading-small.png deleted file mode 100644 index f749556..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/loading-small.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/loading.png b/content/server/10.15/modules/developer_manual/images/img/7/loading.png deleted file mode 100644 index c8d962c..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/loading.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/calendar-dark.png b/content/server/10.15/modules/developer_manual/images/img/7/places/calendar-dark.png deleted file mode 100644 index 39032bc..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/calendar-dark.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/contacts-dark.png b/content/server/10.15/modules/developer_manual/images/img/7/places/contacts-dark.png deleted file mode 100644 index ec60fb6..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/contacts-dark.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/file.png b/content/server/10.15/modules/developer_manual/images/img/7/places/file.png deleted file mode 100644 index ff179e9..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/file.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/files.png b/content/server/10.15/modules/developer_manual/images/img/7/places/files.png deleted file mode 100644 index 16c78ef..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/files.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/folder.png b/content/server/10.15/modules/developer_manual/images/img/7/places/folder.png deleted file mode 100644 index d8eb4cc..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/folder.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/home.png b/content/server/10.15/modules/developer_manual/images/img/7/places/home.png deleted file mode 100644 index 8905bd7..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/home.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/link.png b/content/server/10.15/modules/developer_manual/images/img/7/places/link.png deleted file mode 100644 index 7cf9711..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/link.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/music.png b/content/server/10.15/modules/developer_manual/images/img/7/places/music.png deleted file mode 100644 index 953a2c2..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/music.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/img/7/places/picture.png b/content/server/10.15/modules/developer_manual/images/img/7/places/picture.png deleted file mode 100644 index b60da3b..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/img/7/places/picture.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/android_library/1000000000000270000003A317117674.png b/content/server/10.15/modules/developer_manual/images/mobile_development/android_library/1000000000000270000003A317117674.png deleted file mode 100644 index 63b7771..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/android_library/1000000000000270000003A317117674.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E61DFDBF76.png b/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E61DFDBF76.png deleted file mode 100644 index a370961..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E61DFDBF76.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E637605044.png b/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E637605044.png deleted file mode 100644 index ebacd4b..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E637605044.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E7A7A01884.png b/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E7A7A01884.png deleted file mode 100644 index bdfc169..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E7A7A01884.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E8AB4C3306.png b/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E8AB4C3306.png deleted file mode 100644 index 96d9c8b..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001E8AB4C3306.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001ECB85120C2.png b/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001ECB85120C2.png deleted file mode 100644 index 2ce7120..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100000000000030C000001ECB85120C2.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/10000201000003430000020C65A3C5A7.png b/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/10000201000003430000020C65A3C5A7.png deleted file mode 100644 index e9f59ff..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/10000201000003430000020C65A3C5A7.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100002010000034700000211B6BE4A2B.png b/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100002010000034700000211B6BE4A2B.png deleted file mode 100644 index 5bfc4be..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/100002010000034700000211B6BE4A2B.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/10000201000003480000020EC688993D.png b/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/10000201000003480000020EC688993D.png deleted file mode 100644 index 24ec991..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/mobile_development/ios_library/10000201000003480000020EC688993D.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/images/triageworkflow.png b/content/server/10.15/modules/developer_manual/images/triageworkflow.png deleted file mode 100644 index b558ab6..0000000 Binary files a/content/server/10.15/modules/developer_manual/images/triageworkflow.png and /dev/null differ diff --git a/content/server/10.15/modules/developer_manual/notes_for_the_navigation_file_nav.txt b/content/server/10.15/modules/developer_manual/notes_for_the_navigation_file_nav.txt deleted file mode 100644 index f86388b..0000000 --- a/content/server/10.15/modules/developer_manual/notes_for_the_navigation_file_nav.txt +++ /dev/null @@ -1,13 +0,0 @@ -The navigation files have been relocated and are accessed differently now. - -The main nav.adoc file is in ROOT and includes all nav.adoc files from the modules. To do so, the modules nav.adoc files needed to be relocated from: - -{modulesdir}/nav.adoc -to -{modulesdir}/partials/nav.adoc - -This is due to the fact that "Antora does not classify files located at the root of the module or in the modules folder" which means, there is no access path to a nav.adoc file which is located in the root of a module. - -As a result, the antora.yml file only contains the main ROOT/nav.adoc file. - -This is beneficial, as we now can structure products and their content in a better way. diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/code_signing.adoc b/content/server/10.15/modules/developer_manual/pages/app/advanced/code_signing.adoc deleted file mode 100644 index 64fa065..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/code_signing.adoc +++ /dev/null @@ -1,179 +0,0 @@ -= Code Signing -:page-aliases: go/admin-code-integrity.adoc,go/developer-code-integrity.adoc - -ownCloud supports code signing for the core releases, and for ownCloud -applications. Code signing gives our users an additional layer of -security by ensuring that nobody other than authorized individuals can -push updates. - -It also ensures that all upgrades have been executed properly, so that -no files are left behind, and all old files are properly replaced. In -the past, invalid updates were a significant source of errors when -updating ownCloud. - -== FAQ - -=== Why Did ownCloud Add Code Signing? - -By supporting Code Signing we add another layer of security which -ensures that nobody, other than authorized individuals, can push updates -for applications. This ensures proper upgrades. - -=== Do We Lock Down ownCloud? - -The ownCloud project is open source and always will be. We do not want -to make it more difficult for our users to run ownCloud. Any code -signing errors on upgrades will not prevent ownCloud from running, but -will display a warning on the Admin page. For applications that are not -tagged `Official` the code signing process is optional. - -=== Is ownCloud Not Open Source Anymore? - -The ownCloud project is open source and always will be. The code signing -process is optional, though highly recommended. The code check for the -core parts of ownCloud is enabled when the ownCloud release version -branch has been set to stable. - -For custom distributions of ownCloud it is recommended to change the -release version branch in version.php to something else than `stable`. - -=== Is Code Signing Mandatory For Apps? - -If you intend to upload your app to the Marketplace, yes, code signing _is_ mandatory. -If the app will only be installed directly in an ownCloud installation, then code signing is _optional_, for all third-party applications. - -== Technical details - -ownCloud uses a X.509 based approach to handle authentication of code. -Each ownCloud release contains the certificate of a shipped ownCloud -Code Signing Root Authority. The private key of this certificate is only -accessible to the project leader, who may grant trusted project members -with a copy of this private key. - -This Root Authority is only used for signing certificate signing -requests (CSRs) for additional certificates. Certificates issued by the -Root Authority must always to be limited to a specific scope, usually -the application identifier. This enforcement is done using the `CN` -attribute of the certificate. - -Code signing is then done by creating a `signature.json` file with the -following content: - -*hashes*: This is an array of all files in the folder with their -corresponding SHA-512 hashes. - -*certificate*: This is the certificate used for signing. - -* It has to be issued by the ownCloud Root Authority -* Its CN needs to be permitted to perform the required action. - -*signature*: This is a signature of the hashes which can be verified -using the certificate. Having the certificate bundled within the -`signature.json` file has the advantage that even if a developer loses -their certificate, future updates can still be ensured by having a new -certificate issued. - -== How Code Signing Affects Apps in the ownCloud Marketplace - -* Unsigned apps can’t be uploaded to the marketplace. They can be -installed manually, but the warning: `"Integrity check failed"`, will -always be visible. -* Apps which have been signed in a previous release *MUST* be -code-signed in all future releases as well, otherwise the update will be -refused. - -== How to Get Your App Signed - -The following commands require that you have OpenSSL installed on your -machine. Ensure that you keep all generated files to sign your -application. The following examples will assume that you are trying to -sign an application named *`contacts`*. - -Firstly, generate a private key and CSR. This can be done with the -following command. - ----- -# Replace "contacts" with your application identifier. -openssl req -nodes -newkey rsa:4096 -keyout contacts.key -out contacts.csr -subj "/CN=contacts" ----- - -Then, post the CSR on https://github.com/owncloud/appstore-issues, and -configure your GitHub account to show your mail address in your profile. -ownCloud might ask you for further information to verify that you’re the -legitimate owner of the application. Make sure to keep the private key -file (`contacts.key`) secret and not disclose it to any third-parties. - -ownCloud will then provide you with the signed certificate. - -Finally, run `./occ integrity:sign-app` to sign your application, and -specify your private and the public key as well as the path to the -application. A valid example looks like: - ----- -./occ integrity:sign-app \ - --privateKey=/home/user/contacts.key \ - --certificate=/home/user/CA/contacts.crt \ - --path=/home/user/Programming/contacts ----- - -The occ tool will store a `signature.json` file within the `appinfo` -folder of your application. Then compress the application folder, naming -it `contacts.tar.gz`, and upload it to -{oc-marketplace-url}/. Be aware that making any changes to -the application, after it has been signed, requires it to be signed -again. So if you do not want to have some files shipped remove them -before running the signing command. - -In case you lose your certificate please submit a new CSR as described -above and mention that you have lost the previous one. ownCloud will -revoke the old certificate. - -If you maintain an app together with multiple people it is recommended -to designate a release manager responsible for the signing process as -well as the uploading to {oc-marketplace-url}/[marketplace]. -If case this is not feasible, and multiple certificates are required, -ownCloud can create them on a case by case basis. We do not recommend -developers to share their private key. - -== Errors - -The following errors can be encountered when trying to verify a code -signature. For information about how to get access to those results -please refer to -xref:admin_manual:configuration/general_topics/code_signing.adoc#fixing-invalid-code-integrity-messages[the -Issues section of the ownCloud Classic Administration manual]. - -`INVALID_HASH` - -* The file has a different hash than specified within `signature.json`. -This usually happens when the file has been modified after writing the -signature data. - -`FILE_MISSING` - -* The file cannot be found but has been specified within -`signature.json`. Either a required file has been left out, or -`signature.json` needs to be edited. - -`EXTRA_FILE` - -* The file does not exist in `signature.json`. This usually happens when -a file has been removed and `signature.json` has not been updated. - -`EXCEPTION` - -* Another exception has prevented the code verification. There are -currently these following exceptions: -** `Signature data not found.` -*** The app has mandatory code signing enforced but no `signature.json` -file has been found in its `appinfo` folder. -** `Certificate is not valid.` -*** The certificate has not been issued by the official ownCloud Code -Signing Root Authority. -** `Certificate is not valid for required scope. (Requested: %s, current: %s)` -*** The certificate is not valid for the defined application. -Certificates are only valid for the defined app identifier and cannot be -used for others. -** `Signature could not get verified.` -*** There was a problem with verifying the signature of -`signature.json`. diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/custom-cache-backend.adoc b/content/server/10.15/modules/developer_manual/pages/app/advanced/custom-cache-backend.adoc deleted file mode 100644 index ea306ce..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/custom-cache-backend.adoc +++ /dev/null @@ -1,259 +0,0 @@ -= Custom Filesystem Caches - -The metadata cache in ownCloud can be overridden by a storage class -backend which implements the following methods: - - -[width="100%",cols="47%,53%",options="header",] -|======================================================================= -| Method | Description -| `getCache($path = `, $storage = null)` -`getScanner($path = `, $storage = null)` -`getWatcher($path = `, $storage = null)` |For overwriting the cache -itself. For overwriting the meta data scanning behavior. For overwriting -the behavior of checking for external changes. -|======================================================================= - -It’s unlikely that an app will need to override any of the three -systems; as long as a storage backend behaves accordingly, the cache -systems will work on any storage backend. - -But, here are some cases where it may be practical to do so: - -* *Overriding the cache:* This may be helpful in the case of shared -storage. In this case, the overriding class should redirect any cache -operation to the cache of the user that owns the share. -* *Overriding the scanner:* This is useful in cases where it would -provide an efficient way to retrieve the metadata of a significant -number of files and folders. In doing so it avoids the need to perform a -large number of round-trip requests. -* *Overriding the watcher:* This could be useful for changing the -behavior for detecting changes made to a storage from outside ownCloud. - -However — in almost all cases — overriding the `hasUpdated()` method of -a storage provides sufficient flexibility. - -If any of these three systems need to be overridden, one of the -following classes should be sub-classed: - -* `\OC\Files\Cache\Cache` -* `\OC\Files\Cache\Scanner` -* `\OC\Files\Cache\Watcher` - -This class should then return the subclass from one of the three methods listed above. - -== Cache - -Instead of creating a full, custom, cache object, you can also use the same wrapper pattern as when creating xref:app/advanced/storage-backend.adoc#create-custom-storage-backends[custom storage backends]. -Cache wrappers should be implemented by overriding the `getCache()` method. -In addition, it may also be useful to override the following methods: - -[width="100%",cols="43%,57%",options="header",] -|======================================================================= -| Method | Description -| `get($file)` | Returns either xref:cache-entries[the cache entries] for a -file or folder or false if the file is not in the cache. - -| `getFolderContents($path)` | Returns the cache entries for all files and -folders in a folder or an empty array if the folder is not in the cache. - -| `getFolderContentsById($id)` | Same as `getFolderContents()`, but it -uses a file id instead of a path. - -| `put($file, $data)` | Saves a cache entry for a file. If the file is -already in the cache then `update()` is called automatically. - -| `update($id, $data)` | Updates an existing cache entry. Only the changed -values need to be provided in `$data`, any omitted values will remain -unchanged. - -| `getId($path)` | Retrieves the file id for a file or folder. A file id -is a numeric id for a file or folder that’s unique within an ownCloud -instance which stays the same for the lifetime of a file even through -renaming. - -| `getParentId($path)` | Retrieves the file id of the parent folder or -`=1` if the file has no parent, root, entry. - -| `inCache($file)` | Checks if a file is in the cache. - -| `remove($file)` | Removes a file or folder from the cache. In the case -of removing a folder, it should remove all child entries as well. - -| `move($source, $target)` | Renames a file or folder in the cache. In the -case of moving a folder, it should also move all child entries. - -| `moveFromCache($sourceCache, $sourcePath, $targetPath)` | Moves a file -or folder from a cache instance to a local path. - -| `clear()` | Removes all entries from the cache. - -| `getStatus($file)` | Retrieves the scanned status of a file or folder. - -| `search($pattern)` | Searches the cache for a file or folder where the -filename matches `$pattern`. SQL style wildcards are used in the -pattern. - -| `searchByMime($mimetype)` | Searches for a file or folder with a -matching mimetype. Both full mimetypes (`text/plain') and mimetype -groups (`text') should be supported as search option. - -| `correctFolderSize($path)` | Recalculates the size of a folder and all -parent folders. - -| `calculateFolderSize($path)` | Recalculates the size of a single folder. - -| `getAll()` | Retrieves the file id for all files and folder in the cache - -| `getIncomplete()` | Retrieve folders which have a status of -`Cache::SHALLOW`. - -| `getPathById($id)` | Retrieve the path of a file or folder whose file id -matches `$id`. Returns null if a match is not found. - -| static `getById($id)` | Retrieves the path and storage id for a file -whose file id matches `$id`. This is deprecated in favor of -`getPathById()`. -|======================================================================= - -=== Cache Entries - -A cache entry is an associative array that should contain, at least, the -following values: - -[width="100%",cols="18%,8%,74%",options="header",] -|======================================================================= -| Method | Type | Description -| `fileid` | int | The numeric id of a file (see `getId()`, above). - -| `storage` | int | The numeric id of the storage the file is stored on. - -| `path` | string | The path of the file within the storage (e.g., -`foo/bar.txt'). - -| `name` | string | The basename of a file or folder (’bar.txt). - -| `mimetype` | string | The full mimetype of the file (e.g., `text/plain'). - -| `mimepart` | string | The mimetype group (e.g., `text'). - -| `size` | int | The size of the file or folder in bytes. - -| `mtime` -| int -a| The last modified date of the file as a UNIX timestamp as shown in the UI. - -NOTE: ownCloud does not preserve directory mtimes (modification time), though it does update file mtimes. - -| `storage_mtime` | int | The last modified date of the file as a UNIX -timestamp as stored on the storage. -|======================================================================= - -Note that when a file is updated ownCloud also updates the modification -time of *all* parent folders. Doing so makes it visible to the user -exactly which folder has most recently been updated. However, ownCloud’s -modification time can differ from the mtime value on the underlying -storage. But, this usually only changes when a direct child is added, -removed, or renamed. - -[width="100%",cols="18%,8%,74%",options="header",] -|======================================================================= -| Method | Type | Description -| `etag` | string | An Etag is used to detect changes to files and folders. -An Etag of a _file_ changes whenever the content of the file changes. An -Etag of a _folder_ changes whenever a file _in_ the folder has changed. - -| `permissions` | int | The permissions for the file. These are stored as a -bitwise combination of `\OCP\PERMISSION_READ`, `\OCP\PERMISSION_CREATE`, -`\OCP\PERMISSION_UPDATE`, `\OCP\PERMISSION_DELETE`, and -`\OCP\PERMISSION_SHARE`. -|======================================================================= - -== CacheWrappers - -Just like storage wrappers, cache wrappers can be used to change the -behavior of an existing cache. ownCloud comes with two cache wrappers -which can be useful for applications; these are: - -* `\OC\Files\Cache\Wrapper\CacheJail` -* `\OC\Files\Cache\Wrapper\CachePermissionsMask` - -These serve the same purpose as the two similarly named storage -wrappers. Implementing a cache wrapper can be done by sub-classing -`\OC\Files\Cache\CacheWrapper`. Inside this class, the wrapped cache -will be available as `$this->cache`. - -Besides providing the options to override any method of the wrapped -cache, the cache wrapper also provides the convenience method -`formatCacheEntry($entry)`. This can be overridden to allow for easier -changes to any method that returns cache entries. - -== Scanner - -It might be useful to override the following methods of the scanner: - -[width="100%",cols="20%,80%",options="header",] -|======================================================================= -| Method | Description -| `getData($path)` | Retrieves all metadata of a path to put in the cache. -It returns an array which should contain the following keys: `mimetype`, -`mtime`, `size`, `etag`, -`storage_mtime\`, and`permissions`.`size`should always being`-1` for -folders. - -| `scanFile($file)` | Scans a single file, or scans a folder by passing -`self::SCAN_RECURSIVE` (or true) as the second parameter. When scanning -folders, the scanner should recurse into any sub-directory and the size -of any folder should be calculated correctly. If not, the scanner should -only scan the direct children of the folder. Any folder that’s not fully -scanned should have it’s size set to `-1`. - -| `backgroundScan()` | Should do a recursive scan on all folders which -have not previously been fully scanned. The size should be set to `-1`. -|======================================================================= - -== Watcher - -The watcher is responsible for checking for outside changes made to the -filesystem and updating the cache accordingly. As noted above, in most -cases overriding the `hasUpdated()` method of a storage backend -sub-class is sufficient. However, the following methods could be -overridden, if necessary: - -[width="100%",cols="22%,78%",options="header",] -|======================================================================= -| Method | Description -| `checkUpdate($path)` | Checks if a file or folder has been changed -externally. If so it updates the cache and return `true`, else return -`false`. - -| `cleanFolder($path)` | Checks a folder for any child entries that are no -longer in the storage. This should be called automatically by -`checkUpdate()` if that method detects an update. -|======================================================================= - -An app or admin can also change the watcher behavior by setting it’s -policy by calling `setPolicy($policy)`. This method can take the -following values: - -[width="100%",cols="27%,73%",options="header",] -|======================================================================= -| Method | Description -| `Watcher::CHECK_NEVER` | Don’t check for any external change. This is -recommended if you’re certain that no outside changes will be made. - -| `Watcher::CHECK_ONCE` | Check each path for updates at most once during -a request (default). - -| `Watcher::CHECK_ALWAYS` | Check for external changes any number of times -during a request. It is mostly useful for unit tests. -|======================================================================= - -== Updater - -Another cache related system, which developers should be aware of when -working with custom caches, is the updater. The updater -(`\OC\Files\Cache\Updater`) is responsible for updating the cache when -any change is made from inside ownCloud. It will call either the scanner -or the cache of a storage to make the required changes. The updater *can -not* be overwritten by storage backends. diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/custom-storage-backend.adoc b/content/server/10.15/modules/developer_manual/pages/app/advanced/custom-storage-backend.adoc deleted file mode 100644 index bb030e8..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/custom-storage-backend.adoc +++ /dev/null @@ -1,302 +0,0 @@ -= Create Custom Storage Backends - -== Introduction - -The preferred way for applications to create new storage backends is to -create a subclass of `\OC\Files\Storage\Common` and implement the -abstract methods. It’s also possible to create storage backends by -implementing the required interface. - -However, by sub-classing the common backend a lot of the boiler plate is -taken care of. What’s more, it provides common implementations and -fallbacks to reduce the amount of work it is to create a storage -backend. - -== Required Methods - -All storage backends sub-classing the common storage backend must -implement the following methods: - -[width="100%",cols="36%,64%",options="header",] -|======================================================================= -| Method | Description -| `mkdir($path)` | Creates a new folder on the storage. - -| `rmdir($path)` | Deletes an existing folder on the storage. - -| `opendir($path)` | Opens a directory handle. - -| `stat($path)` | Retrieves the metadata for the file or folder. The -returned array should, at least, contain `mtime` and `size`. - -| `filetype($path)` | Returns the file type; either `file` or `dir`. - -| `file_exists($path)` | Checks if a file or folder exists. - -| `unlink($path)` | Removes a file or folder. This isn’t only for deleting -files, unlike PHP’s unlink method. - -| `fopen($path, $mode)` | Opens a file handle for a file - -| `touch($path, $mtime = null)` | Updates the mtime of a file or folder. -If `$mtime` is omitted the current time should be used. -|======================================================================= - -== Suggested Methods - -The common storage backends provide fallback implementations for a -number of methods to make them easier to implement. However, some of -fallback implementations are either inefficient or don’t always provide -the correct result for custom storage backends. Given that, please -consider overriding one or more of the following methods: - -[width="100%",cols="39%,61%",options="header",] -|======================================================================= -| Method | Description -| `rename($sourcePath, $targetPath)` | Renames a file. The default -implementation uses `copy` and `unlink` which is very inefficient. - -| `copy($sourcePath, $targetPath)` | Copies a file. The default -implementation copies using streams. This is inefficient for remote -storages as it downloads and re-uploads the file. - -| `isReadable($path)` | Checks if a file is readable. It defaults to -`true` if the file exists. - -| `isUpdatable($path)` | Checks if a file or folder can be updated. This -includes being written to or renamed. It defaults to `true` if the file -exists. - -| `isCreatable($path)` | Checks if new files can be created in a folder It -defaults to `isUpdatable($path)`. - -| `isDeletable($path)` | Checks if a file can be deleted. It defaults to -`isUpdatable($path)`. - -| `isSharable($path)` | Checks if a file can be shared. It defaults to -`isReadable($path)`. - -| `free_space($path)` | Checks the free space on the storage in bits. -|======================================================================= - -== Other Useful Methods - -The default implementation for the following methods are good for most -storage backends. But, providing an alternate implementation _can_ -improve user experience. - -[width="100%",cols="40%,60%",options="header",] -|======================================================================= -| Method | Description -| `file_put_contents($path, $data)` | Stores a file on the storage. It -defaults to using `fopen($path, 'w')`. - -| `file_get_contents($path)` | Retrieves a file from storage. Defaults to -using `fopen($path, 'r')`. - -| `getMimeType($path)` | Retrieves the mimetype of a file or folder. -Defaults to guessing the mimetype from the extension. The mimetype of a -folder is _[required] to be `'httpd/unix-directory'`. - -| `hasUpdated($path, $time)` | Checks if a file or folder has been updated -since `$time`. If you’re certain the files on the storage will not be -updated outside of ownCloud you can always return `false` to increase -performance. - -| `getETag($path)` | Retrieves the -https://en.wikipedia.org/wiki/HTTP_ETag[Etag] for a file or folder. - -| `verifyPath($path, $fileName)` | Checks if a filename is valid for the -storage backend. It defaults to checking for invalid characters or names -for the server platform. -|======================================================================= - -== Copying and Moving Between Storage Backends - -When copying or moving files between different storages a stream copy is -used by default. This works well for copying between different types of -storages, such as from local to SMB. But, there are cases where a more -efficient copy is possible, such as between two SMB storages on the same -server. In these cases, storage backends can override the cross-storage -behavior by overriding the following methods: - -* `copyFromStorage(\OCP\Files\Storage $sourceStorage, $sourceInternalPath, $targetInternalPath, $preserveMtime = false);` -* `moveFromStorage(\OCP\Files\Storage $sourceStorage, $sourceInternalPath ,$targetInternalPath);` - -== Working With Streams - -Both `fopen()` and `opendir()` require storage backends to return native -PHP streams for maximum compatibility. ownCloud comes with several -classes which make it easier for storage backends to create native PHP -streams for backends not supported by PHP’s own -{php-net-url}/manual/en/class.streamwrapper.php[streamWrapper]. - -=== IteratorDirectory - -`Icewind\Streams\IteratorDirectory` allows for creating a directory -handle from an array or iterator. - -[source,php] ----- -$fileNames = $this->getFolderContentsSomehow(); -return IteratorDirectory::wrap($fileNames); ----- - -=== CallbackWrapper - -`Icewind\Streams\CallbackWrapper` wraps an existing file handle, and -allows for hooking into file reads and writes, and closing streams. The -most common use case for this class in storage backends is for -implementing `fopen()` with writable streams. This is because writing to -and closing streams happens outside the storage implementation. As a -result, the storage backend needs a way to upload the changed file back -to the backend. This can be done by attaching a close-callback to a -stream for a temporary file. - -[source,php] ----- -$tempFile = $this->downloadFile($path); -$handle = fopen($tempFile, $mode); -return CallBackWrapper::wrap($handle, null, null function() use ($path, $tempFile) { - $this->uploadFile($tempFile, $path); - unlink($tempFile); -} ----- - -== Storage Wrappers - -Besides implementing a complete custom storage backend, ownCloud allows -for modifying the behavior of an existing storage by applying a wrapper -to it. Storage wrappers need to implement the full storage API methods. -Examples of storage wrappers are - -* *The Quota wrapper.* This changes the behavior of free_space by -limiting the free space returned by the wrapped storage to a configured -maximum -* *The Encryption wrapper*. This encrypts and decrypts the data on the -fly by overwriting `file_put_contents`, `file_get_contents`, and -`fopen`. - -When implementing a storage wrapper, the wrapped storage is available as -`$this->storage`. Storage wrappers can either be applied globally to all -used storages using -`\OC\Files\Filesystem::addStorageWrapper($name, $wrapper)` or to a -specific storage, while mounting the storage from the app. Implementing -a storage wrapper is done by sub-classing -`\OC\Files\Storage\Wrapper\Wrapper` and overwriting any of its methods. - -=== Global Storage Wrappers - -For using a storage wrapper globally, you provide a callback which will -be called for each used storage. The callback can than determine if a -wrapper should be applied to the given storage, based on the storage or -mountpoint, or whether it needs to return the storage unwrapped. - -[source,php] ----- -Filesystem::addStorageWrapper('fooWrapper', function($mountPoint, $storage) { - if ($storage->instanceOfStorage('FooStorage')) { - return new FooWrapper(['storage' => $storage]); - } else { - return $storage; - } -} ----- - -=== Wrappers for a Single Storage - -Sometimes an app can avoid having to create a custom storage backend by -instead modifying the behavior of an existing one. ownCloud comes with a -few generic storage wrappers which might be useful when doing so, which -include `PermissionsMask` and `Jail`. - -==== PermissionsMask - -`\OC\Files\Storage\Wrapper\PermissionsMask` can be used to restrict the -permissions on an existing storage. A sample use case is to create a -read-only ftp backend. - -[source,php] ----- -$storage = $this->createStorageToWrapSomehow(); -return new PermissionsMask([ - 'storage' => $storage, - 'mask' => \OCP\Constant::PERMISSION_READ | \OCP\Constant::PERMISSION_SHARE -]); ----- - -==== Jail - -`\OC\Files\Storage\Wrapper\Jail` can be used to limit storage -interaction to a sub-folder of an existing storage. - -[source,php] ----- -$storage = $this->createStorageToWrapSomehow(); -return new Jail([ - 'storage' => $storage, - 'root' => 'some/folder/in/the/storage' -]); ----- - -=== A Note on instanceof() - - -Since storage wrappers wrap an existing storage instead of sub-classing -it, it is not possible to determine if the storage is a specific class -using PHP’s `instanceof` operator. Instead, you need to call the -`instanceOfStorage()` method on the class with the fully-qualified class -name. - -[source,php] ----- -// Only works if no wrappers are applied -if ($storage instanceof \OC\Files\Storage\DAV) { - // ... -} - -// Works regardless of any wrapper -if ($storage->instanceOfStorage('\OC\Files\Storage\DAV')) { - // ... -} ----- - -`instanceOfStorage()` can also be used to check if a certain wrapper is -applied to a storage. - -== Mounting Storages - -For an app to add its storages to the filesystem it should implement a -mount provider and register it with the filesystem. Implementing mount -providers is done by implementing the `\OCP\Files\Config\IMountProvider` -interface, containing the -`getMountsForUser(IUser $user, IStorageFactory $storageFactory)` method, -which returns a list of mountpoints that should be created for a user. - -[source,php] ----- -class MyMountProvider implements IMountProvider { - public function getMountsForUser(IUser $user, IStorageFactory $loader) { - $config = magicallyGetMountConfigurations(); - return array_map(function($mountOptions) use ($loader) { - return new Mount( - $mountOptions['class'], - $mountOptions['mountPoint'], - $mountOptions['storageOptions'], - $loader - ); - }, $config); - } -} ----- - -Registering a mount provider should be done from an app’s -`appinfo/app.php`. Note that any mount provider registered after the -filesystem is setup for a user will not be called again for that user. - -[source,php] ----- -$provider = new MyMountProvider(); -\OC::$server->getMountProviderCollection() - ->registerProvider($provider); ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/examples/signature.json b/content/server/10.15/modules/developer_manual/pages/app/advanced/examples/signature.json deleted file mode 100644 index fbfa3ed..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/examples/signature.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "hashes": { - "/filename.php": - "2401fed2eea6f2c1027c482a633e8e25cd46701f811e2d2c10dc213fd95fa60e350b - ccbbebdccc73a042b1a2799f673fbabadc783284cc288e4f1a1eacb74e3d", - "/lib/base.php": - "55548cc16b457cd74241990cc9d3b72b6335f2e5f45eee95171da024087d114fcbc2 - effc3d5818a6d5d55f2ae960ab39fd0414d0c542b72a3b9e08eb21206dd9" - }, - "certificate": "-----BEGIN CERTIFICATE----- - MIIBvTCCASagAwIBAgIUPvawyqJwCwYazcv7iz16TWxfeUMwDQYJKoZIhvcNAQEF\ - nBQAwIzEhMB8GA1UECgwYb3duQ2xvdWQgQ29kZSBTaWduaW5nIENBMB4XDTE1MTAx\ - nNDEzMTcxMFoXDTE2MTAxNDEzMTcxMFowEzERMA8GA1UEAwwIY29udGFjdHMwgZ8w\ - nDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBANoQesGdCW0L2L+a2xITYipixkScrIpB\ - nkX5Snu3fs45MscDb61xByjBSlFgR4QI6McoCipPw4SUr28EaExVvgPSvqUjYLGps\ - nfiv0Cvgquzbx/X3mUcdk9LcFo1uWGtrTfkuXSKX41PnJGTr6RQWGIBd1V52q1qbC\ - nJKkfzyeMeuQfAgMBAAEwDQYJKoZIhvcNAQEFBQADgYEAvF/KIhRMQ3tYTmgHWsiM\ - nwDMgIDb7iaHF0fS+/Nvo4PzoTO/trev6tMyjLbJ7hgdCpz/1sNzE11Cibf6V6dsz\ - njCE9invP368Xv0bTRObRqeSNsGogGl5ceAvR0c9BG+NRIKHcly3At3gLkS2791bC\ - niG+UxI/MNcWV0uJg9S63LF8=\n - -----END CERTIFICATE-----", - "signature": "U29tZVNpZ25lZERhdGFFeGFtcGxl" -} - diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/extstorage.adoc b/content/server/10.15/modules/developer_manual/pages/app/advanced/extstorage.adoc deleted file mode 100644 index 7367f82..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/extstorage.adoc +++ /dev/null @@ -1,195 +0,0 @@ -= External Storage Backends - -This section shows how a standard app can provide external storage -backends. - -To do so, requires several steps. These are: - -* xref:configure-the-filesystem-type[Configure the filesystem type] -* xref:implement-the-storage-classes[Implement the storage class(es)] -* xref:create-the-backend-adapter[Create the backend adapter] -* xref:register-the-backend-adapter[Register the backend adapter] -* xref:test-the-storage-backend[Test the storage backend] - -To save time, however, you can learn from an existing example, by -reading through the source code of the -https://github.com/owncloud/files_external_ftp[FTP external storage app]. - -== Configure the filesystem type - -First, the /appinfo/info.xml must be adjusted to specify the `type` as `filesystem`. + -For example: - -[source,xml] ----- -include::example$app/storage-backend/appinfo/info.xml[] ----- - -== Implement the storage class(es) - -Next, you need to create a storage class. Usually, you should implement -the interface `\\OCP\\Files\\Storage\\IStorage`. But, the easiest way is -to directly extend `\\OCP\\Files\\Storage\\StorageAdapter`, as it -already provides an implementation for many of the commonly required -methods. - -Here’s an example of how you would create one that implements all the -filesystem operations required by ownCloud, using a fictitious library -called `FakeStorageLib`. - -For this example we mapped the available storage methods to the ones -from the library. Note that, in many cases, the underlying library might -not support some operations and might need extra code to work this -around. - -When extending StorageAdapter, it is good practice to implement the -following methods, for performance reasons: - -* file_exists -* filetype -* fopen -* getId -* mkdir -* opendir -* rmdir -* stat -* touch -* unlink - -If you don’t, your storage backend will still work. But, it will likely -not perform as well as it could. In the case of the `rename` method, -this is because it uses a combination of a stream copy plus a delete for -renaming a file. - -=== Stat/metadata cache - -To create a mature implementation, we need to consider stat and metadata -caching. Within a single PHP request, ownCloud might call the same -storage methods repeatedly, due to different checks which it needs to -carry out. As a result, there is the potential to incur significant -overhead, when working with the underlying filesystem. - -To avoid — or at the very least _reduce_ this — a stat/metadata cache -should be implemented, if the underlying library does not support -stat/metadata caching. To do this, the metadata of any folder entries -which are read should be cached in a local array and returned by the -storage class’ methods. - -=== Writing a Flysystem adapter - -Instead of writing everything by hand, it is also possible to write an ownCloud adapter based on a -https://flysystem.thephpleague.com/docs/advanced/creating-an-adapter/[Flysystem adapter], -as external storage. You can see how it was done in the -https://github.com/owncloud/files_external_ftp/blob/master/lib/Storage/FTP.php#L27[FTP storage adapter]. - -== Create the backend adapter - -After implementing the storage class, a backend adapter needs to be -created. To do that, create a class that extends from -`\\OCP\\Files\\External\\Backend`: - -=== Definition parameters - -==== Flags: - -[cols=",",options="header",] -|============================================================= -| Flag | Description -| *DefinitionParameter::FLAG_NONE* | No flags (default) -| *DefinitionParameter::FLAG_OPTIONAL* | For optional parameters -|============================================================= - -==== Types: - -[cols=",",options="header",] -|======================================================================= -| Type | Description -| *DefinitionParameter::VALUE_TEXT* | Text field (default) - -| *DefinitionParameter::VALUE_PASSWORD* | Masked text field, for passwords -and - -| | keys - -| *DefinitionParameter::VALUE_BOOLEAN* | Boolean / checkbox - -| *DefinitionParameter::VALUE_HIDDEN* | Hidden field, useful with custom - -| | scripts -|======================================================================= - -=== Authentication schemes - -Several authentication schemes can be specified. - -[cols=",",options="header",] -|======================================================================= -| Scheme | Description -| *AuthMechanism::SCHEME_NULL* | No authentication supported - -| *AuthMechanism::SCHEME_BUILTIN* | Authentication is provided through - -| | definition parameters - -| *AuthMechanism::SCHEME_PASSWORD* | Support for password-based auth, - -| | provides two fields `user` and - -| | `password` to the parameter list - -| *AuthMechanism::SCHEME_OAUTH1* | OAuth1, provides fields `app_key`, - -| | `app_secret`, `token`, `token_secret` - -| | and `configured` - -| *AuthMechanism::SCHEME_OAUTH2* | OAuth2, provides fields `client_id`, - -| | `client_secret`, `token` and `configured` - -| *AuthMechanism::SCHEME_PUBLICKEY* | Public key, provides fields -`user`, - -| | `public_key`, `private_key` -|======================================================================= - -=== Custom user interface - -When dealing with complex field values or workflows like -https://en.wikipedia.org/wiki/OAuth[OAuth], an application might need to -provide custom JavaScript code to implement such workflow. To add a -custom script, use the following in the backend constructor: - -[source,php] ----- -$this->addCustomJs('script'); ----- - -This will automatically load the script /js/script.js from the app -folder. The script itself will need to inject events into the external -storage GUI as there is currently no proper public API to do so. - -== Register the backend adapter - -With the backend adapter created, it next needs to be registered. This -can be done in the `Application` class by implementing the -`IBackendProvider` interface, as in the example below: - -[source,php] ----- -include::example$app/storage-backend/OCA/MyStorageApp/AppInfo/Application.php[] ----- - -Then in appinfo/app.php instantiate the `Application` class: - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('AuthorService', function($c) { - return new AuthorService( - $c->query('L10N') - ); - }); - - $container->registerService('L10N', function($c) { - return $c->query('ServerContainer')->getL10N($c->query('AppName')); - }); - } -} ----- - -Strings can then be translated in the following way: - -[source,php] ----- -trans = $trans; - } - - public function getLanguageCode() { - return $this->trans->getLanguageCode(); - } - - public sayHello() { - return $this->trans->t('Hello'); - } - - public function getAuthorName($name) { - return $this->trans->t('Getting author %s', array($name)); - } - - public function getAuthors($count, $city) { - return $this->trans->n( - '%n author is currently in the city %s', // singular string - '%n authors are currently in the city %s', // plural string - $count, - array($city) - ); - } -} ----- - -== Templates - -In every template the global variable `$l` can be used to translate the -strings using its methods `t()` and `n()`: - -[source,php] ----- -
t('Showing %s files', $_['count'])); ?>
- - ----- - -== JavaScript - -There is a global function `t()` available for translating strings. The -first argument is your app name, the second argument is the string to -translate. - -[source,js] ----- -t('myapp', 'Hello World!'); ----- - -For advanced usage, refer to the source code `core/js/l10n.js`, `t()` is -bind to `OC.L10N.translate()`. - -== Hints - -In case some translation strings may be translated wrongly because they -have multiple meanings, you can add hints which will be shown in the -Transifex web-interface: - -[source,php] ----- -
    -
  • - t('Add new file')); - ?> -
  • -
----- - -== Creating Your Own Translatable Files - -If Transifex is not the right choice or the app is not accepted for -translation, generate the gettext strings by yourself by creating an -l10n/ directory in the app folder and executing - -[source,console] ----- -cd /srv/http/owncloud/apps/myapp/l10n -perl l10n.pl read myapp ----- - -The translation script requires `Locale::PO` and `gettext`, installable via: - -[source,console] ----- -sudo apt-get install liblocale-po-perl gettext ----- - -The above script generates a template that can be used to translate all -strings of an app. This template is located in the folder template/ with -the name myapp.pot. It can be used by your favored translation tool -which then creates a .po file. The .po file needs to be placed in a -folder named like the language code with the app name as filename - for -example l10n/es/myapp.po. After this step the Perl script needs to be -invoked to transfer the po file into our own file format that is more -easily readable by the server code - -[source,console] ----- -perl l10n.pl write myapp ----- - -Now the following folder structure is available - -[source,console] ----- -myapp/l10n -|-- es -|   |-- myapp.po -|-- es.js -|-- es.json -|-- es.php -|-- l10n.pl -|-- templates - |-- myapp.pot ----- - -You then just need the .php, .json and .js files for a working localized app. - - -== How to automatically sync translations - -1. Create an initial Transifex config within the app repository under `l10n/.tx/config`: -+ -[source,console] ----- -[main] -host = https://www.transifex.com -lang_map = ja_JP: ja - -[owncloud.APP_NAME] -file_filter = /APP_NAME.po -source_file = templates/APP_NAME.pot -source_lang = en -type = PO ----- -2. Give write permissions to the https://github.com/ownclouders[ownclouders] user, within the ownCloud GitHub organization, just add the `@owncloud/ci` team with admin permissions. -3. Create a pull request at {drone-star-url}[drone], just add another list item to the matrix (the apps are sorted alphabetically). -4. After merging the pull request the translations will already be synced, afterwards it will happen every night. diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/notifications.adoc b/content/server/10.15/modules/developer_manual/pages/app/advanced/notifications.adoc deleted file mode 100644 index 800216a..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/notifications.adoc +++ /dev/null @@ -1,220 +0,0 @@ -= Notifications - -:toc: right - -== Introduction - -This document is about how to manage notifications in ownCloud - -== Create a New Notification - -To create a new notification requires the following steps: - -. xref:retrieve-new-notification-object[Retrieve a new notification object from the notification manager] -. xref:set-the-necessary-information-for-the-notification[Set the necessary notification information] -. xref:send-the-notification-back-to-the-manager[Send the notification back to the manager] - -[[retrieve-new-notification-object]] -=== Retrieve a New Notification Object From the Notification Manager - -Grab a new notification object (`\OCP\Notification\INotification`) from the manager (`\OCP\Notification\IManager`). - -[source,php] ----- -getNotificationManager(); -$notification = $manager->createNotification(); ----- - -=== Set the Necessary Information for the Notification - -[source,php] ----- -createAction(); -$acceptAction - ->setLabel('accept') - ->setLink('/apps/files_sharing/api/v1/remote_shares/1337', 'POST'); - -$declineAction = $notification->createAction(); -$declineAction->setLabel('decline') - ->setLink('/apps/files_sharing/api/v1/remote_shares/1337', 'DELETE'); - -$notification->setApp('files_sharing') - ->setUser('recipient1') - ->setDateTime(new DateTime()) - ->setObject('remote', '1337') // $type and $id - ->setSubject('remote_share', ['/fancyFolder']) // $subject and $parameters - ->addAction($acceptAction) - ->addAction($declineAction) -; ----- - -TIP: Setting _app_, _user_, _timestamp_, _object_ and _subject_ are mandatory. - -You should not use a translated _subject_, _message_ or _action label_. -Use something like a "_language key_", to avoid length problems with translations in the storage of a notification app. -Translation is done via invocation of your notifier by the manager when the notification is prepared for display. - -=== Send the Notification Back to the Manager - -[source,php] ----- -notify($notification); - ----- -== Mark a Notification - -If the user accepted the share or the share was removed/unshared, we want to remove the notification, because no user action is needed anymore. -To do this, we simply have to call the `markProcessed()` method on the manager with the necessary information on a notification object: - -[source,php] ----- -getNotificationManager(); -$notification - ->setApp('files_sharing') - ->setObject('remote', 1337) - ->setUser('recipient1'); -$manager->markProcessed($notification); ----- - -Only the app name is mandatory, so if you don't set the user, the notification will be marked as processed for all users that have it. - -The following example shows how to mark all notifications for the `files_sharing` app on the object "_remote #1337_" as processed. - -[source,php] ----- -getNotificationManager(); -$notification - ->setApp('files_sharing') - ->setObject('remote', 1337); -$manager->markProcessed($notification); ----- - -Notifications can be marked as _read_, _deleted_, _processed_, or _obsoleted_. -To - - -== Prepare a Notification for Display - -To prepare a notification for display, in `app.php`, register your Notifier (`\OCP\Notification\INotifier`) interface to the manager, using a `\Closure`. - -[source,php] ----- -getNotificationManager(); -$manager->registerNotifier(function() { - return new \OCA\Files_Sharing\Notifier(\OC::$server->getL10NFactory()); -}); ----- - -The manager will execute the closure and then call the `prepare()` method on your notifier. -If the notification is not known by your app, throw an `\InvalidArgumentException`. -However, if it is actually from your app, you must set the parsed _subject_, _message_, and _action_ labels. - -[source,php] ----- -factory = $factory; -} - -/** - * @param INotification $notification - * @param string $languageCode The code of the language that should be used to prepare the notification - */ -public function prepare(INotification $notification, $languageCode) { - if ($notification->getApp() !== 'files_sharing') { - // Not my app => throw - throw new \InvalidArgumentException(); - } - - // Read the language from the notification - $l = $this->factory->get('myapp', $languageCode); - - switch ($notification->getSubject()) { - // Deal with known subjects - case 'remote_share': - $notification->setParsedSubject( - (string) $l->t( - 'You received the remote share "%s"', - $notification->getSubjectParameters() - ) - ); - - // Deal with the actions for a known subject - foreach ($notification->getActions() as $action) { - switch ($action->getLabel()) { - case 'accept': - $action->setParsedLabel( - (string) $l->t('Accept') - ); - break; - - case 'decline': - $action->setParsedLabel( - (string) $l->t('Decline') - ); - break; - } - - $notification->addParsedAction($action); - } - return $notification; - break; - - default: - // Unknown subject => Unknown notification => throw - throw new \InvalidArgumentException(); - } -} ----- - -NOTE: Currently, no markup is allowed. - -== Send Notifications - -To send notifications from your app, requires four steps, these are: - -. Fetch the notification manager from the server. -. Use the notification manager to create a notification object. -. Set the notification's information -. Send the notification. - -You can see an example of how to perform all of these steps in the example below. -The notification has a number of properties set that help identify the app that should receive it, along with information for the receiving app to use, once the notification has been received. - -[source,php] ----- -include::example$app/advanced/notifications/intro-notification.php[] ----- - -TIP: Make sure the app set in the notification matches the one you're expecting, because other notifications for other apps might reach your notifier. -Throw an `InvalidArgumentException` if this isn't the case. - -TIP: The notification's subject and message should be set using translated strings. - -In case you need to add some actions to the notification (e.g., to accept or reject shares, or other kind of actions): - -. Create the action from the notification -. Fill the action data -. Add the action in the notification - -You can see an example of how to perform all of these steps in the example below. - -[source,php] ----- -include::example$app/advanced/notifications/notification-with-object.php[] ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/storage-backend.adoc b/content/server/10.15/modules/developer_manual/pages/app/advanced/storage-backend.adoc deleted file mode 100644 index e5ffcc5..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/storage-backend.adoc +++ /dev/null @@ -1,500 +0,0 @@ -= Storage Backends - -== External Storage Backends - -This section shows how a standard app can provide external storage -backends. To do so, requires several steps. These are: - -* xref:configure-the-filesystem-type[Configure the filesystem type] -* xref:implement-the-storage-classes[Implement the storage class(es)] -* xref:create-the-backend-adapter[Create the backend adapter] -* xref:register-the-backend-adapter[Register the backend adapter] -* xref:test-the-storage-backend[Test the storage backend] - -To save time, however, you can learn from an existing example, by -reading through the source code of the -https://github.com/owncloud/files_external_ftp[FTP external storage -app]. - -=== Configure the Filesystem Type - -First, the /appinfo/info.xml must be adjusted to specify the `type` as: -`filesystem`. For example: - -=== Implement the Storage Class(es) - - -Next, you need to create a storage class. Usually, you should implement -the interface `\\OCP\\Files\\Storage\\IStorage`. But, the easiest way is -to directly extend `\\OCP\\Files\\Storage\\StorageAdapter`, as it -already provides an implementation for many of the commonly required -methods. - -Here’s an example of how you would create one that implements all the -filesystem operations required by ownCloud, using a fictitious library -called `FakeStorageLib`. - -For this example we mapped the available storage methods to the ones -from the library. Note that, in many cases, the underlying library might -not support some operations and might need extra code to work this -around. - -When extending `StorageAdapter`, it is good practice to implement the -following methods, for performance reasons: - -* file_exists -* filetype -* fopen -* getId -* mkdir -* opendir -* rmdir -* stat -* touch -* unlink - -If you don’t, your storage backend will still work. But, it will likely -not perform as well as it could. In the case of the `rename` method, -this is because it uses a combination of a stream copy plus a delete for -renaming a file. - -==== Stat/Metadata Cache - -To create a mature implementation, we need to consider stat and metadata -caching. Within a single PHP request, ownCloud might call the same -storage methods repeatedly, due to different checks which it needs to -carry out. As a result, there is the potential to incur significant -overhead, when working with the underlying filesystem. - -To avoid — or at the very least _reduce_ this — a stat/metadata cache -should be implemented, if the underlying library does not support -stat/metadata caching. To do this, the metadata of any folder entries -which are read should be cached in a local array and returned by the -storage class’ methods. - -==== Writing a Flysystem Adapter - -Instead of writing everything by hand, it is also possible to write an -ownCloud adapter based on a -https://flysystem.thephpleague.com/docs/advanced/creating-an-adapter/[Flysystem -adapter], as external storage. You can see how it was done in the -https://github.com/owncloud/files_external_ftp/blob/master/lib/Storage/FTP.php#L27[FTP -storage adapter]. - -=== Create the Backend Adapter - -After implementing the storage class, a backend adapter needs to be -created. To do that, create a class that extends from -`\\OCP\\Files\\External\\Backend`: - -==== Definition Parameters - -Flags -+++++ - -[cols=",",options="header",] -|============================================================= -| Flag | Description -| *DefinitionParameter::FLAG_NONE* | No flags (default) -| *DefinitionParameter::FLAG_OPTIONAL* | For optional parameters -|============================================================= - -Types -+++++ - -[cols=",",options="header",] -|======================================================================= -| Type | Description -| *DefinitionParameter::VALUE_TEXT* | Text field (default) - -| *DefinitionParameter::VALUE_PASSWORD* | Masked text field, for passwords -and - -| | keys - -| *DefinitionParameter::VALUE_BOOLEAN* | Boolean / checkbox - -| *DefinitionParameter::VALUE_HIDDEN* | Hidden field, useful with custom - -| | scripts -|======================================================================= - -=== Authentication Schemes - -Several authentication schemes can be specified. - -[cols=",",options="header",] -|======================================================================= -| Scheme | Description -| *AuthMechanism::SCHEME_NULL* | No authentication supported - -| *AuthMechanism::SCHEME_BUILTIN* | Authentication is provided through - -| | definition parameters - -| *AuthMechanism::SCHEME_PASSWORD* | Support for password-based auth, - -| | provides two fields `user` and - -| | `password` to the parameter list - -| *AuthMechanism::SCHEME_OAUTH1* | OAuth1, provides fields `app_key`, - -| | `app_secret`, `token`, `token_secret` - -| | and `configured` - -| *AuthMechanism::SCHEME_OAUTH2* | OAuth2, provides fields `client_id`, - -| | `client_secret`, `token` and `configured` - -| *AuthMechanism::SCHEME_PUBLICKEY* | Public key, provides fields -`user`, - -| | `public_key`, `private_key` -|======================================================================= - -=== Custom User Interface - -When dealing with complex field values or workflows like -https://en.wikipedia.org/wiki/OAuth[OAuth], an application might need to -provide custom JavaScript code to implement such workflow. To add a -custom script, use the following in the backend constructor: - -[source,php] ----- -$this->addCustomJs('script'); ----- - -This will automatically load the script /js/script.js from the app -folder. The script itself will need to inject events into the external -storage GUI as there is currently no proper public API to do so. - -=== Register the Backend Adapter - -With the backend adapter created, it next needs to be registered. This -can be done in the `Application` class by implementing the -`IBackendProvider` interface, as in the example below: - -[source,php] ----- -:include: examples/storage-backend/OCA/MyStorageApp/AppInfo/Application.php ----- - -Then in appinfo/app.php instantiate the `Application` class: - -[source,php] ----- -getFolderContentsSomehow(); -return IteratorDirectory::wrap($fileNames); ----- - -=== CallbackWrapper - -`Icewind\Streams\CallbackWrapper` wraps an existing file handle, and -allows for hooking into file reads and writes, and closing streams. The -most common use case for this class in storage backends is for -implementing `fopen()` with writable streams. This is because writing to -and closing streams happens outside the storage implementation. As a -result, the storage backend needs a way to upload the changed file back -to the backend. This can be done by attaching a close-callback to a -stream for a temporary file. - -[source,php] ----- -$tempFile = $this->downloadFile($path); -$handle = fopen($tempFile, $mode); -return CallBackWrapper::wrap($handle, null, null function() use ($path, $tempFile) { - $this->uploadFile($tempFile, $path); - unlink($tempFile); -} ----- - -=== Storage Wrappers - -Besides implementing a complete custom storage backend, ownCloud allows -for modifying the behavior of an existing storage by applying a wrapper -to it. Storage wrappers need to implement the full storage API methods. -Examples of storage wrappers are - -* *The Quota wrapper.* This changes the behavior of free_space by -limiting the free space returned by the wrapped storage to a configured -maximum -* *The Encryption wrapper*. This encrypts and decrypts the data on the -fly by overwriting `file_put_contents`, `file_get_contents`, and -`fopen`. - -When implementing a storage wrapper, the wrapped storage is available as -`$this->storage`. Storage wrappers can either be applied globally to all -used storages using -`\OC\Files\Filesystem::addStorageWrapper($name, $wrapper)` or to a -specific storage, while mounting the storage from the app. Implementing -a storage wrapper is done by sub-classing -`\OC\Files\Storage\Wrapper\Wrapper` and overwriting any of its methods. - -=== Global Storage Wrappers - -For using a storage wrapper globally, you provide a callback which will -be called for each used storage. The callback can than determine if a -wrapper should be applied to the given storage, based on the storage or -mountpoint, or whether it needs to return the storage unwrapped. - -[source,php] ----- -Filesystem::addStorageWrapper('fooWrapper', function($mountPoint, $storage) { - if ($storage->instanceOfStorage('FooStorage')) { - return new FooWrapper(['storage' => $storage]); - } else { - return $storage; - } -} ----- - -=== Wrappers for a Single Storage - -Sometimes an app can avoid having to create a custom storage backend by -instead modifying the behavior of an existing one. ownCloud comes with a -few generic storage wrappers which might be useful when doing so, which -include `PermissionsMask` and `Jail`. - -==== PermissionsMask - -`\OC\Files\Storage\Wrapper\PermissionsMask` can be used to restrict the -permissions on an existing storage. A sample use case is to create a -read-only ftp backend. - -[source,php] ----- -$storage = $this->createStorageToWrapSomehow(); -return new PermissionsMask([ - 'storage' => $storage, - 'mask' => \OCP\Constant::PERMISSION_READ | \OCP\Constant::PERMISSION_SHARE -]); ----- - -==== Jail - -`\OC\Files\Storage\Wrapper\Jail` can be used to limit storage -interaction to a sub-folder of an existing storage. - -[source,php] ----- -$storage = $this->createStorageToWrapSomehow(); -return new Jail([ - 'storage' => $storage, - 'root' => 'some/folder/in/the/storage' -]); ----- - -=== A Note on instanceof() - - -Since storage wrappers wrap an existing storage instead of sub-classing -it, it is not possible to determine if the storage is a specific class -using PHP’s `instanceof` operator. Instead, you need to call the -`instanceOfStorage()` method on the class with the fully-qualified class -name. - -[source,php] ----- -// Only works if no wrappers are applied -if ($storage instanceof \OC\Files\Storage\DAV) { - // ... -} - -// Works regardless of any wrapper -if ($storage->instanceOfStorage('\OC\Files\Storage\DAV')) { - // ... -} ----- - -`instanceOfStorage()` can also be used to check if a certain wrapper is -applied to a storage. - -=== Mounting Storages - -For an app to add its storages to the filesystem it should implement a -mount provider and register it with the filesystem. Implementing mount -providers is done by implementing the `\OCP\Files\Config\IMountProvider` -interface, containing the -`getMountsForUser(IUser $user, IStorageFactory $storageFactory)` method, -which returns a list of mountpoints that should be created for a user. - -[source,php] ----- -class MyMountProvider implements IMountProvider { - public function getMountsForUser(IUser $user, IStorageFactory $loader) { - $config = magicallyGetMountConfigurations(); - return array_map(function($mountOptions) use ($loader) { - return new Mount( - $mountOptions['class'], - $mountOptions['mountPoint'], - $mountOptions['storageOptions'], - $loader - ); - }, $config); - } -} ----- - -Registering a mount provider should be done from an app’s -`appinfo/app.php`. Note that any mount provider registered after the -filesystem is setup for a user will not be called again for that user. - -[source,php] ----- -$provider = new MyMountProvider(); -\OC::$server->getMountProviderCollection() - ->registerProvider($provider); ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/two-factor-provider.adoc b/content/server/10.15/modules/developer_manual/pages/app/advanced/two-factor-provider.adoc deleted file mode 100644 index 065a6ce..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/two-factor-provider.adoc +++ /dev/null @@ -1,104 +0,0 @@ -= Two-Factor Providers - -Two-factor authentication providers apps are used to plug custom second -factors into the ownCloud core. The following code was taken from the -https://github.com/ChristophWurst/twofactor_test[two-factor test app]. - -== Implementing a Two-Factor Authentication Provider - -Two-factor authentication providers must implement the -`OCP\Authentication\TwoFactorAuth\IProvider` interface. The example -below shows a minimalist example of such a provider. - -[source,php] ----- - - OCA\TwoFactor_Test\Provider\TwoFactorTestProvider - ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/advanced/users.adoc b/content/server/10.15/modules/developer_manual/pages/app/advanced/users.adoc deleted file mode 100644 index 4641c0c..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/advanced/users.adoc +++ /dev/null @@ -1,172 +0,0 @@ -= User Management - -Users can be managed using the `UserManager` which is injected from the -`ServerContainer`: - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('UserService', function($c) { - return new UserService( - $c->query('UserManager') - ); - }); - - $container->registerService('UserManager', function($c) { - return $c->query('ServerContainer')->getUserManager(); - }); - } -} ----- - -== Creating Users - -Creating a user is done by passing a username and password to the -`create` method: - -[source,php] ----- -userManager = $userManager; - } - - public function create($userId, $password) { - return $this->userManager->create($userId, $password); - } - -} ----- - -== Modifying Users - -Users can be modified by getting a user by the `userId` or by a search -pattern. The returned user objects can then be used to: - -* Delete them -* Set a new password -* Disable/Enable them -* Get their home directory - -[source,php] ----- -userManager = $userManager; - } - - public function delete($userId) { - return $this->userManager->get($userId)->delete(); - } - - /** - * recoveryPassword is used for the encryption app to recover the keys - */ - public function setPassword($userId, $password, $recoveryPassword) { - return $this->userManager->get($userId)->setPassword($password, $recoveryPassword); - } - - public function disable($userId) { - return $this->userManager->get($userId)->setEnabled(false); - } - - public function getHome($userId) { - return $this->userManager->get($userId)->getHome(); - } -} ----- - -== User Session Information - -To login, logout or getting the currently logged in user, the -`UserSession` has to be injected from the `ServerContainer`: - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('UserService', function($c) { - return new UserService( - $c->query('UserSession') - ); - }); - - $container->registerService('UserSession', function($c) { - return $c->query('ServerContainer')->getUserSession(); - }); - - // currently logged in user, userId can be gotten by calling the - // getUID() method on it - $container->registerService('User', function($c) { - return $c->query('UserSession')->getUser(); - }); - } -} ----- - -Then users can be logged in by using: - -[source,php] ----- -userSession = $userSession; - } - - public function login($userId, $password) { - return $this->userSession->login($userId, $password); - } - - public function logout() { - $this->userSession->logout(); - } - -} ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/api.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/api.adoc deleted file mode 100644 index 3a27084..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/api.adoc +++ /dev/null @@ -1,91 +0,0 @@ -= RESTful API - -Offering a RESTful API is not different from creating a route -and controllers for the web interface. It is recommended -though to inherit from ApiController and add *@CORS* annotations to the -methods so that -https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS[web -applications will also be able to access the API]. - -[source,php] ----- - 'author_api#preflighted_cors', - 'url' => '/api/1.0/{path}', - 'verb' => 'OPTIONS', - 'requirements' => array('path' => '.+') -) ----- - -Keep in mind that multiple apps will likely depend on the API interface -once it is published and they will move at different speeds to react to -changes implemented in the API. Therefore it is recommended to version -the API in the URL to not break existing apps when backwards -incompatible changes are introduced: - ----- -/index.php/apps/myapp/api/1.0/resource ----- - -== Modifying the CORS headers - -By default the following values will be used for the preflighted OPTIONS -request: - -* *Access-Control-Allow-Methods*: `PUT, POST, GET, DELETE, PATCH' -* *Access-Control-Allow-Headers*: `Authorization, Content-Type, Accept' -* *Access-Control-Max-Age*: 1728000 - -To add an additional method or header or allow less headers, simply pass -additional values to the parent constructor: - -[source,php] ----- - - \OCA\MyApp\Cron\SomeTask - ----- - -== Testing - -To test the job classes, you can run Cron manually, as in the example below: - -[source,console,subs="attributes+"] ----- -{occ-command-example-prefix} system cron ----- - -After doing so, you will need to reset the job to allow it to be run, -manually, again. To do this, go to the database and run the following -SQL query: - -[source,sql] ----- -UPDATE oc_jobs SET last_run=0,last_checked=0,reserved_at=0; ----- - -== Is The Cron Service Running? - -Finally, don’t forget to add the ownCloud Cron process in the web -server’s http://www.adminschoice.com/crontab-quick-reference[crontab]. -To do this, first open the web server’s crontab for editing by running: - -In this example, `www-data` is the web server user: - -[source,console] ----- -sudo crontab -u www-data -e ----- - -Then, add the ownCloud Cron process to the crontab, for example: - ----- -*/15 * * * * /usr/bin/php /path/to/your/owncloud/occ system:cron ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/changelog.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/changelog.adoc deleted file mode 100644 index dc034a3..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/changelog.adoc +++ /dev/null @@ -1,168 +0,0 @@ -= Changelog - -== Breaking changes - -=== 8.2 RC2 - -The following breaking changes usually only affect applications which -misuse existing API or do not follow best practices. - -* The default Content-Security-Policy of `AppFramework` apps is now -stricter but can be adjusted by developers. See -https://github.com/owncloud/core/pull/13989 -* Parameters passed to `OC.generateUrl` are now automatically encoded, -this behavior can be adjusted by developers. See -https://github.com/owncloud/core/pull/14266 -* Views constructed by OCFilesView do not allow directory traversals -anymore in the constructor. See -https://github.com/owncloud/core/pull/14342 -* The CSRF token may now contain not URL compatible characters (for -example the plus sign: +), developers have to ensure that the CSRF token -is encoded properly before using it in URIs. -* The default RNG now returns all valid Base64 characters -* `OC.msg` escapes the message now by default (see -https://github.com/owncloud/core/pull/14208) - -== Features - -=== 8.2 RC2 - -* There is a new OCSResponse and OCSController which -allows you to easily migrate OCS code to the App Framework. This was -added purely for compatibility reasons and the preferred way of doing -APIs is using a api -* You can now stream files in PHP by using the built in -StreamResponse . -* For more advanced use cases you can now implement the -CallbackResponse interface which allows your response to -do its own response rendering -* Custom preview providers can now be implemented using -`OCP\IPreview::registerProvider` -* There is a mightier class for remote web service requests at -`OCP\Http\Client` -* `OCP\\IImage` allows now basic image manipulations such as resizing or -rotating -* `OCP\\Mail` allows sending mails in an object-oriented way now -* `OCP\\IRequest` contains more methods now such as getting the request -URI -* `OCP\\Encryption` allows writing custom encryption backends - -Furthermore all public APIs have received a `@since` annotation allowing -developers to see when a function has been introduced. - -== Deprecations - -This is a deprecation roadmap which lists all current deprecation -targets and will be updated from release to release. This lists the -version when a specific method or class will be removed. - -Deprecations on interfaces also affect the implementing classes! - -=== Deprecation Policy - -=== 11.1 - -* `OCP\\App::setActiveNavigationEntry` has been deprecated in favour of -`\\OCP\\INavigationManager` -* `OCP\\BackgroundJob::registerJob` has been deprecated in favour of -`OCP\\BackgroundJob\\IJobList` -* `OCP\\Contacts` functions has been deprecated in favour of -`\\OCP\\Contacts\\IManager` -* `OCP\\DB` functions have been deprecated in favour of the ones in -`\\OCP\\IDBConnection` -* `OCP\\Files::tmpFile` has been deprecated in favour of -`\\OCP\\ITempManager::getTemporaryFile` -* `OCP\\Files::tmpFolder` has been deprecated in favour of -`\\OCP\\ITempManager::getTemporaryFolder` -* `\\OCP\\IServerContainer::getDb` has been deprecated in favour of -`\\OCP\\IServerContainer::getDatabaseConnection` -* `\\OCP\\IServerContainer::getHTTPHelper` has been deprecated in favour -of `\\OCP\\Http\\Client\\IClientService` -* Legacy applications not using the `AppFramework` are now likely to use -the deprecated `OCP\\JSON` and `OCP\\Response` code: -** `\\OCP\\JSON` has been completely deprecated in favour of the -`AppFramework`. Developers shall use the `AppFramework` instead of using -the legacy `OCP\\JSON` code. This allows testable controllers and is -highly encouraged. -** `\\OCP\\Response` has been completely deprecated in favour of the -`AppFramework`. Developers shall use the `AppFramework` instead of using -the legacy `OCP\\JSON` code. This allows testable controllers and is -highly encouraged. -* Diverse `OCP\\Users` function got deprecated in favour of -`OCP\\IUserManager`: -** `OCP\\Users::getUsers` has been deprecated in favour of -`OCP\\IUserManager::search` -** `OCP\\Users::getDisplayName` has been deprecated in favour of -`OCP\\IUserManager::getDisplayName` -** `OCP\\Users::getDisplayNames` has been deprecated in favour of -`OCP\\IUserManager::searchDisplayName` -** `OCP\\Users::userExists` has been deprecated in favour of -`OCP\\IUserManager::userExists` -* Various static `OCP\\Util` functions have been deprecated: -** `OCP\\Util::linkToRoute` has been deprecated in favour of -`\\OCP\\IURLGenerator::linkToRoute` -** `OCP\\Util::linkTo` has been deprecated in favour of -`\\OCP\\IURLGenerator::linkTo` -** `OCP\\Util::imagePath` has been deprecated in favour of -`\\OCP\\IURLGenerator::imagePath` -** `OCP\\Util::isValidPath` has been deprecated in favour of -`\\OCP\\IURLGenerator::imagePath` - -=== 10.0 - -* An API added in one version of ownCloud only needs to be maintained as -long as that version is not End of Life (EOL) -* An API can be removed completely in a future version of ownCloud if -the release date of the version is later than the EOL date of the -previous version -* Before removing an API completely, it needs to deprecated for at least -a year. This is done by adding @deprecated tags. -* `OCP\\IDb`: This interface and the implementing classes will be -removed in favor of `OCP\\IDbConnection`. Various layers in between have -also been removed to be consistent with the PDO classes. This leads to -the following changes: -** Replace all calls on the db using `getInsertId` with `lastInsertId` -** Replace all calls on the db using `prepareQuery` with `prepare` -** The `__construct` method of `OCP\\AppFramework\\Db\\Mapper` no longer -requires an instance of `OCP\\IDb` but an instance of -`OCP\\IDbConnection` -** The `execute` method on `OCP\\AppFramework\\Db\\Mapper` no longer -returns an instance of `OC_DB_StatementWrapper` but an instance of -`PDOStatement` - -9.0 -~~~ - -* The following methods have been moved into the -`OCP\\Template::` class instead of being namespaced directly: -** `OCP\\image_path` -** `OCP\\mimetype_icon` -** `OCP\\preview_icon` -** `OCP\\publicPreview_icon` -** `OCP\\human_file_size` -** `OCP\\relative_modified_date` -** `OCP\\html_select_options` -* `OCP\\simple_file_size` has been deprecated in favour of -`OCP\\Template::human_file_size` -* The `OCP\\PERMISSION_` and `OCP\\FILENAME_INVALID_CHARS` -have been moved to `OCP\\Constants::` -* The `OC_GROUP_BACKEND_` and `OC_USER_BACKEND_` have -been moved to `OC_Group_Backend::` and -`OC_User_Backend::` respectively - -8.3 -~~~ - -* https://github.com/owncloud/core/blob/d59c4e832fea87d03d199a3211186a47fd252c32/lib/public/appframework/iapi.php[OCP\AppFramework\IApi]: -full class -* https://github.com/owncloud/core/blob/d59c4e832fea87d03d199a3211186a47fd252c32/lib/public/appframework/iappcontainer.php[OCP\AppFramework\IAppContainer]: -methods `getCoreApi` and `log` -* https://github.com/owncloud/core/blob/d59c4e832fea87d03d199a3211186a47fd252c32/lib/public/appframework/controller.php[OCP\AppFramework\Controller]: -methods `params`, `getParams`, `method`, `getUploadedFile`, `env`, -`cookie`, `render` - -8.1 -~~~ - -* https://github.com/owncloud/core/commit/909a53e087b7815ba9cd814eb6c22845ef5b48c7[\OC\Preferences] -and https://github.com/owncloud/core/commit/4df7c0a1ed52ed1922116686cb5ad8da2544c997[\OC_Preferences] diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/classloader.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/classloader.adoc deleted file mode 100644 index 9ea50a9..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/classloader.adoc +++ /dev/null @@ -1,85 +0,0 @@ -= The Classloader - -The classloader is provided by ownCloud and loads all your classes -automatically. The only thing left to include by yourself are 3rd party -libraries. Those should be loaded in lib/AppInfo/Application.php. - -== PSR-4 Autoloading - -Since ownCloud 9.1 there is a PSR-4 autoloader in place. The namespace -`\\OCA\\MyApp` is mapped to /apps/myapp/lib/. Afterward, normal PSR-4 -rules apply, so a folder is a namespace section in the same casing and -the class name matches the file name. - -If your `appid` can not be turned into the namespace by upper-casing the -first character, you can specify it in your `appinfo/info.xml` by -providing a field called `namespace`. The required namespace is the one -which comes after the top level namespace `OCA\\`, e.g.: for -`OCA\\MyBeautifulApp\\Some\\OtherClass` the needed namespace would be -`MyBeautifulApp` and would be added to the `info.xml` in the following -way: - -[source,xml] ----- - - - MyBeautifulApp - - ----- - -A second PSR-4 root is available when running tests. -`\\OCA\\MyApp\\Tests` is thereby mapped to /apps/myapp/tests/. - -== Legacy Autoloading - -The legacy classloader, deprecated since 9.1, is still in place and -works like this: - -* Take the full qualifier of a class - -[source,php] ----- -\OCA\MyApp\Controller\PageController ----- - -* If it starts with `\\OCA`, then include the file from the apps -directory -* Cut off `\\OCA` - -[source,php] ----- -\MyApp\Controller\PageController ----- - -* Convert all characters to lowercase - -[source,php] ----- -\myapp\controller\pagecontroller ----- - -* Replace \ with / - -[source,php] ----- -/myapp/controller/pagecontroller ----- - -* Append .php - -[source,php] ----- -/myapp/controller/pagecontroller.php ----- - -* Prepend /apps because of the `OCA` namespace and include the file - -[source,php] ----- -require_once '/apps/myapp/controller/pagecontroller.php'; ----- - -*In other words*: In order for the `PageController` class to be -autoloaded, the class `\\OCA\\MyApp\\Controller\\PageController` needs -to be stored in the /apps/myapp/controller/pagecontroller.php diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/configuration.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/configuration.adoc deleted file mode 100644 index 87092bf..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/configuration.adoc +++ /dev/null @@ -1,140 +0,0 @@ -= Configuration - -The config that allows the app to set _global_, _app_, and _user_ -settings can be injected from the `ServerContainer`. All values are -saved as strings and must be cast to the correct value. - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('AuthorService', function($c) { - return new AuthorService( - $c->query('Config'), - $c->query('AppName') - ); - }); - - $container->registerService('Config', function($c) { - return $c->query('ServerContainer')->getConfig(); - }); - } -} ----- - -== System Values - -System values are saved in the `config/config.php` and allow the app to modify and read the global configuration: - -[source,php] ----- -config = $config; - $this->appName = $appName; - } - - public function getSystemValue($key) { - return $this->config->getSystemValue($key); - } - - public function setSystemValue($key, $value) { - $this->config->setSystemValue($key, $value); - } - -} ----- - -== App Values - -App values are saved in the database per application, and are useful for -setting global application settings: - -[source,php] ----- -config = $config; - $this->appName = $appName; - } - - public function getAppValue($key) { - return $this->config->getAppValue($this->appName, $key); - } - - public function setAppValue($key, $value) { - $this->config->setAppValue($this->appName, $key, $value); - } - -} ----- - -== User Values - -User values are saved in the database per user and app and are good for -saving user specific app settings: - -[source,php] ----- -config = $config; - $this->appName = $appName; - } - - public function getUserValue($key, $userId) { - return $this->config->getUserValue($userId, $this->appName, $key); - } - - public function setUserValue($key, $userId, $value) { - $this->config->setUserValue($userId, $this->appName, $key, $value); - } - -} ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/container.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/container.adoc deleted file mode 100644 index bf33d6d..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/container.adoc +++ /dev/null @@ -1,417 +0,0 @@ -= The DI Container - -The App Framework assembles the application by using a container based -on the software pattern -https://en.wikipedia.org/wiki/Dependency_injection[Dependency Injection]. -This makes the code easier to test and thus easier to maintain. - -If you are unfamiliar with this pattern, watch the following videos: - -* http://www.youtube.com/watch?v=DcNtg4_i-2w[Dependency Injection and -the art of Services and Containers Tutorial] -* http://www.youtube.com/watch?v=RlfLCWKxHJ0[Google Clean Code Talks] - -== Dependency Injection - -Dependency Injection sounds pretty complicated but it just means: Don’t -put new dependencies in your constructor or methods but pass them in. So -this: - -[source,php] ----- -db = new Db(); - } - -} ----- - -would turn into this by using Dependency Injection: - -[source,php] ----- -db = $db; - } - -} ----- - -== Using a Container - -Passing dependencies into the constructor rather than instantiating them -in the constructor has the following drawback: Every line in the source -code where `new AuthorMapper` is being used has to be changed, once a -new constructor argument is being added to it. - -The solution for this particular problem is to limit the -`new AuthorMapper` to one file, the container. The container contains -all the factories for creating these objects and is configured in -`lib/AppInfo/Application.php`. - -To add the app’s classes simply open the `lib/AppInfo/Application.php` and -use the `registerService` method on the container object: - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('AuthorController', function($c){ - return new AuthorController( - $c->query('AppName'), - $c->query('Request'), - $c->query('AuthorService') - ); - }); - - /** - * Services - */ - $container->registerService('AuthorService', function($c){ - return new AuthorService( - $c->query('AuthorMapper') - ); - }); - - /** - * Mappers - */ - $container->registerService('AuthorMapper', function($c){ - return new AuthorMapper( - $c->query('ServerContainer')->getDb() - ); - }); - } -} ----- - -=== How the Container Works - -The container works in the following way: - -* A request comes in and is matched against xref:app/tutorial/request.adoc[a route] (for the `AuthorController` in this case) -* The matched route queries `AuthorController` service from the container: -+ ----- -return new AuthorController( - $c->query('AppName'), - $c->query('Request'), - $c->query('AuthorService') -); ----- -* The `AppName` is queried and returned from the baseclass -* The `Request` is queried and returned from the server container -* `AuthorService` is queried: -+ ----- -$container->registerService('AuthorService', function($c){ - return new AuthorService( - $c->query('AuthorMapper') - ); -}); ----- -* `AuthorMapper` is queried: -+ ----- -$container->registerService('AuthorMappers', function($c){ - return new AuthorService( - $c->query('ServerContainer')->getDb() - ); -}); ----- -* The `database connection` is returned from the server container -* Now `AuthorMapper` has all of its dependencies and the object is -returned -* `AuthorService` gets the `AuthorMapper` and returns the object -* `AuthorController` gets the `AuthorService` and finally the controller -can be instantiated and the object is returned - -So basically the container is used as a giant factory to build all the -classes that are needed for the application. Because it centralizes all -the creation of objects (the `new Class()` lines), it is very easy to -add new constructor parameters without breaking existing code: only the -`__construct` method and the container line where the `new` is being -called need to be changed. - -== Use Automatic Dependency Assembly (Recommended) - -Since ownCloud 8 it is possible to omit the -`lib/AppInfo/Application.php` and use automatic dependency assembly -instead. - -== How Does Automatic Assembly Work - -Automatic assembly creates new instances of classes just by looking at -the class name and its constructor parameters. For each constructor -parameter the type or the variable name is used to query the container, -e.g.: - -* `SomeType $type` will use `$container->query('SomeType')` -* `$variable` will use `$container->query('variable')` - -If all constructor parameters are resolved, the class will be created, -saved as a service and returned. So basically the following is now -possible: - -[source,php] ----- -class = $class; - $this->appName = $AppName; - } -} - -$app = new \OCP\AppFramework\App('myapp'); - -$class2 = $app->getContainer()->query('OCA\MyApp\MyTestClass2'); - -$class2 instanceof MyTestClass2; // true -$class2->class instanceof MyTestClass; // true -$class2->appName === 'myapp'; // true -$class2 === $app->getContainer()->query('OCA\MyApp\MyTestClass2'); // true ----- - -$AppName is resolved because the container registered a parameter under -the key `AppName' which will return the app id. The lookup is case -sensitive so while `$AppName` will work correctly, using `$appName` as a -constructor parameter will fail. - -== How Does it Affect the Request Lifecycle - -* A request comes in -* All apps’ `routes.php` files are loaded -** If a `routes.php` file returns an array, and an -`appname/lib/AppInfo/Application.php` exists, include it, create a new -instance of `\\OCA\\AppName\\AppInfo\\Application.php` and register the -routes on it. That way a container can be used while still benefiting -from the new routes behavior -** If a `routes.php` file returns an array, but there is no -`appname/lib/AppInfo/Application.php`, create a new -\OCP\AppFramework\App instance with the app id and register the routes -on it -* A request is matched for the route, e.g. with the name `page#index` -* The appropriate container is being queried for the entry -PageController (to keep backwards compatibility) -* If the entry does not exist, the container is queried for -OCA\AppName\Controller\PageController and if no entry exists, the -container tries to create the class by using reflection on its -constructor parameters - -== How Does This Affect Controllers - -The only thing that needs to be done to add a route and a controller -method is now: - -`myapp/appinfo/routes.php` - -[source,php] ----- - [ - ['name' => 'page#index', 'url' => '/', 'verb' => 'GET'], -]]; ----- - -`myapp/appinfo/lib/Controller/PageController.php` - -[source,php] ----- -getContainer(); - - // AuthorMapper requires a location as string called $TableName - $container->registerParameter('TableName', 'my_app_table'); - - // the interface is called IAuthorMapper and AuthorMapper implements it - $container->registerService('OCA\MyApp\Db\IAuthorMapper', function ($c) { - return $c->query('OCA\MyApp\Db\AuthorMapper'); - }); - } - -} ----- - -== Predefined Core Services - -The following parameter names and type hints can be used to inject core -services instead of using `$container->getServer()->getServiceX()` - -Parameters: - -* `AppName`: The app id -* `WebRoot`: The path to the ownCloud installation -* `UserId`: The id of the current user - -Types: - -* `OCP\\IAppConfig` -* `OCP\\IAppManager` -* `OCP\\IAvatarManager` -* `OCP\\Activity\\IManager` -* `OCP\\ICache` -* `OCP\\ICacheFactory` -* `OCP\\IConfig` -* `OCP\\AppFramework\\Utility\\IControllerMethodReflector` -* `OCP\\Contacts\\IManager` -* `OCP\\IDateTimeZone` -* `OCP\\IDb` -* `OCP\\IDBConnection` -* `OCP\\Diagnostics\\IEventLogger` -* `OCP\\Diagnostics\\IQueryLogger` -* `OCP\\Files\\Config\\IMountProviderCollection` -* `OCP\\Files\\IRootFolder` -* `OCP\\IGroupManager` -* `OCP\\IL10N` -* `OCP\\ILogger` -* `OCP\\BackgroundJob\\IJobList` -* `OCP\\INavigationManager` -* `OCP\\IPreview` -* `OCP\\IRequest` -* `OCP\\AppFramework\\Utility\\ITimeFactory` -* `OCP\\ITagManager` -* `OCP\\ITempManager` -* `OCP\\Route\\IRouter` -* `OCP\\ISearch` -* `OCP\\ISearch` -* `OCP\\Security\\ICrypto` -* `OCP\\Security\\IHasher` -* `OCP\\Security\\ISecureRandom` -* `OCP\\IURLGenerator` -* `OCP\\IUserManager` -* `OCP\\IUserSession` - -== How to Enable It - -To make use of this new feature, the following things have to be done: - -* `appinfo/info.xml` requires to provide another field called -`namespace` where the namespace of the app is defined. The required -namespace is the one which comes after the top level namespace `OCA\\`, -e.g.: for `OCA\\MyBeautifulApp\\Some\\OtherClass` the needed namespace -would be `MyBeautifulApp` and would be added to the info.xml in the -following way: -+ -[source,xml] ----- - - - MyBeautifulApp - - ----- -* `appinfo/routes.php`: Instead of creating a new Application class -instance, simply return the routes array like: -+ -[source,php] ----- - [ - ['name' => 'page#index', 'url' => '/', 'verb' => 'GET'], -]]; ----- - -A namespace tag is required because you can not deduce the namespace -from the app id - -== Which Classes Should Be Added - -In general all of the app’s controllers need to be registered inside the -container. Then the following question is: What goes into the -constructor of the controller? Pass everything into the controller -constructor that matches one of the following criteria: - -* It does I/O (database, write/read to files) -* It is a global (e.g. $_POST, etc. This is in the request class by the -way) -* The output does not depend on the input variables (also called -http://en.wikipedia.org/wiki/Pure_function[impure function]), e.g. time, -random number generator -* It is a service, basically it would make sense to swap it out for a -different object - -What not to inject: - -* It is pure data and has methods that only act upon it (arrays, data -objects) -* It is a http://en.wikipedia.org/wiki/Pure_function[pure function] diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/controllers.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/controllers.adoc deleted file mode 100644 index 9302a43..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/controllers.adoc +++ /dev/null @@ -1,842 +0,0 @@ -= Controllers - -== Introduction - -Controllers are used to connect routes with application logic. -Think of them as callbacks that are executed once a request has come in. -Controllers are defined inside the `lib/Controller/` directory. To -create a controller, extend the `Controller` class and create a method -that should be executed to handle a request. - -Here is an example of how to do so. - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('AuthorApiController', function($c) { - // register the controller in the container - return new AuthorApiController( - $c->query('AppName'), - $c->query('Request') - ); - }); - } -} ----- - -Every controller requires the application name and the request object to -be passed to their parent constructor. This can be done as shown in the -example code above. - -The important part is not the class name, but rather the string which is -passed in as the first parameter of the `registerService` method. - -The other part is the route name. An example route name would look like -this: - ----- -author_api#some_method ----- - -This name is processed in the following way: - -1. Remove the underscore and uppercase the next character: -+ ----- -authorApi#someMethod ----- -2. Then split the name at the # and uppercase the first letter of the -left part: -+ ----- -AuthorApi -someMethod ----- -3. Then append Controller to the first part: -+ ----- -AuthorApiController -someMethod ----- -4. Finally, retrieve the service listed under `AuthorApiController` -from the container, look up the parameters of the `someMethod` method in -the request, cast them if there are PHPDoc type annotations, and execute -the `someMethod` method on the controller with those parameters. - -== Getting Request Parameters - -Parameters can be passed in many ways, including: - -* Extracting them from the URL using curly braces like `\{key\}` inside -the URL (see routes) -* Appending them to the URL as a GET request (e.g. `?something=true`) -* Setting the form’s encoding type as -`application/x-www-form-urlencoded` in a form request -* Setting the encoding type as `application/json` in a `POST`, `PATCH`, -or `PUT` request - -These parameters can be accessed by adding them to the controller -method. For example: - -[source,php] ----- - $id = 3 - // $doMore = false - // $value = 3.5 - } -} ----- - -The following types will be cast: - -* `bool` or `boolean` -* `float` -* `int` or `integer` - -=== JSON Parameters - -It is possible to pass JSON data using a `POST`, `PUT` or `PATCH` -request. To do that the `Content-Type` header has to be set to -`application/json`. The JSON will be parsed as an array. The first level -keys will be used to pass in the arguments, e.g.: - ----- -POST /index.php/apps/myapp/authors -Content-Type: application/json -{ - "name": "test", - "number": 3, - "publisher": true, - "customFields": { - "mail": "test@example.com", - "address": "Somewhere" - } -} ----- - -[source,php] ----- - "test@example.com", "address" => "Somewhere"] - } -} ----- - -=== Reading Headers, Files, Cookies and Environment Variables - -Headers, files, cookies, and environment variables can be accessed -directly from the request object: - -[source,php] ----- -request->getHeader('Content-Type'); // $_SERVER['HTTP_CONTENT_TYPE'] - $cookie = $this->request->getCookie('myCookie'); // $_COOKIES['myCookie'] - $file = $this->request->getUploadedFile('myfile'); // $_FILES['myfile'] - $env = $this->request->getEnv('SOME_VAR'); // $_ENV['SOME_VAR'] - } -} ----- - -Why should those values be accessed from the request object and not from -the global array like `$_FILES`? Simple: -http://c2.com/cgi/wiki?GlobalVariablesAreBad[because it’s bad practice] -and will make testing harder. - -=== Reading and Writing Session Variables - -To set, get or modify session variables, the `ISession` object has to be -injected into the controller. Then session variables can be accessed -like this: - -The session is closed automatically for writing, unless you add the -`@UseSession` annotation! - -[source,php] ----- -session = $session; - } - - /** - * The following annotation is only needed for writing session values - * @UseSession - */ - public function writeASessionVariable() { - // read a session variable - $value = $this->session['value']; - - // write a session variable - $this->session['value'] = 'new value'; - } -} ----- - -=== Setting Cookies - -Cookies can be set or modified directly on the response class: - -[source,php] ----- -addCookie('foo', 'bar'); - $response->addCookie('bar', 'foo', new DateTime('2015-01-01 00:00')); - return $response; - } - - /** - * Invalidates the cookie "foo" - * Invalidates the cookie "bar" and "bazinga" - */ - public function invalidateCookie() { - $response = new TemplateResponse(...); - $response->invalidateCookie('foo'); - $response->invalidateCookies(['bar', 'bazinga']); - return $response; - } -} ----- - - -== Responses - -Similar to how every controller receives a request object, every -controller method has to to return a Response. This can be in the form -of a `Response` subclass or in the form of a value that can be handled -by a registered responder. - -=== JSON - -Returning JSON is simple, just pass an array to a `JSONResponse`: - -[source,php] ----- - 'hi']; - return new JSONResponse($params); - } -} ----- - -Because returning JSON is such an common task, there’s even a shorter -way to do this: - -[source,php] ----- - 'hi']; - } -} ----- - -Why does this work? Because the dispatcher sees that the controller did -not return a subclass of a `Response` and asks the controller to turn -the value into a `Response`. That’s where responders come in. - -=== Responders - -Responders are short functions that take a value and return a response. -They are used to return different kinds of responses based on a `format` -parameter which is supplied by the client. Think of an API that is able -to return both XML and JSON depending on if you call the URL with: - ----- -?format=xml ----- - -or: - ----- -?format=json ----- - -The appropriate responder is being chosen by the following criteria: - -* First the dispatcher checks the Request if there is a `format` -parameter, e.g.: -+ ----- -?format=xml ----- - -or: - ----- -/index.php/apps/myapp/authors.{format} ----- - -* If there is none, take the `Accept` header, use the first mimetype and -cut off `application/`. In the following example the format would be -XML: -+ ----- -Accept: application/xml, application/json ----- -* If there is no Accept header or the responder does not exist, format -defaults to `json`. - -By default there is only a responder for JSON but more can be added -easily: - -[source,php] ----- -registerResponder('xml', function($value) { - if ($value instanceof DataResponse) { - return new XMLResponse( - $value->getData(), - $value->getStatus(), - $value->getHeaders() - ); - } else { - return new XMLResponse($value); - } - }); - - return ['test' => 'hi']; - } - -} ----- - -The above example would only return XML if the `format` parameter was -`XML`. If you want to return an XMLResponse regardless of the format -parameter, extend the Response class and return a new instance of it -from the controller method instead. - -Because returning values works fine in case of a success but not in case -of failure that requires a custom HTTP error code, you can always wrap -the value in a `DataResponse`. This works for both normal responses and -error responses. - -[source,php] ----- - 'not found!'], Http::STATUS_NOT_FOUND); - } - } - -} ----- - -=== Templates - -A template can be rendered by returning a -`TemplateResponse`. A `TemplateResponse` takes the following parameters: - -* `appName`: tells the template engine in which application the template -should be located -* `templateName`: the name of the template inside the `template/` folder -without the .php extension -* `parameters`: optional array parameters that are available in the -template through $_, e.g.: -+ ----- -['key' => 'something'] ----- - -can be accessed through: - ----- -$_['key'] ----- - -* `renderAs`: defaults to `user`, tells ownCloud if it should include it -in the web interface, or in case blank is passed solely render the -template - -[source,php] ----- - 'hi']; - return new TemplateResponse($this->appName, $templateName, $parameters); - } -} ----- - -=== Redirects - -A redirect can be achieved by returning a `RedirectResponse`: - -[source,php] ----- -addHeader('Content-Type', 'application/xml'); - $this->xml = $xml; - } - - public function render() { - $root = new SimpleXMLElement(''); - array_walk_recursive($this->xml, [$root, 'addChild']); - return $xml->asXML(); - } -} ----- - -=== Streamed and Lazily Rendered Responses - -By default all responses are rendered at once and sent as a string -through middleware. In certain cases this is not a desirable behavior, -for instance if you want to stream a file in order to save memory. To do -that, use the `OCP\\AppFramework\\Http\\StreamResponse` class: - -[source,php] ----- -addAllowedImageDomain('*'); - ->addAllowedMediaDomain('*'); - $response->setContentSecurityPolicy($csp); - } -} ----- - -OCS -~~~ - -This is purely for compatibility reasons. If you are planning to offer -an external API, go for a api instead. - -In order to ease migration from OCS API routes to the application -Framework, an additional controller and response have been added. To -migrate your API you can use the `OCP\\AppFramework\\OCSController` base -class and return your data in the form of an array in the following way: - -[source,php] ----- - [ - // actual data is in here - ], - // optional - 'statuscode' => 100, - 'status' => 'OK' - ]; - } -} ----- - -The format parameter works out of the box, no intervention is required. - -=== Handling Errors - -Sometimes a request should fail, for instance if an author with id 1 is -requested but does not exist. In that case use an appropriate -https://en.wikipedia.org/wiki/List_of_HTTP_status_codes#4xx_client_errors[HTTP -error code] to signal the client that an error occurred. - -Each response subclass has access to the `setStatus` method which lets -you set an HTTP status code. To return a `JSONResponse` signaling that -the author with id 1 has not been found, use the following code: - -[source,php] ----- -index()` method should not -check the CSRF token because it has not yet been sent to the client and -because of that can’t work. To turn off checks the following -_Annotations_ can be added before the controller: - -* `@NoAdminRequired`: Also users that are not admins can access the page -* `@NoSubAdminRequired`: Allow normal users access to the page -* `@NoCSRFRequired`: Don’t check the CSRF token - -CAUTION: Use this wisely since as you might create a security hole. To understand what it does see xref:general/security.adoc[the Security Guidelines]. - -* `@PublicPage`: Everyone can access the page without having to log in - -A controller method that turns off all checks would look like this: - -[source,php] ----- - -
Your navigation
-
-
- Your content in here -
-
- ----- - -For built in mobile support your content has to be wrapped inside -another div with the id `app-content-wrapper`. - -== Navigation - -ownCloud provides a default CSS navigation layout. If list entries -should have 16x16 px icons, the `with-icon` class can be added to the -base `ul`. The maximum supported indention level is two; we do not -recommend further indentations. - -[source,html] ----- - ----- - -=== Folders - -Folders are like normal entries and are only supported for the first -level. In contrast to standard entries, the links which show the title -of the folder need to have the `icon-folder` CSS class. - -If the folder should be collapsible, the `collapsible` class and a -button with the class `collapse` are needed. After adding the -collapsible class the folder’s child entries can be toggled by adding -the `open` class to the list element: - -[source,html] ----- - ----- - -=== Drag and Drop - -The class which should be applied to a first level element (`li`) that -hosts or can host a second level is `drag-and-drop`. This will cause the -hovered entry to slide down giving a visual hint that it can accept the -dragged element. In the case of jQuery UI’s droppable feature, the -`hoverClass` option should be set to the `drag-and-drop` class. - -[source,html] ----- - ----- - -=== Menus - -To add actions that affect the current list element, you can add a menu -for second and/or first level elements by adding the button and menu -inside the corresponding `li` element and adding the `with-menu` CSS -class: - -[source,html] ----- -
-
----- - -The div with the class `app-navigation-entry-utils` contains only the -button (class: `app-navigation-entry-utils-menu-button`) to display the -menu but in many cases, another entry is needed to display some sort of -count (mails count, unread feed count, etc.). In that case, add the -`with-counter` class to the list entry to adjust the correct padding and -text-overflow of the entry’s title. - -The count should be limited to 999 and turn to 999+ if any higher number -is given. If AngularJS is used the following filter can be used to get -the correct behavior: - -[source,js] ----- -app.filter('counterFormatter', function () { - 'use strict'; - return function (count) { - if (count > 999) { - return '999+'; - } - return count; - }; -}); ----- - -Use it like this: - -[source,html] ----- -
  • {{ count | counterFormatter }}
  • ----- - -The menu is hidden by default (`display: none`) and has to be triggered -by adding the `open` class to the `app-navigation-entry-menu` div. In -the case of AngularJS the following small directive can be added to -handle all the display and click logic out of the box: - -[source,js] ----- -app.run(function ($document, $rootScope) { - 'use strict'; - $document.click(function (event) { - $rootScope.$broadcast('documentClicked', event); - }); -}); - -app.directive('appNavigationEntryUtils', function () { - 'use strict'; - return { - restrict: 'C', - function (scope, elm) { - var menu = elm.siblings('.app-navigation-entry-menu'); - var button = $(elm) - .find('.app-navigation-entry-utils-menu-button button'); - - button.click(function () { - menu.toggleClass('open'); - }); - - scope.$on('documentClicked', function (scope, event) { - if (event.target !== button[0]) { - menu.removeClass('open'); - } - }); - } - }; -}); ----- - -=== Editing - -Often an edit option is needed for an entry. To add one for a given -entry simply hide the title and add the following div inside the entry: - -[source,html] ----- -
    - -
    ----- - -If AngularJS is used you want to auto-focus the input box. This can be -achieved by placing the show condition inside an `ng-if` on the -`app-navigation-entry-edit` div and adding the following directive: - -[source,js] ----- -app.directive('autofocusOnInsert', function () { - 'use strict'; - return function (scope, elm) { - elm.focus(); - }; -}); ----- - -`ng-if` is required because it removes/inserts the element into the DOM -dynamically instead of just adding a `display: none` to it like -`ng-show` and `ng-hide`. - -=== Undo Entry - -If you want to undo a performed action on a navigation entry such as -deletion, you should show the undo directly in place of the entry and -make it disappear after location change or seven seconds: - -[source,html] ----- -
    - -
    ----- - -== Settings Area - -To create a settings area create a div with the id `app-settings` inside -the `app-navgiation` div: - -[source,html] ----- -
    - -
    - - - -
    -
    - -
    -
    - -
    -
    -
    -
    ----- - -The data attribute `data-apps-slide-toggle` slides up a target area -using a jQuery selector and hides the area if the user clicks outside of -it. - -== Icons - -To use icons which are shipped in core, special classes to apply the -background image are supplied. All of these classes use -`background-position: center` and `background-repeat: no-repeat`. - -|=== -| Name | Image - -| icon-breadcrumb -| image:img/7/breadcrumb.png[image] - -| icon-loading -| image:img/7/loading.png[image] - -| icon-loading-dark -| image:img/7/loading-dark.png[image] - -| icon-loading-small -| image:img/7/loading-small.png[image] - -| icon-add -| image:img/7/actions/add.png[image] - -| icon-caret -| image:img/7/actions/caret.png[image] - -| icon-caret-dark -| image:img/7/actions/caret-dark.png[image] - -| icon-checkmark -| image:img/7/actions/checkmark.png[image] - -| icon-checkmark-white -| image:img/7/actions/checkmark-white.png[image] - -| icon-clock -| image:img/7/actions/clock.png[image] - -| icon-close -| image:img/7/actions/close.png[image] - -| icon-confirm -| image:img/7/actions/confirm.png[image] - -| icon-delete -| image:img/7/actions/delete.png[image] - -| icon-download -| image:img/7/actions/download.png[image] - -| icon-history -| image:img/7/actions/history.png[image] - -| icon-info -| image:img/7/actions/info.png[image] - -| icon-lock -| image:img/7/actions/lock.png[image] - -| icon-logout -| image:img/7/actions/logout.png[image] - -| icon-mail -| image:img/7/actions/mail.png[image] - -| icon-more -| image:img/7/actions/more.png[image] - -| icon-password -| image:img/7/actions/password.png[image] - -| icon-pause -| image:img/7/actions/pause.png[image] - -| icon-pause-big -| image:img/7/actions/pause-big.png[image] - -| icon-play -| image:img/7/actions/play.png[image] - -| icon-play-add -| image:img/7/actions/play-add.png[image] - -| icon-play-big -| image:img/7/actions/play-big.png[image] - -| icon-play-next -| image:img/7/actions/play-next.png[image] - -| icon-play-previous -| image:img/7/actions/play-previous.png[image] - -| icon-public -| image:img/7/actions/public.png[image] - -| icon-rename -| image:img/7/actions/rename.png[image] - -| icon-search -| image:img/7/actions/search.png[image] - -| icon-settings -| image:img/7/actions/settings.png[image] - -| icon-share -| image:img/7/actions/share.png[image] - -| icon-shared -| image:img/7/actions/shared.png[image] - -| icon-sound -| image:img/7/actions/sound.png[image] - -| icon-sound-off -| image:img/7/actions/sound-off.png[image] - -| icon-star -| image:img/7/actions/star.png[image] - -| icon-starred -| image:img/7/actions/starred.png[image] - -| icon-toggle -| image:img/7/actions/toggle.png[image] - -| icon-triangle-e -| image:img/7/actions/triangle-e.png[image] - -| icon-triangle-n -| image:img/7/actions/triangle-n.png[image] - -| icon-triangle-s -| image:img/7/actions/triangle-s.png[image] - -| icon-upload -| image:img/7/actions/upload.png[image] - -| icon-upload-white -| image:img/7/actions/upload-white.png[image] - -| icon-user -| image:img/7/actions/user.png[image] - -| icon-view-close -| image:img/7/actions/view-close.png[image] - -| icon-view-next -| image:img/7/actions/view-next.png[image] - -| icon-view-pause -| image:img/7/actions/view-pause.png[image] - -| icon-view-play -| image:img/7/actions/view-play.png[image] - -| icon-view-previous -| image:img/7/actions/view-previous.png[image] - -| icon-calendar-dark -| image:img/7/places/calendar-dark.png[image] - -| icon-contacts-dark -| image:img/7/places/contacts-dark.png[image] - -| icon-file -| image:img/7/places/file.png[image] - -| icon-files -| image:img/7/places/files.png[image] - -| icon-folder -| image:img/7/places/folder.png[image] - -| icon-filetype-text -| image:img/7/filetypes/text.png[image] - -| icon-filetype-folder -| image:img/7/filetypes/folder.png[image] - -| icon-home -| image:img/7/places/home.png[image] - -| icon-link -| image:img/7/places/link.png[image] - -| icon-music -| image:img/7/places/music.png[image] - -| icon-picture -| image:img/7/places/picture.png[image] -|=== - diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/database.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/database.adoc deleted file mode 100644 index 42e2d89..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/database.adoc +++ /dev/null @@ -1,240 +0,0 @@ -= Database Connectivity -:toc: right -:xml-scheme-notation-url: https://pear.php.net/manual/en/package.database.mdb2-schema.xml-schema-documentation.php -:dbal-class-schema-url: https://www.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/schema-representation.html#schema-representation - -== Database Access - -The basic way to run a database query is to use the database connection provided by `OCP\\IDBConnection`. -Inside your database layer class you can now start running queries like: - -[source,php] ----- -include::example$app/fundamentals/database/database-access.php[] ----- - -== Database Programming Guidelines - -* Always use the Query Builder. -* Don't update more than 1 million rows within a transaction due to DB limitations. -* Don't add more than 999 conditions in a `WHERE ... IN ...` statement but chunk it into separate queries when using SQLite. -* When processing big tables, always do this in chunks, don't store the whole table in memory. -* Oracle compatibility specifics: -** For Oracle, `null` and empty strings are the same thing. Special handling is required to catch these cases. -** When reading values, make sure to convert nulls to empty strings when expected. -** When using a condition based on empty strings, use `is not null` with Oracle instead. -** Oracle can only compare the first 4000 bytes of a `CLOB` column. -** Make sure to properly escape column names when using custom functions with `createFunction`. The escaping is usually done automatically by the query builder. Oracle is the most likely to complain about unquoted columns while other databases will work fine. -** Always add the table name when calling `lastInsertId($tableName)`, as it is required by Oracle to return correct values. -* In general, don't specify a value for an `autoincrement` column. If you have to, keep in mind that Oracle's `autoincrement` trigger will get in the way on `INSERT`. As a result, you'll need a subsequent `UPDATE` to properly adjust the value. -* *Always* make sure there are unit tests for the database operations with queries to verify the result. This will help find out whether the database related code works on all databases and often times might reveal database quirks. -* Running unit tests with specific databases: `make test-php TEST_PHP_SUITE=path/to/test/file.php TEST_DATABASE=$databasetype` where "$databasetype" is one of "sqlite", "mysql", "mariadb", "pgsql", "oci" and "mysqlmb4". -* String concatenation should be done like this: -** `CONCAT(str1, str2, ... strN)` for MYSQL. -** `str1 || str1 ... || strN` SQLite/pgSQL/Oracle. -* Use `IQueryBuilder::createPositionalParameter` instead of `IQueryBuilder::createNamedParameter` when using `like()`. - -== Mappers - -The aforementioned example is the most basic way to write a simple database query but the more queries amass, the more code has to be written and the harder it will become to maintain it. - -To generalize and simplify the problem, split code into resources and create an `Entity` and a `Mapper` class for it. -The mapper class provides a way to run SQL queries and maps the result onto the related entities. - -To create a mapper, inherit from the mapper baseclass and call the parent constructor with the following parameters: - -* Database connection -* Table name -* *Optional*: Entity class name, defaults to `\\OCA\\MyApp\\Db\\Author` -in the example below - -[source,php] ----- -include::example$app/fundamentals/database/authormapper.php[] ----- - -The cursor is closed automatically for all *INSERT*, *DELETE*, *UPDATE* queries and when calling the methods *findOneQuery*, *findEntities*, *findEntity*, *delete*, *insert* and *update*. -For custom calls using execute you should always close the cursor after you are done with the fetching to prevent database lock problems on SqLite - -Every mapper also implements default methods for deleting and updating an entity based on its id: - ----- -$authorMapper->delete($entity); ----- - -or: - ----- -$authorMapper->update($entity); ----- - -== Entities - -Entities are data objects that carry all the table’s information for one row. -Every Entity has an `id` field by default that is set to the integer type. -Table rows are mapped from lower case and underscore separated names to pascal case attributes: - -* *Table column name*: phone_number -* *Property name*: phoneNumber - -[source,php] ----- -include::example$app/fundamentals/database/author.php[] ----- - -== Types - -The following properties should be annotated by types, to not only assure that the types are converted correctly for storing them in the database (e.g., PHP casts false to the empty string which fails on PostgreSQL) but also for casting them when they are retrieved from the database. - -The following types can be added for a field: - -* integer -* float -* boolean - -== Accessing attributes - -Since all attributes should be protected, getters and setters are automatically generated for you: - -[source,php] ----- -include::example$app/fundamentals/database/author-access-attributes.php[] ----- - -== Custom Attribute to Database Column Mapping - -By default each attribute will be mapped to a database column by a certain convention, e.g. `phoneNumber` will be mapped to the column `phone_number` and vice versa. -Sometimes it is needed though to map attributes to different columns because of backwards compatibility. -To define a custom mapping, simply override the `columnToProperty` and `propertyToColumn` methods of the entity in question: - -[source,php] ----- -include::example$app/fundamentals/database/custom-attribute-to-database-column-mapping.php[] ----- - -== Slugs - -Slugs are used to identify resources in the URL by a string rather than integer id. -Since the URL allows only certain values, the entity `baseclass` provides a `slugify` method for it: - -[source,php] ----- -include::example$app/fundamentals/database/slug.php[] ----- - -== Database Migrations - -ownCloud uses migration steps to perform changes between releases. -In most cases, these changes relate to the core database schema. -However, other types of changes may be required. -Therefore we support three kinds of migration steps, these are: - -* *Simple:* run general migration steps. - These are quite similar to the xref:app/fundamentals/info.adoc#repair-steps[migration repair steps]. -* *SQL:* create a list of executable SQL commands. -* *Schema:* migration via schema migration operations. - -Starting with ownCloud Classic 10, this is the preferred way to perform any kind of migrations and is enabled by default within core. -Any app which wants to use this mechanism has to enable it in appinfo/info.xml, by adding the following: - -[source,xml] ----- -true ----- - -IMPORTANT: If migrations are enabled then appinfo/database.xml is ignored. -From this point onwards, when an app is installed or upgraded, all outstanding migrations are executed. -Below is a migration code sample for creating an application’s core table. - -[source,php] ----- -include::example$app/fundamentals/database/migrations.php[] ----- - -You can see examples of how to create the three migration types in the next section. - -It is still necessary to increment the application’s version number to trigger the execution of migrations. - -=== How to Create a Migration - -1. Enable migrations by adding the XML tag to appinfo/info.xml - -[source,xml] ----- -true ----- - -1. Create a migration step - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrations:generate app-name {simple, SQL, schema} ----- - -=== A Simple Migration Step - -The simple migration step skeleton looks like this: - -[source,php] ----- -include::example$app/fundamentals/database/create-migration-step.php[] ----- - -=== A SQL Migration Step - -A SQL migration step skeleton looks like this: - -[source,php] ----- -include::example$app/fundamentals/database/sql-migration-step.php[] ----- - -Within the `sql()` method you can generate any number of SQL commands. -The generated commands will be returned as an array, and the statements will be executed afterward. - -Please do not execute any generated SQL statements directly on the database. - -The parameter `$connection` can be used to retrieve a database platform object or to test if tables exist. -In order to create cross-compatible SQL code, please use the platform object or generate SQL commands for each supported database system. - -=== A Schema Migration Step - -A schema migration step skeleton looks like this: - -[source,php] ----- -include::example$app/fundamentals/database/schema-migration-step.php[] ----- - -Within the `changeSchema()` method, you can use the {dbal-class-schema-url}[Class Schema] to manipulate the existing database schema. -This is the preferred way to manipulate the schema. - -1. Test your migration step - -[source,bash,subs="attributes+"] ----- -{occ-command-example-prefix} migrations:execute dav 20161130090952 ----- - -Because all migration steps will be executed upon installation, there is no explicit need for unit tests. - -1. Deploy the migration(s) - -To trigger the migrations, the app version has to be increased. -Doing so applies all steps which have not yet been executed. - -== How to Update the Database Schema - -TIP: The recommended method for updating the database is to use xref:database-migrations[migrations]. - -ownCloud uses a database abstraction layer on top of {php-net-url}/manual/en/book.pdo.php[PDO], depending on its availability on the server. The database schema is contained in `appinfo/database.xml`, and uses MDB2’s {xml-scheme-notation-url}[XML scheme notation]. The placeholders `dbprefix` (*PREFIX* in your SQL) and `dbname` can be used for the configured database table prefix and database name. - -An example database XML file would look like this: - -[source,xml] ----- -include::example$app/fundamentals/database/schema-update.xml[] ----- - -To update the tables used by the app: adjust the `database.xml` file to reflect the changes which you want to make. -Then, increment the app version number in appinfo/info.xml to trigger an update. diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/filesystem.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/filesystem.adoc deleted file mode 100644 index 7cd6b98..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/filesystem.adoc +++ /dev/null @@ -1,119 +0,0 @@ -= Filesystem - -Because users can choose their storage backend, the filesystem should be -accessed by using the appropriate filesystem classes. Filesystem classes -can be injected from the `ServerContainer` by calling the method -`getRootFolder()`, `getUserFolder()` or `getAppFolder()`: - -[source,php] ----- -getContainer(); - - /** - * Storage Layer - */ - $container->registerService('AuthorStorage', function($c) { - return new AuthorStorage($c->query('RootStorage')); - }); - - $container->registerService('RootStorage', function($c) { - return $c->query('ServerContainer')->getRootFolder(); - }); - - } -} ----- - -== Writing to a File - -All methods return a Folder object on which files and folders can be -accessed, or filesystem operations can be performed relatively to their -root. For instance for writing to `owncloud/data/myfile.txt` you should -get the root folder and use: - -[source,php] ----- -storage = $storage; - } - - public function writeTxt($content) { - // check if file exists and write to it if possible - try { - try { - $file = $this->storage->get('/myfile.txt'); - } catch(\OCP\Files\NotFoundException $e) { - $file = $this->storage->newFile('/myfile.txt'); - } - - // the id can be accessed by $file->getId(); - $file->putContent($content); - - } catch(\OCP\Files\NotPermittedException $e) { - // you have to create this exception by yourself ;) - throw new StorageException('Cant write to file'); - } - } -} ----- - -== Reading from a File - -Files and folders can also be accessed by id, by calling the `getById` -method on the folder. - -[source,php] ----- -storage = $storage; - } - - public function getContent($id) { - // check if file exists and write to it if possible - try { - $file = $this->storage->getById($id); - if($file instanceof \OCP\Files\File) { - return $file->getContent(); - } else { - throw new StorageException('Can not read from folder'); - } - } catch(\OCP\Files\NotFoundException $e) { - throw new StorageException('File does not exist'); - } - } -} ----- - -== How to Get the Storage Owner Using a File Id - -A storage's owner can be retrieved using a file id, as in the following example. - -[source,php] ----- -include::example$app/fundamentals/filesystem/getOwnerByFileId.php[] ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/hooks.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/hooks.adoc deleted file mode 100644 index 5579b83..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/hooks.adoc +++ /dev/null @@ -1,176 +0,0 @@ -= Hooks - -Hooks are used to execute code before or after an event has occurred. -This is for instance useful to run cleanup code after users, groups or -files have been deleted. Hooks should be xref:app/tutorial/development_environment.adoc#appinfoinfo-xml[registered in the app.php]: - -[source,php] ----- -getContainer()->query('UserHooks')->register(); ----- - -The hook logic should be in a separate class that is being registered in -the container - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('UserHooks', function($c) { - return new UserHooks( - $c->query('ServerContainer')->getUserManager() - ); - }); - } -} ----- - -[source,php] ----- -userManager = $userManager; - } - - public function register() { - $callback = function($user) { - // your code that executes before $user is deleted - }; - $this->userManager->listen('\OC\User', 'preDelete', $callback); - } - -} ----- - -== Available Hooks - -The scope is the first parameter that is passed to the `listen` method, -the second parameter is the method and the third one the callback that -should be executed once the hook is being called, e.g.: - -[source,php] ----- -listen('\OC\User', 'preDelete', $callback); ----- - -Hooks can also be removed by using the `removeListener` method on the -object: - -[source,php] ----- -removeListener(null, null, $callback); ----- - -The following hooks are available: - -=== Session - -Injectable from the `ServerContainer` by calling the method -`getUserSession()`. - -Hooks available in scope `\\OC\\User`: - -* `preSetPassword` (\OC\User\User $user, string $password, string -$recoverPassword) -* `postSetPassword` (\OC\User\User $user, string $password, string -$recoverPassword) -* `preDelete` (\OC\User\User $user) -* `postDelete` (\OC\User\User $user) -* `preCreateUser` (string $uid, string $password) -* `postCreateUser` (\OC\User\User $user) -* `preLogin` (string $user, string $password) -* `postLogin` (\OC\User\User $user) -* `failedLogin` (string $user) -* `logout` () - -=== UserManager - -Injectable from the `ServerContainer` by calling the method -`getUserManager()`. - -Hooks available in scope `\\OC\\User`: - -* `preSetPassword` (\OC\User\User $user, string $password, string -$recoverPassword) -* `postSetPassword` (\OC\User\User $user, string $password, string -$recoverPassword) -* `preDelete` (\OC\User\User $user) -* `postDelete` (\OC\User\User $user) -* `preCreateUser` (string $uid, string $password) -* `postCreateUser` (\OC\User\User $user, string $password) - -=== GroupManager - -Hooks available in scope `\\OC\\Group`: - -* `preAddUser` (\OC\Group\Group $group, \OC\User\User $user) -* `postAddUser` (\OC\Group\Group $group, \OC\User\User $user) -* `preRemoveUser` (\OC\Group\Group $group, \OC\User\User $user) -* `postRemoveUser` (\OC\Group\Group $group, \OC\User\User $user) -* `preDelete` (\OC\Group\Group $group) -* `postDelete` (\OC\Group\Group $group) -* `preCreate` (string $groupId) -* `postCreate` (\OC\Group\Group $group) - -=== Filesystem Root - -Injectable from the `ServerContainer` by calling the method -`getRootFolder()`, `getUserFolder()` or `getAppFolder()`. - -Filesystem hooks available in scope `\\OC\\Files`: - -* `preWrite` (\OCP\Files\Node $node) -* `postWrite` (\OCP\Files\Node $node) -* `preCreate` (\OCP\Files\Node $node) -* `postCreate` (\OCP\Files\Node $node) -* `preDelete` (\OCP\Files\Node $node) -* `postDelete` (\OCP\Files\Node $node) -* `preTouch` (\OCP\Files\Node $node, int $mtime) -* `postTouch` (\OCP\Files\Node $node) -* `preCopy` (\OCP\Files\Node $source, \OCP\Files\Node $target) -* `postCopy` (\OCP\Files\Node $source, \OCP\Files\Node $target) -* `preRename` (\OCP\Files\Node $source, \OCP\Files\Node $target) -* `postRename` (\OCP\Files\Node $source, \OCP\Files\Node $target) - -=== Filesystem Scanner - -Filesystem scanner hooks available in scope -`\\OC\\Files\\Utils\\Scanner`: - -* `scanFile` (string $absolutePath) -* `scanFolder` (string $absolutePath) -* `postScanFile` (string $absolutePath) -* `postScanFolder` (string $absolutePath) diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/index.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/index.adoc deleted file mode 100644 index 3f0ca9a..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/index.adoc +++ /dev/null @@ -1,3 +0,0 @@ -= Application Development - Fundamental Details - -In this section, you will find the fundamental details for developing an ownCloud application. diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/info.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/info.adoc deleted file mode 100644 index 89f71b2..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/info.adoc +++ /dev/null @@ -1,293 +0,0 @@ -= Application Metadata -:markdown-cheatsheet-url: https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet - -The appinfo/info.xml contains metadata about the application. In this -section, you will find a complete example configuration, along with an -explanation of what each of file's elements. - -[source,xml,subs="attributes+"] ----- -include::partial$app/fundamentals/complete-info.xml[] ----- - -== id - -*Required*. This field contains the internal application name, and has -to be the same as the folder name of the application. This id needs to -be unique in ownCloud, meaning no other application should have this id. -This value also represents the URL your application is available on the -marketplace. - -== name - -*Required*. This is the human-readable name (or title) of the -application that will be displayed in the application overview page. - -== description - -*Required*. The description provides all the necessary information about the application, and is shown in the application overview page. -Don't get lost in technical details, focus on the benefits which the application offers. -You can use {markdown-cheatsheet-url}[markdown] to format the description. - -NOTE: Max. 4000 characters. - -== version - -This sets the version of your application. - -== licence - -*Required*. The sets the application's license. This license must be -compatible with the AGPL and *must not be proprietary*. - -Two good examples are: - -* AGPL 3 (recommended) -* MIT - -If a proprietary/non-AGPL compatible license must be used, then you have -to use the https://owncloud.com/pricing/[ownCloud Enterprise Edition]. - -== author - -*Required*. The name of the application's author or authors. - -== namespace - -Required if `routes.php` returns an array. For example, if your -application is namespaced, e.g., -`\\OCA\\MyApp\\Controller\\PageController`, then the required namespace -value is `MyApp`. If a namespace is not provided, the application tries -to default to the first letter upper-cased application id, e.g., `myapp` -would be tried under `Myapp`. - -== category - -The ownCloud Marketplace category where you want to publish the application. -The following categories are available: - -[width="52%",cols="50%,50%",options="header",] -|================ -| Category Name -| Value to Use - -| Automation -| automation - -| Collaboration -| collaboration - -| Customization -| customization - -| External plugins -| external-plugins - -| Games -| games - -| Integration -| integration - -| Multimedia -| multimedia - -| Productivity -| productivity - -| Security -| security - -| Storage -| storage - -| Tools -| tools -|================ - -[IMPORTANT] -==== -For publishing themes the category tag must be present — _but empty_ — as in the example below. - -[source,xml] ----- - ----- -==== - -== summary - -*Required*. Provide a short application description (max. 90 chars). -This gets displayed below the product title and on the product tiles. It -is mandatory since ownCloud Classic 10.0.0. - -== types - -ownCloud supports five types. These are: - -* `prelogin`: applications which need to load on the login page -* `filesystem`: applications which provide filesystem functionality -(e.g., file-sharing applications) -* `authentication`: applications which provide authentication backends -* `logging`: applications which implement a logging system -* `prevent_group_restriction`: applications which can not be enabled for -specific groups (e.g., notifications app). - -`prevent_group_restriction` was introduced with ownCloud 9.0. It can be -used in earlier versions, but the functionality will be ignored. - -Due to technical reasons applications of any type listed above can not -be enabled for specific groups only. - -== documentation - -*Required*. Link to _admin_, _user_, and _developer_ documentation. -Common places are: (where `$name` is the name of your app, e.g. -`$name=theapp`) - -[source,xml] ----- -$DOCUMENTATION_BASE = 'https://doc.owncloud.com'; -$DOCUMENTATION_DEVELOPER = $DOCUMENTATION_BASE.'/server/'.$VERSIONS_SERVER_MAJOR_DEV_DOCS.'/developer_manual/$name/';` -$DOCUMENTATION_ADMIN = $DOCUMENTATION_BASE.'/server/'.$VERSIONS_SERVER_MAJOR_STABLE.'/admin_manual/$name/'; -$DOCUMENTATION_USER = $DOCUMENTATION_BASE.'/server/'.$VERSIONS_SERVER_MAJOR_STABLE.'/classic_ui/$name/'; ----- - -These places are maintained at -https://github.com/owncloud/documentation/. Another popular starting -point for developer documentation is the README.md in GitHub. - -== website - -*Required*. A link to the project's web page. - -== repository - -*Required*. A link to the version control repository. - -== bugs - -*Required*. A link to the bug tracker, if any. - -== Dependencies - -All tags within the dependencies tag define a set of requirements which -have to be fulfilled in order to operate properly. As soon as one of -these requirements is not met the application cannot be installed. - -== php - -Defines the minimum and the maximum version of PHP required to run this -application. - -== database - -Each supported database has to be listed here. Valid values are -`sqlite`, `mysql`, `pgsql`, `oci` and `mssql`. In the future it will be -possible to specify versions here as well. In case no database is -specified it is assumed that all databases are supported. - -== command - -Defines a command line tool to be available. With the attribute `os` the -required operating system for this tool can be specified. Valid values -for the `os` attribute are as returned by the php function -{php-net-url}/manual/en/function.php-uname.php[php_uname]. - -== lib - -Defines a required PHP extension with a required minimum and/or maximum -version. The names for the libraries have to match the result as -returned by the php function -{php-net-url}/manual/en/function.get-loaded-extensions.php[get_loaded_extensions]. -The explicit version of an extension is read from -{php-net-url}/manual/de/function.phpversion.php[phpversion] - with some -exception as to be read up in the -https://github.com/owncloud/core/blob/master/lib/private/App/PlatformRepository.php#L43[code base] - -== os - -Defines the required target operating system the application can run on. -Valid values are as returned by the php function -{php-net-url}/manual/en/function.php-uname.php[php_uname]. - -== owncloud - -Defines the minimum and maximum versions of ownCloud core. - -IMPORTANT: This will be mandatory from version 11 onwards. - -== repair-steps - -Defines when to execute repair steps, both for ownCloud and for installed apps. - -=== pre-migration - -Execute repair steps before a database migration. - -=== post-migration - -Execute repair steps after a database migration. - -=== live-migration - -Execute repair steps as background jobs, asynchronously after migration, in live operations - -=== install - -Execute repair steps during installation. - -=== uninstall - -Execute repair steps during uninstallation. - -== Deprecated - -The following sections are listed just for reference and should not be -used because: - -* *public/remote*: Use api instead because you'll have to use xref:core/apis/externalapi.adoc[the external API], which is known to be buggy. It only works properly with GET/POST requests. -* *standalone/default_enable*: They tell core what do on setup, you will not be able to even activate your application if it has those entries. - -This should be replaced by a config file inside core. - -== public - -Used to provide a public interface (requires no login) for the -application. The id is appended to the URL `/owncloud/index.php/public`. -Example with id set to `calendar': - ----- -/owncloud/index.php/public/calendar ----- - -Also take a look at xref:core/apis/externalapi.adoc[the external API]. - -== remote - -Same as public, but requires login. The id is appended to the URL -`/owncloud/index.php/remote`. Example with id set to `calendar': - ----- -/owncloud/index.php/remote/calendar ----- - -Also take a look at xref:core/apis/externalapi.adoc[the external API]. - -== standalone - -Can be set to `true` to indicate that this application is a web -application. This can be used to tell GNOME Web for instance to treat -this like a native application. - -== default_enable - -*Core applications only*: Used to tell ownCloud to enable them after the -installation. - -== shipped - -*Core applications only*: Used to tell ownCloud that the application is -in the standard release. Please note that if this attribute is set to -`FALSE` or not set at all, every time you disable the application, all -the files of the application itself will be _REMOVED_ from the server! diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/js.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/js.adoc deleted file mode 100644 index ffe8b47..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/js.adoc +++ /dev/null @@ -1,156 +0,0 @@ -= JavaScript - -The JavaScript files reside in the `js/` folder and should be included -in the template: - -[source,php] ----- -getEventDispatcher(); -$eventDispatcher->addListener('OCA\Files::loadAdditionalScripts', function() { - script('myapp', 'script'); // adds js/script.js - vendor_script('myapp', 'script'); // adds vendor/script.js -}); ----- - -== Sending the CSRF Token - -If any other JavaScript request library than jQuery is being used, the -requests need to send the CSRF token as an HTTP header named -`requesttoken`. The token is available in the global variable -`oc_requesttoken`. For AngularJS the following lines would need to be -added: - -[source,js] ----- -var app = angular.module('MyApp', []).config(['$httpProvider', function($httpProvider) { - $httpProvider.defaults.headers.common.requesttoken = oc_requesttoken; -}]); ----- - -== Generating URLs - -To send requests to ownCloud the base URL where ownCloud is currently -running is needed. To get the base URL use: - -[source,js] ----- -var baseUrl = OC.generateUrl(`); ----- - -Full URLs can be generated by using: - -[source,js] ----- -var authorUrl = OC.generateUrl('/apps/myapp/authors/1'); ----- - -== Extending Core Parts - -It is possible to extend components of the core web UI. The following -examples should show how this is possible. - -== Extending the `new` Menu in the Files App - -[source,js] ----- -var myFileMenuPlugin = { - attach: function (menu) { - menu.addMenuEntry({ - id: 'abc', - displayName: 'Menu display name', - templateName: 'templateName.ext', - iconClass: 'icon-filetype-text', - fileType: 'file', - actionHandler: function () { - console.log('do something here'); - } - }); - } -}; -OC.Plugins.register('OCA.Files.NewFileMenu', myFileMenuPlugin); ----- - -This will register a new menu entry in the `New` menu of the files -app. The method `attach()` is called once the menu is built. This -usually happens right after the click on the button. - -== Registering file actions - -[source,js] ----- -var myFileListPlugin = { - attach: function(fileList) { - var fileActions = fileList.fileActions; - fileActions.registerAction({ - name: 'exampleActionName', - displayName: 'Action display name', - altText: 'Alt Text', - mime: 'text/plain', - permissions: OC.PERMISSION_READ, - iconClass: 'icon-details', - type: OCA.Files.FileActions.TYPE_DROPDOWN, - actionHandler: function(fileName) { - // handle action - }, - render: function(actionSpec, isDefault, context) { - // handle rendering - } - }); - } -}; -OC.Plugins.register('OCA.Files.FileList', myFileListPlugin); ----- - -This will register an action for all files having the mime type -`text/plain`. - -The `permissions` property defines which permissions are needed -to perform this action. The following permissions are available: - -* `OC.PERMISSION_READ` -* `OC.PERMISSION_CREATE` -* `OC.PERMISSION_UPDATE` -* `OC.PERMISSION_DELETE` -* `OC.PERMISSION_SHARE` -* `OC.PERMISSION_ALL` - -The `type` property defines where the action will be displayed. -There are currently two options available: - -* `OCA.Files.FileActions.TYPE_DROPDOWN` in the 3-dots-menu of the file -* `OCA.Files.FileActions.TYPE_INLINE` in the table row - -=== Setting file actions as default - -A file action can be set as default action that will be triggered -when clicking on the file. The next example sets the action from -above as default: - -[source,js] ----- -fileActions.setDefault('text/plain', 'exampleActionName'); ----- - -As the example shows, this is also possible for specific -mime types only. - -In case multiple actions have been set as default for one -mime type, ownCloud will show a context menu when clicking -on the file. diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/logging.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/logging.adoc deleted file mode 100644 index 9a7d251..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/logging.adoc +++ /dev/null @@ -1,122 +0,0 @@ -= Logging -:ig-url: https://labs.ig.com/logging-level-wrong-abstraction -:keywords: logging -:description: This guide introduces you to logging when developing custom ownCloud applications. - -The logger can be injected from the `ServerContainer`: - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('AuthorService', function($c) { - return new AuthorService( - $c->query('Logger'), - $c->query('AppName') - ); - }); - - $container->registerService('Logger', function($c) { - return $c->query('ServerContainer')->getLogger(); - }); - } -} ----- - -Once injected, it can then be used in the following way: - -[source,php] ----- -logger = $logger; - $this->appName = $appName; - } - - public function log($message) { - $this->logger->error($message, ['app' => $this->appName]); - } - -} ----- - -The following methods are available: - -* `emergency` -* `alert` -* `critical` -* `error` -* `warning` -* `notice` -* `info` -* `debug` - -== Which Logging Level Should You Use? - -When considering which logging level to use, please refer to this guide from {ig-url}[IG]: - -DEBUG:: Information that is useful during development. Usually very chatty, and will not show in production. -INFO:: Information you will need to debug production issues. -WARN (warning):: Someone in the team will have to investigate what happened, but it can wait until tomorrow. -ERROR:: Oh-oh, call the fireman! This needs to be investigated *now!* - -== Usage Examples - -The following example shows how to log a simple text string, to the level of info. -Methods are available which match the other seven log levels. - -[source,php] ----- -logger->info('Entity has changed state.'); ----- - -The following example shows how to log a text string that makes use of string interpolation, and additional JSON fields. - -[source,php] ----- -logger->info('Entity {entityName} has changed state to {newState}', [ - // these are used for text substitution in the above message - 'entityName' => 'X', - 'newState' => 'state2', - // these will appear as additional JSON fields in the log entries - 'extraFields' => [ - 'entityName' => 'X', - 'oldState' => 'state1', - 'newState' => 'state2', - 'entityOwner' => 'someuser', - ], -]); ----- - -== Further Reading - -* xref:admin_manual:configuration/server/logging/logging_configuration.adoc#parameters[ownCloud Logging Configuration documentation]. diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/market_app.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/market_app.adoc deleted file mode 100644 index f9d11d9..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/market_app.adoc +++ /dev/null @@ -1,20 +0,0 @@ -= Market App - -Since ownCloud X (10.0.0) every ownCloud instance gets shipped with the -market app. This app makes it easy to manage your applications out of -the box. To connect your market app with the ownCloud Marketplace: - -* Get you API key under `My Account` -* Inside the market app go to menu:Settings[] -* Paste your API key and click on btn:[Save] - -You are now able to maintain any app in -`downloads/installations/updates` from your ownCloud installation directly. - -== ownCloud Instances in Protected Environments (DMZ) - -To use the market app your ownCloud instance must have an internet -connection. If your instance is running in a protected environment (DMZ -or similar) you cannot use the market app. You need to upload the apps -manually in this case. Every app can be downloaded manually from the -marketplace. diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/middleware.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/middleware.adoc deleted file mode 100644 index 370d06c..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/middleware.adoc +++ /dev/null @@ -1,161 +0,0 @@ -= Middleware - -Middleware is logic that is run before and after each request and is -modelled after -https://docs.djangoproject.com/en/dev/topics/http/middleware/[Django’s -Middleware system]. It offers the following hooks: - -* *beforeController*: This is executed before a controller method is -being executed. This allows you to plug additional checks or logic -before that method, like for instance security checks -* *afterException*: This is being run when either the beforeController -method or the controller method itself is throwing an exception. The -middleware is asked in reverse order to handle the exception and to -return a response. If the middleware can’t handle the exception, it -throws the exception again -* *afterController*: This is being run after a successful controller -method call and allows the manipulation of a Response object. The -middleware is run in reverse order -* *beforeOutput*: This is being run after the response object has been -rendered and allows the manipulation of the outputted text. The -middleware is run in reverse order - -To generate your own middleware, simply inherit from the Middleware -class and overwrite the methods that should be used. - -[source,php] ----- -getContainer(); - - /** - * Middleware - */ - $container->registerService('CensorMiddleware', function($c){ - return new CensorMiddleware(); - }); - - // executed in the order that it is registered - $container->registerMiddleware('CensorMiddleware'); - - } -} ----- - -The order is important! The middleware that is registered first gets run -first in the `beforeController` method. For all other hooks, the order -is being reversed, meaning: if a middleware is registered first, it gets -run last. - -== Parsing Annotations - -Sometimes its useful to conditionally execute code before or after a -controller method. This can be done by defining custom annotations. An -example would be to add a custom authentication method or simply add an -additional header to the response. To access the parsed annotations, -inject the `ControllerMethodReflector` class: - -[source,php] ----- -reflector = $reflector; - } - - /** - * Add custom header if @MyHeader is used - */ - public function afterController($controller, $methodName, IResponse $response){ - if($this->reflector->hasAnnotation('MyHeader')) { - $response->addHeader('My-Header', 3); - } - return $response; - } - -} ----- - -Now adjust the container to inject the reflector: - -[source,php] ----- -getContainer(); - - /** - * Middleware - */ - $container->registerService('HeaderMiddleware', function($c){ - return new HeaderMiddleware($c->query('ControllerMethodReflector')); - }); - - // executed in the order that it is registered - $container->registerMiddleware('HeaderMiddleware'); - } - -} ----- - -An annotation always starts with an uppercase letter. diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/notes.md b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/notes.md deleted file mode 100644 index 62f00db..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/notes.md +++ /dev/null @@ -1,53 +0,0 @@ -owncloud_1 | {"reqId":"QveYQCJXFHyu5nmspxBE","level":3,"time":"2017-07-20T09:28:33+00:00","remoteAddr":"172.19.0.1","user":"admin","app":"index","method":"GET","url":"\/index.php","message":"Exception: {\"Exception\":\"Error\",\"Message\":\"Class 'OCA\\\\FailedLogins\\\\AppInfo\\\\Application' not found\",\"Code\":0,\"Trace\":\"#0 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/Route\\\/Router.php(353): include_once()\\n#1 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/Route\\\/Router.php(151): OC\\\\Route\\\\Router->requireRouteFile('\\\/var\\\/www\\\/ownclo...', 'testapp')\\n#2 \\\/var\\\/www\\\/owncloud\\\/lib\\\/private\\\/Route\\\/Router.php(270): OC\\\\Route\\\\Router->loadRoutes()\\n#3 \\\/var\\\/www\\\/owncloud\\\/lib\\\/base.php(918): OC\\\\Route\\\\Router->match('')\\n#4 \\\/var\\\/www\\\/owncloud\\\/index.php(49): OC::handleRequest()\\n#5 {main}\",\"File\":\"\\\/var\\\/www\\\/owncloud\\\/apps\\\/testapp\\\/appinfo\\\/routes.php\",\"Line\":5}"} - - -www-data@48688230c458: ~/owncloud # ./occ upgrade -ownCloud or one of the apps require upgrade - only a limited number of commands are available -You may use your browser or the occ upgrade command to do the upgrade -Set log level to debug -Turned on maintenance mode -Repair warning: You have incompatible or missing apps enabled that could not be found or updated via the marketplace. -Repair warning: please install app manually with tarball or disable them with: -occ app:disable testapp -OC\RepairException: Upgrade is not possible -Update failed -Maintenance mode is kept active -Reset log level - - -www-data@48688230c458: ~/owncloud # ./occ app:disable testapp -ownCloud or one of the apps require upgrade - only a limited number of commands are available -You may use your browser or the occ upgrade command to do the upgrade -testapp disabled - - -www-data@48688230c458: ~/owncloud # ./occ upgrade -ownCloud or one of the apps require upgrade - only a limited number of commands are available -You may use your browser or the occ upgrade command to do the upgrade -Set log level to debug -Updating database schema -Updated database -Updating ... -Updated to 0.0.2 -Drop old database tables - - Done - 28/28 [============================] 100% -Fix permissions so avatars can be stored again - Done - 2/2 [============================] 100% -Starting code integrity check... -Finished code integrity check -Update successful -Maintenance mode is kept active -Reset log level - - -www-data@48688230c458: ~/owncloud # ./occ maintenance:mode --off -ownCloud is in maintenance mode - no app have been loaded - -Maintenance mode disabled - -## Notes - -After you change a route definition, you seem to need to upgrade diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/publishing.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/publishing.adoc deleted file mode 100644 index a55b47e..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/publishing.adoc +++ /dev/null @@ -1,325 +0,0 @@ -= Publishing in the ownCloud Marketplace - -== The ownCloud Marketplace - -With the ownCloud marketplace, introduced in 2017, we offer a flexible -and easy way to publish your apps and extend your ownCloud. In addition -every ownCloud gets shipped with the new market app which makes it -possible to manage apps directly out of your running ownCloud instance. -Connected with the ownCloud marketplace it mirrors your marketplace -account and provides an easy way to install and update apps. - -The process of publishing apps aims to be: - -* Secure -* Transparent -* Welcoming -* Fair -* Easy to maintain - -Apps in the store are divided into three levels of trust: - -* Official -* Approved -* Experimental - -With each level come requirements and a position in the store. - -=== Official - -Official apps are developed by and within the ownCloud community and its -https://github.com/owncloud[Github] repository and offer functionality -central to ownCloud. They are ready for serious use and can be -considered a part of ownCloud. - -Requirements: - -* Developed in the ownCloud GitHub repo. -* Minimum of 2 active maintainers and contributions from others. -* Security audited and design reviewed. -* App is at least six months old and has seen regular releases. -* Follows app guidelines. -* Supports the same platforms and technologies mentioned in the release -notes of the ownCloud version this app is made for. - -ownCloud Marketplace: - -* Available in Apps page in a separate category. -* Sorted first in all overviews, `Official` tag. -* Shown as featured on https://owncloud.com, etc. -* Major releases optionally featured in the news section on https://owncloud.com -owncloud-announce list. -* New versions/updates approved by at least one other person. - -Official apps include those that are part of the release tarball. We’d -like to keep the tarball minimal, so most official apps are not part of -the standard installation. - -=== Approved - -Approved apps are developed by trusted developers and have passed a -cursory security check. They are actively maintained in an open code -repository, and their maintainers deem them to be stable for casual to -normal use. - -Requirements: - -* Code is developed in an open and version-managed code repository, -ideally GitHub, with git. But other VCS’ and hosting options are also OK. -* Minimum of one active developer/maintainer. -* Minimum 5 ratings, average score 60/100 or better. -* App is at least three months old. -* Follows app guidelines. -* The developer is trusted. -* App is subject to unannounced security audits. -* Has defined requirements and dependencies (like what browsers, -databases, PHP versions and so on are supported). - -*Developer trust*: The developer(s) is/are known in the community; -he/she has/have been active for a while, have met others at events -and/or worked with others in various areas. - -*Security audits*: in practice, this means that at least some of the -code of this developer has been audited; either through another app by -the same developer or with an earlier version of the app. And that the -attitude of the developer towards these audits has been positive. - -ownCloud Marketplace: - -* Visible in ownCloud Marketplace by default -* Sorted above experimental apps -* Search results sorted by ratings -* Developer can directly push new versions to the store -* Warning shows for security/stability risks - -=== Experimental - -Apps which have not been checked at all for security and/or are new, -known to be unstable or under heavy development. - -Requirements: - -* No malicious intent found from this developer at any time -* 0 confirmed security problems -* Less than three unconfirmed `security flags' -* Rating over 20/100 - -ownCloud Marketplace: - -* Show up in Apps page provided user has enabled `allow installation of -experimental apps` in the settings. -* Warning about security and stability risks is shown for app -* Sorted below all others. - -== App Categories - -The following categories are available for apps to be filed under: - -* Automation -* Collaboration -* Customization -* External plugins -* Games -* Integration -* Multimedia -* Productivity -* Security -* Storage -* Tools - -To make your app available under one of these categories, please make -sure to user the proper tag in your `info.xml`: - -[source,xml] ----- -security ----- - -Note: For publishing themes, this tag must be present but empty. - -[source,xml] ----- - ----- - -== App Tags - -Besides these categories apps can have different tags: - -* Enterprise -* Verified -* Trusted - -=== Enterprise - -Apps with the `Enterprise` tag are official ownCloud enterprise apps. -These can only be uploaded by ownCloud itself and represent ownCloud -Enterprise Edition features. - -.ownCloud "Enterprise" tag -image:app/app-tile-enterprise.jpg[The ownCloud 'Enterprise' Tag] - -=== Verified - -To get the `verified` label on your app, you must request a review. We -then will look into your app and check if it meets the ownCloud app -development guidelines (see below). The advantages of verified apps are -that: - -* they are labeled with `verified` badge. -* they are available in apps page in separate category. -* only verified apps can be displayed in the `featured` area. -* major releases optionally featured in the news section on https://owncloud.com - -.ownCloud "Verified" tag -image:app/app-tile-verified.jpg[ownCloud 'Verified' tag] - -=== Trusted - -If your app reaches a rating level of 4 or higher based on 40 ratings or -more it automatically gets the badge `trusted`. It represents a -community oriented level of quality which makes it more attractive to -other users. The advantages of trusted apps are that: - -* they are labeled with `trusted` badge. -* the user can filter by trusted apps. - -== App Review Process - -To request an app review go to menu:Account[My Products > Edit app] and click on the -button btn:[Request review]. Usually, it takes 3-5 -work days to review your app. You will be notified about the result. - -If it is successful, your app will get the `verified` badge. Please be -aware of when uploading a new release to a verified app, you need to -request a new review for the new release. To keep your verified badge, -request the review before setting your new release to `published`. - -== App Guidelines - -The following are the guidelines your app should follow to provide a -high quality. - -=== Legal and Security - -* Apps can not use `ownCloud` in their name -* Irregular and unannounced security audits of all apps can and will take place. -* If any indication of malicious intent or bad faith is found the -developer(s) in question can count on a minimum two-year ban from any ownCloud infrastructure. -* Malicious intent includes deliberate spying on users by leaking user -data to a third party system or adding a back door (like a hard coded -user account) to ownCloud. An unintentional security bug that gets fixed -in time won’t be considered bad faith. -* Apps do not violate any laws; it has to comply with copyright- and trademark law. -* App authors have to respond timely to security concerns and not make -ownCloud more vulnerable to attack. - -Distributing malicious or illegal applications can have legal -consequences including, but not limited to ownCloud or affected users -taking legal action. - -=== Technical - -* Apps can only use the public ownCloud API -* At time of the release of an app, it can only be configured to be -compatible with the latest ownCloud release +1 -* Apps should not cause ownCloud to break, consume excessive memory or slow ownCloud down -* Apps should not hamper functionality of ownCloud unless that is explicitly the goal of the app - -=== Providing Information - -When uploading an app, it should provide a professional and informative -look and feel. To do so, please consider the following three points: - -* The title of your app can be up to 50 characters. Provide a unique -name, which makes it easy for users to identify the product. Do not -include your developer and/or company name in the title. -* The summary of your app can be up to 90 characters. Provide a short -description. This will be displayed below the product titles. -* The description of your app can be up to 4000 characters and supports -Markdown formatting. It should, ideally, provide all the necessary -information about your app — especially information necessary to -convince the user to download, use, and buy your app. So, don’t get lost -in technical details. Explain in simple, yet precise, steps what the -user will get. When writing, focus on the benefits your app offers. - -=== Images - -* Provide meaningful images to your users. -* For best results, images should be 1400px wide and should go with a -rough aspect ratio of 2:1 -* The first image provided in your apps info.xml will be used as the -preview image and is displayed in the top area of your marketplace app -page. - -=== Respect the Users - -* Apps have to follow design and HTML/CSS layout guidelines -* Apps correctly clean up after themselves on uninstall and correctly -handle up- and downgrades -* Apps communicate their intended purpose and active features, including -features introduced through updates. -* Apps respect the users’ choices and do not make unexpected changes, or -limit users’ ability to revert them. For example, they do not remove -other apps or disable settings. -* Apps must respect user privacy. If user data is sent anywhere, this -must be explained and be kept to a minimum for the functioning of an -app. Use proper security measures when needed. - -== Disclaimer - -ownCloud reserves the right to block and/or delete any uploaded app -which does not comply with the ownCloud quality standards. Additionally, -we reserve the right to ban publishers who attempt to upload malicious -code. This does not depend on whether it happens intentionally or not. - -== Available Products Tags - -.Available Product Tags -[cols="15%,85%",options="header"] -|=== -| Tag | Description - -| id -| A unique id. URL of your app will be based on this. - -| name -| The name/title of your app; Max. 50 characters; Provide a concise name so users can identify your app easily; Do not include your developers/company name. - -| summary -| Provide a short description (max. 90 chars). This gets displayed below the product title and on the product tiles; mandatory since ownCloud Classic 10.0.0. - -| description -| Max. 4000 characters; Provide all necessary, detailed information about the product. This should contain all user relevant information. Don’t get lost in technical details, focus on the benefits the product offers; Also, use markdown to layout your description. - -| license -a| At the moment following license are available: - -- https://en.wikipedia.org/wiki/Open_Content_License[OCL] -- https://owncloud.com/licenses/owncloud-commercial/[ownCloud Commercial License] -+ -NOTE: This is for ownCloud Enterprise Apps *only* -- https://en.wikipedia.org/wiki/Affero_General_Public_License[AGPL] -- https://en.wikipedia.org/wiki/MIT_License[MIT License]. - -NOTE: To overwrite a release (using the same version number) it must be in state `planned`. -Once published, you cannot replace a release. - -| category -| The category you want to publish your app in; For all available categories see above. - -| screenshot -| Image URL; insert multiple tags if you want to include multiple images; Note: marketplace will store images in its own file system. You do not need to provide the images on you own hosted area after the upload. - -| dependencies -a| Min and max version of ownCloud platform your app works with. For example: -[source,xml] ----- - - - ----- - -NOTE: For a complete list of tags see: xref:app/fundamentals/info.adoc[]. -|=== - diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/routes.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/routes.adoc deleted file mode 100644 index 8019bf5..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/routes.adoc +++ /dev/null @@ -1,310 +0,0 @@ -= Routing - -Routes map a URL and a method to a controller method. Routes are defined -inside appinfo/routes.php by passing a configuration array to the -`registerRoutes` method. An example route would look like this: - -[source,php] ----- -registerRoutes($this, [ - 'routes' => [ - ['name' => 'page#index', 'url' => '/', 'verb' => 'GET'], - ] -]); ----- - -The route array contains the following parts: - -- `url`: The URL that is matched after `/index.php/apps/myapp` ` `name`: -The controller and the method to call; `page#index` is being mapped to -`PageController->index()`, `articles_api#drop_latest` would be mapped to -`ArticlesApiController->dropLatest()`. The controller that matches the -`page#index` name would have to be registered in the following way -inside `lib/AppInfo/Application.php`: - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('PageController', function($c) { - return new PageController( - $c->query('AppName'), - $c->query('Request') - ); - }); - } - -} ----- - -- `method` (Optional, defaults to `GET`): The HTTP method that should be -matched, (e.g., `GET`, `POST`, `PUT`, `DELETE`, `HEAD`, `OPTIONS`, -`PATCH`) ` `requirements` (Optional): lets you match and extract URLs -that have slashes in them (see `Matching suburls`) ` `postfix` -(Optional): lets you define a route id postfix. Since each route name -will be transformed to a route id (`page#method` -> `myapp.page.method`) -and the route id can only exist once you can use the postfix option to -alter the route id creation by adding a string to the route id e.g.: -`'name' => 'page#method', 'postfix' => 'test'` will yield the route id -`myapp.page.methodtest`. This makes it possible to add more than one -route/url for a controller method ` `defaults` (Optional): If this -setting is given, a default value will be assumed for each URL parameter -which is not present. The default values are passed in as a key => value -par array - -== Extracting Values From the URL - -It is possible to extract values from the URL to allow for RESTful URL -design. To extract value, you have to wrap it inside curly braces: - -[source,php] ----- - 'author#show', 'url' => '/authors/{id}', 'verb' => 'GET'], - -// controller/authorcontroller.php -class AuthorController { - - public function show($id) { - // $id is '3' - } - -} ----- - -The identifier used inside the route is being passed into the controller -method by reflecting the method parameters. To summarize, if you want to -get the value of `\{id\}` in your method, you need to add `$id` to your -method parameters. - -== Matching Sub-URLs - -Sometimes you need to match more than one URL fragment. An example of -this would be to match a request for all URLs that start with -`OPTIONS /index.php/apps/myapp/api`. To do this, use the `requirements` -parameter in your route, which is an array containing pairs of -`'key' => 'regex'`: - -[source,php] ----- - 'author_api#cors', - 'url' => '/api/{path}', - 'verb' => 'OPTIONS', - 'requirements' => ['path' => '.+'] -], - -// controller/authorapicontroller.php -class AuthorApiController { - - public function cors($path) { - // $path will be 'my/route' - } - -} ----- - -== Default Values for Sub-URL - -Apart from matching requirements, a sub-URL may also have a default -value. Say you want to support pagination (a `page' parameter) for your -`/posts` sub-URL that displays posts entries list. You may set a default -value for the `page' parameter, that will be used if not already set in -the URL. Use the `defaults` parameter in your route which is an array -containing pairs of `'urlparameter' => 'defaultvalue'`: - -[source,php] ----- - 'post#index', - 'url' => '/post/{page}', - 'verb' => 'GET', - 'defaults' => ['page' => 1] // this allows same url as /index.php/myapp/post/1 -], - -// controller/postcontroller.php -class PostController -{ - public function index($page = 1) - { - // $page will be 1 - } -} ----- - -== Registering Resources - -When dealing with resources, writing routes can become quite repetitive -since most of the time routes for the following tasks are needed: - -* Get all entries -* Get one entry by id -* Create an entry -* Update an entry -* Delete an entry - -To prevent repetition, it’s possible to define resources. The following -routes: - -[source,php] ----- -registerRoutes($this, [ - 'routes' => [ - ['name' => 'author#index', 'url' => '/authors', 'verb' => 'GET'], - ['name' => 'author#show', 'url' => '/authors/{id}', 'verb' => 'GET'], - ['name' => 'author#create', 'url' => '/authors', 'verb' => 'POST'], - ['name' => 'author#update', 'url' => '/authors/{id}', 'verb' => 'PUT'], - ['name' => 'author#destroy', 'url' => '/authors/{id}', 'verb' => 'DELETE'], - // your other routes here - ] -]); ----- - -can be abbreviated by using the `resources` key: - -[source,php] ----- -registerRoutes($this, [ - 'resources' => [ - 'author' => ['url' => '/authors'] - ], - 'routes' => [ - // your other routes here - ] -]); ----- - -== Using the URLGenerator - -Sometimes its useful to turn a route into a URL 1) to make the code -independent from the URL design or to 2) generate an URL for an image in -`img/`. For those use cases, the `ServerContainer` provides a service -that can be used in your container: - -[source,php] ----- -getContainer(); - - /** - * Controllers - */ - $container->registerService('PageController', function($c) { - return new PageController( - $c->query('AppName'), - $c->query('Request'), - - // inject the URLGenerator into the page controller - $c->query('ServerContainer')->getURLGenerator() - ); - }); - } - -} ----- - -Inside the `PageController` the URL generator can now be used to -generate an URL for a redirect: - -[source,php] ----- -urlGenerator = $urlGenerator; - } - - /** - * redirect to /apps/news/myapp/authors/3 - */ - public function redirect() { - // route name: author_api#do_something - // route url: /apps/news/myapp/authors/{id} - - // # needs to be replaced with a . due to limitations and prefixed - // with your app id - $route = 'myapp.author_api.do_something'; - $parameters = array('id' => 3); - - $url = $this->urlGenerator->linkToRoute($route, $parameters); - - return new RedirectResponse($url); - } - -} ----- - -`URLGenerator` is case-sensitive, so `appName` must match `exactly` the -name you use in configuration . If you use a camel-case -name as _myCamelCaseApp_, - -[source,php] ----- - are available -in an array called `$_[]`, e.g.: - ----- -array('key' => 'something') ----- - -can be accessed through: - ----- -$_['key'] ----- - -To prevent XSS the following PHP *functions for printing are forbidden: -echo, print() and -

    -inc('templateName')` method. - -[source,php] ----- -inc('sub.inc')); ?> ----- - -The parent variables will also be available in the included templates, -but should you require it, you can also pass new variables to it by -using the second optional parameter as array for `$this->inc`. - -templates/sub.inc.php - -[source,php] ----- -
    I am included, but I can still access the parents variables!
    - - -inc('other_template', array('variable' => 'value'))); ?> ----- - -== Including CSS and JavaScript - -To include CSS or JavaScript use the `style` and `script` functions: - -[source,php] ----- -" /> ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/testing.adoc b/content/server/10.15/modules/developer_manual/pages/app/fundamentals/testing.adoc deleted file mode 100644 index 3987d24..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/fundamentals/testing.adoc +++ /dev/null @@ -1,109 +0,0 @@ -= Testing - -All PHP classes can be tested with http://phpunit.de/[PHPUnit], -JavaScript can be tested by using -http://karma-runner.github.io/0.12/index.html[Karma]. - -PHP ---- - -The PHP tests go into the `tests/` directory. Unfortunately the -classloader in core requires a running server (as in a fully configured -and running setup up with a database connection). This is, -unfortunately, too complicated and slow so a separate classloader has to -be provided. - -When writing your own tests, please ensure that PHPUnit bootstraps from -tests/bootstrap.php, to set up various environment variables and -autoloader registration correctly. Without this, you will see errors as -the ownCloud autoloader security policy prevents access to the `tests/` -subdirectory. This can be configured in your phpunit.xml file as -follows: - -[source,xml] ----- - ----- - -PHP classes should be tested by accessing them from the container to -ensure that the container is wired up properly. Services that should be -mocked can be replaced directly in the container. A test for the -`AuthorStorage` class in filesystem: - -[source,php] ----- -storage = $storage; - } - - public function getContent($id) { - // check if file exists and write to it if possible - try { - $file = $this->storage->getById($id); - if($file instanceof \OCP\Files\File) { - return $file->getContent(); - } else { - throw new StorageException('Can not read from folder'); - } - } catch(\OCP\Files\NotFoundException $e) { - throw new StorageException('File does not exist'); - } - } -} ----- - -would look like this: - -[source,php] ----- -container = $app->getContainer(); - $this->storage = $storage = $this->getMockBuilder('\OCP\Files\Folder') - ->disableOriginalConstructor() - ->getMock(); - - $this->container->registerService('RootStorage', function($c) use ($storage) { - return $storage; - }); - } - - /** - * @expectedException \OCA\MyApp\Storage\StorageException - */ - public function testFileNotFound() { - $this->storage->expects($this->once()) - ->method('get') - ->with($this->equalTo(3)) - ->will($this->throwException(new \OCP\Files\NotFoundException())); - - $this->container['AuthorStorage']->getContent(3); - } - -} ----- - -Make sure to extend the `\Test\TestCase` class with your test and always -call the parent methods, when overwriting `setUp()`, -`setUpBeforeClass()`, `tearDown()` or `tearDownAfterClass()` method from -the TestCase. These methods set up important stuff and clean up the -system after the test, so the next test can run without side effects, -like remaining files and entries in the file cache, etc. diff --git a/content/server/10.15/modules/developer_manual/pages/app/introduction.adoc b/content/server/10.15/modules/developer_manual/pages/app/introduction.adoc deleted file mode 100644 index 0b3e276..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/introduction.adoc +++ /dev/null @@ -1,28 +0,0 @@ -= Introduction - -ownCloud applications let you extend and build on the power of ownCloud, -taking it in ways that work just for your specific use-case(s). - -While not overly complex in nature, like any form of software -development, it will take some time to become fully knowledgeable on the -parts that make up and application, how they fit together, and how to -make best use of them. - -This section of the documentation’s been designed to make that process -as simple and as effective as possible, by both stepping you through the -information in a tutorial-fashion, as well as providing you a -significant amount of background technical knowledge. - -You’ll learn how an application works by building one. It won’t do -absolutely everything that you could possibly hope to cover. But it will -teach you the ins and outs of building one, providing links to further -information, which you can work through later. - -Before you start developing an ownCloud application, please check that -there isn’t an application in the -{oc-marketplace-url}/[ownCloud Marketplace], or an official -{oc-marketplace-url}/publishers/owncloud[ownCloud app] that -already does what you need. If there is, we strongly encourage you to -contribute to existing applications before investing the time to develop -your own. Also, feel free to communicate your idea and plans at our -https://talk.owncloud.com[chat system], so other contributors might join in. diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/database_connectivity.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/database_connectivity.adoc deleted file mode 100644 index 373211d..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/database_connectivity.adoc +++ /dev/null @@ -1,549 +0,0 @@ -= Database Connectivity - -== The Database Schema - -TIP: The recommended method for managing the database schema is to use xref:app/fundamentals/database.adoc#database-migrations[migrations]. - -Now that the application’s routes and two controllers have been setup and wired together, we’ll flesh out `NotesController` so that the notes can be saved in the database. -But to do that, we first need to create xref:app/fundamentals/database.adoc[the database schema] by creating `ownnotes/appinfo/database.xml`, with the following content: - -[source,xml] ----- - - *dbname* - true - false - utf8 - - *dbprefix*ownnotes_notes - - - id - integer - true - true - true - true - 8 - - - title - text - 200 - - true - - - user_id - text - 200 - - true - - - content - clob - - true - - -
    -
    ----- - -The schema consists of one table: `ownnotes_notes`, which has four -fields: - -* *id:* An integer -* *title:* A text field -* *user_id:* A text field -* **content:** A CLOB field - -With the file created, xref:app/tutorial/development_environment.adoc#appinfoinfo-xml[the version tag] in `ownnotes/appinfo/info.xml` needs to be increased. -This causes ownCloud to trigger the update process when you next load (or reload) the ownCloud UI. -Part of the update process includes run database migrations, which will create the database table defined in the migration above. - -== Data Entities - -Now that the tables are created, we want to map the database search results to a PHP object. -That way, we’re able to manage the data more precisely. -To do that, xref:app/fundamentals/database.adoc[create an entity] in new file, called: `ownnotes/lib/Db/Note.php`: - -[source,php] ----- - $this->id, - 'title' => $this->title, - 'content' => $this->content - ]; - } - -} ----- - -The `id` field exists in the `Entity` - -We also define a `jsonSerializable` method and implement the interface, -so that we’re able to transform the entity to JSON, making it easy to -persist and cache the information. - -== Data Mappers - -Entities are returned from so-called xref:app/fundamentals/database.adoc[data mappers]. -https://martinfowler.com/eaaCatalog/dataMapper.html[Data mappers are]: - -"" -A layer of Mappers (473) that moves data between objects and a database -while keeping them independent of each other and the mapper itself. -"" - -Let’s create one in `ownnotes/lib/Db/NoteMapper.php` and add a `find` -and `findAll` method: - -[source,php] ----- -findEntity($sql, [$id, $userId]); - } - - public function findAll($userId) { - $sql = 'SELECT * FROM *PREFIX*ownnotes_notes WHERE user_id = ?'; - return $this->findEntities($sql, [$userId]); - } - -} ----- - -The first parent constructor parameter is the database connection object -(or database handle), the second one is the database table and the third -is the entity which the result should be mapped onto. Insert, delete and -update methods are already implemented. - -== Connecting Databases & Controllers - -Now the mapper is finished and can be passed into the controller. -You can do so by adding it as a type-hinted parameter. -ownCloud will figure out how to assemble them by itself. - -Additionally we want to know the `userId` of the currently logged in -user. To do so, add a `$UserId` parameter to the constructor, which is -case-sensitive. Open `ownnotes/lib/Controller/NoteController.php` and -change it to the following: - -[source,php] ----- -mapper = $mapper; - $this->userId = $UserId; - } - - } ----- - -With the constructor defined, we now need to flesh out the rest of the -methods, which we previously didn’t define bodies for. In `index`, -below, we’ll return a `DataResponse` object, which contains the result -of using the Data Mapper’s `findAll` method. - -This method, which is supplied with the current user’s id, retrieves all -notes created by that user. A `DataResponse` object is used to return -generic data responses. It provides a more generic response than -`JSONResponse`, which also works with JSON data. - -[source,php] ----- -/** - * @NoAdminRequired - */ -public function index() { - return new DataResponse($this->mapper->findAll($this->userId)); -} ----- - -Next, we’ll flesh out the `show` function. This function will retrieve -and return the details for a specific note. It does so by using the data -mapper’s find method, which is supplied with the note’s and user’s ids. -If the note cannot be retrieved, then a `DataResponse` is returned, -which results in a 404 Not Found response. - -[source,php] ----- -/** - * @NoAdminRequired - * - * @param int $id - */ -public function show($id) { - try { - return new DataResponse($this->mapper->find($id, $this->userId)); - } catch(Exception $e) { - return new DataResponse([], Http::STATUS_NOT_FOUND); - } -} ----- - -Next, we’ll flesh out the create method, so that we can create notes. -This method receives the note’s title and content from the route and -sets them, along with the current user’s id, on a new `Note` entity -object. The function returns the result of calling the data mapper’s -insert method, which attempts to persist the Note entity in the -database. - -[source,php] ----- -/** - * @NoAdminRequired - * - * @param string $title - * @param string $content - */ -public function create($title, $content) { - $note = new Note(); - $note->setTitle($title); - $note->setContent($content); - $note->setUserId($this->userId); - - return new DataResponse($this->mapper->insert($note)); -} ----- - -Next we’ll flesh out the update function, which updates an existing -note. Similar to the `create` method, it receives the note’s id, title, -and content from the route. It then attempts to retrieve the note, and -throws an exception if it’s unable to do so. If it can retrieve it, it -then updates the title and content, and returns the response from -calling the data mapper’s `update` function. - -[source,php] ----- -/** - * @NoAdminRequired - * - * @param int $id - * @param string $title - * @param string $content - */ -public function update($id, $title, $content) { - try { - $note = $this->mapper->find($id, $this->userId); - } catch(Exception $e) { - return new DataResponse([], Http::STATUS_NOT_FOUND); - } - $note->setTitle($title); - $note->setContent($content); - return new DataResponse($this->mapper->update($note)); -} ----- - -Finally, we’ll flesh out the `destroy` function, which deletes an -existing note. This, like `update`, will first attempt to retrieve a -note, based on the supplied id, and throw an exception if it’s not able -to be found. If it’s able to be found, it will then be passed to the -data mapper’s `delete` function, which will delete the note from the -database. - -[source,php] ----- -/** - * @NoAdminRequired - * - * @param int $id - */ -public function destroy($id) { - try { - $note = $this->mapper->find($id, $this->userId); - } catch(Exception $e) { - return new DataResponse([], Http::STATUS_NOT_FOUND); - } - $this->mapper->delete($note); - return new DataResponse($note); -} ----- - -This is all that is needed on the server side. Now let’s progress to the -client side. - -== Decoupling Controllers and Increasing Reusability - -Let’s now say that our app is now on the ownCloud Marketplace, and we -get a request that we should save the files in the filesystem which -requires access to the filesystem. - -The filesystem API is quite different from the database API and throws -different exceptions, which means we need to rewrite everything in the -`NoteController` class to use it. - -This is bad, because a controller’s only responsibility should be to -deal with incoming HTTP requests and return HTTP responses. If we need -to change the controller because the data storage was changed the code -is probably too tightly coupled. So we need to add another layer in -between, a layer called `Service`. - -Let’s take the logic that was inside the controller and put it into a -separate class inside `ownnotes/lib/Service/NoteService.php`: - -[source,php] ----- -mapper = $mapper; - } - - public function findAll($userId) { - return $this->mapper->findAll($userId); - } - - private function handleException ($e) { - if ($e instanceof DoesNotExistException || - $e instanceof MultipleObjectsReturnedException) { - throw new NotFoundException($e->getMessage()); - } else { - throw $e; - } - } - - public function find($id, $userId) { - try { - return $this->mapper->find($id, $userId); - - // In order to be able to plug in different storage backends like files - // for instance it is a good idea to turn storage related exceptions - // into service related exceptions so controllers and service users - // have to deal with only one type of exception - } catch(Exception $e) { - $this->handleException($e); - } - } - - public function create($title, $content, $userId) { - $note = new Note(); - $note->setTitle($title); - $note->setContent($content); - $note->setUserId($userId); - return $this->mapper->insert($note); - } - - public function update($id, $title, $content, $userId) { - try { - $note = $this->mapper->find($id, $userId); - $note->setTitle($title); - $note->setContent($content); - return $this->mapper->update($note); - } catch(Exception $e) { - $this->handleException($e); - } - } - - public function delete($id, $userId) { - try { - $note = $this->mapper->find($id, $userId); - $this->mapper->delete($note); - return $note; - } catch(Exception $e) { - $this->handleException($e); - } - } - -} ----- - -Following that, create an exception class in `ownnotes/lib/Service/ServiceException.php`: - -[source,php] ----- - $e->getMessage()]; - return new DataResponse($message, Http::STATUS_NOT_FOUND); - } - } - -} ----- - -Now we can wire up the trait and the service inside the -`NoteController`: - -[source,php] ----- -service = $service; - $this->userId = $UserId; - } - - /** - * @NoAdminRequired - */ - public function index() { - return new DataResponse($this->service->findAll($this->userId)); - } - - /** - * @NoAdminRequired - * - * @param int $id - */ - public function show($id) { - return $this->handleNotFound(function () use ($id) { - return $this->service->find($id, $this->userId); - }); - } - - /** - * @NoAdminRequired - * - * @param string $title - * @param string $content - */ - public function create($title, $content) { - return $this->service->create($title, $content, $this->userId); - } - - /** - * @NoAdminRequired - * - * @param int $id - * @param string $title - * @param string $content - */ - public function update($id, $title, $content) { - return $this->handleNotFound(function () use ($id, $title, $content) { - return $this->service->update($id, $title, $content, $this->userId); - }); - } - - /** - * @NoAdminRequired - * - * @param int $id - */ - public function destroy($id) { - return $this->handleNotFound(function () use ($id) { - return $this->service->delete($id, $this->userId); - }); - } - -} ----- - -As a result of these changes, the only reason that the controller needs -to be changed is when request/response related things change. diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/development_environment.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/development_environment.adoc deleted file mode 100644 index 8562d1f..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/development_environment.adoc +++ /dev/null @@ -1,234 +0,0 @@ -= The Core Application Files - -Now that you know how the request life cycle works, let’s look at the core application files. -Any ownCloud application, at its most elementary, only needs a few files and directories; these are: - -[source,console] ----- -. -├── appinfo # Contains app metadata and configuration -│   ├── app.php -│   ├── application.php -│   ├── info.xml -│   └── routes.php -└── lib # Contains the application's class files -    └── Controller # Contains the application's controllers ----- - -In addition to these, there are several additional, commonly used, directories: - -* `bin/`: Contains the command-line scripts -* `css/`: Contains the CSS files -* `img/`: Contains the image files -* `js/`: Contains the JavaScript files -* `l10n/`: Contains the translation files -* `lib/`: Contains the source code files -* `templates/`: Contains the templates -* `tests/`: Contains the tests - -== Create the Core File & Directory Structure - -To create these, in a new directory that will be called `ownnotes`, run the following code in your terminal, in the directory where you want to create the new project: - -[source,console] ----- -mkdir -p ownnotes/{appinfo,lib/Controller} -touch appinfo/{app,application,routes}.php appinfo/info.xml lib/Controller/PageController.php ----- - -== Understanding the Core Files - -Now let’s get an understanding of the core configuration files. - -== appinfo/info.xml - -This stores the application’s properties, or metadata, and is one of the -most important files. Rather like a composer.json file (only in XML -format), in this file you can set details such as the application’s: -_id_, _name_, _description_, _license_, _author_, _version_, -_namespace_, _category_, and _dependencies_. - -In `appinfo/info.xml`, add the following XML, changing it as necessary: - -[source,xml] ----- - - - ownnotes - Own Notes - My first ownCloud App - AGPL - Your Name - 0.0.1 - OwnNotes - tool - - - - ----- - -[IMPORTANT] -==== -Pay careful attention to the `namespace` element. -This element defines the application's relative namespace. -This namespace, in turn, sits inside a parent ownCloud namespace, called `OCA`. -As the application's namespace is `OwnNotes`, then it's fully-qualified namespace is `OCA\OwnNotes`. -==== - -To learn more about the options able to be stored in this file, check out xref:app/fundamentals/info.adoc[the App Metadata section] of the documentation. - -== appinfo/app.php - -The appinfo/app.php is the first file that is loaded and executed. It -usually contains the application’s core configuration settings. These -can include: - -* *id:* This is the string under which your app will be referenced in -ownCloud. -* *order:* Indicates the order in which your application will appear in -the apps menu. -* *href:* The application’s default route, rendered when the -application’s first loaded. -* **icon:** The application’s icon. -* *name:* The application’s title used in ownCloud. - -To start off with, in `appinfo/app.php`, add the following code: - -[source,php] ----- -getNavigationManager()->add(function () { - $urlGenerator = \OC::$server->getURLGenerator(); - return [ - // The string under which your app will be referenced in owncloud - 'id' => 'ownnotes', - - // The sorting weight for the navigation. - // The higher the number, the higher will it be listed in the navigation - 'order' => 10, - - // The route that will be shown on startup - 'href' => $urlGenerator->linkToRoute('ownnotes.page.index'), - - // The icon that will be shown in the navigation, located in img/ - 'icon' => $urlGenerator->imagePath('ownnotes', 'ownnotes.svg'), - - // The application's title, used in the navigation & the settings page of your app - 'name' => \OC::$server->getL10N('ownnotes')->t('Test App'), - ]; -}); ----- - -It can also contain xref:app/fundamentals/backgroundjobs.adoc[background jobs] and xref:app/fundamentals/hooks.adoc[hook registrations], as in the example below. - -[source,php] ----- -// execute OCA\OwnNotes\BackgroundJob\Task::run when cron is called -\OC::$server->getJobList()->add('OCA\OwnNotes\BackgroundJob\Task'); - -// execute OCA\OwnNotes\Hooks\User::deleteUser before a user is being deleted -\OCP\Util::connectHook('OC_User', 'pre_deleteUser', 'OCA\OwnNotes\Hooks\User', 'deleteUser'); ----- - -It is also possible to include xref:app/fundamentals/js.adoc[JavaScript] or xref:app/fundamentals/css.adoc[CSS] for other apps, by placing the `addScript` or `addStyle` functions inside this file as well. -However, this is strongly discouraged, because the file is loaded on each request, as well as for requests that do not return HTML, such as JSON and WebDAV. - -[source,php] ----- - 'hi']; - } -} ----- - -What we’re doing here is to create a minimalist controller with one -action, index, which is what will handle the route that we’ll define -shortly. The index function returns an array, which we’ll see next. - -== appinfo/routes.php - -As the name implies, in this file you register your application’s -routes, and then link them to a handler. In `appinfo/routes.php`, add -the following code: - -[source,php] ----- -registerRoutes($this, [ - 'routes' => [ - [ - // The handler is the PageController's index method - 'name' => 'page#index', - // The route - 'url' => '/', - // Only accessible with GET requests - 'verb' => 'GET' - ], - ] -]); ----- - -== lib/AppInfo/Application.php - -This is the core class of the application. -Here, you setup your controllers among a range of other things. -In `lib/AppInfo/Application.php`, add the following code: - -[source,php] ----- -getContainer(); - $container->registerService('PageController', function($c) { - return new PageController( - $c->query('AppName'), - $c->query('Request') - ); - }); - } -} ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/finishing_touches.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/finishing_touches.adoc deleted file mode 100644 index 0bdfa83..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/finishing_touches.adoc +++ /dev/null @@ -1,46 +0,0 @@ -= Apply Finishing Touches - -Now, the only thing left is to style the textarea in a nicer fashion. -To do that open `ownnotes/css/style.css` and replace the content with the following xref:app/fundamentals/css.adoc[CSS] code: - -[source,css] ----- -#app-content-wrapper { - height: 100%; -} - -#editor { - height: 100%; - width: 100%; -} - -#editor .input { - height: calc(100% - 51px); - width: 100%; -} - -#editor .save { - height: 50px; - width: 100%; - text-align: center; - border-top: 1px solid #ccc; - background-color: #fafafa; -} - -#editor textarea { - height: 100%; - width: 100%; - border: 0; - margin: 0; - border-radius: 0; - overflow-y: auto; -} - -#editor button { - height: 44px; -} ----- - -Congratulations! You’ve written your first ownCloud app. You can now -either try to further improve the tutorial notes app or start writing -your own app. diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/index.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/index.adoc deleted file mode 100644 index 6cae613..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/index.adoc +++ /dev/null @@ -1,7 +0,0 @@ -= Tutorial - -In this tutorial, you’ll learn how to create an ownCloud application, by -stepping through the process of creating one to manage a set of notes. -The application will support _listing_, _viewing_, _creating_, -_updating_, and _deleting_ notes. It will step through as many concepts -and techniques as possible, while not using concepts, just to do so. diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/javascript_and_css.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/javascript_and_css.adoc deleted file mode 100644 index c0bd7e3..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/javascript_and_css.adoc +++ /dev/null @@ -1,42 +0,0 @@ -= Add JavaScript and CSS - -To create a modern web application you need to write xref:app/fundamentals/js.adoc[JavaScript ] and xref:app/fundamentals/css.adoc[CSS]. - -== JavaScript - -You can use any JavaScript framework but for this tutorial we want to -keep it as simple as possible and therefore only include the templating -library http://handlebarsjs.com/[handlebarsjs]. -http://builds.handlebarsjs.com.s3.amazonaws.com/handlebars-v2.0.0.js[Download the file] -into `ownnotes/js/handlebars.js` and include it at the very -top of `ownnotes/templates/main.php` before the other scripts and styles: - -[source,php] ----- - - - - - -
      ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/request.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/request.adoc deleted file mode 100644 index 3b33e50..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/request.adoc +++ /dev/null @@ -1,88 +0,0 @@ -= The Request Life Cycle - -Before we dive in to creating an application, it's important to have an -overview of how the request life cycle of an ownCloud application works. - -If you are not interested in the internals or don't want to execute anything before and after your controller, feel free to skip this section and continue directly with defining xref:app/fundamentals/routes.adoc[your app's routes]. - -As with other web-based applications, it's centered around an HTTP -request, which typically consists of the following, four, components: - -* *A URL*: e.g. `/index.php/apps/myapp/something` -* *Request Parameters*: e.g. `?something=true&name=tom` -* *A Method*: e.g. `GET` -* *Request headers*: e.g. `Accept: application/json` - -These requests are, in turn, handled by five ownCloud components: - -* xref:the-front-controller[The Front Controller] -* xref:the-router[The Router] -* xref:middleware[Middleware] -* xref:the-dependency-injection-container[The Dependency Injection Container] -* xref:the-controller[The Controller] - -== The Front Controller - -All requests are sent to ownCloud's Front Controller: index.php, which -in turn executes lib/base.php. This file: - -* Inspects the HTTP headers -* Abstracts away differences between different web servers -* Initializes the core classes - -Following this, ownCloud then loads its core applications; these are: - -* The authentication backends -* The filesystem handler -* The logging handler - -With these three applications loaded, the remaining initialization steps -are then executed. These are: - -* Attempt to authenticate the user is made. -* Load and execute all the remaining applications' main files. To do this, the application's main file xref:app/tutorial/development_environment.adoc#appinfoinfo-xml[`appinfo/app.php`] is loaded and executed. If you want to execute code before your application is loaded, you need to place code in your app's main file. -* Load all the routes in the applications' `appinfo/routes.php`. -* Execute the router. - -With the setup completed, ownCloud then handles the user's request. - -== The Router - -The router: - -* Parses xref:app/fundamentals/routes.adoc[the application's routing configuration file]: `appinfo/routes.php`. -* Inspects the request's method and URL -* Retrieves xref:app/fundamentals/controllers.adoc[the handling controller] from xref:app/fundamentals/container.adoc[the DI container]. -* Passes control to the dispatcher - -The dispatcher: - -* Handles the requested routes by running hooks, called xref:middleware[Middleware], before and after invoking the controller which handles the route -* Executes the controller method -* Renders the request's output - -== Middleware - -xref:app/fundamentals/middleware.adoc[Middleware] is a convenient way to execute common tasks, such as custom authentication, before or after xref:app/fundamentals/controllers.adoc[a controller method] is executed. -You can execute middleware at the following locations: - -* Before calling the controller method -* After calling the controller method -* After an exception is thrown (also if it is thrown from middleware, -e.g., if an authentication request fails) -* Before the output is rendered - -== The Dependency Injection Container - -xref:app/fundamentals/container.adoc[The Dependency Injection (DI) container] is where you define all the services (or dependencies) that your application will need; in particular, all of your application's controllers. -A key benefit of DI containers is that they handle all dependency instantiation. -This means that you no longer have to rely on either globals or singletons. - -== The Controller - -xref:app/fundamentals/controllers.adoc[The controller] contains the code that you actually want to run when a request has come in. -Think of it like a callback that is executed if everything before went fine. -The controller collects all the information necessary to perform the request, such as from the route and environment, and returns a response. - -This response is then run through follow-up middleware (`afterController` and `beforeOutput`) for final processing. -When those steps are complete, HTTP headers are then set along with the body of the response to the client. diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/requirements.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/requirements.adoc deleted file mode 100644 index 2663fe8..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/requirements.adoc +++ /dev/null @@ -1,20 +0,0 @@ -= Minimum Requirements - -Before you can develop ownCloud applications, as with developing other -software applications, you have to ensure that you have a working -development environment. - -To do that: - -* First, ensure that your development environment meets the minimum -requirements -* Then, create the core files that any ownCloud application needs - -There aren’t many; all that you’ll need is: - -* PHP, with a minimum version {minimum-php-printed} (though preferably {recommended-php-version}) -* A copy of ownCloud core -* A working installation of ownCloud server - -To find out more, read through xref:general/devenv.adoc[the Development Environment section]. -When you've done everything that it suggests, you’re ready to begin developing an ownCloud application. diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/restful_api.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/restful_api.adoc deleted file mode 100644 index 203a6e5..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/restful_api.adoc +++ /dev/null @@ -1,159 +0,0 @@ -= Add a RESTful API (optional) - - -xref:app/fundamentals/api.adoc[A RESTful API] allows other apps such as Android or iPhone apps to access and change your notes. -Since syncing is a big core component of ownCloud it is a good idea to add, and document, your own RESTful API. - -Because we put our logic into the `NoteService` class it is very easy to -reuse it. The only pieces that need to be changed are the annotations -which disable the CSRF check (not needed for a REST call usually) and -add support for https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS[CORS] -so your API can be accessed from other webapps. - -With that in mind create a new controller in -`ownnotes/lib/Controller/NoteApiController.php`: - -[source,php] ----- -service = $service; - $this->userId = $UserId; - } - - /** - * @CORS - * @NoCSRFRequired - * @NoAdminRequired - */ - public function index() { - return new DataResponse($this->service->findAll($this->userId)); - } - - /** - * @CORS - * @NoCSRFRequired - * @NoAdminRequired - * - * @param int $id - */ - public function show($id) { - return $this->handleNotFound(function () use ($id) { - return $this->service->find($id, $this->userId); - }); - } - - /** - * @CORS - * @NoCSRFRequired - * @NoAdminRequired - * - * @param string $title - * @param string $content - */ - public function create($title, $content) { - return $this->service->create($title, $content, $this->userId); - } - - /** - * @CORS - * @NoCSRFRequired - * @NoAdminRequired - * - * @param int $id - * @param string $title - * @param string $content - */ - public function update($id, $title, $content) { - return $this->handleNotFound(function () use ($id, $title, $content) { - return $this->service->update($id, $title, $content, $this->userId); - }); - } - - /** - * @CORS - * @NoCSRFRequired - * @NoAdminRequired - * - * @param int $id - */ - public function destroy($id) { - return $this->handleNotFound(function () use ($id) { - return $this->service->delete($id, $this->userId); - }); - } - -} ----- - -All that is left is to connect the controller to a route and enable the -built in pre-flighted CORS method which is defined in the -`ApiController` base class: - -[source,php] ----- - [ - 'note' => ['url' => '/notes'], - 'note_api' => ['url' => '/api/0.1/notes'] - ], - 'routes' => [ - ['name' => 'page#index', 'url' => '/', 'verb' => 'GET'], - ['name' => 'note_api#preflighted_cors', 'url' => '/api/0.1/{path}', - 'verb' => 'OPTIONS', 'requirements' => ['path' => '.+']] - ] -]; ----- - -It is a good idea to version your API in your URL - -== Testing the API - -You can test the API by running a GET request with *curl*: - -[source,console,subs="attributes+"] ----- -curl -u user:password http://localhost:{std-port-http}/index.php/apps/ownnotes/api/0.1/notes ----- - -Since the `NoteApiController` is basically identical to the -`NoteController`, the unit test for it simply inherits its tests from -the `NoteControllerTest`. Create the file -`ownnotes/tests/Unit/Controller/NoteApiControllerTest.php`: - -[source,php] ----- -controller = new NoteApiController( - 'ownnotes', $this->request, $this->service, $this->userId - ); - } - -} ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/routes_and_controllers.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/routes_and_controllers.adoc deleted file mode 100644 index dd3b15c..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/routes_and_controllers.adoc +++ /dev/null @@ -1,219 +0,0 @@ -= Routes & Controllers - -== Routes - -A typical web application consists of both server side and client side -code. The glue between those two parts are the URLs. In the case of the -own notes application, the following URLs will be used: - -* *GET /*: Returns the interface in HTML format -* *GET /notes*: Returns a list of all notes in JSON format -* *GET /notes/1*: Returns a note with the id 1 in JSON format -* *DELETE /notes/1*: Deletes a note with the id 1 -* *POST /notes*: Creates a new note by passing in JSON format -* *PUT /notes/1*: Updates a note with the id 1 by passing in JSON format - -On the client side we can call these URLs with the following jQuery -code: - -[source,js] ----- -// example for calling the PUT /notes/1 URL -var baseUrl = OC.generateUrl('/apps/ownnotes'); -var note = { - title: 'New note', - content: 'This is the note text' -}; -var id = 1; -$.ajax({ - url: baseUrl + '/notes/' + id, - type: 'PUT', - contentType: 'application/json', - data: JSON.stringify(note) -}).done(function (response) { - // handle success -}).fail(function (response, code) { - // handle failure -}); ----- - -On the server side, we need to register a callback that is executed once the request comes in. -The callback will be a method on xref:app/fundamentals/controllers.adoc[a controller] and the controller will be connected to the URL with xref:app/fundamentals/routes.adoc[a route ]. - -To do that, we create the routes configuration file: `ownnotes/appinfo/routes.php`, which you can see the definition for below. - -[source,php] ----- - [ - ['name' => 'page#index', 'url' => '/', 'verb' => 'GET'], - ['name' => 'note#index', 'url' => '/notes', 'verb' => 'GET'], - ['name' => 'note#show', 'url' => '/notes/', 'verb' => 'GET'], - ['name' => 'note#create', 'url' => '/notes', 'verb' => 'POST'], - ['name' => 'note#update', 'url' => '/notes/', 'verb' => 'PUT'], - ['name' => 'note#destroy', 'url' => '/notes/', 'verb' => 'DELETE'] - ] -]; ----- - -A handy feature of routing in ownCloud is that as the final five routes -are so similar, they can be abbreviated by adding a resource instead: - -[source,php] ----- - [ - 'note' => ['url' => '/notes'] - ], - 'routes' => [ - ['name' => 'page#index', 'url' => '/', 'verb' => 'GET'] - ] -]; ----- - -Let’s look at the route below first, so that you get a better -understanding of how they’re composed. - -[source,php] ----- - [ - ['name' => 'page#index', 'url' => '/', 'verb' => 'GET'] -]]; ----- - -This route (`/`) is accessible only via a GET request and is called -`page#index`. When called, the request will be handled by -`OCA\\OwnNotes\\PageController`’s `index` method. The reason why is -defined in the route’s name. The name is composed of the name of a -controller and a method on that controller, separated by a hash symbol. - -== Controllers - -The controller, more specifically the controller function, as in other -MVC-based frameworks, is the central place of logic for a route (or -action). These functions, as you would expect, can return a range of -responses to the user, including: JSON, HTML, XML, and plain text; a -redirect or 404 Not Found response, or the download of a file. - -In the example below, we’ll return an HTML response, based on the contents of xref:app/fundamentals/templates.adoc[a template file], using the `TemplateResponse` object. -The `TemplateResponse` object renders a template located in an application’s templates directory. - -[source,php] ----- -t()` is used to xref:app/advanced/l10n.adoc[make your strings translatable] and `p()` is used to xref:app/fundamentals/templates.adoc[print escaped HTML]. - -[source,php] ----- - -
      ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/testing.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/testing.adoc deleted file mode 100644 index 1482259..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/testing.adoc +++ /dev/null @@ -1,241 +0,0 @@ -= Writing Tests - -Tests are essential for having happy users and a carefree life. No one -wants their users to rant about your app breaking their ownCloud or -being buggy. To do that you need to test your app. Since this amounts to -a ton of repetitive tasks, we need to automate the tests. - -== Unit Tests - -A unit test is a test that tests a class in isolation. -It is very fast and catches most of the bugs, so we want many unit tests. -Because ownCloud uses xref:app/fundamentals/container.adoc[Dependency Injection] to assemble your app, it is very easy to write unit tests by passing mocks into the constructor. -A simple test for the update method can be added by adding this to `ownnotes/tests/Unit/Controller/NoteControllerTest.php`: - -[source,php] ----- -request = $this->getMockBuilder('OCP\IRequest')->getMock(); - $this->service = $this->getMockBuilder('OCA\OwnNotes\Service\NoteService') - ->disableOriginalConstructor() - ->getMock(); - $this->controller = new NoteController( - 'ownnotes', $this->request, $this->service, $this->userId - ); - } - - public function testUpdate() { - $note = 'just check if this value is returned correctly'; - $this->service->expects($this->once()) - ->method('update') - ->with($this->equalTo(3), - $this->equalTo('title'), - $this->equalTo('content'), - $this->equalTo($this->userId)) - ->will($this->returnValue($note)); - - $result = $this->controller->update(3, 'title', 'content'); - - $this->assertEquals($note, $result->getData()); - } - - - public function testUpdateNotFound() { - // test the correct status code if no note is found - $this->service->expects($this->once()) - ->method('update') - ->will($this->throwException(new NotFoundException())); - - $result = $this->controller->update(3, 'title', 'content'); - - $this->assertEquals(Http::STATUS_NOT_FOUND, $result->getStatus()); - } - -} ----- - -We can and should also create a test for the `NoteService` class: - -[source,php] ----- -mapper = $this->getMockBuilder('OCA\OwnNotes\Db\NoteMapper') - ->disableOriginalConstructor() - ->getMock(); - $this->service = new NoteService($this->mapper); - } - - public function testUpdate() { - // the existing note - $note = Note::fromRow([ - 'id' => 3, - 'title' => 'yo', - 'content' => 'nope' - ]); - $this->mapper->expects($this->once()) - ->method('find') - ->with($this->equalTo(3)) - ->will($this->returnValue($note)); - - // the note when updated - $updatedNote = Note::fromRow(['id' => 3]); - $updatedNote->setTitle('title'); - $updatedNote->setContent('content'); - $this->mapper->expects($this->once()) - ->method('update') - ->with($this->equalTo($updatedNote)) - ->will($this->returnValue($updatedNote)); - - $result = $this->service->update(3, 'title', 'content', $this->userId); - - $this->assertEquals($updatedNote, $result); - } - - - /** - * @expectedException OCA\OwnNotes\Service\NotFoundException - */ - public function testUpdateNotFound() { - // test the correct status code if no note is found - $this->mapper->expects($this->once()) - ->method('find') - ->with($this->equalTo(3)) - ->will($this->throwException(new DoesNotExistException(`))); - - $this->service->update(3, 'title', 'content', $this->userId); - } - -} ----- - -If https://phpunit.de/[PHPUnit is installed] we can run the tests inside -`ownnotes/` with the following command: - ----- -phpunit ----- - -You need to adjust the -`ownnotes/tests/Unit/Controller/PageControllerTest` file to get the -tests passing: remove the `testEcho` method since that method is no -longer present in your `PageController` and do not test the user id -parameters since they are not passed anymore - -== Integration Tests - -Integration tests are slow and need a fully working instance but make -sure that our classes work well together. Instead of mocking out all -classes and parameters we can decide whether to use full instances or -replace certain classes. Because they are slow we don’t want as many -integration tests as unit tests. - -In our case we want to create an integration test for the update method -without mocking out the `NoteMapper` class so we actually write to the -existing database. To do that create a new file called -`ownnotes/tests/Integration/NoteIntegrationTest.php` with the following -content: - -[source,php] ----- -getContainer(); - - // only replace the user id - $container->registerService('UserId', function($c) { - return $this->userId; - }); - - $this->controller = $container->query( - 'OCA\OwnNotes\Controller\NoteController' - ); - - $this->mapper = $container->query( - 'OCA\OwnNotes\Db\NoteMapper' - ); - } - - public function testUpdate() { - // create a new note that should be updated - $note = new Note(); - $note->setTitle('old_title'); - $note->setContent('old_content'); - $note->setUserId($this->userId); - - $id = $this->mapper->insert($note)->getId(); - - // fromRow does not set the fields as updated - $updatedNote = Note::fromRow([ - 'id' => $id, - 'user_id' => $this->userId - ]); - $updatedNote->setContent('content'); - $updatedNote->setTitle('title'); - - $result = $this->controller->update($id, 'title', 'content'); - - $this->assertEquals($updatedNote, $result->getData()); - - // clean up - $this->mapper->delete($result->getData()); - } - -} ----- - -To run the integration tests change into the `ownnotes` directory and -run - -[source,console] ----- -phpunit -c phpunit.integration.xml ----- diff --git a/content/server/10.15/modules/developer_manual/pages/app/tutorial/wiring_it_up.adoc b/content/server/10.15/modules/developer_manual/pages/app/tutorial/wiring_it_up.adoc deleted file mode 100644 index d16439c..0000000 --- a/content/server/10.15/modules/developer_manual/pages/app/tutorial/wiring_it_up.adoc +++ /dev/null @@ -1,216 +0,0 @@ -= Wiring It Up - -When the page is loaded, we want all the existing notes to load. Furthermore: - -* We want to display the btn:[current note] when you click on it in the navigation -* A note should be deleted when we click the btn:[deleted] button -* Clicking on btn:[New note] should create a new note. - -To do that open `ownnotes/js/script.js` and replace the example code with the following: - -[source,js] ----- -(function (OC, window, $, undefined) { -'use strict'; - -$(document).ready(function () { - -var translations = { - newNote: $('#new-note-string').text() -}; - -// this notes object holds all our notes -var Notes = function (baseUrl) { - this._baseUrl = baseUrl; - this._notes = []; - this._activeNote = undefined; -}; - -Notes.prototype = { - load: function (id) { - var self = this; - this._notes.forEach(function (note) { - if (note.id === id) { - note.active = true; - self._activeNote = note; - } else { - note.active = false; - } - }); - }, - getActive: function () { - return this._activeNote; - }, - removeActive: function () { - var index; - var deferred = $.Deferred(); - var id = this._activeNote.id; - this._notes.forEach(function (note, counter) { - if (note.id === id) { - index = counter; - } - }); - - if (index !== undefined) { - // delete cached active note if necessary - if (this._activeNote === this._notes[index]) { - delete this._activeNote; - } - - this._notes.splice(index, 1); - - $.ajax({ - url: this._baseUrl + '/' + id, - method: 'DELETE' - }).done(function () { - deferred.resolve(); - }).fail(function () { - deferred.reject(); - }); - } else { - deferred.reject(); - } - return deferred.promise(); - }, - create: function (note) { - var deferred = $.Deferred(); - var self = this; - $.ajax({ - url: this._baseUrl, - method: 'POST', - contentType: 'application/json', - data: JSON.stringify(note) - }).done(function (note) { - self._notes.push(note); - self._activeNote = note; - self.load(note.id); - deferred.resolve(); - }).fail(function () { - deferred.reject(); - }); - return deferred.promise(); - }, - getAll: function () { - return this._notes; - }, - loadAll: function () { - var deferred = $.Deferred(); - var self = this; - $.get(this._baseUrl).done(function (notes) { - self._activeNote = undefined; - self._notes = notes; - deferred.resolve(); - }).fail(function () { - deferred.reject(); - }); - return deferred.promise(); - }, - updateActive: function (title, content) { - var note = this.getActive(); - note.title = title; - note.content = content; - - return $.ajax({ - url: this._baseUrl + '/' + note.id, - method: 'PUT', - contentType: 'application/json', - data: JSON.stringify(note) - }); - } -}; - -// this will be the view that is used to update the html -var View = function (notes) { - this._notes = notes; -}; - -View.prototype = { - renderContent: function () { - var source = $('#content-tpl').html(); - var template = Handlebars.compile(source); - var html = template({note: this._notes.getActive()}); - - $('#editor').html(html); - - // handle saves - var textarea = $('#app-content textarea'); - var self = this; - $('#app-content button').click(function () { - var content = textarea.val(); - var title = content.split('\n')[0]; // first line is the title - - self._notes.updateActive(title, content).done(function () { - self.render(); - }).fail(function () { - alert('Could not update note, not found'); - }); - }); - }, - renderNavigation: function () { - var source = $('#navigation-tpl').html(); - var template = Handlebars.compile(source); - var html = template({notes: this._notes.getAll()}); - - $('#app-navigation ul').html(html); - - // create a new note - var self = this; - $('#new-note').click(function () { - var note = { - title: translations.newNote, - content: '' - }; - - self._notes.create(note).done(function() { - self.render(); - $('#editor textarea').focus(); - }).fail(function () { - alert('Could not create note'); - }); - }); - - // show app menu - $('#app-navigation .app-navigation-entry-utils-menu-button').click(function () { - var entry = $(this).closest('.note'); - entry.find('.app-navigation-entry-menu').toggleClass('open'); - }); - - // delete a note - $('#app-navigation .note .delete').click(function () { - var entry = $(this).closest('.note'); - entry.find('.app-navigation-entry-menu').removeClass('open'); - - self._notes.removeActive().done(function () { - self.render(); - }).fail(function () { - alert('Could not delete note, not found'); - }); - }); - - // load a note - $('#app-navigation .note > a').click(function () { - var id = parseInt($(this).parent().data('id'), 10); - self._notes.load(id); - self.render(); - $('#editor textarea').focus(); - }); - }, - render: function () { - this.renderNavigation(); - this.renderContent(); - } -}; - -var notes = new Notes(OC.generateUrl('/apps/ownnotes/notes')); -var view = new View(notes); -notes.loadAll().done(function () { - view.render(); -}).fail(function () { - alert('Could not load notes'); -}); - - -}); - -})(OC, window, jQuery); ----- diff --git a/content/server/10.15/modules/developer_manual/pages/bugtracker/codereviews.adoc b/content/server/10.15/modules/developer_manual/pages/bugtracker/codereviews.adoc deleted file mode 100644 index a6906c5..0000000 --- a/content/server/10.15/modules/developer_manual/pages/bugtracker/codereviews.adoc +++ /dev/null @@ -1,54 +0,0 @@ -= Code Reviews - -[, Linus’ Law] -"" -Given enough eyeballs, all bugs are shallow -"" - -== Introduction - -In order to increase the code quality within ownCloud, developers are -requested to perform code reviews. As we are now heavily using the -GitHub platform these code review shall take place on GitHub as well. - -== Precondition - -From now on no direct commits/pushes to master or any of the stable -branches are allowed in general. *Every code* change - *even one liners* -- have to be reviewed! - -== How will it work? - -1. A developer will submit his changes on GitHub via a pull request (PR). -https://help.GitHub.com/articles/using-pull-requests[GitHub:help - using pull requests] -2. Within the pull request the developer could already name other -developers (using -+ -@GitHubusername) and ask them for review. -3. Using Labels section on the right side, they add _`3 - To review`_ -label if the patch is complete. If they have no permission to do that, -other developers may add this Label in case PR author had indicated. -4. Other developers (either named or at free will) have a look at the -changes and are welcome to write comments within the comment field. -5. In case the reviewer is okay with the changes and thinks all his -comments and suggestions have been take into account a :+1 on the -comment will signal a positive review. -6. Before a pull request will be merged into master or the -corresponding branch at least 2 reviewers need to give :+1 score. -7. Our https://drone.owncloud.com/owncloud[continuous integration server] will -give an additional indicator for the quality of the pull request. - -== Examples - -Read our xref:general/codingguidelines.adoc[coding style guidelines] for information on what a good -pull request and good ownCloud code looks like. - -These are two examples that are considered to be good examples of how -pull requests should be handled - -* https://github.com/owncloud/core/pull/121 -* https://github.com/owncloud/core/pull/146 - -== Questions? - -Feel free to drop a line on our https://talk.owncloud.com[chat system]. diff --git a/content/server/10.15/modules/developer_manual/pages/bugtracker/index.adoc b/content/server/10.15/modules/developer_manual/pages/bugtracker/index.adoc deleted file mode 100644 index b720e9e..0000000 --- a/content/server/10.15/modules/developer_manual/pages/bugtracker/index.adoc +++ /dev/null @@ -1,26 +0,0 @@ -= Bugtracker - -Thank you for helping ownCloud by reporting bugs. Before submitting an -issue, please read -https://github.com/owncloud/core/blob/master/.github/CONTRIBUTING.md#reporting-bugs[Issue submission guidelines] first. - -* If the issue is with the ownCloud server, report it to the -https://github.com/owncloud/core/issues[Core repository] -* If the issue is with the ownCloud desktop client, report it to the -https://github.com/owncloud/client/issues[Desktop client repository] -* If the issue is with the ownCloud iOS app, report it to the -https://github.com/owncloud/ios/issues[iOS repository] -* If the issue is with the ownCloud Android app, report it to the -https://github.com/owncloud/android/issues[Android repository] -* If the issue with with an ownCloud app, report it to where that app is -developed -* If the issue is with a Marketplace app, report it to the -https://github.com/owncloud/marketplace-issues[Marketplace issue -tracker] -* If the app is listed in our https://github.com/owncloud[main github -repository] report it to the correct sub repository -* If the app is listed in the -https://github.com/owncloud/apps/issues[apps repository] report it there - -Please note that the mailing list should not be used for bug reports, as -it is hard to track them there. diff --git a/content/server/10.15/modules/developer_manual/pages/bugtracker/triaging.adoc b/content/server/10.15/modules/developer_manual/pages/bugtracker/triaging.adoc deleted file mode 100644 index 4fbecd0..0000000 --- a/content/server/10.15/modules/developer_manual/pages/bugtracker/triaging.adoc +++ /dev/null @@ -1,241 +0,0 @@ -= Bug Triaging - -// Links -:link-bugs-least-recently-commented-on: https://github.com/issues?q=is%3Aissue+user%3Aowncloud+is%3Aopen+sort%3Aupdated-asc -:link-least-commented-issues: https://github.com/issues?q=is%3Aissue+user%3Aowncloud+is%3Aopen+no%3Aassignee+no%3Amilestone+no%3Alabel+sort%3Acomments-asc -:link-bugs-which-need-info: https://github.com/issues?q=is%3Aissue+user%3Aowncloud+is%3Aopen+label%3A%22Needs+info%22+sort%3Acreated-asc -:link-guidelines-and-howtos-bug-triaging: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging -:link-bug-reporting-guidelines: https://github.com/owncloud/core/blob/master/.github/CONTRIBUTING.md#reporting-bugs - -== Introduction - -Bug Triaging is the process of checking bug reports to see if they are -still valid (the problem might be solved since the bug was reported), -reproducing them when possible (to make sure it really is an ownCloud -issue and not a configuration problem) and in general making sure the -bug is useful for a developer who wants to fix it. If the bug is not -useful and can’t be augmented by the original reporter or the triaging -contributor, it has to be closed. - -== Why do you want to join - -Helping to bring the number of issues down makes it easier for -developers to spend their time productively and bug triagers thus -*contribute greatly to ownCloud development*! Triaging a bug doesn’t -take long so the work comes in small chunks and you don’t need many -skills, just some patience and sometimes perseverance. - -== How do you triage bugs - -The process of checking, reproducing and closing invalid issues is -called ‘bug triaging‘. Issues can be divided in one of three kinds: - -1. Bugs or feature requests which come with all needed information to -allow a developer to fix or work on them -2. Incomplete or duplicate bug reports or feature requests -3. Irrelevant or wrong bug reports or feature requests - -The job of a bug triager is to identify the One’s for developers to look -at, help remove, merge or improve any Two to a One and dismiss Three’s -in a friendly and emphatic way. - -Triaging follows these steps: - -* Find an issue somebody should look at -* Be that somebody and see if the issue content is useful for a -developer -* Reply and close, ask a question, add information or a label. -* Find the next bug-to-be-dealt-with and repeat! - -== General considerations - -* You need a https://github.com[github account] to contribute to bug triaging. -* If you are not familiar with the github issue tracker interface (which -is used by ownCloud to handle bug reports), you -https://guides.github.com/features/issues/[may find this guide useful]. -* You will initially only be able to comment on issues. The ability to -close issues or assign labels will be given liberally to those who have -shown to be willing and able to contribute. Just ask on IRC! -* Read -https://github.com/owncloud/core/blob/master/.github/CONTRIBUTING.md#reporting-bugs[our -bug reporting guidelines] so you know what a good report should look -like and where things belong. The -https://github.com/owncloud/core/issues/new/choose[issue template] asks specifically for some information developers need to solve issues. -* It might even be fixed, sometimes! It can also be fruitful to contact -the irc://freenode/#owncloud-dev[developers on irc]. Tell them you’re -triaging bugs and share what problem you bumped into. Or just ask on the -test-pilots mailing list. -* To ensure no two people are working on the same issue, we ask you to -simply add a comment like `I am triaging this` in the issue you want -to work on, and when done, before or after executing the triaging -actions, note similarly that you’re done. -+ -NOTE: To be able to tag and close issues, you need to have access to the -repository. For the core and sync app repositories this also means -having signed the contributor agreement. However, this isn’t really -needed for triaging as you can comment after you’re done triaging and -somebody else can execute those actions. - -== Finding bugs to triage - -Github offers several search queries which can be useful to find a list -of bugs which deserve a closer look: - -* {link-bugs-least-recently-commented-on}[Bugs least recently commented on] -* {link-least-commented-issues}[Least commented issues] -* {link-bugs-which-need-info}[Bugs which need info] - -But there are more methods. -For example, if you are a user of ownCloud with a specific setup which uses Apache as the webserver, Dropbox as storage, or uses the encryption app, you could look for bugs with these keywords. -You can then use your knowledge of your installation and your installation itself to see if bugs are (still) valid or reproduce them. - -Once you have picked an issue, add a comment that you’ve started triaging: - -`I am triaging this bug` - -== Checking if the issue is useful - -Much content from -{link-guidelines-and-howtos-bug-triaging}[Guidelines and HOWTOs/Bug triaging] - -The goal of triaging is to have only useful bug reports for the -developers. And you don’t have to know much to be able to judge at least -some bug reports to be less than useful. There are duplications, -incomplete reports and so on. Here is the work flow for each bug: - -image:triageworkflow.png[image] - -Let’s go over each step. - -=== Finding duplicates - -To find duplicates, the search tool in github is your first stop. In -https://github.com/owncloud/core/issues[this screen] you can easily -search for a few keywords from the bug report. If you find other bugs -with the same content, decide what the best bug report is (often the -oldest or the one where one or more developers have already started to -engage and discuss the problem). That is the `master' bug report, you -can now close the other one (or comment that it can be closed as -duplicate). - -If the bug report you were reviewing contains additional information, -you can add that information to the `master' bug report in a comment. -Mention this bug report (using #) so a developer can -look up the original, closed, report and perhaps ask the initial -reporter there for additional information. - -If you can’t find anything, look in closed bug reports. The problem -might be solved already and be listed there! Of course, these other bug -reports might be closed as duplicates of the one you are looking at now -- if you can’t find one that is solved nor can find any duplicates, you -can move on to the next step. If you are unsure, just add a comment: -`might be a duplicate of #` will usually suffice. - -When the issue is a feature request, you can be helpful in the same way: -merge related requests by adding information of one to the other and -closing the first. - -Be polite: when you need to request information or feedback be clear and -polite, and you will get more information in less time. Think about how -you’d like to be treated, were you to report a bug! - -You can answer more quickly and friendly using one of -https://gist.github.com/jancborchardt/6155185#clean-up-inactive-issues[these templates]. - -Often our github issue tracker is a place for discussions about -solutions. Be friendly, inclusive and respect other people’s position. - -=== Determining relevance of issue - -Not all issues are relevant for ownCloud. -Bugs can be due to a specific configuration or unsupported platforms. -Raspberry Pi’s suffer from SQLite time-outs, NGINX has problems which Apache doesn't, and Microsoft Server with IIS is not well supported. -While external issues are not always a reason to close a report, be sure that they are clear: does the user use the `standard' platform? -Ask for information if this is missing. - -Last but not least, the problem might be due to the user doing something -that simply does not work. Your general ownCloud knowledge might be -helpful here - if this is the case, you can often swiftly close the -issue with a comment about what went wrong. - -You might have to say no to some requests, for example when a problem -has been solved in a new release but won’t become available for the -release the reporter is using; or when a solution has been chosen which -the reporter is unhappy about. Be considerate. People feel surprisingly -strong about ownCloud, and you should take care to explain that we don’t -aim to ignore them; on the contrary. But sometimes, decisions which -benefit the majority of users don’t help an individual. The -extensibility and open availability of the code of ownCloud is here to -relieve the pain of such decisions. - -=== Determining if the report is complete - -Now that you know that the bug report is unique, and that is not an -external issue, you need to check all the needed information is there. - -Check our {link-bug-reporting-guidelines}[bug reporting guidelines] -and make sure bug reports comply with it! The information asked in the -https://github.com/owncloud/core/blob/master/.github/ISSUE_TEMPLATE/issue_template.md[issue template] is needed for developers to solve issues. - -Once you added a request for more information, add a #needinfo tag. - -If there has been a request for more information on the report, either -by you, a developer or somebody else, but the original reporter (or -somebody else who might have the answer) has not responded for 1 month -or longer, you can close the issue. Be polite and note that whoever can -answer the question can re-open the issue! - -=== Reproducing the issue - -An important step of bug triaging is trying to reproduce the bugs, this -means, using the information the reporters added to the bug report to -force (recreate, reproduce, repeat) the bug in the application. - -This is needed in order to differentiate random/race condition bugs of -reproducible ones (which may be reproduced by developers too; and they -can fix them). - -To reproduce an issue, please refer to xref:developer_manual:testing/index.adoc[our testing documents]. - -If you can’t reproduce an issue in a newer version of ownCloud, it is -most likely fixed and can be closed. Comment that you failed to -reproduce the problem, and if the reporter can confirm (or doesn’t -respond for a long time), you can close the issue. Also, be sure to add -what exactly you tested with - the ownCloud Master or a branch (and if -so, when), or did you use a release, and if so - what version? - -=== Finalizing and tagging - -Once you are done reproducing an issue, it is time to finish up and make -clear to the developers what they can do: - -* If it is a genuine bug (or you are pretty sure it is) add the `Bug' -tag. -* If it is a genuine feature request (or you are pretty sure it is) add -the `enhancement' tag. -* If the issue is clearly related to something specific, @mention a -maintainer. examples: @schiesbn for encryption, @blizzz for LDAP, -@PVince81 for quota stuff… You can find a -https://github.com/owncloud/core/wiki/Maintainers[list of maintainers here]. - -Now, the developers can pick the issue up. Note that while we wish we -would always pick up and solve problems promptly, not all areas of -ownCloud get the same amount of attention and contribution, so this can -occasionally take a long time. - -== Collaboration - -You can just get started with bug triaging. -But if you want, you can register at the https://talk.owncloud.com[chat system]. - -You can also join the '#owncloud-testing' channel on irc://freenode.net and https://webchat.freenode.net/, to ask questions but keep in mind that people aren't active 24/7, and it can occasionally take a while to get a response. -Last, but not least, ownCloud contributor https://gist.github.com/jancborchardt/6155185[Jan Borchardt has a great guide for developers and triagers] about dealing with issues, including some 'stock answers' and thoughts on how to deal with pull requests. - -For further questions or help you can also send a mail to: - -* X (IRC: Y) - -We are looking forward to working with you! - -*Credit:* this document is in debt to the extensive -https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging[KDE guide to bug triaging]. diff --git a/content/server/10.15/modules/developer_manual/pages/commun/help_and_communication.adoc b/content/server/10.15/modules/developer_manual/pages/commun/help_and_communication.adoc deleted file mode 100644 index cafc3bb..0000000 --- a/content/server/10.15/modules/developer_manual/pages/commun/help_and_communication.adoc +++ /dev/null @@ -1,43 +0,0 @@ -= Help and Communication -:toc: right - -== Getting Involved - -=== Introduction - -There are a variety of ways to get involved and seek help if and when you need it. -Here’s the best ways. - -=== Community Support Forum - -Ask questions on {oc-central-url}[ownCloud Central]. -We strongly recommend using ownCloud Central, as it hosts dedicated FAQ pages. -These include topics which address typical mistakes and commonly occurring issues. - -=== Talk - -Ask questions on RocketChat: - -* https://talk.owncloud.com[Talk via RocketChat] - -=== Social Media - -Ask questions on social media: - -* https://www.facebook.com/ownclouders/[Facebook] -* https://twitter.com/ownclouders/[Twitter] - -=== IRC Channels - -Chat with us on http://www.irchelp.org/[IRC] (*irc.freenode.net*). -You can chat via the web with http://webchat.freenode.net, or use your favorite IRC client. -The channel names are: - -* Setup: *#owncloud* -* Testing: *#owncloud-testing* -* Development: *#owncloud-dev* -* Design: *#owncloud-design* - -=== Maintainers - -If you need to contact a maintainer of a certain app or division you can find the details at https://owncloud.com/contact-us/. diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/externalapi.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/externalapi.adoc deleted file mode 100644 index dcb1831..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/externalapi.adoc +++ /dev/null @@ -1,151 +0,0 @@ -= External API -:toc: right -:page-aliases: core/externalapi.adoc - -== Introduction - -The external API inside ownCloud allows third party developers to access -data provided by ownCloud apps. ownCloud follows the -http://www.freedesktop.org/wiki/Specifications/open-collaboration-services-1.7[OCS -v1.7 specification] (draft). - -== Usage - -=== Registering Methods - -Methods are registered inside the appinfo/routes.php using :phpOCP\\API - -[source,php] ----- - - - - ok - 100 - - - - - - ----- --- -JSON:: -+ --- -[source,js] ----- -{ - "ocs": { - "meta": { - "status": "ok", - "statuscode": 100, - "message": null - }, - "data": { - // data here - } - } -} ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -==== XML - -[source,xml] ----- - - - - ok - 100 - - - - - - ----- - -==== JSON - -[source,js] ----- -{ - "ocs": { - "meta": { - "status": "ok", - "statuscode": 100, - "message": null - }, - "data": { - // data here - } - } -} ----- -endif::[] - -=== Status codes - -The status code can be any of the following numbers: - -* *100* - successful -* *996* - server error -* *997* - not authorized -* *998* - not found -* *999* - unknown error diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/index.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/index.adoc deleted file mode 100644 index bdf0b1d..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/index.adoc +++ /dev/null @@ -1,4 +0,0 @@ -:section-title: APIs -:section-preamble-ender: to use APIs in ownCloud - -include::partial$section_page.adoc[] diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-capabilities.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-capabilities.adoc deleted file mode 100644 index c31bfd5..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-capabilities.adoc +++ /dev/null @@ -1,90 +0,0 @@ -= OCS Rest API -:toc: right -:page-aliases: core/ocs-capabilities.adoc - -== Available Capabilities - -[cols=",,",options="header",] -|================================================================= -| Request Path | Method | Content Type -| `/ocs/v1.php/cloud/capabilities?format=json` | `GET` | `text/plain` -|================================================================= - -To retrieve a list of your ownCloud server’s available capabilities, you -need to make an authenticated `GET` request, as in the example below. - ----- -curl --silent -u admin:admin \ - 'http://localhost/ocs/v1.php/cloud/capabilities?format=json' | json_pp ----- - -The example uses http://search.cpan.org/~makamaka/JSON-PP-2.27103/bin/json_pp[json_pp] -to make the response easier to read, and omits some content for the sake of brevity. - -This will return a JSON response, similar to the example below, along with a status of: `HTTP/1.1 200 OK`. - -[source,json] ----- -include::example$core/apis/ocs-capabilities/list-capabilities-response.json[] ----- - -In the example, in the `capabilities` element, you can see that the -server lists six capabilities, along with their settings, sub-settings, -and their values. - -== Core - -Stored under the `core` capabilities element, this returns the server’s -core status settings, the interval to poll for server side changes in milliseconds, and -it’s WebDAV API root. - -== Checksums - -Stored under the `checksums` capabilities element, this returns the -server’s supported checksum types, and preferred upload checksum type. - -== Files - -Stored under the `files` capabilities element, this returns the server's support for the following capabilities: - -[cols=",",options="header"] -|=== -|Capability -|Response Key - -|Big file chunking -|`bigfilechunking` - -|File versioning -|`versioning` - -|Can provide a private link to a file or folder in a DAV response -|`privateLinks` - -|Its ability to undelete files; and -|`undelete` - -|The list of files that are currently blacklisted. -|`blacklisted_files` -|=== - -== Files Sharing - -Stored under the `files_sharing` capabilities element, this returns the -server’s support for file sharing, re-sharing (by users and groups), -federated file support, and public link shares (as well as whether -passwords and expiry dates are enforced), and also whether the sharing -API is enabled. - -== Notifications - -Stored under the `notifications` capabilities element, this returns what -the server sends notifications for. - -== WebDAV - -Stored under the `dav` capabilities element, this returns the server’s -WebDAV API support. - -Other apps add detail information to the capabilities, to indicate the -availability of certain features, for example notifications. diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-notification-endpoint-v1.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-notification-endpoint-v1.adoc deleted file mode 100644 index 34e0db3..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-notification-endpoint-v1.adoc +++ /dev/null @@ -1,324 +0,0 @@ -= OCS Notifications API (v1) -:toc: right -:toclevels: 1 -:request-base-path: ocs/v2.php - -== Check Server Capabilities - -In order to find out if notifications is installed and enabled on the server, you can run a request against the capabilities endpoint. - -* Path: `{request-base-path}/cloud/capabilities` -* Method: `GET` - -=== Request Parameters - -[cols="15%,15%,70%",options="header",width=100%] -|=== -|Attribute -|Type -|Description - -|`format` -|string -|The format to return the response in. -It can be either `XML` or `JSON`. -|=== - -=== Returns - -On success, the request returns either an XML (the default) or a JSON response, along with an `HTTP 200 OK` status code, which shows the server’s notifications capabilities. - -=== Example Responses - -ifndef::format[] -[tabs] -==== -JSON:: -+ --- -[source,json] ----- -include::example$core/apis/ocs/notifications/get-server-capabilities-response.json[] ----- --- - -XML:: -+ --- -[source,xml] ----- -include::example$core/apis/ocs/notifications/get-server-capabilities-response.xml[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -==== JSON - -[source,json] ----- -include::example$core/apis/ocs/notifications/get-server-capabilities-response.json[] ----- - -==== XML - -[source,xml] ----- -include::example$core/apis/ocs/notifications/get-server-capabilities-response.xml[] ----- -endif::[] - -=== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,bash,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/notifications/get-server-capabilities.sh[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -==== Curl - -[source,bash,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/notifications/get-server-capabilities.sh[] ----- -endif::[] - -== Get User Notifications - -This endpoint supports retrieving a list of notifications for a user. - -* Path: `{request-base-path}/apps/notifications/api/v1/notifications` -* Method: `GET` - -[TIP] -==== -In order to get a single notification, you can send a `GET` request against the endpoint below. -Note the property at the end of the endpoint. - -[source,console] ----- -{request-base-path}/apps/notifications/api/v1/notifications/ ----- -==== - -=== Request Parameters - -[cols="15%,15%,70%",options="header",width=100%] -|=== -|Attribute -|Type -|Description - -|`format` -|string -|The format to return the response in. -It can be either `XML` or `JSON`. -|=== - -=== Returns - -On success, the request returns either an XML (the default) or a JSON response, along with an `HTTP 200 OK` status code, which shows the server’s notifications capabilities. - -=== Example Responses - -==== Response With Notifications - -ifndef::format[] -[tabs] -==== -JSON:: -+ --- -[source,json] ----- -include::example$core/apis/ocs/notifications/get-user-notifications-response.json[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== JSON - -[source,json] ----- -include::example$core/apis/ocs/notifications/get-user-notifications-response.json[] ----- -endif::[] - -==== Response Without Notifications - -ifndef::format[] -[tabs] -==== -JSON:: -+ --- -[source,json] ----- -include::example$core/apis/ocs/notifications/get-user-notifications-no-notifications-response.json[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== JSON - -[source,json] ----- -include::example$core/apis/ocs/notifications/get-user-notifications-no-notifications-response.json[] ----- -endif::[] - -=== Specification - -Optional elements are still set in the array, the value is just empty: - -[options="header"] -|=== -|Type | Empty value -|array | `[]` -|string | `""` -|=== - -==== Notification Element - -[cols="20%,10%,70%",options="header"] -|=== -|Field name -|Type -|Value description - -|`actions` -|array -|(Optional) An array of action elements. - -|`app` -|string -|The name of the app that triggered the notification. - -|`datetime` -|string -|The ISO 8601 date and time of when the notification was published. - -|`link` -|string -|(Optional) A link that should be followed when the subject/message is clicked. - -|`message` -|string -|(Optional) The translated, potentially longer, message that should be presented to the user. - -|`notification_id` -|int -|The unique notification identifier. -It can be used to dismiss a notification. - -|`object_id` -|string -|The ID of the object which the notification is about. -The id can be used in PHP to mark a notification as resolved. - -|`object_type` -|string -|The type of the object which the notification is about. -It can be used in PHP to mark a notification as resolved. - -|`subject` -|string -|The translated short subject that should be presented to the user. - -|`user` -|string -|The user id of the user that receives the notification. -|=== - -==== Action Element - -[cols="20%,10%,70%",options="header"] -|=== -|Field name -|Type -|Value description - -|`label` -|string -|The translated short label of the action/button that should be presented to the user. - -|`link` -|string -|A link that should be followed when the action is performed/clicked. - -|`primary` -|bool -|If the action is the primary action for the notification or not. - -|`type` -|string -|The HTTP method that should be used for the request against the link. -It can be one of `GET`, `POST`, or `DELETE`. -|=== - -=== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,bash,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/notifications/get-user-notifications.sh[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -==== Curl - -[source,bash,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/notifications/get-user-notifications.sh[] ----- -endif::[] - -NOTE: If the HTTP status code is `204` (No Content), you can slow down the polling to once per hour. -This status code means that there is no app that can generate notifications. - -== Delete a User Notification - -To delete a notification, send a `DELETE` request against `{request-base-path}/apps/notifications/api/v1/notifications/` - -* Path: `{request-base-path}/apps/notifications/api/v1/notifications/` -* Method: `DELETE` - -=== Request Parameters - -[cols="15%,15%,70%",options="header",width=100%] -|=== -|Attribute -|Type -|Description - -|`id` -|integer -|The id of the notification to delete. -|=== - -=== Returns - -On success, the request returns either an {http-status-codes-base-url}/100[HTTP 100 Continue] status code, and no response body. diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-notify-public-link-by-email.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-notify-public-link-by-email.adoc deleted file mode 100644 index f5afdd3..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-notify-public-link-by-email.adoc +++ /dev/null @@ -1,152 +0,0 @@ -= Notify Public Link Via Email -:toc: right -:toclevels: 1 -:request-base-path: ocs/v1.php/apps/files_sharing/api/v1/notification/notify-public-link-by-email - -== Introduction - -The public-files API allows access to public links via WebDAV. - -[cols="40%,30%,30%",options="header",] -|=== -| Request Path -| Method -| Content Type - -| `ocs/v1.php/apps/files_sharing/api/v1/notification/notify-public-link-by-email` -| `POST` -| `text/xml` -|=== - -== Request Parameters - -[cols=",,",options="header",] -|=== -|Attribute -|Type -|Description - -|`format` -|string -|The format to return the response body in. -The allowed options are `json` and `xml` (default). -|=== - -== POST Parameters - -[cols=",,",options="header",] -|=== -|Attribute -|Type -|Description - -|`recipients` -|array of string -|A list of email addresses to send the notification to. - -|`link` -|string -|The public link. - -|`personalNote` -|string -|A personal note to send with the email notification. -|=== - -== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/notify-public-link-by-email.sh[] ----- --- -PHP:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/php/notify-public-link-by-email.php[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -=== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/notify-public-link-by-email.sh[] ----- - -=== PHP - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/php/notify-public-link-by-email.php[] ----- -endif::[] - -== Returns - -=== Example Response - -If the notification is successful, you will see the response below, along with an HTTP 200 status code — _if you specified the format as `json`_. - -[source,xml] ----- -{ - "ocs" : { - "meta" : { - "itemsperpage" : "", - "totalitems" : "", - "status" : "ok", - "statuscode" : 100, - "message" : "OK" - }, - "data" : [] - } -} ----- - -If the notification could not be sent to one or more recipients, you will see the response below, along with an HTTP 200 status code — _if you specified the format as `json`_. - -[source,xml] ----- -{ - "ocs" : { - "data" : [], - "meta" : { - "totalitems" : "", - "statuscode" : 400, - "itemsperpage" : "", - "message" : "Couldn't send mail to following recipient(s): test@email.com", - "status" : "error" - } - } -} ----- - -If public link mail notification is not allowed, then the following response will be returned, along with an HTTP 200 status code. - -[source,xml] ----- - - - - failure - 403 - Public link mail notification is not allowed - - - - - ----- - diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-recipient-api.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-recipient-api.adoc deleted file mode 100644 index 7e94b1e..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-recipient-api.adoc +++ /dev/null @@ -1,69 +0,0 @@ -= OCS Recipient API -:toc: right -:page-aliases: core/ocs-recipient-api.adoc - -== Introduction - -The OCS Recipient API is a new OCS endpoint that is used by the share -dialog autocomplete process, when you pick a user or group to share to. - -The base URL for all calls to the share API is: -_/ocs/v1.php/apps/files_sharing/api/v1/sharees?format=json_&itemType=file - -== Get Shares Recipients - -Get all share recipients for the provided search term. - -* Syntax: /sharees -* Method: GET - -=== Query Attributes - -[cols=",,,,",options="header",] -|======================================================================= -| Attribute | Type | Description | Required | Default -| format | string | The response format. Can be either `xml` or `json` | -| `xml` - -| search | string | The search string | | - -| itemType | string | The type which is shared. | Yes | - -| | | Can be either `file` or `folder` | | - -| shareType | integer | Any one of: | | - -| | | - 0 (user) | | - -| | | - 1 (group) | | - -| | | - 6 (remote) | | - -| page | integer | The page number in the results to be returned | | 1 - -| perPage | integer | The number of items per page | Yes | 200 -|======================================================================= - -=== Status Codes - -[cols=",",options="header",] -|============================================ -| Code | Description -| 100 | Successful -| 400 | Failure due to invalid query parameters -|============================================ - -=== Example Request Response Payloads -If the users admin, user1, user2 and the groups group1 and group2 were registered on a server. - -[source,json] ----- -include::example$core/scripts/responses/recipients/response-success.json[] ----- - -The same request with xml body. - -[source,xml] ----- -include::example$core/scripts/responses/recipients/response-success.xml[] ----- diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-share-api.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-share-api.adoc deleted file mode 100644 index ca2a3a4..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-share-api.adoc +++ /dev/null @@ -1,1323 +0,0 @@ -= OCS Share API -:toc: right -:page-aliases: core/ocs-share-api.adoc -:endpoint-uri: /ocs/v1.php/apps/files_sharing/api/v1/shares - -== Introduction - -The OCS Share API allows you to access the sharing API from outside over pre-defined OCS calls. -The base URL for all calls to the share API is: `{endpoint-uri}`. - -== Local Shares - -=== Get All Shares - -Get all shares shared with a user. - -[cols="20%,80%"] -|=== -|*Endpoint* |`{endpoint-uri}` -|*Method* |GET -|=== - -==== Request Attributes - -[cols="20%,15%,65%",options="header",] -|=== -|Attribute -|Type -|Description - -|`format` -|string -|sets the output format of the response. -Default value is `xml`. -Available options are `xml` and `json`. - -|`path` -|string -|limit the shares to those in a specific path. - -|`reshares` -|boolean -|returns not only the shares shared with the current user but all shares. - -|`shared_with_me` -|string -|limits the returned shares to only those shared with the authenticating user. - -|`state` -|string -a|limits the returned shares to only those with the specified state. -Available options are `accepted`, `all`, `declined`, `pending`, and `rejected`. - -NOTE: This attribute is only valid when `shared_with_me` is set. - -NOTE: `declined` and `rejected` are interchangeable. - -|`subfiles` -|boolean -|returns all shares within a folder, given that path defines a folder. -This option requires the path option to be specified. -|=== - -==== Status Codes - -[cols="20%,80%",options="header",] -|=== -| Code | Description -| 100 | Successful. -| 400 | Not a directory (if the `subfile' argument was used). -| 404 | Couldn't fetch shares or file doesn't exist. -| 997 | Unauthorised. -|=== - -==== Example Request Response Payloads - -If the user that you're connecting with is not authorized, then you will see output similar to the following: - -[source,xml] ----- -include::example$core/scripts/responses/not-authorised-response.xml[] ----- - -If the user that you're connecting with _is_ authorized, then you will see output similar to the following: - -[source,xml] ----- -include::example$core/scripts/responses/shares/get-all-shares-success-no-shares.xml[] ----- - -[source,xml] ----- -include::example$core/scripts/responses/shares/list-share-details-failure.xml[] ----- - -.Files shared with the current user in XML format. -[source,xml] ----- -include::example$core/scripts/responses/shares/list-share-details-success.xml[] ----- - -.Files shared with the current user in JSON format. -[source,json] ----- -include::example$core/scripts/responses/shares/list-share-details-success.json[] ----- - -==== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/list-share-details.sh[] ----- --- -PHP:: -+ --- -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/list-share-details.php[] ----- --- -Ruby:: -+ --- -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/list-share-details.rb[] ----- --- -Go:: -+ --- -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/list-share-details.go[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/list-share-details.sh[] ----- - -===== PHP - -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/list-share-details.php[] ----- - -===== Ruby - -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/list-share-details.rb[] ----- - -===== Go - -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/list-share-details.go[] ----- -endif::[] - -=== Get Information About A Known Share - -[cols="20%,80%"] -|=== -|Endpoint |`{endpoint-uri}/` -|Method |GET -|=== - -==== Supported Attributes - -[cols=",,",options="header",] -|=== -| Attribute | Type | Description -| share_id | int | The share's unique id -|=== - -==== Response Status Codes - -[cols="20%,80%",options="header",] -|=== -| Code | Description -| 100 | Successful -| 404 | Share doesn't exist -|=== - -==== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/get-share-info.sh[] ----- --- -PHP:: -+ --- -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/get-share-info.php[] ----- --- -Ruby:: -+ --- -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/get-share-info.rb[] ----- --- -Go:: -+ --- -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/get-share-info.go[] ----- --- -Kotlin:: -+ --- -[source,kotlin,subs="attributes+"] ----- -include::example$core/scripts/kotlin/get-share-info.kt[] ----- --- -Java:: -+ --- -[source,java,subs="attributes+"] ----- -include::example$core/scripts/java/get-share-info.java[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/get-share-info.sh[] ----- - -===== PHP - -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/get-share-info.php[] ----- - -===== Ruby - -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/get-share-info.rb[] ----- - -===== Go - -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/get-share-info.go[] ----- - -===== Kotlin - -[source,kotlin,subs="attributes+"] ----- -include::example$core/scripts/kotlin/get-share-info.kt[] ----- - -===== Java - -[source,java,subs="attributes+"] ----- -include::example$core/scripts/java/get-share-info.java[] ----- -endif::[] - -NOTE: The Java and Kotlin examples use https://github.com/square/okhttp[the square/okhttp library]. - -==== Example Response Payloads - -ifndef::format[] -[tabs] -==== -Success:: -+ --- -[source,console] ----- -include::example$core/scripts/responses/shares/get-share-info-success.xml[] ----- --- -Failure:: -+ --- -[source,console] ----- -include::example$core/scripts/responses/shares/get-share-info-failure.xml[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== Success - -[source,console] ----- -include::example$core/scripts/responses/shares/get-share-info-success.xml[] ----- - -===== Failure - -[source,console] ----- -include::example$core/scripts/responses/shares/get-share-info-failure.xml[] ----- -endif::[] - -==== Response Attributes - -For details about the elements in the XML response payload please refer to the Response Attributes section of xref:response-attributes[the Create a New Share section] below. - -=== Accept a Pending Share - -[cols="20%,80%"] -|=== -|Endpoint |`{endpoint-uri}/` -|Method |POST -|=== - -==== Request Attributes - -[cols="20%,15%,65%",options="header",] -|=== -|Attribute -|Type -|Description - -|share id -|integer -|the id of the pending share to accept. -Pending share ids are available in xref:get-all-shares[the get all shares response]. -|=== - -==== Status Codes - -[cols="20%,80%",options="header",] -|=== -|Code -|Description - -|200 -a| -* Pending share successfully accepted. -* Share doesn't exist. -|=== - -==== Example Request Response Payloads - -ifndef::format[] -[tabs] -==== -Success:: -+ --- -.Pending share was successfully accepted -[source,console] ----- -include::example$core/scripts/responses/shares/accept-pending-share-success.xml[] ----- --- -Failure:: -+ --- -.The share id does not exist. -[source,console] ----- -include::example$core/scripts/responses/shares/accept-pending-share-failure.xml[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== Success - -.Pending share was successfully accepted -[source,console] ----- -include::example$core/scripts/responses/shares/accept-pending-share-success.xml[] ----- - -===== Failure - -.The share id does not exist. -[source,console] ----- -include::example$core/scripts/responses/shares/accept-pending-share-failure.xml[] ----- -endif::[] - -==== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/accept-pending-share.sh[] ----- --- -PHP:: -+ --- -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/accept-pending-share.php[] ----- --- -Ruby:: -+ --- -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/accept-pending-share.rb[] ----- --- -Go:: -+ --- -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/accept-pending-share.go[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/accept-pending-share.sh[] ----- - -===== PHP - -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/accept-pending-share.php[] ----- - -===== Ruby - -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/accept-pending-share.rb[] ----- - -===== Go - -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/accept-pending-share.go[] ----- -endif::[] - -=== Decline a Pending Share - -[cols="20%,80%"] -|=== -|Endpoint |`{endpoint-uri}/` -|Method |DELETE -|=== - -==== Request Attributes - -[cols="20%,15%,65%",options="header",] -|=== -|Attribute -|Type -|Description - -|share id -|integer -|the id of the pending share to decline. -Pending share ids are available in xref:get-all-shares[the get all shares response]. -|=== - -==== Status Codes - -[cols=",",options="header",] -|=== -|Code -|Description - -|200 -a| -* Pending share successfully declined (one or more times). -* Share doesn't exist. -|=== - -==== Example Request Response Payloads - -.A pending share is successfully declined. -[source,xml] ----- - - - - ok - 100 - - - - - - ----- - -.The share id does not exist or the pending share has already been declined. -[source,xml] ----- - - - - failure - 404 - Wrong share ID, share doesn't exist - - - - - ----- - -==== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/decline-pending-share.sh[] ----- --- -PHP:: -+ --- -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/decline-pending-share.php[] ----- --- -Ruby:: -+ --- -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/decline-pending-share.rb[] ----- --- -Go:: -+ --- -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/decline-pending-share.go[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/decline-pending-share.sh[] ----- --- -===== PHP - -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/decline-pending-share.php[] ----- - -===== Ruby - -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/decline-pending-share.rb[] ----- - -===== Go - -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/decline-pending-share.go[] ----- -endif::[] - -=== Create A New Share - -Share an existing file or folder with a user, a group, or as a public link. - -[cols="20%,80%"] -|=== -|Endpoint |`{endpoint-uri}` -|Method |POST -|=== - -==== Function Arguments - -[width="100%",cols="27%,11%,62%",options="header",] -|=== -| Argument | Type | Description -| name | string | A (human-readable) name for the share, which can be up to -64 characters in length. - -| path | string | The path to the file or folder which should be shared. - -| shareType | int a| -The type of the share. This can be one of: - -* 0 = user -* 1 = group -* 3 = public link -* 6 = federated cloud share - -| shareWith | string | The user or group id with which the file should be shared. - -| publicUpload | boolean | Whether to allow public upload to a public link shared folder. - -| password | string | The password to protect the public link share with. - -| permissions | int -a| -The permissions to set on the share. - -* 1 = read (default for public link shares); -* 2 = update; -* 4 = create; -* 8 = delete; -* 16 = share; - -Common example combinations are: - -* 15 = read/write(update and create)/delete; -* 31 = All permissions. - -| expireDate -| string -| An expire date for the user, group or public link share. -This argument expects a date string in the following format `'YYYY-MM-DD'`. -The share expires at the end of the specified day. - -| attributes -| array -| Contain a set of one or more permissions to set for a share. -The list of available permissions can be obtained from a request to xref:core/apis/roles-api.adoc[the Roles API]. -|=== - -[NOTE] -==== -Things to remember about public link shares - -* Files can only ever have the *read* and *update* permission set -* Folders can have *read*, *update*, *create*, and *delete* set -* Public link shares *cannot* be shared with users and groups -* Public link shares are not available if public link sharing is disabled by the administrator -* When creating a public link share of a folder, specify permissions 15 to give download/view/edit access -* When creating a public link share of a single file, also specify permissions 15 in the API request to give download/view/edit access. The public link share will actually be given permissions 3 (read and update) because create and delete permissions are not relevant for single file shares - -*Mandatory Fields* - -`shareType` is mandatory; `path` and `shareWith` are mandatory if `shareType` is set to 0 or 1 -==== - -==== Returns - -XML containing the share ID (int) of the newly created share - -==== Status Codes - -[cols="20%,80%",options="header",] -|=== -| Code | Description -| 100 | Successful -| 400 | Unknown share type -| 403 | Public upload was disabled by the admin -| 404 | File or folder couldn't be shared -|=== - -==== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/create-share.sh[] ----- --- -PHP:: -+ --- -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/create-share.php[] ----- --- -Ruby:: -+ --- -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/create-share.rb[] ----- --- -Go:: -+ --- -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/create-share.go[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/create-share.sh[] ----- - -===== PHP - -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/create-share.php[] ----- - -===== Ruby - -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/create-share.rb[] ----- - -===== Go - -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/create-share.go[] ----- -endif::[] - -==== Example Request Response Payloads - -Failure - -[source,xml] ----- -include::example$core/scripts/responses/shares/create-share-failure.xml[] ----- - -Success - -[source,xml] ----- -include::example$core/scripts/responses/shares/create-share-success.xml[] ----- - -==== Response Attributes - -[width="100%",cols="27%,11%,62%",options="header",] -|=== -| Argument | Type | Description -| id | int | The share's unique id. - -| share_type | int a| -The share's type. This can be one of: - -* 0 = user -* 1 = group -* 3 = public link -* 6 = federated cloud share - -| uid_owner | string | The username of the owner of the share. - -| displayname_owner | string | The display name of the owner of the share. - -| permissions | octal a | -The permission attribute set on the file. Options are: - -* 1 = Read -* 2 = Update -* 4 = Create -* 8 = Delete -* 16 = Share -* 31 = All permissions - -The default is 31, and for public link shares is 1. - -| stime | int | The UNIX timestamp when the share was created. - -| parent | int | The UNIX timestamp when the share was created. - -| expiration | string | The date when the share expires, in format YYYY-MM-DD 00:00:00. - -| token | string | The public link to the item being shared. - -| uid_file_owner | string | The unique id of the user that owns the file or -folder being shared. - -| displayname_file_owner | string | The display name of the user that owns -the file or folder being shared. - -| path | string | The path to the shared file or folder. - -| item_type | string | The type of the object being shared. This can be one -of file or folder. - -| mimetype | string | The https://tools.ietf.org/html/rfc2045[RFC-compliant mimetype] of the file. - -| storage_id | string | - -| storage | int | - -| item_source | int | The unique node id of the item being shared. - -| file_source | int | The unique node id of the item being shared. For -legacy reasons item_source and file_source attributes have the same value. - -| file_parent | int | The unique node id of the parent node of the item being shared. - -| file_target | int | The name of the shared file. - -| share_with | string | The uid of the receiver of the file. This is either -a GID (group id) if it is being shared with a group or a UID (user id) -if the share is shared with a user. - -| share_with_displayname | string | The display name of the receiver of the file. - -| url | string | - -| mail_send | int | Whether the recipient was notified, by mail, about the -share being shared with them. - -| name | string | A (human-readable) name for the share, which can be up to -64 characters in length -|=== - -=== Delete A Share - -Remove the given share. - -[cols="20%,80%"] -|=== -| Endpoint -| `{endpoint-uri}/` - -| Method -| DELETE -|=== - -[cols=",,",options="header",] -|=== -| Attribute -| Type - -| Description -| share_id - -| int -| The share's unique id -|=== - -==== Status Codes - -[cols="20%,80%",options="header",] -|=== -| Code | Description -| 100 | Successful -| 404 | Share couldn't be deleted -|=== - -==== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/delete-share.sh[] ----- --- -PHP:: -+ --- -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/delete-share.php[] ----- --- -Ruby:: -+ --- -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/delete-share.rb[] ----- --- -Go:: -+ --- -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/delete-share.go[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -Curl -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/delete-share.sh[] ----- --- -PHP:: -+ --- -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/delete-share.php[] ----- --- -Ruby:: -+ --- -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/delete-share.rb[] ----- --- -Go:: -+ --- -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/delete-share.go[] ----- -endif::[] - -==== Example Request Response Payloads - -Failure - -[source,xml] ----- -include::example$core/scripts/responses/shares/delete-share-success.xml[] ----- - -Success - -[source,xml] ----- -include::example$core/scripts/responses/shares/delete-share-failure.xml[] ----- - -=== Update Share - -Update a given share. -Only one value can be updated per request. - -[cols=","] -|=== -| Endpoint -| `{endpoint-uri}/` - -| Method -| PUT -|=== - -==== Request Arguments - -[cols=",,",options="header"] -|=== -| Argument -| Type -| Description - -| name -| string -| A (human-readable) name for the share, which can - -| -| -| be up to 64 characters in length - -| share_id -| int -| The share's unique id - -| permissions -| int -| Update permissions - -| -| -| (see xref:create-a-new-share[the create share section] above) - -| password -| string -| Updated password for a public link share - -| publicUpload -| boolean -| Enable (true) / disable (false) - -| -| -| public upload for public link shares. - -| expireDate -| string -a| Set an expire date for the user, group or public link share. + -This argument expects a well-formatted date string such as: `YYYY-MM-DD` -|=== - -NOTE: Only one of the update parameters can be specified at once. - -==== Status Codes - -[cols=",",options="header",] -|=== -| Code | Description -| 100 | Successful -| 400 | Wrong or no update parameter given -| 403 | Public upload disabled by the admin -| 404 | Couldn't update share -|=== - -==== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/update-share.sh[] ----- --- -PHP:: -+ --- -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/update-share.php[] ----- --- -Ruby:: -+ --- -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/update-share.rb[] ----- --- -Go:: -+ --- -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/update-share.go[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/update-share.sh[] ----- - -===== PHP - -[source,php,subs="attributes+"] ----- -include::example$core/scripts/php/update-share.php[] ----- - -===== Ruby - -[source,ruby,subs="attributes+"] ----- -include::example$core/scripts/ruby/update-share.rb[] ----- - -===== Go - -[source,go,subs="attributes+"] ----- -include::example$core/scripts/go/update-share.go[] ----- -endif::[] - -==== Example Request Response Payloads - -Failure - -[source,xml] ----- -include::example$core/scripts/responses/shares/update-share-failure.xml[] ----- - -Success - -[source,xml] ----- -include::example$core/scripts/responses/shares/update-share-success.xml[] ----- - -== Federated Cloud Shares - -Both the sending and the receiving instance need to have federated cloud sharing enabled and configured. -See xref:admin_manual:configuration/files/federated_cloud_sharing_configuration.adoc[Configuring Federated Cloud Sharing]. - -=== Create A New Federated Cloud Share - -Creating a federated cloud share can be done via the local share -endpoint, using (int) 6 as a shareType and the -https://owncloud.com/features/federated-cloud-sharing/[Federated Cloud ID] of the share -recipient as shareWith. See xref:create-a-new-share[Create a new Share] for more information. - -=== List Accepted Federated Cloud Shares - -Get all federated cloud shares the user has accepted. - -* Syntax: /remote_shares -* Method: GET - -==== Returns - -XML with all accepted federated cloud shares - -==== Status Codes - -[cols=",",options="header",] -|=== -| Code | Description -| 100 | Successful -|=== - -=== Get Information About A Known Federated Cloud Share - -Get information about a given received federated cloud share that was sent from a remote instance. - -* Syntax: /remote_shares/ -* Method: GET - -[cols=",,",options="header",] -|=== -| Attribute | Type | Description -| share_id | int | The share id as listed in the id field -| | | in the `remote_shares` list -|=== - -==== Returns - -XML with the share information - -==== Status Codes - -[cols=",",options="header",] -|=== -| Code | Description -| 100 | Successful -| 404 | Share doesn't exist -|=== - -=== Delete An Accepted Federated Cloud Share - -Locally delete a received federated cloud share that was sent from a remote instance. - -* Syntax: /remote_shares/ -* Method: DELETE - -[cols=",,",options="header",] -|=== -| Attribute | Type | Description -| share_id | int | The share id as listed in the id field -| | | in the `remote_shares` list -|=== - -==== Status Codes - -[cols=",",options="header",] -|=== -| Code | Description -| 100 | Successful -| 404 | Share doesn't exist -|=== - -=== List Pending Federated Cloud Shares - -Get all pending federated cloud shares the user has received. - -* Syntax: /remote_shares/pending -* Method: GET - -==== Returns - -XML with all pending federated cloud shares - -==== Status Codes - -[cols=",",options="header",] -|=== -| Code | Description -| 100 | Successful -| 404 | Share doesn't exist -|=== - -=== Accept a Pending Federated Cloud Share - -Locally accept a received federated cloud share that was sent from a remote instance. - -* Syntax: /remote_shares/pending/** -* Method: POST - -[cols=",,",options="header",] -|=== -| Attribute | Type | Description -| share_id | int | The share id as listed in the id field -| | | in the `remote_shares/pending` list -|=== - -==== Status Codes - -[cols=",",options="header",] -|=== -| Code | Description -| 100 | Successful -| 404 | Share doesn't exist -|=== - -=== Decline a Pending Federated Cloud Share - -Locally decline a received federated cloud share that was sent from a remote instance. - -* Syntax: /remote_shares/pending/ -* Method: DELETE - -[cols=",,",options="header",] -|=== -| Attribute | Type | Description -| share_id | int | The share id as listed in the id field -| | | in the `remote_shares/pending` list -|=== - -==== Status Codes - -[cols=",",options="header",] -|=== -| Code | Description -| 100 | Successful -| 404 | Share doesn't exist -|=== diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-totp-validation-api.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-totp-validation-api.adoc deleted file mode 100644 index c6d02bf..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-totp-validation-api.adoc +++ /dev/null @@ -1,206 +0,0 @@ -= OCS TOTP (Time-based One-time Password) Validation API -:toc: right -:toclevels: 1 -:request-base-path: ocs/v1.php/apps/twofactor_totp/api/v1/validate -:2fa-app-url: {oc-marketplace-url}/apps/twofactor_totp -:totp-url: https://en.wikipedia.org/wiki/Time-based_One-time_Password_algorithm - -== Introduction - -The OCS {totp-url}[TOTP (Time-based One-time Password)] Validation API allows administrator users to validate if a TOTP is valid. - -IMPORTANT: Only admin accounts can use this API. - -IMPORTANT: When {2fa-app-url}[2FA (Two-Factor Authentication)] is activated on an account, authorization with a username and password is not possible. -Requests must authenticate via xref:classic_ui:session_management.adoc#app-passwords[app passwords]. - -== Prerequisites - -This API requires {2fa-app-url}[the 2-Factor Authentication app] to be installed and enabled. - -== Validate TOTP - -* Path: `{request-base-path}//` -* Method: `GET` - -=== Request Parameters - -[cols="15%,15%,70%",options="header",width=100%] -|=== -|Attribute -|Type -|Description - -|`userid` -|string -|The user id of the user to validate the TOTP for. - -|`totp` -|string -|The TOTP to validate. -|=== - -=== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/validate-totp.sh[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/validate-totp.sh[] ----- --- -endif::[] - -=== Returns - -The request returns either an XML (the default) or a JSON response, along with an `HTTP 200 OK` status code, which show whether: - -. The TOTP is valid -. The TOTP is invalid -. The user was not found - -The status of the TOTP is located in the `ocs/data/result` element. -If the user was not found, then: - -. `ocs/meta/status` will be set to `failure`. -. `ocs/meta/statuscode` will be set to `404`. - -=== Example Responses - -==== TOTP Is Valid - -ifndef::format[] -[tabs] -==== -JSON:: -+ --- -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/json/totp-is-valid.json[] ----- --- - -XML:: -+ --- -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/xml/totp-is-valid.xml[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== JSON - -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/json/totp-is-valid.json[] ----- - -===== XML - --- -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/xml/totp-is-valid.xml[] ----- -endif::[] - -==== TOTP Is Not Valid - -ifndef::format[] -[tabs] -==== -JSON:: -+ --- -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/json/totp-is-invalid.json[] ----- --- - -XML:: -+ --- -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/xml/totp-is-invalid.xml[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== JSON - -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/json/totp-is-invalid.json[] ----- - -===== XML - -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/xml/totp-is-invalid.xml[] ----- -endif::[] - -==== User or Secret Not Found - -ifndef::format[] -[tabs] -==== -JSON:: -+ --- -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/json/totp-user-is-not-found.json[] ----- --- - -XML:: -+ --- -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/xml/totp-user-is-not-found.xml[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -===== JSON - -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/json/totp-user-is-not-found.json[] ----- - -===== XML - -[source,console] ----- -include::example$core/apis/ocs/totp-validation/responses/xml/totp-user-is-not-found.xml[] ----- -endif::[] - diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-user-sync-api.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-user-sync-api.adoc deleted file mode 100644 index 4ef80a3..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/ocs-user-sync-api.adoc +++ /dev/null @@ -1,96 +0,0 @@ -= OCS User Sync API -:toc: right -:toclevels: 1 -:request-base-path: ocs/v2.php - -== Introduction - -This endpoint triggers user-sync for a specific user. - -* Path: `{request-base-path}/cloud/user-sync/` -* Method: `POST` - -== Requirements - -This endpoint can only be executed by a user with admin privileges. -We suggest creating a technical user who is in the admin group to run this command with. - -== Request Parameters - -[cols="15%,15%,70%",options="header",width=100%] -|=== -|Attribute -|Type -|Description - -|`userid` -|string -|The id of the user to trigger a sync for. -|=== - -== Returns - -The request returns the following status codes. - -[cols="30%,70%",options="header"] -|=== -|Status Code -|When... - -|`HTTP 200 OK` -|The user sync was executed. - -|`HTTP 404 Not Found` -|The supplied user id is unknown. - -|`HTTP 409 Conflict` -|Multiple users have been found for the given user id. -|=== - -== Example Responses - -[source,xml] ----- -include::example$core/apis/ocs/user-sync/successful-response.xml[] ----- - -== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/user-sync.sh[] ----- --- - -PHP:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/php/ocs/user-sync.php[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -=== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/ocs/user-sync.sh[] ----- - -=== PHP - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/php/ocs/user-sync.php[] ----- -endif::[] diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/provisioning-api.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/provisioning-api.adoc deleted file mode 100644 index ca6b790..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/provisioning-api.adoc +++ /dev/null @@ -1,1165 +0,0 @@ -= Provisioning API -:toc: right -:page-aliases: go/admin-provisioning-api.adoc - -== Introduction - -The Provisioning API application enables a set of APIs that external -systems can use to: - -* Create, edit, delete and query user attributes -* Query, set and remove groups -* Set quota and query total storage used in ownCloud -* Group admin users can also query ownCloud and perform the same -functions as an admin for groups they manage. -* Query for active ownCloud applications, application info, and to -enable or disable an app. - -HTTP requests can be used via -https://en.wikipedia.org/wiki/Basic_access_authentication[a Basic Auth header] -to perform any of the functions listed above. The Provisioning -API app is enabled by default. The base URL for all calls to the share -API is *owncloud_base_url/ocs/v1.php/cloud*. - -== Instruction Set For Users - -=== Add User - -Create a new user on the ownCloud server. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -==== Syntax - -[cols=",,",options="header",] -|=== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users` | `POST` | `text/plain` -|=== - -[cols="15%,15%,70%",options="header",] -|=== -| Argument -| Type -| Description - -| `groups` -| array -| Groups to add the user to (_optional_). -Groups must already exist. - -| `password` -| string -| The required password for the new user. - -| `userid` -| string -| The required username for the new user. -|=== - -==== Status Codes - -* 100 - successful -* 101 - invalid input data -* 102 - username already exists -* 103 - unknown error occurred whilst adding the user -* 104 - group does not exist - -==== Usage Examples - -.Create the user "Frank" with password "frankspassword". -[source,console] ----- -curl -X POST http://admin:secret@example.com/ocs/v1.php/cloud/users \ - -d userid="Frank" \ - -d password="frankspassword" ----- - -.Create the user "Frank" with password "frankspassword" and add him to the "finance" and "management" groups. -[source,console] ----- -curl -X POST http://admin:secret@example.com/ocs/v1.php/cloud/users \ - -d userid="Frank" \ - -d password="frankspassword" \ - -d groups[]="finance" -d groups[]="management" ----- - -==== XML Output - -[source,xml] ----- - - - - ok - 100 - - - - ----- - -=== Get Users - -Retrieves a list of users from the ownCloud server. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|============================================= -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users` | `GET` | `text/plain` -|============================================= - -[cols=",,",options="header",] -|====================================== -| Argument | Type | Description -| search | string | optional search string -| limit | int | optional limit value -| offset | int | optional offset value -|====================================== - -==== Status Codes - -* 100 - successful - -==== Get Users Example - -[source,console] ----- -# Returns list of users matching the search string. -curl http://admin:secret@example.com/ocs/v1.php/cloud/users?search=Frank ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - - Frank - - - ----- - -=== Get User - -Retrieves information about a single user. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|============================================================== -|Request Path |Method |Content Type -| `Syntax: ocs/v1.php/cloud/users/\{userid\}` | `GET` | `text/plain` -|============================================================== - -[cols=",,",options="header",] -|======================================= -| Argument | Type | Description -| userid | int | Id of the user to retrieve -|======================================= - -==== Status Codes - -* 100 - successful - -==== Get User Example - -[source,xml] ----- -# Returns information on the user "Frank" -curl http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank ----- - -==== XML Output - -[source,xml] ----- - - - - ok - 100 - - - - true - - 81919008768 - 5809166 - 81924817934 - 0.01 - - user@example.com - Frank - /mnt/data/files/Frank - false - 1635846303 - - ----- - -==== File Storage Space Quota Response Fields - -free:: -The number of bytes of quota remaining - -used:: -The number of bytes of quota currently used - -total:: -The total number of bytes of storage that the user has permission to use - -relative:: -The percentage of quota currently used - -==== Last Login Response Field - -The `last_login` response field contains a Unix timestamp number of seconds that represents the date-time that the user last accessed the ownCloud server. Accesses include all requests by the user, such as using the webUI and syncing to/from clients. - -If the user has not yet logged in then `last_login` is zero. - -=== Edit User - -Edits attributes related to a user. Users are able to edit _email_, -_displayname_ and _password_; admins can also edit the _quota_ value. -Exactly one attribute can be set or modified at a time. -To set or modify multiple attributes then multiple calls must be made. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|====================================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}` | `PUT` | `text/plain` -|====================================================== - -[cols=",,",options="header",] -|================================================================ -| Argument | Type | Description -| key | string | the field to edit (email, quota, display, password) -| value | mixed | the new value for the field -|================================================================ - -==== Status Codes - -* 100 - successful -* 101 - user not found -* 102 - invalid input data - -==== Edit User Example - -[source,console] ----- -Updates the email address for the user "Frank" -curl -X PUT http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank \ - -d key="email" \ - -d value="franksnewemail@example.org" - -Updates the quota for the user "Frank" -curl -X PUT http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank \ - -d key="quota" \ - -d value="100MB" ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - ----- - -=== Enable User - -Enables a user on the ownCloud server. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols="2,1,1",options="headers"] -|=== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}/enable` | `PUT` | `text/plain` -|=== - -[cols="1,1,2",options="headers"] -|=== -| Argument | Type | Description -| userid | string | The id of the user to enable -|=== - -==== Status Codes - -* 100 - successful -* 101 - failure - -==== Enable User Example - -[source,console] ----- -# Enable the user with the userid "Frank" -curl -X PUT http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank/enable ----- - -==== XML Output - -[source,xml] ----- - - - - ok - 100 - - - - ----- - -=== Disable User - -Disables a user on the ownCloud server. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols="2,1,1",options="headers"] -|=== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}/disable` | `PUT` | `text/plain` -|=== - -[cols="1,1,2",options="headers"] -|=== -| Argument | Type | Description -| userid | string | The id of the user to disable -|=== - -==== Status Codes - -* 100 - successful -* 101 - failure - -==== Disable User Example - -[source,console] ----- -# Disable the user "Frank" -curl -X PUT http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank/disable ----- - -==== XML Output - -[source,xml] ----- - - - - ok - 100 - - - - ----- - - -=== Delete User - -Deletes a user from the ownCloud server. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|========================================================= -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}` | `DELETE` | `text/plain` -|========================================================= - -[cols=",,",options="header",] -|============================================ -| Argument | Type | Description -| userid | string | The id of the user to delete -|============================================ - -==== Status Codes - -* 100 - successful -* 101 - failure - -==== Delete User Example - -[source,console] ----- -# Deletes the user "Frank" -curl -X DELETE http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - ----- - -=== Get Groups - -Retrieves a list of groups the specified user is a member of. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|============================================================= -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}/groups` | `GET` | `text/plain` -|============================================================= - -[cols=",,",options="header",] -|========================================================= -| Argument | Type | Description -| userid | string | The id of the user to retrieve groups for -|========================================================= - -==== Status Codes - -* 100 - successful - -==== Get Groups Example - -[source,console] ----- -# Retrieves a list of groups of which "Frank" is a member -curl http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank/groups ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - - admin - group1 - - - ----- - -=== Add To Group - -Adds the specified user to the specified group. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|============================================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}/groups` | `POST` | `text/plain` -|============================================================== - -[cols=",,",options="header",] -|========================================================= -| Argument | Type | Description -| userid | string | The id of the user to retrieve groups for -| groupid | string | The group to add the user to -|========================================================= - -==== Status Codes - -* 100 - successful -* 101 - no group specified -* 102 - group does not exist -* 103 - user does not exist -* 104 - insufficient privileges -* 105 - failed to add user to group - -==== Add To Group Example - -[source,console] ----- -# Adds the user "Frank" to the group "newgroup" -curl -X POST http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank/groups -d groupid="newgroup" ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - ----- - -=== Remove From Group - -Removes the specified user from the specified group. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|================================================================ -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}/groups` | `DELETE` | `text/plain` -|================================================================ - -[cols=",,",options="header",] -|========================================================= -| Argument | Type | Description -| userid | string | The id of the user to retrieve groups for -| groupid | string | The group to remove the user from -|========================================================= - -==== Status Codes - -* 100 - successful -* 101 - no group specified -* 102 - group does not exist -* 103 - user does not exist -* 104 - insufficient privileges -* 105 - failed to remove user from group - -==== Remove From Group Example - -[source,console] ----- -# Removes the user "Frank" from the group "newgroup" -curl -X DELETE http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank/groups -d groupid="newgroup" ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - ----- - -=== Create Sub-admin - -Makes a user the sub-admin of a group. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|================================================================= -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}/subadmins` | `POST` | `text/plain` -|================================================================= - -[cols=",,",options="header",] -|================================================================ -| Argument | Type | Description -| userid | string | The id of the user to be made a sub-admin -| groupid | string | the group of which to make the user a sub-admin -|================================================================ - -==== Status Codes - -* 100 - successful -* 101 - user does not exist -* 102 - group does not exist -* 103 - unknown failure - -==== Create Sub-admin Example - -[source,console] ----- -# Makes the user "Frank" a sub-admin of the "group" group -curl -X POST https://admin:secret@example.com/ocs/v1.php/cloud/users/Frank/subadmins -d groupid="group" ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - ----- - -=== Remove Sub-admin - -Removes the sub-admin rights for the user specified from the group -specified. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|=================================================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}/subadmins` | `DELETE` | `text/plain` -|=================================================================== - -[cols=",,",options="header",] -|======================================================================= -| Argument | Type | Description -| userid | string | the id of the user to retrieve groups for - -| groupid | string | the group from which to remove the user’s sub-admin -rights -|======================================================================= - -==== Status Codes - -* 100 - successful -* 101 - user does not exist -* 102 - user is not a sub-admin of the group / group does not exist -* 103 - unknown failure - -==== Remove Sub-admin Example - ----- -# Removes "Frank's" sub-admin rights from the "oldgroup" group -curl -X DELETE https://admin:secret@example.com/ocs/v1.php/cloud/users/Frank/subadmins -d groupid="oldgroup" ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - ----- - -=== Get Sub-admin Groups - -Returns the groups in which the user is a sub-admin. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|================================================================ -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/users/\{userid\}/subadmins` | `GET` | `text/plain` -|================================================================ - -[cols=",,",options="header",] -|=================================================================== -| Argument | Type | Description -| userid | string | The id of the user to retrieve sub-admin groups for -|=================================================================== - -==== Status Codes - -* 100 - successful -* 101 - user does not exist -* 102 - unknown failure - -==== Get Sub-admin Groups Example - -[source,console] ----- -# Returns the groups of which "Frank" is a sub-admin -curl -X GET https://admin:secret@example.com/ocs/v1.php/cloud/users/Frank/subadmins ----- - -==== XML Output - -[source,xml] ----- - - - - ok - 100 - - - - testgroup - - ----- - -== Instruction Set For Groups - -=== Get Groups - -Retrieves a list of groups from the ownCloud server. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|============================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/groups` | `GET` | `text/plain` -|============================================== - -[cols=",,",options="header",] -|====================================== -| Argument | Type | Description -| search | string | optional search string -| limit | int | optional limit value -| offset | int | optional offset value -|====================================== - -==== Status Codes - -* 100 - successful - -==== Get Groups Example - -[source,console] ----- -# Returns list of groups matching the search string. -curl http://admin:secret@example.com/ocs/v1.php/cloud/groups?search=admi ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - - admin - - - ----- - -=== Add Group - -Adds a new group. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|=============================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/groups` | `POST` | `text/plain` -|=============================================== - -[cols=",,",options="header",] -|===================================== -| Argument | Type | Description -| groupid | string | the new group’s name -|===================================== - -==== Status Codes - -* 100 - successful -* 101 - invalid input data -* 102 - group already exists -* 103 - failed to add the group - -==== Add Group Example - -[source,console] ----- -# Adds a new group called "newgroup" -curl -X POST http://admin:secret@example.com/ocs/v1.php/cloud/groups -d groupid="newgroup" ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - ----- - -=== Get Group - -Retrieves a list of group members. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|======================================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/groups/\{groupid\}` | `GET` | `text/plain` -|======================================================== - -[cols=",,",options="header",] -|==================================================== -| Argument | Type | Description -| groupid | string | The group id to return members from -|==================================================== - -==== Status Codes - -* 100 - successful - -==== Get Group Example - -[source,console] ----- -# Returns a list of users in the "admin" group -curl http://admin:secret@example.com/ocs/v1.php/cloud/groups/admin ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - - Frank - - - ----- - -=== Get Sub-admins - -Returns sub-admins of the group. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|================================================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/groups/\{groupid\}/subadmins` | `GET` | `text/plain` -|================================================================== - -[cols=",,",options="header",] -|=================================================== -| Argument | Type | Description -| groupid | string | The group id to get sub-admins for -|=================================================== - -==== Status Codes - -* 100 - successful -* 101 - group does not exist -* 102 - unknown failure - -==== Get Sub-admins Example - -[source,console] ----- -# Return the sub-admins of the group: "mygroup" -curl https://admin:secret@example.com/ocs/v1.php/cloud/groups/mygroup/subadmins ----- - -==== XML Output - -[source,xml] ----- - - - - ok - 100 - - - - Tom - - ----- - -=== Delete Group - -Removes a group. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|=========================================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/groups/\{groupid\}` | `DELETE` | `text/plain` -|=========================================================== - -[cols=",,",options="header",] -|==================================== -| Argument | Type | Description -| groupid | string | the group to delete -|==================================== - -==== Status Codes - -* 100 - successful -* 101 - group does not exist -* 102 - failed to delete group - -==== Delete Group Example - -[source,console] ----- -# Delete the group "mygroup" -curl -X DELETE http://admin:secret@example.com/ocs/v1.php/cloud/groups/mygroup ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - ----- - -== Instruction Set For Apps - -=== Get Apps - -Returns a list of apps installed on the ownCloud server. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|============================================= -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/apps/` | `GET` | `text/plain` -|============================================= - -[cols=",,",options="header",] -|====================================================== -| Argument | Type | Description -| filter | string | Whether to retrieve enabled or disable -| | | apps. Available values are `enabled` -| | | and `disabled`. -|====================================================== - -==== Status Codes - -* 100 - successful -* 101 - invalid input data - -==== Get Apps Example - -[source,console] ----- -# Gets enabled apps -curl http://admin:secret@example.com/ocs/v1.php/cloud/apps?filter=enabled ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - - files - provisioning_api - - - ----- - -=== Get App Info - -Provides information on a specific application. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|==================================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/apps/\{appid\}` | `GET` | `text/plain` -|==================================================== - -[cols=",,",options="header",] -|================================================== -| Argument | Type | Description -| appid | string | The app to retrieve information for -|================================================== - -==== Status Codes - -* 100 - successful - -==== Get App Info Example - -[source,console] ----- -# Get app info for the "files" app -curl http://admin:secret@example.com/ocs/v1.php/cloud/apps/files ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - - - - appinfo/remote.php - appinfo/remote.php - appinfo/filesync.php - - - files - Files - File Management - AGPL - Robin Appelman - 4.9 - true - - - - filesystem - - - ----- - -=== Enable App - -Enable an app. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|===================================================== -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/apps/\{appid\}` | `POST` | `text/plain` -|===================================================== - -[cols=",,",options="header",] -|========================================== -| Argument | Type | Description -| appid | string | The id of the app to enable -|========================================== - -==== Status Codes - -* 100 - successful - -==== Enable Example - -[source,console] ----- -# Enable the "files_texteditor" app -curl -X POST http://admin:secret@example.com/ocs/v1.php/cloud/apps/files_texteditor ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - ----- - -=== Disable App - -Disables the specified app. - -IMPORTANT: The Basic Authorization HTTP header must be used to authenticate this request, using the credentials of a user who has sufficient access rights to make the request. - -[cols=",,",options="header",] -|======================================================= -| Request Path | Method | Content Type -| `ocs/v1.php/cloud/apps/\{appid\}` | `DELETE` | `text/plain` -|======================================================= - -[cols=",,",options="header",] -|=========================================== -| Argument | Type | Description -| appid | string | The id of the app to disable -|=========================================== - -==== Status Codes - -* 100 - successful - -==== Disable Example - -[source,console] ----- -Disable the "files_texteditor" app -curl -X DELETE http://admin:secret@example.com/ocs/v1.php/cloud/apps/files_texteditor ----- - -==== XML Output - -[source,xml] ----- - - - - 100 - ok - - ----- diff --git a/content/server/10.15/modules/developer_manual/pages/core/apis/roles-api.adoc b/content/server/10.15/modules/developer_manual/pages/core/apis/roles-api.adoc deleted file mode 100644 index a48a1ac..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/apis/roles-api.adoc +++ /dev/null @@ -1,166 +0,0 @@ -= Roles API -:toc: right -:toclevels: 1 -:request-base-path: ocs/v1.php/cloud/roles -:accept-language-header-url: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Accept-Language - -== Introduction - -The roles API allows clients to ask the server for supported roles. -Three things are worth noting about this API: - -. Only roles for public links are implemented. -. Apps can listen to the event dispatcher and add their own roles. -. Apps cannot change existing roles. - -== Get Roles - -[cols=",,",options="header",] -|=== -| Request Path -| Method -| Content Type - -| `ocs/v1.php/cloud/roles` -| `GET` -| `text/xml` or `text/json` -|=== - -=== Request Parameters - -[cols="15%,15%,70%",options="header",width=100%] -|=== -|Attribute -|Type -|Description - -|`format` -|string -|The format of the response content. -Accepted values are `xml` and `json`. -|=== - -=== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -#!/usr/bin/env bash - -API_PATH="ocs/v1.php/cloud/roles?format=json" -SERVER_URI="{oc-examples-server-url}" - -curl '$SERVER_URI/$API_PATH/' \ - --user "{oc-examples-username}:{oc-examples-password}" | jq ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -==== Curl - -[source,console,subs="attributes+"] ----- -#!/usr/bin/env bash - -API_PATH="ocs/v1.php/cloud/roles?format=json" -SERVER_URI="{oc-examples-server-url}" - -curl '$SERVER_URI/$API_PATH/' \ - --user "{oc-examples-username}:{oc-examples-password}" | jq ----- -endif::[] - -=== Returns - -On success, the request returns either an XML (the default) or a JSON response body, along with an `HTTP 200 OK` status code. -The response body lists all the available roles, along with information about each one. - -=== Example Responses - -ifndef::format[] -[tabs] -==== -JSON:: -+ --- -[source,json,subs="attributes+"] ----- -include::example$core/apis/ocs/roles/responses/success.json[] ----- --- -XML:: -+ --- -[source,xml,subs="attributes+"] ----- -include::example$core/apis/ocs/roles/responses/success.xml[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -=== JSON - -[source,json,subs="attributes+"] ----- -include::example$core/apis/ocs/roles/responses/success.json[] ----- - -=== XML - -[source,xml,subs="attributes+"] ----- -include::example$core/apis/ocs/roles/responses/success.xml[] ----- -endif::[] - -=== Setting The Language of the Response Body - -The language of the response’s content can be set with {accept-language-header-url}[the Accept-Language header]. -By default, the response will be in English. -You can see an example of requesting the response in a specific language in the code example below. - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -#!/usr/bin/env bash - -API_PATH="ocs/v1.php/cloud/roles?format=json" -SERVER_URI="{oc-examples-server-url}" - -curl '$SERVER_URI/$API_PATH/' \ - --user "{oc-examples-username}:{oc-examples-password}" \ - -H 'Accept-Language: de-DE' | jq ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -==== Curl - -[source,console,subs="attributes+"] ----- -#!/usr/bin/env bash - -API_PATH="ocs/v1.php/cloud/roles?format=json" -SERVER_URI="{oc-examples-server-url}" - -curl '$SERVER_URI/$API_PATH/' \ - --user "{oc-examples-username}:{oc-examples-password}" \ - -H 'Accept-Language: de-DE' | jq ----- -endif::[] diff --git a/content/server/10.15/modules/developer_manual/pages/core/code-standard.adoc b/content/server/10.15/modules/developer_manual/pages/core/code-standard.adoc deleted file mode 100644 index 4de0d42..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/code-standard.adoc +++ /dev/null @@ -1,66 +0,0 @@ -= Code Standards Compliance -:toc: right -:owncloud-coding-standard-url: https://github.com/owncloud/coding-standard -:phpcsfixer-url: https://github.com/FriendsOfPhp/PHP-CS-Fixer -:phpcodesniffer-url: https://github.com/squizlabs/PHP_CodeSniffer - -== Fixing Code Standard Violations - -To ensure that your code follows the ownCloud standard, run `make test-php-style` before a PR is initially submitted and each time any additional changes to it are made. - -The command runs {phpcsfixer-url}[php-cs-fixer] over the codebase, using {owncloud-coding-standard-url}[ownCloud's coding-standard], loaded from `.php_cs.dist` in the root directory of your ownCloud installation. -The acceptance test code is also checked by {phpcodesniffer-url}[php_codesniffer], using the rules in `phpcs.xml` in the root directory of your ownCloud installation. - -If any standards violations are detected by {phpcsfixer-url}[php-cs-fixer] then run `make test-php-style-fix` to automatically correct them. - -{phpcodesniffer-url}[php_codesniffer] cannot always fix code standards violations that it finds. You must manually fix those. - -== Viewing Code Standard Violations - -TIP: For further details about the coding standard please refer to the {owncloud-coding-standard-url}[owncloud/coding-standard] repository. - -To check for style errors, run `make test-php-style`. -After running it, you will see console output from {phpcsfixer-url}[php-cs-fixer], similar to the example below: - -[source,console] ----- -php -d zend.enable_gc=0 vendor-bin/owncloud-codestyle/vendor/bin/php-cs-fixer fix -v --diff --diff-format udiff --allow-risky yes --dry-run -Loaded config ownCloud coding standard from "/ownCloud/core/.php_cs.dist". -Using cache file ".php_cs.cache". -.....................................................................................................................................................F........................................................................................ -Legend: ?-unknown, I-invalid file syntax, file ignored, S-Skipped, .-no changes, F-fixed, E-error - 1) apps/files_sharing/tests/Iterator/WritableAppsPathsFilterIteratorTest.php (class_definition, braces) - ---------- begin diff ---------- ---- Original -+++ New -@@ -23,5 +23,4 @@ - use Test\TestCase; - - class WritableAppsPathsFilterIteratorTest extends TestCase { -- - } - - ----------- end diff ----------- ----- - -If {phpcodesniffer-url}[php_codesniffer] detects violations then you will see console output similar to the example below: - -[source,console] ----- -vendor-bin/php_codesniffer/vendor/bin/phpcs --cache --runtime-set ignore_warnings_on_exit --standard=phpcs.xml tests/acceptance tests/TestHelpers -...........E................................................ 60 / 121 (50%) -............................................................ 120 / 121 (99%) -. 121 / 121 (100%) - - - -FILE: /home/phil/git/owncloud/core/tests/acceptance/features/bootstrap/BasicStructure.php -------------------------------------------------------------------------------------------------------------- -FOUND 1 ERROR AFFECTING 1 LINE -------------------------------------------------------------------------------------------------------------- - 202 | ERROR | Doc comment for parameter "$ocPath" missing - | | (PEAR.Commenting.FunctionComment.MissingParamTag) -------------------------------------------------------------------------------------------------------------- - -Time: 1.05 secs; Memory: 113.29MB ----- diff --git a/content/server/10.15/modules/developer_manual/pages/core/configfile.adoc b/content/server/10.15/modules/developer_manual/pages/core/configfile.adoc deleted file mode 100644 index f0c0774..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/configfile.adoc +++ /dev/null @@ -1,137 +0,0 @@ -= Application Configuration - -[source,php] ----- - false, - - /* Type of database, can be sqlite, mysql or pgsql */ - 'dbtype' => 'sqlite', - - /* Name of the ownCloud database */ - 'dbname' => 'owncloud', - - /* User to access the ownCloud database */ - 'dbuser' => '', - - /* Password to access the ownCloud database */ - 'dbpassword' => '', - - /* Host running the ownCloud database */ - 'dbhost' => '', - - /* Prefix for the ownCloud tables in the database */ - 'dbtableprefix' => '', - - /** - Define the salt used to hash the user passwords. - All your user passwords are lost if you lose this string. - */ - 'passwordsalt' => '', - - /* Force use of HTTPS connection (true = use HTTPS) */ - 'forcessl' => false, - - /* Theme to use for ownCloud */ - 'theme' => '', - - /* Path to the 3rdparty directory */ - '3rdpartyroot' => '', - - /* URL to the 3rdparty directory, as seen by the browser */ - '3rdpartyurl' => '', - - /* Default app to load on login */ - 'defaultapp' => 'files', - - /* Enable the help menu item in the settings */ - 'knowledgebaseenabled' => true, - - /* Enable installing apps from the appstore */ - 'appstoreenabled' => true, - - /* URL of the appstore to use, server should understand OCS */ - 'appstoreurl' => 'https://api.owncloud.com/v1', - - /* Mode to use for sending mail, can be sendmail, smtp, qmail or php, see PHPMailer docs */ - 'mail_smtpmode' => 'sendmail', - - /* Host to use for sending mail, depends on mail_smtpmode if this is used */ - 'mail_smtphost' => '127.0.0.1', - - /* authentication needed to send mail, depends on mail_smtpmode if this is used - * (false = disable authentication) - */ - 'mail_smtpauth' => false, - - /* Username to use for sendmail mail, depends on mail_smtpauth if this is used */ - 'mail_smtpname' => '', - - /* Password to use for sendmail mail, depends on mail_smtpauth if this is used */ - 'mail_smtppassword' => '', - - /* Check 3rdparty apps for malicious code fragments */ - 'appcodechecker' => '', - - /* Check if ownCloud is up to date */ - 'updatechecker' => true, - - /* Place to log to, can be owncloud and syslog (owncloud is log menu item in admin menu) */ - 'log_type' => 'owncloud', - - /* File for the owncloud logger to log to, (default is ownloud.log in the data dir */ - 'logfile' => '', - - /* Loglevel to start logging at. 0=DEBUG, 1=INFO, 2=WARN, 3=ERROR (default is WARN) */ - 'loglevel' => '', - - /* Lifetime of the remember login cookie, default is 15 days */ - 'remember_login_cookie_lifetime' => 60*60*24*15, - - /* The directory where the user data is stored, default to data in the owncloud - * directory. The sqlite database is also stored here, when sqlite is used. - */ - 'datadirectory' => '/var/www/owncloud/data', - - /* Set an array of path for your apps directories - key 'path' is for the filesystem path and the key 'url' is for the http path to your - applications paths. 'writable' indicates if the user can install apps in this folder. - You must have at least 1 app folder writable or you must set the parameter : appstoreenabled to false. - */ - 'apps_paths' => [ - [ - 'path' => OC::$SERVERROOT.'/apps', - 'url' => '/apps', - 'writable' => true, - ], - ] -] ----- - -== Using alternative app directories - -ownCloud can be set to use a custom app directory in `/config/config.php`. -Customise the following code and add it to your config file: - -[source,php] ----- -'apps_paths' => [ - [ - 'path' => OC::$SERVERROOT.'/apps', - 'url' => '/apps', - 'writable' => false, - ], - [ - 'path' => OC::$SERVERROOT.'/apps-external', - 'url' => '/apps-external', - 'writable' => true, - ], -], ----- - -ownCloud will use for new or app updates the first app directory which it finds in the array with `writable` set to `true`. - -NOTE: Make sure that all app directories that are defined in your `config.php` in the `apps_paths` section do exist. diff --git a/content/server/10.15/modules/developer_manual/pages/core/index.adoc b/content/server/10.15/modules/developer_manual/pages/core/index.adoc deleted file mode 100644 index c79cb81..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/index.adoc +++ /dev/null @@ -1,5 +0,0 @@ -= Core Development - -In this section you will find all the details you need to develop ownCloud’s core. - -You should develop starting with the latest code in the core master branch. The core development documentation is written assuming that you are doing that. \ No newline at end of file diff --git a/content/server/10.15/modules/developer_manual/pages/core/introduction.adoc b/content/server/10.15/modules/developer_manual/pages/core/introduction.adoc deleted file mode 100644 index 5ce7abc..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/introduction.adoc +++ /dev/null @@ -1,4 +0,0 @@ -= Introduction - -Please make sure you have set up a xref:general/devenv.adoc[Development Environment]. Use the latest code in the core master branch when starting development. - diff --git a/content/server/10.15/modules/developer_manual/pages/core/theming.adoc b/content/server/10.15/modules/developer_manual/pages/core/theming.adoc deleted file mode 100644 index 8702881..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/theming.adoc +++ /dev/null @@ -1,543 +0,0 @@ -= Theming ownCloud -:toc: right -:toclevels: 1 -:page-aliases: go/developer-theming.adoc -:css-gradient-url: https://cssgradient.io/ - -== Introduction - -Themes can be used to customize the look and feel of any aspect of an ownCloud installation. They can override the default _JavaScript_, _CSS_, _image_, and _template_ files, as well as the _user interface translations_ with custom versions. They can also affect both the web front-end and the ownCloud Desktop client. However, this documentation only covers customizing the web front-end, _so far_. - -NOTE: Before ownCloud Classic 10, theming was done via the `config.php` entry `'theme' => ''`. This is deprecated in ownCloud Classic 10. Users who have this entry in their `config.php` should remove it and use a theme app to customize their ownCloud instance instead. - -== Quick Start - -For the impatient, who want to play with themes right away, the following commands get a theme installed quickly. Adjust the names and paths according to your setup. For docker installations use the directory `/var/www/owncloud/custom`. - -. Install unzip if not available -+ -[source,console] ----- -sudo apt install unzip ----- - -. If it exists, go into your `apps-external` folder, else use `apps` -+ -[source,console] ----- -cd /var/www/owncloud/apps-external ----- - -. Download the theme - -+ -[source,console] ----- -wget https://github.com/owncloud/theme-example/archive/master.zip ----- - -. Extract the theme -+ -[source,console] ----- -unzip master.zip ----- - -. Remove the zip file -+ -[source,console] ----- -rm master.zip ----- - -. Rename the theme -+ -[source,console] ----- -mv theme-example-master mynewtheme ----- - -. Change the app ID in info.xml -+ -[source,console] ----- -sed -i "s#theme-example<#mynewtheme<#" "mynewtheme/appinfo/info.xml" ----- - -. Adjust the permissions -+ -[source,console] ----- -sudo chown -R www-data: mynewtheme ----- - -. Activate your theme -+ -[source,console,subs="attributes+"] ----- -{occ-command-example-prefix} app:enable mynewtheme ----- - -. Exclude your new theme from integrity checking. Add the following setting to `config/config.php`: -+ -[source,php] ----- -'integrity.ignore.missing.app.signature' => [ - 'mynewtheme', - ], ----- - -The last step is necessary since you're not likely to provide a signature.json file. The theme is treated like an app. The ID is usually the name of the subfolder for the theme, in this case mynewtheme. - -Throughout this section of the documentation, for the sake of simplicity, it will be assumed that your ownCloud installation directory is `/owncloud`. If you’re following this guide to create or customize a theme, make sure you change any references to match the location of your ownCloud installation. - -To save time and effort, you can use the shell script below to create the basis of a new theme from https://github.com/owncloud/theme-example[ownCloud's example theme]. - -Using this script (and the following one, `read-config.php`), you will have a new theme, ready to go, in less than five seconds. You can execute this script with two variables; the first one is the *theme name* and the second one is your *ownCloud directory*. - -For example: - -[source,console] ----- -theme-bootstrap.sh mynewtheme /var/www/owncloud ----- - -IMPORTANT: Don't forget to create `read-config.php` from the included code below, before you attempt to run `theme-bootstrap.sh`, otherwise `theme-bootstrap.sh` will fail. - -*theme-bootstrap.sh* - -[source,bash] ----- -include::example$scripts/theme-bootstrap.sh[] ----- - -*read-config.php* - -[source,php] ----- -include::example$scripts/read-config.php[] ----- - -== How to Create a New Theme - -Now in more detail for those who want to understand the procedures presented above and work on their new theme. Creating a theme requires two basic steps: - -1. Copy and extend https://github.com/owncloud/theme-example[ownCloud's example theme] or create one from scratch. -2. Enable the theme which can be found in menu:Settings[Admin > Apps > Show disabled Apps] - -All themes, whether copied or new, must meet two key criteria: - -1. They must be stored in an app directory of your ownCloud installation, preferably in `apps-external` or a -xref:admin_manual:installation/apps_management_installation.adoc#using-custom-app-directories[custom app directory] -+ -NOTE: To ensure that custom themes aren’t lost during upgrades, we strongly encourage you to store them in a custom app directory. - -2. They require a configuration file called `appinfo/info.xml` to be present. - -=== appinfo/info.xml - -Here’s an example of the bare minimum which the file needs to contain: - -[source,xml] ----- - - - theme-example - Example Theme - - - - - - - ----- - -And here’s a longer, more complete example: - -[source,xml] ----- - - - theme-example - Example Theme - This App provides the ownCloud theme. - AGPL - John Doe - 0.0.1 - - - - - - - ----- - -The value of the `id` element needs to be the name of your theme’s folder. We recommend that it always be prefixed with `theme-`. The main reason for doing so, is that it is alphabetically sorted in a terminal -when handling app folders. - -The `type` element needs to be the same as is listed above, so that ownCloud knows to handle the app as a theme. The dependencies element needs to be present to set the minimum and maximum versions of ownCloud which are supported. If it’s not present, a warning will be displayed in ownCloud Classic 10 and an error will be thrown in the upcoming ownCloud Classic 11. - -While the remaining elements are optional, they help when working with the theme in the ownCloud Admin dashboard. Consider filling out as many as possible, as completely as possible. - -=== Theme Signing - -If you are going to publish the theme as an app in the {oc-marketplace-url}[marketplace], you need to sign it. However, if you are only creating a private theme for your own ownCloud installation, then you do not need to. - -That said, to avoid a signature warning in the ownCloud UI, you need to add it to the `integrity.ignore.missing.app.signature` list in `config/config.php`. The following example allows the app whose application ID is `app-id` to have no signature. - -[source,console] ----- -'integrity.ignore.missing.app.signature' => [ - 'app-id', - ], ----- - -== How to Override Images - -Any image, such as the default logo, can be overridden by including one with the same path structure in your theme. For example, let’s say that you want to replace the logo on the login page above the credentials box which, by default, has the path: `owncloud/core/img/logo-icon.svg`. To override it, assuming that your custom theme was called `theme-example` (_which will be assumed for the remainder of the theming documentation_), add a new file with the following path: `owncloud/apps/theme-example/core/img/logo-icon.svg`. After the theme is activated, this image will override the default one. - -=== Default Image Paths - -To make building a new theme easier, find below a list of a range of the image paths used in the default theme. - -[cols="50%,20%,70%",options="header",] -|=== -| Description | Section | Location -| The logo at the login page above the credentials box | General | `owncloud/core/img/logo-icon.svg` -| The logo in the left upper corner after login | | `owncloud/core/img/logo-icon.svg` -| All files folder image | | `owncloud/core/img/folder.svg` -| Favorites star image | | `owncloud/core/img/star.svg` -| Shared with you/others image | | `owncloud/core/img/shared.svg` -| Shared by link image | | `owncloud/core/img/public.svg` -| Tags image | | `owncloud/core/img/tag.svg` -| Deleted files image | | `owncloud/core/img/delete.svg` -| Settings image | | `owncloud/core/img/actions/settings.svg` -| Search image | | `owncloud/core/img/actions/search-white.svg` -| Breadcrumbs home image | | `owncloud/core/img/places/home.svg` -| Breadcrumbs separator | | `owncloud/core/img/breadcrumb.svg` -| Dropdown arrow | Admin Menu | `owncloud/core/img/actions/caret.svg` -| Personal image | | `owncloud/settings/img/personal.svg` -| Users image | | `owncloud/settings/img/users.svg` -| Help image | | `owncloud/settings/img/help.svg` -| Admin image | | `owncloud/settings/img/admin.svg` -| Logout image | | `owncloud/core/img/actions/logout.svg` -| Apps menu - Files image | | `owncloud/apps/files/img/app.svg` -| Apps menu - Plus image | | `owncloud/settings/img/apps.svg` -| Upload image | Personal | `owncloud/core/img/actions/upload.svg` -| Folder image | | `owncloud/core/img/filetypes/folder.svg` -| Trash can image | | `owncloud/core/img/actions/delete.svg` -|=== - -NOTE: When overriding the favicon, make sure your custom theme includes an override for both `owncloud/apps/core/img/favicon.svg` and `owncloud/apps/core/img/favicon.png`, to cover any future updates to favicon handling. - -NOTE: When using custom filetype icons in a custom theme, it is necessary to run `occ maintenance:mimetype:update-js` to activate them. For more information, refer to -xref:admin_manual:configuration/mimetypes/index.adoc[mimetypes management]. - -=== How to Change the Background Image - -image::core/theming/2_ow_login.png[Change the background login image in ownCloud] - -NOTE: This guide assumes that you are in the folder of your custom theme, for example: `/var/www/owncloud/apps/my_custom_theme/`. - -==== How to Change the Login Background Image - -. Put the new background image in `core/img/background.jpg`. -. Change the owner and group permissions of the file to your web server user and group. -. Update `background-image` in `core/css/styles.css`. - -[source,css] ----- -#body-login { - background-image: url("../img/background.jpg"); /* path to image */ - background-position: 50% 50%; /* ensure optimal scalability */ - background-repeat: no-repeat; /* prevent tiled background */ - background-size: cover; /* ensure screen coverage */ - text-align: center; /* Center Entitlement text, copyright */ - background-color: #000000 !important; /* Fallback for old browsers */ -} ----- - -If your image size is 1920px x 1680px, you don't need the lines below the path. However, they ensure optimal positioning and scaling. - -image::core/theming/3_cu_login.png[Set a custom login background image in ownCloud] - -TIP: You can also change the background color, logo, and slogan. - -==== How to Change the Login Background Image to a Color - -In `core/css/styles.css`, search for the following CSS code: - -[source,css] ----- -#body-login { - background: #745bca; /* Old browsers */ - background: -moz-linear-gradient(top, #947bea 0%, #745bca 100%); -} ----- - -Replace it with the following: - -[source,css] ----- -#body-login { - background: rgb(31,9,121); - background: linear-gradient(90deg, rgba(31,9,121,1) 38%, rgba(2,0,36,1) 58%); -} ----- - -If you only want one color, replace the existing CSS code with this: - -[source,css] ----- -#body-login { - background: rgb(31,9,121); -} ----- - -TIP: If you are not sure what color to pick, {css-gradient-url}[CSS Gradient] may be able to help. - -To change the icon, replace the files in `core/img` (`logo.png`, and `logo.svg`) with your icons. The reason for the PNG files is to have a fallback option for older browsers. - -If you keep the names, you don't need to change the path in `core/css/styles.css`. If you change the names, adjust the `styles.css` file accordingly like in the following example: - -[source,css] ----- -#header .logo { - background-image: url('../img/logo.svg'); - width: 250px; - height: 121px; -} ----- - -=== How to Change the Header - -image::core/theming/4_oc_header.png[The default ownCloud header] - -The image above is the default ownCloud header. - -image::core/theming/5_cu_header.png[Set a custom ownCloud header image] - -You can change it to a custom color with a custom logo. -Search for `#body-public #header` in `core/css/styles.css`. - -[source,css] ----- -#body-public #header { - background-color: #745bca; -} ----- - -You can also write your own, like the one from the login page for example: - -[source,css] ----- -#body-public #header { - background: rgb(31,9,121); - background: linear-gradient(90deg, rgba(31,9,121,1) 38%, rgba(2,0,36,1) 58%); -} ----- - -Change the logo by replacing `logo-icon.png` and `logo-icon.svg` with your logo, in `core/img`. If you change the names of the logos, adjust the path accordingly in `core/css/styles.css`. - -[source,css] ----- -#header .logo-icon { - background-image: url('../img/logo-icon.svg'); - height: 34px; -} ----- - -=== How to Override Settings Page Icons - -ownCloud provides the ability to override Personal and Admin settings page icons. To do so requires two things: - -. A custom (SVG) icon; and -. Refactoring `SettingsManager.php` - -For example, if you want to override the Admin Encryption settings icon, first add a custom icon to an app's `img` directory, e.g. `
      /apps/encryption/img/gnu.svg`. - -Then, update the `getBuiltInSections` function of `lib/private/Settings/SettingsManager.php`. You need to change the final argument of the relevant call to `new Section` for the settings section that you want to change, like in the example below. - -[source,php] ----- -new Section('encryption', $this->l->t('Encryption'), 85, 'gnu'), ----- - -In the example above, I've changed the encryption section's icon, by changing the final argument to be the custom icon's name — _minus the file extension_. - -TIP: Icons *must* be in SVG format. No other file formats are supported. - -== How to Override the Default Colors - -To override the default style sheet, create a new CSS style sheet called `styles.css` in the theme’s `css` directory. - -== How to Override Translations - -You can override the translation of any string in your theme. To do so: - -1. Create the `l10n` folder inside your theme for the app that you want to override. -2. In the `l10n` folder, create the translation file for the language that you want to customize. - -For example, if you want to overwrite the German translation of _`Download`_ in the files app, create the file `owncloud/apps/theme-example/apps/files/l10n/de_DE.js`. Note that the structure is the same as for images. You just mimic the original file location inside your theme. Put the following code in the file: - -[source,js] ----- -OC.L10N.register( - "files", - { - "Download" : "Herunterladen" - }, - "nplurals=2; plural=(n != 1);" -); ----- - -Next, create a second translation file, `owncloud/apps/theme-example/apps/files/l10n/de_DE.json`, which looks like this: - -[source,json] ----- -{ - "translations": { - "Download" : "Herunterladen" - }, - "pluralForm" :"nplurals=2; plural=(n != 1);" -} ----- - -Both files (`.js` and `.json`) are needed. The first is needed to enable translations in the JavaScript code and the second one is read by the PHP code and provides the data for translated terms. - -== How to Override Names, Slogans, and URLs - -In addition to translations, the ownCloud theme allows you to change a lot of the names shown on the web interface. This is done in `defaults.php`, which needs to be located within the theme’s root folder. You can find a sample version in `owncloud/app/theme-example/defaults.php`. In the file, you need to define a class named `OC_Theme` and implement the methods that you want to overwrite. - -[source,php] ----- -class OC_Theme { - public function getAndroidClientUrl() { - return 'https://play.google.com/store/apps/details?id=com.owncloud.android'; - } - - public function getName() { - return 'ownCloud'; - } -} ----- - -Each method must return a string. The following methods are available: - -[cols="30%,60%",options="header",] -|=== -| Method | Description -| `getAndroidClientUrl` | Returns the URL to Google Play for the Android Client. -| `getBaseUrl` | Returns the base URL. -| `getDocBaseUrl` | Returns the documentation URL. -| `getEntity` | Returns the entity (e.g., company name) used in footers and copyright notices. -| `getName` | Returns the short name of the software. -| `getHTMLName` | Returns the short name of the software containing HTML strings. -| `getiOSClientUrl` | Returns the URL to the ownCloud Marketplace for the iOS Client. -| `getiTunesAppId` | Returns the AppId for the ownCloud Marketplace for the iOS Client. -| `getLogoClaim` | Returns the logo claim. -| `getLongFooter` | Returns the long version of the footer. -| `getMailHeaderColor` | Returns the mail header color. -| `getSyncClientUrl` | Returns the URL where the sync clients are listed. -| `getTitle` | Returns the title. -| `getShortFooter` | Returns short version of the footer. -| `getSlogan` | Returns the slogan. -|=== - -Only these methods are available in the templates, because we internally wrap around hardcoded method names. - -One exception is the method `buildDocLinkToKey` which gets passed in a key as its first parameter. For core, we do something similar to build the documentation - -[source,php] ----- -public function buildDocLinkToKey($key) { - return $this->getDocBaseUrl() . '/server/latest/go.php?to=' . $key; -} ----- - -== How to Test a Theme - -There are different options for testing themes: - -* If you’re using a tool like the Inspector tools of Mozilla, you can test the CSS styles immediately inside the css-attributes, while you’re looking at the page. -* If you have a development server, you can test out the effects in a live environment. - -== Settings Page Registration - -=== How Can an App Register a Section in the Admin or Personal Section? - -As of ownCloud Classic 10.0, apps must register Admin and Personal section settings in `info.xml`. As a result, all calls to -`OC_App::registerPersonal` and `OC_App::registerAdmin` should now be removed. The settings panels of any apps that are still using these calls will now be rendered in the `Additional` section of the dashboard. - -For each panel an app wishes to register, two things are required: - -1. An update to `info.xml` -2. A controller class - -==== Updating info.xml - -First, an entry must be added into the `` element in `info.xml`, specifying the class name responsible for rendering the panel. These will be loaded automatically when an app is enabled. For example, to register an Admin and a Personal section requires the following configuration: - -[source,xml] ----- - - OCA\MyApp\PersonalPanel::class - OCA\MyApp\AdminPanel::class - ----- - -==== The Controller Class - -Next, a controller class which implements the `OCP\Settings\ISettings` interface must be created to represent the panel. Doing so enforces that the necessary settings panel information is returned. The interface specifies three methods: - - -* getSectionID -* getPanel -* getPriority - -*getSectionID:* This method returns the identifier of the section that this panel should be shown under. ownCloud Classic comes with a predefined list of sections which group related settings together; the intention of which is to improve the user experience. This can be found here in -https://github.com/owncloud/core/blob/master/lib/private/Settings/SettingsManager.php#L195[this example]: - -*getPanel:* This method returns the `OCP\Template` or `OCP\TemplateReponse` which is used to render the panel. The method may also return `null` if the panel should not be shown to the user. - -*getPriority:* An integer between 0 and 100 representing the importance of the panel (higher is more important). Most apps should return a value: - -* between 20 and 50 for general information. -* greater than 50 for security information and notices. -* lower than 20 for tips and debug output. - -Here’s an example implementation of a controller class for creating a personal panel in the security section. - -[source,php] ----- -assign('var', 'value'); - } -} ----- - -=== Create Custom Sections - -At the moment, there is no provision for apps creating their own settings sections. This is to encourage sensible grouping of the settings panels which in turn should improve the overall user experience. However, if you think a new section should be added to core, please create a PR with the appropriate changes to `OC\Settings\SettingsManager`. diff --git a/content/server/10.15/modules/developer_manual/pages/core/translation.adoc b/content/server/10.15/modules/developer_manual/pages/core/translation.adoc deleted file mode 100644 index a5712cc..0000000 --- a/content/server/10.15/modules/developer_manual/pages/core/translation.adoc +++ /dev/null @@ -1,118 +0,0 @@ -= Translation -:toc: right -:toclevels: 1 - -== Make text translatable - -In HTML or PHP wrap it like this -`t('This is some text'));?>` or this -`t('This is some text'));?>` For the right -date format use `l('date', time()));?>`. Change the way -dates are shown by editing /core/l10n/l10n-[lang].php To translate text -in javascript use: `t('appname','text to translate');` - -`print_unescaped()` should be preferred only if you would like to -display HTML code. Otherwise, using `p()` is strongly preferred to -escape HTML characters against XSS attacks. - -== You shall never split sentences! - -=== Reason: - - -Translators lose the context and they have no chance to possibly -re-arrange words. - -=== Example: - - -[source,php] ----- -t('Select file from')) . ' '; ?>t('local filesystem'));?>t(' or ')); ?>t('cloud'));?> ----- - -=== Translators will translate: - - -* Select file from -* local filesystem -* ’ or " -* cloud - -Translating these individual strings results in `local filesystem` and -`cloud` losing case. The two white spaces surrounding `or` will get lost -while translating as well. For languages that have a different -grammatical order it prevents the translators from reordering the -sentence components. - -=== Html in translation strings - -Html tags can be kept out of translation strings like in the example -below. Then the detail of the tags is uncoupled from the translation. - -=== What about variables in the strings? - -If you need to add variables to the translation strings do it like this: - -[source,php] ----- -$l->t('%1$s is available. Get %2$smore information%3$s', [$data['versionstring'], '', ''); ----- - -When there are multiple substitutions, number them. Then the translators -have the chance to re-order them if they need to translate the whole -sentence in a different word order. - -== Automated synchronization of translations - -Multiple nightly jobs have been setup in order to synchronize -translations - it’s a multi-step process: `perl l10n.pl read` will -rescan all php and javascript files and generate the templates. The -templates are pushed to -https://www.transifex.com/owncloud-org/owncloud/[Transifex] (tx push -s). -All translations are pulled from -https://www.transifex.com/owncloud-org/owncloud/[Transifex] (tx pull -a). -`perl l10n.pl write` will write the php files containing the -translations. Finally the changes are pushed to git. - -=== Please follow the steps below to add translation support to your app: - - -Create a folder `l10n`. Create the file `ignorelist` which can contain -files which shall not be scanned during step 4. Edit `l10n/.tx/config` -and copy/past a config section and adopt it by changing the app/folder -name. Run `perl l10n.pl read` with l10n Add the newly created -translation template (l10n/Templates/.pot) to git and commit -the changes above. After the next nightly sync job a new resource will -appear on Transifex and from now on every night the latest translations -will arrive. - -=== Translation sync jobs: - - -https://drone.owncloud.com/owncloud/translation-sync - -*Caution: information below is in general not needed!* - -== Manual quick translation update: - -[source,bash] ----- -cd l10n/ && perl l10n.pl read && tx push -s && tx pull -a && perl l10n.pl write && cd .. ----- - -The translation script requires Locale::PO, installable via -`apt-get install liblocale-po-perl` - -== Configure transifex - -[source,bash] ----- -tx init - -for resource in calendar contacts core files media settings -do -tx set --auto-local -r owncloud.$resource "/$resource.po" --source-language=en \ - --source-file "templates/$resource.pot" --execute -done ----- diff --git a/content/server/10.15/modules/developer_manual/pages/found_a_mistake.adoc b/content/server/10.15/modules/developer_manual/pages/found_a_mistake.adoc deleted file mode 100644 index 9d189de..0000000 --- a/content/server/10.15/modules/developer_manual/pages/found_a_mistake.adoc +++ /dev/null @@ -1,4 +0,0 @@ -= Have You Found a Mistake In The Documentation? -:new-issue-url: https://github.com/owncloud/docs/issues/new - -If you have found a mistake in the documentation, no matter how large or small, please let us know by {new-issue-url}[creating a new issue in the docs repository]. diff --git a/content/server/10.15/modules/developer_manual/pages/general/backporting.adoc b/content/server/10.15/modules/developer_manual/pages/general/backporting.adoc deleted file mode 100644 index eef9515..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/backporting.adoc +++ /dev/null @@ -1,123 +0,0 @@ -= Backporting -:toc: right -:homebrew-url: https://brew.sh -:json-processor-url: https://stedolan.github.io/jq/download/ -:rate-limit-url: https://developer.github.com/v3/#rate-limiting -:backport-request-url: https://github.com/owncloud/core/labels/Backport-Request -:git-alias-url: https://git-scm.com/book/en/v2/Git-Basics-Git-Aliases - -== Introduction - -We backport important fixes and improvements from the current master release to get them to our users faster. - -== Process - -We mostly consider bug fixes for backporting. Occasionally, important changes to the API can be backported to make it easier for developers to keep their apps working between major releases. If you think a pull request (PR) is relevant for the stable release, go through these steps: - -. Make sure the PR is merged to master -. Ask the feature maintainer if the code should be backported and add the label {backport-request-url}[backport-request] -to the PR -. If the maintainer agrees, create a new branch based on the respective stable branch, cherry-pick the needed commits to that branch and create a PR on GitHub. -. Specify the corresponding milestone for that series to this PR and reference the original PR in there. This enables the QA team to find the backported items for testing and having the original PR with detailed description linked. - -NOTE: Before each patch release there is a freeze to be able to test everything as a whole without pulling in new changes. While this freeze is active a backport isn’t allowed and has to wait for the next patch release. - -The QA team will try to reproduce all the issues with the X.Y.Z-next-maintenance milestone on the relevant release and verify it is fixed by the patch release (and doesn’t cause new problems). Once the patch release is out, the post-fix -next-maintenance is removed and a new -next-maintenance milestone is created for that series. - -== Backporting Steps - -Because pushing directly to particular ownCloud branches is forbidden (e.g., `origin/stable-xx`), you need to create your own remote branch, based off of the branch that you wish to backport to. However, doing so can involve a number of manual steps. To reduce the effort and time involved, use the script below instead. - -=== Backporting Notes - -NOTE: The script relies on a recent version of `grep`. macOS users may find on their system a version provided from Apple which is outdated and lacking needed options. Use {homebrew-url}[homebrew] to install a recent version of `grep`. - -NOTE: The script uses `curl` and the `jq` (lightweight and flexible command-line JSON processor) package. Please install them before first usage. Please see this {json-processor-url}[link] for installation details of `jq` covering various OS. - -NOTE: This script uses the github API. For unauthenticated requests, the rate limit allows for up to 60 requests per hour. Unauthenticated requests are associated with the originating IP address, and not the user making requests. Please see this {rate-limit-url}[link] for more information about github rate limiting. - -NOTE: The script requires that you have checked out the branch containing the merge SHA1 hash. The script will not proceed if either the merge SHA1 hash is not present or the branch containing the merge SHA1 hash is not checked out. - -NOTE: In case of conflicts, the script exits. The merge conflicts will need to be resolved before manually continuing the backport. When done, we suggest that you use the printed subject title from the script for the Pull Request. - -WARNING: While adding, renaming or changing files has no issues for backporting, the script will fail if files have been deleted. You need to manually finalize the backport using git commands. - -=== Backporting Script - -[source,console] ----- -include::example$scripts/backport.sh[] ----- - -TIP: It is highly recommended to use the merge SHA1 hash when backporting a Pull Request. The merge commit includes all PR sub commits to be backported. With that, no individual sub commit backporting is necessary. - -The following example assumes that: - -- You save the script in a file called `/backport.sh` and marked it executable -- You have checked out the branch containing the merge SHA1 hash (like `master`) -- Your Pull Request merge SHA1 hash = 1234567 and your target branch = 10.9 - -The command to backport this Pull Request would be called as follows: - -[source,console] ----- -/backport.sh 1234567 10.9 -4 commits beeing cherry picked: - -2e03d938 -fef19729 -61ac3f09 -0528601f -... -Switched to a new branch ‘10.9-1234567-34654‘ -... -[10.9] [PR 34654] Each generated birthday or death event gets a new UID -... -Cherry picking commit 1: 2e03d938 -Cherry picking commit 1: fef19729 -... -Pushing: ... -... ----- - -NOTE: Please keep in mind that this is an example and you have to adapt the commit hash and the target branch accordingly. - -The script lists quantity and commits to be backported and the current cherry-pick in process. This can be helpful in case there is a conflict and you manually continue after the conflict has been resolved. - -When the script completes, go to GitHub, where it will suggest that you make a PR from pushed branch. - -Even the script tries to automate the following steps by adding predefined messages, you may need to set the Pull Request subject and message text manually via copy/paste based on the script output. This is not a bug in the script but depends on GitHub. It is highly suggested to use these messages as it eases finding and referencing a lot. - -IMPORTANT: When not using the browser supported PR creation below, change the base branch to be committed against, from `master` to your target branch (in our example `10.9`) and continue. - -In case you have installed the `xdg-utils` package, you can add at the end of the script above following code which opens the PR to be finalized in your browser. macOS does not need this package. Use the command `open` instead of `xdg-open`: - -[source,console] ----- -# open the browser and prepare the pull request -echo "Creating pull request for branch ${targetBranch} in ${repository}" -xdg-open "https://github.com/${repository}/pull/new/${targetBranch}...${newBranch}" &>/dev/null ----- - -NOTE: This command opens the Pull Request and sets the target branch (in our example `10.9`) for the backport automatically. - -=== Backporting Alias - -You can also create a {git-alias-url}[git alias] for backporting, making it simpler to use. - -Open the `~/.gitconfig` file with the editor of your choice and add the following: - -[source,text] ----- -[alias] - backport = !bash -c '/backport.sh $1 $2' - ----- - -You can create a backport by invoking following command: - -[source,console] ----- -git backport 1234567 10.9 ----- - -NOTE: Please keep in mind that this is an example and you have to adapt the commit hash and the target branch accordingly. diff --git a/content/server/10.15/modules/developer_manual/pages/general/code-of-conduct.adoc b/content/server/10.15/modules/developer_manual/pages/general/code-of-conduct.adoc deleted file mode 100644 index 5a38497..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/code-of-conduct.adoc +++ /dev/null @@ -1,175 +0,0 @@ -= Community Code of Conduct -:toc: right - -== Preamble - -In the ownCloud community, participants from all over the world come -together to create Free Software for a free internet. This is made -possible by the support, hard work and enthusiasm of thousands of -people, including those who create and use ownCloud software. - -This document offers some guidance to ensure ownCloud participants can -cooperate effectively in a positive and inspiring atmosphere, and to -explain how together we can strengthen and support each other. - -This Code of Conduct is shared by all contributors and users who engage -with the ownCloud team and its community services. - -== Overview - -This Code of Conduct presents a summary of the shared values and -common sense thinking in our community. The basic social ingredients -that hold our project together include: - -* Be considerate -* Be respectful -* Be collaborative -* Be pragmatic -* Support others in the community -* Get support from others in the community - -Our community is made up of several groups of individuals and -organizations which can roughly be divided into two groups: - -* Contributors, or those who add value to the project through improving -ownCloud software and its services -* Users, or those who add value to the project through their support as -consumers of ownCloud software - -This Code of Conduct reflects the agreed standards of behavior for -members of the ownCloud community, in any forum, mailing list, wiki, web -site, IRC channel, public meeting or private correspondence within the -context of the ownCloud team and its services. - -The community acts according to the standards written down in this Code -of Conduct and will defend these standards for the benefit of the -community. Leaders of any group, such as moderators of mailing lists, -IRC channels, forums, etc., will exercise the right to suspend access to -any person who persistently breaks our shared Code of Conduct. - -== Be collaborative - -The Free Software Movement depends on collaboration: it helps limit -duplication of effort while improving the quality of the software -produced. In order to avoid misunderstanding, try to be clear and -concise when requesting help or giving it. Remember it is easy to -misunderstand emails (especially when they are not written in your -mother tongue). Ask for clarifications if unsure how something is meant; -remember the first rule – assume in the first instance that people mean -well. - -As a contributor, you should aim to collaborate with other community -members, as well as with other communities that are interested in or -depend on the work you do. Your work should be transparent and be fed -back into the community when available, not just when ownCloud releases. -If you wish to work on something new in existing projects, keep those -projects informed of your ideas and progress. - -It may not always be possible to reach consensus on the implementation -of an idea, so don’t feel obliged to achieve this before you begin. -However, always ensure that you keep the outside world informed of your -work, and publish it in a way that allows outsiders to test, discuss and -contribute to your efforts. - -Contributors on every project come and go. When you leave or disengage -from the project, in whole or in part, you should do so with pride about -what you have achieved and by acting responsibly towards others who come -after you to continue the project. - -As a user, your feedback is important, as is its form. Poorly thought -out comments can cause pain and the demotivation of other community -members, but considerate discussion of problems can bring positive -results. An encouraging word works wonders. - -== Be considerate - -Your actions and work will affect and be used by other people and you in -turn will depend on the work and actions of others. Any decision you -take will affect other community members, and we expect you to take -those consequences into account when making decisions. - -As a contributor, ensure that you give full credit for the work of -others and bear in mind how your changes affect others. It is also -expected that you try to follow the development schedule and guidelines. - -== Be pragmatic - -ownCloud is a pragmatic community. We value tangible results over having -the last word in a discussion. We defend our core values like freedom -and respectful collaboration, but we don’t let arguments about minor -issues get in the way of achieving more important results. - -We are open to suggestions and welcome solutions regardless of their -origin. When in doubt support a solution which helps getting things done -over one which has theoretical merits, but isn’t being worked on. Use -the tools and methods which help getting the job done. Let decisions be -taken by those who do the work. - -As a user, remember that contributors work hard on their part of -ownCloud and take great pride in it. If you are frustrated your problems -are more likely to be resolved if you can give accurate and -well-mannered information to all concerned. - -== Be respectful - -In order for the ownCloud community to stay healthy its members must -feel comfortable and accepted. Treating one another with respect is -absolutely necessary for this. In a disagreement, in the first instance -assume that people mean well. - -We do not tolerate personal attacks, racism, sexism or any other form of -discrimination. Disagreement is inevitable, from time to time, but -respect for the views of others will go a long way to winning respect -for your own view. Respecting other people, their work, their -contributions and assuming well-meaning motivation will make community -members feel comfortable and safe and will result in motivation and -productivity. - -We expect members of our community to be respectful when dealing with -other contributors, users and communities. Remember that ownCloud is an -international project and that you may be unaware of important aspects -of other cultures. - -== Get support from others in the community - -Disagreements, both political and technical, happen all the time. Our -community is no exception to the rule. The goal is not to avoid -disagreements or differing views but to resolve them constructively. You -should turn to the community to seek advice and to resolve disagreements -and where possible consult the team most directly involved. - -Think deeply before turning a disagreement into a public dispute. If -necessary request mediation, trying to resolve differences in a less -highly-emotional medium. If you do feel that you or your work is being -attacked, take your time to breathe through before writing heated -replies. Consider a 24 hour moratorium if emotional language is being -used – a cooling off period is sometimes all that is needed. If you -really want to go a different way, then we encourage you to publish your -ideas and your work, so that it can be tried and tested. - -This document is licensed under the Creative Commons Attribution – Share -Alike 3.0 License. - -The authors of this document would like to thank the ownCloud community -and those who have worked to create such a dynamic environment to share -in and who offered their thoughts and wisdom in the authoring of this -document. We would also like to thank other vibrant communities that -have helped shape this document with their own examples, especially KDE. - -== Support others in the community - -Our community is made strong by mutual respect, collaboration and -pragmatic, responsible behavior. Sometimes there are situations where -this has to be defended and other community members need help. - -If you witness others being attacked, think first about how you can -offer them personal support. If you feel that the situation is beyond -your ability to help individually, go privately to the victim and ask if -some form of official intervention is needed. Similarly you should -support anyone who appears to be in danger of burning out, either -through work-related stress or personal problems. - -When problems do arise, consider respectfully reminding those involved -of our shared Code of Conduct as a first action. Leaders are defined by -their actions, and can help set a good example by working to resolve -issues in the spirit of this Code of Conduct before they escalate. diff --git a/content/server/10.15/modules/developer_manual/pages/general/codingguidelines.adoc b/content/server/10.15/modules/developer_manual/pages/general/codingguidelines.adoc deleted file mode 100644 index c4ab3fe..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/codingguidelines.adoc +++ /dev/null @@ -1,601 +0,0 @@ -= Coding Style & General Guidelines -:toc: right - -== Coding - -* Maximum line-length of 80 characters -* Use tabs to indent -* A tab is 4 spaces wide -* Opening braces of blocks are on the same line as the definition -* Quotes: ’ for everything, " for HTML attributes (`

      `) -* End of Lines : Unix style (LF / `\n`) only -* No global variables or functions -* Unit tests -* HTML should be HTML5 compliant -* When you `git pull`, always `git pull --rebase` to avoid generating extra commits like: _merged master into master_ - -CSS ---- - -Take a look at the http://www.youtube.com/watch?v=hou2wJCh3XE&feature=plcp[Writing Tactical CSS & HTML] video on YouTube. - -Don’t bind your CSS too much to your HTML structure and try to avoid -IDs. Also try to make your CSS reusable by grouping common attributes -into classes. - -*DO*: - -[source,css] ----- -.list { - list-style-type: none; -} - -.list > .list_item { - display: inline-block; -} - -.important_list_item { - color: red; -} ----- - -*DON’T*: - -[source,css] ----- -#content .myHeader ul { - list-style-type: none; -} - -#content .myHeader ul li.list_item { - color: red; - display: inline-block; -} ----- - -== General - -* Ideally, discuss your plans on the -https://talk.owncloud.com[chat system] to see -if others want to work with you on it -* We use https://github.com/owncloud[Github], please get an account -there and clone the repositories you want to work on -* Fixes go directly to master, nevertheless they need to be tested -thoroughly. -* New features are always developed in a branch and only merged to -master once they are fully done. -* Software should work. We only put features into master when they are -complete. It’s better to not have a feature instead of having one that -works poorly. -* It is best to start working based on an issue - create one if there is -none. You describe what you want to do, ask feedback on the direction -you take it and take it from there. -* When you are finished, use the merge request function on Github to -create a pull request. The other developers will look at it and give you -feedback. You can signify that your PR is ready for review by adding the -label `5 - ready for review` to it. You can also post your merge -request to the mailing list to let people know. See -the code review page for more information <../bugtracker/codereviews> -* It is essential to keep changes small and separate. The bigger a PR -grows, the harder it is to complete a quick and efficient review. Given -that, split larger changes up into smaller changes, where you can. For -example, if you need a minor improvement, get it in first rather than -adding it as part of a much larger piece of work. -* Decisions are made by consensus. We strive for making the best -technical decisions and as nobody can know everything, we collaborate. -That means a first negative comment might not be the final word, neither -is positive feedback an immediate GO. ownCloud is built out of modular -pieces (apps) and maintainers have a strong influence. In case of -disagreement we consult other seasoned contributors. - -== Labels - -We assign labels to issues and pull requests to make it easier to find -them as well as to signal what needs to be done with them. Some of these -are assigned by the developers, others by QA, bug triggers, project lead -or maintainers and so on. It is not desired that users/reporters of bugs -assign labels themselves, unless they are developers/contributors to -ownCloud. - -The most important labels and their meaning: - -[cols="1,2"] -|=== -| Label | Meaning - -| `#bug` -| This issue is a bug - -| `#enhancement` -| This issue is a feature request/idea for improvement of ownCloud - -| `#design` -| This needs help from the design team or is a design-related issue/pull request - -| `#sharing` -| This issue or PR is related to sharing - -| `#technical debt` -| This issue or PR is about http://en.wikipedia.org/wiki/Technical_debt[technical debt] - -| `#sev1-critical` `#sev2-high` `#sev3-medium` `#sev4-low ` -| Signify how important the bug is. - -| `#p1-urgent` `#p2-high` `#p3-medium` `#p4-low` -| Signify the priority of the bug. - -| `#Junior Job` -| These are issues which are relatively easy to solve and ideal for people who want to learn how to code in ownCloud - -| `#triage` | This issue _has to be_ xref:bugtracker/triaging.adoc[triaged] -| `#needs info` | This issue needs further information from the reporter, see xref:bugtracker/triaging.adoc[triaged] old tag is #clarification request, please don’t use that one anymore. -| `#discussion` | This issue needs to be discussed -| `#security` | This is a security related issue -| `#windows server` | This is related to windows server -| `#research` | This item requires some research before it can continue -| `#packaging` | This is related to packaging -| `#theming` | Refers to theming issues or improvements -| `#l10n` | Refers to translation issues or improvements -| `#release note` | Relevant for the release notes -| `#privacy` | Refers to issues that might lead to privacy concerns -| `#won't fix` | This problem won’t be fixed (can be for a wide variety of reasons.) -|=== - -=== Tag Groups - -[cols="1,1,2"] -|=== -| Group | Tags | Description - -| App tags -| #app:files #app:user_ldap #app:files_versions and so on. -| These tags indicate the app that is impacted by the issue or which the PR is related to - -| Settings tags -| #settings:personal #settings:apps #settings:admin and so on. -| These tags indicate the settings area that is impacted by the issue or which the PR is related to - -| db tags -| #db:mysql #db:sqlite #db:postgresql and so on. -| These tags indicate the database that is impacted by the issue or which the PR is related to - -| Browser tags -| #browser:ie #browser:safari and so on. -| These tags indicate the browser that is impacted by the issue or which the PR is related to - -| Component tags -| #comp:filesystem #comp:javascript and so on. -| These tags indicate the components of ownCloud impacted by the issue or which the PR is related to - -| Development tool tags -| #dev:unit_testing #dev:public_API and so on. -| These tags indicate development-specific tools like those for testing and public developer-facing API’s impacted by the issue or which the PR is related - -| Feature tags: -| #feature:something. -| These tags indicate the features across apps and components which are impacted by the issue or which the PR is related to -|=== - -=== Labels showing the state of the issue or PR (numbered 1-6) - -[cols="1,2"] -|=== -| Label | Description -| `#1 - To develop` | Ready to start development on this -| `#2 - Developing` | Development in progress -| `#3 - To Review` | Ready for review -| `#4 - To Release` | Reviewed PR that awaits unfreeze of a branch to get merged -|=== - -=== Severity Level Labels - -To better understand which severity level to apply, if any, here is a -description of each of the four severity labels. - -[cols="1,2",options="header",] -|======================================================================= -| Label -| Description - -| #sev1-critical -| The operation is in production and is mission critical to the business. The product is inoperable and the situation is resulting in a total disruption of work. There is no workaround available. - -| #sev2-high -| Operations are severely restricted. Important features are unavailable, although work can continue in a limited fashion. A workaround is available. - -| #sev3-medium -| The product does not work as designed resulting in a minor loss of usage. A workaround is available. - -| #sev4-low -| There is no loss of service. This may be a request for documentation, general information, product enhancement request, etc. -|======================================================================= - -=== Don’t See The Label You Need? - -If you want a label not in the list above, please first discuss on the -mailing list. - -== JavaScript - -In general take a look at http://www.jslint.com/[JSLint] without the -whitespace rules. - -* Use a js/main.js or js/app.js where your program is started -* Complete every statement with a *;* -* Use *var* to limit variable to local scope -* To keep your code local, wrap everything in a self executing function. -To access global objects or export things to the global namespace, pass -all global objects to the self executing function. -* Use JavaScript strict mode -* Use a global namespace object where you bind publicly used functions -and objects to - -*DO*: - -[source,javascript] ----- -// set up namespace for sharing across multiple files -var MyApp = MyApp || {}; - -(function(window, $, exports, undefined) { - 'use strict'; - - // if this function or object should be global, attach it to the namespace - exports.myGlobalFunction = function(params) { - return params; - }; - -})(window, jQuery, MyApp); ----- - -*DONT* (Seriously): - -[source,javascript] ----- -// This does not only make everything global but you're programming -// JavaScript like C functions with namespaces -MyApp = { - myFunction:function(params) { - return params; - }, - ... -}; ----- - -=== Objects & Inheritance - -Try to use OOP in your JavaScript to make your code reusable and -flexible. - -This is how you’d do inheritance in JavaScript: - -[source,javascript] ----- -// create parent object and bind methods to it -var ParentObject = function(name) { - this.name = name; -}; - -ParentObject.prototype.sayHello = function() { - console.log(this.name); -} - - -// create childobject, call parents constructor and inherit methods -var ChildObject = function(name, age) { - ParentObject.call(this, name); - this.age = age; -}; - -ChildObject.prototype = Object.create(ParentObject.prototype); - -// overwrite parent method -ChildObject.prototype.sayHello = function() { - // call parent method if you want to - ParentObject.prototype.sayHello.call(this); - console.log('childobject'); -}; - -var child = new ChildObject('toni', 23); - -// prints: -// toni -// childobject -child.sayHello(); ----- - -=== Objects, Functions & Variables - -Use Pascal case for Objects, Camel case for functions and variables. - -[source,javascript] ----- -var MyObject = function() { - this.attr = "hi"; -}; - -var myFunction = function() { - return true; -}; - -var myVariable = 'blue'; - -var objectLiteral = { - value1: 'somevalue' -}; ----- - -=== Operators - -Use *===* and *!==* instead of *==* and *!=*. - -Here’s why: - -[source,javascript] ----- -` == '0' // false -0 == ` // true -0 == '0' // true - -false == 'false' // false -false == '0' // true - -false == undefined // false -false == null // false -null == undefined // true - -' \t\r\n ' == 0 // true ----- - -=== Control Structures - -* Always use \{ } for one line ifs -* Split long ifs into multiple lines -* Always use break in switch statements and prevent a default block with -warnings if it shouldn’t be accessed - -*DO*: - -[source,javascript] ----- -// single line if -if (myVar === 'hi') { - myVar = 'ho'; -} else { - myVar = 'bye'; -} - -// long ifs -if ( something === 'something' - || condition2 - && condition3 -) { - // your code -} - -// for loop -for (var i = 0; i < 4; i++) { - // your code -} - -// switch -switch (value) { - - case 'hi': - // yourcode - break; - - default: - console.warn('Entered undefined default block in switch'); - break; -} ----- - -PHP ---- - -The ownCloud coding style guide is based on -http://pear.php.net/manual/en/standards.php[PEAR Coding Standards]. To -check your PHP codestyle use -https://github.com/squizlabs/PHP_CodeSniffer[PHP Code Sniffer] >= 3.0 -with the `phpcs.xml` config file from the core branch. - -To check one file use: `phpcs --standard=./phpcs.xml yourCode.php` - -To check all files in a folder (recursive) use: -`phpcs --standard=./phpcs.xml your/code/folder/` - -A https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks[git -pre-commit hook] is available -https://raw.githubusercontent.com/Ikke/git-precommit-phpcs/master/pre-commit[here]. -Download and save the file in the `.git/hooks` folder of your owncloud -project and change the `PHPCS_STANDARD` constant to the path of the -`phpcs.xml` file. - -=== Start & closing - -Always use: - ----- - ----- - -should not be used at the end of the file due to the -http://stackoverflow.com/questions/4410704/php-closing-tag[possible -issue of sending white spaces]. - -=== Comments - -All API methods need to be marked with -http://en.wikipedia.org/wiki/PHPDoc[PHPDoc] markup. An example would be: - -[source,php] ----- - 'bar', - 'spam' => 'ham', -); - -?> ----- - -=== Operators - -Use *===* and *!==* instead of *==* and *!=*. - -Here’s why: - -[source,php] ----- - true -var_dump("1" == "01"); // 1 == 1 -> true -var_dump("10" == "1e1"); // 10 == 10 -> true -var_dump(100 == "1e2"); // 100 == 100 -> true - -?> ----- - -=== Control Structures - -* Always use \{ } for one line ifs -* Split long ifs into multiple lines -* Always use break in switch statements and prevent a default block with -warnings if it shouldn’t be accessed - -[source,php] ----- - ----- - -=== Unit tests - -Unit tests must always extend the `\Test\TestCase` class, which takes -care of cleaning up the installation after the test. - -If a test is run with multiple different values, a data provider must be -used. The name of the data provider method must not start with `test` -and must end with `Data`. - -[source,php] ----- -assertEquals($expected, \Dummy::method($input)); - } -} ----- - -== User Interface - -* Software should not get in the way of what the user needs to do. It -should do as much as possible automatically, instead of offering -configuration options for the user to chose from. -* Software should be easy to use. Show only the most important elements. -Secondary elements should only appear as a result of a hovering the -mouse over an element, or via choosing advanced functionality. -* User data is sacred. Provide undo instead of asking for confirmation - -http://www.alistapart.com/articles/neveruseawarning/[which might be -dismissed] -* The state of the application should be clear. If something loads, -provide feedback. -* Do not adapt broken concepts (for example design of desktop apps) just -for the sake of consistency. We aim to provide a better interface, so -let’s find out how to do that! -* Regularly reset your installation to see what the first-run experience -looks like — then improve it! -* Ideally do -http://jancborchardt.net/usability-in-free-software[usability testing] -to know how people use the software. -* For further UX principles, read -http://uxmag.com/articles/quantifying-usability[Alex Faaborg from -Mozilla]. diff --git a/content/server/10.15/modules/developer_manual/pages/general/debugging.adoc b/content/server/10.15/modules/developer_manual/pages/general/debugging.adoc deleted file mode 100644 index 5bc2b86..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/debugging.adoc +++ /dev/null @@ -1,88 +0,0 @@ -= Debugging -:toc: right - -== Debugging HTML and templates - -By default ownCloud caches HTML generated by templates. This may prevent -changes to app templates, for example, from being applied on page -refresh. To disable caching, see Debug mode. - -== Debugging Javascript - -By default all JavaScript files in ownCloud are minified (compressed) -into a single file without whitespace. To prevent this, see Debug mode. - -== Debug mode - -When debug mode is enabled in ownCloud, a variety of debugging features -are enabled - see debugging documentation. Set `debug` to `true` in -/config/config.php to enable it: - -== Debugging variables - -You should use exceptions if you need to debug variable values manually, -and not alternatives like trigger_error() (which may not be logged), -e.g.,: - -[source,php] ----- - ----- - -not: - -[source,php] ----- - ----- - -To disable custom error handling in ownCloud (and have PHP and your Web -server handle errors instead), see Debug mode. - -== Identifying errors - -ownCloud uses custom error PHP handling that prevents errors being -printed to Web server log files or command line output. Instead, errors -are generally stored in ownCloud’s own log file, located at: -/data/owncloud.log. - -== Using alternative app directories - -It may be useful to have multiple app directories for testing purposes, -so you can conveniently switch between different versions of -applications. See the configuration file documentation for details. - -== Using a PHP debugger (XDebug) - -Using a debugger connected to PHP allows you to step through code line -by line, view variables at each line and even change values while the -code is running. The de-facto standard debugger for PHP is XDebug, -available as an installable package in many distributions. It just -provides the PHP side however, so you will need a frontend to actually -control XDebug. When installed, it needs to be enabled in php.ini, along -with some parameters to enable connections to the debugging interface: - -XDebug will now (when activated) try to connect to localhost on port -9000, and will communicate over the standard protocol DBGP. This -protocol is supported by many debugging interfaces, such as the -following popular ones: - -* vdebug - Multi-language DBGP debugger client for Vim -* SublimeTextXdebug - XDebug client for Sublime Text -* PhpStorm - in-built DBGP debugger - -For further reading, see the XDebug documentation: -http://xdebug.org/docs/step_debug - -Once you are familiar with how your debugging client works, you can -start debugging with XDebug. To test ownCloud through the web interface -or other HTTP requests, set the `XDEBUG_SESSION_START` cookie or POST -parameter. Alternatively, there are browser extensions to make this easy: - -* XDebug for Firefox: -https://addons.mozilla.org/en-US/firefox/search/?q=xdebug -* XDebug Helper for Chrome: -https://chrome.google.com/webstore/detail/xdebug-helper/eadndfjplgieldjbigjakmdgkmoaaaoc - -For debugging scripts on the command line, like `occ` or unit tests, set -the `XDEBUG_CONFIG` environment variable. diff --git a/content/server/10.15/modules/developer_manual/pages/general/devenv.adoc b/content/server/10.15/modules/developer_manual/pages/general/devenv.adoc deleted file mode 100644 index f549396..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/devenv.adoc +++ /dev/null @@ -1,259 +0,0 @@ -= Setup Your Development Environment -:toc: right - -== Introduction - -This page helps with setting up your environment for use with and developing ownCloud. - -Feel free to skip already one or more of the following steps, if you have already completed them. -Otherwise, if you’re just getting started, begin by getting the ownCloud source code. - -== Install the Core Software - -The first thing to do is to ensure that your server has the necessary software for installing and running ownCloud. -While you can go further, you need to install at least the -xref:admin_manual:installation/manual_installation/manual_installation.adoc[required packages]. -Then, you will need to install the software required to run the development environment's installation process. - -* https://www.gnu.org/software/make/[Make] -* https://nodejs.org[Node.js] -* https://git-scm.com/[git] -* https://www.npmjs.com/[npm] -* https://linux.die.net/man/1/unzip[unzip] -* https://www.gnu.org/software/wget/[wget] - -=== Install Dependencies on Ubuntu 16.04/18.04 - -==== Install nodejs, make, unzip, and git - -[source,console] ----- -cd ~ -curl -sL https://deb.nodesource.com/setup_8.x -o nodesource_setup.sh -sudo bash nodesource_setup.sh -sudo apt-get -y -q update -sudo apt-get -y -q upgrade -sudo apt-get install nodejs build-essential make unzip git ----- - -==== Install Composer - -===== Prepare the Installation - -[source,console] ----- -cd ~/tmp -sudo apt-get install wget php-cli php-zip -php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" -HASH="$(wget -q -O - https://composer.github.io/installer.sig)" -php -r "if (hash_file('SHA384', 'composer-setup.php') === '$HASH') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" ----- - -If the hashes match, you will see the following output: - ----- -Installer verified ----- - -===== Install Composer - -To install Composer, run the following command: - -[source,console] ----- -sudo php composer-setup.php \ - --install-dir=/usr/local/bin \ - --filename=composer ----- - -Running the command will produce output similar to the following. - ----- -All settings correct for using Composer -Downloading... - -Composer (version 1.7.2) successfully installed to: /usr/local/bin/composer -Use it: php /usr/local/bin/composer ----- - -===== Verify the Installation - -To verify that Composer is properly installed, run `composer`. -You should see output similar to that below. - -[source,console] ----- - ______ - / ____/___ ____ ___ ____ ____ ________ _____ - / / / __ \/ __ `__ \/ __ \/ __ \/ ___/ _ \/ ___/ -/ /___/ /_/ / / / / / / /_/ / /_/ (__ ) __/ / -\____/\____/_/ /_/ /_/ .___/\____/____/\___/_/ - /_/ -Composer version 1.8.4 2019-02-11 10:52:10 ----- - -Composer is fully installed, and ready to be used. - -==== Install Yarn - - -[source,console] ----- -# Enable the Yarn repository -curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - - -# Add the Yarn APT repository to your system’s software repository list: -echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list - -# Update the package list and install Yarn: -sudo apt-get update -sudo apt-get install --no-install-recommends yarn ----- - -===== Verify that Yarn installed successfully: - -After you have installed yarn, you can run `yarn --version` to confirm that it’s fully installed. -If it is, then it will print output similar to the following to the console. - ----- -yarn version v1.13.0 ----- - -=== Install Dependencies on openSUSE Leap 42.3 - ----- -# Ensure that Zypper's cache is up to date -sudo zypper --non-interactive --quiet \ - update --auto-agree-with-licenses --best-effort - -# Auto-install the required dependencies with a minimum of output -sudo zypper --quiet --non-interactive install \ - wget make nodejs6 nodejs-common unzip git - npm6 phantomjs php7-curl php7-openssl openssl php7-phar ----- - -== Setup the Webserver and Database - -Next, you need to setup your web and database servers, so that they work -properly with ownCloud. The respective guides are available at: - -* xref:admin_manual:installation/manual_installation/manual_installation.adoc#configure-the-web-server[Apache Webserver Configuration] -* xref:admin_manual:configuration/database/linux_database_configuration.adoc[Database Server Configuration] - -== Get The Source - -With the web and database servers setup, you next need to get a copy of -ownCloud. There are two ways to do so: - -. Use a xref:admin_manual:installation/manual_installation/manual_installation.adoc[manual installation] -. Clone the development version from https://github.com/owncloud[GitHub]: - -For the sake of a brief example, assuming you chose to clone from -GitHub, here’s an example of how to do so: - ----- -# Assuming that /var/www/html is the webserver's document root -git clone https://github.com/owncloud/core.git /var/www/html/core ----- - -*What is the Web Server’s Root Directory?* - -The quickest way to find out is by using the `ls` command, for example: -`ls -lah /var/www`. Depending on your Linux distribution, it’s likely -to be one of `/var/www`, `/var/www/html`, or `/srv/http`. - -=== Set User, Group, and Permissions - -You now need to make sure that the web server user (and optionally the -web server’s group) have read/write access to the directory where you -installed ownCloud: The following commands assume that `/var/www` is the -web server’s directory and that `www-data` is the web server user and -group. The following commands will do this: - ----- -# Set the user and group to the webserver user and group -sudo chown -R www-data:www-data /var/www/html/core/ - -# Set read/write permissions on the directory -sudo chmod o+rw -R /var/www/html/core/ ----- - -*What is the Web Server’s User and Group?* - -There are a few ways to identify the user and group the webserver is -running as. Likely the easiest are `grep` and `ps`. Here’s an example of -using both (which assumes that the distribution is Ubuntu 16.04). - ----- -# Find the user defined in Apache's configuration files -grep -r 'APACHE_RUN_USER' /etc/apache2/ - -# Find the user that's running Apache. -ps -aux | grep apache2 ----- - -Depending on your distribution, it will likely be one of `http`, `www-data`, `apache`, or `wwwrun`. - - -== Install Software Dependencies - -With the ownCloud source -xref:admin_manual:installation/manual_installation/manual_installation.adoc#configure-the-web-server[available to your webserver], -next install ownCloud’s dependencies by running -https://www.gnu.org/software/make/[Make], from the directory where -ownCloud’s located. Here’s an example of how to do so: - -[source,console] ----- -# Assuming that the ownCloud source is located in `/var/www/html/core` -cd /var/www/html/core && make ----- - -By default, running `make` will install the required dependencies for -both PHP and JavaScript. However, there are other options that it -supports, which you can see in the table below, which are useful for a -variety of tasks. - -[cols=",",options="header",] -|=== -| Target | Description -| make | Pulls in both Composer and Bower dependencies -| make clean | Cleans up dependencies. This is useful for starting over or when switching to older branches -| make dist | Builds a minimal owncloud-core tarball with only core apps in build/dist/core, stripped -of unwanted files -| make docs | Builds the JavaScript documentation using http://usejsdoc.org[JSDoc] -| make test | Runs all of the test targets -| make test-external | Runs one of the external storage tests, and is configurable through make variables -| make test-js | Runs the Javascript unit tests, replacing ./autotest-js.sh -| make test-php | Runs the PHPUnit tests with SQLite as the data source. + -This replaces ./autotest.sh sqlite and is configurable through make variables -|=== - -== Enable Debug Mode - -Now that ownCloud’s available to your web server and the dependencies -are installed, we strongly encourage you to disable JavaScript and CSS -caching during development. This is so that when changes are made, -they’re immediately visible, not at some later stage when the respective -caches expire. To do so, enable debug mode by setting `debug` to `true` -in config/config.php, as in the example below. - -[source,php] ----- - true, - ... configuration goes here ... -]; ----- - -Do not enable this for production! This can create security problems and -is only meant for debugging and development! - -== Setup ownCloud - -With all that done, you’re now ready to use either -xref:admin_manual:installation/installation_wizard.adoc[the installation wizard] or -xref:admin_manual:installation/manual_installation/manual_installation.adoc#command-line-installation[command line installer] -to finish setting up ownCloud. diff --git a/content/server/10.15/modules/developer_manual/pages/general/examples/debugging/debug-mode.php b/content/server/10.15/modules/developer_manual/pages/general/examples/debugging/debug-mode.php deleted file mode 100644 index 55a7545..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/examples/debugging/debug-mode.php +++ /dev/null @@ -1,6 +0,0 @@ - true, - // ... configuration goes here ... - ]; diff --git a/content/server/10.15/modules/developer_manual/pages/general/examples/debugging/xdebug.ini b/content/server/10.15/modules/developer_manual/pages/general/examples/debugging/xdebug.ini deleted file mode 100644 index 82225d5..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/examples/debugging/xdebug.ini +++ /dev/null @@ -1,5 +0,0 @@ -zend_extension=/usr/lib/php/modules/xdebug.so -xdebug.remote_enable=on -xdebug.remote_host=127.0.0.1 -xdebug.remote_port=9000 -xdebug.remote_handler=dbgp diff --git a/content/server/10.15/modules/developer_manual/pages/general/index.adoc b/content/server/10.15/modules/developer_manual/pages/general/index.adoc deleted file mode 100644 index 8b80ef2..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/index.adoc +++ /dev/null @@ -1,3 +0,0 @@ -= General - -In this section you will find a range of general information on developing with ownCloud, such as xref:general/performance.adoc[performance], xref:general/security.adoc[security], xref:general/debugging.adoc[debugging], and xref:general/backporting.adoc[backporting]. diff --git a/content/server/10.15/modules/developer_manual/pages/general/performance.adoc b/content/server/10.15/modules/developer_manual/pages/general/performance.adoc deleted file mode 100644 index 7a327eb..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/performance.adoc +++ /dev/null @@ -1,107 +0,0 @@ -= Performance Considerations -:toc: right -:toclevels: 1 - -== Introduction - -This document introduces some common considerations and tips on -improving performance of ownCloud. Speed of ownCloud is important - -nobody likes to wait and often, what is _just slow_ for a small amount -of data will become _unusable_ with a large amount of data. Please keep -these tips in mind when developing for ownCloud and consider reviewing -your app to make it faster. - -*Tips welcome*: More tips and ideas on performance are very welcome! - -== Database performance - -The database plays an important role in ownCloud performance. The -general rule is: database queries are very bad and should be avoided if -possible. The reasons for that are: - -* Roundtrips: Bigger ownCloud installations have the database not -installed on the application server but on a remote dedicated database -server. The problem is that database queries then go over the network. -These roundtrips can add up significantly if you have a lot of queries. -* Speed. A lot of people think that databases are fast. This is not -always true if you compare it with handling data internally in PHP or in -the filesystem or even using key/value based storages. So every -developer should always double check if the database is really the best -place for the data. -* Scalability. If you have a big ownCloud cluster setup you usually have -several ownCloud/Web servers in parallel and a central database and a -central storage. This means that everything that happens on the -ownCloud/PHP side can parallelize and can be scaled. Stuff that is -happening in the database and in the storage is critical because it only -exists once and can’t be scaled so easily. - -We can reduce the load on the database by: - -1. Making sure that every query uses an index. -2. Reducing the overall number of queries. -3. If you are familiar with cache invalidation you can try caching -query results in PHP. - -There a several ways to monitor which queries are actually executed on -the database. - -With MySQL it is very easy with just a bit of configuration: - -1. Slow query log. - -If you put this into your my.cnf file, every query that takes longer -than one second is logged to a logfile: - ----- -log_slow_queries = 1 -log_slow_queries = /var/log/mysql/mysql-slow.log -long_query_time=1 ----- - -If a query takes more than a second we have a serious problem of course. -You can watch it with tail -f /var/log/mysql/mysql-slow.log while using -ownCloud. - -1. log all queries. - -If you reduce the long_query_time to zero then every statement is -logged. This is super helpful to see what is going on. Just do a tail -f -on the logfile and click around in the interface or access the WebDAV -interface: - ----- -log_slow_queries = 1 -log_slow_queries = /var/log/mysql/mysql-slow.log -long_query_time=0 ----- - -1. log queries without an index. - -If you increase the long_query_time to 100 and add -log-queries-not-using-indexes, all the queries that are not using an -index are logged. Every query should always use an index. So ideally -there should be no output: - ----- -log-queries-not-using-indexes -log_slow_queries = 1 -log_slow_queries = /var/log/mysql/mysql-slow.log -long_query_time=100 ----- - -=== Measuring performance - -If you do bigger changes in the architecture or the database structure -you should always double check the positive or negative performance -impact. There are a -https://github.com/owncloud/administration/tree/master/performance-tests[few -nice small scripts] that can be used for this. - -The recommendation is to automatically do 10000 PROPFINDs or file -uploads, measure the time and compare the time before and after the -change. - -== Getting help - -If you need help with performance or other issues please ask on our -https://talk.owncloud.com[chat system] for more details. diff --git a/content/server/10.15/modules/developer_manual/pages/general/security.adoc b/content/server/10.15/modules/developer_manual/pages/general/security.adoc deleted file mode 100644 index d8603f2..0000000 --- a/content/server/10.15/modules/developer_manual/pages/general/security.adoc +++ /dev/null @@ -1,671 +0,0 @@ -= Security Guidelines -:toc: right -:xss-link: https://www.owasp.org/index.php/Cross-site_Scripting_(XSS) - -== Introduction - -These security guidelines are for both core and application developers. -They: - -* highlight some of the most common security problems and how to prevent -them. -* give you some best practices and tips about security when developing -with ownCloud. - -Please use them to assess how secure your application is. - -*Program defensively*: for instance always check for CSRF or escape -strings, even if you do not need it. Doing so prevents future problems -where you might miss a change that leads to a security hole. - -All application Framework security features depend on the call of the -controller through `OCA\\AppFramework\\App::main`. If the controller -method executes directly, security checks are not performed! - -== General - -=== Source Code Analysis - -Before releasing an application and after security-related changes, the -complete source code *must* be scanned. We currently use -http://rips-scanner.sourceforge.net/[RIPS] to perform scans. Affected -Software: - -* Core -* All apps in core -* All apps in the marketplace - -== Architecture - -=== Security Related Comments in Source Code - -* Security-related comments in source code are forbidden. Source code -means PHP code and especially JavaScript code. Security-related comments -are: -** Usernames and passwords -** Descriptions of processes and algorithms -* Before deploying your code, -use a minifier for JavaScript and CSS files. - -=== HTTP or HTTPS - -* Only use HTTPS for rendering content. -* Avoid switching between HTTP and HTTPS, which creates -https://developer.mozilla.org/en-US/docs/Web/Security/Mixed_content[mixed-content -pages]. - -=== Security Related Actions - -* All security-related actions must take place on the server. This -includes _validation_, _authentication_, and _authorization_. -Authorization implementations on the client side are only useful for -providing a better user experience. -* Don’t hard-code passwords or encryption keys in the source code. They -have to be in config files and should be user-generated. - -=== Browser plugins - -Don’t use browser plugins such as: - -* ActiveX Controls -* Java Applets -* Flash - -=== Least Privilege Principle - -* Every application should only have the rights that it needs. -* An application should not access core database tables. If it needs -data from these tables, it should call an API endpoint to retrieve it. - -=== Error Messages and Error Pages - -* Don’t show sensitive information on error pages or in error messages. -Sensitive information includes: -** Username/password -** E-Mail addresses -** Version numbers -** Paths -* Don’t show overly detailed information in error messages or on error -pages. -+ -*Example:* -+ -If a user can’t login, don’t show an error like: `__Your password is -wrong__`. Instead, show a message such as: `__There was an error with -your credentials__`. If you print `__Your password is wrong__` then -an attacker knows the username was a valid one in the ownCloud -installation. -* Consider implementing a https://en.wikipedia.org/wiki/CAPTCHA[CAPTCHA] -to prevent brute force attacks, after five failed login attempts. - -=== Session ID Transport - -* Don’t use a session id as a GET Parameter, because these persist in -browser history. Use cookies instead. - -=== New Session ID After a Successful Login - -* After a successful login, regenerate the session id to prevent -https://www.owasp.org/index.php/Session_fixation[session fixation attacks]. -* If you have to switch between HTTPS and HTTP, you should change the -session id, because an attacker could have already read the session id. - -== Access Protection With Authorization Checks - -* Every request to the server must check if the user has the -authorization to perform this request. We do not recommend running these -on the client-side, as they can be avoided. However, client-side checks -can improve the user’s experience. - -== Best Practices - -=== Use of the eval Function - -* Don’t use either PHP’s or JavaScript’s `eval` functions — especially -not with user-supplied data. - -=== Input Validation - -* All user-supplied data, `$_SERVER`, and `$_COOKIE` variables *must* be -validated. All these contain data which can be changed (or forged) by -the client. -* Sanitize any supplied script code. - -*Example:* - -If you expect to receive an integer id as a GET parameter, then always -explicitly cast it into an integer using the cast operator `(int)`, -because all `$_REQUEST` parameters are strings. However, if you expect -text as a parameter, use -{php-net-url}/manual/en/function.htmlspecialchars.php[PHP’s htmlspecialchars function] with -`ENT_QUOTES` or `strip_tags` to prevent {xss-link}[Cross-site Scripting (XSS) attacks]. - -[source,php] ----- -Test", ENT_QUOTES); -echo $neu; // <a href='test'>Test</a> ----- - -[source,php] ----- -Test-Absatz.

      Anderer Text'; -echo strip_tags($text); -echo "\n"; ----- - -*Output:* - -[source,console] ----- -Test-Absatz. Anderer Text -

      Test-Absatz.

      Anderer Text ----- - -Do the validation *before* all other actions. - -=== Path Traversal and Path Manipulation - -* Don’t use user-supplied data to build path names, if you need to -access the file system. You have to check the input parameters for null -bytes (`\0`), the links to the current and parent directory on -UNIX/Linux filesystems (`.` and `..`), and empty strings. - -=== Prevent Command Injection - -* Use {php-net-url}/manual/en/function.escapeshellarg.php[PHP’s escapeshellarg() function], if your input parameters are arguments for -{php-net-url}/manual/en/function.exec.php[exec()], -{php-net-url}/manual/en/function.popen.php[popen()], -{php-net-url}/manual/en/function.system.php[system()], or the backtick (``) operator. -+ -[source,php] ----- - ----- - -== Attack Vectors - -=== Auth bypass / Privilege escalations - -Auth bypass/privilege escalations happen when users can perform -unauthorized actions. ownCloud offers three simple checks: - -* *OCP\JSON::checkLoggedIn()*: Checks if the logged in user is logged in -* *OCP\JSON::checkAdminUser()*: Checks if the logged in user has admin -privileges -* *OCP\JSON::checkSubAdminUser()*: Checks if the logged in user has -group admin privileges - -These checks are already automatically performed, by the application -framework, for each request. If they are not required, they have to be -_explicitly_ turned off by using annotations above your xref:app/fundamentals/controllers.adoc[controller method]. Additionally, always check /if the user has the right to perform that action. - -=== Clickjacking - -http://en.wikipedia.org/wiki/Clickjacking[Clickjacking] tricks the user -to click into an invisible iframe to perform an arbitrary action (e.g., -deleting a user account). - -To prevent such attacks ownCloud sends the X-Frame-Options header to all -template responses. Don’t remove this header unless you need to! - -This functionality is built into ownCloud when -xref:app/fundamentals/templates.adoc[ownCloud templates] or -https://twig.symfony.com/[Twig Templates] are used. - -=== Code executions / File inclusions - -Code execution means that an attacker can include an arbitrary PHP file. -This PHP file runs with all the privileges granted to the normal -application and can do an enormous amount of damage. Code executions and -file inclusions can be easily prevented by never allowing user-input to -run through the following functions: - -* *include()* -* *require()* -* *require_once()* -* *eval()* -* *fopen()* - -*Never* allow the user to upload files into a folder which is reachable -from the URL! - -*DON’T* - -[source,php] ----- -`, to take control -of the user account. The same problem occurs when outputting content -from the database, or any other location that is writable by users. -Another attack vector that is often overlooked is XSS vulnerabilities in -`href` attributes. HTML allows for executing JavaScript in `href` -attributes like this: - ----- - ----- - -To prevent XSS in your app, never use `echo`, `print()` or `<\%=`, use -`p()` instead. Doing so sanitizes input. Also *validate URLs to start -with the expected protocol* (starts with `http` for instance)! - -Should you ever need to print something unescaped, double check if it is -necessary. If there is no other way (e.g., when including sub-templates) -use print_unescaped with care. - -=== JavaScript - -Avoid manipulating HTML directly via JavaScript. Doing so often leads to -XSS vulnerabilities since people often forget to sanitize variables. For -example: - -[source,js] ----- -var html = '
    • ' + username + '
    • "'; ----- - -If you want to use JavaScript for something like this use escapeHTML to -sanitize the variables: - -[source,js] ----- -var html = '
    • ' + escapeHTML(username) + '
    • '; ----- - -An even better way to make your application safer is to use the jQuery -built-in function *$.text()*, instead of *$.html()*. - -*DON’T* - -[source,js] ----- -messageTd.html(username); ----- - -*DO* - -[source,js] ----- -messageTd.text(username); ----- - -It may also be wise to choose a proper JavaScript framework, like -AngularJS, which automatically handles JavaScript escaping for you. - -=== Directory Traversal - -Very often, developers forget about sanitizing the file path (such as -removing all `\\` and `/`). Doing so allows an attacker to traverse -through directories on the server and opens several potential attack -vendors, which include _privilege escalations_, _code executions_, and -_file disclosures_. - -*DON’T* - -[source,php] ----- -execute($params); ----- - -If the application Framework is used, write SQL queries like this in the -class that extends the Mapper: - -[source,php] ----- -execute($sql, $params); ----- - -=== Unvalidated redirects - -This is more of an annoyance than a critical security vulnerability -since it may be used for social engineering or phishing. Before -redirecting, always validate the URL if the requested URL is on the same -domain or is an allowed resource. - -*DON’T* - -[source,php] ----- - files = result.getData(); - // do your stuff here - } - } - … -} ----- - -== Read file - -Get information related to a certain file or folder, information -obtained is: `filePath`, `filename`, `isDirectory`, `size` and `date`. - -=== Code example - ----- -private void startReadFileProperties(String filePath) { - ReadRemoteFileOperation readOperation = new ReadRemoteFileOperation(filePath); - readOperation.execute(mClient, this, mHandler); -} - -@Override -public void onRemoteOperationFinish(RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof ReadRemoteFileOperation) { - if (result.isSuccess()) { - RemoteFile file = result.getData()[0]; - // do your stuff here - } - } - … -} ----- - -== Delete file or folder - -Delete a file or folder on the cloud server. The info needed is the path -of folder/file to be deleted. - -=== Code example - ----- -private void startRemoveFile(String filePath) { - RemoveRemoteFileOperation removeOperation = new RemoveRemoteFileOperation(remotePath); - removeOperation.execute( mClient , this , mHandler); -} - -@Override -public void onRemoteOperationFinish(RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof RemoveRemoteFileOperation) { - if (result.isSuccess()) { - // do your stuff here - } - } - … -} ----- - -== Download a file - -Download an existing file on the cloud server. The info needed is path -of the file on the server and targetDirectory, path where the file will -be stored on the device. - -=== Code example - -[source,java] ----- -private void startDownload(String filePath, File targetDirectory) { - DownloadRemoteFileOperation downloadOperation = new DownloadRemoteFileOperation(filePath, targetDirectory.getAbsolutePath()); - downloadOperation.addDatatransferProgressListener(this); - downloadOperation.execute( mClient, this, mHandler); -} - -@Override -public void onRemoteOperationFinish( RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof DownloadRemoteFileOperation) { - if (result.isSuccess()) { - // do your stuff here - } - } -} - -@Override -public void onTransferProgress( long progressRate, long totalTransferredSoFar, long totalToTransfer, String fileName) { -mHandler.post( new Runnable() { - @Override - public void run() { - // do your UI updates about progress here - } -}); -} ----- - -== Upload a file - -Upload a new file to the cloud server. The info needed is fileToUpload, -path where the file is stored on the device, remotePath, path where the -file will be stored on the server and mimeType. - -=== Code example - -[source,java] ----- -private void startUpload (File fileToUpload, String remotePath, String mimeType) { - UploadRemoteFileOperation uploadOperation = new UploadRemoteFileOperation( fileToUpload.getAbsolutePath(), remotePath, mimeType); - uploadOperation.addDatatransferProgressListener(this); - uploadOperation.execute(mClient, this, mHandler); -} - -@Override -public void onRemoteOperationFinish(RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof UploadRemoteFileOperation) { - if (result.isSuccess()) { - // do your stuff here - } - } -} - -@Override -public void onTransferProgress(long progressRate, long totalTransferredSoFar, long totalToTransfer, String fileName) { - mHandler.post( new Runnable() { - @Override - public void run() { - // do your UI updates about progress here - } - }); -} ----- - -== Move a file or folder - -Move an existing file or folder to a different location in the ownCloud -server. Parameters needed are the path to the file or folder to move, -and the new path desired for it. The parent folder of the new path must -exist in the server. - -When the parameter `overwrite' is set to `true', the file or folder is -moved even if the new path is already used by a different file or -folder. This one will be replaced by the former. - -=== Code example - -[source,java] ----- -private void startFileMove(String filePath, String newFilePath, boolean overwrite) { - MoveRemoteFileOperation moveOperation = new MoveRemoteFileOperation(filePath, newFilePath, overwrite); - moveOperation.execute( mClient , this , mHandler); -} - -@Override -public void onRemoteOperationFinish(RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof MoveRemoteFileOperation) { - if (result.isSuccess()) { - // do your stuff here - } - } - … -} ----- - -== Read shared items by link - -Get information about what files and folder are shared by link (the -object mClient contains the information about the server url and -account) - -=== Code example - -[source,java] ----- -private void startAllSharesRetrieval() { - GetRemoteSharesOperation getSharesOp = new GetRemoteSharesOperation(); - getSharesOp.execute( mClient , this , mHandler); -} - -@Override -public void onRemoteOperationFinish( RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof GetRemoteSharesOperation) { - if (result.isSuccess()) { - ArrayList< OCShare > shares = new ArrayList< OCShare >(); - for (Object obj: result.getData()) { - shares.add(( OCShare) obj); - } - // do your stuff here - } - } -} ----- - -== Get the share resources for a given file or folder - -Get information about what files and folder are shared by link on a -certain folder. The info needed is filePath, path of the file/folder on -the server, the Boolean variable, getReshares, come from the Sharing -api, from the moment it is not in use within the ownCloud Android -library. - -=== Code example - -[source,java] ----- -private void startSharesRetrievalForFileOrFolder(String filePath, boolean getReshares) { - GeteRemoteSharesForFileOperation operation = new GetRemoteSharesForFileOperation(filePath, getReshares, false); - operation.execute( mClient, this, mHandler); -} - -private void startSharesRetrievalForFilesInFolder(String folderPath, boolean getReshares) { - GetRemoteSharesForFileOperation operation = new GetRemoteSharesForFileOperation(folderPath, getReshares, true); - operation.execute( mClient, this, mHandler); -} - -@Override -public void onRemoteOperationFinish( RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof GetRemoteSharesForFileOperation) { - if (result.isSuccess()) { - ArrayList< OCShare > shares = new ArrayList< OCShare >(); - for (Object obj: result.getData()) { - shares.add(( OCShare) obj); - } - // do your stuff here - } -} -} ----- - -== Share link of file or folder - -Share a file or a folder from your cloud server by link. - -The info needed is filePath, the path of the item that you want to share -and Password, this comes from the Sharing api, from the moment it is not -in use within the ownCloud Android library. - -=== Code example - -[source,java] ----- -private void startCreationOfPublicShareForFile(String filePath, String password) { - CreateRemoteShareOperation operation = new CreateRemoteShareOperation(filePath, ShareType.PUBLIC_LINK, "", false, password, 1); - operation.execute( mClient , this , mHandler); -} - -private void startCreationOfGroupShareForFile(String filePath, String groupId) { - CreateRemoteShareOperation operation = new CreateRemoteShareOperation(filePath, ShareType.GROUP, groupId, false , "", 31); - operation.execute(mClient, this, mHandler); -} - -private void startCreationOfUserShareForFile(String filePath, String userId) { - CreateRemoteShareOperation operation = new CreateRemoteShareOperation(filePath, ShareType.USER, userId, false, "", 31); - operation.execute(mClient, this, mHandler); -} - -@Override -public void onRemoteOperationFinish( RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof CreateRemoteShareOperation) { - if (result.isSuccess()) { - OCShare share = (OCShare) result.getData ().get(0); - // do your stuff here - } - } -} ----- - -== Delete a share resource - -Stop sharing by link a file or a folder from your cloud server. - -The info needed is the object OCShare that you want to stop sharing by -link. - -=== Code example - -[source,java] ----- -private void startShareRemoval(OCShare share) { - RemoveRemoteShareOperation operation = new RemoveRemoteShareOperation((int) share.getIdRemoteShared()); - operation.execute( mClient, this, mHandler); -} - -@Override -public void onRemoteOperationFinish( RemoteOperation operation, RemoteOperationResult result) { - if (operation instanceof RemoveRemoteShareOperation) { - if (result.isSuccess()) { - // do your stuff here - } - } -} ----- - -== Tips - -* Credentials must be set before calling any method -* Paths must not be on URL Encoding -* Correct path: `\https://example.com/owncloud/remote.php/dav/PopMusic` -* Wrong path: `\https://example.com/owncloud/remote.php/dav/Pop%20Music/` -* There are some forbidden characters to be used in folder and files names on the server, same on the ownCloud Android Library: `/`,`<`,`>`,`:`,`"`,`\``,`?`,`*`. -* Upload and download actions may be cancelled thanks to the objects `uploadOperation.cancel()`, `downloadOperation.cancel()` -* Unit tests, before launching unit tests you have to enter your account information (server url, user and password) on `TestActivity.java`. diff --git a/content/server/10.15/modules/developer_manual/pages/mobile_development/android_library/index.adoc b/content/server/10.15/modules/developer_manual/pages/mobile_development/android_library/index.adoc deleted file mode 100644 index a28f9c0..0000000 --- a/content/server/10.15/modules/developer_manual/pages/mobile_development/android_library/index.adoc +++ /dev/null @@ -1,25 +0,0 @@ -= Android Application Development - -ownCloud provides an official ownCloud Android client, which gives its -users access to their files on their ownCloud. It also includes -functionality like automatically uploading pictures and videos to -ownCloud. For third party application developers, ownCloud offers the -ownCloud Android library under the MIT license. - -== Android ownCloud Client development - -If you are interested in working on the ownCloud android client, you can find the source code https://github.com/owncloud/android/[in github]. -The setup and process of contribution is https://github.com/owncloud/android/blob/master/SETUP.md[documented here]. -You might want to start with doing one or two https://github.com/owncloud/android/issues?q=is%3Aopen+is%3Aissue+label%3A%22Junior+Job%22[junior jobs] to get into the code and note our xref:general/codingguidelines.adoc[General Contributor Guidelines]. -Note that contribution to the Android client require signing the https://owncloud.com/contribute/join-the-development/contributor-agreement/[ownCloud Contributor Agreement]. - -== ownCloud Android Library - -This document will describe how to the use ownCloud Android Library. The -ownCloud Android Library allows a developer to communicate with any -ownCloud server; among the features included are file synchronization, -upload and download of files, delete rename files and folders, etc. - -This library may be added to a project and seamlessly integrates any -application with ownCloud. The tool needed is any IDE for Android. This -guide includes some screenshots showing examples in Eclipse. diff --git a/content/server/10.15/modules/developer_manual/pages/mobile_development/android_library/library_installation.adoc b/content/server/10.15/modules/developer_manual/pages/mobile_development/android_library/library_installation.adoc deleted file mode 100644 index 9decc0e..0000000 --- a/content/server/10.15/modules/developer_manual/pages/mobile_development/android_library/library_installation.adoc +++ /dev/null @@ -1,23 +0,0 @@ -= Library Installation - -== Obtaining the library - -The ownCloud Android library may be obtained from the following GitHub repository: - -https://github.com/owncloud/android-library[https://github.com/owncloud/android-library] - -Once obtained, this code should be compiled. -The Github repository not only contains the library, but also a sample project, sample_client sample_client properties/android/librerias, which will assist in learning how to use the library. - -== Add the library to a project - -There are different methods to add an external library to a project, then we will describe one of them. - -1. Compile the ownCloud Android Library -2. Define a dependency within your project. - -For that, access menu:Properties[Android > Library], click on btn:[Add] and select the **ownCloud Android library** - -image:mobile_development/android_library/1000000000000270000003A317117674.png[1000000000000270000003A317117674_png,width=407,height=608] - -Then all the public classes and methods of the library will be available for your own app. diff --git a/content/server/10.15/modules/developer_manual/pages/mobile_development/index.adoc b/content/server/10.15/modules/developer_manual/pages/mobile_development/index.adoc deleted file mode 100644 index 2dfbbac..0000000 --- a/content/server/10.15/modules/developer_manual/pages/mobile_development/index.adoc +++ /dev/null @@ -1,3 +0,0 @@ -= Mobile Development - -In this section, you will find the core information that you need to develop mobile apps that work with ownCloud. diff --git a/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/examples.adoc b/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/examples.adoc deleted file mode 100644 index a7523bb..0000000 --- a/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/examples.adoc +++ /dev/null @@ -1,786 +0,0 @@ -= Examples - -== Init the library - -Start using the library, it is needed to init the object -OCCommunication. - -We recommend using the singleton method in the AppDelegate class in -order to use the ownCloud iOS library. - -=== Code example - -[source,Objective-C] ----- -#import "OCCommunication.h" - -+ (OCCommunication *)sharedOCCommunication -{ - static OCCommunication* sharedOCCommunication = nil; - - if (sharedOCCommunication == nil) - { - sharedOCCommunication = [ [ OCCommunicationalloc] init ]; - } - - return sharedOCCommunication; -} ----- - -Also could happen that you need to overwrite the class -AFURLSessionManager to manage SSL Certificates - -[source,objective-c] ----- -#import "OCCommunication.h" - -+ (OCCommunication*)sharedOCCommunication -{ -static OCCommunication* sharedOCCommunication = nil; -if (sharedOCCommunication == nil) -{ -//Network Upload queue for NSURLSession (iOS 7) - NSURLSessionConfiguration *configuration = [NSURLSessionConfiguration backgroundSessionConfiguration:k_session_name]; - configuration.HTTPMaximumConnectionsPerHost = 1; - configuration.requestCachePolicy = NSURLRequestReloadIgnoringLocalCacheData; - OCURLSessionManager *uploadSessionManager = [[OCURLSessionManager alloc] initWithSessionConfiguration:configuration]; - [uploadSessionManager.operationQueue setMaxConcurrentOperationCount:1]; - [uploadSessionManager setSessionDidReceiveAuthenticationChallengeBlock:^NSURLSessionAuthChallengeDisposition (NSURLSession *session, NSURLAuthenticationChallenge *challenge, NSURLCredential * __autoreleasing *credential) { - return NSURLSessionAuthChallengePerformDefaultHandling; - }]; - - sharedOCCommunication = [[OCCommunication alloc] initWithUploadSessionManager:uploadSessionManager]; - -} -return sharedOCCommunication; -} ----- - -== Set credentials - -Authentication on the app is possible by 3 different methods: - -* Basic authentication, user name and password -* Cookie -* Token (oAuth) - -=== Code example - -[source,objective-c] ----- -#Basic authentication, user name and password -[[ AppDelegate sharedOCCommunication ] setCredentialsWithUser : userName andPassword : password ]; - -#Authentication with cookie -[[ AppDelegate sharedOCCommunication ] setCredentialsWithCookie : cookie ]; - -#Authentication with token -[[ AppDelegate sharedOCCommunication ] setCredentialsOauthWithToken : token ]; ----- - -== Create a folder - -Create a new folder on the cloud server, the info needed to be sent is -the path of the new folder. - -=== Code example - -[source,objective-c] ----- -[[ AppDelegate sharedOCCommunication ] createFolder :path onCommunication : [ AppDelegate sharedOCCommunication ] - -successRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer) { -//Folder Created -} - -failureRequest :^( NSHTTPURLResponse *response, NSError *error) { - -//Failure - -switch (response.statusCode) { - -case kOCErrorServerUnauthorized : - //Bad credentials - break; -case kOCErrorServerForbidden : - //Forbidden - break; -case kOCErrorServerPathNotFound : - //Not Found - break; -case kOCErrorServerTimeout : - //timeout - break; -default: - //default - break; -} - -} -errorBeforeRequest :^( NSError *error) { -//Error before request - -if (error.code == OCErrorForbidenCharacters) { - //Forbidden characters -} -else -{ - //Other error -} - -}]; -  ----- - -== Read folder - -Get the content of an existing folder on the cloud server, the info -needed to be sent is the path of the folder. As answer of this method, -it will be received an array with all the files and folders stored in -the selected folder. - -=== Code example - -[source,objective-c] ----- -[[ AppDelegate sharedOCCommunication] readFolder:path onCommunication:[ AppDelegate sharedOCCommunication] - -successRequest:^( NSHTTPURLResponse *response, NSArray *items, NSString *redirectedServer) { - //Success - for ( OCFileDto * ocFileDto in items) { - NSLog( @"item path: %@%@" , ocFileDto.filePath, ocFileDto.fileName); - } -} - -failureRequest:^( NSHTTPURLResponse *response, NSError *error) { - -//Failure -switch (response.statusCode) { -case kOCErrorServerPathNotFound : - //Path not found - break; -case kOCErrorServerUnauthorized : - //Bad credentials - break; -case kOCErrorServerForbidden : - //Forbidden - break; -case kOCErrorServerTimeout : - //Timeout - break ; -default : - break; -} - -}]; ----- - -== Read file - -Get information related to a certain file or folder. Although, more -information can be obtained, the library only gets the eTag. - -Other properties of the file or folder may be obtained: filePath, -filename, isDirectory, size and date - -=== Code example - -[source,objective-c] ----- -[[ AppDelegate sharedOCCommunication ] readFile :path onCommunication :[ AppDelegate sharedOCCommunication ] - -successRequest :^( NSHTTPURLResponse *response, NSArray *items, NSString *redirectedServer) { - -OCFileDto *ocFileDto = [items objectAtIndex : 0 ]; -NSLog ( @"item etag: %lld" , ocFileDto. etag); } -failureRequest :^( NSHTTPURLResponse *response, NSError *error) { -switch (response.statusCode) { -case kOCErrorServerPathNotFound: - //Path not found - break; -case kOCErrorServerUnauthorized: - //Bad credentials - break; -case kOCErrorServerForbidden: - //Forbidden - break; -case kOCErrorServerTimeout: - //Timeout - break; -default: - break; -} -}]; ----- - -== Move file or folder - -Move a file or folder from their current path to a new one on the cloud -server. The info needed is the origin path and the destiny path. - -=== Code example - -[source,objective-c] ----- -[[ AppDelegate sharedOCCommunication ] moveFileOrFolder :sourcePath toDestiny :destinyPath onCommunication :[ AppDelegate sharedOCCommunication ] - -successRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer) { - //File/Folder moved or renamed -} -failureRequest :^( NSHTTPURLResponse *response, NSError *error) { - //Failure - switch (response.statusCode) { - case kOCErrorServerPathNotFound: - //Path not found - break; - case kOCErrorServerUnauthorized: - //Bad credentials - break; - case kOCErrorServerForbidden: - //Forbidden - break; - case kOCErrorServerTimeout: - //Timeout - break; - default: - break; -} - -} -errorBeforeRequest :^( NSError *error) { - if (error.code == OCErrorMovingTheDestinyAndOriginAreTheSame) { - //The destiny and the origin are the same - } - else if (error.code == OCErrorMovingFolderInsideHimself) { - //Moving folder inside himself - } - else if (error.code == OCErrorMovingDestinyNameHaveForbiddenCharacters) { - //Forbidden Characters - } - else - { - //Default - } - -}]; ----- - -== Delete file or folder - -Delete a file or folder on the cloud server. The info needed is the path -to delete. - -=== Code example - -[source,objective-c] ----- - - [[ AppDelegate sharedOCCommunication ] deleteFileOrFolder :path - onCommunication :[ AppDelegate - - sharedOCCommunication ] successRequest :^( NSHTTPURLResponse - __response, NSString__redirectedServer) \{;; - //File or Folder deleted - - } failureRequest :^( NSHTTPURLResponse __response, NSError__error) \{ - - switch (response.statusCode) \{ case kOCErrorServerPathNotFound: - //Path not found break; case kOCErrorServerUnauthorized: //Bad - credentials break; case kOCErrorServerForbidden: //Forbidden break; - case kOCErrorServerTimeout: //Timeout break; default: break; } - - }]; ----- - -== Download a file - -Download an existing file on the cloud server. The info needed is the -server URL, path of the file on the server and localPath, path where the -file will be stored on the device and a boolean to indicate if is -necessary to use LIFO queue or FIFO. - -=== Code example - -[source,objective-c] ----- -NSOperation *op = nil; -op = [[ AppDelegate sharedOCCommunication ] downloadFile :remotePath toDestiny :localPath withLIFOSystem:isLIFO onCommunication :[ AppDelegate sharedOCCommunication ] - -progressDownload :^( NSUInteger bytesRead, long long totalBytesRead, long long totalBytesExpectedToRead) { - -//Calculate percent -float percent = ( float)totalBytesRead / totalBytesExpectedToRead; - NSLog ( @"Percent of download: %f" , percent); } -successRequest :^(NSHTTPURLResponse *response, NSString *redirectedServer) { - //Download complete -} -failureRequest :^(NSHTTPURLResponse *response, NSError *error) { - switch (response. statusCode) { - case kOCErrorServerUnauthorized: - //Bad credentials - break; - case kOCErrorServerForbidden: - //Forbidden - break; - case kOCErrorProxyAuth: - //Proxy access required - break; - case kOCErrorServerPathNotFound: - //Path not found - break; - default: - //Default - break; - } -} -shouldExecuteAsBackgroundTaskWithExpirationHandler :^{ - [op cancel ]; -}]; ----- - -== Download a file with background session - -Download an existing file stored on the cloud server using background -session, only supported by iOS 7 and higher. - -The info needed is, the server URL: path where the file is stored on the -server; localPath: path where the file will be stored on the device; and -NSProgress: object where get the callbacks of the upload progress. - -To get the callbacks of the progress is needed use a KVO in the progress -object. We add the code in this example of the call to set the KVO and -the method where catch the notifications. - -=== Code example - -[source,objective-c] ----- -NSURLSessionDownloadTask *downloadTask = nil; - -NSProgress *progress = nil; - -downloadTask = [_sharedOCCommunication downloadFileSession:serverUrl toDestiny:localPath defaultPriority:YES onCommunication:_sharedOCCommunication withProgress:&progress successRequest:^(NSURLResponse *response, NSURL *filePath) { - //Upload complete - } failureRequest:^(NSURLResponse *response, NSError *error) { - - switch (error.code) { - case kCFURLErrorUserCancelledAuthentication: - //Authentication cancelled - break; - - default: - switch (response.statusCode) { - case kOCErrorServerUnauthorized : - //Bad credentials - break; - case kOCErrorServerForbidden: - //Forbidden - break; - case kOCErrorProxyAuth: - //Proxy access required - break; - case kOCErrorServerPathNotFound: - //Path not found - break; - default: - //Default - break; - } - break; - } - }]; - -// Observe fractionCompleted using KVO - [progress addObserver:self forKeyPath:@"fractionCompleted" options:NSKeyValueObservingOptionNew context:NULL]; - - -//Method to catch the progress notifications with callbacks -- (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context -{ - if ([keyPath isEqualToString:@"fractionCompleted"] && [object isKindOfClass:[NSProgress class]]) { - NSProgress *progress = (NSProgress *)object; - - float percent = roundf (progress.fractionCompleted * 100); - - //We make it on the main thread because we came from a delegate - dispatch_async(dispatch_get_main_queue(), ^{ - NSLog(@"Progress is %f", percent); - }); - } -} ----- - -== Set callback when background download task finishes - -Method to set callbacks of the pending download transfers when the app -starts. It’s used when there are pending download background transfers. -The block is executed when a pending background task finishes. - -=== Code example - -[source,objective-c] ----- -[[AppDelegate sharedOCCommunication] setDownloadTaskComleteBlock:^NSURL *(NSURLSession *session, NSURLSessionDownloadTask *downloadTask, NSURL *location) { - - -}]; ----- - -== Set progress callback with pending background download tasks - -Method to set progress callbacks of the pending download transfers. It’s -used when there are pending background download transfers. The block is -executed when a pending task get a input progress. - -=== Code example - -[source,objective-c] ----- -[[AppDelegate sharedOCCommunication] setDownloadTaskDidGetBodyDataBlock:^(NSURLSession *session, NSURLSessionDownloadTask *downloadTask, int64_t bytesWritten, int64_t totalBytesWritten, int64_t totalBytesExpectedToWrite) { - - -}]; ----- - -== Upload a file - -Upload a new file to the cloud server. The info needed is localPath, -path where the file is stored on the device and server URL, path where -the file will be stored on the server. - -=== Code example - -[source,objective-c] ----- -NSOperation *op = nil; -op = [[ AppDelegate sharedOCCommunication ] uploadFile :localPath toDestiny : remotePath onCommunication :[ AppDelegate sharedOCCommunication ] - -progressUpload :^( NSUInteger bytesWrote, long long totalBytesWrote, long long totalBytesExpectedToWrite) { - //Calculate upload percent - if ( totalBytesExpectedToRead/1024 != 0) { - if ( bytesWrote > 0) { - float percent = totalBytesWrote* 100 / totalBytesExpectedToRead; - NSLog ( @"Percent: %f" , percent); - } - } -} -successRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer) { - //Upload complete -} -failureRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer, NSError *error) { - switch (response. statusCode) { - case kOCErrorServerUnauthorized : - //Bad credentials - break; - case kOCErrorServerForbidden: - //Forbidden - break; - case kOCErrorProxyAuth: - //Proxy access required - break; - case kOCErrorServerPathNotFound: - //Path not found - break; - default: - //Default - break; - } -} -failureBeforeRequest :^( NSError *error) { - switch (error.code) { - case OCErrorFileToUploadDoesNotExist: - //File does not exist - break; - default: - //Default - break; - } -} -shouldExecuteAsBackgroundTaskWithExpirationHandler :^{ - [op cancel]; -}]; ----- - -== Upload a file with background session - -Upload a new file to the cloud server using background session, only -supported by iOS 7 and higher. - -The info needed is localPath, path where the file is stored on the -device and server URL, path where the file will be stored on the server -and NSProgress object where get the callbacks of the upload progress. - -To get the callbacks of the progress is needed use a KVO in the progress -object. We add the code in this example of the call to set the KVO and -the method where catch the notifications. - -=== Code example - -[source,objective-c] ----- -NSURLSessionUploadTask *uploadTask = nil; - -NSProgress *progress = nil; - -uploadTask = [[AppDelegate sharedOCCommunication] uploadFileSession:localPath toDestiny:remotePath onCommunication:[ AppDelegate sharedOCCommunication ] withProgress:&progress successRequest:^(NSURLResponse *response, NSString *redirectedServer) { - //Upload complete - } failureRequest:^(NSURLResponse *response, NSString *redirectedServer, NSError *error) { - switch (response.statusCode) { - case kOCErrorServerUnauthorized : - //Bad credentials - break; - case kOCErrorServerForbidden: - //Forbidden - break; - case kOCErrorProxyAuth: - //Proxy access required - break; - case kOCErrorServerPathNotFound: - //Path not found - break; - default: - //Default - break; - } - - }]; - -// Observe fractionCompleted using KVO - [progress addObserver:self forKeyPath:@"fractionCompleted" options:NSKeyValueObservingOptionNew context:NULL]; - - - -//Method to catch the progress notifications with callbacks -- (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context -{ - if ([keyPath isEqualToString:@"fractionCompleted"] && [object isKindOfClass:[NSProgress class]]) { - NSProgress *progress = (NSProgress *)object; - - float percent = roundf (progress.fractionCompleted * 100); - - //We make it on the main thread because we came from a delegate - dispatch_async(dispatch_get_main_queue(), ^{ - NSLog(@"Progress is %f", percent); - }); - - } -} ----- - -== Set callback when background task finish - -Method to set callbacks of the pending transfers when the app starts. -It’s used when there are pending background transfers. The block is -executed when a pending background task finished. - -=== Code example - -[source,objective-c] ----- -[[AppDelegate sharedOCCommunication] setTaskDidCompleteBlock:^(NSURLSession *session, NSURLSessionTask *task, NSError *error) { - - -}]; ----- - -== Set progress callback with pending background tasks - -Method to set progress callbacks of the pending transfers. It’s used -when there are pending background transfers. The block is executed when -a pending task get a input progress. - -=== Code example - -[source,objective-c] ----- -[[AppDelegate sharedOCCommunication] setTaskDidSendBodyDataBlock:^(NSURLSession *session, NSURLSessionTask *task, int64_t bytesSent, int64_t totalBytesSent, int64_t totalBytesExpectedToSend) { - - - -}]; ----- - -== Check if the server supports Sharing api - -The Sharing API is included in ownCloud 5.0.13 and greater versions. The -info needed is activeUser.url, the server URL that you want to check. - -=== Code Example - -[source,objective-c] ----- -[[ AppDelegate sharedOCCommunication ] hasServerShareSupport :_activeUser.url onCommunication :[ AppDelegate sharedOCCommunication ] - - successRequest :^( NSHTTPURLResponse *response, BOOL hasSupport, NSString *redirectedServer) { - } - failureRequest :^( NSHTTPURLResponse *response, NSError *error){ - } -}]; ----- - -== Read shared all items by link - -Get information about what files and folder are shared by link. - -The info needed is Path, the server URL that you want to check. - -=== Code example - -[source,objective-c] ----- -[[ AppDelegate sharedOCCommunication ] readSharedByServer :path onCommunication :[ AppDelegate sharedOCCommunication ] - -successRequest :^( NSHTTPURLResponse *response, NSArray *items, NSString *redirectedServer) { - NSLog ( @"Item: %d" , items); -} - -failureRequest :^( NSHTTPURLResponse *response, NSError *error){ - NSLog ( @"error: %@" , error); - NSLog ( @"Operation error: %d" , response.statusCode); -}]; ----- - -== Read shared items by link of a path - -Get information about what files and folder are shared by link in a -specific path. - -The info needed is the server URL that you want to check and the -specific path tha you want to check. - -=== Code example - -[source,objective-c] ----- -[[AppDelegate sharedOCCommunication] readSharedByServer:serverPath andPath:path onCommunication:[AppDelegate sharedOCCommunication] successRequest:^(NSHTTPURLResponse *response, NSArray *items, NSString *redirectedServer) { - NSLog ( @"Item: %d" , items); - - - } failureRequest:^(NSHTTPURLResponse *response, NSError *error) { - NSLog ( @"error: %@" , error); - NSLog ( @"Operation error: %d" , response.statusCode); -}]; ----- - -== Share link of file or folder - -Share a file or a folder from your cloud server by link. The info needed -is Path, your server URL and the path of the item that you want to share -(for example `/folder/file.pdf`) - -=== Code example - ----- -[[ AppDelegate sharedOCCommunication ] shareFileOrFolderByServer :path andFileOrFolderPath :itemPath onCommunication :[ AppDelegate sharedOCCommunication ] -successRequest :^( NSHTTPURLResponse *response, NSString *token, NSString *redirectedServer) { - -NSString *sharedLink = [ NSString stringWithFormat:@ `path/public.php?service=files&t=%@ `_ -, token]; - -} -failureRequest :^( NSHTTPURLResponse *response, NSError *error){ - [ _delegate endLoading ]; - -DLog ( @”error.code: %d” , error. code); -DLog (@”server.error: %d”, response. statusCode); -int code = response. statusCode ; -if (error.code == kOCErrorServerPathNotFound) { -} - -switch (code) { -case kOCErrorServerPathNotFound: - //File to share not exists - break; -case kOCErrorServerUnauthorized: - //Error login - break; -case kOCErrorServerForbidden: - //Permission error - break; -case kOCErrorServerTimeout: - //Not possible to connect to server - break; -default: -if (error.code == kOCErrorServerPathNotFound) { - //File to share not exists -} else { - //Not possible to connect to the server -} -break; - -} - -}]; - -} - -NSLog ( @"error: %@" , error); -NSLog ( @"Operation error: %d" , response.statusCode); -}]; ----- - -== Unshare a folder or file by link - -Stop sharing by link a file or a folder from your cloud server. - -The info needed is Path, your server URL and the Id of the item that you -want to Unshare. - -Before unsharing an item, you have to read the shared items on the -selected server, using the method “ readSharedByServer ” so that you get -the array `items` with all the shared elements. These are objects -OCShareDto, one of their properties is idRemoteShared, parameter needed -to unshared an element. - -=== Code example - -[source,objective-c] ----- -[[ AppDelegate sharedOCCommunication ] unShareFileOrFolderByServer :path andIdRemoteSharedShared :sharedByLink. idRemoteShared onCommunication :[ AppDelegate sharedOCCommunication ] - - successRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer) { - //File unshared - } - failureRequest :^( NSHTTPURLResponse *response, NSError *error){ - //Error - } -]; ----- - -== Check if file of folder is shared - -Check if a specific file or folder is shared in your cloud server. - -Teh info need is Path, your server URL and the Id of the item that you -want. - -Before check an item, you have to read the shared items on the selected -server, using the method “ readSharedByServer ” so that you get the -array `items` with all the shared elements. These are objects -OCShareDto, one of their properties is idRemoteShared, parameter needed -to unshared an element. - -=== Code example - -[source,objective-c] ----- -[[AppDelegate sharedOCCommunication] isShareFileOrFolderByServer:path andIdRemoteShared:_shareDto.idRemoteShared onCommunication:[AppDelegate sharedOCCommunication] successRequest:^(NSHTTPURLResponse *response, NSString *redirectedServer, BOOL isShared) { - //File/Folder is shared - - } failureRequest:^(NSHTTPURLResponse *response, NSError *error) { - //File/Folder is not shared -}]; ----- - -== Tips - -* Credentials must be set before calling any method -* Paths must not be on URL Encoding -* Correct path: `\https://example.com/owncloud/remote.php/dav/Pop_Music/` -* Wrong path: `\https://example.com/owncloud/remote.php/dav/Pop%20Music/` -* There are some forbidden characters to be used in folder and files names on the server, same on the ownCloud iOS library -`/`,`<`,`>`,`:`,`"`,`\``,`?`,`*` -* To move a folder the origin path and the destination path must end with `/` -* To move a file the origin path and the destination path must not end with `/` -* Upload and download actions may be cancelled thanks to the object `NSOperation` -* Unit tests, before launching unit tests you have to enter your account information (server url, user and password) on `OCCommunicationLibTests.m` diff --git a/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/index.adoc b/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/index.adoc deleted file mode 100644 index 8e5bee7..0000000 --- a/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/index.adoc +++ /dev/null @@ -1,34 +0,0 @@ -= iOS Application Development - -ownCloud provides an official ownCloud iOS client, which gives its users -access to their files on their ownCloud. It also includes functionality -like automatically uploading pictures and videos to ownCloud. - -For third party application developers, ownCloud offers the ownCloud iOS -library under the MIT license. - -== iOS ownCloud Client development - -If you are interested in working on the ownCloud iOS client, you can -find the source code https://github.com/owncloud/ios[in github]. The -setup and process of contribution is -https://github.com/owncloud/ios/blob/master/SETUP.md[documented here]. - -You might want to start with doing one or two https://github.com/owncloud/ios/issues?q=is%3Aopen+is%3Aissue+label%3A%22Junior+Job%22[junior jobs] to get into the code and note our xref:general/codingguidelines.adoc[General Contributor Guidelines]. - -Note that contribution to the iOS client requires signing the iOS addendum to the https://owncloud.com/contribute/join-the-development/contributor-agreement/[ownCloud Contributor Agreement]. -You are permitted to test the iOS client on Apple hardware thanks to the https://owncloud.com/contribute/join-the-development/contributor-agreement/owncloud-mobile-app-for-ios/[iOS license exception]. - -== ownCloud iOS Library - -This document will describe how to the use ownCloud iOS library. The -ownCloud iOS library for iOS allows a developer to communicate with any -ownCloud server; among the features included are file synchronization, -upload and download of files, delete rename and move of files and -folders and share files or folders by link among others. - -This library may be added to a project and seamlessly integrates any -application with ownCloud. - -The tool needed is Xcode 6, this guide includes some screenshots showing -examples in Xcode 6. diff --git a/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/library_installation.adoc b/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/library_installation.adoc deleted file mode 100644 index cbbe60f..0000000 --- a/content/server/10.15/modules/developer_manual/pages/mobile_development/ios_library/library_installation.adoc +++ /dev/null @@ -1,102 +0,0 @@ -= Library Installation - -== Obtaining the library - -The ownCloud iOS library may be obtained from the following Github -repository: - -link:https://github.com/owncloud/ios-library[owncloud/ios-library] - -Once obtained, this code should be compiled with Xcode 6. The Github -repository not only contains the library, ownCloud iOS library, but also -contains a sample project, OCLibraryExample, which will assist in -learning how to use the library. - -== Add the library to a project - -There are two methods to add this library to a project. - -* Reference the headers and library binary file (`.a`) directly. -* Include the library as a subproject. - -Which method to choose depends on user preference as well as whether the -source code and project file of the static library are available. - -=== Reference headers and library binary files - -Follow these steps if this is the desired method. - -1. Compile the ownCloud iOS library and run the project. A `libownCloudiOS.a` file will be generated. - -The following files are required: - -*Library file* - -* `libownCloudiOS.a` (Library) - -*Library Classes* - -* `OCCommunication.h` (Accessors) Import in the communication class -* `OCErrorMsg.h` (Error Messages) Import in the communication class -* `OCFileDto.h` and `OCFileDto.m` (File/Folder object) Import when using -* `readFolder` and `readFile` methods -* `OCFrameworkConstants.h` (Customize constants) - -[start=2] -. Add the library file to the project. From the `Build Phases` tab, scroll to `Link binary files` and select the `+` to add a library. -Select the library file. - -image:mobile_development/ios_library/10000201000003480000020EC688993D.png[10000201000003480000020EC688993D_png] - -[start=3] -. Add the path of the library header files. Under the `Build -Settings` tab, select the target library and add the path in the -`Header Search Paths` field. - -image:mobile_development/ios_library/10000201000003430000020C65A3C5A7.png[10000201000003430000020C65A3C5A7_png] - -[start=4] -. Remaining in the `Build Setting` tab, add the flag `-Obj-C` under the `Other Linker Flags` option. - -image:mobile_development/ios_library/100002010000034700000211B6BE4A2B.png[100002010000034700000211B6BE4A2B_png] - -At this stage, the library is included on your project and you can start -communicating with the ownCloud server. - -=== Include the library as a subproject - -Follow these steps if this is the desired method. - -[start=5] -. Add the file `ownCloud iOS library.xcodeproj` to the project via drag and drop. - -image:mobile_development/ios_library/100000000000030C000001E61DFDBF76.png[100000000000030C000001E61DFDBF76_png] - -[start=6] -. Within the project, navigate to the `Build Phases` tab. Under the -`Target Dependencies` section, select the `+' and choose the library target. - -image:mobile_development/ios_library/100000000000030C000001E7A7A01884.png[100000000000030C000001E7A7A01884_png] - -[start=7] -. Link the library file to the project target. Under the `Build -Phases` tab, select the `+' under the `Link Binary with Libraries` section and select the library file. - -image:mobile_development/ios_library/100000000000030C000001E8AB4C3306.png[100000000000030C000001E8AB4C3306_png] - -[start=8] -. Add the flag `-Obj-C` to `Other Linker Flags` under the project target on the `Build Settings` tab. - -image:mobile_development/ios_library/100000000000030C000001ECB85120C2.png[100000000000030C000001ECB85120C2_png] - -[start=9] -. Finally add the path of the library headers. Under the `Build -Settings` tab, add the path under the `Header Search Paths` option. - -image:mobile_development/ios_library/100000000000030C000001E637605044.png[100000000000030C000001E637605044_png] - -== Sources - -* https://www.raywenderlich.com/2658-creating-a-static-library-in-ios-tutorial[Creating a static library in iOS tutorial (raywenderlich.com)] -* https://www.technetexperts.com/mobile/creating-static-library-in-ios-app-development/[Creating Static Library in iOS App Development] - diff --git a/content/server/10.15/modules/developer_manual/pages/scripts/theme-bootstrap.sh b/content/server/10.15/modules/developer_manual/pages/scripts/theme-bootstrap.sh deleted file mode 100755 index 6143204..0000000 --- a/content/server/10.15/modules/developer_manual/pages/scripts/theme-bootstrap.sh +++ /dev/null @@ -1,57 +0,0 @@ -#!/bin/bash -# theme-bootstrap.sh -# Invoke this script with one argument, the new theme's name. -# Written by Dmitry Mayorov & Matthew Setter -# Copyright (c) ownCloud 2018. -set -e - -E_BADARGS=85 - -if (( $# != 2 )) -then - echo "Not enough arguments supplied." - echo "Usage: $( basename "$0" ) [-v] [-h] [theme id] [owncloud directory]" - exit $E_BADARGS -fi - -app_name="$1" -owncloud_directory="$2" -apps="$owncloud_directory/apps" - -OLDPWD=${OLDPWD:=$(pwd)} - -echo "Bootstrapping theme development." - -cd "$owncloud_directory" - -# Copy the example theme to your theme -echo -echo "Copying default theme" -cp -r "$apps/theme-example" "$apps/$app_name" - -# Remove the default signature, which will cause a code integrity violation -if [ -f "$apps/$app_name/appinfo/signature.json" ]; then - echo - echo "Removing default signature.json file to avoid code integrity violation" - rm "$apps/$app_name/appinfo/signature.json" -fi - -# Replace the default id -echo -echo "Updating theme id" -sed -i "s#theme-example<#$app_name<#" "$apps/$app_name/appinfo/info.xml" - -# Set the appropriate permissions -echo -echo "Setting theme file permissions" -chown -R www-data:www-data "$apps/$app_name" - -# Enable the theme (app) -echo -echo "Enabling theme" -sudo -u www-data "$owncloud_directory/occ" app:enable "$app_name" - -echo -echo "Finished bootstrapping the new theme." - -cd "$OLDPWD" diff --git a/content/server/10.15/modules/developer_manual/pages/testing/acceptance-tests.adoc b/content/server/10.15/modules/developer_manual/pages/testing/acceptance-tests.adoc deleted file mode 100644 index b009d06..0000000 --- a/content/server/10.15/modules/developer_manual/pages/testing/acceptance-tests.adoc +++ /dev/null @@ -1,1154 +0,0 @@ -= Acceptance Tests -:toc: right -:toclevels: 1 -:behat-tags-docs-url: https://behat.org/en/latest/user_guide/organizing.html#tags -:page-aliases: core/acceptance-tests.adoc - -== The Test Directory Structure - -This is the structure of the acceptance directory inside https://github.com/owncloud/core[the core repository's] `tests` directory: - -[source,bash] ----- -tests -├── acceptance -│ ├── config -│ │ └── behat.yml -│ ├── features -│ │ ├── apiTags (example suite of API tests) -│ │ │ └── feature files (behat gherkin files) -│ │ ├── bootstrap -│ │ │ └── Contexts and traits (php files) -│ │ ├── cliProvisioning (example suite of CLI tests) -│ │ │ └── feature files (behat gherkin files) -│ │ ├── lib -│ │ │ └── Page objects for webUI tests (php files) -│ │ └── webUILogin (example suite of webUI tests) -│ │ └── feature files (behat gherkin files) -│ ├── filesForUpload -│ └── run.sh ----- - -Here's a short description of each component of the directory. - -=== `config/` - -This directory contains `behat.yml` which sets up the acceptance tests. -In this file we can add new suites and define the contexts needed by each suite. -Here's an example configuration: - -[source,yaml,subs="attributes+"] ----- -default: - autoload: - '': '%paths.base%/../features/bootstrap' - suites: - apiMain: - paths: - - '%paths.base%/../features/apiMain' - contexts: - - FeatureContext: &common_feature_context_params - baseUrl: http://localhost:{std-port-http} - adminUsername: admin - adminPassword: admin - regularUserPassword: 123456 - ocPath: apps/testing/api/v1/occ - - AppManagementContext: - - CalDavContext: - - CardDavContext: - - apiCapabilities: - paths: - - '%paths.base%/../features/apiCapabilities' - contexts: - - FeatureContext: *common_feature_context_params - - CapabilitiesContext: ----- - -=== `features/` - -This directory contains sub-directories for each of the test suites. - -=== `features/suiteName` - -This directory stores http://behat.org/en/latest/guides.html[Behat's feature files] for the test suite. -These contain Behat's test cases, called scenarios, which use the Gherkin language. - -=== `feature/bootstrap` - -This folder contains all the Behat contexts. -Contexts contain the PHP code required to run Behat's scenarios. -Every suite has to have one or more contexts associated with it. -The contexts define the test steps used by the scenarios in the feature files of the test suite. - -=== `filesForUpload/` - -This folder contains convenience files that tests can use to upload. - -=== `run.sh` - -This script runs the test suites. -It is called by the `make` commands that are used to run acceptance tests. - -== The Testing App - -The testing app provides an API that allows the acceptance tests to set up the environment of the system-under-test. -For example, running `occ` commands to set system and app config settings. -The testing app must be installed and enabled on the system-under-test. - -The testing app also provides skeleton folders that the tests can use as the default set of files for new users. - -=== `apps/testing/data/tinySkeleton/` - -This folder stores just a single file. -This is useful when wanting to test with a skeleton and there is no need for more than one file. - -=== `apps/testing/data/smallSkeleton/` - -This folder stores a small set of initial files to be loaded for a new user. - -=== `apps/testing/data/largeSkeleton/` - -This folder stores a larger set of initial files to be loaded for a new user. -These can be convenient when a longer list of files is needed, e.g., in a UI test that scrolls a file list. - -== Running Acceptance Tests - -=== Preparing to Run Acceptance Tests - -This is a concise guide to running acceptance tests on ownCloud Classic. -Before you can do so, you need to meet a few prerequisites available; these are - -* ownCloud -* Composer -* MySQL - -In `php.ini` on your system, set `opcache.revalidate_freq=0` so that changes made to ownCloud `config.php` by test scenarios are -implemented immediately. - -After cloning core, run `make` as your webserver's user in the root directory of the project. - -Now that the prerequisites are satisfied, and assuming that `$installation_path` is the location where you cloned the `ownCloud/core` repository, the following commands will prepare the installation for running the acceptance tests. - -[source,bash,subs="attributes+"] ----- -# Remove current configuration (if existing) -sudo rm -rf $installation_path/data/* -sudo rm -rf $installation_path/config/* - -# Remove existing 'owncloud' database -mysql -u root -h localhost -e "drop database owncloud" -mysql -u root -h localhost -e "drop user oc_admin" -mysql -u root -h localhost -e "drop user oc_admin@localhost" - -# Install ownCloud server with the command-line -{occ-command-example-prefix} maintenance:install \ - --database='mysql' --database-name='owncloud' --database-user='root' \ - --database-pass='mysqlrootpassword' --admin-user='admin' --admin-pass='admin' ----- - -=== Types of Acceptance Tests - -There are 3 types of acceptance tests; API, CLI and webUI. - -- API tests test the ownCloud public APIs. -- CLI tests test the `occ` command-line commands. -- webUI tests test the browser-based user interface. - -webUI tests require an additional environment to be set up. -See xref:developer_manual:testing/ui-testing.adoc[the UI testing documentation] for more information. -API and CLI tests are run by using the `test-acceptance-api` and `test-acceptance-cli` make commands. - -=== Test Server Environments -In order to run acceptance tests, server urls should be specified through environment variables. -[cols="20,20,80",options="header"] -|=== -|Environment Variable -|Default -|Description - -|`TEST_SERVER_URL` -| \http://localhost:8080 -|OC server url to be used in tests. - -|`TEST_SERVER_FED_URL` -| \http://localhost:8180 -|OC federated server url to be used in tests. -|=== - -=== Running Acceptance Tests for a Suite - -Run a command like the following: - -[source,bash] ----- -make test-acceptance-api BEHAT_SUITE=apiTags -make test-acceptance-cli BEHAT_SUITE=cliProvisioning ----- - -=== Running Acceptance Tests for a Feature - -Run a command like the following: - -[source,bash] ----- -make test-acceptance-api BEHAT_FEATURE=tests/acceptance/features/apiTags/createTags.feature -make test-acceptance-cli BEHAT_FEATURE=tests/acceptance/features/cliProvisioning/addUser.feature ----- - -=== Running Acceptance Tests for a Tag - -Some test scenarios are tagged. -For example, tests that are known to fail and are awaiting fixes are tagged `@skip`. -To run test scenarios with a particular tag: - -[source,bash] ----- -make test-acceptance-api BEHAT_SUITE=apiTags BEHAT_FILTER_TAGS=@skip -make test-acceptance-cli BEHAT_SUITE=cliProvisioning BEHAT_FILTER_TAGS=@skip ----- - -=== Running Acceptance Tests for different User Names and User Attributes - -The user names and user attributes in test scenarios can be replaced at run-time. -This allows running the acceptance test suites with different unusual user names, display names, -email addresses and passwords. This can be useful for finding values that cause problems. - -The replacement values are defined in `tests/acceptance/usernames.json`. Edit that file -and specify the values to be used at run time. For example: - -[source,bash] ----- -{ - "Alice": { - "username": "000", - "displayname": "0.0", - "email": "zero@example.org", - "password": "0123" - }, - "Brian": { - "username": "1.1", - "displayname": "नेपाली name", - "email": "nepal@example.org", - "password": "नेपाल" - }, - "Carol": { - "username": "12E3", - "displayname": "12 thousand", - "email": "twelve-thousand@example.org", - "password": "random12000" - }, - "David": { - "username": "123@someone", - "displayname": "321@nobody", - "email": "someone@example.org", - "password": "some123one" - }, - "Emily": { - "username": "e+f", - "displayname": "a+b-c*d", - "email": "emily+fred@example.org", - "password": "notsorandom" - } -} ----- - -If you are running tests locally, define the environment variable `REPLACE_USERNAMES` to be true: - -[source,bash] ----- -export REPLACE_USERNAMES=true ----- - -You can also run the acceptance tests in CI with the replaced user attributes. This is useful if you want to -run many acceptance tests with an unusual combination of usernames, display names, email addresses and -passwords without taking up many hours on a local machine. _A PR is necessary for testing but is not to be merged_, -it is just a way to get test results. In the `acceptance` section of `.drone.star` switch on the `replaceUsernames` setting. -Commit the changes to `.drone.star` and `tests/acceptance/usernames.json`, push to GitHub, and make a _draft_ PR: - -**Example Changes** -[source,bash] ----- -'acceptance': { - 'api': { - 'suites': [ - 'apiAuth', - 'apiAuthOcs', - 'apiAuthWebDav', - # and so on... - ], - 'replaceUsernames': True, - }, -}, ----- - -When the acceptance tests are run, the user names and attributes will be replaced. -When you are finished running the tests, remember to close the PR and leave a comment -describing the outcome of your testing. - -=== Running Acceptance Tests Using Part System -The part system allows us to divide the test run without knowing how many or which suites are available. Filter tags can also be used to run targeted scenarios after divisions. Multiple test suites are grouped together in each part. For example, if there are 26 test suites to be grouped into 10 parts then 2 or 3 test suites will be run in each part. This functionality is most useful in CI. The CI can split the test suites into as many pipelines as is appropriate without needing to know the actual names of the test suites. - -The following two methods can be used to achieve this: - -**1. Environment Variables** - -[cols="20,80",options="header"] -|=== -|Environment Variable -|Description - -|`DIVIDE_INTO_NUM_PARTS` -|The number of parts the test suite will be divided into - -|`RUN_PART` -|The part-number to test -|=== - -Execute the tests by setting the above environment variables and running the usual make command. -[source,bash] ----- -RUN_PART=1 DIVIDE_INTO_NUM_PARTS=5 make test-acceptance-api ----- - -**2. part argument** - -If `run.sh` is used directly to run acceptance tests, the part system can be achieved using the `--part` flag. The script below divides the test suite into five parts and runs just the first one. - -[source,bash] ----- -./run.sh --part 1 5 ----- - -With this method, it is also possible to use environment variables. - -[source,bash] ----- -RUN_PART=1 DIVIDE_INTO_NUM_PARTS=5 ./run.sh ----- - -=== Displaying the ownCloud Log - -It can be useful to see the tail of the ownCloud log when the test run ends. -To do that, specify `SHOW_OC_LOGS=true`: - -[source,bash] ----- -make test-acceptance-api BEHAT_SUITE=apiTags SHOW_OC_LOGS=true ----- - -=== Step Through Each Step of a Scenario - -When doing test development, or investigating problems with a test or with the system-under-test, -it is useful to be able to stop the test at each step while investigating what happens. -Setting `STEP_THROUGH=true` will cause the test runner to pause after each step. -Press enter to resume the test and execute the next test step. - -[source,bash] ----- -make test-acceptance-api STEP_THROUGH=true BEHAT_FEATURE=tests/acceptance/features/apiComments/createComments.feature:35 -... - Scenario: sharee comments on a group shared file - Given group "grp1" has been created - [Paused after "group "grp1" has been created" - press enter to continue] - And user "Brian" has been added to group "grp1" - [Paused after "user "Brian" has been added to group "grp1"" - press enter to continue] - And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/myFileToComment.txt" - [Paused after "user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/myFileToComment.txt"" - press enter to continue] -... ----- - -=== Get Detailed Information About API Requests - -If you set any of these environment variables, then the test runner will display information about the details of each request to and response from the API. -This generates a large amount of output, but can be useful to understand exactly what a test is doing and why it fails. - -[cols="20,80",options="header"] -|=== -|Environment Variable -|Description -|`DEBUG_ACCEPTANCE_REQUESTS` -|Output the details of each API request. -|`DEBUG_ACCEPTANCE_RESPONSES` -|Output the details of each API response. -|`DEBUG_ACCEPTANCE_API_CALLS` -|Output the details of each API request and response. -|=== - -[source,bash] ----- -make test-acceptance-api DEBUG_ACCEPTANCE_API_CALLS=true BEHAT_SUITE=apiTags ----- - -=== Optional Environment Variables - -If you define `SEND_SCENARIO_LINE_REFERENCES` then the API tests will send an extra `X-Request-Id` header in each request -to the API. The value sent is a string that indicates the test suite, feature, scenario and line number of the step. -For example, `apiComments/editComments.feature:26-28` indicates the apiComments test suite, editComments feature, -the scenario at line 26 and the test step at line 28. A system-under-test could write that string into log entries, -or report in a way that makes it easier to correlate the test runner API requests with the events in the system-under-test. - -[source,bash] ----- -make test-acceptance-api BEHAT_SUITE=apiTags SEND_SCENARIO_LINE_REFERENCES=true ----- - -If you want to use an alternative home name using the `env` variable add to the execution `OC_TEST_ALT_HOME=1`, as in the following example: - -[source,bash] ----- -make test-acceptance-api BEHAT_SUITE=apiTags OC_TEST_ALT_HOME=1 ----- - -If you want to have encryption enabled add `OC_TEST_ENCRYPTION_ENABLED=1`, as in the following example: - -[source,bash] ----- -make test-acceptance-api BEHAT_SUITE=apiTags OC_TEST_ENCRYPTION_ENABLED=1 ----- - -== How to Write Acceptance Tests - -Each acceptance test is a scenario in a feature file in a test suite. - -=== Feature Files - -Each feature file describes and tests a particular feature of the software. -The feature file starts with the `Feature:` keyword, a sentence describing the feature. -This is followed by more detail explaining who uses the feature and why, in the format: - -[source,gherkin] ----- - As a [role] - I want [feature] - So that [benefit] ----- - -For example: - -[source,gherkin] ----- -Feature: upload file using the WebDav API - As a user - I want to be able to upload files - So that I can store and share files between multiple client systems ----- - -This detail is free-text and has no effect on the running of automated tests. - -The rest of a feature file contains the test scenarios. - -Make small feature files for individual features. -For example "the Provisioning API" is too big to be a single feature. -Split it into the functional things that it allows a client to do. For example: - -- `addGroup.feature` -- `addUser.feature` -- `addToGroup.feature` -- `deleteGroup.feature` -- `deleteUser.feature` -- `disableUser.feature` -- `editUser.feature` -- `enableUser.feature` -- `removeFromGroup.feature` - -=== Test Scenarios - -A feature file should have up to 10 or 20 scenarios that test the feature. -If you need more scenarios than that, then perhaps there really are multiple features and you should make multiple feature files. - -Each scenario starts with the `Scenario:` keyword followed by a description of the scenario. -Then the steps to execute for that scenario are listed. - -There are 3 types of test steps: - -- `Given` steps that get the system into the desired state to start the test (e.g., create users and groups, share some files) -- `When` steps that perform the action under test (e.g., upload a file to a share) -- `Then` steps that verify that the action was successful (e.g., check the HTTP status code, check that other users can access the uploaded file) - -A single scenario should test a single action or logical sequence of actions. -So the `Given`, `When` and `Then` steps should come in that order. - -If there are multiple `Given` or `When` steps, then steps after the first start with the keyword `And`. - -If there are multiple `Then` steps, then steps after the first start with the keyword `And` or `But`. - -==== Writing a Given Step - -`Given` steps are written in the https://www.ef.com/english-resources/english-grammar/present-perfect/[present-perfect tense]. -They specify things that "have been done". For example: - -[source,gherkin] ----- - Scenario: delete files in a sub-folder - Given user "Alice" has been created - And user "Alice" has moved file "/welcome.txt" to "/FOLDER/welcome.txt" - And user "Alice" has created a folder "/FOLDER/SUBFOLDER" - And user "Alice" has copied file "/textfile0.txt" to "/FOLDER/SUBFOLDER/testfile0.txt" ----- - -`Given` steps do not mention how the action is done. -They can mention the actor that performs the step, when that matters. -For example, creating a user must be done by something with enough admin privilege. -So there is no need to mention "the administrator". -But creating a file must be done in the context of some user. -So the user must be mentioned. - -The test code is free to achieve the desired system state however it likes. -For example, by using an available API, by running a suitable `occ` command on the system-under-test, or by doing it with the webUI. -Typically the test code for `Given` steps will use an API, because that is usually the most efficient. - -==== Writing a When Step - -`When` steps are written in the https://www.ef.com/english-resources/english-grammar/simple-present-tense/[simple present tense]. -They specify the action that is being tested. Continuing the example above: - -[source,gherkin] ----- - Scenario: delete all files in a sub-folder - Given user "Alice" has been created - And user "Alice" has moved file "/welcome.txt" to "/FOLDER/welcome.txt" - And user "Alice" has created a folder "/FOLDER/SUBFOLDER" - And user "Alice" has copied file "/textfile0.txt" to "/FOLDER/SUBFOLDER/testfile0.txt" - When user "Alice" deletes everything from folder "/FOLDER/" using the WebDAV API ----- - -In ownCloud there are usually 2 or 3 interfaces that can implement an action. -For example, a user can be created using an `occ` command, the Provisioning API or the webUI. -Files can be managed using the WebDAV API or the webUI. -File shares can be managed using the Sharing API or the webUI. -So `When` steps should end with a phrase specifying the interface to be tested, such as: - -- `using the occ command` -- `using the Sharing API` -- `using the Provisioning API` -- `using the WebDAV API` -- `using the webUI` - -If a `When` step takes an action that is not expected to succeed, then the step can use the phrase "tries to". -This makes it clear to the reader that the action is not expected to succeed in the normal way. -It also allows the test code to act differently when handling the step. For example, it could ignore the fact that some -element that is usually on the UI is missing, or it can understand that some different UI page will be displayed next. - -[source,gherkin] ----- - Scenario: admin login with invalid password - Given the user has browsed to the login page - When the administrator tries to login with an invalid password "wrongPassword" using the webUI - ... ----- - -Write `When` steps that state what the user wants to achieve. This helps the test to remain focused on the business -need rather than the implementation detail. - -Sometimes there is a workflow on the UI that takes a few UI actions to achieve the result. For example, when the -user moves or copies a file they go through a few actions. Normally write a single `When` step. But sometimes there -are points in the workflow where the user has the option to take a different path. For example, there is a cancel -button available at each step of the workflow. In order to test the cancel button, write smaller `When` steps to -describe exactly how the user progresses through the workflow. - -[source,gherkin] ----- - Scenario: cancel copying a file - Given user "Alice" has logged in using the webUI - And the user has browsed to the files page - When the user opens the file action menu of folder "data.zip" using the webUI - And the user selects the copy action for folder "data.zip" using the webUI - And the user selects the folder "simple-empty-folder" as a place to copy the file using the webUI - And the user cancels the attempt to copy the file into folder "simple-empty-folder" using the webUI - Then file "data.zip" should be listed on the webUI - But file "data.zip" should not be listed in the folder "simple-empty-folder" on the webUI ----- - -==== Writing a Then Step - -`Then` steps describe what should be the case if the `When` step(s) happened successfully. -They should contain the word `should` somewhere in the step text. - -[source,gherkin] ----- - Scenario: delete all files in a sub-folder - Given user "Alice" has been created - And user "Alice" has moved file "/welcome.txt" to "/FOLDER/welcome.txt" - And user "Alice" has created a folder "/FOLDER/SUBFOLDER" - And user "Alice" has copied file "/textfile0.txt" to "/FOLDER/SUBFOLDER/testfile0.txt" - When user "Alice" deletes everything from folder "/FOLDER/" using the WebDAV API - Then user "Alice" should see the following elements - | /FOLDER/ | - | /PARENT/ | - | /PARENT/parent.txt | - | /textfile0.txt | - | /textfile1.txt | - | /textfile2.txt | - | /textfile3.txt | - | /textfile4.txt | - But user "Alice" should not see the following elements - | /FOLDER/SUBFOLDER/ | - | /FOLDER/welcome.txt | - | /FOLDER/SUBFOLDER/testfile0.txt | ----- - -Note that there are often multiple things that `should` or `should not` be the case after the `When` action. -For example, in the above scenario, various files and folders (that are part of the skeleton) should still be there. -But other files and folders under `FOLDER` should have been deleted. - -Where it makes the scenario read more easily, use the `But` as well as `And` keywords in the `Then` section. - -`Then` steps should test an appropriate range of evidence that the `When` action did happen. -For example: - -[source,gherkin] ----- - Scenario: admin creates a user - Given user "brand-new-user" has been deleted - When the administrator sends a user creation request for user "brand-new-user" password "%alt1%" using the provisioning API - Then the OCS status code should be "100" - And the HTTP status code should be "200" - And user "brand-new-user" should exist - And user "brand-new-user" should be able to access a skeleton file ----- - -In this scenario we check that the OCS and HTTP status codes of the API request are good. -But it is possible that the server lies, and returns HTTP status 200 for every request, even if the server did not create the user. -So we check that the user exists. -However maybe the user exists according to some API that can query for valid user names/ids, -but the user account is not really valid and working. -So we also check that the user can do something, in this case that they can access one of their skeleton files. - -==== Specifying the Actor - -Test steps often need to specify the actor that does the action or check. -For example, the user. - -Use realistic user names, display names and email addresses when writing scenarios. -This helps real humans to more easily understand scenarios. -There are five user names that are typically used in the test scenarios. -Use those usernames unless there is some special reason not to. -That helps to be able to automatically replace user names and run all the test scenarios with different unusual user names. -The acceptance test code has defaults for the display name and email address of these "known" users. -So you can just create these users in `Given` steps and they get the corresponding display name and email address. - -[cols="20,20,20,40",options="header"] -|=== -|User Name -|Display Name -|Email Address -|Description -|Alice -|Alice Hansen -|alice@example.org -|The primary actor in a scenario, e.g. the one doing the sharing -|Brian -|Brian Murphy -|brian@example.org -|The second actor, e.g., the one receiving a share -|Carol -|Carol King -|carol@example.org -|The third actor, e.g., might be a member of a group -|David -|David Lopez -|david@example.org -|Another actor, when needed -|Emily -|Emily Wagner -|emily@example.org -|Another actor, when needed -|=== - - -The acceptance test code can remember the "current" user with a step like: - -[source,gherkin] ----- - Given as user "Alice" - And the user has uploaded file "abc.txt" - When the user deletes file "abc.txt" - ... ----- - -So that later steps can just mention `the user`. - -Or you can mention the user in each step: - -[source,gherkin] ----- - Given user "Alice" has uploaded file "abc.txt" - When user "Alice" deletes file "abc.txt" - ... ----- - -Either form is acceptable. Longer tests with a single user read well with the first form. -Shorter tests, or sharing tests that mix actions of multiple users, read well with the second form. - -When the actor is the administrator (a special user with privileges) then use `the administrator` in the step text. -Do not write `When user "admin" does something`. -The user name of the user with administrator privilege on the system-under-test might not be `admin`. -The user name of the administrator needs to be determined at run-time, not hard-coded in the scenario. - -==== Referring to Named Entities - -When referring to specific named entities on the system, such as a user, group, file, folder or tag, -then do not put the word `the` in front, but do put the name of the entity. For example: - -[source,gherkin] ----- - Given user "Alice" has been added to group "grp1" - And user "Alice" has uploaded file "abc.txt" into folder "folder1" - And user "Alice" has added tag "aTag" to file "folder1/abc.txt" - When user "Alice" shares folder "folder1" with user "Brian" - ... ----- - -This makes it clearer to understand which entity is required in which position of the sentence. -For example: - -[source,gherkin] ----- - And "Alice" has uploaded "abc.txt" into "folder1" - ... ----- - -would be less clear that the required entities for this step are a user, file and folder. - -=== Scenario Background - -If all the scenarios in a feature start with a common set of `Given` steps, -then put them into a `Background:` section. For example: - -[source,gherkin] ----- - Background: - Given user "Alice" has been created - And user "Brian" has been created - And user "Alice" has uploaded file "abc.txt" - - Scenario: share a file with another user - When user "Alice" shares file "abc.txt" with user "Brian" using the sharing API - Then the HTTP status code should be "200" - And user "Brian" should be able to download file "abc.txt" - - Scenario: share a file with a group - Given group "grp1" has been created - And "Brian" has been added to group "grp1" - When user "Alice" shares file "abc.txt" with user "Brian" using the sharing API - Then the HTTP status code should be "200" - And user "Brian" should be able to download file "abc.txt" ----- - -This reduces some duplication in feature files. - -== Controlling Running Test Scenarios In Different Environments - -A feature or test scenario might only be relevant to run on a system-under-test that has a particular environment. -For example, a particular app enabled. - -To allow the test runner script to run the features and scenarios relevant to the system-under-test the feature file or individual scenarios are tagged. -The test runner script can then filter by tags to select the relevant features or scenarios. - -TIP: For general information on tagging features and scenarios see {behat-tags-docs-url}[the Behat tags documentation]. - -=== Tagging Features By API, CLI and webUI - -Tag every feature with its major acceptance test type `api`, `cli` or `webUI`, as in the following examples. -Doing so allows the tests of a particular major type to be quickly run or skipped. - -==== `@api` - -[source,gherkin] ----- -@api -Feature: add groups - As an admin - I want to be able to add groups - So that I can more easily manage access to resources by groups rather than individual users ----- - -==== `@cli` - -[source,gherkin] ----- -@cli -Feature: add group - As an admin - I want to be able to add groups - So that I can more easily manage access to resources by groups rather than individual users ----- - -==== `@webUI` - -[source,gherkin] ----- -@webUI -Feature: login users - As a user - I want to be able to log into my account - So that I have access to my files ----- - - -=== Tagging Scenarios That Require An App - -When a feature or scenario requires a core app to be enabled then tag it like: - -[source,gherkin] ----- -@comments-app-required -@federation-app-required -@files_trashbin-app-required -@files_versions-app-required -@notifications-app-required -@provisioning-app-required -@systemtags-app-required ----- - -The above apps might be disabled on a system-under-test. -Tagging the feature or scenario allows all tests for the app to be quickly run or skipped. - -For tests in an app repository, do not tag them with the app name (e.g., `files_texteditor-app-required`). -It is already a given that the app in the repository is required for running the tests! - -=== Tagging Scenarios That Need to Be Skipped - -==== Skip UI Tests On A Particular Browser - -Some browsers have difficulty with some automated test actions. -To skip scenarios for a browser tag them with the relevant tags: - -[source,gherkin] ----- -@skipOnCHROME -@skipOnFIREFOX -@skipOnINTERNETEXPLORER -@skipOnMICROSOFTEDGE ----- - -==== Skip Tests On A Particular Version Of ownCloud - -The acceptance test suite is sometimes run against a system-under-test that has an older version of ownCloud. -When writing new test scenarios for a new or changed feature, tag them to be skipped on the previous recent release of ownCloud. -Use tag formats like the following to skip on a particular major, minor or patch version. - -[source,gherkin] ----- -@skipOnOcV10 -@skipOnOcV10.4 -@skipOnOcV10.5.0 ----- - -The acceptance test suite has scenarios that test federated sharing. -Those scenarios are run against federated servers running older versions of ownCloud, to ensure that federated sharing can work between different server versions. -When writing scenarios for new or fixed federated features that are not expected to work with older versions, then skip those scenarios using tags like: - -[source,gherkin] ----- -@skipOnFedOcV10 -@skipOnFedOcV10.4 -@skipOnFedOcV10.5.0 ----- - -If there are significant changes for a new release and many test scenarios have to be modified and skipped on older ownCloud versions -then the old scenarios can be left in the feature files for when the test suite is used against an older version of ownCloud. -Tag the older scenarios like the following. Add logic to `tests/acceptance/run.sh` when you need to add new tags for -newer versions. - -[source,gherkin] ----- -@skipOnAllVersionsGreaterThanOcV10.8.0 ----- - -==== Skip Tests In Other Environments - -[cols="20,80",options="header"] -|=== -|Annotation -|Description -|`@skipOnDockerContainerTesting` -|skip the scenario if the test is running against the ownCloud docker container. Some settings are preset in the docker container and the tests cannot change those, so the related test scenarios must be skipped. -|`@skipOnLDAP` -|skip the scenario if the test is running with the LDAP backend. For example, some user provisioning features may not be relevant when LDAP is the backend for authentication. -|`@skipOnStorage:ceph` -|skip the scenario if the test is running with `ceph` backend storage. -|`@skipOnStorage:scality` -|skip the scenario if the test is running with `scality` backend storage. -|`@skipOnEncryption` -|skip the scenario if the test is running with encryption enabled. -|`@skipOnEncryptionType:masterkey` -|skip the scenario if the test is running with `masterkey` encryption enabled. -|`@skipOnEncryptionType:user-keys` -|skip the scenario if the test is running with `user-keys` encryption enabled. -|`@notToImplementOnOCIS` -|the scenario is not relevant on an OCIS system. OCIS CI and developers can skip these scenarios. -|=== - -=== Tags For Tests To Run In Special Environments - -[cols="25,75",options="header"] -|=== -|Annotation -|Description -|`@smokeTest` -|this scenario has been selected as part of a base set of smoke tests. -|`@TestAlsoOnExternalUserBackend` -|this scenario is selected as part of a base set of tests to run when a special user backend is in place (e.g., LDAP). -|`@local_storage` -|this scenario requires and tests the local storage feature. -|`@mailhog` -|this scenario requires an email server running -|=== - -=== Special Tags for UI Tests - -[cols="25,75",options="header"] -|=== -|Annotation -|Description -|`@insulated` -|this makes the browser driver restart the browser session between each scenario. -It helps isolate the browser state. -When the browser session is recording, there is a separate video for each scenario. -Use this tag on all UI scenarios. -|`@disablePreviews` -|generating previews/thumbnails takes time. Use this tag on UI test scenarios that do not need to test thumbnail behavior. -|=== - -=== Running tests using release tarballs in CI -If you want to run the tests in CI against a system installed from one of the release tarballs, you can use the `testAgainstCoreTarball` setting in the `config` section of `.drone.star`. You can use the `coreTarball` option to specify which release tarball to install from. If no tarball version is specified then `daily-master-qa` will be used. -This will only use the release tarballs for running the acceptance tests while the unit and integration tests will run using the git branch. - -[source,python] ----- -config = { - 'acceptance': { - 'api': { - 'suites': [ - 'apiAuth', - 'apiAuthOcs', - 'apiAuthWebDav', - # and so on... - ], - 'testAgainstCoreTarball': True, - 'coreTarball': '10.7.0', - }, - }, -} ----- - -== Writing Scenarios For Bugs - -If you are developing a new feature, and the scenarios that you have written do not pass, -or existing scenarios are failing, then fix the code so that they pass. - -If you are writing scenarios to cover features and scenarios that are not currently covered -by acceptance tests then you may find existing bugs. - -If the bug is easy to fix, then provide the bugfix and the new acceptance test scenario(s) -in the same pull request. - -If the bug is not easy to fix, then: - - - create an issue describing the bug. - - write a scenario that demonstrates the existing wrong behavior. - - include commented-out steps in the scenario to document what is the expected correct behavior. - - write the scenario so that it will fail when the bug is fixed. - - tag the scenario with the issue number. - -[source,gherkin] ----- - @issue-32385 - Scenario: Change email address - When the user changes the email address to "new-address@owncloud.com" using the webUI - # When the issue is fixed, remove the following step and replace with the commented-out step - Then the email address "new-address@owncloud.com" should not have received an email - #And the user follows the email change confirmation link received by "new-address@owncloud.com" using the webUI - Then the attributes of user "Brian" returned by the API should include - | email | new-address@owncloud.com | ----- - -The above scenario is an example of this. -When the bug is fixed then the step about `should not have received an email` will fail. -CI will fail, and so the developer will notice this scenario and will have to correct it. - -== How to Add New Test Steps - -See http://behat.org/en/latest/user_guide.html[the Behat User Guide] for information about writing test step code. - -In addition to that, follow these guidelines. - -=== Given Steps - -The code of a `Given` step should achieve the desired system state by whatever means is quick to execute. -Typically use a public API if available, rather than running an `occ` command via the testing app or entering data in the webUI. - -If there is a simple way to gain confidence that the `Given` step was successful, then do it. -Typically this will check a status code returned in the API response. -Doing simple confidence checks in `Given` steps makes it easier to catch some unexpected problem during the scenario `Given` section. - -Here's example code for a `Given` step: - -[source,php] ----- -include::example$core/acceptance-tests/given-step.php[] ----- - -The code calls the method for the `When` step and then checks the HTTP status code. - -=== When Steps - -The code of a `When` step should perform the action but not check its result. -A `When` step should not ordinarily fail. -Often a `When` step will save the response. -It is the responsibility of later `Then` steps to decide if the scenario passed or failed. - -Here's example code for a `When` step: - -[source,php] ----- -include::example$core/acceptance-tests/when-step.php[] ----- - -The code saves the response so that later `Then` steps can examine it. - -=== Then Steps - -The code of a `Then` step should check some result of the `When` action. -Often it will find information in the saved response and assert something. - -Here's example code for a `Then` step: - -[source,php] ----- -include::example$core/acceptance-tests/then-step.php[] ----- - -However, a `Then` step may need to do actions of its own to retrieve more information about the state of the system. -For example, after changing a user password we could check that the user can still access some file: - -[source,php] ----- -include::example$core/acceptance-tests/then-step-with-actions.php[] ----- - -In the above example, `listFolder` is called and does an API call to access the file and then asserts that the response has a valid ETag. - -== References - -For more information on Behat, and how to write acceptance tests using it, see http://behat.org/en/latest/guides.html[the Behat documentation]. -For background information on Behaviour-Driven Development (BDD), see https://dannorth.net/whats-in-a-story/[Dan North resources]. - -== Skipping and Debugging Test Suites in CI - -=== Skip Pipelines - -For various purposes, you may skip one or more CI pipelines. Use `skip` in the drone config to skip the test pipelines. `skip` is available for `javascript`, `phpunit` and `acceptance` tests. - -Usage: -[source,py] ----- -... -'phpunit': { - 'allDatabases' : { - 'phpVersions': [ - '7.3', - ], - 'skip': True - }, -} -... -'acceptance': { - 'api': { - 'suites': [ - 'apiAuth', - 'apiAuthOcs', - 'apiAuthWebDav', - 'apiCapabilities', - 'apiComments' - ], - 'skip': True - }, -} -... ----- - -=== Debug Specific Test Suites -In CI, you may want to run only one or specific test suites for debugging purposes. To do so you can use `debugSuites` in the drone config which takes a list of suite names. If `debugSuites` is included with one or more test suites in it then only those suites will run in CI. -(Note: remember to set `'skip': False` if you are using `skip`) - -Usage: -[source,py] ----- -... -'acceptance': { - 'api': { - 'suites': [ - 'apiAuth', - 'apiAuthOcs', - 'apiAuthWebDav', - 'apiCapabilities', - 'apiComments' - ], - 'debugSuites': ['apiAuth'] - } -} -... ----- - -Similarly, in the case of test suites that run in parts, you can use `skipExceptParts` to specify only which part(s) you want to run. - -Usage: -[source,py] ----- -... -'acceptance': { - 'apiProxy': { - 'suites': { - 'apiProxySmoketest': 'apiProxySmoke', - }, - 'numberOfParts': 8, - 'skipExceptParts': [3, 7] - } -} -... ----- - -=== Organizing feature files -It may become difficult to maintain or even understand feature files as they grow larger. Now that we have a general background about the scenarios and steps in a feature file, the following things should be kept in mind while writing a feature file: - -==== Adding comments -Feature files are themselves a documentation of the feature being tested. It is a good practice to add comments in the code but for feature files, mostly feature & scenario descriptions should be prioritized. However, there are some cases where comments are necessary. An example might be to add a comment to a scenario explaining the step that shows the bug, as well as specifying the replacement after the bug is fixed. - -==== Adding tags -A scenario can have multiple tags. Tags not only help to run a subset of scenarios, but also provide the documentation of the scenario. For example, a scenario tagged with `@notToImplementOnOcis` can be used to track the scenarios that are not to be implemented for the oCIS server. A scenario can also be tagged with a related issue if it describes or refers to a bug. This makes it easier to track bugs and their fixes. For example, a scenario tagged with `@issue-123` can be used to track the scenario that is related to the issue with id `123` in the respective repository. - -The following two factors might complicate the process of assigning/removing tags: - -- *Should we leave closed issue tags in the scenarios?* - Yes, we should. This is purely for the purpose of documentation. The same issue may reappear in the future or something similar to it may happen. So, it is better to keep the tags in the scenarios. - -- *Which issue to tag in case of multiple issues?* - In cases where a scenario pertains to multiple issues, it should be tagged with the most relevant issue. A tagged issue should have a clearer description or more relevant discussion. - -==== Inter-scenario spacings -Since we follow the line numbers of the scenarios in the expected failure files, the scenarios in the feature files should be maintained in a more stable way. This means that the scenarios should not be moved around more often or gaps should be made consistent. For this, the following things should be kept in mind: - -- Between two scenarios, one blank line should be left. -- One line below the gap is reserved for the tags. - -There will be two lines of gaps if a scenario has no assigned tags. - -Usage: -[source,gherkin] ----- -... - # inter-scenario gap -@issue-123 # reserved tag line -Scenario: Scenario 1 - Given ... - When ... - Then ... - # inter-scenario gap - # reserved tag line -Scenario: Scenario 2 - Given ... - When ... - Then ... -... ----- diff --git a/content/server/10.15/modules/developer_manual/pages/testing/drone.adoc b/content/server/10.15/modules/developer_manual/pages/testing/drone.adoc deleted file mode 100644 index ce19e95..0000000 --- a/content/server/10.15/modules/developer_manual/pages/testing/drone.adoc +++ /dev/null @@ -1,85 +0,0 @@ -= Drone Testing -:toc: right - -:drone-cli-url: https://github.com/drone/drone-cli -:smashbox-url: https://github.com/owncloud-docker/smashbox - -== Introduction - -This document will show you how to run drone tests locally. - -== Setup Drone - -- Download the {drone-cli-url}[command line client] for the Drone Continuous Integration Server -- Have a local docker available -- Look at file `.drone.yml` for possible values or the variables as they appear in the CI drone runs -- Command: `PHP_VERSION=7.4 DB_TYPE=postgres TEST_SUITE=phpunit drone exec` - -== Acceptance Tests - -- You need a local ownCloud setup. If not already done, finalize the installation it with: -+ -[source,console,subs="attributes+"] ----- -{occ-command-example-prefix} maintenance:install ----- - -- Change into directory: -+ -[source,console] ----- -cd tests/acceptance ----- - -- Run all tests: -+ -[source,console] ----- -./run.sh ----- - -- Run a particular test by adding a feature file name and optionally line number: -+ -[source,console] ----- - ./run.sh features/sharing-v1.feature:123 ----- - -- From drone, use TEST_SUITE=api-acceptance-tests - -== Smashbox Tests - -Download the {smashbox-url}[ownCloud Smashbox Image] and see following possible commands: - -Note, the following command will not work, docker does not understand localhost, and needs a user and password: - -[source,console] ----- -sudo docker run -e SMASHBOX_URL=localhost:9680 \ - -e SMASHBOX_USERNAME=admin \ - -e SMASHBOX_ACCOUNT_PASSWORD=admin \ - owncloud/smashbox lib/test_basicSync.py ----- - -This is a correct working example: - -[source,console] ----- -sudo docker run -e SMASHBOX_URL=172.42.16.124:80/octest \ - -e SMASHBOX_USERNAME=admin \ - -e SMASHBOX_ACCOUNT_PASSWORD=admin \ - -e SMASHBOX_PASSWORD=admin \ - owncloud/smashbox lib/test_basicSync.py ----- - -This will run a specific test: - -[source,console] ----- -sudo docker run -e SMASHBOX_URL=172.42.16.124:80/octest \ - -e SMASHBOX_USERNAME=admin \ - -e SMASHBOX_ACCOUNT_PASSWORD=admin \ - -e SMASHBOX_PASSWORD=admin \ - owncloud/smashbox lib/test_basicSync.py -t 0 ----- - diff --git a/content/server/10.15/modules/developer_manual/pages/testing/index.adoc b/content/server/10.15/modules/developer_manual/pages/testing/index.adoc deleted file mode 100644 index 8a7e067..0000000 --- a/content/server/10.15/modules/developer_manual/pages/testing/index.adoc +++ /dev/null @@ -1,5 +0,0 @@ -:section-title: Testing -:section-preamble-ender: to learn about testing ownCloud's apps - -include::partial$section_page.adoc[optional attributes] - diff --git a/content/server/10.15/modules/developer_manual/pages/testing/test-pilots.adoc b/content/server/10.15/modules/developer_manual/pages/testing/test-pilots.adoc deleted file mode 100644 index c5d1822..0000000 --- a/content/server/10.15/modules/developer_manual/pages/testing/test-pilots.adoc +++ /dev/null @@ -1,82 +0,0 @@ -= ownCloud Test Pilots -:toc: right - -== Introduction - -The ownCloud Test Pilots help to test and improve different server and -client setups with ownCloud. - -== What do you do - -You will receive emails from the mailing list and also from the bug -tracker if developers need your help. Also, there will be announcements -of new releases and preview releases on the mailing list, which give you -the possibility to test releases early and to help the developers fix -them. - -We are looking forward to working with you :) - -== Why do you want to join - -There are many different setups, and people have different interests. -If we want ownCloud to run well on a variety of different software configurations, someone has to test them. -Furthermore, during bug fixing the ownCloud developers often do not have the possibility to reproduce the bug in a given environment, nor are they able confirm if it was fixed. - -As a member of the Test Pilot Team you could act as a contact person for -a particular area to help developers *fix the bugs you care about*. -Testing ownCloud before it is released is the best way of making sure it -does what you need. - -Another benefit is a closer relationship with the developers, because -you will know which people are responsible for which parts, and it will -be easier to get help. - -If you want, you can also be listed as an active contributor on the -https://owncloud.com[owncloud.com] page. - -== Who can join - -Anyone who is interested in improving the quality on his/her setup and -is willing to communicate with developers and other testers. - -== How do you join - -Just subscribe to the https://owncloud.com/beta-testing/#join[testpilot mailing list]. - -== How do you test - -Testing follows these steps: - -1. Setup your testing environment -2. Pick something to test -3. Test it -4. Go Back to step 2 until something unexpected/bad happens -5. Check if what you found is a genuine bug -6. File the bug - -== Installing ownCloud - -Testing starts with setting up a testing environment. We urge you not to -put your production data on testing releases unless you have a backup -somewhere! - -Start by installing ownCloud, either on real hardware or in a VM. You can find instructions for installing ownCloud in the xref:admin_manual:installation/manual_installation/manual_installation.adoc[Manual Installation on Linux]. - -Please note that we are still working on the documentation and if you -bump into a problem, you can -https://github.com/owncloud/docs[help us fix it]. Small things -can be edited straight on GitHub. - -== The Real Testing - -Testing is a matter of trying out some scenarios you decide on or were -asked to test, for example, sharing a folder and mounting it on another -ownCloud instance. If it works – awesome, move on. If it doesn’t, find -out as much as you can about why it doesn’t and use that for a bug -report. - -This is the stage where you should see if your issue is already reported by checking the relevant xref:bugtracker/index.adoc[bug tracker]. -It might even be fixed, sometimes! Alternatively, just ask on the test-pilots mailing list. - -Finally, if the issue you bump into is a definite bug and the developers -are not aware of it, file it as a new issue in xref:bugtracker/index.adoc[the relevant bug tracker]. diff --git a/content/server/10.15/modules/developer_manual/pages/testing/ui-testing.adoc b/content/server/10.15/modules/developer_manual/pages/testing/ui-testing.adoc deleted file mode 100644 index 52f4cef..0000000 --- a/content/server/10.15/modules/developer_manual/pages/testing/ui-testing.adoc +++ /dev/null @@ -1,249 +0,0 @@ -= User Interface Testing -:toc: right -:toclevels: 1 -:page-aliases: core/ui-testing.adoc - -== Requirements - -* ownCloud >= 10.0. Make sure you have a running instance of ownCloud -xref:admin_manual:installation/index.adoc[setup completely]. -* Default language set to `en` (in `config/config.php` set -`'default_language' => 'en',`). -* An admin user called `admin` with the password `admin`. -* No self-signed SSL certificates. -* The testing app installed and enabled. -* Testing utils (running `make` in your terminal from the `webroot` directory will install them). -* https://docs.docker.com/install/linux/docker-ce/ubuntu/[Docker CE Installed] -* https://docs.docker.com/install/linux/linux-postinstall/[Docker Post-install] done to put your developer account in the docker group so you can run Docker without `sudo` -* Docker subnet enabled for any firewall that may be active such as, https://help.ubuntu.com/community/UFW[ufw]. The example below shows how to update UFW's firewall rules to allow the `172.17.0.0/16` Docker subnet: - - sudo ufw status - sudo ufw allow from 172.17.0.0/16 - - -* Docker containers pulled. It is recommended to use `standalone-chrome-debug` which allows seeing the browser live. -The latest `standalone-chrome-*` containers have an https://github.com/owncloud/core/issues/35444[issue]. -So make sure to pull the specific chrome container versions listed below. -You will also need https://github.com/inbucket/inbucket[InBucket]. -Pull any or all of these Docker containers: - -[source] ----- -docker pull selenium/standalone-chrome:3.141.59-oxygen -docker pull selenium/standalone-chrome-debug:3.141.59-oxygen -docker pull selenium/standalone-firefox -docker pull selenium/standalone-firefox-debug -docker pull inbucket/inbucket ----- - -* A `vnc` viewer installed (in order to view the browser action as the UI tests run). For example: - -[source] ----- -sudo apt install tigervnc-viewer ----- - -* To run the https://www.seleniumhq.org[Selenium server] locally (not in Docker) see the notes at the end. - -== Overview - -Tests are divided into suites, enabling each suite to test some logical portion of the functionality and for the total elapsed run-time of a single suite to be reasonable (up to about 30 minutes on drone). -Elapsed run-time on a local developer system is very dependent on the IO as well as CPU performance. -Smaller apps may have all tests in a single suite. - -Each suite consists of a number of features. Each feature is described -in a `*.feature` file. There are a number of scenarios in each feature -file. Each scenario has a number of scenario steps that define the steps -taken to do the test. - -== Set Up Test - -- Start the Selenium Docker container in a terminal: - -[source,console] ----- -docker run -p 4445:4444 -p 5900:5900 -v /dev/shm:/dev/shm selenium/standalone-chrome-debug ----- - -Ports on the Selenium Docker IP address are mapped to `localhost` so they can be accessed by the tests and the `vnc` viewer. - -* Start the InBucket Docker container in another terminal: - -[source] ----- -docker run -p 2500:2500 -p 9000:9000 inbucket/inbucket ----- - -Ports on the InBucket docker IP address are mapped to `localhost` so they can be accessed by the tests. -By running these in terminal windows, it is simple to press `ctrl-C` to stop them when you are finished. - -* Set the following environment variables: - -** `EMAIL_HOST=localhost` (so that the tests know how to deliver mails) -** `TEST_SERVER_URL` (The URL of your webserver) -** `TEST_SERVER_FED_URL` (The alternative URL of your webserver for federation share tests - _optional_) -** `BROWSER` (Any one of `chrome`, `firefox`, `internet explorer` or `MicrosoftEdge`. Defaults to `chrome`) -** `BROWSER_VERSION` (version of the browser you want to use - _optional_) - -e.g., to test an instance running on the Docker subnet with Chrome do: - -[source,console,subs="attributes+"] ----- -export EMAIL_HOST=localhost -export TEST_SERVER_URL=http://172.17.0.1:{std-port-http}/owncloud-core -export TEST_SERVER_FED_URL=http://172.17.0.1:8180/owncloud-core -export BROWSER=chrome ----- - -* If your ownCloud install is running locally on Apache, then it should already be available on the Docker subnet at `172.17.0.1` - -* To run the federation Sharing tests: -1. Install another instance of ownCloud with its own separate database, code, data directory and URL -2. Install and enable the testing app -3. Make sure you have configured HTTPS with valid certificates on both servers URLs -4. xref:admin_manual:configuration/server/import_ssl_cert.adoc[Import SSL certificates] (or do not offer HTTPS). -* Run a suite of tests: -+ -[source,console] ----- -make test-acceptance-webui BEHAT_SUITE=webUILogin ----- - -The names of suites are found in the `tests/acceptance/config/behat.yml` file, and start with `webUI`. - -* The browser for the tests runs inside the Selenium docker container. View it by running the `vnc` viewer: `vncviewer`. - -And connect to `localhost`. The VNC password of the docker container is `secret`. - -== Running UI Tests using IPv6 - -The test system must have (at least locally) functioning IPv6: - -* working loopback address ::1 -* a `real` routable IPv6 address (not just a link-local address) - -If you have a server set up that listens on both IPv4 and IPv6 (e.g. localhost on 127.0.0.1 and ::1) then the UI tests will access the server via whichever protocol your operating system prefers. -If there are tests that specifically specify IPv4 or IPv6, then those will choose a suitable local address to come from so that they access the server using the required IP version. - -Because not everyone will have functional IPv6 on their test system yet, tests that specifically require IPv6 are tagged `@skip @ipv6`. -To run those tests, follow the section below on running skipped tests and specify `--tags @ipv6`. - -== Running UI Tests for One Feature - -You can run the UI tests for just a single feature by specifying the -feature file: - -[source,console] ----- -make test-acceptance-webui BEHAT_FEATURE=tests/acceptance/features/webUITrashbin/trashbinDelete.feature ----- - -To run just a single scenario within a feature, specify the line number -of the scenario: - -[source,console] ----- -make test-acceptance-webui BEHAT_FEATURE=tests/acceptance/features/webUITrashbin/trashbinDelete.feature ----- - -== Running UI Tests for an App - -With the app installed, run the UI tests for the app from the app root folder: - -[source,console] ----- -cd apps/files_texteditor -../../tests/acceptance/run.sh --suite webUITextEditor ----- - -Run UI the tests for just a single feature of the app by specifying -the feature file: - -[source,console] ----- -cd apps/files_texteditor -../../tests/acceptance/run.sh tests/acceptance/features/webUITextEditor/editTextFiles.feature ----- - -== Skipping Tests - -If a UI test is known to fail because of an existing bug, then it is -left in the test set _but_ is skipped by default. Skip a test by tagging -it `@skip` and then put another tag with text that describes the reason -it is skipped. e.g.,: - -[source,console] ----- -@skip @trashbin-restore-problem-issue-1234 -Scenario: restore a single file from the trashbin ----- - -Skipped tests are listed at the end of a default UI test run. -You can locally run the skipped test(s). -Run all skipped tests for a suite with: - -[source,console] ----- -make test-acceptance-webui BEHAT_SUITE=webUITrashbin BEHAT_FILTER_TAGS=@skip ----- - -Or run just a particular test by using its unique tag: - -[source,console] ----- -make test-acceptance-webui BEHAT_SUITE=webUITrashbin BEHAT_FILTER_TAGS=@trashbin-restore-problem-issue-1234 ----- - -When fixing the bug, remove these skip tags in the PR along with the bug -fix code. - -=== Additional Command Options - -Running all test suites in a single run is not recommended. -It will take many hours on a typical development system. -However, you may run all UI tests with: - -[source] ----- -make test-acceptance-webui ----- - -By default, any test scenarios that fail are automatically rerun once. -This minimizes transient failures caused by browser and Selenium driver timing issues. -When developing tests it can be convenient to override this behavior. - -To not rerun failed test scenarios: - -[source] ----- -make test-acceptance-webui NORERUN=true BEHAT_SUITE=webUILogin ----- - -=== Local Selenium Setup - -You may optionally run the Selenium server locally. -Docker is now the recommended way, but local Selenium is also possible: - -* https://docs.seleniumhq.org/download/[Selenium standalone server] e.g. version 3.12.0 or newer. -* Browser installed that you would like to test on (e.g. chrome) -* https://www.selenium.dev/downloads/#thirdPartyDrivers[Web driver for the browser] that you want to test. -* Place the Selenium standalone server jar file and the web driver(s) somewhere in the same folder. -* Start the Selenium server: - -[source] ----- -java -jar selenium-server-standalone-3.12.0.jar \ - -port 4445 \ - -enablePassThrough false ----- - -- In this configuration, the tests will continually open the browser-under-test on your local system. -- If you run any test scenarios that need an email service (to test password reset etc.), then you need to run the InBucket Docker container. - - -== Known Issues - -* Tests that are known not to work in specific browsers are tagged e.g., `@skipOnFIREFOX47+` or `@skipOnINTERNETEXPLORER` and will be skipped by the script automatically -* - The web driver for the current version of Firefox works differently to the old one. If you want to test FF < 56 you need to test on 47.0.2 and to use Selenium server 2.53.1 for it -- https://ftp.mozilla.org/pub/firefox/releases/47.0.2/[Download and install version 47.0.2 of Firefox]. -- https://selenium-release.storage.googleapis.com/index.html?path=2.53/[Download version 2.53.2 of the Selenium web driver]. diff --git a/content/server/10.15/modules/developer_manual/pages/testing/unit-testing.adoc b/content/server/10.15/modules/developer_manual/pages/testing/unit-testing.adoc deleted file mode 100644 index 949a525..0000000 --- a/content/server/10.15/modules/developer_manual/pages/testing/unit-testing.adoc +++ /dev/null @@ -1,376 +0,0 @@ -= Unit-Testing -:toc: right -:phpunit-docs-url: https://phpunit.readthedocs.io/ -:writing-tests-url: https://phpunit.readthedocs.io/en/9.5/writing-tests-for-phpunit.html -:recommended-way-to-organise-tests-url: https://phpunit.readthedocs.io/en/9.5/organizing-tests.html -:page-aliases: core/unit-testing.adoc -:notes-app-url: https://github.com/owncloud/notes - -== PHP Unit Tests - -ownCloud uses PHPUnit >= 7.5 for unit testing PHP code. - -=== Getting PHPUnit - -Running `make` in your terminal from the `webroot` directory will prepare -everything for testing. This will install beside necessary dependencies, -a local version of PHPUnit at `/lib/composer/phpunit/phpunit`. - -* Run `make help` to get a list of parameters -* To update your testing environment run `make clean` and `make` again. -* Take care that the php phpunit file in the path provided has the executable permission set. - -=== Running PHP Unit tests - -There are existing test options provided by ownCloud. -To run them, change into the root directory of your ownCloud installation and run `grep "make test" <(make help)` to see tests and parameters available. - -You should see output similar to the below example. - -[cols="50%,90%",grid=none,frame=none] -|=== -|make test -|run all tests - -|make test-php-unit -|run all PHP tests - -|make test-php-style -|run PHP code style checks - -|make test-php-phan -|run PHP phan static code analyzer - -|make test-php-phpstan -|run PHP phpstan static code analyzer - -|make test-js -|run Javascript tests - -|make test-js-debug -|run Javascript tests in debug mode (continuous) - -|make test-acceptance-api -|run API acceptance tests - -|make test-acceptance-cli -|run CLI acceptance tests - -|make test-acceptance-webui -|run webUI acceptance tests - -|make test-php-unit -|TEST_DATABASE=mysql TEST_PHP_SUITE=path/to/testfile.php - -|make test-php-style-fix -|run PHP code style checks and fix any issues found -|=== - -==== Testing Apps - -To run the tests for a specific app with the provided PHPUnit version: - -. Change into one of the writable directories listed in the `apps_paths` array in `config/config.php`, for example: -+ -[source,bash] ----- -cd apps-external ----- - -. Clone the app from GitHub, for example: -+ -[source,bash] ----- -git clone https://github.com/owncloud/notes.git ----- - -. Enable the app, for example: -+ -[source,bash,subs="attributes+"] ----- -cd .. -{occ-command-example-prefix} app:enable notes ----- - -. Change into the newly cloned directory, for example: -+ -[source,bash] ----- -cd apps-external/notes ----- - -. Run the following command: -+ --- -[source,bash] ----- -make test-php-unit ----- - -Here's an example of running the command in the {notes-app-url}[notes app]: - -[source,bash] ----- -php -d zend.enable_gc=0 "/home/phil/git/owncloud/core/apps-external/notes/../../lib/composer/bin/phpunit" --configuration ./phpunit.xml --testsuite unit -PHPUnit 7.5.20 by Sebastian Bergmann and contributors. - -Runtime: PHP 7.3.16-1+ubuntu18.04.1+deb.sury.org+1 with Xdebug 2.9.3 -Configuration: /home/phil/git/owncloud/core/apps-external/notes/phpunit.xml - -.................................. 34 / 34 (100%) - -Time: 541 ms, Memory: 24.00 MB - -OK (34 tests, 107 assertions) - -Generating code coverage report in Clover XML format ... done ----- --- - - -[NOTE] -==== -Apps that are part of core *do not* have their own Makefile. -Third party apps are all apps that are not distributed by {oc-marketplace-url}/publishers/owncloud[ownCloud] or not in xref:admin_manual:installation/apps_supported.adoc[the supported apps list]. -==== - -=== Writing PHP Unit tests - -To get started, do the following: - -* Create a directory called `tests/unit` in the top level of your application -* Create a PHP file in the directory and `require_once` your class which you want to test. - -Then you can run the created test with `phpunit`. - -TIP: Alternatively, you can use xref:attachment$/core/Makefile.example[the default Makefile] to automate your unit tests. - -If you use ownCloud functions in your class under test (i.e: -OC::getUser()) you’ll need to bootstrap ownCloud or use dependency -injection. - -[NOTE] -==== -You'll most likely run your tests under a different user than the Web server. -This might cause problems with your PHP settings (i.e., `open_basedir`) and requires you to adjust your configuration. -==== - -Given the class `MyClass` in your app: - -.`/srv/http/owncloud/apps/myapp/tests/lib/MyClass.php` -[source,php] ----- -include::example$core/unit-testing/MyClass.php[MyClass.php] ----- - -An example for a simple test would be: - -.`/srv/http/owncloud/apps/myapp/tests/unit/MyClassTest.php` -[source,php] ----- -include::example$core/unit-testing/MyClassTest.php[MyClassTest.php] ----- - -[NOTE] -==== -The class under test and the test class should share the same namespace so you do not need to use a dedicated `use` statement for it. -This is {recommended-way-to-organise-tests-url}[the recommended way to organize tests]. -==== - -In `/srv/http/owncloud/apps/myapp/` you run the test with the following command: - -[source,bash] ----- -phpunit tests/unit/MyClassTest.php ----- - -Make sure to extend the `\Test\TestCase` class with your test and always call the parent methods, when overwriting `setUp()`, -`setUpBeforeClass()`, `tearDown()` or `tearDownAfterClass()` methods from the `TestCase`. -These methods set up important stuff and clean up the system after the test so that the next test can run without side effects, such as clearing files and entries from the file cache, etc. -For more resources on writing tests for PHPUnit visit {writing-tests-url}[the writing tests section] of the PHPUnit documentation. - -=== Bootstrapping ownCloud - -If you use ownCloud functions or classes in your code, you’ll need to -make them available to your test by bootstrapping ownCloud. - -To do this, you’ll need to provide the `--bootstrap` argument when -running PHPUnit - -[source,bash] ----- -cd /srv/http/owncloud -phpunit --bootstrap tests/bootstrap.php apps/myapp/tests/testsuite.php ----- - -If you run the test suite as a user other than your Web server, you'll -have to adjust your php.ini and file rights. - -[source,bash] ----- -nano /etc/php/php.ini ----- - -and add `open_basedir = none` - -[source,bash] ----- -cd /srv/http/owncloud -su -c "chmod a+r config/config.php" -su -c "chmod a+rx data/" -su -c "chmod a+w data/owncloud.log" ----- - -=== Running Unit Tests for ownCloud Core - -The core project provides a script that runs all the core unit tests -using the specified database backend like `sqlite`, `mysql`, `pgsql`, -`oci` (for Oracle), the default is `sqlite` - -To run tests on `mysql` or `pgsql` you need a database user called -`oc_autotest` with the password `owncloud`. This user needs the -privilege to create and delete the database called `oc_autotest`. - -==== MySQL Setup - -[source,sql] ----- -CREATE DATABASE oc_autotest; -CREATE USER 'oc_autotest'@'localhost' IDENTIFIED BY 'owncloud'; -GRANT ALL ON oc_autotest.* TO 'oc_autotest'@'localhost'; ----- - -For parallel executor support with EXECUTOR_NUMBER=0 -++++++++++++++++++++++++++++++++++++++++++++++++++++ - -[source,sql] ----- -CREATE DATABASE oc_autotest0; -CREATE USER 'oc_autotest0'@'localhost' IDENTIFIED BY 'owncloud'; -GRANT ALL ON oc_autotest0.* TO 'oc_autotest0'@'localhost'; ----- - -==== PostgreSQL Setup - -[source,bash] ----- -su - postgres ----- - -[source,sql] ----- -# Use password "owncloud" -createuser -P oc_autotest - -# Give the user the privilege to create databases -psql -c 'ALTER USER oc_autotest CREATEDB;' ----- - -To enable `dropdb` add `local all all trust` to `pg_hba.conf`. - -For parallel executor support with EXECUTOR_NUMBER=0 -++++++++++++++++++++++++++++++++++++++++++++++++++++ - -[source,bash] ----- -su - postgres ----- - -[source,sql] ----- -# Use password "owncloud" -createuser -P oc_autotest0 - -# Give the user the privilege to create databases -psql -c 'ALTER USER oc_autotest0 CREATEDB;' ----- - -==== Run Tests - -To run all tests, run the following command: - -[source,bash] ----- -make test-php-unit ----- - -To run tests only for MySQL, run the following command: - -[source,bash] ----- -make test-php-unit TEST_DATABASE=mysql ----- - -To run a particular test suite, use the following command as a guide: - -[source,bash] ----- -make test-php-unit TEST_DATABASE=mysql TEST_PHP_SUITE=tests/lib/share/share.php ----- - -By default, a code coverage report is generated after the test run. To -avoid the time taken for that, specify `NOCOVERAGE`: - -[source,bash] ----- -make test-php-unit NOCOVERAGE=true TEST_DATABASE=mysql TEST_PHP_SUITE=tests/lib/share/share.php ----- - -=== Further Reading - -* http://googletesting.blogspot.de/2008/08/by-miko-hevery-so-you-decided-to.html[Writing Testable Code] -* {phpunit-docs-url}[PHPUnit Manual] -* http://www.youtube.com/watch?v=4E4672CS58Q&feature=bf_prev&list=PLBDAB2BA83BB6588E[Clean Code Talks - GuiceBerry] -* https://www.amazon.com/Clean-Code-Handbook-Software-Craftsmanship-ebook/dp/B001GSTOAM[Clean Code by Robert C. Martin] - -== Unit Testing JavaScript in Core - -JavaScript Unit testing for *core* and *core apps* is done using the -http://karma-runner.github.io[Karma] test runner with -https://jasmine.github.io[Jasmine]. - -=== Installing Node JS - -To run the JavaScript unit tests you will need to install *Node JS*. You -can get it here: http://nodejs.org/ After that you will need to setup -the *Karma* test environment. The easiest way to do this is to run the -automatic test script first, see next section. - -=== Running All The Tests - -To run all JavaScript tests, run the following command: - -[source,bash] ----- -make test-js ----- - -This will also automatically set up your test environment. - -=== Debugging Tests in the Browser - -To debug tests in the browser, this will run *Karma* in browser mode - -[source,bash] ----- -make test-js-debug ----- - -From there, open the URL `\http://localhost:9876` in a web browser. On that -page, click on the btn:[Debug] button. An empty page will appear, from -which you must open the browser console (F12 in Firefox/Chrome). Every -time you reload the page, the unit tests will be relaunched and will -output the results in the browser console. - -=== Unit Test File Paths - -JavaScript unit test examples can be found in `apps/files/tests/js/`. + -Unit tests for the core app JavaScript code can be found in `core/js/tests/specs`. - -=== Documentation - -Here are some useful links about how to write unit tests with Jasmine and Sinon: - -* Karma test runner: http://karma-runner.github.io -* Jasmine: https://jasmine.github.io -* Sinon (for mocking and stubbing): http://sinonjs.org/ diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/comments.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/comments.adoc deleted file mode 100644 index 6f9db6a..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/comments.adoc +++ /dev/null @@ -1,257 +0,0 @@ -= Comments API -:toc: right -:toclevels: 1 - -== Introduction - -The comments API allows the following functionalities for files and folders stored in ownCloud. - -It provides all of the functionality available through the UI and from the command-line. - -== List Comments - -[cols=",,",options="header",] -|================================================================ -| Request Path | Method | Content Type -| `remote.php/dav/comments/files/` | `PROPFIND` | `text/xml` -|================================================================ - -To retrieve a list of all comments, whether, for a file or folder, you -need to make an authenticated `PROPFIND` request, and supply it with the -path to the file or folder that you want to retrieve the comments of, as -in the example below. - ----- -curl --silent -u username:password \ - -X PROPFIND \ - -H "Content-Type: text/xml" \ - 'http://localhost/remote.php/dav/comments/files/4' | xmllint --format - ----- - -The response payload will look similar to the example below. It will -contain a list of `d:response` elements, one for each comment attached -to the file specified. - -The example above uses `xmllint`, available in the `libxml2` package to make -the response easier to read. - -[source,xml] ----- - - - - /remote.php/dav/comments/files/4/4 - - - - 1 - 0 - 0 - 0 - Here is a comment. - comment - users - admin - Tue, 16 May 2017 12:34:10 GMT - - files - 4 - admin - false - - HTTP/1.1 200 OK - - - ----- - -If you want to filter the information returned in the `d:prop` element -of the XML response, you can supply a `PROPFIND` XML element in the body -of the request method. The example below shows how to filter the -information returned to just the `oc:message` element. - -[source,xml] ----- - - - - - - ----- - -To use it in the request, add the `--data-binary` switch, passing in the -name of the file containing the `PROPFIND` XML element. I’ve called it -`report-propfind.xml` in the example below. - ----- -curl --silent -u username:password \ - -X PROPFIND \ - -H "Content-Type: text/xml" \ - --data-binary "@report-propfind.xml" \ - 'http://localhost/remote.php/dav/comments/files/4' | xmllint --format - ----- - -== Create Comments - -[cols=",,",options="header",] -|==================================================================== -| Request Path | Method | Content Type -| `remote.php/dav/comments/files/` | `POST` | `application/json` -|==================================================================== - -To create a comment, you need to send an authenticated `POST` request -with a JSON body containing the details of the comment to create. The -example below shows how to create a comment on the file with the file id -4. - ----- -curl -u username:password \ - -X POST \ - -H "Content-Type: application/json" \ - --data-binary '{"message":"this is my message","actorType":"users","verb":"comment"}' \ - "http://localhost/remote.php/dav/comments/files/4" ----- - -The available options are: - -[cols=",,",options="header",] -|======================================================================= -| Parameter | Type | Description -| `actorType` | String | The type of user who’s adding the comment. - -| `message` | String | The comment’s message text. It can be up to 1,000 -characters in length. - -| `verb` | String | The type of comment to create, typically `comment`. -|======================================================================= - -The comment is attributed to the user making the request. - -To retrieve a file id, refer to the -xref:classic_ui:files/access_webdav.adoc[relevant section of the documentation]. - -=== Response - -If the request is successful, there will be no response body returned. -However, it will have an `HTTP/1.1 201 Created` status. - -== Update Comments - -[cols=",,",options="header",] -|======================================================================= -| Request Path | Method | Content Type -| `remote.php/dav/comments/files//` | `PROPPATCH` -| `text/xml` -|======================================================================= - -To update an existing comment, you need to send an authenticated -`PROPPATCH` request and provide a `PROPFIND` XML element in the body. - -As with creating comments, we encourage you to store this in a separate -file and use the `--data-binary` switch to include it in the request. -This makes the information more maintainable. - -Below is an example request, which will change the comment with the id -of 4, on the file with the file id of 4. - ----- -curl -u username:password \ - -X PROPPATCH \ - -H "Content-Type: text/xml" \ - --data-binary "@update-comment.xml" \ - 'http://localhost/remote.php/dav/comments/files/4/4' | xmllint --format - ----- - -Below is an example `PROPPATCH` element, which changes the message text -but leaves the rest of the message unchanged. - -[source,xml] ----- - - - - - This is an updated message. - - - ----- - -=== Response - -Update comment requests will return the status: -`HTTP/1.1 207 Multi-Status`, and an XML response similar to the example -below. In it, you can see, in the `d:href` element the comment which was -changed. In the `d:status` element, you can see if the update was -successful or not. - -[source,xml] ----- - - - - /remote.php/dav/comments/files/4/4 - - - - - HTTP/1.1 200 OK - - - ----- - -If something goes wrong, you should receive a response similar to the -following - -[source,xml] ----- - - - Sabre\DAV\Exception\BadRequest - This should never happen (famous last words) - ----- - -If the tag is not available, then you will receive the following -response, along with an `HTTP/1.1 404 Not Found` status code. - -[source,xml] ----- - - - Sabre\DAV\Exception\NotFound - - ----- - -== Delete Comments - -[cols=",,",options="header",] -|======================================================================= -| Request Path | Method | Content Type -| `remote.php/dav/comments/files//` | `DELETE` -| `text/plain` -|======================================================================= - -To delete a comment, send an authenticated `DELETE` request, specifying -the path to the comment that you want to delete. - ----- -curl -u username:password -X DELETE 'http://localhost/remote.php/dav/comments/files/4/5' ----- - -If the comment was successfully deleted, no response body would be -returned, but an `HTTP/1.1 204 No Content` status code will be returned. -However, if the comment does not exist, then the following response will -be returned, along with an `HTTP/1.1 404 Not Found` status code. - -[source,xml] ----- - - - Sabre\DAV\Exception\NotFound - - ----- diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/files_versions.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/files_versions.adoc deleted file mode 100644 index d3db30b..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/files_versions.adoc +++ /dev/null @@ -1,19 +0,0 @@ -= Files Versions -:toc: right -:request_path: remote.php/dav -:method: PROPFIND -:content_type: text/xml - -== Introduction - -// The files versions API allows for two things: - -The files versions API allows the following: - -* xref:list-file-versions[Listing file versions] - -// * xref:restore-another-version-of-a-file[Restoring previous versions of files] - -// Note that "xref:restore-another-version-of-a-file" is missing in the included partial... using git log --follow -p modules/developer_manual/pages/_partials/webdav_api/files_versions/list_files_versions.adoc does not return a deletion = it was missing from the beginning - -include::partial$webdav_api/files_versions/list_files_versions.adoc[leveloffset=+1] diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/groups.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/groups.adoc deleted file mode 100644 index d260881..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/groups.adoc +++ /dev/null @@ -1,14 +0,0 @@ -= Group Management API -:toc: right -:request_base_path: remote.php/dav/customgroups/groups -:username: admin -:password: password -:prewrap: - -// some variables used in includes here are defined there - -== Custom Groups - -include::./groups/custom_groups_endpoints.adoc[] - -include::./groups/group_membership_endpoints.adoc[] diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/groups/custom_groups_endpoints.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/groups/custom_groups_endpoints.adoc deleted file mode 100644 index 31e9e1a..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/groups/custom_groups_endpoints.adoc +++ /dev/null @@ -1,131 +0,0 @@ -=== List Groups -:page-noindex: yes - -:request_base_path: remote.php/dav/customgroups/groups -:request_data_file: list-custom-groups.xml -:request_method: PROPFIND -:request_path_suffix: - -// this page is included via groups.adoc -// some variables like request_base_path used in includes here are defined there - -This endpoint returns a list of all custom groups. - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -.{request_data_file} -[source,xml] ----- -include::example$core/webdav_api/group/request/list-custom-groups.xml[] ----- - -Successful requests return two things: - -. An XML payload. -. A status of `HTTP/1.1 207 Multi-Status`. - -You can see an example of the XML payload below. -The XML payload contains a `response` element for each group. - -[source,xml] ----- -include::example$core/webdav_api/group/response/list-groups-successful-response.xml[] ----- - -==== No Results - -If there are no custom groups, then a response similar to the following will be returned. - -[source,xml] ----- -include::example$core/webdav_api/group/response/list-groups-no-results-response.xml[] ----- - -=== Rename Custom Group -:request_method: PROPPATCH -:request_data_file: rename-custom-group.xml -:request_path_suffix: <$groupId> - -This endpoint allows a custom group to be renamed. - -NOTE: Only group admins can rename the groups that they manage. - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -.{request_data_file} -[source,xml] ----- -include::example$core/webdav_api/group/request/rename-custom-group.xml[] ----- - -==== Responses - -===== Success - -A successful request will only return a status of `HTTP/1.1 204 No Content`. -No other information will be returned or displayed. - -===== Failure - -include::partial$webdav_api/responses/insufficient-privileges-overview.adoc[] - -====== Missing Group - -If the specified group does not exist, then the following XML response body will be returned, along with an `HTTP/1.1 207 Multi-Status` status. - -[source,xml] ----- -include::example$core/webdav_api/group/response/list-groups-missing-group-response.xml[] ----- - -=== Delete Group -:request_method: DELETE -:request_data_file: -:request_path_suffix: <$groupId> - -This endpoint allows for a custom group to be deleted. - -NOTE: Only group admins can delete a group. - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -==== Responses - -===== Success - -A successful request will only return a status of `HTTP/1.1 204 No Content`. -No other information will be returned or displayed. - -===== Failure - -include::partial$webdav_api/responses/insufficient-privileges-overview.adoc[] - -=== Create Group -:request_method: MKCOL -:request_path_suffix: <$groupId> - -This endpoint allows for creating a custom group. - -NOTE: The group's creator automatically becomes the group's admin and its initial member. - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -==== Responses - -===== Success - -A successful request will only return a status of `HTTP/1.1 201 Created`. -No other information will be returned or displayed. - -===== Failure - -include::partial$/webdav_api/responses/insufficient-privileges-overview.adoc[] - diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/groups/group_membership_endpoints.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/groups/group_membership_endpoints.adoc deleted file mode 100644 index 18f3d0a..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/groups/group_membership_endpoints.adoc +++ /dev/null @@ -1,181 +0,0 @@ -== Group Membership -:page-noindex: yes - -:request_base_path: /remote.php/dav/customgroups/users - -// this page is included via groups.adoc -// some variables like request_base_path used in includes here are defined there - -=== List Members -:request_method: PROPFIND -:request_data_file: list-custom-group-members.xml -:request_path_suffix: - -This endpoint allows for listing all of the members in a custom group. - -NOTE: Only group members can list a group's members. Other users will receive a status of `HTTP/1.1 403 Forbidden` - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -.{request_data_file} -[source,xml] ----- -include::example$core/webdav_api/group/request/list-custom-group-members.xml[] ----- - -==== Responses - -===== Success - -Successful requests return two things: - -. An XML payload. -. A status of `HTTP/1.1 207 Multi-Status`. - -You can see an example of the XML payload below. - -[source,xml] ----- -include::example$core/webdav_api/group/response/list-group-members-successful-response.xml[] ----- - -===== Failure - -include::partial$/webdav_api/responses/insufficient-privileges-overview.adoc[] - -=== Add Member -:request_method: PUT -:request_data_file: -:request_path_suffix: <$numericGroupId>/<$userId> - -This endpoint allows for adding members to a custom group. - -NOTE: Only group admins can add members. - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -==== Responses - -===== Success - -If the request succeeds, then only a `HTTP/1.1 201 Created` status will be returned. - -===== Failure - -===== Method Not Allowed - -If the request was made using any other method than `PUT`, then an `HTTP/1.1 405 Method Not Allowed` status will be returned, along with the XML payload below: - -[source,xml] ----- - - - Sabre\DAV\Exception\MethodNotAllowed - Cannot create collections - ----- - -include::partial$/webdav_api/responses/insufficient-privileges-overview.adoc[] - -=== Remove Member -:request_method: DELETE -:request_data_file: -:request_path_suffix: <$numericGroupId>/<$userId> - -This endpoint allows for removing members from a custom group. - -NOTE: Only group admins can remove members. -Group admins cannot remove themselves if no other admin exists in the group. -A group member can remove themselves using this API call. - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -==== Responses - -===== Success - -A successful request will only return a status of `HTTP/1.1 204 No Content`. -No other information will be returned or displayed. - -===== Failure - -include::partial$/webdav_api/responses/insufficient-privileges-overview.adoc[] - -=== Change Admin Role of a Member -:request_method: PROPPATCH -:request_data_file: -:request_path_suffix: <$numericGroupId>/<$userId> - -This endpoint allows for changing the admin role of an existing member of the group. - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -==== Responses - -===== Success - -===== Failure - -include::partial$/webdav_api/responses/insufficient-privileges-overview.adoc[] - -=== List Group Memberships of a Given User -:request_method: PROPFIND -:request_data_file: -:request_base_path: /remote.php/dav/customgroups/users -:request_path_suffix: <$userId>/<$membership> - -This endpoint lists the groups that a user is a member of. - -include::partial$/webdav_api/uri_request_table.adoc[] - -include::partial$/webdav_api/core_curl_request.adoc[] - -==== Responses - -===== Success - -Successful requests return two things: - -. An XML payload. -. A status of `HTTP/1.1 207 Multi-Status`. - -You can see an example of the XML payload below. - -[source,xml] ----- -include::example$core/webdav_api/group/response/list-group-memberships-of-a-given-user-successful-response.xml[] ----- - -===== Failure - -include::partial$/webdav_api/responses/insufficient-privileges-overview.adoc[] -//// -== REPORT - -.report-customgroups.xml -[source,xml] ----- -include::example$core/webdav_api/group/report-customgroups.xml[indent=0] ----- - -[source,console] ----- -curl -u admin:admin -X REPORT \ - -H "Content-Type: text/xml" \ - --data-binary "@report-customgroups.xml" \ - 'http://localhost/owncloud/remote.php/dav/customgroups/' ----- - -[source,xml] ----- -include::example$core/webdav_api/group/response-success.xml[indent=0] ----- -//// diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/index.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/index.adoc deleted file mode 100644 index 4f2355f..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/index.adoc +++ /dev/null @@ -1,4 +0,0 @@ -:section-title: WebDAV APIs -:section-preamble-ender: to ownCloud's WebDAV APIs - -include::partial$section_page.adoc[] diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/meta.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/meta.adoc deleted file mode 100644 index 9346be4..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/meta.adoc +++ /dev/null @@ -1,85 +0,0 @@ -= Meta API -:toc: right -// Attributes for the core details include -:request_path: remote.php/dav/meta/ -:method: PROPFIND -:content_type: text/xml -:report-request-uri: https://tools.ietf.org/html/rfc3253#section-3.6 -:libxml-url: http://www.xmlsoft.org -:http207-url: https://httpstatuses.com/207 -:http404-url: https://httpstatuses.com/404 - -== Introduction - -An authenticated `PROPFIND` request to `{request_path}` returns the path to a file/folder for the -logged in user. - -TIP: To retrieve a list of available files, use the -xref:webdav_api/search.adoc#limiting-returned-file-properties[Filter Files endpoint], -and ensure that returned properties includes `fileid`. - -include::partial$webdav_api/core_request_details.adoc[leveloffset=+1] - -== Request Parameters - -[cols=",,",options="header",] -|=== -|Attribute -|Type -|Description - -|`fileid` -|integer -|The file's id. -|=== - -TIP: The example above uses xmllint, available in {libxml-url}[the libxml2 package] to make -the response easier to read. - -== Example Responses - -=== Success - -If the file of folder is found, then a response similar to the following will be returned with an -{http207-url}[HTTP/1.1 207 Multi-Status] status: - -[source,xml] ----- -include::example$core/webdav_api/meta/response-success.xml[] ----- - -=== Failure - -If the file is not found, then the following response will be returned with an -{http404-url}[HTTP/1.1 404 Not Found] status: - -[source,xml] ----- -include::example$core/webdav_api/meta/response-failure.xml[] ----- - -== Example Request - -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -curl -u {oc-examples-username}:{oc-examples-password} \ - -X PROPFIND \ - -H "Depth: 0" \ - -H "Content-Type: text/xml" \ - --data "@meta-files.xml" \ - '{oc-examples-server-url}/remote.php/dav/meta/' | xmllint --format - ----- --- -==== - -=== meta-files.xml - -[source,xml] ----- -include::example$core/webdav_api/meta/meta-files-filter.xml[] ----- diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/public_files.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/public_files.adoc deleted file mode 100644 index eb4acb2..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/public_files.adoc +++ /dev/null @@ -1,105 +0,0 @@ -= Public Files API -:toc: right -:toclevels: 1 -:request-base-path: remote.php/dav/public-files -:xmlpp-url: https://linux.die.net/man/1/xml_pp - - -== Introduction - -The public-files API allows access to public links via WebDAV. - -[cols="40%,30%,30%",options="header",] -|=== -| Request Path -| Method -| Content Type - -| `remote.php/dav/public-files/` -| `PROPFIND` -| `text/xml` -|=== - -== Request Parameters - -[cols=",,",options="header",] -|=== -|Attribute -|Type -|Description - -|`SHARE_TOKEN` -|string -|The share token for the public link. -|=== - -== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/dav/public_files/view_public_link.sh[] ----- --- -PHP:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/php/dav/public_files/view_public_link.php[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -=== Curl - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/dav/public_files/view_public_link.sh[] ----- - -=== PHP - -[source,console,subs="attributes+"] ----- -include::example$core/scripts/php/dav/public_files/view_public_link.php[] ----- -endif::[] - -NOTE: No user and password is required, by default. -In case the public link _is_ protected with a password, use `public` for the username and the share link password for the password. - -TIP: The curl example uses {xmlpp-url}[xml_pp] to pretty print the result. - -== Returns - - -=== Example Response - -If the public link is available, then output similar to the following will be displayed. - -[source,xml] ----- -include::example$core/webdav_api/public_files/response/public-link-is-available.xml[] ----- - -If the share token is missing or invalid, then you will see output similar to the following: - -[source,xml] ----- -include::example$core/webdav_api/public_files/response/listing-members-is-disabled.xml[] ----- - -If the user does not have read privileges on the public link, then they will see output similar to the following: - -[source,xml] ----- -include::example$core/webdav_api/public_files/response/listing-members-is-disabled.xml[] ----- diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/search.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/search.adoc deleted file mode 100644 index cf5915c..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/search.adoc +++ /dev/null @@ -1,11 +0,0 @@ -= Search API -:toc: right - -== Introduction - -If you need to search for files, then you can use the WebDAV search API. -The search API exposes two endpoints for finding files in a user’s filesystem. - -include::./search/_search_files.adoc[leveloffset=+1] - -include::./search/_filter_files.adoc[leveloffset=+1] diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/search/_filter_files.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/search/_filter_files.adoc deleted file mode 100644 index a3652ca..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/search/_filter_files.adoc +++ /dev/null @@ -1,117 +0,0 @@ -= Filter Files -:page-noindex: yes - -// Attributes for the core details include -:request_path: remote.php/dav/files/ -:method: REPORT -:content_type: text/xml - -The `filter-files` report allows for retrieving a list of files in an ownCloud user's filesystem, based on two criteria: - -include::partial$/webdav_api/core_request_details.adoc[leveloffset=+1] - -== The Request - -An authenticated https://tools.ietf.org/html/rfc3253#section-3.6[REPORT request] needs to be made to retrieve a list of all files stored in a user's ownCloud filesystem. - -=== Example Request - -[source,console] ----- -curl --silent \ - -X REPORT \ - --data "@filter-files-criteria.xml" \ - -u admin:admin \ - 'http://localhost/remote.php/dav/files/admin' | xmllint --format - ----- - -The request must include a request body that includes the rules to filter by. -There are two filter rules which can be supplied; these are: - -[cols="1,2,1,1,1",options="header",] -|=== -|Rule -|Description -|Type -|Accepted Values -|Mandatory - -|`favorite` -|Whether they’ve been marked as a favorite or not (mandatory) -|integer -|`0`,`1` -|Yes - -|`systemtag` -|The tags that have been assigned to them -|integer -|Any valid system tag. - These can be retrieved by using xref:webdav_api/tags.adoc#list-tags[the Tags API]. -|No -|=== - -=== Example Request Bodies - -Below, are several examples of the XML response bodies that can be sent with the request. - -==== Minimal Request Body - -In the `search` element, it specifies the search pattern to filter down the list of files to return in a successful resultset. - -[source,xml] ----- -include::example$core/webdav_api/search/request/filter_files/minimal_filter_files_report_request_body.xml[indent=0] ----- - -==== Limiting Returned File Properties - -If only a specific list of properties is required for each file, then a `prop` element needs to be included in the response body, such as in the example below. - -include::partial$/webdav_api/search/file_properties.adoc[] - -[source,xml] ----- -include::example$core/webdav_api/search/request/filter_files/search_body_requesting_all_properties.xml[indent=0] ----- - -==== Filtering By Tag - -Files can be filtered by those assigned specific tags. -If this is required, then the `systemtag` element needs to be supplied, which contains a space-separated list of tag _ids_ to filter by. - -TIP: Tag ids can be retrieved by using xref:webdav_api/tags.adoc#list-tags[the Tags API]. - -[source,xml] ----- -include::example$core/webdav_api/search/request/filter_files/search_body_filtering_by_system_tag_ids.xml[indent=0] ----- - -NOTE: The example uses http://xmlsoft.org/xmllint.html[xmllint] to make the response more readable. -Xmllint is available in the http://www.xmlsoft.org/[libxml2 package]. - -== The Response - -=== Success - -Successful requests return two things: - -. An XML payload. -. A status of `HTTP/1.1 207 Multi-Status`. - -You can see an example of the XML payload below. -The XML payload contains a `response` element for each file. -And each `response` element contains three items: - -. A link to the file (`href`). -. The requested properties, along with their respective values (`propstat`). -. The file's status (`status`). - -.Example of a successful search response -[source,xml] ----- -include::example$core/webdav_api/search/response/filter_files/success.xml[indent=0] ----- - -=== Failure - -include::partial$/webdav_api/search/common_error_responses.adoc[] diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/search/_search_files.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/search/_search_files.adoc deleted file mode 100644 index 7237bc7..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/search/_search_files.adoc +++ /dev/null @@ -1,126 +0,0 @@ -= Search Files -:page-noindex: yes - -// Attributes for the core details include -:request_path: remote.php/dav/files/ -:method: REPORT -:content_type: text/xml - -The `search-files` report search through the available files in an ownCloud user's filesystem, based on a rudimentary filename pattern match. - -By default, the report uses ownCloud's default search provider to power the search functionality. -However, other search providers, such as https://github.com/owncloud/search_elastic[search_elastic] and https://github.com/owncloudarchive/search_lucene[search_lucene] greatly enrich the ability to search, such as being able to search through file content, as well as by a file's name. -When installed, they replace ownCloud's default search provider and the search API will automatically use them. - -TIP: When using the default search provider, if you use the search string "_ownCloud_", files whose filename has "ownCloud" in it will be matched. -However, if installed https://github.com/owncloud/search_elastic[the search_elastic app], the report also retrieves files that have "_ownCloud_" in the file's contents. - -include::partial$/webdav_api/core_request_details.adoc[leveloffset=+1] - -== The Request - -An authenticated https://tools.ietf.org/html/rfc3253#section-3.6[REPORT request] needs to be made to search for all files stored in a user's ownCloud filesystem - -=== Example Request - -[source,console] ----- -curl --silent \ - -X REPORT \ - --data "@supported.xml" \ - -u admin:admin \ - 'http://localhost/remote.php/dav/files/admin' | xmllint --format - ----- - -The request must include a request body that includes the search pattern, and can also include a list of properties to return. - -=== Example Request Bodies - -Below, are several examples of XML response bodies. - -==== Searching For Records - -In the `search` element, specify the search pattern to filter the list of files to return. - -[source,xml] ----- -include::example$core/webdav_api/search/request/search_files/minimal_request_body.xml[indent=0] ----- - -==== Filtering Records - -The `filter-rules` element provides the ability to filter records based on a range of properties. -In the example below, you can see how to filter out any file that has not been favorited. - -[source,xml] ----- -include::example$core/webdav_api/search/request/filter_files/minimal_filter_files_report_request_body.xml[indent=0] ----- - -==== Limiting The Number Of Results Returned - -To limit the number of results returned, use a combination of the `search` element’s `limit`, and `offset` elements, as in the following example. -In the example below, at most one hundred records, starting from record 200, will be returned. - -[source,xml] ----- -include::example$core/webdav_api/search/request/search_files/limit_number_of_results.xml[indent=0] ----- - -==== Reducing The File Properties Returned - -However, if a specific list of properties is required for each file, then a `prop` element needs to be included in the response body, such as in the example below. - -include::partial$/webdav_api/search/file_properties.adoc[] - -[source,xml] ----- -include::example$core/webdav_api/search/request/search_files/search_body_with_properties.xml[indent=0] ----- - -NOTE: The example uses http://xmlsoft.org/xmllint.html[xmllint] to make the response more readable. -Xmllint is available in the http://www.xmlsoft.org/[libxml2 package]. - -== The Response - -=== Success - -Successful requests return two things: - -. An XML payload. -. A status of `HTTP/1.1 207 Multi-Status`. - -You can see an example of the XML payload below. -The XML payload contains a `response` element for each file. -And each `response` element contains three items: - -. A link to the file (`href`). -. The requested properties, along with their respective values (`propstat`). -. The file's status (`status`). - -.Search Response -[source,xml] ----- -include::example$core/webdav_api/search/response/search_files/success/search_response.xml[indent=0] ----- - -=== Failure - -==== If The Payload File Cannot Be Read Or Is Invalid XML - -If the payload file cannot be read or is invalid XML, then the following XML response is sent, along with an `HTTP/1.1 500 Internal Server Error` status code. - -[source,xml] ----- -include::example$core/webdav_api/search/response/common/failure/incorrect_payload_or_parse_failure.xml[indent=0] ----- - -==== If a Non-Existent Property Is Requested - -If a non-existent property is requested, then an additional `propstat` element is returned, as in the example below, which contains a list of the properties which were not available. - -[source,xml] ----- -include::example$core/webdav_api/search/response/common/failure/request_non_existent_property.xml[indent=0,lines=19..25] ----- - diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/tags.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/tags.adoc deleted file mode 100644 index 09477e6..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/tags.adoc +++ /dev/null @@ -1,490 +0,0 @@ -= Tags API -:toc: right -:toclevels: 1 - -== Introduction - -The tags API provides extensive support for managing tags within ownCloud. -In short, it provides all of the functionality available through the UI, -from the command-line. - -== List Tags - -[cols=",,",options="header",] -|===================================================== -| Request Path | Method | Content Type -| `remote.php/dav/systemtags` | `PROPFIND` | `text/plain` -|===================================================== - -To retrieve a list of all tags, stored in your ownCloud installation, you need to make an authenticated `PROPFIND` request, as in the example below. - ----- -curl --silent -u username:password \ - -X PROPFIND \ - 'http://localhost/remote.php/dav/systemtags' | xmllint --format - ----- - -The curl examples use http://xmlsoft.org/xmllint.html[xmllint], available in the libxml2 package, to make the response easier to read. - -This request will return an XML response similar to this example and a status of: `HTTP/1.1 207 Multi-Status`. - -[source,xml] ----- - - - - /remote.php/dav/systemtags/2 - - - - - HTTP/1.1 200 OK - - - ----- - -Note that it does not return very much, just the `href` and `status` properties. -If you want to retrieve more detailed information, you need to supply a https://webmasters.stackexchange.com/questions/59211/what-is-http-method-propfind-used-for[PROPFIND] element in the request body, containing all the properties that you want to retrieve in the response. -The sample below, which for the purposes of this example we'll store in a file called `report-propfind.xml`, shows how to do so. - -[source,xml] ----- - - - - - - - - - - ----- - -To use it in the request, add the `--data-binary` switch, passing in the name of the file containing the `PROPFIND` XML element. - ----- -curl --silent -u username:password \ - -X PROPFIND \ - -H "Content-Type: text/xml" \ - --data-binary "@report-propfind.xml" \ - 'http://localhost/remote.php/dav/systemtags' | xmllint --format - ----- - -We encourage you to store this in a separate file and use the `--data-binary` switch to include it in the request, instead of supplying the information in the command directly. -This makes the information more maintainable. - -Adding the `PROPFIND` XML element will cause the XML response to look similar to the following example. - -[source,xml] ----- - - - - /remote.php/dav/systemtags/10 - - - file - true - 10 - - HTTP/1.1 200 OK - - - - /remote.php/dav/systemtags/9 - - - for - true - 9 - - HTTP/1.1 200 OK - - - ----- - -You can see that, along with the `href` and `status` elements, each element now contains the `display-name`, `user-visible`, and `id` elements. -To clarify, `display-name` contains the visible tag name. - -== Create Tags - -[cols=",,",options="header",] -|===================================================== -| Request Path | Method | Content Type -| `remote.php/dav/systemtags` | POST | `application/json` -|===================================================== - -To create a tag, you need to send an authenticated `POST` request with a JSON body containing the details of the tag to create. -The example below shows how to create a tag with the name `test5`, which is visible to all users. - ----- -curl -u username:password \ - -X POST \ - -H "Content-Type: application/json" \ - --data-binary '{"name":"test5","userVisible":"true","userAssignable":"true"}' \ - "http://localhost/remote.php/dav/systemtags" ----- - -=== Available Parameters - -[cols=",,,",options="header",] -|================================= -| Parameter | Type | Length | Required -| name | string | | yes -| userVisible | boolean | | no -| userAssignable | boolean | | no -|================================= - -=== Response - -Regardless of success or failure, no response body is returned. -However, if the tag is created successfully a status of `HTTP/1.1 201 Created` will be sent, and the location (and id) of the new tag will be available in the Content-Location header. -For example: `Content-Location: /remote.php/dav/systemtags/15`. -If a tag with the name supplied already exists a status of `HTTP/1.1 409 Conflict` will be sent. - -== Update Tags - -[cols=",,",options="header",] -|============================================================ -| Request Path | Method | Content Type -| `remote.php/dav/systemtags/` | `PROPPATCH` | `text/xml` -|============================================================ - -To update an existing tag, you need to send an authenticated `PROPPATCH` request and provide a `PROPFIND` XML element in the body. -Below is an example request, which will change the tag with the id of 15. - ----- -curl -u username:password -X PROPPATCH \ - -H "Content-Type: text/xml" \ - --data-binary '@update-tag.xml' \ - "http://localhost/remote.php/dav/systemtags/15" | xmllint --format - ----- - -Below is an example `PROPPATCH` element, which changes the message text but leaves the rest of the message unchanged. - -[source,xml] ----- - - - - - This is an updated tag. - - - ----- - -=== Response - -If the update is successful, then an XML response body will be returned, which looks similar to the example below. -In addition an `HTTP/1.1 207 Multi-Status` status will also be returned. - -[source,xml] ----- - - - - /remote.php/dav/systemtags/15 - - - - - HTTP/1.1 200 OK - - - ----- - -== Delete Tags - -[cols=",,",options="header",] -|======================================================= -| Request Path | Method | Content Type -| `remote.php/dav/systemtags/` | DELETE | text/plain -|======================================================= - -To delete a tag, send an authenticated `DELETE` request, specifying the path to the tag that you want to delete. - ----- -curl -u username:password -X DELETE 'http://localhost/remote.php/dav/systemtags/15' ----- - -If the comment was successfully deleted, an `HTTP/1.1 204 No Content` status will be returned but with no response body. -However, if the comment does not exist, then the following response will be returned, along with an `HTTP/1.1 404 Not Found` status. - -[source,xml] ----- - - - Sabre\DAV\Exception\NotFound - Tag with id 15 not found - ----- - -== Retrieve the Tag IDs and Metadata of a Given File - -[cols=",,",options="header",] -|======================================================================= -| Request Path | Method | Content Type -| `remote.php/dav/systemtags-relations/files/` | PROPFIND -| `text/xml` -|======================================================================= - -To retrieve the tag ids and metadata of a given file, send an authenticated `PROPFIND` request, specifying the path to the file to retrieve the information from. - ----- -# Retrieve the details from file with id 4 -curl -u username:password -X PROPFIND \ - -H "Content-Type: text/xml" \ - "http://localhost/remote.php/dav/systemtags-relations/files/4" | xmllint --format - ----- - -=== Response - -[source,xml] ----- - - - - /remote.php/dav/systemtags-relations/files/4/ - - - - - - - HTTP/1.1 200 OK - - - ----- - -If more detailed information is desired, a `PROPFIND` element in the -request body is required. The sample below, which for the purposes of -this example we’ll store in a file called `report-propfind.xml`, will -return the `display-name`, `user-visible`, `user-assignable`, and `id` values -for each tag. - -[source,xml] ----- - - - - - - - - - ----- - -To use it, as in previous examples, the `--data-binary` switch is -required, as in the example below. - ----- -curl -u username:password -X PROPFIND \ - -H "Content-Type: text/xml" \ - --data-binary '@report-propfind.xml' \ - "http://localhost/remote.php/dav/systemtags-relations/files/4" | xmllint --format - ----- - -Below is an example of the response returned from this request: - -[source,xml] ----- - - - - /remote.php/dav/systemtags-relations/files/4/2 - - - test - true - true - 2 - - HTTP/1.1 200 OK - - ----- - -== Assign a Tag to a File - -[cols=",,",options="header",] -|======================================================================= -| Request Path | Method | Content Type -| `remote.php/dav/systemtags-relations/files//` | PUT -| `text/xml` -|======================================================================= - -To assign a tag to a file, send an authenticated `PUT` request -specifying the path to the file to tag. Here is an example of how to do -it using Curl. - ----- -curl -u username:password -X PUT \ - -H "Content-Type: text/xml" \ - "http://localhost/remote.php/dav/systemtags-relations/files/4/6" ----- - -=== Response - -If the request is successful, no response body will be returned, but an -`HTTP/1.1 201 Created` status will be returned. If the request is not -successful, then either an `HTTP/1.1 404 Not Found` or an -`HTTP/1.1 409 Conflict` status will be returned. A 404 status is -returned if the file or folder doesn’t exist. A 409 status is returned -if the tag has already been assigned to that file or folder. - -== Unassign a Tag From a File - -[cols=",,",options="header",] -|======================================================================= -| Request Path | Method | Content Type -| `remote.php/dav/systemtags-relations/files//` | DELETE -| `text/xml` -|======================================================================= - -To un-assign or remove a tag from a file, send an authenticated `DELETE` -request specifying the path to the file and the tag to remove. Here is -an example of how to do it using Curl. - ----- -curl --silent --verbose -u username:password -X DELETE \ - -H "Content-Type: text/xml" \ - "http://localhost/remote.php/dav/systemtags-relations/files/4/6" ----- - -=== Response - -If the request is successful, no response body will be returned, but an -`HTTP/1.1 204 No Content` status will be returned. If the request is not -successful, likely because the tag was not assigned to the file or -folder, then an `HTTP/1.1 404 Not Found` status will be returned. - -== Create and Assign a Tag at the Same Time - -[cols=",,",options="header",] -|======================================================================= -| Request Path | Method | Content Type -| `remote.php/dav/systemtags-relations/files/` | POST -| application/json -|======================================================================= - -In addition to assigning existing tags to a file, you can also create a -new tag and assign it to a file in one request. You do this by sending -an authenticated `POST` request specifying the path to the file and a -JSON body containing the details of the tag to create. - -The new tag will be created and assigned, effectively, in one atomic -operation. Here is an example of how to do it using Curl. - ----- -curl --silent --verbose -u username:password -X POST \ - -H "Content-Type: application/json" \ - --data-binary '{"name":"variabletag","userVisible":"true","userAssignable":"true"}' \ - "http://localhost/remote.php/dav/systemtags-relations/files/4" ----- - -If the request is successful, no response body will be returned, but an -`HTTP/1.1 201 Created` status will be returned. If the request is not -successful, likely because the tag already exists, then an -`HTTP/1.1 409 Conflict` status will be returned. - -== Retrieve All Files Tagged with a Tag ID - -[cols=",,",options="header",] -|======================================== -| Request Path | Method | Content Type -| `remote.php/webdav/` | REPORT | `text/xml` -|======================================== - -To retrieve all the files tagged with a given tag id send an -authenticated `REPORT` request with a `PROPFIND` element in the request -body containing the tag id to filter on and the list of properties to -return. - -The sample a `PROPFIND` element below, which for the purposes of this -example we’ll store in a file called `report-propfind.xml`, will return -every tag property, and will filter on tag id 17. - -[source,xml] ----- - - - - - - - - - - - - - - - - - - - 17 - - ----- - -And here is an example of how to make the request using Curl. - ----- -curl --silent --verbose -u username:password -X REPORT \ - -H "Content-Type: text/xml" \ - --data-binary "@find-tags-by-file.xml" \ - "http://localhost/remote.php/webdav/" | xmllint --format - ----- - -=== Response - -A successful response which you can see an example of below, along with -a status of `HTTP/1.1 207 Multi-Status` will be returned. - -[source,xml] ----- - - - - /remote.php/webdav/Photos/Squirrel.jpg - - - Wed, 03 May 2017 11:05:49 GMT - "0169c644a1580687b346ef43315d5ac8" - image/jpeg - - 6 - RDNVW - 233724 - 233724 - - 0 - 0 - admin - - - HTTP/1.1 200 OK - - - ----- - -If the request was unsuccessful, likely because the tag specified didn't exist, then an `HTTP/1.1 412 Precondition failed` status will be returned, along with the following XML payload in the body of the response. - -[source,xml] ----- - - - Sabre\DAV\Exception\PreconditionFailed - Cannot filter by non-existing tag - ----- diff --git a/content/server/10.15/modules/developer_manual/pages/webdav_api/trashbin.adoc b/content/server/10.15/modules/developer_manual/pages/webdav_api/trashbin.adoc deleted file mode 100644 index 5f69576..0000000 --- a/content/server/10.15/modules/developer_manual/pages/webdav_api/trashbin.adoc +++ /dev/null @@ -1,266 +0,0 @@ -= Trashbin API -:toc: right -:toclevels: 1 -:request-base-path: remote.php/dav/trash-bin - -== Introduction - -The trash bin API provides support for managing files in ownCloud’s trash bin. -Specifically, it provides the following functionality: - -* xref:list-files[List files in the trash bin] -* xref:delete-files[Delete files permanently from the trash bin] -* xref:restore-deleted-file[Restore deleted files to the trash bin] - -== List Files - -List all files in the trash bin - -* Path: `{request-base-path}/` -* Method: `PROPFIND` - -=== Request Parameters - -[cols=",,",options="header",] -|=== -|Attribute -|Type -|Description - -|`username` -|string -|The username of the user to list files for. -|=== - -=== Request Headers - -[cols="25%,25%,50%",options="header",] -|=== -|Header -|Type -|Description - -|`Depth` -|int -a|The maximum level to descend to, when retrieving a listing of the files in the user's trash bin. - -NOTE: Only one level of files and directories is returned if this header is omitted. -|=== - -=== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/dav/trashbin_api/list-files-in-trashbin.sh[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/dav/trashbin_api/list-files-in-trashbin.sh[] ----- -endif::[] - -=== Returns - -This method returns an HTTP 207 (Multi-Status) status code and an XML response that contains the files in the trash bin of the authenticating user, limited to the depth specified by the `Depth` header. - -==== Example Response - -If the user that you’re connecting with is authorized, then you will see output similar to the following: - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,xml] ----- -include::example$core/webdav_api/trashbin/list-files-in-trashbin-success-response.xml[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -[source,xml] ----- -include::example$core/webdav_api/trashbin/list-files-in-trashbin-success-response.xml[] ----- -endif::[] - -== Delete Files - -Permanently delete a file from the trash bin. - -* Path: `{request-base-path}//` -* Method: `DELETE` - -=== Request Parameters - -[cols=",,",options="header",] -|=== -|Attribute -|Type -|Description - -|`username` -|string -|The username of the user to list files for. - -|`fileid` -|integer -|The id of the file to delete. -|=== - -=== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/dav/trashbin_api/delete-file-from-trashbin.sh[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/dav/trashbin_api/delete-file-from-trashbin.sh[] ----- -endif::[] - -=== Returns - -This method returns an HTTP 204 (No Content) status code, if the file is successfully deleted. -If there is no file in the trash bin with the specified file id, then an HTTP 404 (Not Found) status code is returned. - -== Restore Deleted File - -Restore a file from the trash bin. - -* Path: `{request-base-path}//` -* Method: `MOVE` - -=== Request Parameters - -[cols=",,",options="header",] -|=== -|Attribute -|Type -|Description - -|`username` -|string -|The username of the user to list files for. - -|`fileid` -|integer -|The id of the file to delete. -|=== - -=== Request Headers - -[cols="15%,15%,40%,30%",options="header",] -|=== -|Header -|Type -|Value -|Description - -|`Overwrite` -|string -|`F` or `T` -|Whether to overwrite an existing file. - -|`Destination` -|string -|`/remote.php/dav/files//` -|The path where the file will be restored to. -|=== - -=== Code Example - -ifndef::format[] -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/dav/trashbin_api/restore-file-to-trashbin.sh[] ----- --- -==== -endif::[] - -ifeval::["{format}" == "pdf"] -[source,console,subs="attributes+"] ----- -include::example$core/scripts/curl/dav/trashbin_api/restore-file-to-trashbin.sh[] ----- -endif::[] - -=== Returns - -==== Success - -If `Overwrite` is set to `F` and a file with the same name in the specified location does not exist, or if `Overwrite` is set to `T`, an HTTP 204 (No Content) status code will be returned, if the resource is successfully restored. - -==== File Already Exists - -If the `Overwrite` header is set to `F` and a file exists with the same name as specified in the `Destination` string, then an HTTP 412 (Precondition Failed) status code is returned, along with the following XML response: - -[source,xml] ----- - - - Sabre\DAV\Exception\PreconditionFailed - The destination node already exists, and the overwrite header is set to false - Overwrite - ----- - -==== Incorrect Overwrite Header - -If the `Overwrite` header is not set to either `T` or `F`, then an HTTP 400 (Bad Request) status code will be returned, along with the following XML response: - -[source,xml] ----- - - - Sabre\DAV\Exception\BadRequest - The HTTP Overwrite header should be either T or F - ----- - -==== Destination Directory Does Not Exist - -If the destination directory does not exist, then an HTTP 409 (Conflict) status code will be returned, along with the following XML response: - -[source,xml] ----- - - - Sabre\DAV\Exception\Conflict - The destination node is not found - ----- - diff --git a/content/server/10.15/modules/developer_manual/partials/app/fundamentals/complete-info.xml b/content/server/10.15/modules/developer_manual/partials/app/fundamentals/complete-info.xml deleted file mode 100644 index 2708710..0000000 --- a/content/server/10.15/modules/developer_manual/partials/app/fundamentals/complete-info.xml +++ /dev/null @@ -1,85 +0,0 @@ - - - - yourapp - Your App - A description of your application - 1.0 - AGPL - https://raw.githubusercontent.com/foo/yourapp/master/screenshots/big.png - - A category for the application. - A summary of your application's purpose (max 90 chars) - - - - - - - https://doc.owncloud.com/webui/next/classic_ui/pim/index.html - https://doc.owncloud.com/server/latest/admin_manual/configuration_server/occ_command.html?highlight=contact#dav-commands - https://github.com/owncloud/contacts/blob/master/README.md - - - Your Name - YourAppNamespace - https://owncloud.com - https://github.com/owncloud/yourapp/issues - https://github.com/owncloud/yourapp.git - - - - sqlite - mysql - grep - notepad.exe - xml - intl - curl - Linux - - - - - - OCA\YourAppNamespace\FilesEncryption\Migration\Install - - - OCA\YourAppNamespace\FilesEncryption\Migration\PreMigration - - - OCA\YourAppNamespace\FilesEncryption\Migration\PostMigration - - - OCA\YourAppNamespace\FilesEncryption\Migration\LiveMigration - - - OCA\YourAppNamespace\FilesEncryption\Migration\Uninstall - - - - - - OCA\YourAppNamespace\Settings\Admin - OCA\YourAppNamespace\Settings\Personal - - - - - OCA\YourAppNamespace\Settings\AdminSection - OCA\YourAppNamespace\Settings\PersonalSection - - - - - appinfo/caldav.php - - - appinfo/caldav.php - - - - true - - diff --git a/content/server/10.15/modules/developer_manual/partials/nav.adoc b/content/server/10.15/modules/developer_manual/partials/nav.adoc deleted file mode 100644 index efff41b..0000000 --- a/content/server/10.15/modules/developer_manual/partials/nav.adoc +++ /dev/null @@ -1,101 +0,0 @@ -// note that the module reference post xref is now a mandatory element -* Developer Manual -** xref:developer_manual:index.adoc[Introduction] -** xref:developer_manual:general/index.adoc[General Contributor Guidelines] -*** xref:developer_manual:general/code-of-conduct.adoc[Community Code of Conduct] -*** xref:developer_manual:general/codingguidelines.adoc[Coding Style & General Guidelines] -*** xref:developer_manual:general/debugging.adoc[Debugging] -*** xref:developer_manual:general/performance.adoc[Performance Considerations] -*** xref:developer_manual:general/security.adoc[Security Guidelines] -*** xref:developer_manual:general/backporting.adoc[Backporting] -** xref:developer_manual:commun/help_and_communication.adoc[Help and Communication] -** xref:developer_manual:core/index.adoc[Developing ownCloud Core] -*** xref:developer_manual:core/introduction.adoc[Introduction] -*** xref:developer_manual:general/devenv.adoc[Setup Your Development Environment] -*** xref:developer_manual:core/configfile.adoc[Application Configuration] -*** xref:developer_manual:core/theming.adoc[Theming] -*** xref:developer_manual:core/translation.adoc[Translation] -*** xref:developer_manual:core/code-standard.adoc[Code Standards Compliance] -*** xref:developer_manual:testing/index.adoc[Testing] -**** xref:developer_manual:testing/test-pilots.adoc[ownCloud Test Pilots] -**** xref:developer_manual:testing/drone.adoc[Drone Testing] -**** xref:developer_manual:testing/unit-testing.adoc[Unit Testing] -**** xref:developer_manual:testing/acceptance-tests.adoc[Acceptance Tests] -**** xref:developer_manual:testing/ui-testing.adoc[User Interface Testing] -*** xref:developer_manual:core/apis/index.adoc[Available APIs] -**** xref:developer_manual:core/apis/externalapi.adoc[The External API] -**** xref:developer_manual:core/apis/provisioning-api.adoc[The Provisioning API] -**** OCS -***** xref:developer_manual:core/apis/ocs-notification-endpoint-v1.adoc[The OCS Notifications API (v1)] -***** xref:developer_manual:core/apis/ocs-capabilities.adoc[The OCS REST API] -***** xref:developer_manual:core/apis/ocs-recipient-api.adoc[The OCS Recipient API] -***** xref:developer_manual:core/apis/ocs-share-api.adoc[The OCS Share API] -***** xref:developer_manual:core/apis/ocs-totp-validation-api.adoc[The OCS TOTP Validation API] -***** xref:developer_manual:core/apis/ocs-user-sync-api.adoc[The OCS User Sync API] -***** xref:developer_manual:core/apis/ocs-notify-public-link-by-email.adoc[Notify Public Link By Email] -***** xref:developer_manual:core/apis/roles-api.adoc[The Roles API] -**** xref:developer_manual:webdav_api/index.adoc[WebDAV APIs] -***** xref:developer_manual:webdav_api/comments.adoc[The Comments API] -***** xref:developer_manual:webdav_api/groups.adoc[The Custom Groups Management API] -***** xref:developer_manual:webdav_api/files_versions.adoc[The Files Versions API] -***** xref:developer_manual:webdav_api/meta.adoc[The Meta API] -***** xref:developer_manual:webdav_api/search.adoc[The Search API] -***** xref:developer_manual:webdav_api/tags.adoc[The Tags API] -***** xref:developer_manual:webdav_api/trashbin.adoc[The Trash Bin API] -***** xref:developer_manual:webdav_api/public_files.adoc[The Public Files API] -** xref:developer_manual:app/introduction.adoc[Application Development] -*** xref:developer_manual:app/fundamentals/index.adoc[Fundamental Concepts] -**** xref:developer_manual:app/fundamentals/info.adoc[Application Metadata] -**** xref:developer_manual:app/fundamentals/classloader.adoc[The Classloader] -**** xref:developer_manual:app/fundamentals/configuration.adoc[Configuration] -**** xref:developer_manual:app/fundamentals/routes.adoc[Routing] -**** xref:developer_manual:app/fundamentals/controllers.adoc[Controllers] -**** xref:developer_manual:app/fundamentals/templates.adoc[Templates] -**** xref:developer_manual:app/fundamentals/js.adoc[JavaScript] -**** xref:developer_manual:app/fundamentals/css.adoc[CSS] -**** xref:developer_manual:app/fundamentals/middleware.adoc[Middleware] -**** xref:developer_manual:app/fundamentals/database.adoc[Database Connectivity] -**** xref:developer_manual:app/fundamentals/backgroundjobs.adoc[Background Jobs] -**** xref:developer_manual:app/fundamentals/logging.adoc[Logging] -**** xref:developer_manual:app/fundamentals/testing.adoc[Testing] -**** xref:developer_manual:app/fundamentals/container.adoc[The DI Container] -**** xref:developer_manual:app/fundamentals/filesystem.adoc[Filesystem] -**** xref:developer_manual:app/fundamentals/api.adoc[RESTful API] -**** xref:developer_manual:app/fundamentals/hooks.adoc[Hooks] -**** xref:developer_manual:app/fundamentals/publishing.adoc[Publishing in the ownCloud Marketplace] -**** xref:developer_manual:app/fundamentals/changelog.adoc[Changelog] -**** xref:developer_manual:app/fundamentals/market_app.adoc[Market App] -*** xref:developer_manual:app/advanced/index.adoc[Advanced Concepts] -**** xref:developer_manual:app/advanced/custom-cache-backend.adoc[Custom Filesystem Caches] -**** xref:developer_manual:app/advanced/custom-storage-backend.adoc[Custom Storage Backends] -**** xref:developer_manual:app/advanced/notifications.adoc[Notifications] -**** xref:developer_manual:app/advanced/storage-backend.adoc[Storage Backends] -**** xref:developer_manual:app/advanced/extstorage.adoc[External Storage Backends] -**** xref:developer_manual:app/advanced/l10n.adoc[Translation] -**** xref:developer_manual:app/advanced/two-factor-provider.adoc[Two-Factor Providers] -**** xref:developer_manual:app/advanced/users.adoc[User Management] -**** xref:developer_manual:app/advanced/code_signing.adoc[Code Signing] -*** xref:developer_manual:app/tutorial/index.adoc[Tutorial] -**** xref:developer_manual:app/tutorial/requirements.adoc[Minimum Requirements] -**** xref:developer_manual:app/tutorial/request.adoc[The Request Life Cycle] -**** xref:developer_manual:app/tutorial/development_environment.adoc[The Core Application Files] -**** xref:developer_manual:app/tutorial/routes_and_controllers.adoc[Routes and Controllers] -**** xref:developer_manual:app/tutorial/database_connectivity.adoc[Database Connectivity] -**** xref:developer_manual:app/tutorial/template_content.adoc[Create Template Content] -**** xref:developer_manual:app/tutorial/navigation.adoc[Create a Navigation Menu] -**** xref:developer_manual:app/tutorial/javascript_and_css.adoc[Add JavaScript and CSS] -**** xref:developer_manual:app/tutorial/wiring_it_up.adoc[Wiring it Up] -**** xref:developer_manual:app/tutorial/finishing_touches.adoc[Apply the Finishing Touches] -**** xref:developer_manual:app/tutorial/restful_api.adoc[Add a RESTful API] -**** xref:developer_manual:app/tutorial/testing.adoc[Writing Tests] -** xref:developer_manual:mobile_development/index.adoc[Mobile Development] -*** xref:developer_manual:mobile_development/android_library/index.adoc[Android] -**** xref:developer_manual:mobile_development/android_library/library_installation.adoc[Library Installation] -**** xref:developer_manual:mobile_development/android_library/examples.adoc[Examples] -*** xref:developer_manual:mobile_development/ios_library/index.adoc[iOS] -**** xref:developer_manual:mobile_development/ios_library/library_installation.adoc[Library Installation] -**** xref:developer_manual:mobile_development/ios_library/examples.adoc[Examples] -** xref:developer_manual:bugtracker/index.adoc[Bugtracker] -*** xref:developer_manual:bugtracker/codereviews.adoc[Code Reviews] -*** xref:developer_manual:bugtracker/triaging.adoc[Bug Triaging] -** xref:developer_manual:found_a_mistake.adoc[Found a Mistake?] diff --git a/content/server/10.15/modules/developer_manual/partials/section_page.adoc b/content/server/10.15/modules/developer_manual/partials/section_page.adoc deleted file mode 100644 index f764675..0000000 --- a/content/server/10.15/modules/developer_manual/partials/section_page.adoc +++ /dev/null @@ -1,3 +0,0 @@ -= {section-title} - -In this section you will find all the details you need {section-preamble-ender}. diff --git a/content/server/10.15/modules/developer_manual/partials/webdav_api/core_curl_request.adoc b/content/server/10.15/modules/developer_manual/partials/webdav_api/core_curl_request.adoc deleted file mode 100644 index 21e7579..0000000 --- a/content/server/10.15/modules/developer_manual/partials/webdav_api/core_curl_request.adoc +++ /dev/null @@ -1,11 +0,0 @@ -[source,console,subs="attributes+"] ----- -curl --silent \ - -X {request_method} \ -ifdef::request_data_file[] - --data "@{request_data_file}" \ -endif::[] - -u {oc-examples-username}:{oc-examples-password} \ - 'http://localhost/{request_base_path}/{request_path_suffix}' \ - | xmllint --format - ----- diff --git a/content/server/10.15/modules/developer_manual/partials/webdav_api/core_request_details.adoc b/content/server/10.15/modules/developer_manual/partials/webdav_api/core_request_details.adoc deleted file mode 100644 index 6eb9671..0000000 --- a/content/server/10.15/modules/developer_manual/partials/webdav_api/core_request_details.adoc +++ /dev/null @@ -1,13 +0,0 @@ -= Core Details - -[cols=",,",options="header",] -|===================================================== -|Request Path -|Method -|Content Type - -|`{request_path}` -|{method} -|{content_type} -|===================================================== - diff --git a/content/server/10.15/modules/developer_manual/partials/webdav_api/files_versions/list_files_versions.adoc b/content/server/10.15/modules/developer_manual/partials/webdav_api/files_versions/list_files_versions.adoc deleted file mode 100644 index 5818c76..0000000 --- a/content/server/10.15/modules/developer_manual/partials/webdav_api/files_versions/list_files_versions.adoc +++ /dev/null @@ -1,101 +0,0 @@ -= List File Versions -:toc: right -:toclevels: 1 -:content_type: text/xml -:method: PROPFIND -:request-base-path: remote.php/dav/meta/$fileid/v - -== Introduction - -This endpoint lists all versions of a file. - -* Path: `{request-base-path}/` -* Method: `{method}` - -TIP: To retrieve a list of available files, use xref:webdav_api/search.adoc#limiting-returned-file-properties[the Filter Files endpoint], and ensure that returned properties includes `fileid`. - -== Request Parameters - -[cols=",,",options="header",] -|=== -|Attribute -|Type -|Description - -|`fileid` -|integer -|The file's id. -|=== - -== Returns - -If the file _is_ found, then a response similar to the following is returned. - -=== Example Response - -==== File Is Found and Has Only One Version - -If the file _is_ found but has only one version, then a response, similar to the following, is returned, with an `HTTP 207 Multi-Status` status. - -[source,xml] ----- -include::example$core/webdav_api/files_versions/successful-response-which-contains-one-version.xml[] ----- - -==== File Is Found and Has Multiple Versions - -If the file _is_ found and has multiple versions, then a response, similar to the following, is returned, with an `HTTP 207 Multi-Status` status. - -[source,xml] ----- -include::example$core/webdav_api/files_versions/successful-response-which-contains-multiple-versions.xml[] ----- - -==== File Is Not Found - -If the file _is not_ found, then the following response is returned with an `HTTP/1.1 404 Not Found` status. - -[source,xml] ----- - - - Sabre\DAV\Exception\NotFound - - ----- - -== Code Example - -This example retrieves versions with only the essential properties. -If you want to see all properties, don’t use the `--data-binary` option. - -[tabs] -==== -Curl:: -+ --- -[source,console,subs="attributes+"] ----- -curl --silent -v -u {oc-examples-username}:{oc-examples-password} \ - -X PROPFIND \ - -H "Content-Type: text/xml" \ - --data-binary "@search-files-with-filters.xml" \ - '{oc-examples-server-url}/remote.php/dav/meta/44/v' | xmllint --format - ----- --- -==== - -=== search-files-with-filters.xml - -[source,xml] ----- - - - - - - - - - ----- diff --git a/content/server/10.15/modules/developer_manual/partials/webdav_api/responses/insufficient-privileges-overview.adoc b/content/server/10.15/modules/developer_manual/partials/webdav_api/responses/insufficient-privileges-overview.adoc deleted file mode 100644 index 254d746..0000000 --- a/content/server/10.15/modules/developer_manual/partials/webdav_api/responses/insufficient-privileges-overview.adoc +++ /dev/null @@ -1,14 +0,0 @@ -====== Insufficient Privileges or the User is not Authorized - -If the user making the request that only and admin can perform, then a status of `HTTP/1.1 401 Unauthorized` will be returned. - -If the user making the request has insufficient privileges to make the request then a status of `HTTP/1.1 401 Unauthorized` will be returned, along with the following XML in the response’s body: - -[source,xml] ----- - - - Sabre\DAV\Exception\NotAuthenticated - No public access to this resource., Username or password was incorrect, Username or password was incorrect - ----- diff --git a/content/server/10.15/modules/developer_manual/partials/webdav_api/search/common_error_responses.adoc b/content/server/10.15/modules/developer_manual/partials/webdav_api/search/common_error_responses.adoc deleted file mode 100644 index 2a330eb..0000000 --- a/content/server/10.15/modules/developer_manual/partials/webdav_api/search/common_error_responses.adoc +++ /dev/null @@ -1,18 +0,0 @@ -==== If The Payload File Cannot Be Read Or Is Invalid XML - -If the payload file cannot be read or is invalid XML, then the following XML response is sent, along with an `HTTP/1.1 500 Internal Server Error` status code. - -[source,xml] ----- -include::example$core/webdav_api/search/response/common/failure/incorrect_payload_or_parse_failure.xml[indent=0] ----- - -==== If a Non-Existent Property Is Requested - -If a non-existent property is requested, then an additional `propstat` element is returned, as in the example below, which contains a list of the properties which were not available. - -[source,xml] ----- -include::example$core/webdav_api/search/response/common/failure/request_non_existent_property.xml[indent=0,lines=19..25] ----- - diff --git a/content/server/10.15/modules/developer_manual/partials/webdav_api/search/file_properties.adoc b/content/server/10.15/modules/developer_manual/partials/webdav_api/search/file_properties.adoc deleted file mode 100644 index 639fdeb..0000000 --- a/content/server/10.15/modules/developer_manual/partials/webdav_api/search/file_properties.adoc +++ /dev/null @@ -1,81 +0,0 @@ -// Page attributes -:page-partial: - -.Available File Properties -[cols="1,3,2",options="header",] -|=== -|Property -|Description -|Namespace - -|getcontentlength -|The file's content length. -This is only sent for files, not for folders and collections. -Refer to the `size` property for folders and collections. -|`DAV` - -|getcontenttype -|The file's content type. -|`DAV` - -|getetag -|The file's ETag -|`DAV` - -|getlastmodified -|The last modified date of the file -|`DAV` - -|lockdiscovery -| Supports the "_persistent file locking_" backend feature. -For more information on this property, please refer to https://tools.ietf.org/html/rfc4918#section-6.8[the W3C spec]. -|`DAV` - -|resourcetype -|The resource's type. If the resource is a folder, then the value is set to `collection`, otherwise, no value is returned. -|`DAV` - -|comments-unread -|The number of comments on the item that have yet to be read. -|`\http://owncloud.org/ns` - -|favorite -|Indicates whether the file has been favorited or not -|`\http://owncloud.org/ns` - -|fileid -|The id of the file -|`\http://owncloud.org/ns` - -|owner-display-name -|The display name of the file owner -|`\http://owncloud.org/ns` - -|owner-id -|The id of the file owner -|`\http://owncloud.org/ns` - -|permissions -|The permissions set on the file -|`\http://owncloud.org/ns` - -|share-types -a|It is an OC-specific property which summarizes what outgoing share types are applied to the current item. -The share type values are: - -* `0`: user share -* `1`: group share -* `3`: link shares -|`\http://owncloud.org/ns` - -|size -|The size of a folder or collection. -This property is not returned for files. -Refer to the `getcontentlength` property for folders and collections. -|`\http://owncloud.org/ns` - -|tags -|A collection of tags that have been added to the file. -|`\http://owncloud.org/ns` - -|=== diff --git a/content/server/10.15/modules/developer_manual/partials/webdav_api/uri_request_table.adoc b/content/server/10.15/modules/developer_manual/partials/webdav_api/uri_request_table.adoc deleted file mode 100644 index 47c636e..0000000 --- a/content/server/10.15/modules/developer_manual/partials/webdav_api/uri_request_table.adoc +++ /dev/null @@ -1,9 +0,0 @@ -[cols="25%,75%",options="header,autowidth"] -|=== -|URI -|Request Type - -|`{request_method}` -|`{request_base_path}/{request_path_suffix}` -|=== - diff --git a/content/server/10.15/modules/notes_for_the_navigation_file_nav.txt b/content/server/10.15/modules/notes_for_the_navigation_file_nav.txt deleted file mode 100644 index f86388b..0000000 --- a/content/server/10.15/modules/notes_for_the_navigation_file_nav.txt +++ /dev/null @@ -1,13 +0,0 @@ -The navigation files have been relocated and are accessed differently now. - -The main nav.adoc file is in ROOT and includes all nav.adoc files from the modules. To do so, the modules nav.adoc files needed to be relocated from: - -{modulesdir}/nav.adoc -to -{modulesdir}/partials/nav.adoc - -This is due to the fact that "Antora does not classify files located at the root of the module or in the modules folder" which means, there is no access path to a nav.adoc file which is located in the root of a module. - -As a result, the antora.yml file only contains the main ROOT/nav.adoc file. - -This is beneficial, as we now can structure products and their content in a better way. diff --git a/extension-tests/go-redirect.test.js b/extension-tests/go-redirect.test.js index 5d03fa9..4bec1a0 100644 --- a/extension-tests/go-redirect.test.js +++ b/extension-tests/go-redirect.test.js @@ -40,7 +40,7 @@ test('a user key redirects into the classic_ui module', () => { test('a published version segment is preserved for per-version fidelity', () => { // `latest` and `next` are served redirect trees, so they are preserved too: the // stub the go.php link lands on carries the reader on to the real version. - for (const v of ['10.15', '10.16', '11.0', 'latest', 'next']) { + for (const v of ['10.16', '11.0', 'latest', 'next']) { const p = `/owncloud-docs-monorepo/server/${v}/` assert.equal( resolveGoPhp(p + 'go.php', '?to=admin-sharing'), diff --git a/sync/manifest.yml b/sync/manifest.yml index 3a9fc08..09fe888 100644 --- a/sync/manifest.yml +++ b/sync/manifest.yml @@ -48,7 +48,6 @@ repos: - name: docs-server url: https://github.com/owncloud/docs-server.git mappings: - - { branch: '10.15', dest: content/server/10.15 } - { branch: '10.16', dest: content/server/10.16 } # no 11.0 release branch upstream yet -- master still is the 11.0 line - { branch: master, dest: content/server/11.0 } diff --git a/ui/supplemental/js/go-redirect.js b/ui/supplemental/js/go-redirect.js index 5768fea..a995c1c 100644 --- a/ui/supplemental/js/go-redirect.js +++ b/ui/supplemental/js/go-redirect.js @@ -51,7 +51,7 @@ // the sitemap keep-set both derive `latest` automatically from // component.latest. The unit tests fail the build if this list drifts from // the published server segments. - var PUBLISHED_VERSIONS = ['10.15', '10.16', '11.0', 'latest', 'next'] + var PUBLISHED_VERSIONS = ['10.16', '11.0', 'latest', 'next'] // key -> path relative to the version root (…/server//). var MAPPING = { diff --git a/ui/supplemental/ui.yml b/ui/supplemental/ui.yml index 915a632..e2d4f23 100644 --- a/ui/supplemental/ui.yml +++ b/ui/supplemental/ui.yml @@ -9,8 +9,8 @@ # see: https://docs.antora.org/antora-ui-default/static-files/ # # llms.txt (https://llmstxt.org/) pins the version of every page it links to, so -# its links need updating on a release rollover -- test/static-files.test.js fails -# the build while they are stale. +# its links need updating on a release rollover -- +# extension-tests/static-files.test.js fails the build while they are stale. static_files: - robots.txt - llms.txt