-
Notifications
You must be signed in to change notification settings - Fork 131
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[feature/custom-app-scheme] Custom app/auth schemes (#1060)
* - add support and documentation for DISABLE_APPSTORE_LICENSING build flag * - ReleaseNotesHostViewController: remove unused reference to StoreKit - OCLicenseDuration: make sure SKProductSubscriptionPeriod conversion code is excluded when using the DISABLE_APPSTORE_LICENSING build flag * - add support for app.custom-app-scheme and app.custom-auth-scheme to Fastfile - add documentation for new custom scheme Branding.plist parameters * - remove test values from Branding.plist * - move build options from `app.` space to `build.` space and rename options accordingly - add legacy support for previously used Branding.plist build customization option names - add `BuildOptions` class to `ownCloudApp` framework to make build customization options visible in documentation * - ensure BuildOptions class is actually loaded/initialized * - update Xcode to 12.5.1 for GitHub workflow configuration-documentation.yml * - adapt code in `ImportPasteboardAction.swift` to also compile in Xcode 12.4 * Configuration documentation updated Co-authored-by: felix-schwarz <felix-schwarz@users.noreply.github.com> Co-authored-by: Matthias Hühne <mhuehne@owncloud.com>
- Loading branch information
1 parent
1441c04
commit 7783b40
Showing
10 changed files
with
466 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
# Build Flags | ||
|
||
## Description | ||
|
||
Build Flags can be used to control the inclusion or exclusion of certain functionality or features. | ||
|
||
## Usage in Branding | ||
|
||
A space-separated list of flags can be specified in the `Branding.plist` with the key `build.flags`, f.ex.: | ||
|
||
```xml | ||
<key>build.flags</key> | ||
<string>DISABLE_BACKGROUND_LOCATION</string> | ||
``` | ||
|
||
## Flags | ||
|
||
The following options can be used as `build.flags`: | ||
|
||
### `DISABLE_BACKGROUND_LOCATION` | ||
|
||
Removes the following from the app: | ||
- the option for location-triggered background uploads from Settings | ||
- the location description keys from the app's `Info.plist` | ||
|
||
Not used by default. | ||
|
||
### `DISABLE_APPSTORE_LICENSING` | ||
|
||
Removes the following from the app: | ||
- App Store integration for OCLicense | ||
- App Store related view controllers and settings section | ||
|
||
|
||
# Custom Schemes | ||
|
||
## Description | ||
|
||
The app uses two URL schemes: | ||
- `oc` for authentication | ||
- `owncloud` for private links | ||
|
||
Both schemes are part of the app's `Info.plist`, which can only be changed at build time. | ||
|
||
## Usage in Branding | ||
|
||
### Private Links | ||
|
||
The default `owncloud` app URL scheme in `Info.plist` can be changed by providing an alternative scheme name in the `Branding.plist` with the key `build.custom-app-scheme`, f.ex.: | ||
|
||
```xml | ||
<key>build.custom-app-scheme</key> | ||
<string>myscheme</string> | ||
``` | ||
|
||
### Authentication | ||
|
||
The default `oc` app URL scheme in `Info.plist` can be changed by providing an alternative scheme name in the `Branding.plist` with the key `build.custom-auth-scheme`, f.ex.: | ||
|
||
```xml | ||
<key>build.custom-auth-scheme</key> | ||
<string>ms</string> | ||
``` | ||
|
||
The change in the `Info.plist` is only necessary when an external browser is used for authentication via OAuth2 or OIDC. In that case, the scheme must also be changed in the regular options for OIDC and OAuth2 authentication methods: | ||
|
||
```xml | ||
<key>authentication-oauth2.oa2-redirect-uri</key> | ||
<string>ms://ios.owncloud.com</string> | ||
<key>authentication-oauth2.oidc-redirect-uri</key> | ||
<string>ms://ios.owncloud.com</string> | ||
``` | ||
|
||
Depending on OAuth2 and OIDC implementation on the server side: | ||
- it may be necessary to also adapt the registered redirect URI on the server | ||
- authentication could fail if not adapted on the server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.