https://oxpedia.org/wiki/api.php?action=feedcontributions&user=Frank.de-bruijcker&feedformat=atomOpen-Xchange - User contributions [en]2024-03-29T07:15:37ZUser contributionsMediaWiki 1.31.0https://oxpedia.org/wiki/index.php?title=AppSuite:Filestorages&diff=23888AppSuite:Filestorages2018-03-23T10:08:15Z<p>Frank.de-bruijcker: /* Configuration */</p>
<hr />
<div>= Common preparations =<br />
This page shows how to setup external file stores. For all of these file stores you have to install the package "open-xchange-oauth", which provides the necessary authentication mechanisms.<br />
<br />
Moreover your setup is required to be reachable via HTTPS, since the providers expect that a call-back URL to your setup is specified. Such a call-back URL is only accepted if it contains the <source enclose="none" lang="java">"https://"</source> scheme., e.g.:<br />
<syntaxhighlight lang="java"><br />
"https://my.oxsetup.invalid/ajax/defer"<br />
</syntaxhighlight><br />
<br />
== Keep HTTPS protocol ==<br />
[[Appsuite:Grizzly#Cluster_setup]] shows that HTTPS communication is terminated by the Apache balancer in front of the Open-Xchange nodes. To let the Open-Xchange application know about the HTTPS protocol that is used to communicate with the Apache server:<br />
* Either set a special header in the SSL virtual hosts configurations in Apache to forward this information. The de facto standard for this is the <source enclose="none" lang="java">"X-Forwarded-Proto"</source> header. See [[Appsuite:Grizzly#X-FORWARDED-PROTO_Header]] for how to setup that header.<br />
* Or force the Open-Xchange application to assume it is reached via SSL through setting property <source enclose="none" lang="properties">"com.openexchange.forceHTTPS=true"</source> in file ''/opt/open-xchange/etc/server.properties''.<br />
<br />
== Deferrer URL ==<br />
Open-Xchange application uses the deferrer URL as call-back for some of the providers, which use OAuth v2.0 authentication (such as Google).<br />
<br />
If your OX server is reachable only via one host name, you won't have to do anything. If it is reachable by more than one host name, create or open the file ''/opt/openexchange/etc/deferrer.properties'' and set the properties therein as such:<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.http.deferrer.url=https://mymaindomain.invalid<br />
</syntaxhighlight><br />
<br />
= Dropbox =<br />
<br />
To setup the Dropbox file store you have to install the package "open-xchange-file-storage-dropbox".<br />
<br />
== Registering your app ==<br />
* Log in to your Dropbox account [https://www.dropbox.com/login here], and create your Dropbox app [https://www.dropbox.com/developers/apps/create here]<br />
* There are two options available creating an app, Drops-in App & Dropbox API App. Please select '''Dropbox API''' app and enter the name of your app.<br />
* Go to [https://www.dropbox.com/developers/apps App Console] and select your created app. Select settings tab to view the <source enclose="none" lang="java">APP_KEY</source> (App key) and <source enclose="none" lang="java">SECRET_KEY</source> (App secret) and to configure the redirect URI to your AppSuite platform under the Oauth2 section. All the other fields can keep their default value.<br />
* Please ensure the following conditions are met for the redirect URI:<br />
** The redirect URI uses <source enclose="none" lang="java">"https://"</source> as protocol<br />
** The redirect URI follows the pattern: <source enclose="none" lang="java">"https://" + <host-name> + "/ajax/defer"</source><br />
** E.g. <source enclose="none" lang="java">"https://myappsuite.mydomain.invalid/ajax/defer"</source><br />
<br><br />
<br />
== Configuration ==<br />
In addition you have to configure the following properties in file ''/opt/open-xchange/etc/dropboxoauth.properties'':<br />
<br />
* Enable the OAuth connector to Dropbox OAuth<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.dropbox=true<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the API key and secret<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.dropbox.apiKey=REPLACE_THIS_WITH_DROPBOX_APP_KEY<br />
com.openexchange.oauth.dropbox.apiSecret=REPLACE_THIS_WITH_DROPBOX_APP_SECRET<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the redirect URL. Please ensure the use the same URL as specified in the Dropbox App:<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.dropbox.redirectUrl=<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the product ID of the registered Dropbox app<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.dropbox.productName=<br />
</syntaxhighlight><br />
<br><br />
<br />
You can define them system-wide or via the config cascade mechanism.<br />
<br />
{{InstallPlugin|pluginname=open-xchange-file-storage-dropbox|toplevel=products|sopath=appsuite/stable/backend|version=App Suite}}<br />
<br />
= Google Drive = <br />
<br />
To setup the Google Drive file store you have to install the package "open-xchange-file-storage-googledrive".<br />
<br />
== Registering your app ==<br />
* Sign in to [https://console.developers.google.com/ Google Developers Console] using your Google account<br />
* Please follow [https://developers.google.com/identity/sign-in/web/devconsole-project these] instructions to create a new project with a client ID, which is needed to call the sign-in API<br />
* Enable the following APIs for your project<br />
** BigQuery API<br />
** Calendar API<br />
** Contacts API<br />
** Drive API<br />
** Drive SDK<br />
** Gmail API<br />
** Google Cloud SQL<br />
** Google Cloud Storage<br />
** Google Cloud Storage JSON API<br />
* perform [https://support.google.com/webmasters/answer/35179 Google's site verification]<br />
** you can use any method listed by Google in general<br />
** in case our OXaaS offering is used the HTML tag and HTML file methods are not accessible but the DNS based approach is required<br />
* [[AppSuite:GoogleAppVerification|get your app verified by Google]] to avoid awkward warnings<br />
<br />
== Configuration ==<br />
In addition you have to configure the following properties in file ''/opt/open-xchange/etc/googleoauth.properties'':<br />
<br />
* Enable the OAuth connector to Google OAuth<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.google=true<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the API key and secret, which is Client ID and Client Secret to call the sign-in API (Select your project, select API manager from upper left burger menu, select credentials in left side bar, select Client ID for Web application)<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.google.apiKey=REPLACE_THIS_WITH_YOUR_CLIENT_ID<br />
com.openexchange.oauth.google.apiSecret=REPLACE_THIS_WITH_YOUR_CLIENT_SECRET<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the redirect URL. Please ensure the following conditions are met:<br />
** The redirect URL specified in the Google App needs to be the same as the one specified by this property.<br />
** The redirect URI uses <source enclose="none" lang="java">"https://"</source> as protocol<br />
** The redirect URI follows the pattern: <source enclose="none" lang="java">"https://" + <host-name> + "/ajax/defer"</source><br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.google.redirectUrl=<br />
</syntaxhighlight><br />
E.g. <source enclose="none" lang="java">"https://myappsuite.mydomain.invalid/ajax/defer"</source><br />
<br><br />
<br />
* Set the product ID of the registered Google app<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.google.productName=<br />
</syntaxhighlight><br />
<br><br />
<br />
You can define them system-wide or via the config cascade mechanism.<br />
<br />
{{InstallPlugin|pluginname=open-xchange-file-storage-googledrive|toplevel=products|sopath=appsuite/stable/backend|version=App Suite}}<br />
<br />
= Microsoft Onedrive =<br />
To setup the Microsoft OneDrive file store you have to install the package "open-xchange-file-storage-onedrive".<br />
<br />
== Registering your app ==<br />
* Please follow [https://msdn.microsoft.com/en-us/library/ff751474.aspx this guide] to create/register your app<br />
<br />
== Configuration ==<br />
In addition you have to configure the following properties in file ''/opt/open-xchange/etc/msliveconntectoauth.properties'':<br />
<br />
* Enable the OAuth connector<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.msliveconnect=true<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the API key and secret<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.msliveconnect.apiKey=REPLACE_THIS_WITH_YOUR_MS_LIVE_CONNECT_CLIENT_KEY<br />
com.openexchange.oauth.msliveconnect.apiSecret=REPLACE_THIS_WITH_YOUR_MS_LIVE_CONNECT_CLIENT_SECRET<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the redirect URL<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.msliveconnect.redirectUrl=REPLACE_THIS_WITH_YOUR_MS_LIVE_CONNECT_REDIRECT_URL<br />
</syntaxhighlight><br />
<br><br />
<br />
You can define them system-wide or via the config cascade mechanism.<br />
<br />
{{InstallPlugin|pluginname=open-xchange-file-storage-onedrive|toplevel=products|sopath=appsuite/stable/backend|version=App Suite}}<br />
<br />
= Box.com = <br />
To setup the Box.com file store you have to install the package "open-xchange-file-storage-boxcom".<br />
<br />
== Registering your app ==<br />
* Sign in to [https://developers.box.com/ box Developers]<br />
* Select '''Create a Box Application'''<br />
* Select '''Box Content'''<br />
* Hit '''Configure your application'''<br />
* Enter ''redirect_uri''' (the deferrer URL; e.g. <source enclose="none" lang="java">"https://my.oxsetup.invalid/ajax/defer"</source>)<br />
* Enable ''Read and write all files and folders''<br />
<br />
== Configuration ==<br />
In addition you have to configure the following properties in file ''/opt/open-xchange/etc/boxcomoauth.properties'':<br />
<br />
* Enable the OAuth connector<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.boxcom=true<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the API key and secret<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.boxcom.apiKey=REPLACE_THIS_WITH_YOUR_BOX_CLIENT_KEY<br />
com.openexchange.oauth.boxcom.apiSecret=REPLACE_THIS_WITH_YOUR_BOX_CLIENT_SECRET<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the redirect URL<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.boxcom.redirectUrl=REPLACE_THIS_WITH_YOUR_BOX_REDIRECT_URL<br />
</syntaxhighlight><br />
<br><br />
<br />
You can define them system-wide or via the config cascade mechanism.<br />
<br />
{{InstallPlugin|pluginname=open-xchange-file-storage-boxcom|toplevel=products|sopath=appsuite/stable/backend|version=App Suite}}</div>Frank.de-bruijckerhttps://oxpedia.org/wiki/index.php?title=AppSuite:Filestorages&diff=23887AppSuite:Filestorages2018-03-23T10:08:05Z<p>Frank.de-bruijcker: /* Registering your app */</p>
<hr />
<div>= Common preparations =<br />
This page shows how to setup external file stores. For all of these file stores you have to install the package "open-xchange-oauth", which provides the necessary authentication mechanisms.<br />
<br />
Moreover your setup is required to be reachable via HTTPS, since the providers expect that a call-back URL to your setup is specified. Such a call-back URL is only accepted if it contains the <source enclose="none" lang="java">"https://"</source> scheme., e.g.:<br />
<syntaxhighlight lang="java"><br />
"https://my.oxsetup.invalid/ajax/defer"<br />
</syntaxhighlight><br />
<br />
== Keep HTTPS protocol ==<br />
[[Appsuite:Grizzly#Cluster_setup]] shows that HTTPS communication is terminated by the Apache balancer in front of the Open-Xchange nodes. To let the Open-Xchange application know about the HTTPS protocol that is used to communicate with the Apache server:<br />
* Either set a special header in the SSL virtual hosts configurations in Apache to forward this information. The de facto standard for this is the <source enclose="none" lang="java">"X-Forwarded-Proto"</source> header. See [[Appsuite:Grizzly#X-FORWARDED-PROTO_Header]] for how to setup that header.<br />
* Or force the Open-Xchange application to assume it is reached via SSL through setting property <source enclose="none" lang="properties">"com.openexchange.forceHTTPS=true"</source> in file ''/opt/open-xchange/etc/server.properties''.<br />
<br />
== Deferrer URL ==<br />
Open-Xchange application uses the deferrer URL as call-back for some of the providers, which use OAuth v2.0 authentication (such as Google).<br />
<br />
If your OX server is reachable only via one host name, you won't have to do anything. If it is reachable by more than one host name, create or open the file ''/opt/openexchange/etc/deferrer.properties'' and set the properties therein as such:<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.http.deferrer.url=https://mymaindomain.invalid<br />
</syntaxhighlight><br />
<br />
= Dropbox =<br />
<br />
To setup the Dropbox file store you have to install the package "open-xchange-file-storage-dropbox".<br />
<br />
== Registering your app ==<br />
* Log in to your Dropbox account [https://www.dropbox.com/login here], and create your Dropbox app [https://www.dropbox.com/developers/apps/create here]<br />
* There are two options available creating an app, Drops-in App & Dropbox API App. Please select '''Dropbox API''' app and enter the name of your app.<br />
* Go to [https://www.dropbox.com/developers/apps App Console] and select your created app. Select settings tab to view the <source enclose="none" lang="java">APP_KEY</source> (App key) and <source enclose="none" lang="java">SECRET_KEY</source> (App secret) and to configure the redirect URI to your AppSuite platform under the Oauth2 section. All the other fields can keep their default value.<br />
* Please ensure the following conditions are met for the redirect URI:<br />
** The redirect URI uses <source enclose="none" lang="java">"https://"</source> as protocol<br />
** The redirect URI follows the pattern: <source enclose="none" lang="java">"https://" + <host-name> + "/ajax/defer"</source><br />
** E.g. <source enclose="none" lang="java">"https://myappsuite.mydomain.invalid/ajax/defer"</source><br />
<br><br />
<br />
== Configuration ==<br />
In addition you have to configure the following properties in file ''/opt/open-xchange/etc/dropboxoauth.properties'':<br />
<br />
* Enable the OAuth connector to Dropbox OAuth<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.dropbox=true<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the API key and secret<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.dropbox.apiKey=REPLACE_THIS_WITH_DROPBOX_APP_KEY<br />
com.openexchange.oauth.dropbox.apiSecret=REPLACE_THIS_WITH_DROPBOX_APP_SECRET<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the redirect URL. Please ensure the following conditions are met:<br />
** The redirect URL specified in the Dropbox App needs to be the same as the one specified by this property.<br />
** The redirect URI uses <source enclose="none" lang="java">"https://"</source> as protocol<br />
** The redirect URI follows the pattern: <source enclose="none" lang="java">"https://" + <host-name> + "/ajax/defer"</source><br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.dropbox.redirectUrl=<br />
</syntaxhighlight><br />
E.g. <source enclose="none" lang="java">"https://myappsuite.mydomain.invalid/ajax/defer"</source><br />
<br><br />
<br />
* Set the product ID of the registered Dropbox app<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.dropbox.productName=<br />
</syntaxhighlight><br />
<br><br />
<br />
You can define them system-wide or via the config cascade mechanism.<br />
<br />
{{InstallPlugin|pluginname=open-xchange-file-storage-dropbox|toplevel=products|sopath=appsuite/stable/backend|version=App Suite}}<br />
<br />
= Google Drive = <br />
<br />
To setup the Google Drive file store you have to install the package "open-xchange-file-storage-googledrive".<br />
<br />
== Registering your app ==<br />
* Sign in to [https://console.developers.google.com/ Google Developers Console] using your Google account<br />
* Please follow [https://developers.google.com/identity/sign-in/web/devconsole-project these] instructions to create a new project with a client ID, which is needed to call the sign-in API<br />
* Enable the following APIs for your project<br />
** BigQuery API<br />
** Calendar API<br />
** Contacts API<br />
** Drive API<br />
** Drive SDK<br />
** Gmail API<br />
** Google Cloud SQL<br />
** Google Cloud Storage<br />
** Google Cloud Storage JSON API<br />
* perform [https://support.google.com/webmasters/answer/35179 Google's site verification]<br />
** you can use any method listed by Google in general<br />
** in case our OXaaS offering is used the HTML tag and HTML file methods are not accessible but the DNS based approach is required<br />
* [[AppSuite:GoogleAppVerification|get your app verified by Google]] to avoid awkward warnings<br />
<br />
== Configuration ==<br />
In addition you have to configure the following properties in file ''/opt/open-xchange/etc/googleoauth.properties'':<br />
<br />
* Enable the OAuth connector to Google OAuth<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.google=true<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the API key and secret, which is Client ID and Client Secret to call the sign-in API (Select your project, select API manager from upper left burger menu, select credentials in left side bar, select Client ID for Web application)<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.google.apiKey=REPLACE_THIS_WITH_YOUR_CLIENT_ID<br />
com.openexchange.oauth.google.apiSecret=REPLACE_THIS_WITH_YOUR_CLIENT_SECRET<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the redirect URL. Please ensure the following conditions are met:<br />
** The redirect URL specified in the Google App needs to be the same as the one specified by this property.<br />
** The redirect URI uses <source enclose="none" lang="java">"https://"</source> as protocol<br />
** The redirect URI follows the pattern: <source enclose="none" lang="java">"https://" + <host-name> + "/ajax/defer"</source><br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.google.redirectUrl=<br />
</syntaxhighlight><br />
E.g. <source enclose="none" lang="java">"https://myappsuite.mydomain.invalid/ajax/defer"</source><br />
<br><br />
<br />
* Set the product ID of the registered Google app<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.google.productName=<br />
</syntaxhighlight><br />
<br><br />
<br />
You can define them system-wide or via the config cascade mechanism.<br />
<br />
{{InstallPlugin|pluginname=open-xchange-file-storage-googledrive|toplevel=products|sopath=appsuite/stable/backend|version=App Suite}}<br />
<br />
= Microsoft Onedrive =<br />
To setup the Microsoft OneDrive file store you have to install the package "open-xchange-file-storage-onedrive".<br />
<br />
== Registering your app ==<br />
* Please follow [https://msdn.microsoft.com/en-us/library/ff751474.aspx this guide] to create/register your app<br />
<br />
== Configuration ==<br />
In addition you have to configure the following properties in file ''/opt/open-xchange/etc/msliveconntectoauth.properties'':<br />
<br />
* Enable the OAuth connector<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.msliveconnect=true<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the API key and secret<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.msliveconnect.apiKey=REPLACE_THIS_WITH_YOUR_MS_LIVE_CONNECT_CLIENT_KEY<br />
com.openexchange.oauth.msliveconnect.apiSecret=REPLACE_THIS_WITH_YOUR_MS_LIVE_CONNECT_CLIENT_SECRET<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the redirect URL<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.msliveconnect.redirectUrl=REPLACE_THIS_WITH_YOUR_MS_LIVE_CONNECT_REDIRECT_URL<br />
</syntaxhighlight><br />
<br><br />
<br />
You can define them system-wide or via the config cascade mechanism.<br />
<br />
{{InstallPlugin|pluginname=open-xchange-file-storage-onedrive|toplevel=products|sopath=appsuite/stable/backend|version=App Suite}}<br />
<br />
= Box.com = <br />
To setup the Box.com file store you have to install the package "open-xchange-file-storage-boxcom".<br />
<br />
== Registering your app ==<br />
* Sign in to [https://developers.box.com/ box Developers]<br />
* Select '''Create a Box Application'''<br />
* Select '''Box Content'''<br />
* Hit '''Configure your application'''<br />
* Enter ''redirect_uri''' (the deferrer URL; e.g. <source enclose="none" lang="java">"https://my.oxsetup.invalid/ajax/defer"</source>)<br />
* Enable ''Read and write all files and folders''<br />
<br />
== Configuration ==<br />
In addition you have to configure the following properties in file ''/opt/open-xchange/etc/boxcomoauth.properties'':<br />
<br />
* Enable the OAuth connector<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.boxcom=true<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the API key and secret<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.boxcom.apiKey=REPLACE_THIS_WITH_YOUR_BOX_CLIENT_KEY<br />
com.openexchange.oauth.boxcom.apiSecret=REPLACE_THIS_WITH_YOUR_BOX_CLIENT_SECRET<br />
</syntaxhighlight><br />
<br><br />
<br />
* Set the redirect URL<br />
<syntaxhighlight lang="properties"><br />
com.openexchange.oauth.boxcom.redirectUrl=REPLACE_THIS_WITH_YOUR_BOX_REDIRECT_URL<br />
</syntaxhighlight><br />
<br><br />
<br />
You can define them system-wide or via the config cascade mechanism.<br />
<br />
{{InstallPlugin|pluginname=open-xchange-file-storage-boxcom|toplevel=products|sopath=appsuite/stable/backend|version=App Suite}}</div>Frank.de-bruijcker