diff --git a/Makefile b/Makefile index 96c206e9221..713df05b219 100644 --- a/Makefile +++ b/Makefile @@ -136,12 +136,12 @@ docker-services: $(MAKE) -C services/nginz docker DOCKER_DEV_NETWORK := --net=host -DOCKER_DEV_VOLUMES := -v `pwd`:/src/wire-server +DOCKER_DEV_VOLUMES := -v `pwd`:/wire-server DOCKER_DEV_IMAGE := quay.io/wire/alpine-builder:$(DOCKER_TAG) .PHONY: run-docker-builder run-docker-builder: @echo "if this does not work, consider 'docker pull', 'docker tag', or 'make -C build-alpine builder'." - docker run -it $(DOCKER_DEV_NETWORK) $(DOCKER_DEV_VOLUMES) --rm $(DOCKER_DEV_IMAGE) /bin/bash + docker run --workdir /wire-server -it $(DOCKER_DEV_NETWORK) $(DOCKER_DEV_VOLUMES) --rm $(DOCKER_DEV_IMAGE) /bin/bash ################################# ## dependencies diff --git a/README.md b/README.md index af5c05aa752..911c1ae46d7 100644 --- a/README.md +++ b/README.md @@ -69,7 +69,7 @@ The following diagram gives a high-level outline of the (deployment) architectur of the components that make up a Wire Server as well as the main internal and external dependencies between components. -![wire-arch](doc/arch/wire-arch-2.png) +![wire-arch](docs/developer/architecture/wire-arch-2.png) Communication between internal components is currently not guarded by dedicated authentication or encryption and is assumed to be confined to a @@ -88,7 +88,7 @@ This requires a range of dependencies that depend on your platform/OS, such as: - Haskell & Rust compiler and package managers - Some package dependencies (libsodium, openssl, protobuf, icu, geoip, snappy, [cryptobox-c](https://github.com/wireapp/cryptobox-c), ...) that depend on your platform/OS -See [doc/Dependencies.md](doc/Dependencies.md) for details. +See [docs/developer/dependencies.md](docs/developer/dependencies.md) for details. Once all dependencies are set up, the following should succeed: diff --git a/build/alpine/Dockerfile.builder b/build/alpine/Dockerfile.builder index 84331c5b85d..f0b03bf2aa2 100644 --- a/build/alpine/Dockerfile.builder +++ b/build/alpine/Dockerfile.builder @@ -3,7 +3,7 @@ ARG prebuilder=quay.io/wire/alpine-prebuilder FROM ${prebuilder} -WORKDIR /src/wire-server +WORKDIR / # Download stack indices and compile/cache dependencies to speed up subsequent # container creation. @@ -16,23 +16,13 @@ WORKDIR /src/wire-server # to avoid a Haddock segfault. See https://github.com/haskell/haddock/issues/928 RUN apk add --no-cache git ncurses && \ - mkdir -p /src && cd /src && \ git clone -b develop https://github.com/wireapp/wire-server.git && \ - cd wire-server && \ + cd /wire-server && \ stack update && \ - echo "allow-different-user: true" >> /root/.stack/config.yaml && \ - echo >> /root/.stack/config.yaml && \ - echo '# NB: do not touch following line!' >> /root/.stack/config.yaml && \ - echo '# this image is used both for building docker images with the' >> /root/.stack/config.yaml && \ - echo '# integration tests (so they can be run on the ci) and for' >> /root/.stack/config.yaml && \ - echo '# interactive integration testing (with the working copy of the' >> /root/.stack/config.yaml && \ - echo '# host system mounted into the docker container). in the latter' >> /root/.stack/config.yaml && \ - echo '# use case, we want the docker container to write to its own' >> /root/.stack/config.yaml && \ - echo '# stack-work directory and not pollute the one on the host.' >> /root/.stack/config.yaml && \ - echo 'work-dir: .stack-docker' >> /root/.stack/config.yaml && \ - stack --work-dir .stack-docker-profile build --haddock --dependencies-only --profile haskell-src-exts && \ - stack --work-dir .stack-docker build --haddock --dependencies-only haskell-src-exts && \ - stack --work-dir .stack-docker-profile build --haddock --no-haddock-hyperlink-source --profile haskell-src-exts && \ - stack --work-dir .stack-docker build --haddock --no-haddock-hyperlink-source haskell-src-exts && \ - stack --work-dir .stack-docker-profile build --pedantic --haddock --test --no-run-tests --bench --no-run-benchmarks --dependencies-only --profile && \ - stack --work-dir .stack-docker build --pedantic --haddock --test --no-run-tests --bench --no-run-benchmarks --dependencies-only + echo "allow-different-user: true" >> /root/.stack/config.yaml && \ + stack build --haddock --dependencies-only --profile haskell-src-exts && \ + stack build --haddock --no-haddock-hyperlink-source --profile haskell-src-exts && \ + stack build --pedantic --haddock --test --no-run-tests --bench --no-run-benchmarks --dependencies-only --profile && \ + cd / && \ + # we run the build only to cache the built source in /root/.stack, we can remove the source code itself + rm -rf /wire-server diff --git a/build/alpine/Dockerfile.intermediate b/build/alpine/Dockerfile.intermediate index c82a95e8011..de58eb16181 100644 --- a/build/alpine/Dockerfile.intermediate +++ b/build/alpine/Dockerfile.intermediate @@ -12,16 +12,15 @@ ARG deps=quay.io/wire/alpine-deps #--- Builder stage --- FROM ${builder} as builder -# ensure no stale files remain if they get deleted from the branch. -RUN find /src/wire-server/ -maxdepth 1 -mindepth 1 | grep -v .stack- | xargs rm -rf +WORKDIR /wire-server/ -COPY . /src/wire-server/ +COPY . /wire-server/ -RUN cd /src/wire-server && make clean install +RUN make clean install #--- Minified stage --- FROM ${deps} -COPY --from=builder /src/wire-server/dist/ /dist/ +COPY --from=builder /wire-server/dist/ /dist/ # brig also needs some templates. -COPY --from=builder /src/wire-server/services/brig/deb/opt/brig/templates/ /dist/templates/ +COPY --from=builder /wire-server/services/brig/deb/opt/brig/templates/ /dist/templates/ diff --git a/deploy/services-demo/conf/brig.demo-docker.yaml b/deploy/services-demo/conf/brig.demo-docker.yaml index c3a7e14c21b..eac4ee5d100 100644 --- a/deploy/services-demo/conf/brig.demo-docker.yaml +++ b/deploy/services-demo/conf/brig.demo-docker.yaml @@ -95,6 +95,7 @@ optSettings: setUserCookieThrottle: stdDev: 3000 # 50 minutes retryAfter: 86400 # 1 day + setRichInfoLimit: 5000 # should be in sync with Spar setDefaultLocale: en setMaxTeamSize: 128 setMaxConvSize: 128 diff --git a/deploy/services-demo/conf/brig.demo.yaml b/deploy/services-demo/conf/brig.demo.yaml index 05ca1c7d68e..17e3f1a1030 100644 --- a/deploy/services-demo/conf/brig.demo.yaml +++ b/deploy/services-demo/conf/brig.demo.yaml @@ -95,6 +95,7 @@ optSettings: setUserCookieThrottle: stdDev: 3000 # 50 minutes retryAfter: 86400 # 1 day + setRichInfoLimit: 5000 # should be in sync with Spar setDefaultLocale: en setMaxTeamSize: 128 setMaxConvSize: 128 diff --git a/deploy/services-demo/conf/gundeck.demo-docker.yaml b/deploy/services-demo/conf/gundeck.demo-docker.yaml index 3a35a4de5e3..8f83e7ae492 100644 --- a/deploy/services-demo/conf/gundeck.demo-docker.yaml +++ b/deploy/services-demo/conf/gundeck.demo-docker.yaml @@ -24,3 +24,6 @@ settings: httpPoolSize: 1024 notificationTTL: 24192200 bulkPush: false + +logLevel: Info +logNetStrings: false diff --git a/deploy/services-demo/conf/gundeck.demo.yaml b/deploy/services-demo/conf/gundeck.demo.yaml index af3bed79072..7bf823ec6d6 100644 --- a/deploy/services-demo/conf/gundeck.demo.yaml +++ b/deploy/services-demo/conf/gundeck.demo.yaml @@ -24,3 +24,6 @@ settings: httpPoolSize: 1024 notificationTTL: 24192200 bulkPush: false + +logLevel: Info +logNetStrings: false diff --git a/deploy/services-demo/conf/spar.demo-docker.yaml b/deploy/services-demo/conf/spar.demo-docker.yaml index 717c6a61c8d..308b1fa6ba0 100644 --- a/deploy/services-demo/conf/spar.demo-docker.yaml +++ b/deploy/services-demo/conf/spar.demo-docker.yaml @@ -32,5 +32,6 @@ maxttlAuthreq: 28800 # 8h maxttlAuthresp: 28800 # 8h maxScimTokens: 16 +richInfoLimit: 5000 # should be in sync with Brig logNetStrings: False # log using netstrings encoding (see http://cr.yp.to/proto/netstrings.txt) diff --git a/deploy/services-demo/conf/spar.demo.yaml b/deploy/services-demo/conf/spar.demo.yaml index 9db8fc19cf7..d8adfebab22 100644 --- a/deploy/services-demo/conf/spar.demo.yaml +++ b/deploy/services-demo/conf/spar.demo.yaml @@ -32,5 +32,6 @@ maxttlAuthreq: 28800 # 8h maxttlAuthresp: 28800 # 8h maxScimTokens: 16 +richInfoLimit: 5000 # should be in sync with Brig logNetStrings: False # log using netstrings encoding (see http://cr.yp.to/proto/netstrings.txt) diff --git a/deploy/services-demo/demo.sh b/deploy/services-demo/demo.sh index 4fb4eea8ca8..ca4e9a4e82b 100755 --- a/deploy/services-demo/demo.sh +++ b/deploy/services-demo/demo.sh @@ -142,7 +142,7 @@ copy_nginz_configs if [ "$docker_deployment" = "false" ]; then run_haskell_service brig ${green} run_haskell_service galley ${yellow} - run_haskell_service gundeck ${blue} Info + run_haskell_service gundeck ${blue} run_haskell_service cannon ${orange} run_haskell_service cargohold ${purpleish} Info run_haskell_service proxy ${redish} Info diff --git a/doc/arch/wire-arch-2.png b/docs/developer/architecture/wire-arch-2.png similarity index 100% rename from doc/arch/wire-arch-2.png rename to docs/developer/architecture/wire-arch-2.png diff --git a/doc/arch/wire-arch-2.xml b/docs/developer/architecture/wire-arch-2.xml similarity index 100% rename from doc/arch/wire-arch-2.xml rename to docs/developer/architecture/wire-arch-2.xml diff --git a/doc/Dependencies.md b/docs/developer/dependencies.md similarity index 100% rename from doc/Dependencies.md rename to docs/developer/dependencies.md diff --git a/docs/reference/user/rich-info.md b/docs/reference/user/rich-info.md new file mode 100644 index 00000000000..5e08a3258fe --- /dev/null +++ b/docs/reference/user/rich-info.md @@ -0,0 +1,107 @@ +# Rich info {#RefRichInfo} + +_Author: Artyom Kazak_ + +--- + +This page describes a part of the user profile called "Rich info". The corresponding feature is called "Rich profiles". + +## Summary {#RefRichInfoSummary} + +For every team user we can store a list of key-value pairs that are displayed in the user profile. This is similar to "custom profile fields" in Slack and other enterprise messengers. + +Different users can have different sets of fields; there is no team-wide schema for fields. All field values are strings. Fields are passed as an ordered list, and the order information is preserved when displaying fields in client apps. + +Only team members and partners can see the user's rich info. + +## API {#RefRichInfoApi} + +### Querying rich info {#RefRichInfoGet} + +`GET /users/:user/rich-info`. Sample output: + +```json +{ + "version": 0, + "fields": [ + { + "type": "Department", + "value": "Sales & Marketing" + }, + { + "type": "Favorite color", + "value": "Blue" + } + ] +} +``` + +If the requesting user is not allowed to see rich info, error code 403 is returned with the `"insufficient-permissions"` error label. + +Otherwise, if the rich info is missing, an empty field list is returned: + +```json +{ + "version": 0, + "fields": [] +} +``` + +### Setting rich info {#RefRichInfoPut} + +**Not implemented yet.** Currently the only way to set rich info is via SCIM. + +### Events {#RefRichInfoEvents} + +**Not implemented yet.** + +When user's rich info changes, the backend sends out an event to all team members: + +```json +{ + "type": "user.rich-info-update", + "user": { + "id": "" + } +} +``` + +Connected users who are not members of user's team will not receive an event (nor can they query user's rich info by other means). + +## SCIM support {#RefRichInfoScim} + +Rich info can be pushed to Wire by setting the `"richInfo"` field belonging to the `"urn:wire:scim:schemas:profile:1.0"` extension. Both `PUT /scim/v2/Users/:id` and `POST /scim/v2/Users/:id` can contain rich info. Here is an example for `PUT`: + +```javascript +PUT /scim/v2/Users/:id + +{ + ..., + "urn:wire:scim:schemas:profile:1.0": { + "richInfo": [ + { + "type": "Department", + "value": "Sales & Marketing" + }, + { + "type": "Favorite color", + "value": "Blue" + } + ] + } +} +``` + +Rich info set via SCIM can be queried by doing a `GET /scim/v2/Users` or `GET /scim/v2/Users/:id` query. + +### SCIM provisioning agent support {#RefRichInfoScimAgents} + +* Okta: unable to push fields in the format we require (checked on 2019-02-21). + +* OneLogin: likely able to push fields. + +## Limitations {#RefRichInfoLimitations} + +* The whole of user-submitted information (field names and values) cannot exceed 5000 characters in length. There are no limitations on the number of fields, or the maximum of individual field names or values. + +* Field values can not be empty (`""`). If they are empty, the corresponding field will be removed. diff --git a/libs/brig-types/package.yaml b/libs/brig-types/package.yaml index a13d97ec678..064aa0994cb 100644 --- a/libs/brig-types/package.yaml +++ b/libs/brig-types/package.yaml @@ -1,4 +1,4 @@ -defaults: +defaults: local: ../../package-defaults.yaml name: brig-types version: '1.35.0' @@ -46,8 +46,8 @@ library: - bytestring-conversion >=0.2 - containers >=0.5 - currency-codes >=2.0 - - galley-types >=0.45.7 - errors >=1.4 + - galley-types >=0.45.7 - hashable - iproute >=1.5 - iso3166-country-codes >=0.2 @@ -79,6 +79,7 @@ tests: - bytestring - containers - currency-codes + - extra - galley-types - iproute - iso639 diff --git a/libs/brig-types/src/Brig/Types/Swagger.hs b/libs/brig-types/src/Brig/Types/Swagger.hs index 024f15f7f3a..a02e97e3c22 100644 --- a/libs/brig-types/src/Brig/Types/Swagger.hs +++ b/libs/brig-types/src/Brig/Types/Swagger.hs @@ -29,6 +29,8 @@ brigModels = , asset , userHandleInfo , checkHandles + , richInfo + , richField -- User Connections / Invitations , connection @@ -181,6 +183,22 @@ asset = defineModel "UserAsset" $ do property "size" assetSize $ description "The asset size / format" +richField :: Model +richField = defineModel "RichField" $ do + description "RichInfo field" + property "type" string' $ + description "Field name" + property "value" string' $ + description "Field value" + +richInfo :: Model +richInfo = defineModel "RichInfo" $ do + description "Rich info about the user" + property "fields" (array (ref richField)) $ + description "List of fields" + property "version" int32' $ + description "Format version (the current version is 0)" + userName :: Model userName = defineModel "UserName" $ do description "User name" diff --git a/libs/brig-types/src/Brig/Types/User.hs b/libs/brig-types/src/Brig/Types/User.hs index 04a486c8c34..71adb730d89 100644 --- a/libs/brig-types/src/Brig/Types/User.hs +++ b/libs/brig-types/src/Brig/Types/User.hs @@ -17,7 +17,6 @@ import Brig.Types.Activation (ActivationCode) import Brig.Types.Common as C import Brig.Types.User.Auth (CookieLabel) import Data.Aeson -import Data.Aeson.Types (Parser, Pair) import Data.ByteString.Conversion import Data.Id import Data.Json.Util ((#), UTCTimeMillis) @@ -29,8 +28,10 @@ import Galley.Types.Bot (ServiceRef) import Galley.Types.Teams hiding (userId) import qualified Brig.Types.Code as Code +import qualified Data.Aeson.Types as Aeson import qualified Data.Currency as Currency import qualified Data.HashMap.Strict as HashMap +import qualified Data.Text as Text ----------------------------------------------------------------------------- -- User Attributes @@ -40,7 +41,7 @@ newtype Pict = Pict { fromPict :: [Object] } deriving (Eq, Show, ToJSON) instance FromJSON Pict where - parseJSON x = Pict . fromRange <$> (parseJSON x :: Parser (Range 0 10 [Object])) + parseJSON x = Pict . fromRange @0 @10 <$> parseJSON x noPict :: Pict noPict = Pict [] @@ -235,6 +236,79 @@ instance FromJSON SelfProfile where instance ToJSON SelfProfile where toJSON (SelfProfile u) = toJSON u +---------------------------------------------------------------------------- +-- Rich info + +data RichInfo = RichInfo + { richInfoFields :: ![RichField] -- ^ An ordered list of fields + } + deriving (Eq, Show) + +instance ToJSON RichInfo where + toJSON u = object + [ "fields" .= richInfoFields u + , "version" .= (0 :: Int) + ] + +instance FromJSON RichInfo where + parseJSON = withObject "RichInfo" $ \o -> do + version :: Int <- o .: "version" + case version of + 0 -> do + fields <- o .: "fields" + checkDuplicates (map richFieldType fields) + pure (RichInfo fields) + _ -> fail ("unknown version: " <> show version) + where + checkDuplicates :: [Text] -> Aeson.Parser () + checkDuplicates xs = + case filter ((> 1) . length) . group . sort $ xs of + [] -> pure () + ds -> fail ("duplicate fields: " <> show (map head ds)) + +data RichField = RichField + { richFieldType :: !Text + , richFieldValue :: !Text + } + deriving (Eq, Show) + +instance ToJSON RichField where + -- NB: "name" would be a better name for 'richFieldType', but "type" is used because we + -- also have "type" in SCIM; and the reason we use "type" for SCIM is that @{"type": ..., + -- "value": ...}@ is how all other SCIM payloads are formatted, so it's quite possible + -- that some provisioning agent would support "type" but not "name". + toJSON u = object + [ "type" .= richFieldType u + , "value" .= richFieldValue u + ] + +instance FromJSON RichField where + parseJSON = withObject "RichField" $ \o -> do + RichField + <$> o .: "type" + <*> o .: "value" + +-- | Empty rich info, returned for users who don't have rich info set. +emptyRichInfo :: RichInfo +emptyRichInfo = RichInfo + { richInfoFields = [] + } + +-- | Calculate the length of user-supplied data in 'RichInfo'. Used for enforcing +-- 'setRichInfoLimit' +-- +-- NB: we could just calculate the length of JSON-encoded payload, but it is fragile because +-- if our JSON encoding changes, existing payloads might become unacceptable. +richInfoSize :: RichInfo -> Int +richInfoSize (RichInfo fields) = + sum [Text.length t + Text.length v | RichField t v <- fields] + +-- | Remove fields with @""@ values. +normalizeRichInfo :: RichInfo -> RichInfo +normalizeRichInfo RichInfo{..} = RichInfo + { richInfoFields = filter (not . Text.null . richFieldValue) richInfoFields + } + ----------------------------------------------------------------------------- -- New Users @@ -265,7 +339,7 @@ data NewUserOrigin = deriving (Eq, Show) parseNewUserOrigin :: Maybe PlainTextPassword -> Maybe UserIdentity -> Maybe UserSSOId - -> Object -> Parser (Maybe NewUserOrigin) + -> Object -> Aeson.Parser (Maybe NewUserOrigin) parseNewUserOrigin pass uid ssoid o = do invcode <- o .:? "invitation_code" teamcode <- o .:? "team_code" @@ -284,7 +358,7 @@ parseNewUserOrigin pass uid ssoid o = do (Just (NewUserOriginTeamUser _), Nothing, _) -> fail "all team users must set a password on creation" _ -> pure result -jsonNewUserOrigin :: NewUserOrigin -> [Pair] +jsonNewUserOrigin :: NewUserOrigin -> [Aeson.Pair] jsonNewUserOrigin = \case NewUserOriginInvitationCode inv -> ["invitation_code" .= inv] NewUserOriginTeamUser (NewTeamMember tc) -> ["team_code" .= tc] @@ -353,7 +427,7 @@ instance ToJSON NewUser where # maybe [] jsonNewUserOrigin (newUserOrigin u) -- | Fails if email or phone or ssoid are present but invalid -parseIdentity :: Maybe UserSSOId -> Object -> Parser (Maybe UserIdentity) +parseIdentity :: Maybe UserSSOId -> Object -> Aeson.Parser (Maybe UserIdentity) parseIdentity ssoid o = if isJust (HashMap.lookup "email" o <|> HashMap.lookup "phone" o) || isJust ssoid then Just <$> parseJSON (Object o) else pure Nothing @@ -431,6 +505,7 @@ newtype EmailUpdate = EmailUpdate { euEmail :: Email } deriving (Eq, Show) newtype PhoneUpdate = PhoneUpdate { puPhone :: Phone } deriving (Eq, Show) newtype HandleUpdate = HandleUpdate { huHandle :: Text } deriving (Eq, Show) newtype ManagedByUpdate = ManagedByUpdate { mbuManagedBy :: ManagedBy } deriving (Eq, Show) +newtype RichInfoUpdate = RichInfoUpdate { riuRichInfo :: RichInfo } deriving (Eq, Show) newtype EmailRemove = EmailRemove { erEmail :: Email } deriving (Eq, Show) newtype PhoneRemove = PhoneRemove { prPhone :: Phone } deriving (Eq, Show) @@ -488,6 +563,13 @@ instance FromJSON ManagedByUpdate where instance ToJSON ManagedByUpdate where toJSON m = object ["managed_by" .= mbuManagedBy m] +instance FromJSON RichInfoUpdate where + parseJSON = withObject "rich-info-update" $ \o -> + RichInfoUpdate <$> o .: "rich_info" + +instance ToJSON RichInfoUpdate where + toJSON m = object ["rich_info" .= riuRichInfo m] + instance FromJSON EmailRemove where parseJSON = withObject "email-remove" $ \o -> EmailRemove <$> o .: "email" diff --git a/libs/brig-types/test/unit/Test/Brig/Types/Arbitrary.hs b/libs/brig-types/test/unit/Test/Brig/Types/Arbitrary.hs index 1ae3818f307..e80b94bec7f 100644 --- a/libs/brig-types/test/unit/Test/Brig/Types/Arbitrary.hs +++ b/libs/brig-types/test/unit/Test/Brig/Types/Arbitrary.hs @@ -29,6 +29,7 @@ import Data.Currency import Data.IP import Data.Json.Util (UTCTimeMillis (..), toUTCTimeMillis) import Data.LanguageCodes +import Data.List.Extra (nubOn) import Data.Misc import Data.Proxy import Data.Range @@ -303,6 +304,17 @@ instance Arbitrary UserProfile where <*> arbitrary <*> arbitrary +instance Arbitrary RichField where + arbitrary = RichField <$> arbitrary <*> arbitrary + +instance Arbitrary RichInfo where + arbitrary = do + richInfoFields <- nubOn richFieldType <$> arbitrary + pure RichInfo{..} + +instance Arbitrary RichInfoUpdate where + arbitrary = RichInfoUpdate <$> arbitrary + instance Arbitrary ServiceRef where arbitrary = ServiceRef <$> arbitrary <*> arbitrary diff --git a/libs/brig-types/test/unit/Test/Brig/Types/User.hs b/libs/brig-types/test/unit/Test/Brig/Types/User.hs index 2d80d915182..790ed547fad 100644 --- a/libs/brig-types/test/unit/Test/Brig/Types/User.hs +++ b/libs/brig-types/test/unit/Test/Brig/Types/User.hs @@ -96,7 +96,9 @@ roundtripTests = , run @UserIdentity Proxy , run @UserProfile Proxy , run @User Proxy + , run @RichInfo Proxy , run @UserUpdate Proxy + , run @RichInfoUpdate Proxy , run @VerifyDeleteUser Proxy ] where diff --git a/services/brig/brig.integration.yaml b/services/brig/brig.integration.yaml index 20aa2a81f53..1c4e3aa04d6 100644 --- a/services/brig/brig.integration.yaml +++ b/services/brig/brig.integration.yaml @@ -73,7 +73,17 @@ emailSMS: templateDir: deb/opt/brig/templates emailSender: backend-integration@wire.com smsSender: "" - + templateBranding: + brand: Wire + brandUrl: https://wire.com + brandLabelUrl: wire.com # This is the text in the label for the above URL + brandLogoUrl: https://wire.com/p/img/email/logo-email-black.png + brandService: Wire Service Provider + copyright: © WIRE SWISS GmbH + misuse: misuse@wire.com + legal: https://wire.com/legal/ + forgot: https://wire.com/forgot/ + support: https://support.wire.com/ user: activationUrl: http://127.0.0.1:8080/activate?key=${key}&code=${code} smsActivationUrl: http://127.0.0.1:8080/v/${code} @@ -127,6 +137,7 @@ optSettings: setUserCookieThrottle: stdDev: 5 retryAfter: 1 + setRichInfoLimit: 5000 # should be in sync with Spar setDefaultLocale: en setMaxTeamSize: 32 setMaxConvSize: 16 diff --git a/services/brig/deb/opt/brig/template-version b/services/brig/deb/opt/brig/template-version index 84b50637e06..e6d41e92977 100644 --- a/services/brig/deb/opt/brig/template-version +++ b/services/brig/deb/opt/brig/template-version @@ -1 +1 @@ -v1.0.42 +v1.0.55 diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/activation-subject.txt b/services/brig/deb/opt/brig/templates/de/provider/email/activation-subject.txt index 10a38a4b99b..4c419a07664 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/provider/email/activation-subject.txt @@ -1 +1 @@ -Dein Wire Service-Provider-Konto \ No newline at end of file +Dein ${brand_service}-Benutzerkonto \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/activation.html b/services/brig/deb/opt/brig/templates/de/provider/email/activation.html index 93b05ef4032..e2d5a5920cb 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/activation.html +++ b/services/brig/deb/opt/brig/templates/de/provider/email/activation.html @@ -1 +1 @@ -Dein Wire Service-Provider-Konto

wire.com

Bestätige deine E-Mail-Adresse

Deine E-Mail-Adresse ${email} wurde benutzt, um sich als Wire Serviceanbieter zu registrieren.

Um die Registrierung abzuschließen, bestätige bitte deine E-Mail-Adresse, indem du auf den unteren Button klickst.

Bitte beachte, dass das Service-Provider-Konto nach der Bestätigung der E-Mail-Adresse noch durch uns freigeschaltet werden muss. Dies erfolgt üblicherweise innerhalb von 24 Stunden. Über die Freischaltung wirst du per E-Mail informiert.

 
Überprüfe
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Solltest du dich nicht für eine Wire Service-Provider-Konto mit dieser E-Mail-Adresse registriert haben, kannst du diese Meldung ignorieren. Falls du einen Missbrauch deiner E-Mail-Adresse melden möchtest kontaktiere uns bitte.

Bitte antworte nicht auf diese E-Mail.

                                                           
+Dein ${brand_service}-Benutzerkonto

${brand_label_url}

Bestätige deine E-Mail-Adresse

Deine E-Mail-Adresse ${email} wurde benutzt, um sich als ${brand_service} Serviceanbieter zu registrieren.

Um die Registrierung abzuschließen, bestätige bitte deine E-Mail-Adresse, indem du auf den unteren Button klickst.

Bitte beachte, dass das ${brand_service} nach der Bestätigung der E-Mail-Adresse noch durch uns freigeschaltet werden muss. Dies erfolgt üblicherweise innerhalb von 24 Stunden. Über die Freischaltung wirst du per E-Mail informiert.

 
Überprüfe
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Solltest du dich nicht für eine ${brand} Service-Provider-Konto mit dieser E-Mail-Adresse registriert haben, kannst du diese Meldung ignorieren. Falls du einen Missbrauch deiner E-Mail-Adresse melden möchtest kontaktiere uns bitte.

Bitte antworte nicht auf diese E-Mail.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/activation.txt b/services/brig/deb/opt/brig/templates/de/provider/email/activation.txt index 1c6b92fcd4c..074632d6e5a 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/activation.txt +++ b/services/brig/deb/opt/brig/templates/de/provider/email/activation.txt @@ -1,29 +1,32 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + BESTÄTIGE DEINE E-MAIL-ADRESSE -Deine E-Mail-Adresse ${email} wurde benutzt, um sich als Wire Serviceanbieter zu -registrieren. +Deine E-Mail-Adresse ${email} wurde benutzt, um sich als ${brand_service} +Serviceanbieter zu registrieren. Um die Registrierung abzuschließen, bestätige bitte deine E-Mail-Adresse, indem du auf den unteren Button klickst. -Bitte beachte, dass das Service-Provider-Konto nach der Bestätigung der -E-Mail-Adresse noch durch uns freigeschaltet werden muss. Dies erfolgt -üblicherweise innerhalb von 24 Stunden. Über die Freischaltung wirst du per -E-Mail informiert. +Bitte beachte, dass das ${brand_service} nach der Bestätigung der E-Mail-Adresse +noch durch uns freigeschaltet werden muss. Dies erfolgt üblicherweise innerhalb +von 24 Stunden. Über die Freischaltung wirst du per E-Mail informiert. Überprüfe [${url}]Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein: ${url} -Solltest du dich nicht für eine Wire Service-Provider-Konto mit dieser +Solltest du dich nicht für eine ${brand} Service-Provider-Konto mit dieser E-Mail-Adresse registriert haben, kannst du diese Meldung ignorieren. Falls du einen Missbrauch deiner E-Mail-Adresse melden möchtest kontaktiere uns bitte. -[https://support.wire.com/hc/de/requests/new] +[${support}] Bitte antworte nicht auf diese E-Mail. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm-subject.txt b/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm-subject.txt index 10a38a4b99b..4c419a07664 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm-subject.txt @@ -1 +1 @@ -Dein Wire Service-Provider-Konto \ No newline at end of file +Dein ${brand_service}-Benutzerkonto \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm.html b/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm.html index de9ac4d4976..844327c5a6d 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm.html +++ b/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm.html @@ -1 +1 @@ -Dein Wire Service-Provider-Konto

wire.com

Hallo,

Wir freuen uns dir mitzuteilen, dass du jetzt ein genehmigter Wire Service-Provider bist.

Bitte antworte nicht auf diese E-Mail.

Wenn du dich nicht für ein Wire Service-Provider-Konto mit dieser E-Mail-Adresse registriert hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file +Dein ${brand_service}-Benutzerkonto

${brand_label_url}

Hallo,

Wir freuen uns dir mitzuteilen, dass du jetzt ein genehmigter ${brand_service} bist.

Bitte antworte nicht auf diese E-Mail.

Wenn du dich nicht für ein ${brand_service}-Konto mit dieser E-Mail-Adresse registriert hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm.txt b/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm.txt index 88607a7c150..5f19b2d6b15 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm.txt +++ b/services/brig/deb/opt/brig/templates/de/provider/email/approval-confirm.txt @@ -1,16 +1,19 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + Hallo, -Wir freuen uns dir mitzuteilen, dass du jetzt ein genehmigter Wire -Service-Provider bist. +Wir freuen uns dir mitzuteilen, dass du jetzt ein genehmigter ${brand_service} +bist. Bitte antworte nicht auf diese E-Mail. -Wenn du dich nicht für ein Wire Service-Provider-Konto mit dieser E-Mail-Adresse -registriert hast, bitte kontaktiere uns -[https://support.wire.com/hc/requests/new]. +Wenn du dich nicht für ein ${brand_service}-Konto mit dieser E-Mail-Adresse +registriert hast, bitte kontaktiere uns [${support}]. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/approval-request-subject.txt b/services/brig/deb/opt/brig/templates/de/provider/email/approval-request-subject.txt index f120d9e4335..f038d3070a6 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/approval-request-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/provider/email/approval-request-subject.txt @@ -1 +1 @@ -Anfrage genehmigen: Wire Service-Provider \ No newline at end of file +Anfrage genehmigen: ${brand_service} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/approval-request.html b/services/brig/deb/opt/brig/templates/de/provider/email/approval-request.html index 611063715c1..862723a5e71 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/approval-request.html +++ b/services/brig/deb/opt/brig/templates/de/provider/email/approval-request.html @@ -1 +1 @@ -Anfrage genehmigen: Wire Service-Provider

wire.com

Anfrage genehmigen

Ein neuer Wire Service-Provider hat sich registriert und erwartet deine Genehmigung. Bitte überprüfe die folgenden Informationen.

Name: ${name}

E-mail: ${email}

Website: ${url}

Beschreibung: ${description}

Wenn die Anfrage echt scheint, kannst du den Service-Provider genehmigen, indem du auf den unteren Button klickst. Sobald genehmigt, kann der Service-Provider sich anmelden und anfangen Dienste zu registrieren, die Wire Nutzer zu ihren Unterhaltungen hinzufügen werden können.

Falls die Anfrage zweifelhaft scheint, kontaktiere bitte den Service-Provider für Klarstellung bevor du fortfährst.

 
Genehmigen
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Bitte antworte nicht auf diese E-Mail.

                                                           
\ No newline at end of file +Anfrage genehmigen: ${brand_service}

${brand_label_url}

Anfrage genehmigen

Ein neuer ${brand_service} hat sich registriert und erwartet deine Genehmigung. Bitte überprüfe die folgenden Informationen.

Name: ${name}

E-mail: ${email}

Website: ${url}

Beschreibung: ${description}

Wenn die Anfrage echt scheint, kannst du den Service-Provider genehmigen, indem du auf den unteren Button klickst. Sobald genehmigt, kann der Service-Provider sich anmelden und anfangen Dienste zu registrieren, die ${brand} Nutzer zu ihren Unterhaltungen hinzufügen werden können.

Falls die Anfrage zweifelhaft scheint, kontaktiere bitte den Service-Provider für Klarstellung bevor du fortfährst.

 
Genehmigen
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Bitte antworte nicht auf diese E-Mail.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/provider/email/approval-request.txt b/services/brig/deb/opt/brig/templates/de/provider/email/approval-request.txt index a2ee700c2f9..61c5215e06a 100644 --- a/services/brig/deb/opt/brig/templates/de/provider/email/approval-request.txt +++ b/services/brig/deb/opt/brig/templates/de/provider/email/approval-request.txt @@ -1,6 +1,10 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + ANFRAGE GENEHMIGEN -Ein neuer Wire Service-Provider hat sich registriert und erwartet deine -Genehmigung. Bitte überprüfe die folgenden Informationen. +Ein neuer ${brand_service} hat sich registriert und erwartet deine Genehmigung. +Bitte überprüfe die folgenden Informationen. Name: ${name} @@ -12,7 +16,7 @@ Beschreibung: ${description} Wenn die Anfrage echt scheint, kannst du den Service-Provider genehmigen, indem du auf den unteren Button klickst. Sobald genehmigt, kann der Service-Provider -sich anmelden und anfangen Dienste zu registrieren, die Wire Nutzer zu ihren +sich anmelden und anfangen Dienste zu registrieren, die ${brand} Nutzer zu ihren Unterhaltungen hinzufügen werden können. Falls die Anfrage zweifelhaft scheint, kontaktiere bitte den Service-Provider @@ -28,5 +32,5 @@ Bitte antworte nicht auf diese E-Mail. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/team/email/invitation-subject.txt b/services/brig/deb/opt/brig/templates/de/team/email/invitation-subject.txt index 5ed0cedf202..895f0c6e3b0 100644 --- a/services/brig/deb/opt/brig/templates/de/team/email/invitation-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/team/email/invitation-subject.txt @@ -1 +1 @@ -Du wurdest eingeladen einem Team auf Wire beizutreten \ No newline at end of file +Du wurdest eingeladen einem Team auf ${brand} beizutreten \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/team/email/invitation.html b/services/brig/deb/opt/brig/templates/de/team/email/invitation.html index 0d9ff830663..66cb8bb1a3d 100644 --- a/services/brig/deb/opt/brig/templates/de/team/email/invitation.html +++ b/services/brig/deb/opt/brig/templates/de/team/email/invitation.html @@ -1 +1 @@ -Du wurdest eingeladen einem Team auf Wire beizutreten

wire.com

Team Einladung

${inviter} hat dich auf Wire zu einem Team eingeladen. Klicke auf den nachstehenden Button um die Einladung zu akzeptieren.

 
Einladung akzeptieren
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn Du Fragen hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file +Du wurdest eingeladen einem Team auf ${brand} beizutreten

${brand_label_url}

Team Einladung

${inviter} hat dich auf ${brand} zu einem Team eingeladen. Klicke auf den nachstehenden Button um die Einladung zu akzeptieren.

 
Einladung akzeptieren
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn du Fragen hast, dann kontaktiere uns bitte.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/team/email/invitation.txt b/services/brig/deb/opt/brig/templates/de/team/email/invitation.txt index 6a727d7361f..fdcb06419f5 100644 --- a/services/brig/deb/opt/brig/templates/de/team/email/invitation.txt +++ b/services/brig/deb/opt/brig/templates/de/team/email/invitation.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + TEAM EINLADUNG -${inviter} hat dich auf Wire zu einem Team eingeladen. Klicke auf den +${inviter} hat dich auf ${brand} zu einem Team eingeladen. Klicke auf den nachstehenden Button um die Einladung zu akzeptieren. Einladung akzeptieren [${url}]Falls du nicht auf den Button klicken kannst, @@ -7,11 +11,10 @@ kopiere den Link und füge ihn in deinem Browser ein: ${url} -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome-subject.txt b/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome-subject.txt index 761a6e9f1a5..59162064340 100644 --- a/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome-subject.txt @@ -1 +1 @@ -Du bist einem Team auf Wire beigetreten \ No newline at end of file +Du bist einem Team auf ${brand} beigetreten \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome.html b/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome.html index d100cffd90c..ff71b078a39 100644 --- a/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome.html +++ b/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome.html @@ -1 +1 @@ -Du bist einem Team auf Wire beigetreten

wire.com

Willkommen zu ${team_name}.

Du bist soeben mit ${email} einem Team namens ${team_name} auf Wire beigetreten.

 

Wire vereint sichere Verschlüsselung mit reichhaltigem Funktionsumfang und einfacher Bedienung in einer einzigen App. Unterstützt alle gängigen Plattformen.

 
Wire herunterladen
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn Du Fragen hast, bitte kontaktiere uns.

Team ID: ${team_id}

                                                           
\ No newline at end of file +Du bist einem Team auf ${brand} beigetreten

${brand_label_url}

Willkommen zu ${team_name}.

Du bist soeben mit ${email} einem Team namens ${team_name} auf ${brand} beigetreten.

 

${brand} vereint sichere Verschlüsselung mit reichhaltigem Funktionsumfang und einfacher Bedienung in einer einzigen App. Unterstützt alle gängigen Plattformen.

 
${brand} herunterladen
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn du Fragen hast, dann kontaktiere uns bitte.

Team ID: ${team_id}

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome.txt b/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome.txt index f472e18d4c2..bba395a030c 100644 --- a/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome.txt +++ b/services/brig/deb/opt/brig/templates/de/team/email/new-member-welcome.txt @@ -1,22 +1,26 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + WILLKOMMEN ZU ${team_name}. -Du bist soeben mit ${email} einem Team namens ${team_name} auf Wire beigetreten. +Du bist soeben mit ${email} einem Team namens ${team_name} auf ${brand} +beigetreten. -Wire vereint sichere Verschlüsselung mit reichhaltigem Funktionsumfang und +${brand} vereint sichere Verschlüsselung mit reichhaltigem Funktionsumfang und einfacher Bedienung in einer einzigen App. Unterstützt alle gängigen Plattformen. -Wire herunterladen [${url}]Falls du nicht auf den Button klicken kannst, kopiere -den Link und füge ihn in deinem Browser ein: +${brand} herunterladen [${url}]Falls du nicht auf den Button klicken kannst, +kopiere den Link und füge ihn in deinem Browser ein: ${url} -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. Team ID: ${team_id} -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/activation-subject.txt b/services/brig/deb/opt/brig/templates/de/user/email/activation-subject.txt index b9f0880a4c7..0a423e9a016 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/activation-subject.txt @@ -1 +1 @@ -Dein Wire-Benutzerkonto \ No newline at end of file +Dein ${brand}-Benutzerkonto \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/activation.html b/services/brig/deb/opt/brig/templates/de/user/email/activation.html index b1632f60312..2d59aecade7 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/activation.html +++ b/services/brig/deb/opt/brig/templates/de/user/email/activation.html @@ -1 +1 @@ -Dein Wire-Benutzerkonto

wire.com

Bestätige deine E-Mail-Adresse

${email} wurde verwendet um ein Konto auf Wire zu erstellen.
Klicke den folgenden Button um die E-Mail-Adresse zu bestätigen.

 
Überprüfe
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn Du Fragen hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file +Dein ${brand}-Benutzerkonto

${brand_label_url}

Bestätige deine E-Mail-Adresse

${email} wurde verwendet um ein Konto auf ${brand} zu erstellen.
Klicke den folgenden Button um die E-Mail-Adresse zu bestätigen.

 
Überprüfe
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn du Fragen hast, dann kontaktiere uns bitte.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/activation.txt b/services/brig/deb/opt/brig/templates/de/user/email/activation.txt index 240eed0ebde..618bc70ac1e 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/activation.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/activation.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + BESTÄTIGE DEINE E-MAIL-ADRESSE -${email} wurde verwendet um ein Konto auf Wire zu erstellen. +${email} wurde verwendet um ein Konto auf ${brand} zu erstellen. Klicke den folgenden Button um die E-Mail-Adresse zu bestätigen. Überprüfe [${url}]Falls du nicht auf den Button klicken kannst, kopiere den Link @@ -7,11 +11,10 @@ und füge ihn in deinem Browser ein: ${url} -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/deletion.html b/services/brig/deb/opt/brig/templates/de/user/email/deletion.html index 50d0c22df36..fcc35ae74a2 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/deletion.html +++ b/services/brig/deb/opt/brig/templates/de/user/email/deletion.html @@ -1 +1 @@ -Konto löschen?

wire.com

Lösche dein Konto

Wir haben eine Anfrage zur Löschung deines Wire-Benutzerkontos erhalten. Klicke innerhalb der nächsten 10 Minuten auf den nachstehenden Link, um alle deine Unterhaltungen, Nachrichten und Kontakte zu löschen.

 
Konto löschen
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Falls du dies nicht beantragt hast, setze dein Passwort zurück.

Wenn Du Fragen hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file +Konto löschen?

${brand_label_url}

Lösche dein Konto

Wir haben eine Anfrage zur Löschung deines ${brand}-Benutzerkontos erhalten. Klicke innerhalb der nächsten 10 Minuten auf den nachstehenden Link, um alle deine Unterhaltungen, Nachrichten und Kontakte zu löschen.

 
Konto löschen
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Falls du dies nicht beantragt hast, setze dein Passwort zurück.

Wenn du Fragen hast, dann kontaktiere uns bitte.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/deletion.txt b/services/brig/deb/opt/brig/templates/de/user/email/deletion.txt index f23d380795c..3a68b9e5ded 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/deletion.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/deletion.txt @@ -1,21 +1,23 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + LÖSCHE DEIN KONTO -Wir haben eine Anfrage zur Löschung deines Wire-Benutzerkontos erhalten. Klicke -innerhalb der nächsten 10 Minuten auf den nachstehenden Link, um alle deine -Unterhaltungen, Nachrichten und Kontakte zu löschen. +Wir haben eine Anfrage zur Löschung deines ${brand}-Benutzerkontos erhalten. +Klicke innerhalb der nächsten 10 Minuten auf den nachstehenden Link, um alle +deine Unterhaltungen, Nachrichten und Kontakte zu löschen. Konto löschen [${url}]Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein: ${url} -Falls du dies nicht beantragt hast, setze dein Passwort zurück -[https://account.wire.com/forgot/]. +Falls du dies nicht beantragt hast, setze dein Passwort zurück [${forgot}]. -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/new-client.html b/services/brig/deb/opt/brig/templates/de/user/email/new-client.html index e0964f898ac..16af344a1e0 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/new-client.html +++ b/services/brig/deb/opt/brig/templates/de/user/email/new-client.html @@ -1 +1 @@ -Neues Gerät

wire.com

Neues Gerät

Ein neues Gerät wurde zu deinem Wire-Benutzerkonto hinzugefügt:

${date}

${model}

Du hast Wire vermutlich auf einem neuen Gerät installiert oder dich auf einem bestehenden Gerät erneut eingeloggt. Falls dies nicht der Fall ist, gehe in deine Wire Einstellungen, entferne das Gerät und setze dein Passwort zurück.

Wenn Du Fragen hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file +Neues Gerät

${brand_label_url}

Neues Gerät

Ein neues Gerät wurde zu deinem ${brand}-Benutzerkonto hinzugefügt:

${date}

${model}

Du hast ${brand} vermutlich auf einem neuen Gerät installiert oder dich auf einem bestehenden Gerät erneut eingeloggt. Falls dies nicht der Fall ist, gehe in deine ${brand} Einstellungen, entferne das Gerät und setze dein Passwort zurück.

Wenn du Fragen hast, dann kontaktiere uns bitte.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/new-client.txt b/services/brig/deb/opt/brig/templates/de/user/email/new-client.txt index a41bf36719c..4247a9d03c0 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/new-client.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/new-client.txt @@ -1,20 +1,23 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + NEUES GERÄT -Ein neues Gerät wurde zu deinem Wire-Benutzerkonto hinzugefügt: +Ein neues Gerät wurde zu deinem ${brand}-Benutzerkonto hinzugefügt: ${date} ${model} -Du hast Wire vermutlich auf einem neuen Gerät installiert oder dich auf einem -bestehenden Gerät erneut eingeloggt. Falls dies nicht der Fall ist, gehe in -deine Wire Einstellungen, entferne das Gerät und setze dein Passwort zurück -[https://account.wire.com/forgot/]. +Du hast ${brand} vermutlich auf einem neuen Gerät installiert oder dich auf +einem bestehenden Gerät erneut eingeloggt. Falls dies nicht der Fall ist, gehe +in deine ${brand} Einstellungen, entferne das Gerät und setze dein Passwort +zurück [${forgot}]. -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/password-reset-subject.txt b/services/brig/deb/opt/brig/templates/de/user/email/password-reset-subject.txt index 385921c27da..c6cdffefdd8 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/password-reset-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/password-reset-subject.txt @@ -1 +1 @@ -Änderung des Passworts auf Wire \ No newline at end of file +Änderung des Passworts auf ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/password-reset.html b/services/brig/deb/opt/brig/templates/de/user/email/password-reset.html index 3804b3828cc..48de102b5da 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/password-reset.html +++ b/services/brig/deb/opt/brig/templates/de/user/email/password-reset.html @@ -1 +1 @@ -Änderung des Passworts auf Wire

wire.com

Passwort zurücksetzen

Wir haben eine Anfrage zum Zurücksetzen des Passworts für dein Wire-Benutzerkonto erhalten. Klicke auf den nachstehenden Button, um ein neues Passwort zu erstellen.

 
Passwort zurücksetzen
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn Du Fragen hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file +Änderung des Passworts auf ${brand}

${brand_label_url}

Passwort zurücksetzen

Wir haben eine Anfrage zum Zurücksetzen des Passworts für dein ${brand}-Benutzerkonto erhalten. Klicke auf den nachstehenden Button, um ein neues Passwort zu erstellen.

 
Passwort zurücksetzen
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn du Fragen hast, dann kontaktiere uns bitte.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/password-reset.txt b/services/brig/deb/opt/brig/templates/de/user/email/password-reset.txt index c21beae109f..fb97d4e83ac 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/password-reset.txt @@ -1,18 +1,21 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + PASSWORT ZURÜCKSETZEN Wir haben eine Anfrage zum Zurücksetzen des Passworts für dein -Wire-Benutzerkonto erhalten. Klicke auf den nachstehenden Button, um ein neues -Passwort zu erstellen. +${brand}-Benutzerkonto erhalten. Klicke auf den nachstehenden Button, um ein +neues Passwort zu erstellen. Passwort zurücksetzen [${url}]Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein: ${url} -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/team-activation-subject.txt b/services/brig/deb/opt/brig/templates/de/user/email/team-activation-subject.txt index 3ecf32fd7e7..52da05105ba 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/team-activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/team-activation-subject.txt @@ -1 +1 @@ -Wire Benutzerkonto \ No newline at end of file +${brand} Benutzerkonto \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/team-activation.html b/services/brig/deb/opt/brig/templates/de/user/email/team-activation.html index ec366911b55..0287f7fa751 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/team-activation.html +++ b/services/brig/deb/opt/brig/templates/de/user/email/team-activation.html @@ -1 +1 @@ -Wire Benutzerkonto

wire.com

Dein neues Wire-Benutzerkonto

Ein neues Wire Team wurde mit ${email} erstellt. Bitte verifiziere deine E-Mail-Adresse.

 
Überprüfe
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn Du Fragen hast, bitte kontaktiere uns.

                                                           
+${brand} Benutzerkonto

${brand_label_url}

Dein neues ${brand}-Benutzerkonto

Ein neues ${brand} Team wurde mit ${email} erstellt. Bitte verifiziere deine E-Mail-Adresse.

 
Überprüfe
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn du Fragen hast, dann kontaktiere uns bitte.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/team-activation.txt b/services/brig/deb/opt/brig/templates/de/user/email/team-activation.txt index 4422d4b9b54..cece07b41e1 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/team-activation.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/team-activation.txt @@ -1,5 +1,9 @@ -DEIN NEUES WIRE-BENUTZERKONTO -Ein neues Wire Team wurde mit ${email} erstellt. Bitte verifiziere deine +[${brand_logo}] + +${brand_label_url} [${brand_url}] + +DEIN NEUES ${brand}-BENUTZERKONTO +Ein neues ${brand} Team wurde mit ${email} erstellt. Bitte verifiziere deine E-Mail-Adresse. Überprüfe [${url}]Falls du nicht auf den Button klicken kannst, kopiere den Link @@ -7,11 +11,10 @@ und füge ihn in deinem Browser ein: ${url} -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/update-subject.txt b/services/brig/deb/opt/brig/templates/de/user/email/update-subject.txt index 509d3b2d217..14019aa91b1 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/update-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/update-subject.txt @@ -1 +1 @@ -Deine neue E-Mail-Adresse auf Wire \ No newline at end of file +Deine neue E-Mail-Adresse auf ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/update.html b/services/brig/deb/opt/brig/templates/de/user/email/update.html index 1be2e54b1c4..1b08f3ccc61 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/update.html +++ b/services/brig/deb/opt/brig/templates/de/user/email/update.html @@ -1 +1 @@ -Deine neue E-Mail-Adresse auf Wire

wire.com

Bestätige deine E-Mail-Adresse

${email} wurde als deine neue E-Mail-Adresse auf Wire registriert. Klicke auf den nachstehenden Button, um deine neue Adresse zu bestätigen.

 
Überprüfe
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn Du Fragen hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file +Deine neue E-Mail-Adresse auf ${brand}

${brand_label_url}

Bestätige deine E-Mail-Adresse

${email} wurde als deine neue E-Mail-Adresse auf ${brand} registriert. Klicke auf den nachstehenden Button, um deine neue Adresse zu bestätigen.

 
Überprüfe
 

Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein:

${url}

Wenn du Fragen hast, dann kontaktiere uns bitte.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/update.txt b/services/brig/deb/opt/brig/templates/de/user/email/update.txt index b13004cfc2d..cdccc9848a6 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/update.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/update.txt @@ -1,17 +1,20 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + BESTÄTIGE DEINE E-MAIL-ADRESSE -${email} wurde als deine neue E-Mail-Adresse auf Wire registriert. Klicke auf -den nachstehenden Button, um deine neue Adresse zu bestätigen. +${email} wurde als deine neue E-Mail-Adresse auf ${brand} registriert. Klicke +auf den nachstehenden Button, um deine neue Adresse zu bestätigen. Überprüfe [${url}]Falls du nicht auf den Button klicken kannst, kopiere den Link und füge ihn in deinem Browser ein: ${url} -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/verification-subject.txt b/services/brig/deb/opt/brig/templates/de/user/email/verification-subject.txt index 3b122e88dd6..e7d4814bef1 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/verification-subject.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/verification-subject.txt @@ -1 +1 @@ -Wire Bestätigungs-Code ist ${code} \ No newline at end of file +${brand} Bestätigungs-Code ist ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/verification.html b/services/brig/deb/opt/brig/templates/de/user/email/verification.html index 498f1425138..016660e86d5 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/verification.html +++ b/services/brig/deb/opt/brig/templates/de/user/email/verification.html @@ -1 +1 @@ -Wire Bestätigungs-Code ist ${code}

wire.com

Bestätige deine E-Mail-Adresse

${email} wurde verwendet um ein Benutzerkonto auf Wire zu erstellen. Gib diesen Code ein, um deine E-Mail-Adresse zu verifizieren und dein Konto zu erstellen.

 

${code}

 

Wenn Du Fragen hast, bitte kontaktiere uns.

                                                           
\ No newline at end of file +${brand} Bestätigungs-Code ist ${code}

${brand_label_url}

Bestätige deine E-Mail-Adresse

${email} wurde verwendet um ein Benutzerkonto auf ${brand} zu erstellen. Gib diesen Code ein, um deine E-Mail-Adresse zu verifizieren und dein Konto zu erstellen.

 

${code}

 

Wenn du Fragen hast, dann kontaktiere uns bitte.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/email/verification.txt b/services/brig/deb/opt/brig/templates/de/user/email/verification.txt index 0879bce75b9..d95c7b87de3 100644 --- a/services/brig/deb/opt/brig/templates/de/user/email/verification.txt +++ b/services/brig/deb/opt/brig/templates/de/user/email/verification.txt @@ -1,14 +1,18 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + BESTÄTIGE DEINE E-MAIL-ADRESSE -${email} wurde verwendet um ein Benutzerkonto auf Wire zu erstellen. Gib diesen -Code ein, um deine E-Mail-Adresse zu verifizieren und dein Konto zu erstellen. +${email} wurde verwendet um ein Benutzerkonto auf ${brand} zu erstellen. Gib +diesen Code ein, um deine E-Mail-Adresse zu verifizieren und dein Konto zu +erstellen. ${code} -Wenn Du Fragen hast, bitte kontaktiere uns -[https://support.wire.com/hc/de/requests/new]. +Wenn du Fragen hast, dann kontaktiere uns [${support}] bitte. -------------------------------------------------------------------------------- -Datenschutz [https://wire.com/legal/] · Missbrauch melden [misuse@wire.com] -© WIRE SWISS GmbH. ALLE RECHTE VORBEHALTEN. \ No newline at end of file +Datenschutz [${legal}] · Missbrauch melden [${misuse}] +${copyright}. Alle Rechte vorbehalten. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/de/user/sms/activation.txt b/services/brig/deb/opt/brig/templates/de/user/sms/activation.txt index d8f73ef99d8..1a91f15695e 100644 --- a/services/brig/deb/opt/brig/templates/de/user/sms/activation.txt +++ b/services/brig/deb/opt/brig/templates/de/user/sms/activation.txt @@ -1,3 +1,3 @@ -Dein Wire Code ist ${code}. +Dein ${brand} Code ist ${code}. Öffne ${url}, um deine Nummer zu überprüfen. diff --git a/services/brig/deb/opt/brig/templates/de/user/sms/deletion.txt b/services/brig/deb/opt/brig/templates/de/user/sms/deletion.txt index 4d3fb98f258..c5b37108816 100644 --- a/services/brig/deb/opt/brig/templates/de/user/sms/deletion.txt +++ b/services/brig/deb/opt/brig/templates/de/user/sms/deletion.txt @@ -1,2 +1,2 @@ -Klicke den Link, dein Wire-Benutzerkonto zu löschen. -${url} +Klicke den Link, dein ${brand}-Benutzerkonto zu löschen. +${url} diff --git a/services/brig/deb/opt/brig/templates/de/user/sms/login.txt b/services/brig/deb/opt/brig/templates/de/user/sms/login.txt index ac95cc585c3..9fc536f200f 100644 --- a/services/brig/deb/opt/brig/templates/de/user/sms/login.txt +++ b/services/brig/deb/opt/brig/templates/de/user/sms/login.txt @@ -1,3 +1,3 @@ -Dein Login-Code für Wire lautet ${code}. +Dein Login-Code für ${brand} lautet ${code}. Öffne ${url}, um dich anzumelden. diff --git a/services/brig/deb/opt/brig/templates/de/user/sms/password-reset.txt b/services/brig/deb/opt/brig/templates/de/user/sms/password-reset.txt index f8217d37fe8..16dd05e5673 100644 --- a/services/brig/deb/opt/brig/templates/de/user/sms/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/de/user/sms/password-reset.txt @@ -1,3 +1,3 @@ -Dein Rücksetzcode für Wire ist ${code}. +Dein Rücksetzcode für ${brand} ist ${code}. -Verwende diesen Code, um das Zurücksetzen deines Kennworts zu bestätigen. \ No newline at end of file +Verwende diesen Code, um das Zurücksetzen deines Kennworts zu bestätigen. diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/activation-subject.txt b/services/brig/deb/opt/brig/templates/en/provider/email/activation-subject.txt index dde526f9c0a..194b2073948 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/provider/email/activation-subject.txt @@ -1 +1 @@ -Your Wire Service Provider Account \ No newline at end of file +Your ${brand_service} Account \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/activation.html b/services/brig/deb/opt/brig/templates/en/provider/email/activation.html index e0e973efdc8..5858bdd4c3c 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/activation.html +++ b/services/brig/deb/opt/brig/templates/en/provider/email/activation.html @@ -1 +1 @@ -Your Wire Service Provider Account

wire.com

Verify your email

Your email address ${email} was used to register as a Wire Service Provider.

To complete the registration, it is necessary that you verify your e-mail address by clicking on the button below.

Please note that upon successful verification of your e-mail, your Wire Service Provider account is still subject to approval through our staff, which usually happens within 24 hours. You will be informed of the approval via a separate e-mail.

 
Verify
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you didn’t register for a Wire service provider account using this e-mail address, you can safely ignore this message. If you want to report abuse of your e-mail address, please contact us.

Please don’t reply to this message.

                                                           
+Your ${brand_service} Account

${brand_label_url}

Verify your email

Your email address ${email} was used to register as a ${brand_service}.

To complete the registration, it is necessary that you verify your e-mail address by clicking on the button below.

Please note that upon successful verification of your e-mail, your ${brand_service} account is still subject to approval through our staff, which usually happens within 24 hours. You will be informed of the approval via a separate e-mail.

 
Verify
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you didn’t register for a ${brand} service provider account using this e-mail address, you can safely ignore this message. If you want to report abuse of your e-mail address, please contact us.

Please don’t reply to this message.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/activation.txt b/services/brig/deb/opt/brig/templates/en/provider/email/activation.txt index 6640cba169b..48e61c1dbfa 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/activation.txt +++ b/services/brig/deb/opt/brig/templates/en/provider/email/activation.txt @@ -1,27 +1,31 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + VERIFY YOUR EMAIL -Your email address ${email} was used to register as a Wire Service Provider. +Your email address ${email} was used to register as a ${brand_service}. To complete the registration, it is necessary that you verify your e-mail address by clicking on the button below. -Please note that upon successful verification of your e-mail, your Wire Service -Provider account is still subject to approval through our staff, which usually -happens within 24 hours. You will be informed of the approval via a separate -e-mail. +Please note that upon successful verification of your e-mail, your +${brand_service} account is still subject to approval through our staff, which +usually happens within 24 hours. You will be informed of the approval via a +separate e-mail. Verify [${url}]If you can’t click the button, copy and paste this link to your browser: ${url} -If you didn’t register for a Wire service provider account using this e-mail +If you didn’t register for a ${brand} service provider account using this e-mail address, you can safely ignore this message. If you want to report abuse of your -e-mail address, please contact us. [https://support.wire.com/hc/requests/new] +e-mail address, please contact us. [${support}] Please don’t reply to this message. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm-subject.txt b/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm-subject.txt index dde526f9c0a..194b2073948 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm-subject.txt @@ -1 +1 @@ -Your Wire Service Provider Account \ No newline at end of file +Your ${brand_service} Account \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm.html b/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm.html index 5bcd59f749b..86cc1cf3884 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm.html +++ b/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm.html @@ -1 +1 @@ -Your Wire Service Provider Account

wire.com

Hello,

We are happy to inform you that you are now an approved Wire Service Provider.

Please don’t reply to this message.

If you didn’t register for a Wire Service Provider account using this e-mail address, please contact us.

                                                           
+Your ${brand_service} Account

${brand_label_url}

Hello,

We are happy to inform you that you are now an approved ${brand_service}.

Please don’t reply to this message.

If you didn’t register for a ${brand_service} account using this e-mail address, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm.txt b/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm.txt index f1c6f02661f..3a84fa32267 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm.txt +++ b/services/brig/deb/opt/brig/templates/en/provider/email/approval-confirm.txt @@ -1,14 +1,18 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + Hello, -We are happy to inform you that you are now an approved Wire Service Provider. +We are happy to inform you that you are now an approved ${brand_service}. Please don’t reply to this message. -If you didn’t register for a Wire Service Provider account using this e-mail -address, please contact us [https://support.wire.com/hc/requests/new]. +If you didn’t register for a ${brand_service} account using this e-mail address, +please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/approval-request-subject.txt b/services/brig/deb/opt/brig/templates/en/provider/email/approval-request-subject.txt index ca2f50c1928..b5cae18da41 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/approval-request-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/provider/email/approval-request-subject.txt @@ -1 +1 @@ -Approval Request: Wire Service Provider \ No newline at end of file +Approval Request: ${brand_service} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/approval-request.html b/services/brig/deb/opt/brig/templates/en/provider/email/approval-request.html index a4d039c5c2c..c0c1f2d954e 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/approval-request.html +++ b/services/brig/deb/opt/brig/templates/en/provider/email/approval-request.html @@ -1 +1 @@ -Approval Request: Wire Service Provider

wire.com

Approval request

A new Wire Service Provider has registered and is awaiting approval. Please review the information provided below.

Name: ${name}

E-mail: ${email}

Website: ${url}

Description: ${description}

If the request seems genuine, you can approve the provider by clicking on the button below. Once approved, the provider will be able to sign in and start registering services that Wire users can add to their conversations.

If the request seems dubious, please contact the provider for clarifications before proceeding.

 
Approve
 

If you can’t click the button, copy and paste this link to your browser:

${url}

Please don’t reply to this message.

                                                           
+Approval Request: ${brand_service}

${brand_label_url}

Approval request

A new ${brand_service} has registered and is awaiting approval. Please review the information provided below.

Name: ${name}

E-mail: ${email}

Website: ${url}

Description: ${description}

If the request seems genuine, you can approve the provider by clicking on the button below. Once approved, the provider will be able to sign in and start registering services that ${brand} users can add to their conversations.

If the request seems dubious, please contact the provider for clarifications before proceeding.

 
Approve
 

If you can’t click the button, copy and paste this link to your browser:

${url}

Please don’t reply to this message.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/approval-request.txt b/services/brig/deb/opt/brig/templates/en/provider/email/approval-request.txt index 9a7bc46d4a1..0dbbe1e2460 100644 --- a/services/brig/deb/opt/brig/templates/en/provider/email/approval-request.txt +++ b/services/brig/deb/opt/brig/templates/en/provider/email/approval-request.txt @@ -1,6 +1,10 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + APPROVAL REQUEST -A new Wire Service Provider has registered and is awaiting approval. Please -review the information provided below. +A new ${brand_service} has registered and is awaiting approval. Please review +the information provided below. Name: ${name} @@ -12,7 +16,7 @@ Description: ${description} If the request seems genuine, you can approve the provider by clicking on the button below. Once approved, the provider will be able to sign in and start -registering services that Wire users can add to their conversations. +registering services that ${brand} users can add to their conversations. If the request seems dubious, please contact the provider for clarifications before proceeding. @@ -27,5 +31,5 @@ Please don’t reply to this message. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/provider/email/sender.txt b/services/brig/deb/opt/brig/templates/en/provider/email/sender.txt new file mode 100644 index 00000000000..fa8f332be16 --- /dev/null +++ b/services/brig/deb/opt/brig/templates/en/provider/email/sender.txt @@ -0,0 +1 @@ +Wire \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/team/email/invitation-subject.txt b/services/brig/deb/opt/brig/templates/en/team/email/invitation-subject.txt index 3ea04bf1b2e..9fef363e407 100644 --- a/services/brig/deb/opt/brig/templates/en/team/email/invitation-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/team/email/invitation-subject.txt @@ -1 +1 @@ -You have been invited to join a team on Wire \ No newline at end of file +You have been invited to join a team on ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/team/email/invitation.html b/services/brig/deb/opt/brig/templates/en/team/email/invitation.html index 44aa53214c1..1f52baa0626 100644 --- a/services/brig/deb/opt/brig/templates/en/team/email/invitation.html +++ b/services/brig/deb/opt/brig/templates/en/team/email/invitation.html @@ -1 +1 @@ -You have been invited to join a team on Wire

wire.com

Team invitation

${inviter} has invited you to join a team on Wire. Click the button below to accept the invitation.

 
Accept invitation
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file +You have been invited to join a team on ${brand}

${brand_label_url}

Team invitation

${inviter} has invited you to join a team on ${brand}. Click the button below to accept the invitation.

 
Accept invitation
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/team/email/invitation.txt b/services/brig/deb/opt/brig/templates/en/team/email/invitation.txt index 144d6e0f8c7..72dc5946bdb 100644 --- a/services/brig/deb/opt/brig/templates/en/team/email/invitation.txt +++ b/services/brig/deb/opt/brig/templates/en/team/email/invitation.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + TEAM INVITATION -${inviter} has invited you to join a team on Wire. Click the button below to +${inviter} has invited you to join a team on ${brand}. Click the button below to accept the invitation. Accept invitation [${url}]If you can’t click the button, copy and paste this @@ -7,11 +11,10 @@ link to your browser: ${url} -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome-subject.txt b/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome-subject.txt index 69d5a0f6bf8..bc803c8137e 100644 --- a/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome-subject.txt @@ -1 +1 @@ -You joined a team on Wire \ No newline at end of file +You joined a team on ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome.html b/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome.html index 558a970bdb6..968305a26ea 100644 --- a/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome.html +++ b/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome.html @@ -1 +1 @@ -You joined a team on Wire

wire.com

Welcome to ${team_name}.

You have just joined a team called ${team_name} on Wire with ${email}.

 

Wire combines strong encryption, a rich feature set and ease-of-use in one app like never before. Works on all popular platforms.

 
Download Wire
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

Team ID: ${team_id}

                                                           
\ No newline at end of file +You joined a team on ${brand}

${brand_label_url}

Welcome to ${team_name}.

You have just joined a team called ${team_name} on ${brand} with ${email}.

 

${brand} combines strong encryption, a rich feature set and ease-of-use in one app like never before. Works on all popular platforms.

 
Download ${brand}
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

Team ID: ${team_id}

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome.txt b/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome.txt index 3b655fbb096..1b2ec611c30 100644 --- a/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome.txt +++ b/services/brig/deb/opt/brig/templates/en/team/email/new-member-welcome.txt @@ -1,21 +1,24 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + WELCOME TO ${team_name}. -You have just joined a team called ${team_name} on Wire with ${email}. +You have just joined a team called ${team_name} on ${brand} with ${email}. -Wire combines strong encryption, a rich feature set and ease-of-use in one app -like never before. Works on all popular platforms. +${brand} combines strong encryption, a rich feature set and ease-of-use in one +app like never before. Works on all popular platforms. -Download Wire [${url}]If you can’t click the button, copy and paste this link to -your browser: +Download ${brand} [${url}]If you can’t click the button, copy and paste this +link to your browser: ${url} -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. Team ID: ${team_id} -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/activation-subject.txt b/services/brig/deb/opt/brig/templates/en/user/email/activation-subject.txt index 7566d46a576..ee2f8b6ce3d 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/activation-subject.txt @@ -1 +1 @@ -Your Wire Account \ No newline at end of file +Your ${brand} Account \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/activation.html b/services/brig/deb/opt/brig/templates/en/user/email/activation.html index 3d2dbe28ef8..e9213590ee0 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/activation.html +++ b/services/brig/deb/opt/brig/templates/en/user/email/activation.html @@ -1 +1 @@ -Your Wire Account

wire.com

Verify your email

${email} was used to register on Wire.
Click the button to verify your address.

 
Verify
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file +Your ${brand} Account

${brand_label_url}

Verify your email

${email} was used to register on ${brand}.
Click the button to verify your address.

 
Verify
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/activation.txt b/services/brig/deb/opt/brig/templates/en/user/email/activation.txt index 46d10d0b5b1..f822ffc81ba 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/activation.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/activation.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + VERIFY YOUR EMAIL -${email} was used to register on Wire. +${email} was used to register on ${brand}. Click the button to verify your address. Verify [${url}]If you can’t click the button, copy and paste this link to your @@ -7,11 +11,10 @@ browser: ${url} -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/deletion.html b/services/brig/deb/opt/brig/templates/en/user/email/deletion.html index f2f440c9b42..89e0ea8d067 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/deletion.html +++ b/services/brig/deb/opt/brig/templates/en/user/email/deletion.html @@ -1 +1 @@ -Delete account?

wire.com

Delete your account

We’ve received a request to delete your Wire account. Click the button below within 10 minutes to delete all your conversations, content and connections.

 
Delete account
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you didn’t request this, reset your password.

If you have any questions, please contact us.

                                                           
\ No newline at end of file +Delete account?

${brand_label_url}

Delete your account

We’ve received a request to delete your ${brand} account. Click the button below within 10 minutes to delete all your conversations, content and connections.

 
Delete account
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you didn’t request this, reset your password.

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/deletion.txt b/services/brig/deb/opt/brig/templates/en/user/email/deletion.txt index 39ce7df5ae9..998b2d05f77 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/deletion.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/deletion.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + DELETE YOUR ACCOUNT -We’ve received a request to delete your Wire account. Click the button below +We’ve received a request to delete your ${brand} account. Click the button below within 10 minutes to delete all your conversations, content and connections. Delete account [${url}]If you can’t click the button, copy and paste this link @@ -7,14 +11,12 @@ to your browser: ${url} -If you didn’t request this, reset your password -[https://account.wire.com/forgot/]. +If you didn’t request this, reset your password [${forgot}]. -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/new-client.html b/services/brig/deb/opt/brig/templates/en/user/email/new-client.html index b99758a387f..fdd443a4f49 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/new-client.html +++ b/services/brig/deb/opt/brig/templates/en/user/email/new-client.html @@ -1 +1 @@ -New device

wire.com

New device

Your Wire account was used on:

${date}

${model}

You may have installed Wire on a new device or installed it again on an existing one. If that was not the case, go to Wire Settings, remove the device and reset your password.

If you have any questions, please contact us.

                                                           
\ No newline at end of file +New device

${brand_label_url}

New device

Your ${brand} account was used on:

${date}

${model}

You may have installed ${brand} on a new device or installed it again on an existing one. If that was not the case, go to ${brand} Settings, remove the device and reset your password.

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/new-client.txt b/services/brig/deb/opt/brig/templates/en/user/email/new-client.txt index a78669cae64..224703fe422 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/new-client.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/new-client.txt @@ -1,19 +1,22 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + NEW DEVICE -Your Wire account was used on: +Your ${brand} account was used on: ${date} ${model} -You may have installed Wire on a new device or installed it again on an existing -one. If that was not the case, go to Wire Settings, remove the device and reset -your password [https://account.wire.com/forgot/]. +You may have installed ${brand} on a new device or installed it again on an +existing one. If that was not the case, go to ${brand} Settings, remove the +device and reset your password [${forgot}]. -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/password-reset-subject.txt b/services/brig/deb/opt/brig/templates/en/user/email/password-reset-subject.txt index dfba835fc9a..6a7bbce1a09 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/password-reset-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/password-reset-subject.txt @@ -1 +1 @@ -Password Change at Wire \ No newline at end of file +Password Change at ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/password-reset.html b/services/brig/deb/opt/brig/templates/en/user/email/password-reset.html index f9c46aae177..6203a8b7947 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/password-reset.html +++ b/services/brig/deb/opt/brig/templates/en/user/email/password-reset.html @@ -1 +1 @@ -Password Change at Wire

wire.com

Reset your password

We’ve received a request to reset the password for your Wire account. To create a new password, click the button below.

 
Reset password
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file +Password Change at ${brand}

${brand_label_url}

Reset your password

We’ve received a request to reset the password for your ${brand} account. To create a new password, click the button below.

 
Reset password
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/password-reset.txt b/services/brig/deb/opt/brig/templates/en/user/email/password-reset.txt index 417a290e457..b78fc6f7821 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/password-reset.txt @@ -1,17 +1,20 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + RESET YOUR PASSWORD -We’ve received a request to reset the password for your Wire account. To create -a new password, click the button below. +We’ve received a request to reset the password for your ${brand} account. To +create a new password, click the button below. Reset password [${url}]If you can’t click the button, copy and paste this link to your browser: ${url} -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/team-activation-subject.txt b/services/brig/deb/opt/brig/templates/en/user/email/team-activation-subject.txt index 1e58cd00b89..3e5330c275a 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/team-activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/team-activation-subject.txt @@ -1 +1 @@ -Wire Account \ No newline at end of file +${brand} Account \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/team-activation.html b/services/brig/deb/opt/brig/templates/en/user/email/team-activation.html index 734db78444c..10beb757272 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/team-activation.html +++ b/services/brig/deb/opt/brig/templates/en/user/email/team-activation.html @@ -1 +1 @@ -Wire Account

wire.com

Your new account on Wire

A new Wire team was created with ${email}. Please verify your email.

 
Verify
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
+${brand} Account

${brand_label_url}

Your new account on ${brand}

A new ${brand} team was created with ${email}. Please verify your email.

 
Verify
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/team-activation.txt b/services/brig/deb/opt/brig/templates/en/user/email/team-activation.txt index a10f47635b9..7e64c9701d2 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/team-activation.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/team-activation.txt @@ -1,16 +1,19 @@ -YOUR NEW ACCOUNT ON WIRE -A new Wire team was created with ${email}. Please verify your email. +[${brand_logo}] + +${brand_label_url} [${brand_url}] + +YOUR NEW ACCOUNT ON ${brand} +A new ${brand} team was created with ${email}. Please verify your email. Verify [${url}]If you can’t click the button, copy and paste this link to your browser: ${url} -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/update-subject.txt b/services/brig/deb/opt/brig/templates/en/user/email/update-subject.txt index 97b5791f48e..62ff1daae5c 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/update-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/update-subject.txt @@ -1 +1 @@ -Your new email address on Wire \ No newline at end of file +Your new email address on ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/update.html b/services/brig/deb/opt/brig/templates/en/user/email/update.html index d9155cb86f1..e6cb7b14d6e 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/update.html +++ b/services/brig/deb/opt/brig/templates/en/user/email/update.html @@ -1 +1 @@ -Your new email address on Wire

wire.com

Verify your email

${email} was registered as your new email address on Wire. Click the button below to verify your address.

 
Verify
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file +Your new email address on ${brand}

${brand_label_url}

Verify your email

${email} was registered as your new email address on ${brand}. Click the button below to verify your address.

 
Verify
 

If you can’t click the button, copy and paste this link to your browser:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/update.txt b/services/brig/deb/opt/brig/templates/en/user/email/update.txt index 827e3aa0315..801abe887c4 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/update.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/update.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + VERIFY YOUR EMAIL -${email} was registered as your new email address on Wire. Click the button +${email} was registered as your new email address on ${brand}. Click the button below to verify your address. Verify [${url}]If you can’t click the button, copy and paste this link to your @@ -7,11 +11,10 @@ browser: ${url} -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/verification-subject.txt b/services/brig/deb/opt/brig/templates/en/user/email/verification-subject.txt index 76daa3ac562..64f64ad00fe 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/verification-subject.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/verification-subject.txt @@ -1 +1 @@ -Wire verification code is ${code} \ No newline at end of file +${brand} verification code is ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/verification.html b/services/brig/deb/opt/brig/templates/en/user/email/verification.html index c9133bd90f7..62e9e4534dd 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/verification.html +++ b/services/brig/deb/opt/brig/templates/en/user/email/verification.html @@ -1 +1 @@ -Wire verification code is ${code}

wire.com

Verify your email

${email} was used to register on Wire. Enter this code to verify your email and create your account.

 

${code}

 

If you have any questions, please contact us.

                                                           
\ No newline at end of file +${brand} verification code is ${code}

${brand_label_url}

Verify your email

${email} was used to register on ${brand}. Enter this code to verify your email and create your account.

 

${code}

 

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/email/verification.txt b/services/brig/deb/opt/brig/templates/en/user/email/verification.txt index f2f47e48fb6..d9f27a305e4 100644 --- a/services/brig/deb/opt/brig/templates/en/user/email/verification.txt +++ b/services/brig/deb/opt/brig/templates/en/user/email/verification.txt @@ -1,14 +1,17 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + VERIFY YOUR EMAIL -${email} was used to register on Wire. Enter this code to verify your email and -create your account. +${email} was used to register on ${brand}. Enter this code to verify your email +and create your account. ${code} -If you have any questions, please contact us -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privacy [https://wire.com/legal/] · Report Misuse [misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/en/user/sms/activation.txt b/services/brig/deb/opt/brig/templates/en/user/sms/activation.txt index 44f9a81b8c9..69d66e37b0c 100644 --- a/services/brig/deb/opt/brig/templates/en/user/sms/activation.txt +++ b/services/brig/deb/opt/brig/templates/en/user/sms/activation.txt @@ -1,3 +1,3 @@ -Your Wire code is ${code}. +Your ${brand} code is ${code}. Open ${url} to verify your number. diff --git a/services/brig/deb/opt/brig/templates/en/user/sms/deletion.txt b/services/brig/deb/opt/brig/templates/en/user/sms/deletion.txt index 32c9c20915d..07a9b8e54c1 100644 --- a/services/brig/deb/opt/brig/templates/en/user/sms/deletion.txt +++ b/services/brig/deb/opt/brig/templates/en/user/sms/deletion.txt @@ -1,2 +1,2 @@ -Tap to delete your Wire account. -${url} +Tap to delete your ${brand} account. +${url} diff --git a/services/brig/deb/opt/brig/templates/en/user/sms/login.txt b/services/brig/deb/opt/brig/templates/en/user/sms/login.txt index 547a6880cb1..26a0a436325 100644 --- a/services/brig/deb/opt/brig/templates/en/user/sms/login.txt +++ b/services/brig/deb/opt/brig/templates/en/user/sms/login.txt @@ -1,3 +1,3 @@ -Your Wire login code is ${code}. +Your ${brand} login code is ${code}. Open ${url} to log in. diff --git a/services/brig/deb/opt/brig/templates/en/user/sms/password-reset.txt b/services/brig/deb/opt/brig/templates/en/user/sms/password-reset.txt index 9b6a062aced..d99d8bff89a 100644 --- a/services/brig/deb/opt/brig/templates/en/user/sms/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/en/user/sms/password-reset.txt @@ -1,3 +1,3 @@ -Your Wire recovery code is ${code}. +Your ${brand} recovery code is ${code}. -Use this code to complete the password reset. \ No newline at end of file +Use this code to complete the password reset. diff --git a/services/brig/deb/opt/brig/templates/et/user/email/activation-subject.txt b/services/brig/deb/opt/brig/templates/et/user/email/activation-subject.txt index d564267124a..ee2f8b6ce3d 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/activation-subject.txt @@ -1 +1 @@ -Sinu Wire konto \ No newline at end of file +Your ${brand} Account \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/activation.html b/services/brig/deb/opt/brig/templates/et/user/email/activation.html index da3e8465d78..8d22a627988 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/activation.html +++ b/services/brig/deb/opt/brig/templates/et/user/email/activation.html @@ -1 +1 @@ -Sinu Wire konto

wire.com

Kinnita oma e-posti aadress

${email} meiliaadressi kasutatu Wire konto loomiseks.
Kliki allolevat nuppu, et oma meiliaadress kinnitada.

 
Kinnita
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

Küsimuste korral võtke ühendust.

                                                           
\ No newline at end of file +Your ${brand} Account

${brand_label_url}

Kinnita oma e-posti aadress

${email} was used to register on ${brand}.
Click the button to verify your address.

 
Kinnita
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/activation.txt b/services/brig/deb/opt/brig/templates/et/user/email/activation.txt index c69fd4b21e5..5b479ed1a56 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/activation.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/activation.txt @@ -1,17 +1,20 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + KINNITA OMA E-POSTI AADRESS -${email} meiliaadressi kasutatu Wire konto loomiseks. -Kliki allolevat nuppu, et oma meiliaadress kinnitada. +${email} was used to register on ${brand}. +Click the button to verify your address. Kinnita [${url}]Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse: ${url} -Küsimuste korral võtke ühendust [https://support.wire.com/hc/en-us/requests/new] -. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privaatsus [https://wire.com/legal/] · Klienditugi [misuse@wire.com] -© WIRE SWISS GmbH. Kõik õigused kaitstud. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/deletion.html b/services/brig/deb/opt/brig/templates/et/user/email/deletion.html index f3aa5468f03..3fb80587843 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/deletion.html +++ b/services/brig/deb/opt/brig/templates/et/user/email/deletion.html @@ -1 +1 @@ -Kustuta konto?

wire.com

Kustuta konto

Saime päringu su Wire konto kustutada. Kogu kontoga seotud info kustutamise kinnitamiseks kliki kümne minuti jooksul alloleval lingil.

 
Kustuta konto
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

Kui see polnud sina, kes konto kustutamise tellis, siis soovitame kindlasti parooli ära muuta.

Küsimuste korral võtke ühendust.

                                                           
\ No newline at end of file +Kustuta konto?

${brand_label_url}

Kustuta konto

We’ve received a request to delete your ${brand} account. Kogu kontoga seotud info kustutamise kinnitamiseks kliki kümne minuti jooksul alloleval lingil.

 
Kustuta konto
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

If you didn’t request this, reset your password.

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/deletion.txt b/services/brig/deb/opt/brig/templates/et/user/email/deletion.txt index 97748301f6c..68255a33b63 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/deletion.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/deletion.txt @@ -1,20 +1,22 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + KUSTUTA KONTO -Saime päringu su Wire konto kustutada. Kogu kontoga seotud info kustutamise -kinnitamiseks kliki kümne minuti jooksul alloleval lingil. +We’ve received a request to delete your ${brand} account. Kogu kontoga seotud +info kustutamise kinnitamiseks kliki kümne minuti jooksul alloleval lingil. Kustuta konto [${url}]Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse: ${url} -Kui see polnud sina, kes konto kustutamise tellis, siis soovitame kindlasti -parooli ära muuta [https://account.wire.com/forgot/]. +If you didn’t request this, reset your password [${forgot}]. -Küsimuste korral võtke ühendust [https://support.wire.com/hc/en-us/requests/new] -. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privaatsus [https://wire.com/legal/] · Klienditugi [misuse@wire.com] -© WIRE SWISS GmbH. Kõik õigused kaitstud. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/new-client.html b/services/brig/deb/opt/brig/templates/et/user/email/new-client.html index 0e96bc9b464..b84a0901e43 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/new-client.html +++ b/services/brig/deb/opt/brig/templates/et/user/email/new-client.html @@ -1 +1 @@ -Sisselogimine uuelt seadmelt

wire.com

Wire uuel seadmel

Sinu Wire kontot kasutati:

${date}

${model}

Võimalik põhjus – paigaldasid Wire uuele seadmele või paigaldasid selle seadmele, kus Wire on varem olnud, kuid siis eemaldatud. Kui see polnud sina, kes uuelt seadmelt sisse logis, siis ava Wire äpis Seaded > Seadmed ja kustuta tundmatu seade. Seejärel muuda oma parool ära.

Küsimuste korral võtke ühendust.

                                                           
\ No newline at end of file +Sisselogimine uuelt seadmelt

${brand_label_url}

Wire uuel seadmel

Your ${brand} account was used on:

${date}

${model}

You may have installed ${brand} on a new device or installed it again on an existing one. If that was not the case, go to ${brand} Settings, remove the device and reset your password.

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/new-client.txt b/services/brig/deb/opt/brig/templates/et/user/email/new-client.txt index 60d9bff035b..99a52c66d2e 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/new-client.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/new-client.txt @@ -1,21 +1,22 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + WIRE UUEL SEADMEL -Sinu Wire kontot kasutati: +Your ${brand} account was used on: ${date} ${model} -Võimalik põhjus – paigaldasid Wire uuele seadmele või paigaldasid selle -seadmele, kus Wire on varem olnud, kuid siis eemaldatud. Kui see polnud sina, -kes uuelt seadmelt sisse logis, siis ava Wire äpis Seaded > Seadmed ja kustuta -tundmatu seade. Seejärel muuda oma parool ära. -[https://account.wire.com/forgot/] +You may have installed ${brand} on a new device or installed it again on an +existing one. If that was not the case, go to ${brand} Settings, remove the +device and reset your password [${forgot}]. -Küsimuste korral võtke ühendust [https://support.wire.com/hc/en-us/requests/new] -. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privaatsus [https://wire.com/legal/] · Klienditugi [misuse@wire.com] -© WIRE SWISS GmbH. Kõik õigused kaitstud. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/password-reset-subject.txt b/services/brig/deb/opt/brig/templates/et/user/email/password-reset-subject.txt index de10faa191a..6a7bbce1a09 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/password-reset-subject.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/password-reset-subject.txt @@ -1 +1 @@ -Wire parooli muutmine \ No newline at end of file +Password Change at ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/password-reset.html b/services/brig/deb/opt/brig/templates/et/user/email/password-reset.html index b925857a8f8..1b13170a94a 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/password-reset.html +++ b/services/brig/deb/opt/brig/templates/et/user/email/password-reset.html @@ -1 +1 @@ -Wire parooli muutmine

wire.com

Lähtesta oma parool

Saime päringu sinu Wire konto parool ära muuta. Uue salasõna loomiseks vajutage järgmisele lingile:

 
Lähesta parool
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

Küsimuste korral võtke ühendust.

                                                           
\ No newline at end of file +Password Change at ${brand}

${brand_label_url}

Lähtesta oma parool

We’ve received a request to reset the password for your ${brand} account. Uue salasõna loomiseks vajutage järgmisele lingile:

 
Lähesta parool
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/password-reset.txt b/services/brig/deb/opt/brig/templates/et/user/email/password-reset.txt index b44c61837f5..72df2b6c90b 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/password-reset.txt @@ -1,17 +1,20 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + LÄHTESTA OMA PAROOL -Saime päringu sinu Wire konto parool ära muuta. Uue salasõna loomiseks vajutage -järgmisele lingile: +We’ve received a request to reset the password for your ${brand} account. Uue +salasõna loomiseks vajutage järgmisele lingile: Lähesta parool [${url}]Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse: ${url} -Küsimuste korral võtke ühendust [https://support.wire.com/hc/en-us/requests/new] -. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privaatsus [https://wire.com/legal/] · Klienditugi [misuse@wire.com] -© WIRE SWISS GmbH. Kõik õigused kaitstud. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/team-activation-subject.txt b/services/brig/deb/opt/brig/templates/et/user/email/team-activation-subject.txt index d564267124a..3e5330c275a 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/team-activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/team-activation-subject.txt @@ -1 +1 @@ -Sinu Wire konto \ No newline at end of file +${brand} Account \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/team-activation.html b/services/brig/deb/opt/brig/templates/et/user/email/team-activation.html index ede0e51f755..59cf5a03e05 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/team-activation.html +++ b/services/brig/deb/opt/brig/templates/et/user/email/team-activation.html @@ -1 +1 @@ -Sinu Wire konto

wire.com

Sinu uus Wire konto

Meiliaadressiga ${email} loodi äsja Wire rakenduses uus tiimikonto. Palun kinnita oma meiliaadress.

 
Kinnita
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

Küsimuste korral võtke ühendust.

                                                           
+${brand} Account

${brand_label_url}

Your new account on ${brand}

A new ${brand} team was created with ${email}. Palun kinnita oma meiliaadress.

 
Kinnita
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/team-activation.txt b/services/brig/deb/opt/brig/templates/et/user/email/team-activation.txt index ab7cd9afa5d..538d0626d18 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/team-activation.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/team-activation.txt @@ -1,17 +1,19 @@ -SINU UUS WIRE KONTO -Meiliaadressiga ${email} loodi äsja Wire rakenduses uus tiimikonto. Palun -kinnita oma meiliaadress. +[${brand_logo}] + +${brand_label_url} [${brand_url}] + +YOUR NEW ACCOUNT ON ${brand} +A new ${brand} team was created with ${email}. Palun kinnita oma meiliaadress. Kinnita [${url}]Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse: ${url} -Küsimuste korral võtke ühendust [https://support.wire.com/hc/en-us/requests/new] -. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privaatsus [https://wire.com/legal/] · Klienditugi [misuse@wire.com] -© WIRE SWISS GmbH. Kõik õigused kaitstud. +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/update-subject.txt b/services/brig/deb/opt/brig/templates/et/user/email/update-subject.txt index 67b7b03d8c1..62ff1daae5c 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/update-subject.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/update-subject.txt @@ -1 +1 @@ -Uus Wire'ga seotud meiliaadress \ No newline at end of file +Your new email address on ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/update.html b/services/brig/deb/opt/brig/templates/et/user/email/update.html index 1547fbfb16f..c60eb119c37 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/update.html +++ b/services/brig/deb/opt/brig/templates/et/user/email/update.html @@ -1 +1 @@ -Uus Wire'ga seotud meiliaadress

wire.com

Kinnita oma e-posti aadress

${email} on Wire'is nüüd registreeritud kui sinu uus meiliaadress. Aadressi kinnitamiseks kliki alloleval lingil.

 
Kinnita
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

Küsimuste korral võtke ühendust.

                                                           
\ No newline at end of file +Your new email address on ${brand}

${brand_label_url}

Kinnita oma e-posti aadress

${email} was registered as your new email address on ${brand}. Aadressi kinnitamiseks kliki alloleval lingil.

 
Kinnita
 

Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev aadress veebibrauserisse:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/update.txt b/services/brig/deb/opt/brig/templates/et/user/email/update.txt index 610bc9212e4..ea0c2a7f7b8 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/update.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/update.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + KINNITA OMA E-POSTI AADRESS -${email} on Wire'is nüüd registreeritud kui sinu uus meiliaadress. Aadressi +${email} was registered as your new email address on ${brand}. Aadressi kinnitamiseks kliki alloleval lingil. Kinnita [${url}]Kui sul pole võimalik nuppu klikkida, siis kopeeri allolev @@ -7,11 +11,10 @@ aadress veebibrauserisse: ${url} -Küsimuste korral võtke ühendust [https://support.wire.com/hc/en-us/requests/new] -. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privaatsus [https://wire.com/legal/] · Klienditugi [misuse@wire.com] -© WIRE SWISS GmbH. Kõik õigused kaitstud. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/verification-subject.txt b/services/brig/deb/opt/brig/templates/et/user/email/verification-subject.txt index ea908fd924a..64f64ad00fe 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/verification-subject.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/verification-subject.txt @@ -1 +1 @@ -Wire konto kinnituskood on ${code} \ No newline at end of file +${brand} verification code is ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/verification.html b/services/brig/deb/opt/brig/templates/et/user/email/verification.html index 9f3ce1d54b1..28f72733476 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/verification.html +++ b/services/brig/deb/opt/brig/templates/et/user/email/verification.html @@ -1 +1 @@ -Wire konto kinnituskood on ${code}

wire.com

Kinnita oma e-posti aadress

Meiliaadressi ${email} kasutati Wire konto loomiseks. Konto loomiseks sisestage see kood brauseriaknas.

 

${code}

 

Küsimuste korral võtke ühendust.

                                                           
\ No newline at end of file +${brand} verification code is ${code}

${brand_label_url}

Kinnita oma e-posti aadress

${email} was used to register on ${brand}. Konto loomiseks sisestage see kood brauseriaknas.

 

${code}

 

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/email/verification.txt b/services/brig/deb/opt/brig/templates/et/user/email/verification.txt index 6fe1833653b..243a7246988 100644 --- a/services/brig/deb/opt/brig/templates/et/user/email/verification.txt +++ b/services/brig/deb/opt/brig/templates/et/user/email/verification.txt @@ -1,14 +1,17 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + KINNITA OMA E-POSTI AADRESS -Meiliaadressi ${email} kasutati Wire konto loomiseks. Konto loomiseks sisestage -see kood brauseriaknas. +${email} was used to register on ${brand}. Konto loomiseks sisestage see kood +brauseriaknas. ${code} -Küsimuste korral võtke ühendust [https://support.wire.com/hc/en-us/requests/new] -. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privaatsus [https://wire.com/legal/] · Klienditugi [misuse@wire.com] -© WIRE SWISS GmbH. Kõik õigused kaitstud. \ No newline at end of file +Privacy [${legal}] · Report Misuse [${misuse}] +${copyright}. ALL RIGHTS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/et/user/sms/activation.txt b/services/brig/deb/opt/brig/templates/et/user/sms/activation.txt index 0ff06c67911..ddc0b074631 100644 --- a/services/brig/deb/opt/brig/templates/et/user/sms/activation.txt +++ b/services/brig/deb/opt/brig/templates/et/user/sms/activation.txt @@ -1,3 +1,3 @@ -Sinu Wire kood on ${code} +Your ${brand} code is ${code}. Toksa ${url} et number kinnitada. diff --git a/services/brig/deb/opt/brig/templates/et/user/sms/deletion.txt b/services/brig/deb/opt/brig/templates/et/user/sms/deletion.txt index 158c661bd33..07a9b8e54c1 100644 --- a/services/brig/deb/opt/brig/templates/et/user/sms/deletion.txt +++ b/services/brig/deb/opt/brig/templates/et/user/sms/deletion.txt @@ -1,2 +1,2 @@ -Wire konto kustutamiseks toksa lingil. -${url} +Tap to delete your ${brand} account. +${url} diff --git a/services/brig/deb/opt/brig/templates/et/user/sms/login.txt b/services/brig/deb/opt/brig/templates/et/user/sms/login.txt index 19eb9f0314f..34755c3343a 100644 --- a/services/brig/deb/opt/brig/templates/et/user/sms/login.txt +++ b/services/brig/deb/opt/brig/templates/et/user/sms/login.txt @@ -1,3 +1,3 @@ -Sinu Wire sisselogimiskood on ${code} +Your ${brand} login code is ${code}. Sisselogimiseks ava aadress ${url} diff --git a/services/brig/deb/opt/brig/templates/et/user/sms/password-reset.txt b/services/brig/deb/opt/brig/templates/et/user/sms/password-reset.txt index 7ff10293461..067c0e51f62 100644 --- a/services/brig/deb/opt/brig/templates/et/user/sms/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/et/user/sms/password-reset.txt @@ -1,3 +1,3 @@ -Sinu Wire kood on ${code} +Your ${brand} recovery code is ${code}. -Kasuta seda koodi parooli muutmiseks. \ No newline at end of file +Kasuta seda koodi parooli muutmiseks. diff --git a/services/brig/deb/opt/brig/templates/fr/user/call/activation.txt b/services/brig/deb/opt/brig/templates/fr/user/call/activation.txt index 6afb53c54a4..391fe95d6ac 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/call/activation.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/call/activation.txt @@ -1 +1 @@ -Votre code Wire est ${code}. +Bonjour, votre code de vérification pour Wire est : ${code}. Je répète, votre code est : ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/call/login.txt b/services/brig/deb/opt/brig/templates/fr/user/call/login.txt index 2637232d001..20a123ba2c1 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/call/login.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/call/login.txt @@ -1 +1 @@ -Votre code de connexion Wire est ${code}. +Bonjour, votre code de connexion Wire est : ${code}. Je répète, votre code est : ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/activation-subject.txt b/services/brig/deb/opt/brig/templates/fr/user/email/activation-subject.txt index 463fdb6626e..2953594b3a0 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/activation-subject.txt @@ -1 +1 @@ -Votre compte Wire \ No newline at end of file +Votre Compte ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/activation.html b/services/brig/deb/opt/brig/templates/fr/user/email/activation.html index 3dc9060286a..5a5a63f80fc 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/activation.html +++ b/services/brig/deb/opt/brig/templates/fr/user/email/activation.html @@ -1,127 +1 @@ - - - - - - - -
- - - - - - - - - - - - - - - - - -
- - - wire.com -
-

- Bonjour, -

- -

- ${email} a été utilisé pour créer un compte Wire. Veuillez vérifier votre email s’il vous plaît. -

-

- - VÉRIFIER - -

-

- Cliquez sur le bouton ci-dessus pour vérifier votre adresse. Vous ne pourrez pas utiliser Wire si vous ne le faîtes pas. -

-

- Si vous ne pouvez pas cliquer sur le bouton, utilisez ce lien :
-

-

- ${url} -

-

- Si vous n'avez pas demandé ce changement, vous pouvez ignorer ce mail ou - - nous informer - . -

-
- Politique de confidentialité· - Signaler un abus -
- © Wire Swiss GmbH. Tous droits réservés. -
- - +Votre Compte ${brand}

${brand_label_url}

Vérification de votre adresse email

${email} a été utilisé pour s'enregistrer sur ${brand}.
Cliquez sur le bouton ci-dessous pour vérifier votre adresse.

 
Vérifier
 

Si vous ne pouvez pas cliquer sur le bouton, copiez et collez ce lien dans votre navigateur :

${url}

Si vous avez des questions, veuillez contactez-nous.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/activation.txt b/services/brig/deb/opt/brig/templates/fr/user/email/activation.txt index 842fff0428a..f5afab3b144 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/activation.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/activation.txt @@ -1,22 +1,20 @@ -Wire +[${brand_logo}] +${brand_label_url} [${brand_url}] -Bonjour, - -Votre adresse email ${email} a été utilisée pour créer un compte Wire. Veuillez vérifier votre email s’il vous plaît. - -Suivez le lien ci-dessous afin de vérifier votre adresse. Vous ne pourrez pas utiliser Wire si vous ne le faîtes pas. +VÉRIFICATION DE VOTRE ADRESSE EMAIL +${email} a été utilisé pour s'enregistrer sur ${brand}. +Cliquez sur le bouton ci-dessous pour vérifier votre adresse. +Vérifier [${url}]Si vous ne pouvez pas cliquer sur le bouton, copiez et collez +ce lien dans votre navigateur : ${url} -Merci de ne pas répondre à ce message. - -Si vous n'avez pas créé de compte Wire en utilisant cette adresse email, merci de visiter https://support.wire.com - - +Si vous avez des questions, veuillez contactez-nous [${support}]. -(c) Wire Swiss GmbH +-------------------------------------------------------------------------------- -Politique de confidentialité | Signaler un abus +Confidentialité [${legal}] · Report Misuse [${misuse}] +${copyright}. TOUTES DROITS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/deletion-subject.txt b/services/brig/deb/opt/brig/templates/fr/user/email/deletion-subject.txt index 7c24b196020..38c749c8611 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/deletion-subject.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/deletion-subject.txt @@ -1 +1 @@ -Supprimer le compte? \ No newline at end of file +Supprimer votre compte ? \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/deletion.html b/services/brig/deb/opt/brig/templates/fr/user/email/deletion.html index 82d5840208c..27ee8750023 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/deletion.html +++ b/services/brig/deb/opt/brig/templates/fr/user/email/deletion.html @@ -1,126 +1 @@ - - - - - - - -
- - - - - - - - - - - - - - - - - -
- - - wire.com -
-

- Bonjour ${name}, -

- -

- Nous avons reçu une demande de suppression de votre compte Wire. Cliquez sur le bouton ci-dessous dans les 10 minutes qui suivent afin de supprimer toutes vos conversations, contenus et connexions. -

-

- - SUPPRIMER VOTRE COMPTE - -

-

- Si vous ne pouvez pas cliquer sur le bouton, utilisez ce lien :
-

-

- ${url} -

-

- Si vous n'êtes pas à l'origine de la demande, réinitialisez votre mot de passe. -

-

- L'équipe Wire -

-
- Politique de confidentialité · - Signaler un abus -
- © Wire Swiss GmbH. Tous droits réservés. -
- - +Supprimer votre compte ?

${brand_label_url}

Supprimer votre compte

Nous avons reçu une demande de suppression de votre compte ${brand}. Cliquez sur le lien ci-dessous dans les 10 minutes pour supprimer toutes vos conversations, contenus et connexions.

 
Supprimer le compte
 

Si vous ne pouvez pas cliquer sur le bouton, copiez et collez ce lien dans votre navigateur :

${url}

Si vous n'êtes pas à l'origine de cette demande, réinitialisez votre mot de passe.

Si vous avez des questions, veuillez contactez-nous.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/deletion.txt b/services/brig/deb/opt/brig/templates/fr/user/email/deletion.txt index 0d7139fa7b2..03ab049b06a 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/deletion.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/deletion.txt @@ -1,17 +1,24 @@ -Wire +[${brand_logo}] +${brand_label_url} [${brand_url}] -Bonjour ${name}, +SUPPRIMER VOTRE COMPTE +Nous avons reçu une demande de suppression de votre compte ${brand}. Cliquez sur +le lien ci-dessous dans les 10 minutes pour supprimer toutes vos conversations, +contenus et connexions. -Nous avons reçu une demande de suppression de votre compte Wire. Cliquez sur le lien ci-dessous dans les 10 minutes pour supprimer toutes vos conversations, contenus et connexions. +Supprimer le compte [${url}]Si vous ne pouvez pas cliquer sur le bouton, copiez +et collez ce lien dans votre navigateur : ${url} -Si vous n'êtes pas à l'origine de la demande, réinitialisez votre mot de passe. +Si vous n'êtes pas à l'origine de cette demande, réinitialisez votre mot de +passe [${forgot}]. -L'équipe Wire +Si vous avez des questions, veuillez contactez-nous [${support}]. -(c) Wire Swiss GmbH +-------------------------------------------------------------------------------- -Politique de confidentialité | Signaler un abus +Confidentialité [${legal}] · Report Misuse [${misuse}] +${copyright}. TOUTES DROITS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/new-client.html b/services/brig/deb/opt/brig/templates/fr/user/email/new-client.html index 4defadc0973..f14f34cd5ca 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/new-client.html +++ b/services/brig/deb/opt/brig/templates/fr/user/email/new-client.html @@ -1,102 +1 @@ - - - - - - - -
- - - - - - - - - - - - - - - - - -
- - - wire.com -
-

- Bonjour ${name}, -

- -

- Votre compte Wire a été utilisé le : -

- -

- ${date} -

-

- ${model} -

- -

- Il se peut que vous ayez installé Wire sur un nouvel appareil ou réinstallé sur le même. Si ce n'est pas le cas, allez dans les Paramètres de Wire, supprimez l'appareil et réinitialisez votre mot de passe. -

- -

- L'équipe Wire -

-
- Politique de confidentialité · - Signaler un abus -
- © Wire Swiss GmbH. Tous droits réservés. -
- - +Nouvel appareil

${brand_label_url}

Nouvel appareil

Votre compte ${brand} a été utilisé sur :

${date}

${model}

Il se peut que vous ayez installé ${brand} sur un nouvel appareil ou réinstallé sur le même. Si ce n'était pas le cas, allez dans les paramètres de ${brand}, retirez cet appareil et réinitialisez votre mot de passe.

Si vous avez des questions, veuillez contactez-nous.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/new-client.txt b/services/brig/deb/opt/brig/templates/fr/user/email/new-client.txt index da24c2e1e5e..388718cfaa2 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/new-client.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/new-client.txt @@ -1,18 +1,22 @@ -Wire +[${brand_logo}] +${brand_label_url} [${brand_url}] -Bonjour ${name}, +NOUVEL APPAREIL +Votre compte ${brand} a été utilisé sur : -Votre compte Wire a été utilisé le : +${date} - ${date} - ${model} +${model} -Il se peut que vous ayez installé Wire sur un nouvel appareil ou réinstallé sur le même. Si ce n'est pas le cas, allez dans les Paramètres de Wire, supprimez l'appareil et réinitialisez votre mot de passe. +Il se peut que vous ayez installé ${brand} sur un nouvel appareil ou réinstallé +sur le même. Si ce n'était pas le cas, allez dans les paramètres de ${brand}, +retirez cet appareil et réinitialisez votre mot de passe [${forgot}]. -L'équipe Wire +Si vous avez des questions, veuillez contactez-nous [${support}]. -(c) Wire Swiss GmbH +-------------------------------------------------------------------------------- -Politique de confidentialité | Signaler un abus +Confidentialité [${legal}] · Report Misuse [${misuse}] +${copyright}. TOUTES DROITS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/password-reset-subject.txt b/services/brig/deb/opt/brig/templates/fr/user/email/password-reset-subject.txt index 2eab30b593b..10dcaee48dc 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/password-reset-subject.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/password-reset-subject.txt @@ -1 +1 @@ -Changement de mot de passe Wire \ No newline at end of file +Réinitialisation du mot de passe ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/password-reset.html b/services/brig/deb/opt/brig/templates/fr/user/email/password-reset.html index 348026cc9f5..e1bec18caac 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/password-reset.html +++ b/services/brig/deb/opt/brig/templates/fr/user/email/password-reset.html @@ -1,119 +1 @@ - - - - - - - -
- - - - - - - - - - - - - - - - - -
- - - wire.com -
-

- Bonjour, -

-

- Nous avons reçu une demande de changement de mot de passe pour votre compte Wire. - Pour changer votre mot de passe, cliquez sur le bouton ci-dessous. -

-

- - CHANGER DE MOT DE PASSE - -

-

- Si vous ne pouvez pas cliquer sur le bouton, utilisez ce lien :
-

-

- ${url} -

-

- Ceci est un message automatisé et personne ne verra votre réponse. -

-
- Politique de confidentialité · - Signaler un abus -
- © Wire Swiss GmbH. Tous droits réservés. -
- - +Réinitialisation du mot de passe ${brand}

${brand_label_url}

Réinitialiser votre mot de passe

Nous avons reçu une demande pour réinitialiser le mot de passe de votre compte ${brand}. Pour créer un nouveau mot de passe, cliquez sur le bouton ci-dessous.

 
Réinitialiser le mot de passe
 

Si vous ne pouvez pas cliquer sur le bouton, copiez et collez ce lien dans votre navigateur :

${url}

Si vous avez des questions, veuillez contactez-nous.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/password-reset.txt b/services/brig/deb/opt/brig/templates/fr/user/email/password-reset.txt index ddd8def24a5..302f2a98ea4 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/password-reset.txt @@ -1,21 +1,20 @@ -Wire +[${brand_logo}] +${brand_label_url} [${brand_url}] -Bonjour, +RÉINITIALISER VOTRE MOT DE PASSE +Nous avons reçu une demande pour réinitialiser le mot de passe de votre compte +${brand}. Pour créer un nouveau mot de passe, cliquez sur le bouton ci-dessous. -Nous avons reçu une demande de changement de mot de passe pour votre compte Wire. - -Pour modifier votre mot de passe, suivez le lien ci-dessous. +Réinitialiser le mot de passe [${url}]Si vous ne pouvez pas cliquer sur le +bouton, copiez et collez ce lien dans votre navigateur : ${url} -Merci de ne pas répondre à ce message. - -Ceci est un message automatisé et personne ne verra votre réponse. -Si vous désirez plus d'informations, veuillez visiter https://support.wire.com - +Si vous avez des questions, veuillez contactez-nous [${support}]. -(c) Wire Swiss GmbH +-------------------------------------------------------------------------------- -Politique de confidentialité | Signaler un abus +Confidentialité [${legal}] · Report Misuse [${misuse}] +${copyright}. TOUTES DROITS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/team-activation-subject.txt b/services/brig/deb/opt/brig/templates/fr/user/email/team-activation-subject.txt index 463fdb6626e..6bc70f2c02b 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/team-activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/team-activation-subject.txt @@ -1 +1 @@ -Votre compte Wire \ No newline at end of file +Compte ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/team-activation.html b/services/brig/deb/opt/brig/templates/fr/user/email/team-activation.html index 7935a54f404..8e6bb7de2f6 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/team-activation.html +++ b/services/brig/deb/opt/brig/templates/fr/user/email/team-activation.html @@ -1,121 +1 @@ - - - - - - - -
- - - - -
-
- - - - - - - - - - - - - - - - - -
- Wire - - wire.com -
-

- Votre nouveau compte Wire -

-
-

- Une nouvelle team sur Wire a été créée avec ${email}. Veuillez vérifier votre email s’il vous plaît. -

-

- - VÉRIFIER - -

-

- Cliquez sur le bouton ci-dessus pour vérifier votre adresse. Vous ne pourrez pas utiliser Wire si vous ne le faîtes pas. -

-

- Si vous ne pouvez pas cliquer sur le bouton, utilisez ce lien:
-

-

- ${url} -

-

- Si vous n'avez pas demandé ce changement, vous pouvez ignorer ce mail ou - - nous informer - . -

-
- Politique de confidentialité· - Signaler un abus
Wire Swiss GmbH. Tous droits réservés. -
-
-
- - +Compte ${brand}

${brand_label_url}

Votre nouveau compte ${brand}

Une nouvelle équipé a été créée sur ${brand} avec ${email}. Veuillez vérifier votre adresse email s’il vous plaît.

 
Vérifier
 

Si vous ne pouvez pas cliquer sur le bouton, copiez et collez ce lien dans votre navigateur :

${url}

Si vous avez des questions, veuillez contactez-nous.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/team-activation.txt b/services/brig/deb/opt/brig/templates/fr/user/email/team-activation.txt index 43b1bd51824..ea08d4b8353 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/team-activation.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/team-activation.txt @@ -1,22 +1,20 @@ -Wire +[${brand_logo}] +${brand_label_url} [${brand_url}] -Bonjour, - -Une nouvelle team a été créée sur Wire avec ${email}. Veuillez vérifier votre email s’il vous plaît. - -Suivez le lien ci-dessous afin de vérifier votre adresse. Vous ne pourrez pas utiliser Wire si vous ne le faîtes pas. +VOTRE NOUVEAU COMPTE ${brand} +Une nouvelle équipé a été créée sur ${brand} avec ${email}. Veuillez vérifier +votre adresse email s’il vous plaît. +Vérifier [${url}]Si vous ne pouvez pas cliquer sur le bouton, copiez et collez +ce lien dans votre navigateur : ${url} -Merci de ne pas répondre à ce message. - -Si vous n'avez pas créé de compte Wire en utilisant cette adresse email, merci de visiter https://support.wire.com - - +Si vous avez des questions, veuillez contactez-nous [${support}]. -(c) Wire Swiss GmbH +-------------------------------------------------------------------------------- -Politique de confidentialité | Signaler un abus +Confidentialité [${legal}] · Report Misuse [${misuse}] +${copyright}. TOUTES DROITS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/update-subject.txt b/services/brig/deb/opt/brig/templates/fr/user/email/update-subject.txt index fc584fbd3a2..6ea81448df6 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/update-subject.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/update-subject.txt @@ -1 +1 @@ -Votre nouvelle adresse e-mail sur Wire \ No newline at end of file +Votre nouvelle adresse e-mail sur ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/update.html b/services/brig/deb/opt/brig/templates/fr/user/email/update.html index ed47c30e077..ebc43c79776 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/update.html +++ b/services/brig/deb/opt/brig/templates/fr/user/email/update.html @@ -1,126 +1 @@ - - - - - - - -
- - - - - - - - - - - - - - - - - -
- - - wire.com -
-

- Bonjour, -

- -

- ${email} a été enregistré comme votre nouvelle adresse email sur Wire. Veuillez vérifier votre email s’il vous plaît. -

-

- - VÉRIFIER - -

-

- Cliquez sur le bouton ci-dessus pour vérifier votre nouvelle adresse e-mail. -

-

- Si vous ne pouvez pas cliquer sur le bouton, utilisez ce lien :
-

-

- ${url} -

-

- Si vous n'avez pas demandé ce changement, vous pouvez ignorer ce mail ou - - nous informer - . -

-
- Politique de confidentialité· - Signaler un abus -
- © Wire Swiss GmbH. Tous droits réservés. -
- - +Votre nouvelle adresse e-mail sur ${brand}

${brand_label_url}

Vérification de votre adresse email

${email} a été enregistré comme votre nouvelle adresse email sur ${brand}. Veuillez vérifier votre email s’il vous plaît. Cliquez sur le bouton ci-dessous pour vérifier votre adresse email.

 
Vérifier
 

Si vous ne pouvez pas cliquer sur le bouton, copiez et collez ce lien dans votre navigateur :

${url}

Si vous avez des questions, veuillez contactez-nous.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/update.txt b/services/brig/deb/opt/brig/templates/fr/user/email/update.txt index d455ca680e8..cf63735f929 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/update.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/update.txt @@ -1,22 +1,21 @@ -Wire +[${brand_logo}] +${brand_label_url} [${brand_url}] -Bonjour, - -${email} est votre nouvelle adresse e-mail sur Wire. Veuillez vérifier votre email s’il vous plaît. - -Cliquez sur le lien ci-dessous afin de vérifier votre nouvelle adresse. +VÉRIFICATION DE VOTRE ADRESSE EMAIL +${email} a été enregistré comme votre nouvelle adresse email sur ${brand}. +Veuillez vérifier votre email s’il vous plaît. Cliquez sur le bouton ci-dessous +pour vérifier votre adresse email. +Vérifier [${url}]Si vous ne pouvez pas cliquer sur le bouton, copiez et collez +ce lien dans votre navigateur : ${url} -Veuillez ne pas répondre à ce message. - -Si vous n'avez pas demandé ce changement, vous pouvez ignorer ce mail ou vous rendre sur https://support.wire.com - - +Si vous avez des questions, veuillez contactez-nous [${support}]. -(c) Wire Swiss GmbH +-------------------------------------------------------------------------------- -Politique de confidentialité | Signaler un abus +Confidentialité [${legal}] · Report Misuse [${misuse}] +${copyright}. TOUTES DROITS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/verification-subject.txt b/services/brig/deb/opt/brig/templates/fr/user/email/verification-subject.txt index 65d8a8167c9..9f0a5996390 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/verification-subject.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/verification-subject.txt @@ -1 +1 @@ -Code de vérification Wire : ${code} \ No newline at end of file +Votre code de vérification ${brand} est ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/verification.html b/services/brig/deb/opt/brig/templates/fr/user/email/verification.html index 0bd76be9eb7..35323075161 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/verification.html +++ b/services/brig/deb/opt/brig/templates/fr/user/email/verification.html @@ -1,82 +1 @@ - - - - - - - -
- - - - -
-
- - - - - - - - - - - - - - - - - -
- Wire - - wire.com -
-

- Vérification de votre adresse email -

-
-

- ${email} a été utilisée pour vous inscrire sur Wire. Entrez ce code afin de vérifier votre adresse email et créer votre compte. -

-

- ${code} -

-

- Si vous n'avez pas demandé ce changement, vous pouvez ignorer ce mail ou - - nous informer - . -

-
- Politique de confidentialité· - Signaler un abus
Wire Swiss GmbH. Tous droits réservés. -
-
-
- - +Votre code de vérification ${brand} est ${code}

${brand_label_url}

Vérification de votre adresse email

L'adresse ${email} a été utilisée pour créer un compte sur ${brand}. Entrez ce code afin de vérifier votre adresse email et créer votre compte.

 

${code}

 

Si vous avez des questions, veuillez contactez-nous.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/email/verification.txt b/services/brig/deb/opt/brig/templates/fr/user/email/verification.txt index fd7c118cf42..1988898eeb0 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/email/verification.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/email/verification.txt @@ -1,18 +1,17 @@ -Wire +[${brand_logo}] +${brand_label_url} [${brand_url}] -Bonjour, - -${email} a été utilisée pour vous inscrire sur Wire. Entrez ce code afin de vérifier votre adresse email et créer votre compte. +VÉRIFICATION DE VOTRE ADRESSE EMAIL +L'adresse ${email} a été utilisée pour créer un compte sur ${brand}. Entrez ce +code afin de vérifier votre adresse email et créer votre compte. ${code} -Merci de ne pas répondre à ce message. - -Si vous n'avez pas créé de compte Wire en utilisant cette adresse email, merci de visiter https://support.wire.com - +Si vous avez des questions, veuillez contactez-nous [${support}]. -(c) Wire Swiss GmbH +-------------------------------------------------------------------------------- -Politique de confidentialité | Signaler un abus +Confidentialité [${legal}] · Report Misuse [${misuse}] +${copyright}. TOUTES DROITS RESERVED. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/fr/user/sms/activation.txt b/services/brig/deb/opt/brig/templates/fr/user/sms/activation.txt index 636ad96d0e6..be11bb1e3c1 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/sms/activation.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/sms/activation.txt @@ -1,3 +1,3 @@ -Votre code Wire est ${code}. +Votre code ${brand} est ${code}. -Afin de vérifier votre compte, ouvrez ${url} ou entrez manuellement le code ci-dessus dans Wire. +Ouvrez ${url} pour vérifier votre numéro. diff --git a/services/brig/deb/opt/brig/templates/fr/user/sms/deletion.txt b/services/brig/deb/opt/brig/templates/fr/user/sms/deletion.txt index 7116c6787ca..8fb5c0c3b57 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/sms/deletion.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/sms/deletion.txt @@ -1,2 +1,2 @@ -Tappez afin de supprimer votre compte Wire. -${url} +Cliquez pour supprimer votre compte ${brand}. +${url} diff --git a/services/brig/deb/opt/brig/templates/fr/user/sms/login.txt b/services/brig/deb/opt/brig/templates/fr/user/sms/login.txt index 97dab0db8d8..0b859e561a6 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/sms/login.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/sms/login.txt @@ -1,3 +1,3 @@ -Votre code de connexion Wire est ${code}. +Votre code de connexion ${brand} est ${code}. -Entrez ce code sur Wire: ${code}. +Ouvrez ${url} pour vous connecter. diff --git a/services/brig/deb/opt/brig/templates/fr/user/sms/password-reset.txt b/services/brig/deb/opt/brig/templates/fr/user/sms/password-reset.txt index b9faa15f9a4..5ad45f6dd89 100644 --- a/services/brig/deb/opt/brig/templates/fr/user/sms/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/fr/user/sms/password-reset.txt @@ -1,3 +1,3 @@ -Votre code de récupération Wire est ${code}. +Votre code de récupération ${brand} est ${code}. -Ouvrez Wire et utilisez ce code pour terminer la réinitialisation du mot de passe. \ No newline at end of file +Utilisez ce code pour finir de réinitialiser votre mot de passe. diff --git a/services/brig/deb/opt/brig/templates/index.html b/services/brig/deb/opt/brig/templates/index.html index 750bd4b5a61..aef5a515aa1 100644 --- a/services/brig/deb/opt/brig/templates/index.html +++ b/services/brig/deb/opt/brig/templates/index.html @@ -4,4 +4,4 @@ link.rel = 'stylesheet'; link.href = '//cdnjs.cloudflare.com/ajax/libs/flag-icon-css/2.9.0/css/flag-icon.min.css'; document.head.appendChild(link); - }
 

Wire Email Templates Preview

Click the links below to display the content of each message:

Provider
  1. Activation
  2. Approval confirm
  3. Approval request
Team
  1. Invitation
  2. New member welcome
User
  1. Activation
  2. Deletion
  3. New client
  4. Password reset
  5. Update
  6. Verification
  7. Team activation
Billing
  1. Suspension

For source and instructions, see github.com/wireapp/wire-emails.

                                                           
+ }
 

Wire Email Templates Preview

Click the links below to display the content of each message:

Provider
  1. Activation
  2. Approval confirm
  3. Approval request
Team
  1. Invitation
  2. New member welcome
User
  1. Activation
  2. Deletion
  3. New client
  4. Password reset
  5. Update
  6. Verification
  7. Team activation
Billing
  1. Suspension

For source and instructions, see github.com/wireapp/wire-emails.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/call/activation.txt b/services/brig/deb/opt/brig/templates/lt/user/call/activation.txt index d70fafec595..579b007b3ee 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/call/activation.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/call/activation.txt @@ -1 +1 @@ -Sveiki, jūsų „Wire“ patvirtinimo kodas yra: ${code}. Dar kartą, jūsų kodas yra: ${code} +Sveiki, jūsų „Wire“ patvirtinimo kodas yra: ${code}. Dar kartą, jūsų kodas yra: ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/call/login.txt b/services/brig/deb/opt/brig/templates/lt/user/call/login.txt index b493dfd2b33..807fd238462 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/call/login.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/call/login.txt @@ -1 +1 @@ -Sveiki, jūsų „Wire“ prisijungimo kodas yra: ${code}. Dar kartą, jūsų kodas yra: ${code} +Sveiki, jūsų „Wire“ prisijungimo kodas yra: ${code}. Dar kartą, jūsų kodas yra: ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/activation-subject.txt b/services/brig/deb/opt/brig/templates/lt/user/email/activation-subject.txt index b99ec44d2b5..ee2f8b6ce3d 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/activation-subject.txt @@ -1 +1 @@ -Wire paskyra +Your ${brand} Account \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/activation.html b/services/brig/deb/opt/brig/templates/lt/user/email/activation.html index 2cd84757ecd..54fe886af10 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/activation.html +++ b/services/brig/deb/opt/brig/templates/lt/user/email/activation.html @@ -1 +1 @@ -Wire paskyra

wire.com

Patvirtinkite savo el. paštą

${email} buvo panaudotas, registruojantis Wire.
Norėdami patvirtinti savo adresą, spustelėkite mygtuką.

 
Patvirtinti
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

Jeigu turite kokių nors klausimų, susisiekite su mumis.

                                                           
+Your ${brand} Account

${brand_label_url}

Patvirtinkite savo el. paštą

${email} was used to register on ${brand}.
Click the button to verify your address.

 
Patvirtinti
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/activation.txt b/services/brig/deb/opt/brig/templates/lt/user/email/activation.txt index 03509dc6998..63173f9ae1b 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/activation.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/activation.txt @@ -1,18 +1,20 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + PATVIRTINKITE SAVO EL. PAŠTĄ -${email} buvo panaudotas, registruojantis Wire. -Norėdami patvirtinti savo adresą, spustelėkite mygtuką. +${email} was used to register on ${brand}. +Click the button to verify your address. Patvirtinti [${url}]Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę: ${url} -Jeigu turite kokių nors klausimų, susisiekite su mumis -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privatumas [https://wire.com/legal/] · Pranešti apie piktnaudžiavimą -[misuse@wire.com] -© WIRE SWISS GmbH. VISOS TEISĖS SAUGOMOS. +Privatumas [${legal}] · Pranešti apie piktnaudžiavimą [${misuse}] +${copyright}. VISOS TEISĖS SAUGOMOS. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/deletion-subject.txt b/services/brig/deb/opt/brig/templates/lt/user/email/deletion-subject.txt index e08e42663a9..ffb84baed5c 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/deletion-subject.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/deletion-subject.txt @@ -1 +1 @@ -Ištrinti paskyrą? +Ištrinti paskyrą? \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/deletion.html b/services/brig/deb/opt/brig/templates/lt/user/email/deletion.html index 8e5cf266905..bf753b484b0 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/deletion.html +++ b/services/brig/deb/opt/brig/templates/lt/user/email/deletion.html @@ -1 +1 @@ -Ištrinti paskyrą?

wire.com

Ištrinti jūsų paskyrą

Mes gavome užklausą ištrinti jūsų Wire paskyrą. Norėdami ištrinti visus savo pokalbius, visą turinį ir ryšius, 10 minučių bėgyje spustelėkite žemiau esantį mygtuką.

 
Ištrinti paskyrą
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

Jeigu jūs to neprašėte, tuomet atstatykite savo slaptažodį.

Jeigu turite kokių nors klausimų, susisiekite su mumis.

                                                           
+Ištrinti paskyrą?

${brand_label_url}

Ištrinti jūsų paskyrą

Mes gavome užklausą ištrinti jūsų ${brand} paskyrą. Norėdami ištrinti visus savo pokalbius, visą turinį ir ryšius, 10 minučių bėgyje spustelėkite žemiau esantį mygtuką.

 
Ištrinti paskyrą
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

Jeigu jūs nebuvote to užklausę, atstatykite savo slaptažodį.

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/deletion.txt b/services/brig/deb/opt/brig/templates/lt/user/email/deletion.txt index 64ee3429d7c..009299a73a2 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/deletion.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/deletion.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + IŠTRINTI JŪSŲ PASKYRĄ -Mes gavome užklausą ištrinti jūsų Wire paskyrą. Norėdami ištrinti visus savo +Mes gavome užklausą ištrinti jūsų ${brand} paskyrą. Norėdami ištrinti visus savo pokalbius, visą turinį ir ryšius, 10 minučių bėgyje spustelėkite žemiau esantį mygtuką. @@ -8,15 +12,12 @@ Ištrinti paskyrą [${url}]Jeigu negalite spustelėti ant mygtuko, nukopijuokite ${url} -Jeigu jūs to neprašėte, tuomet atstatykite savo slaptažodį -[https://account.wire.com/forgot/]. +Jeigu jūs nebuvote to užklausę, atstatykite savo slaptažodį [${forgot}]. -Jeigu turite kokių nors klausimų, susisiekite su mumis -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privatumas [https://wire.com/legal/] · Pranešti apie piktnaudžiavimą -[misuse@wire.com] -© WIRE SWISS GmbH. VISOS TEISĖS SAUGOMOS. +Privatumas [${legal}] · Pranešti apie piktnaudžiavimą [${misuse}] +${copyright}. VISOS TEISĖS SAUGOMOS. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/new-client-subject.txt b/services/brig/deb/opt/brig/templates/lt/user/email/new-client-subject.txt index b828e8a2a96..73c5b7588d6 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/new-client-subject.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/new-client-subject.txt @@ -1 +1 @@ -Naujas įrenginys +Naujas įrenginys \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/new-client.html b/services/brig/deb/opt/brig/templates/lt/user/email/new-client.html index 63ad270c06b..faee7ecf087 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/new-client.html +++ b/services/brig/deb/opt/brig/templates/lt/user/email/new-client.html @@ -1 +1 @@ -Naujas įrenginys

wire.com

Naujas įrenginys

Jūsų Wire paskyra buvo naudota:

${date}

${model}

Tikriausiai, įdiegėte Wire naujame įrenginyje arba iš naujo įdiegėte esamame įrenginyje. Jeigu to nedarėte, pereikite į Wire nustatymus, pašalinkite įrenginį ir atstatykite savo slaptažodį.

Jeigu turite kokių nors klausimų, susisiekite su mumis.

                                                           
+Naujas įrenginys

${brand_label_url}

Naujas įrenginys

Your ${brand} account was used on:

${date}

${model}

You may have installed ${brand} on a new device or installed it again on an existing one. If that was not the case, go to ${brand} Settings, remove the device and reset your password.

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/new-client.txt b/services/brig/deb/opt/brig/templates/lt/user/email/new-client.txt index 7c862723d0d..346f44783ee 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/new-client.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/new-client.txt @@ -1,20 +1,22 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + NAUJAS ĮRENGINYS -Jūsų Wire paskyra buvo naudota: +Your ${brand} account was used on: ${date} ${model} -Tikriausiai, įdiegėte Wire naujame įrenginyje arba iš naujo įdiegėte esamame -įrenginyje. Jeigu to nedarėte, pereikite į Wire nustatymus, pašalinkite įrenginį -ir atstatykite savo slaptažodį [https://account.wire.com/forgot/]. +You may have installed ${brand} on a new device or installed it again on an +existing one. If that was not the case, go to ${brand} Settings, remove the +device and reset your password [${forgot}]. -Jeigu turite kokių nors klausimų, susisiekite su mumis -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privatumas [https://wire.com/legal/] · Pranešti apie piktnaudžiavimą -[misuse@wire.com] -© WIRE SWISS GmbH. VISOS TEISĖS SAUGOMOS. +Privatumas [${legal}] · Pranešti apie piktnaudžiavimą [${misuse}] +${copyright}. VISOS TEISĖS SAUGOMOS. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/password-reset-subject.txt b/services/brig/deb/opt/brig/templates/lt/user/email/password-reset-subject.txt index 5212eff1ddb..6a7bbce1a09 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/password-reset-subject.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/password-reset-subject.txt @@ -1 +1 @@ -Wire slaptažodžio pakeitimas +Password Change at ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/password-reset.html b/services/brig/deb/opt/brig/templates/lt/user/email/password-reset.html index 36576ab3ed5..0e2eeff4908 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/password-reset.html +++ b/services/brig/deb/opt/brig/templates/lt/user/email/password-reset.html @@ -1 +1 @@ -Wire slaptažodžio pakeitimas

wire.com

Atstatyti jūsų slaptažodį

Mes gavome užklausą atstatyti jūsų Wire paskyros slaptažodį. Norėdami susikurti naują slaptažodį, spustelėkite mygtuką žemiau.

 
Atstatyti slaptažodį
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

Jeigu turite kokių nors klausimų, susisiekite su mumis.

                                                           
+Password Change at ${brand}

${brand_label_url}

Atstatyti jūsų slaptažodį

We’ve received a request to reset the password for your ${brand} account. Norėdami susikurti naują slaptažodį, spustelėkite mygtuką žemiau.

 
Atstatyti slaptažodį
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/password-reset.txt b/services/brig/deb/opt/brig/templates/lt/user/email/password-reset.txt index f551e14fcc2..356676900da 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/password-reset.txt @@ -1,18 +1,20 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + ATSTATYTI JŪSŲ SLAPTAŽODĮ -Mes gavome užklausą atstatyti jūsų Wire paskyros slaptažodį. Norėdami susikurti -naują slaptažodį, spustelėkite mygtuką žemiau. +We’ve received a request to reset the password for your ${brand} account. +Norėdami susikurti naują slaptažodį, spustelėkite mygtuką žemiau. Atstatyti slaptažodį [${url}]Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę: ${url} -Jeigu turite kokių nors klausimų, susisiekite su mumis -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privatumas [https://wire.com/legal/] · Pranešti apie piktnaudžiavimą -[misuse@wire.com] -© WIRE SWISS GmbH. VISOS TEISĖS SAUGOMOS. +Privatumas [${legal}] · Pranešti apie piktnaudžiavimą [${misuse}] +${copyright}. VISOS TEISĖS SAUGOMOS. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/team-activation-subject.txt b/services/brig/deb/opt/brig/templates/lt/user/email/team-activation-subject.txt index b99ec44d2b5..3e5330c275a 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/team-activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/team-activation-subject.txt @@ -1 +1 @@ -Wire paskyra +${brand} Account \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/team-activation.html b/services/brig/deb/opt/brig/templates/lt/user/email/team-activation.html index b3d7a724ca4..9ae8f126881 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/team-activation.html +++ b/services/brig/deb/opt/brig/templates/lt/user/email/team-activation.html @@ -1 +1 @@ -Wire paskyra

wire.com

Jūsų nauja paskyra programoje Wire

Naudojant ${email}, buvo sukurta nauja Wire komanda. Patvirtinkite savo el. paštą.

 
Patvirtinti
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

Jeigu turite kokių nors klausimų, susisiekite su mumis.

                                                           
+${brand} Account

${brand_label_url}

Your new account on ${brand}

A new ${brand} team was created with ${email}. Patvirtinkite savo el. paštą.

 
Patvirtinti
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/team-activation.txt b/services/brig/deb/opt/brig/templates/lt/user/email/team-activation.txt index a41f36de916..30fa4059e6d 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/team-activation.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/team-activation.txt @@ -1,18 +1,19 @@ -JŪSŲ NAUJA PASKYRA PROGRAMOJE WIRE -Naudojant ${email}, buvo sukurta nauja Wire komanda. Patvirtinkite savo el. -paštą. +[${brand_logo}] + +${brand_label_url} [${brand_url}] + +YOUR NEW ACCOUNT ON ${brand} +A new ${brand} team was created with ${email}. Patvirtinkite savo el. paštą. Patvirtinti [${url}]Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę: ${url} -Jeigu turite kokių nors klausimų, susisiekite su mumis -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privatumas [https://wire.com/legal/] · Pranešti apie piktnaudžiavimą -[misuse@wire.com] -© WIRE SWISS GmbH. VISOS TEISĖS SAUGOMOS. +Privatumas [${legal}] · Pranešti apie piktnaudžiavimą [${misuse}] +${copyright}. VISOS TEISĖS SAUGOMOS. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/update-subject.txt b/services/brig/deb/opt/brig/templates/lt/user/email/update-subject.txt index 30eeb8fd4ad..62ff1daae5c 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/update-subject.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/update-subject.txt @@ -1 +1 @@ -Jūsų naujas el. pašto adresas programoje Wire +Your new email address on ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/update.html b/services/brig/deb/opt/brig/templates/lt/user/email/update.html index 74416e9bbe2..66766f08d87 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/update.html +++ b/services/brig/deb/opt/brig/templates/lt/user/email/update.html @@ -1 +1 @@ -Jūsų naujas el. pašto adresas programoje Wire

wire.com

Patvirtinkite savo el. paštą

${email} buvo užregistruotas kaip jūsų naujasis el. pašto adresas programoje Wire. Norėdami patvirtinti savo adresą, spustelėkite mygtuką žemiau.

 
Patvirtinti
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

Jeigu turite kokių nors klausimų, susisiekite su mumis.

                                                           
+Your new email address on ${brand}

${brand_label_url}

Patvirtinkite savo el. paštą

${email} was registered as your new email address on ${brand}. Norėdami patvirtinti savo adresą, spustelėkite mygtuką žemiau.

 
Patvirtinti
 

Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę:

${url}

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/update.txt b/services/brig/deb/opt/brig/templates/lt/user/email/update.txt index 9f39c797ce0..eacf651087d 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/update.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/update.txt @@ -1,18 +1,20 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + PATVIRTINKITE SAVO EL. PAŠTĄ -${email} buvo užregistruotas kaip jūsų naujasis el. pašto adresas programoje -Wire. Norėdami patvirtinti savo adresą, spustelėkite mygtuką žemiau. +${email} was registered as your new email address on ${brand}. Norėdami +patvirtinti savo adresą, spustelėkite mygtuką žemiau. Patvirtinti [${url}]Jeigu negalite spustelėti ant mygtuko, nukopijuokite ir įdėkite šią nuorodą į savo naršyklę: ${url} -Jeigu turite kokių nors klausimų, susisiekite su mumis -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privatumas [https://wire.com/legal/] · Pranešti apie piktnaudžiavimą -[misuse@wire.com] -© WIRE SWISS GmbH. VISOS TEISĖS SAUGOMOS. +Privatumas [${legal}] · Pranešti apie piktnaudžiavimą [${misuse}] +${copyright}. VISOS TEISĖS SAUGOMOS. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/verification-subject.txt b/services/brig/deb/opt/brig/templates/lt/user/email/verification-subject.txt index 13cd158c78d..64f64ad00fe 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/verification-subject.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/verification-subject.txt @@ -1 +1 @@ -Wire patvirtinimo kodas yra ${code} +${brand} verification code is ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/verification.html b/services/brig/deb/opt/brig/templates/lt/user/email/verification.html index 3571a1679f0..d4ca03e03ad 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/verification.html +++ b/services/brig/deb/opt/brig/templates/lt/user/email/verification.html @@ -1 +1 @@ -Wire patvirtinimo kodas yra ${code}

wire.com

Patvirtinkite savo el. paštą

Registruojantis Wire, buvo panaudotas ${email}. Norėdami patvirtinti savo el. paštą ir susikurti paskyrą, įveskite šį kodą.

 

${code}

 

Jeigu turite kokių nors klausimų, susisiekite su mumis.

                                                           
+${brand} verification code is ${code}

${brand_label_url}

Patvirtinkite savo el. paštą

${email} was used to register on ${brand}. Norėdami patvirtinti savo el. paštą ir susikurti paskyrą, įveskite šį kodą.

 

${code}

 

If you have any questions, please contact us.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/email/verification.txt b/services/brig/deb/opt/brig/templates/lt/user/email/verification.txt index 558f46bc1ac..09e727ec5d6 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/email/verification.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/email/verification.txt @@ -1,15 +1,17 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + PATVIRTINKITE SAVO EL. PAŠTĄ -Registruojantis Wire, buvo panaudotas ${email}. Norėdami patvirtinti savo el. -paštą ir susikurti paskyrą, įveskite šį kodą. +${email} was used to register on ${brand}. Norėdami patvirtinti savo el. paštą +ir susikurti paskyrą, įveskite šį kodą. ${code} -Jeigu turite kokių nors klausimų, susisiekite su mumis -[https://support.wire.com/hc/en-us/requests/new]. +If you have any questions, please contact us [${support}]. -------------------------------------------------------------------------------- -Privatumas [https://wire.com/legal/] · Pranešti apie piktnaudžiavimą -[misuse@wire.com] -© WIRE SWISS GmbH. VISOS TEISĖS SAUGOMOS. +Privatumas [${legal}] · Pranešti apie piktnaudžiavimą [${misuse}] +${copyright}. VISOS TEISĖS SAUGOMOS. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/lt/user/sms/activation.txt b/services/brig/deb/opt/brig/templates/lt/user/sms/activation.txt index 91409920717..68bfeccaac9 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/sms/activation.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/sms/activation.txt @@ -1,3 +1,3 @@ -Jūsų „Wire“ kodas yra ${code}. +Jūsų ${brand} kodas yra ${code}. -Atvėrę ${url} galėsite patvirtinti savo numerį. +Atverkite ${url} norėdami patvirtinti savo numerį. diff --git a/services/brig/deb/opt/brig/templates/lt/user/sms/deletion.txt b/services/brig/deb/opt/brig/templates/lt/user/sms/deletion.txt index e235575d97a..b918b6f022b 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/sms/deletion.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/sms/deletion.txt @@ -1,2 +1,2 @@ -Spustelėję ištrinsite „Wire“ paskyrą. -${url} +Bakstelėkite, norėdami ištrinti savo ${brand} paskyrą. +${url} diff --git a/services/brig/deb/opt/brig/templates/lt/user/sms/login.txt b/services/brig/deb/opt/brig/templates/lt/user/sms/login.txt index d2e5e3d0a11..36ad720403a 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/sms/login.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/sms/login.txt @@ -1,3 +1,3 @@ -„Wire“ prisijungimo kodas yra ${code}. +Jūsų ${brand} prisijungimo kodas yra ${code}. -Atvėrę ${url} galėsite prisijungti. +Atverkite ${url} norėdami prisijungti. diff --git a/services/brig/deb/opt/brig/templates/lt/user/sms/password-reset.txt b/services/brig/deb/opt/brig/templates/lt/user/sms/password-reset.txt index 884865136c9..5baca0ba65c 100644 --- a/services/brig/deb/opt/brig/templates/lt/user/sms/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/lt/user/sms/password-reset.txt @@ -1,3 +1,3 @@ -„Wire“ atkūrimo kodas yra ${code}. +Jūsų ${brand} atkūrimo kodas yra ${code}. -Naudokite šį kodą norėdami užbaigti slaptažodžio pakeitimą. +Naudokite šį kodą norėdami užbaigti slaptažodžio atstatymą. diff --git a/services/brig/deb/opt/brig/templates/ru/user/call/activation.txt b/services/brig/deb/opt/brig/templates/ru/user/call/activation.txt index fdf79023d69..abecab36f3f 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/call/activation.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/call/activation.txt @@ -1 +1 @@ -Здравствуйте, ваш код для подтверждения Wire: ${code}. Еще разок, ваш код подтверждения: ${code} +Здравствуйте, ваш код для подтверждения Wire: ${code}. Еще разок, ваш код подтверждения: ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/call/login.txt b/services/brig/deb/opt/brig/templates/ru/user/call/login.txt index 5571389ce1e..fb8b3ac2fff 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/call/login.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/call/login.txt @@ -1 +1 @@ -Здравствуйте, ваш код для входа в Wire: ${code}. Еще раз, ваш код подтверждения: ${code} +Здравствуйте, ваш код для входа в Wire: ${code}. Еще раз, ваш код подтверждения: ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/activation-subject.txt b/services/brig/deb/opt/brig/templates/ru/user/email/activation-subject.txt index b2326f4678b..72cbdea7c61 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/activation-subject.txt @@ -1 +1 @@ -Ваша учетная запись Wire +Ваша учетная запись ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/activation.html b/services/brig/deb/opt/brig/templates/ru/user/email/activation.html index 434d8899c9f..02a4e5bcc47 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/activation.html +++ b/services/brig/deb/opt/brig/templates/ru/user/email/activation.html @@ -1 +1 @@ -Ваша учетная запись Wire

wire.com

Подтвердите ваш email

Email адрес ${email} был использован для регистрации в Wire.
Нажмите на кнопку для подтверждения вашего email адреса.

 
Подтвердить
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если у вас есть вопросы, пожалуйста, свяжитесь с нами.

                                                           
+Ваша учетная запись ${brand}

${brand_label_url}

Подтвердите ваш email

${email} был использован для регистрации в ${brand}.
Нажмите на кнопку для подтверждения вашего email адреса.

 
Подтвердить
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/activation.txt b/services/brig/deb/opt/brig/templates/ru/user/email/activation.txt index 089dd2d9a7d..fd61f3899c8 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/activation.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/activation.txt @@ -1,5 +1,9 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + ПОДТВЕРДИТЕ ВАШ EMAIL -Email адрес ${email} был использован для регистрации в Wire. +${email} был использован для регистрации в ${brand}. Нажмите на кнопку для подтверждения вашего email адреса. Подтвердить [${url}]Если вы не можете нажать на кнопку, скопируйте и вставьте @@ -7,12 +11,11 @@ Email адрес ${email} был использован для регистра ${url} -Если у вас есть вопросы, пожалуйста, свяжитесь с нами -[https://support.wire.com/hc/en-us/requests/new]. +Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами +[${support}]. -------------------------------------------------------------------------------- -Конфиденциальность [https://wire.com/legal/] · Сообщить о злоупотреблении -[misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Конфиденциальность [${legal}] · Сообщить о злоупотреблении [${misuse}] +${copyright}. ВСЕ ПРАВА ЗАЩИЩЕНЫ. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/deletion-subject.txt b/services/brig/deb/opt/brig/templates/ru/user/email/deletion-subject.txt index b6eec5aafd5..96d6854f517 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/deletion-subject.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/deletion-subject.txt @@ -1 +1 @@ -Удалить учетную запись? +Удалить учетную запись? \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/deletion.html b/services/brig/deb/opt/brig/templates/ru/user/email/deletion.html index 9d5303530ca..7854d3305d8 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/deletion.html +++ b/services/brig/deb/opt/brig/templates/ru/user/email/deletion.html @@ -1 +1 @@ -Удалить учетную запись?

wire.com

Удалить учетную запись

Мы получили запрос на удаление вашей учетной записи в Wire. Нажмите на кнопку ниже в течение 10 минут для удаления всех ваших разговоров, контента и контактов.

 
Удалить учетную запись
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если вы не запрашивали удаления вашего аккаунта, то сбросьте ваш пароль.

Если у вас есть вопросы, пожалуйста, свяжитесь с нами.

                                                           
+Удалить учетную запись?

${brand_label_url}

Удалить учетную запись

Мы получили запрос на удаление вашего аккаунта ${brand}. Нажмите на кнопку ниже в течение 10 минут для удаления всех ваших разговоров, контента и контактов.

 
Удалить учетную запись
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если вы не запрашивали удаление вашего аккаунта, то сбросьте ваш пароль.

Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/deletion.txt b/services/brig/deb/opt/brig/templates/ru/user/email/deletion.txt index b4897fe75e4..727f8abf46e 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/deletion.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/deletion.txt @@ -1,22 +1,24 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + УДАЛИТЬ УЧЕТНУЮ ЗАПИСЬ -Мы получили запрос на удаление вашей учетной записи в Wire. Нажмите на кнопку -ниже в течение 10 минут для удаления всех ваших разговоров, контента и -контактов. +Мы получили запрос на удаление вашего аккаунта ${brand}. Нажмите на кнопку ниже +в течение 10 минут для удаления всех ваших разговоров, контента и контактов. Удалить учетную запись [${url}]Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер: ${url} -Если вы не запрашивали удаления вашего аккаунта, то сбросьте ваш пароль -[https://account.wire.com/forgot/]. +Если вы не запрашивали удаление вашего аккаунта, то сбросьте ваш пароль +[${forgot}]. -Если у вас есть вопросы, пожалуйста, свяжитесь с нами -[https://support.wire.com/hc/en-us/requests/new]. +Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами +[${support}]. -------------------------------------------------------------------------------- -Конфиденциальность [https://wire.com/legal/] · Сообщить о злоупотреблении -[misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Конфиденциальность [${legal}] · Сообщить о злоупотреблении [${misuse}] +${copyright}. ВСЕ ПРАВА ЗАЩИЩЕНЫ. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/new-client.html b/services/brig/deb/opt/brig/templates/ru/user/email/new-client.html index d5ad6f2c8eb..6e80b6b5049 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/new-client.html +++ b/services/brig/deb/opt/brig/templates/ru/user/email/new-client.html @@ -1 +1 @@ -Новое устройство

wire.com

Новое устройство

Ваша учетная запись Wire использовалась на:

${date}

${model}

Возможно, вы установили Wire на новом устройстве или переустановили его на одном из уже используемых ранее. Если это не так, перейдите в настройки Wire, удалите это устройство из списка и сбросьте ваш пароль.

Если у вас есть вопросы, пожалуйста, свяжитесь с нами.

                                                           
+Новое устройство

${brand_label_url}

Новое устройство

Ваша учетная запись ${brand} использовалась на:

${date}

${model}

Возможно, вы установили ${brand} на новом устройстве или переустановили его на одном из уже используемых ранее. Если это не так, перейдите в настройки ${brand}, удалите это устройство из списка и сбросьте ваш пароль.

Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/new-client.txt b/services/brig/deb/opt/brig/templates/ru/user/email/new-client.txt index 41db71257c5..c6850a1857e 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/new-client.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/new-client.txt @@ -1,21 +1,23 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + НОВОЕ УСТРОЙСТВО -Ваша учетная запись Wire использовалась на: +Ваша учетная запись ${brand} использовалась на: ${date} ${model} -Возможно, вы установили Wire на новом устройстве или переустановили его на одном -из уже используемых ранее. Если это не так, перейдите в настройки Wire, удалите -это устройство из списка и сбросьте ваш пароль -[https://account.wire.com/forgot/]. +Возможно, вы установили ${brand} на новом устройстве или переустановили его на +одном из уже используемых ранее. Если это не так, перейдите в настройки +${brand}, удалите это устройство из списка и сбросьте ваш пароль [${forgot}]. -Если у вас есть вопросы, пожалуйста, свяжитесь с нами -[https://support.wire.com/hc/en-us/requests/new]. +Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами +[${support}]. -------------------------------------------------------------------------------- -Конфиденциальность [https://wire.com/legal/] · Сообщить о злоупотреблении -[misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Конфиденциальность [${legal}] · Сообщить о злоупотреблении [${misuse}] +${copyright}. ВСЕ ПРАВА ЗАЩИЩЕНЫ. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/password-reset-subject.txt b/services/brig/deb/opt/brig/templates/ru/user/email/password-reset-subject.txt index c99dfad6624..28db82c9e95 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/password-reset-subject.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/password-reset-subject.txt @@ -1 +1 @@ -Смена пароля в Wire +Смена пароля в ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/password-reset.html b/services/brig/deb/opt/brig/templates/ru/user/email/password-reset.html index 89a98c882ed..cc5a85963de 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/password-reset.html +++ b/services/brig/deb/opt/brig/templates/ru/user/email/password-reset.html @@ -1 +1 @@ -Смена пароля в Wire

wire.com

Сбросить пароль

Мы получили запрос на сброс пароля для вашей учетной записи Wire. Чтобы создать новый пароль нажмите на кнопку ниже.

 
Сбросить пароль
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если у вас есть вопросы, пожалуйста, свяжитесь с нами.

                                                           
+Смена пароля в ${brand}

${brand_label_url}

Сбросить пароль

Мы получили запрос на сброс пароля для вашей учетной записи ${brand}. Чтобы создать новый пароль нажмите на кнопку ниже.

 
Сбросить пароль
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/password-reset.txt b/services/brig/deb/opt/brig/templates/ru/user/email/password-reset.txt index 950198e0295..f69ff61fd2d 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/password-reset.txt @@ -1,18 +1,21 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + СБРОСИТЬ ПАРОЛЬ -Мы получили запрос на сброс пароля для вашей учетной записи Wire. Чтобы создать -новый пароль нажмите на кнопку ниже. +Мы получили запрос на сброс пароля для вашей учетной записи ${brand}. Чтобы +создать новый пароль нажмите на кнопку ниже. Сбросить пароль [${url}]Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер: ${url} -Если у вас есть вопросы, пожалуйста, свяжитесь с нами -[https://support.wire.com/hc/en-us/requests/new]. +Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами +[${support}]. -------------------------------------------------------------------------------- -Конфиденциальность [https://wire.com/legal/] · Сообщить о злоупотреблении -[misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Конфиденциальность [${legal}] · Сообщить о злоупотреблении [${misuse}] +${copyright}. ВСЕ ПРАВА ЗАЩИЩЕНЫ. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/team-activation-subject.txt b/services/brig/deb/opt/brig/templates/ru/user/email/team-activation-subject.txt index 76d93122000..72cbdea7c61 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/team-activation-subject.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/team-activation-subject.txt @@ -1 +1 @@ -Учетная запись Wire +Ваша учетная запись ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/team-activation.html b/services/brig/deb/opt/brig/templates/ru/user/email/team-activation.html index a9b6d4ecdf0..ad2d97988ed 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/team-activation.html +++ b/services/brig/deb/opt/brig/templates/ru/user/email/team-activation.html @@ -1 +1 @@ -Учетная запись Wire

wire.com

Ваша новая учетная запись Wire

В Wire была создана новая команда с использованием email адреса ${email}. Подтвердите ваш email адрес.

 
Подтвердить
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если у вас есть вопросы, пожалуйста, свяжитесь с нами.

                                                           
+Ваша учетная запись ${brand}

${brand_label_url}

Ваша новая учетная запись ${brand}

В ${brand} была создана новая команда с использованием email адреса ${email}. Подтвердите ваш email адрес.

 
Подтвердить
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/team-activation.txt b/services/brig/deb/opt/brig/templates/ru/user/email/team-activation.txt index 4a4025964cd..f79d7472f58 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/team-activation.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/team-activation.txt @@ -1,5 +1,9 @@ -ВАША НОВАЯ УЧЕТНАЯ ЗАПИСЬ WIRE -В Wire была создана новая команда с использованием email адреса ${email}. +[${brand_logo}] + +${brand_label_url} [${brand_url}] + +ВАША НОВАЯ УЧЕТНАЯ ЗАПИСЬ ${brand} +В ${brand} была создана новая команда с использованием email адреса ${email}. Подтвердите ваш email адрес. Подтвердить [${url}]Если вы не можете нажать на кнопку, скопируйте и вставьте @@ -7,12 +11,11 @@ ${url} -Если у вас есть вопросы, пожалуйста, свяжитесь с нами -[https://support.wire.com/hc/en-us/requests/new]. +Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами +[${support}]. -------------------------------------------------------------------------------- -Конфиденциальность [https://wire.com/legal/] · Сообщить о злоупотреблении -[misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Конфиденциальность [${legal}] · Сообщить о злоупотреблении [${misuse}] +${copyright}. ВСЕ ПРАВА ЗАЩИЩЕНЫ. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/update-subject.txt b/services/brig/deb/opt/brig/templates/ru/user/email/update-subject.txt index 829a4ca2d5b..045a3a476f6 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/update-subject.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/update-subject.txt @@ -1 +1 @@ -Ваш новый email адрес в Wire +Ваш новый email адрес в ${brand} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/update.html b/services/brig/deb/opt/brig/templates/ru/user/email/update.html index 6dac138693b..db75c172106 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/update.html +++ b/services/brig/deb/opt/brig/templates/ru/user/email/update.html @@ -1 +1 @@ -Ваш новый email адрес в Wire

wire.com

Подтвердите ваш email адрес

${email} был указан как ваш новый email адрес в Wire. Нажмите на кнопку ниже для подтверждения своего адреса.

 
Подтвердить
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если у вас есть вопросы, пожалуйста, свяжитесь с нами.

                                                           
+Ваш новый email адрес в ${brand}

${brand_label_url}

Подтвердите ваш email адрес

${email} был указан как ваш новый email адрес в ${brand}. Нажмите на кнопку ниже для подтверждения своего адреса.

 
Подтвердить
 

Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер:

${url}

Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/update.txt b/services/brig/deb/opt/brig/templates/ru/user/email/update.txt index a1d9ec80a6d..7f5806237de 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/update.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/update.txt @@ -1,18 +1,21 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + ПОДТВЕРДИТЕ ВАШ EMAIL АДРЕС -${email} был указан как ваш новый email адрес в Wire. Нажмите на кнопку ниже для -подтверждения своего адреса. +${email} был указан как ваш новый email адрес в ${brand}. Нажмите на кнопку ниже +для подтверждения своего адреса. Подтвердить [${url}]Если вы не можете нажать на кнопку, скопируйте и вставьте эту ссылку в свой браузер: ${url} -Если у вас есть вопросы, пожалуйста, свяжитесь с нами -[https://support.wire.com/hc/en-us/requests/new]. +Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами +[${support}]. -------------------------------------------------------------------------------- -Конфиденциальность [https://wire.com/legal/] · Сообщить о злоупотреблении -[misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Конфиденциальность [${legal}] · Сообщить о злоупотреблении [${misuse}] +${copyright}. ВСЕ ПРАВА ЗАЩИЩЕНЫ. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/verification-subject.txt b/services/brig/deb/opt/brig/templates/ru/user/email/verification-subject.txt index 3115aa5f152..5359291e0d0 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/verification-subject.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/verification-subject.txt @@ -1 +1 @@ -Код подтверждения в Wire: ${code} +Код подтверждения ${brand} - ${code} \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/verification.html b/services/brig/deb/opt/brig/templates/ru/user/email/verification.html index fbedec6d00f..724704c0d68 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/verification.html +++ b/services/brig/deb/opt/brig/templates/ru/user/email/verification.html @@ -1 +1 @@ -Код подтверждения в Wire: ${code}

wire.com

Подтвердите ваш email

${email} был использован для регистрации в Wire. Введите этот код для подтверждения email и создания учетной записи.

 

${code}

 

Если у вас есть вопросы, пожалуйста, свяжитесь с нами.

                                                           
+Код подтверждения ${brand} - ${code}

${brand_label_url}

Подтвердите ваш email

${email} был использован для регистрации в ${brand}. Введите этот код для подтверждения email и создания учетной записи.

 

${code}

 

Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами.

                                                           
\ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/email/verification.txt b/services/brig/deb/opt/brig/templates/ru/user/email/verification.txt index 72f6b6766ce..009969585be 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/email/verification.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/email/verification.txt @@ -1,15 +1,18 @@ +[${brand_logo}] + +${brand_label_url} [${brand_url}] + ПОДТВЕРДИТЕ ВАШ EMAIL -${email} был использован для регистрации в Wire. Введите этот код для +${email} был использован для регистрации в ${brand}. Введите этот код для подтверждения email и создания учетной записи. ${code} -Если у вас есть вопросы, пожалуйста, свяжитесь с нами -[https://support.wire.com/hc/en-us/requests/new]. +Если у вас возникли вопросы или нужна помощь, пожалуйста свяжитесь с нами +[${support}]. -------------------------------------------------------------------------------- -Конфиденциальность [https://wire.com/legal/] · Сообщить о злоупотреблении -[misuse@wire.com] -© WIRE SWISS GmbH. ALL RIGHTS RESERVED. +Конфиденциальность [${legal}] · Сообщить о злоупотреблении [${misuse}] +${copyright}. ВСЕ ПРАВА ЗАЩИЩЕНЫ. \ No newline at end of file diff --git a/services/brig/deb/opt/brig/templates/ru/user/sms/activation.txt b/services/brig/deb/opt/brig/templates/ru/user/sms/activation.txt index d9b0f67b10d..414a58f3381 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/sms/activation.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/sms/activation.txt @@ -1,3 +1,3 @@ -Ваш Wire код: ${code}. +Ваш код ${brand}: ${code}. Откройте ${url}, чтобы подтвердить ваш номер. diff --git a/services/brig/deb/opt/brig/templates/ru/user/sms/deletion.txt b/services/brig/deb/opt/brig/templates/ru/user/sms/deletion.txt index bfddc50cb34..194f5ceb1fc 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/sms/deletion.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/sms/deletion.txt @@ -1,2 +1,2 @@ -Коснитесь для удаления вашего Wire-аккаунта. -${url} +Нажмите для удаления вашего аккаунта ${brand}. +${url} diff --git a/services/brig/deb/opt/brig/templates/ru/user/sms/login.txt b/services/brig/deb/opt/brig/templates/ru/user/sms/login.txt index ae03700801c..5cf0687df4d 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/sms/login.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/sms/login.txt @@ -1,3 +1,3 @@ -Ваш код входа Wire: ${code}. +Ваш код входа ${brand}: ${code}. Откройте ${url}, чтобы войти. diff --git a/services/brig/deb/opt/brig/templates/ru/user/sms/password-reset.txt b/services/brig/deb/opt/brig/templates/ru/user/sms/password-reset.txt index 073c2d7db06..e19f76b4f92 100644 --- a/services/brig/deb/opt/brig/templates/ru/user/sms/password-reset.txt +++ b/services/brig/deb/opt/brig/templates/ru/user/sms/password-reset.txt @@ -1,3 +1,3 @@ -Ваш код восстановления Wire: ${code}. +Ваш код восстановления ${brand}: ${code}. Используйте этот код, чтобы завершить сброс пароля. diff --git a/services/brig/deb/opt/brig/templates/version b/services/brig/deb/opt/brig/templates/version index 84b50637e06..e6d41e92977 100644 --- a/services/brig/deb/opt/brig/templates/version +++ b/services/brig/deb/opt/brig/templates/version @@ -1 +1 @@ -v1.0.42 +v1.0.55 diff --git a/services/brig/schema/src/Main.hs b/services/brig/schema/src/Main.hs index c13885e5df0..a0ecff49a9f 100644 --- a/services/brig/schema/src/Main.hs +++ b/services/brig/schema/src/Main.hs @@ -52,6 +52,7 @@ import qualified V54 import qualified V55 import qualified V56 import qualified V57 +import qualified V58 main :: IO () main = do @@ -106,4 +107,5 @@ main = do , V55.migration , V56.migration , V57.migration + , V58.migration ] `finally` close l diff --git a/services/brig/schema/src/V58.hs b/services/brig/schema/src/V58.hs new file mode 100644 index 00000000000..7bd8c0b9415 --- /dev/null +++ b/services/brig/schema/src/V58.hs @@ -0,0 +1,18 @@ +{-# LANGUAGE OverloadedStrings #-} +{-# LANGUAGE QuasiQuotes #-} + +module V58 (migration) where + +import Imports +import Cassandra.Schema +import Text.RawString.QQ + +migration :: Migration +migration = Migration 58 "Add table for storing rich info" $ do + void $ schema' [r| + create table if not exists rich_info + ( user uuid + , json blob + , primary key (user) + ) + |] diff --git a/services/brig/src/Brig/API.hs b/services/brig/src/Brig/API.hs index 0f10155cb02..4bbd0385ddd 100644 --- a/services/brig/src/Brig/API.hs +++ b/services/brig/src/Brig/API.hs @@ -218,6 +218,12 @@ sitemap o = do .&. contentType "application" "json" .&. request + put "/i/users/:uid/rich-info" (continue updateRichInfo) $ + capture "uid" + .&. accept "application" "json" + .&. contentType "application" "json" + .&. request + post "/i/clients" (continue internalListClients) $ accept "application" "json" .&. contentType "application" "json" @@ -395,6 +401,21 @@ sitemap o = do Doc.returns (Doc.ref Doc.pubClient) Doc.response 200 "Client" Doc.end + -- + + get "/users/:user/rich-info" (continue getRichInfo) $ + header "Z-User" + .&. capture "user" + .&. accept "application" "json" + + document "GET" "getRichInfo" $ do + Doc.summary "Get user's rich info" + Doc.parameter Doc.Path "user" Doc.bytes' $ + Doc.description "User ID" + Doc.returns (Doc.ref Doc.richInfo) + Doc.response 200 "RichInfo" Doc.end + Doc.errorResponse insufficientTeamPermissions + -- /self ------------------------------------------------------------------ -- Profile @@ -1081,11 +1102,23 @@ getUserClient (user ::: cid ::: _) = lift $ do Just c -> json c Nothing -> setStatus status404 empty +getRichInfo :: UserId ::: UserId ::: JSON -> Handler Response +getRichInfo (self ::: user ::: _) = do + -- Check that both users exist and the requesting user is allowed to see rich info of the + -- other user + selfUser <- ifNothing userNotFound =<< lift (Data.lookupUser self) + otherUser <- ifNothing userNotFound =<< lift (Data.lookupUser user) + case (userTeam selfUser, userTeam otherUser) of + (Just t1, Just t2) | t1 == t2 -> pure () + _ -> throwStd insufficientTeamPermissions + -- Query rich info + json . fromMaybe emptyRichInfo <$> lift (API.lookupRichInfo user) + listPrekeyIds :: UserId ::: ClientId ::: JSON -> Handler Response listPrekeyIds (usr ::: clt ::: _) = json <$> lift (API.lookupPrekeyIds usr clt) autoConnect :: JSON ::: JSON ::: UserId ::: Maybe ConnId ::: Request -> Handler Response -autoConnect(_ ::: _ ::: uid ::: conn ::: req) = do +autoConnect (_ ::: _ ::: uid ::: conn ::: req) = do UserSet to <- parseJsonBody req let num = Set.size to when (num < 1) $ @@ -1469,6 +1502,16 @@ updateManagedBy (uid ::: _ ::: _ ::: req) = do lift $ Data.updateManagedBy uid managedBy return empty +updateRichInfo :: UserId ::: JSON ::: JSON ::: Request -> Handler Response +updateRichInfo (uid ::: _ ::: _ ::: req) = do + richInfo <- normalizeRichInfo . riuRichInfo <$> parseJsonBody req + maxSize <- setRichInfoLimit <$> view settings + when (richInfoSize richInfo > maxSize) $ throwStd tooLargeRichInfo + lift $ Data.updateRichInfo uid richInfo + -- FUTUREWORK: send an event + -- Intra.onUserEvent uid (Just conn) (richInfoUpdate uid ri) + return empty + deleteUser :: UserId ::: Request ::: JSON ::: JSON -> Handler Response deleteUser (u ::: r ::: _ ::: _) = do body <- parseJsonBody r diff --git a/services/brig/src/Brig/API/Error.hs b/services/brig/src/Brig/API/Error.hs index aab60bbee1b..665b2f5f085 100644 --- a/services/brig/src/Brig/API/Error.hs +++ b/services/brig/src/Brig/API/Error.hs @@ -337,6 +337,14 @@ authTokenInvalid = Wai.Error status403 "invalid-credentials" "Invalid token" incorrectPermissions :: Wai.Error incorrectPermissions = Wai.Error status403 "invalid-permissions" "Copy permissions must be a subset of self permissions" +-- | User's relation to the team is not what we expect it to be. Examples: +-- +-- * Requested action requires the user to be a team member, but the user doesn't belong to +-- the team. +-- +-- * Requested action requires the user to be a team owner. +-- +-- * Requested action can't be performed if the user is the only team owner left in the team. insufficientTeamPermissions :: Wai.Error insufficientTeamPermissions = Wai.Error status403 "insufficient-permissions" "Insufficient team permissions" @@ -359,6 +367,9 @@ tooManyTeamMembers = Wai.Error status403 "too-many-team-members" "Too many membe loginsTooFrequent :: Wai.Error loginsTooFrequent = Wai.Error status429 "client-error" "Logins too frequent" +tooLargeRichInfo :: Wai.Error +tooLargeRichInfo = Wai.Error status413 "too-large-rich-info" "Rich info has exceeded the limit" + internalServerError :: Wai.Error internalServerError = Wai.Error status500 "internal-server-error" "Internal Server Error" diff --git a/services/brig/src/Brig/API/User.hs b/services/brig/src/Brig/API/User.hs index 0e947cdb3e4..70cbf30747b 100644 --- a/services/brig/src/Brig/API/User.hs +++ b/services/brig/src/Brig/API/User.hs @@ -22,6 +22,7 @@ module Brig.API.User , Data.lookupName , Data.lookupLocale , Data.lookupUser + , Data.lookupRichInfo , removeEmail , removePhone , revokeIdentity diff --git a/services/brig/src/Brig/App.hs b/services/brig/src/Brig/App.hs index df27aea8072..a08e9d3a959 100644 --- a/services/brig/src/Brig/App.hs +++ b/services/brig/src/Brig/App.hs @@ -17,6 +17,7 @@ module Brig.App , userTemplates , providerTemplates , teamTemplates + , templateBranding , requestId , httpManager , extGetManager @@ -49,7 +50,7 @@ import Bilge (MonadHttp, Manager, newManager, RequestId (..)) import Bilge.RPC (HasRequestId (..)) import Brig.Options (Opts, Settings) import Brig.Queue.Types (Queue (..)) -import Brig.Template (Localised, forLocale) +import Brig.Template (Localised, forLocale, genTemplateBranding, TemplateBranding) import Brig.Provider.Template import Brig.Team.Template import Brig.User.Search.Index (runIndexIO, IndexEnv (..), MonadIndexIO (..)) @@ -109,7 +110,7 @@ import qualified System.Logger as Log import qualified System.Logger.Class as LC schemaVersion :: Int32 -schemaVersion = 57 +schemaVersion = 58 ------------------------------------------------------------------------------- -- Environment @@ -129,6 +130,7 @@ data Env = Env , _usrTemplates :: Localised UserTemplates , _provTemplates :: Localised ProviderTemplates , _tmTemplates :: Localised TeamTemplates + , _templateBranding :: TemplateBranding , _httpManager :: Manager , _extGetManager :: (Manager, [Fingerprint Rsa] -> SSL.SSL -> IO ()) , _settings :: Settings @@ -167,6 +169,7 @@ newEnv o = do utp <- loadUserTemplates o ptp <- loadProviderTemplates o ttp <- loadTeamTemplates o + let branding = genTemplateBranding . Opt.templateBranding . Opt.general . Opt.emailSMS $ o (emailAWSOpts, emailSMTP) <- emailConn lgr $ Opt.email (Opt.emailSMS o) aws <- AWS.mkEnv lgr (Opt.aws o) emailAWSOpts mgr zau <- initZAuth o @@ -203,6 +206,7 @@ newEnv o = do , _usrTemplates = utp , _provTemplates = ptp , _tmTemplates = ttp + , _templateBranding = branding , _httpManager = mgr , _extGetManager = ext , _settings = sett diff --git a/services/brig/src/Brig/Data/Instances.hs b/services/brig/src/Brig/Data/Instances.hs index 9ef26f375a2..b09da183099 100644 --- a/services/brig/src/Brig/Data/Instances.hs +++ b/services/brig/src/Brig/Data/Instances.hs @@ -17,8 +17,6 @@ import Data.String.Conversions (cs, LBS, ST) import Data.Text.Ascii() import qualified Data.Aeson as JSON -import qualified Data.Aeson.Parser as JSON -import qualified Data.Attoparsec.ByteString.Lazy as P deriving instance Cql Name deriving instance Cql Handle @@ -175,7 +173,9 @@ instance Cql PrekeyId where instance Cql PropertyValue where ctype = Tagged BlobColumn toCql = toCql . Blob . JSON.encode . propertyValueJson - fromCql (CqlBlob v) = note "Failed to read property value" $ fmap PropertyValue (P.maybeResult (P.parse JSON.value v)) + fromCql (CqlBlob v) = case JSON.eitherDecode v of + Left e -> fail ("Failed to read property value: " <> e) + Right x -> pure (PropertyValue x) fromCql _ = fail "PropertyValue: Blob expected" instance Cql Country where @@ -205,3 +205,9 @@ instance Cql ManagedBy where toCql ManagedByWire = CqlInt 0 toCql ManagedByScim = CqlInt 1 + +instance Cql RichInfo where + ctype = Tagged BlobColumn + toCql = toCql . Blob . JSON.encode + fromCql (CqlBlob v) = JSON.eitherDecode v + fromCql _ = fail "RichInfo: Blob expected" diff --git a/services/brig/src/Brig/Data/User.hs b/services/brig/src/Brig/Data/User.hs index 9d7effa8c54..8634a06a039 100644 --- a/services/brig/src/Brig/Data/User.hs +++ b/services/brig/src/Brig/Data/User.hs @@ -7,10 +7,13 @@ module Brig.Data.User ( AuthError (..) , ReAuthError (..) , newAccount + , insertAccount , authenticate , reauthenticate , filterActive , isActivated + + -- * Lookups , lookupAccount , lookupAccounts , lookupUser @@ -19,8 +22,12 @@ module Brig.Data.User , lookupLocale , lookupPassword , lookupStatus + , lookupRichInfo , lookupUserTeam - , insertAccount + , lookupServiceUsers + , lookupServiceUsersForTeam + + -- * Updates , updateUser , updateEmail , updatePhone @@ -32,12 +39,13 @@ module Brig.Data.User , updatePassword , updateStatus , updateSearchableStatus + , updateHandle + , updateRichInfo + + -- * Deletions , deleteEmail , deletePhone , deleteServiceUser - , lookupServiceUsers - , lookupServiceUsersForTeam - , updateHandle ) where import Imports @@ -214,6 +222,9 @@ updatePassword u t = do p <- liftIO $ mkSafePassword t retry x5 $ write userPasswordUpdate (params Quorum (p, u)) +updateRichInfo :: UserId -> RichInfo -> AppIO () +updateRichInfo u ri = retry x5 $ write userRichInfoUpdate (params Quorum (ri, u)) + deleteEmail :: UserId -> AppIO () deleteEmail u = retry x5 $ write userEmailDelete (params Quorum (Identity u)) @@ -289,6 +300,10 @@ lookupStatus :: UserId -> AppIO (Maybe AccountStatus) lookupStatus u = join . fmap runIdentity <$> retry x1 (query1 statusSelect (params Quorum (Identity u))) +lookupRichInfo :: UserId -> AppIO (Maybe RichInfo) +lookupRichInfo u = fmap runIdentity <$> + retry x1 (query1 richInfoSelect (params Quorum (Identity u))) + lookupUserTeam :: UserId -> AppIO (Maybe TeamId) lookupUserTeam u = join . fmap runIdentity <$> retry x1 (query1 teamSelect (params Quorum (Identity u))) @@ -298,6 +313,9 @@ lookupAuth u = fmap f <$> retry x1 (query1 authSelect (params Quorum (Identity u where f (pw, st) = (pw, fromMaybe Active st) +-- | Return users with given IDs. +-- +-- Skips nonexistent users. /Does not/ skip users who have been deleted. lookupUsers :: [UserId] -> AppIO [User] lookupUsers usrs = do loc <- setDefaultLocale <$> view settings @@ -392,6 +410,9 @@ accountStateSelectAll = "SELECT id, activated, status FROM user WHERE id IN ?" statusSelect :: PrepQuery R (Identity UserId) (Identity (Maybe AccountStatus)) statusSelect = "SELECT status FROM user WHERE id = ?" +richInfoSelect :: PrepQuery R (Identity UserId) (Identity RichInfo) +richInfoSelect = "SELECT json FROM rich_info WHERE user = ?" + teamSelect :: PrepQuery R (Identity UserId) (Identity (Maybe TeamId)) teamSelect = "SELECT team FROM user WHERE id = ?" @@ -458,6 +479,9 @@ userEmailDelete = "UPDATE user SET email = null WHERE id = ?" userPhoneDelete :: PrepQuery W (Identity UserId) () userPhoneDelete = "UPDATE user SET phone = null WHERE id = ?" +userRichInfoUpdate :: PrepQuery W (RichInfo, UserId) () +userRichInfoUpdate = "UPDATE rich_info SET json = ? WHERE user = ?" + ------------------------------------------------------------------------------- -- Conversions diff --git a/services/brig/src/Brig/Options.hs b/services/brig/src/Brig/Options.hs index 60bae02b83b..f7b3c7a4ebb 100644 --- a/services/brig/src/Brig/Options.hs +++ b/services/brig/src/Brig/Options.hs @@ -89,14 +89,31 @@ instance FromJSON InternalEventsOpts where InternalEventsOpts <$> parseJSON (Y.Object o) data EmailSMSGeneralOpts = EmailSMSGeneralOpts - { templateDir :: !FilePath -- ^ Email, SMS, ... template directory - , emailSender :: !Email -- ^ Email sender address - , smsSender :: !Text -- ^ Twilio sender identifier (number or - -- messaging service ID) + { templateDir :: !FilePath -- ^ Email, SMS, ... template directory + , emailSender :: !Email -- ^ Email sender address + , smsSender :: !Text -- ^ Twilio sender identifier (number or + -- messaging service ID) + , templateBranding :: !BrandingOpts -- ^ Customizable branding text for + -- emails/sms/calls } deriving (Show, Generic) instance FromJSON EmailSMSGeneralOpts +data BrandingOpts = BrandingOpts + { brand :: !Text + , brandUrl :: !Text + , brandLabelUrl :: !Text + , brandLogoUrl :: !Text + , brandService :: !Text + , copyright :: !Text + , misuse :: !Text + , legal :: !Text + , forgot :: !Text + , support :: !Text + } deriving (Show, Generic) + +instance FromJSON BrandingOpts + data EmailUserOpts = EmailUserOpts { activationUrl :: !Text -- ^ Activation URL template , smsActivationUrl :: !Text -- ^ SMS activation URL template @@ -225,6 +242,9 @@ data Settings = Settings -- it is renewed during token refresh , setUserCookieLimit :: !Int -- ^ Max. # of cookies per user and cookie type , setUserCookieThrottle :: !CookieThrottle -- ^ Throttling settings + , setRichInfoLimit :: !Int -- ^ Max size of rich info (number of chars in + -- field names and values), should be in sync + -- with Spar , setDefaultLocale :: !Locale -- ^ Default locale to use -- (e.g. when selecting templates) , setMaxTeamSize :: !Word16 -- ^ Max. # of members in a team. diff --git a/services/brig/src/Brig/Provider/Email.hs b/services/brig/src/Brig/Provider/Email.hs index 8d733cd9d6f..76f75771e1d 100644 --- a/services/brig/src/Brig/Provider/Email.hs +++ b/services/brig/src/Brig/Provider/Email.hs @@ -11,8 +11,10 @@ import Imports import Brig.App import Brig.Email import Brig.Provider.Template +import Brig.Template import Brig.Types.Common import Brig.Types.Provider +import Control.Lens (view) import Data.ByteString.Conversion import Data.Range import Data.Text (pack) @@ -28,8 +30,9 @@ import qualified Data.Text.Lazy as LT sendActivationMail :: Name -> Email -> Code.Key -> Code.Value -> Bool -> AppIO () sendActivationMail name email key code update = do tpl <- selectTemplate update . snd <$> providerTemplates Nothing + branding <- view templateBranding let mail = ActivationEmail email name key code - sendMail $ renderActivationMail mail tpl + sendMail $ renderActivationMail mail tpl branding where selectTemplate True = activationEmailUpdate selectTemplate False = activationEmail @@ -41,8 +44,8 @@ data ActivationEmail = ActivationEmail , acmCode :: !Code.Value } -renderActivationMail :: ActivationEmail -> ActivationEmailTemplate -> Mail -renderActivationMail ActivationEmail{..} ActivationEmailTemplate{..} = +renderActivationMail :: ActivationEmail -> ActivationEmailTemplate -> TemplateBranding -> Mail +renderActivationMail ActivationEmail{..} ActivationEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", LT.toStrict subj) @@ -55,20 +58,20 @@ renderActivationMail ActivationEmail{..} ActivationEmailTemplate{..} = where (Code.Key key, Code.Value code) = (acmKey, acmCode) - from = Address (Just "Wire") (fromEmail activationEmailSender) + from = Address (Just activationEmailSenderName) (fromEmail activationEmailSender) to = mkMimeAddress acmName acmTo - txt = renderText activationEmailBodyText replace - html = renderHtml activationEmailBodyHtml replace - subj = renderText activationEmailSubject replace + txt = renderTextWithBranding activationEmailBodyText replace branding + html = renderHtmlWithBranding activationEmailBodyHtml replace branding + subj = renderTextWithBranding activationEmailSubject replace branding - replace "url" = renderActivationUrl activationEmailUrl acmKey acmCode + replace "url" = renderActivationUrl activationEmailUrl acmKey acmCode branding replace "email" = fromEmail acmTo replace "name" = fromName acmName replace x = x -renderActivationUrl :: Template -> Code.Key -> Code.Value -> Text -renderActivationUrl t (Code.Key k) (Code.Value v) = - LT.toStrict $ renderText t replace +renderActivationUrl :: Template -> Code.Key -> Code.Value -> TemplateBranding -> Text +renderActivationUrl t (Code.Key k) (Code.Value v) branding = + LT.toStrict $ renderTextWithBranding t replace branding where replace "key" = Ascii.toText (fromRange k) replace "code" = Ascii.toText (fromRange v) @@ -80,8 +83,9 @@ renderActivationUrl t (Code.Key k) (Code.Value v) = sendApprovalRequestMail :: Name -> Email -> HttpsUrl -> Text -> Code.Key -> Code.Value -> AppIO () sendApprovalRequestMail name email url descr key val = do tpl <- approvalRequestEmail . snd <$> providerTemplates Nothing + branding <- view templateBranding let mail = ApprovalRequestEmail email name url descr key val - sendMail $ renderApprovalRequestMail mail tpl + sendMail $ renderApprovalRequestMail mail tpl branding data ApprovalRequestEmail = ApprovalRequestEmail { aprTo :: !Email @@ -92,8 +96,8 @@ data ApprovalRequestEmail = ApprovalRequestEmail , aprCode :: !Code.Value } -renderApprovalRequestMail :: ApprovalRequestEmail -> ApprovalRequestEmailTemplate -> Mail -renderApprovalRequestMail ApprovalRequestEmail{..} ApprovalRequestEmailTemplate{..} = +renderApprovalRequestMail :: ApprovalRequestEmail -> ApprovalRequestEmailTemplate -> TemplateBranding -> Mail +renderApprovalRequestMail ApprovalRequestEmail{..} ApprovalRequestEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", LT.toStrict subj) @@ -102,23 +106,23 @@ renderApprovalRequestMail ApprovalRequestEmail{..} ApprovalRequestEmailTemplate{ , mailParts = [ [ plainPart txt, htmlPart html ] ] } where - from = Address (Just "Wire") (fromEmail approvalRequestEmailSender) - to = Address (Just "Wire Staff") (fromEmail approvalRequestEmailTo) - txt = renderText approvalRequestEmailBodyText replace - html = renderHtml approvalRequestEmailBodyHtml replace - subj = renderText approvalRequestEmailSubject replace + from = Address (Just approvalRequestEmailSenderName) (fromEmail approvalRequestEmailSender) + to = Address (Just "Provider Approval Staff") (fromEmail approvalRequestEmailTo) + txt = renderTextWithBranding approvalRequestEmailBodyText replace branding + html = renderHtmlWithBranding approvalRequestEmailBodyHtml replace branding + subj = renderTextWithBranding approvalRequestEmailSubject replace branding replace "email" = fromEmail aprTo replace "name" = fromName aprName replace "url" = Text.decodeUtf8 (toByteString' aprUrl) replace "description" = aprDescr - replace "approvalUrl" = renderApprovalUrl approvalRequestEmailUrl aprKey aprCode + replace "approvalUrl" = renderApprovalUrl approvalRequestEmailUrl aprKey aprCode branding replace x = x -- TODO: Unify with renderActivationUrl -renderApprovalUrl :: Template -> Code.Key -> Code.Value -> Text -renderApprovalUrl t (Code.Key k) (Code.Value v) = - LT.toStrict $ renderText t replace +renderApprovalUrl :: Template -> Code.Key -> Code.Value -> TemplateBranding -> Text +renderApprovalUrl t (Code.Key k) (Code.Value v) branding = + LT.toStrict $ renderTextWithBranding t replace branding where replace "key" = Ascii.toText (fromRange k) replace "code" = Ascii.toText (fromRange v) @@ -130,16 +134,17 @@ renderApprovalUrl t (Code.Key k) (Code.Value v) = sendApprovalConfirmMail :: Name -> Email -> AppIO () sendApprovalConfirmMail name email = do tpl <- approvalConfirmEmail . snd <$> providerTemplates Nothing + branding <- view templateBranding let mail = ApprovalConfirmEmail email name - sendMail $ renderApprovalConfirmMail mail tpl + sendMail $ renderApprovalConfirmMail mail tpl branding data ApprovalConfirmEmail = ApprovalConfirmEmail { apcTo :: !Email , apcName :: !Name } -renderApprovalConfirmMail :: ApprovalConfirmEmail -> ApprovalConfirmEmailTemplate -> Mail -renderApprovalConfirmMail ApprovalConfirmEmail{..} ApprovalConfirmEmailTemplate{..} = +renderApprovalConfirmMail :: ApprovalConfirmEmail -> ApprovalConfirmEmailTemplate -> TemplateBranding -> Mail +renderApprovalConfirmMail ApprovalConfirmEmail{..} ApprovalConfirmEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", LT.toStrict subj) @@ -148,11 +153,11 @@ renderApprovalConfirmMail ApprovalConfirmEmail{..} ApprovalConfirmEmailTemplate{ , mailParts = [ [ plainPart txt, htmlPart html ] ] } where - from = Address (Just "Wire") (fromEmail approvalConfirmEmailSender) + from = Address (Just approvalConfirmEmailSenderName) (fromEmail approvalConfirmEmailSender) to = mkMimeAddress apcName apcTo - txt = renderText approvalConfirmEmailBodyText replace - html = renderHtml approvalConfirmEmailBodyHtml replace - subj = renderText approvalConfirmEmailSubject replace + txt = renderTextWithBranding approvalConfirmEmailBodyText replace branding + html = renderHtmlWithBranding approvalConfirmEmailBodyHtml replace branding + subj = renderTextWithBranding approvalConfirmEmailSubject replace branding replace "homeUrl" = pack $ show approvalConfirmEmailHomeUrl replace "email" = fromEmail apcTo @@ -165,8 +170,9 @@ renderApprovalConfirmMail ApprovalConfirmEmail{..} ApprovalConfirmEmailTemplate{ sendPasswordResetMail :: Email -> Code.Key -> Code.Value -> AppIO () sendPasswordResetMail to key code = do tpl <- passwordResetEmail . snd <$> providerTemplates Nothing + branding <- view templateBranding let mail = PasswordResetEmail to key code - sendMail $ renderPwResetMail mail tpl + sendMail $ renderPwResetMail mail tpl branding data PasswordResetEmail = PasswordResetEmail { pwrTo :: !Email @@ -174,8 +180,8 @@ data PasswordResetEmail = PasswordResetEmail , pwrCode :: !Code.Value } -renderPwResetMail :: PasswordResetEmail -> PasswordResetEmailTemplate -> Mail -renderPwResetMail PasswordResetEmail{..} PasswordResetEmailTemplate{..} = +renderPwResetMail :: PasswordResetEmail -> PasswordResetEmailTemplate -> TemplateBranding -> Mail +renderPwResetMail PasswordResetEmail{..} PasswordResetEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", LT.toStrict subj) @@ -188,18 +194,18 @@ renderPwResetMail PasswordResetEmail{..} PasswordResetEmailTemplate{..} = where (Code.Key key, Code.Value code) = (pwrKey, pwrCode) - from = Address (Just "Wire") (fromEmail passwordResetEmailSender) + from = Address (Just passwordResetEmailSenderName) (fromEmail passwordResetEmailSender) to = Address Nothing (fromEmail pwrTo) - txt = renderText passwordResetEmailBodyText replace - html = renderHtml passwordResetEmailBodyHtml replace - subj = renderText passwordResetEmailSubject replace + txt = renderTextWithBranding passwordResetEmailBodyText replace branding + html = renderHtmlWithBranding passwordResetEmailBodyHtml replace branding + subj = renderTextWithBranding passwordResetEmailSubject replace branding - replace "url" = renderPwResetUrl passwordResetEmailUrl pwrKey pwrCode + replace "url" = renderPwResetUrl passwordResetEmailUrl pwrKey pwrCode branding replace x = x -renderPwResetUrl :: Template -> Code.Key -> Code.Value -> Text -renderPwResetUrl t (Code.Key k) (Code.Value v) = - LT.toStrict $ renderText t replace +renderPwResetUrl :: Template -> Code.Key -> Code.Value -> TemplateBranding -> Text +renderPwResetUrl t (Code.Key k) (Code.Value v) branding = + LT.toStrict $ renderTextWithBranding t replace branding where replace "key" = Ascii.toText (fromRange k) replace "code" = Ascii.toText (fromRange v) diff --git a/services/brig/src/Brig/Provider/Template.hs b/services/brig/src/Brig/Provider/Template.hs index 5d0ed6664f6..178982cb4ba 100644 --- a/services/brig/src/Brig/Provider/Template.hs +++ b/services/brig/src/Brig/Provider/Template.hs @@ -35,6 +35,7 @@ data ActivationEmailTemplate = ActivationEmailTemplate , activationEmailBodyText :: !Template , activationEmailBodyHtml :: !Template , activationEmailSender :: !Email + , activationEmailSenderName :: !Text } data ApprovalRequestEmailTemplate = ApprovalRequestEmailTemplate @@ -43,6 +44,7 @@ data ApprovalRequestEmailTemplate = ApprovalRequestEmailTemplate , approvalRequestEmailBodyText :: !Template , approvalRequestEmailBodyHtml :: !Template , approvalRequestEmailSender :: !Email + , approvalRequestEmailSenderName :: !Text , approvalRequestEmailTo :: !Email } @@ -51,6 +53,7 @@ data ApprovalConfirmEmailTemplate = ApprovalConfirmEmailTemplate , approvalConfirmEmailBodyText :: !Template , approvalConfirmEmailBodyHtml :: !Template , approvalConfirmEmailSender :: !Email + , approvalConfirmEmailSenderName :: !Text , approvalConfirmEmailHomeUrl :: !HttpsUrl } @@ -60,6 +63,7 @@ data PasswordResetEmailTemplate = PasswordResetEmailTemplate , passwordResetEmailBodyText :: !Template , passwordResetEmailBodyHtml :: !Template , passwordResetEmailSender :: !Email + , passwordResetEmailSenderName :: !Text } -- TODO @@ -78,35 +82,41 @@ loadProviderTemplates o = readLocalesDir defLocale (templateDir gOptions) "provi <$> readTemplate fp "email/activation-subject.txt" <*> readTemplate fp "email/activation.txt" <*> readTemplate fp "email/activation.html" - <*> pure (emailSender gOptions)) + <*> pure (emailSender gOptions) + <*> readText fp "email/sender.txt") <*> (ActivationEmailTemplate activationUrl' <$> readTemplate fp "email/update-subject.txt" <*> readTemplate fp "email/update.txt" <*> readTemplate fp "email/update.html" - <*> pure (emailSender gOptions)) + <*> pure (emailSender gOptions) + <*> readText fp "email/sender.txt") <*> (ApprovalRequestEmailTemplate approvalUrl' <$> readTemplate fp "email/approval-request-subject.txt" <*> readTemplate fp "email/approval-request.txt" <*> readTemplate fp "email/approval-request.html" <*> pure (emailSender gOptions) + <*> readText fp "email/sender.txt" <*> pure (approvalTo pOptions)) <*> (ApprovalConfirmEmailTemplate <$> readTemplate fp "email/approval-confirm-subject.txt" <*> readTemplate fp "email/approval-confirm.txt" <*> readTemplate fp "email/approval-confirm.html" <*> pure (emailSender gOptions) + <*> readText fp "email/sender.txt" <*> pure (fromMaybe (error "Invalid HTTPS URL") maybeUrl)) <*> (PasswordResetEmailTemplate pwResetUrl' <$> readTemplate fp "email/password-reset-subject.txt" <*> readTemplate fp "email/password-reset.txt" <*> readTemplate fp "email/password-reset.html" - <*> pure (emailSender gOptions)) + <*> pure (emailSender gOptions) + <*> readText fp "email/sender.txt") where maybeUrl = fromByteString $ encodeUtf8 $ homeUrl pOptions gOptions = general $ emailSMS o pOptions = provider $ emailSMS o defLocale = setDefaultLocale (optSettings o) readTemplate = readTemplateWithDefault (templateDir gOptions) defLocale "provider" + readText = readTextWithDefault (templateDir gOptions) defLocale "provider" -- URL templates activationUrl' = template $ providerActivationUrl pOptions diff --git a/services/brig/src/Brig/Team/Email.hs b/services/brig/src/Brig/Team/Email.hs index b00afce1b4b..f0cb0c215f8 100644 --- a/services/brig/src/Brig/Team/Email.hs +++ b/services/brig/src/Brig/Team/Email.hs @@ -13,7 +13,9 @@ import Imports import Brig.App import Brig.Email import Brig.Team.Template +import Brig.Template import Brig.Types +import Control.Lens (view) import Data.Id (idToText, TeamId) import Data.Text.Lazy (toStrict) @@ -26,20 +28,23 @@ import qualified Data.Text.Ascii as Ascii sendInvitationMail :: Email -> TeamId -> Email -> InvitationCode -> Maybe Locale -> AppIO () sendInvitationMail to tid from code loc = do tpl <- invitationEmail . snd <$> teamTemplates loc + branding <- view templateBranding let mail = InvitationEmail to tid code from - Email.sendMail $ renderInvitationEmail mail tpl + Email.sendMail $ renderInvitationEmail mail tpl branding sendCreatorWelcomeMail :: Email -> TeamId -> Text -> Maybe Locale -> AppIO () sendCreatorWelcomeMail to tid teamName loc = do tpl <- creatorWelcomeEmail . snd <$> teamTemplates loc + branding <- view templateBranding let mail = CreatorWelcomeEmail to tid teamName - Email.sendMail $ renderCreatorWelcomeMail mail tpl + Email.sendMail $ renderCreatorWelcomeMail mail tpl branding sendMemberWelcomeMail :: Email -> TeamId -> Text -> Maybe Locale -> AppIO () sendMemberWelcomeMail to tid teamName loc = do tpl <- memberWelcomeEmail . snd <$> teamTemplates loc + branding <- view templateBranding let mail = MemberWelcomeEmail to tid teamName - Email.sendMail $ renderMemberWelcomeMail mail tpl + Email.sendMail $ renderMemberWelcomeMail mail tpl branding ------------------------------------------------------------------------------- -- Invitation Email @@ -51,8 +56,8 @@ data InvitationEmail = InvitationEmail , invInviter :: !Email } -renderInvitationEmail :: InvitationEmail -> InvitationEmailTemplate -> Mail -renderInvitationEmail InvitationEmail{..} InvitationEmailTemplate{..} = +renderInvitationEmail :: InvitationEmail -> InvitationEmailTemplate -> TemplateBranding -> Mail +renderInvitationEmail InvitationEmail{..} InvitationEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -66,17 +71,17 @@ renderInvitationEmail InvitationEmail{..} InvitationEmailTemplate{..} = from = Address (Just invitationEmailSenderName) (fromEmail invitationEmailSender) to = Address Nothing (fromEmail invTo) - txt = renderText invitationEmailBodyText replace - html = renderHtml invitationEmailBodyHtml replace - subj = renderText invitationEmailSubject replace + txt = renderTextWithBranding invitationEmailBodyText replace branding + html = renderHtmlWithBranding invitationEmailBodyHtml replace branding + subj = renderTextWithBranding invitationEmailSubject replace branding - replace "url" = renderInvitationUrl invitationEmailUrl invTeamId invInvCode + replace "url" = renderInvitationUrl invitationEmailUrl invTeamId invInvCode branding replace "inviter" = fromEmail invInviter replace x = x -renderInvitationUrl :: Template -> TeamId -> InvitationCode -> Text -renderInvitationUrl t tid (InvitationCode c) = - toStrict $ renderText t replace +renderInvitationUrl :: Template -> TeamId -> InvitationCode -> TemplateBranding -> Text +renderInvitationUrl t tid (InvitationCode c) branding = + toStrict $ renderTextWithBranding t replace branding where replace "team" = idToText tid replace "code" = Ascii.toText c @@ -91,8 +96,8 @@ data CreatorWelcomeEmail = CreatorWelcomeEmail , cwTeamName :: !Text } -renderCreatorWelcomeMail :: CreatorWelcomeEmail -> CreatorWelcomeEmailTemplate -> Mail -renderCreatorWelcomeMail CreatorWelcomeEmail{..} CreatorWelcomeEmailTemplate{..} = +renderCreatorWelcomeMail :: CreatorWelcomeEmail -> CreatorWelcomeEmailTemplate -> TemplateBranding -> Mail +renderCreatorWelcomeMail CreatorWelcomeEmail{..} CreatorWelcomeEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -103,9 +108,9 @@ renderCreatorWelcomeMail CreatorWelcomeEmail{..} CreatorWelcomeEmailTemplate{..} where from = Address (Just creatorWelcomeEmailSenderName) (fromEmail creatorWelcomeEmailSender) to = Address Nothing (fromEmail cwTo) - txt = renderText creatorWelcomeEmailBodyText replace - html = renderHtml creatorWelcomeEmailBodyHtml replace - subj = renderText creatorWelcomeEmailSubject replace + txt = renderTextWithBranding creatorWelcomeEmailBodyText replace branding + html = renderHtmlWithBranding creatorWelcomeEmailBodyHtml replace branding + subj = renderTextWithBranding creatorWelcomeEmailSubject replace branding replace "url" = creatorWelcomeEmailUrl replace "email" = fromEmail cwTo @@ -122,8 +127,8 @@ data MemberWelcomeEmail = MemberWelcomeEmail , mwTeamName :: !Text } -renderMemberWelcomeMail :: MemberWelcomeEmail -> MemberWelcomeEmailTemplate -> Mail -renderMemberWelcomeMail MemberWelcomeEmail{..} MemberWelcomeEmailTemplate{..} = +renderMemberWelcomeMail :: MemberWelcomeEmail -> MemberWelcomeEmailTemplate -> TemplateBranding -> Mail +renderMemberWelcomeMail MemberWelcomeEmail{..} MemberWelcomeEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -134,9 +139,9 @@ renderMemberWelcomeMail MemberWelcomeEmail{..} MemberWelcomeEmailTemplate{..} = where from = Address (Just memberWelcomeEmailSenderName) (fromEmail memberWelcomeEmailSender) to = Address Nothing (fromEmail mwTo) - txt = renderText memberWelcomeEmailBodyText replace - html = renderHtml memberWelcomeEmailBodyHtml replace - subj = renderText memberWelcomeEmailSubject replace + txt = renderTextWithBranding memberWelcomeEmailBodyText replace branding + html = renderHtmlWithBranding memberWelcomeEmailBodyHtml replace branding + subj = renderTextWithBranding memberWelcomeEmailSubject replace branding replace "url" = memberWelcomeEmailUrl replace "email" = fromEmail mwTo diff --git a/services/brig/src/Brig/Template.hs b/services/brig/src/Brig/Template.hs index 884073df528..bbe3d3a5451 100644 --- a/services/brig/src/Brig/Template.hs +++ b/services/brig/src/Brig/Template.hs @@ -1,3 +1,5 @@ +{-# LANGUAGE RecordWildCards #-} + -- | Common templating utilities. module Brig.Template ( -- * Reading templates @@ -10,6 +12,10 @@ module Brig.Template -- * Rendering templates , renderText , renderHtml + , renderTextWithBranding + , renderHtmlWithBranding + , genTemplateBranding + , TemplateBranding -- * Re-exports , Template @@ -17,6 +23,7 @@ module Brig.Template ) where import Imports hiding (readFile) +import Brig.Options import Brig.Types (Locale (..), parseLocale, locToText) import Control.Exception (catchJust) import Data.Text (pack, unpack) @@ -30,6 +37,9 @@ import qualified Data.Text.Lazy as Lazy import qualified Data.Text.Template as Template import qualified HTMLEntities.Text as HTML +-- | See 'genTemplateBranding'. +type TemplateBranding = Text -> Text + -- | Localised templates. data Localised a = Localised { locDefault :: !(Locale, a) @@ -105,11 +115,23 @@ readText f = catchJust (\e -> if isDoesNotExistError e then Just () else Nothing (readFile f) (\_ -> error $ "Missing file: '" ++ f) +-- | Uses a replace and a branding function, to replaces all placeholders from the +-- given template to produce a Text. To be used on plain text templates +renderTextWithBranding :: Template -> (Text -> Text) -> TemplateBranding -> Lazy.Text +renderTextWithBranding tpl replace branding = renderText tpl (replace . branding) + +-- | Uses a replace and a branding function to replace all placeholders from the +-- given template to produce a Text. To be used on HTML templates +renderHtmlWithBranding :: Template -> (Text -> Text) -> TemplateBranding -> Lazy.Text +renderHtmlWithBranding tpl replace branding = renderHtml tpl (replace . branding) + +-- TODO: Do not export this function renderText :: Template -> (Text -> Text) -> Lazy.Text renderText = Template.render +-- TODO: Do not export this function renderHtml :: Template -> (Text -> Text) -> Lazy.Text -renderHtml tpl f = renderText tpl (HTML.text . f) +renderHtml tpl replace = renderText tpl (HTML.text . replace) readWithDefault :: (String -> IO a) -> FilePath @@ -131,3 +153,21 @@ readWithDefault readFn baseDir defLoc typ prefix name = do <> unpack (locToText defLoc) <> "/" <> typ <> "/" <> name + +-- | Function to be applied everywhere where email/sms/call +-- templating is used (ensures that placeholders are replaced +-- by the appropriate branding, typically Wire) +genTemplateBranding :: BrandingOpts -> TemplateBranding +genTemplateBranding BrandingOpts{..} = fn + where + fn "brand" = brand + fn "brand_url" = brandUrl + fn "brand_label_url" = brandLabelUrl + fn "brand_logo" = brandLogoUrl + fn "brand_service" = brandService + fn "copyright" = copyright + fn "misuse" = misuse + fn "legal" = legal + fn "forgot" = forgot + fn "support" = support + fn other = other diff --git a/services/brig/src/Brig/User/Email.hs b/services/brig/src/Brig/User/Email.hs index 71991883181..65f48cb2cc7 100644 --- a/services/brig/src/Brig/User/Email.hs +++ b/services/brig/src/Brig/User/Email.hs @@ -17,7 +17,9 @@ import Brig.App import Brig.Email import Brig.Locale (formatDateTime, timeLocale) import Brig.User.Template +import Brig.Template import Brig.Types +import Control.Lens (view) import Data.Json.Util (fromUTCTimeMillis) import Data.Range import Data.Text.Lazy (toStrict) @@ -29,14 +31,16 @@ import qualified Data.Text.Ascii as Ascii sendVerificationMail :: Email -> ActivationPair -> Maybe Locale -> AppIO () sendVerificationMail to pair loc = do tpl <- verificationEmail . snd <$> userTemplates loc + branding <- view templateBranding let mail = VerificationEmail to pair - Email.sendMail $ renderVerificationMail mail tpl + Email.sendMail $ renderVerificationMail mail tpl branding sendActivationMail :: Email -> Name -> ActivationPair -> Maybe Locale -> Maybe UserIdentity -> AppIO () sendActivationMail to name pair loc ident = do tpl <- selectTemplate . snd <$> userTemplates loc + branding <- view templateBranding let mail = ActivationEmail to name pair - Email.sendMail $ renderActivationMail mail tpl + Email.sendMail $ renderActivationMail mail tpl branding where selectTemplate = if isNothing ident @@ -46,24 +50,28 @@ sendActivationMail to name pair loc ident = do sendPasswordResetMail :: Email -> PasswordResetPair -> Maybe Locale -> AppIO () sendPasswordResetMail to pair loc = do tpl <- passwordResetEmail . snd <$> userTemplates loc + branding <- view templateBranding let mail = PasswordResetEmail to pair - Email.sendMail $ renderPwResetMail mail tpl + Email.sendMail $ renderPwResetMail mail tpl branding sendDeletionEmail :: Name -> Email -> Code.Key -> Code.Value -> Locale -> AppIO () sendDeletionEmail name email key code locale = do tpl <- deletionEmail . snd <$> userTemplates (Just locale) - Email.sendMail $ renderDeletionEmail tpl (DeletionEmail email name key code) + branding <- view templateBranding + Email.sendMail $ renderDeletionEmail tpl (DeletionEmail email name key code) branding sendNewClientEmail :: Name -> Email -> Client -> Locale -> AppIO () sendNewClientEmail name email client locale = do tpl <- newClientEmail . snd <$> userTemplates (Just locale) - Email.sendMail $ renderNewClientEmail tpl (NewClientEmail locale email name client) + branding <- view templateBranding + Email.sendMail $ renderNewClientEmail tpl (NewClientEmail locale email name client) branding sendTeamActivationMail :: Email -> Name -> ActivationPair -> Maybe Locale -> Text -> AppIO () sendTeamActivationMail to name pair loc team = do tpl <- teamActivationEmail . snd <$> userTemplates loc let mail = TeamActivationEmail to name team pair - Email.sendMail $ renderTeamActivationMail mail tpl + branding <- view templateBranding + Email.sendMail $ renderTeamActivationMail mail tpl branding ------------------------------------------------------------------------------- -- New Client Email @@ -75,8 +83,8 @@ data NewClientEmail = NewClientEmail , nclClient :: !Client } -renderNewClientEmail :: NewClientEmailTemplate -> NewClientEmail -> Mail -renderNewClientEmail NewClientEmailTemplate{..} NewClientEmail{..} = +renderNewClientEmail :: NewClientEmailTemplate -> NewClientEmail -> TemplateBranding -> Mail +renderNewClientEmail NewClientEmailTemplate{..} NewClientEmail{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -87,9 +95,9 @@ renderNewClientEmail NewClientEmailTemplate{..} NewClientEmail{..} = where from = Address (Just newClientEmailSenderName) (fromEmail newClientEmailSender) to = mkMimeAddress nclName nclTo - txt = renderText newClientEmailBodyText replace - html = renderHtml newClientEmailBodyHtml replace - subj = renderText newClientEmailSubject replace + txt = renderTextWithBranding newClientEmailBodyText replace branding + html = renderHtmlWithBranding newClientEmailBodyHtml replace branding + subj = renderTextWithBranding newClientEmailSubject replace branding replace "name" = fromName nclName replace "label" = fromMaybe "N/A" (clientLabel nclClient) @@ -109,8 +117,8 @@ data DeletionEmail = DeletionEmail , delCode :: !Code.Value } -renderDeletionEmail :: DeletionEmailTemplate -> DeletionEmail -> Mail -renderDeletionEmail DeletionEmailTemplate{..} DeletionEmail{..} = +renderDeletionEmail :: DeletionEmailTemplate -> DeletionEmail -> TemplateBranding -> Mail +renderDeletionEmail DeletionEmailTemplate{..} DeletionEmail{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -124,14 +132,14 @@ renderDeletionEmail DeletionEmailTemplate{..} DeletionEmail{..} = from = Address (Just deletionEmailSenderName) (fromEmail deletionEmailSender) to = mkMimeAddress delName delTo - txt = renderText deletionEmailBodyText replace1 - html = renderHtml deletionEmailBodyHtml replace1 - subj = renderText deletionEmailSubject replace1 + txt = renderTextWithBranding deletionEmailBodyText replace1 branding + html = renderHtmlWithBranding deletionEmailBodyHtml replace1 branding + subj = renderTextWithBranding deletionEmailSubject replace1 branding key = Ascii.toText (fromRange (Code.asciiKey delKey)) code = Ascii.toText (fromRange (Code.asciiValue delCode)) - replace1 "url" = toStrict (renderText deletionEmailUrl replace2) + replace1 "url" = toStrict (renderTextWithBranding deletionEmailUrl replace2 branding) replace1 "email" = fromEmail delTo replace1 "name" = fromName delName replace1 x = x @@ -148,8 +156,8 @@ data VerificationEmail = VerificationEmail , vfPair :: !ActivationPair } -renderVerificationMail :: VerificationEmail -> VerificationEmailTemplate -> Mail -renderVerificationMail VerificationEmail{..} VerificationEmailTemplate{..} = +renderVerificationMail :: VerificationEmail -> VerificationEmailTemplate -> TemplateBranding -> Mail +renderVerificationMail VerificationEmail{..} VerificationEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -163,9 +171,9 @@ renderVerificationMail VerificationEmail{..} VerificationEmailTemplate{..} = from = Address (Just verificationEmailSenderName) (fromEmail verificationEmailSender) to = Address Nothing (fromEmail vfTo) - txt = renderText verificationEmailBodyText replace - html = renderHtml verificationEmailBodyHtml replace - subj = renderText verificationEmailSubject replace + txt = renderTextWithBranding verificationEmailBodyText replace branding + html = renderHtmlWithBranding verificationEmailBodyHtml replace branding + subj = renderTextWithBranding verificationEmailSubject replace branding replace "code" = Ascii.toText code replace "email" = fromEmail vfTo @@ -180,8 +188,8 @@ data ActivationEmail = ActivationEmail , acmPair :: !ActivationPair } -renderActivationMail :: ActivationEmail -> ActivationEmailTemplate -> Mail -renderActivationMail ActivationEmail{..} ActivationEmailTemplate{..} = +renderActivationMail :: ActivationEmail -> ActivationEmailTemplate -> TemplateBranding -> Mail +renderActivationMail ActivationEmail{..} ActivationEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -196,18 +204,18 @@ renderActivationMail ActivationEmail{..} ActivationEmailTemplate{..} = from = Address (Just activationEmailSenderName) (fromEmail activationEmailSender) to = mkMimeAddress acmName acmTo - txt = renderText activationEmailBodyText replace - html = renderHtml activationEmailBodyHtml replace - subj = renderText activationEmailSubject replace + txt = renderTextWithBranding activationEmailBodyText replace branding + html = renderHtmlWithBranding activationEmailBodyHtml replace branding + subj = renderTextWithBranding activationEmailSubject replace branding - replace "url" = renderActivationUrl activationEmailUrl acmPair + replace "url" = renderActivationUrl activationEmailUrl acmPair branding replace "email" = fromEmail acmTo replace "name" = fromName acmName replace x = x -renderActivationUrl :: Template -> ActivationPair -> Text -renderActivationUrl t (ActivationKey k, ActivationCode c) = - toStrict $ renderText t replace +renderActivationUrl :: Template -> ActivationPair -> TemplateBranding -> Text +renderActivationUrl t (ActivationKey k, ActivationCode c) branding = + toStrict $ renderTextWithBranding t replace branding where replace "key" = Ascii.toText k replace "code" = Ascii.toText c @@ -223,8 +231,8 @@ data TeamActivationEmail = TeamActivationEmail , tacmPair :: !ActivationPair } -renderTeamActivationMail :: TeamActivationEmail -> TeamActivationEmailTemplate -> Mail -renderTeamActivationMail TeamActivationEmail{..} TeamActivationEmailTemplate{..} = +renderTeamActivationMail :: TeamActivationEmail -> TeamActivationEmailTemplate -> TemplateBranding -> Mail +renderTeamActivationMail TeamActivationEmail{..} TeamActivationEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -239,11 +247,11 @@ renderTeamActivationMail TeamActivationEmail{..} TeamActivationEmailTemplate{..} from = Address (Just teamActivationEmailSenderName) (fromEmail teamActivationEmailSender) to = mkMimeAddress tacmName tacmTo - txt = renderText teamActivationEmailBodyText replace - html = renderHtml teamActivationEmailBodyHtml replace - subj = renderText teamActivationEmailSubject replace + txt = renderTextWithBranding teamActivationEmailBodyText replace branding + html = renderHtmlWithBranding teamActivationEmailBodyHtml replace branding + subj = renderTextWithBranding teamActivationEmailSubject replace branding - replace "url" = renderActivationUrl teamActivationEmailUrl tacmPair + replace "url" = renderActivationUrl teamActivationEmailUrl tacmPair branding replace "email" = fromEmail tacmTo replace "name" = fromName tacmName replace "team" = tacmTeamName @@ -257,8 +265,8 @@ data PasswordResetEmail = PasswordResetEmail , pwrPair :: !PasswordResetPair } -renderPwResetMail :: PasswordResetEmail -> PasswordResetEmailTemplate -> Mail -renderPwResetMail PasswordResetEmail{..} PasswordResetEmailTemplate{..} = +renderPwResetMail :: PasswordResetEmail -> PasswordResetEmailTemplate -> TemplateBranding -> Mail +renderPwResetMail PasswordResetEmail{..} PasswordResetEmailTemplate{..} branding = (emptyMail from) { mailTo = [ to ] , mailHeaders = [ ("Subject", toStrict subj) @@ -273,16 +281,16 @@ renderPwResetMail PasswordResetEmail{..} PasswordResetEmailTemplate{..} = from = Address (Just passwordResetEmailSenderName) (fromEmail passwordResetEmailSender) to = Address Nothing (fromEmail pwrTo) - txt = renderText passwordResetEmailBodyText replace - html = renderHtml passwordResetEmailBodyHtml replace - subj = renderText passwordResetEmailSubject replace + txt = renderTextWithBranding passwordResetEmailBodyText replace branding + html = renderHtmlWithBranding passwordResetEmailBodyHtml replace branding + subj = renderTextWithBranding passwordResetEmailSubject replace branding - replace "url" = renderPwResetUrl passwordResetEmailUrl pwrPair + replace "url" = renderPwResetUrl passwordResetEmailUrl pwrPair branding replace x = x -renderPwResetUrl :: Template -> PasswordResetPair -> Text -renderPwResetUrl t (PasswordResetKey k, PasswordResetCode c) = - toStrict $ renderText t replace +renderPwResetUrl :: Template -> PasswordResetPair -> TemplateBranding -> Text +renderPwResetUrl t (PasswordResetKey k, PasswordResetCode c) branding = + toStrict $ renderTextWithBranding t replace branding where replace "key" = Ascii.toText k replace "code" = Ascii.toText c diff --git a/services/brig/test/integration/API/RichInfo/Util.hs b/services/brig/test/integration/API/RichInfo/Util.hs new file mode 100644 index 00000000000..c55574bfb60 --- /dev/null +++ b/services/brig/test/integration/API/RichInfo/Util.hs @@ -0,0 +1,38 @@ +module API.RichInfo.Util where + +import Imports +import Bilge +import Brig.Types +import Data.ByteString.Conversion +import Data.Id +import Util + +getRichInfo + :: HasCallStack + => Brig + -> UserId -- ^ The user who is performing the query + -> UserId -- ^ The users whose rich info is being queried + -> Http (Either Int RichInfo) +getRichInfo brig self uid = do + r <- get ( brig + . paths ["users", toByteString' uid, "rich-info"] + . zUser self + ) + if | statusCode r == 200 -> Right <$> decodeBody r + | statusCode r `elem` [403, 404] -> pure . Left . statusCode $ r + | otherwise -> error $ + "expected status code 200, 403, or 404, got: " <> show (statusCode r) + +-- | This contacts an internal end-point. Note the asymmetry between this and the external +-- GET end-point in the body: here we need to wrap the 'RichInfo' in a 'RichInfoUpdate'. +putRichInfo + :: HasCallStack + => Brig + -> UserId -- ^ The user whose rich info is being updated + -> RichInfo + -> Http ResponseLBS +putRichInfo brig uid rinfo = do + put ( brig + . paths ["i", "users", toByteString' uid, "rich-info"] + . json (RichInfoUpdate rinfo) + ) diff --git a/services/brig/test/integration/API/User.hs b/services/brig/test/integration/API/User.hs index 16ac865ccf6..d62e13b647c 100644 --- a/services/brig/test/integration/API/User.hs +++ b/services/brig/test/integration/API/User.hs @@ -16,6 +16,7 @@ import qualified API.User.Handles import qualified API.User.Onboarding import qualified API.User.PasswordReset import qualified API.User.Property +import qualified API.User.RichInfo import qualified Brig.AWS as AWS import qualified Brig.Options as Opt @@ -35,6 +36,7 @@ tests conf p b c ch g aws = do , API.User.Onboarding.tests cl at conf p b c g , API.User.PasswordReset.tests cl at conf p b c g , API.User.Property.tests cl at conf p b c g + , API.User.RichInfo.tests cl at conf p b c g ] mkZAuthEnv :: Maybe Opt.Opts -> IO ZAuth.Env diff --git a/services/brig/test/integration/API/User/RichInfo.hs b/services/brig/test/integration/API/User/RichInfo.hs new file mode 100644 index 00000000000..a5c201c6259 --- /dev/null +++ b/services/brig/test/integration/API/User/RichInfo.hs @@ -0,0 +1,131 @@ +module API.User.RichInfo (tests) where + +import Imports +import API.Team.Util (createUserWithTeam, createTeamMember) +import API.User.Util +import API.RichInfo.Util +import Bilge hiding (accept, timeout) +import Bilge.Assert +import Brig.Types +import Brig.Options +import Test.Tasty hiding (Timeout) +import Test.Tasty.HUnit +import Util + +import qualified Brig.Options as Opt +import qualified Data.List1 as List1 +import qualified Data.Text as Text +import qualified Galley.Types.Teams as Team + +tests :: ConnectionLimit -> Opt.Timeout -> Maybe Opt.Opts -> Manager -> Brig -> Cannon -> Galley -> TestTree +tests _cl _at conf p b _c g = testGroup "rich info" + [ test p "there is default empty rich info" $ testDefaultRichInfo b g + , test p "missing fields in an update are deleted" $ testDeleteMissingFieldsInUpdates b g + , test p "fields with empty strings are deleted" $ testDeleteEmptyFields b g + , test p "duplicate field names are forbidden" $ testForbidDuplicateFieldNames b g + , test p "exceeding rich info size limit is forbidden" $ testRichInfoSizeLimit b g conf + , test p "non-team members don't have rich info" $ testNonTeamMembersDoNotHaveRichInfo b g + , test p "non-members / other membes / guests cannot see rich info" $ testGuestsCannotSeeRichInfo b g + ] + +-- | Test that for team members there is rich info set by default, and that it's empty. +testDefaultRichInfo :: Brig -> Galley -> Http () +testDefaultRichInfo brig galley = do + -- Create a team with two users + (owner, tid) <- createUserWithTeam brig galley + member1 <- userId <$> createTeamMember brig galley owner tid Team.noPermissions + member2 <- userId <$> createTeamMember brig galley owner tid Team.noPermissions + -- The first user should see the second user's rich info and it should be empty + richInfo <- getRichInfo brig member1 member2 + liftIO $ assertEqual "rich info is not empty, or not present" + (Right (RichInfo {richInfoFields = []})) + richInfo + +testDeleteMissingFieldsInUpdates :: Brig -> Galley -> Http () +testDeleteMissingFieldsInUpdates brig galley = do + (owner, tid) <- createUserWithTeam brig galley + member1 <- userId <$> createTeamMember brig galley owner tid Team.noPermissions + member2 <- userId <$> createTeamMember brig galley owner tid Team.noPermissions + let superset = RichInfo + [ RichField "department" "blue" + , RichField "relevance" "meh" + ] + subset = RichInfo + [ RichField "relevance" "meh" + ] + putRichInfo brig member2 superset !!! const 200 === statusCode + putRichInfo brig member2 subset !!! const 200 === statusCode + subset' <- getRichInfo brig member1 member2 + liftIO $ assertEqual "dangling rich info fields" (Right subset) subset' + +testDeleteEmptyFields :: Brig -> Galley -> Http () +testDeleteEmptyFields brig galley = do + (owner, tid) <- createUserWithTeam brig galley + member1 <- userId <$> createTeamMember brig galley owner tid Team.noPermissions + member2 <- userId <$> createTeamMember brig galley owner tid Team.noPermissions + let withEmpty = RichInfo + [ RichField "department" "" + ] + putRichInfo brig member2 withEmpty !!! const 200 === statusCode + withoutEmpty <- getRichInfo brig member1 member2 + liftIO $ assertEqual "dangling rich info fields" (Right $ RichInfo []) withoutEmpty + +testForbidDuplicateFieldNames :: Brig -> Galley -> Http () +testForbidDuplicateFieldNames brig galley = do + (owner, _) <- createUserWithTeam brig galley + let bad = RichInfo + [ RichField "department" "blue" + , RichField "department" "green" + ] + putRichInfo brig owner bad !!! const 400 === statusCode + +testRichInfoSizeLimit :: HasCallStack => Brig -> Galley -> Maybe Opt.Opts -> Http () +testRichInfoSizeLimit _ _ Nothing = error "this test needs a config file" +testRichInfoSizeLimit brig galley (Just conf) = do + let maxSize :: Int = setRichInfoLimit $ optSettings conf + (owner, _) <- createUserWithTeam brig galley + let bad1 = RichInfo + [ RichField "department" (Text.replicate (fromIntegral maxSize) "#") + ] + bad2 = RichInfo $ [0 .. ((maxSize `div` 2))] <&> + \i -> RichField (Text.pack $ show i) "#" + putRichInfo brig owner bad1 !!! const 413 === statusCode + putRichInfo brig owner bad2 !!! const 413 === statusCode + +-- | Test that rich info of non-team members can not be queried. +-- +-- Note: it would be nice to also test that non-team members can not set rich info, but for +-- now there's no public endpoint for setting it in Brig, so we can't do anything. +testNonTeamMembersDoNotHaveRichInfo :: Brig -> Galley -> Http () +testNonTeamMembersDoNotHaveRichInfo brig galley = do + -- Create a user + targetUser <- userId <$> randomUser brig + -- Another user should get a 'Nothing' when querying their info + do nonTeamUser <- userId <$> randomUser brig + richInfo <- getRichInfo brig nonTeamUser targetUser + liftIO $ assertEqual "rich info is present" (Left 403) richInfo + -- A team member should also get a 'Nothing' when querying their info + do (teamUser, _) <- createUserWithTeam brig galley + richInfo <- getRichInfo brig teamUser targetUser + liftIO $ assertEqual "rich info is present" (Left 403) richInfo + +testGuestsCannotSeeRichInfo :: Brig -> Galley -> Http () +testGuestsCannotSeeRichInfo brig galley = do + -- Create a team + (owner, _) <- createUserWithTeam brig galley + + -- A non-team user should get "forbidden" when querying rich info for team user. + do nonTeamUser <- userId <$> randomUser brig + richInfo <- getRichInfo brig nonTeamUser owner + liftIO $ assertEqual "rich info status /= 403" (Left 403) richInfo + + -- ... even if she's a guest in the team... + do guest <- userId <$> randomUser brig + connectUsers brig owner (List1.singleton guest) + richInfo <- getRichInfo brig guest owner + liftIO $ assertEqual "rich info status /= 403" (Left 403) richInfo + + -- ... or if she's in another team. + do (otherOwner, _) <- createUserWithTeam brig galley + richInfo <- getRichInfo brig otherOwner owner + liftIO $ assertEqual "rich info status /= 403" (Left 403) richInfo diff --git a/services/gundeck/deb/etc/sv/gundeck/run b/services/gundeck/deb/etc/sv/gundeck/run index 93757a4ef37..0f6b45f4574 100755 --- a/services/gundeck/deb/etc/sv/gundeck/run +++ b/services/gundeck/deb/etc/sv/gundeck/run @@ -6,47 +6,14 @@ exec 2>&1 # defaults USER=${USER:=www-data} APP=gundeck -CONFIG=${CONFIG:=/etc/$APP/.env} +CONFIG=${CONFIG:-/etc/${APP}/${APP}.yaml} HOME=${APP_HOME:=/opt/$APP} BIN=$HOME/bin/$APP -chpst -u $USER get_config -source $CONFIG - -source <(khan --silent metadata --multiline) - -GUNDECK_DISCO_URL="http://${KHAN_ENV}-${KHAN_REGION_ABBREV}-klabautermann.${KHAN_DOMAIN}/describe-instances" - -export LOG_LEVEL=${GUNDECK_LOG_LEVEL:-Debug} -export LOG_BUFFER=${GUNDECK_LOG_BUFFER:-4096} -export LOG_NETSTR=${GUNDECK_LOG_NETSTR:-True} - -if [ -n "$GUNDECK_CANNON_BULK_PUSH" ]; then - GUNDECK_CANNON_BULK_PUSH="--bulk-push" -else - GUNDECK_CANNON_BULK_PUSH="" -fi +if [ ! -f $CONFIG ]; then exec chpst -u $USER get_config; fi cd $HOME ulimit -n 65536 -exec chpst -u $USER \ - $BIN \ - --host=${GUNDECK_HOST:-'127.0.0.1'} \ - --port=${GUNDECK_PORT?'unset'} \ - --cassandra-host=${GUNDECK_CASSANDRA_HOST?'unset'} \ - --cassandra-port=${GUNDECK_CASSANDRA_PORT?'unset'} \ - --cassandra-keyspace=${GUNDECK_CASSANDRA_KEYSPACE?'unset'} \ - --disco-url=${GUNDECK_DISCO_URL?'unset'} \ - --redis-host=${GUNDECK_REDIS_HOST?'unset'} \ - --redis-port=${GUNDECK_REDIS_PORT?'unset'} \ - --http-pool-size=${GUNDECK_HTTP_POOL_SIZE:-128} \ - --event-queue-name=${GUNDECK_EVENT_QUEUE_NAME?'unset'} \ - --notification-ttl=${GUNDECK_NOTIFICATION_TTL?'unset'} \ - --aws-region=${KHAN_REGION?'unset'} \ - --aws-account=${AWS_ACCOUNT_ID?'unset'} \ - --aws-arn-env=${KHAN_ENV?'unset'} \ - --aws-sqs-endpoint=${GUNDECK_AWS_SQS_ENDPOINT:-'https://sqs.eu-west-1.amazonaws.com'} \ - --aws-sns-endpoint=${GUNDECK_AWS_SNS_ENDPOINT:-'https://sns.eu-west-1.amazonaws.com'} \ - ${GUNDECK_CANNON_BULK_PUSH} +exec chpst -u $USER $BIN --config-file=${CONFIG} diff --git a/services/gundeck/gundeck.integration.yaml b/services/gundeck/gundeck.integration.yaml index b0d8b8c291d..ebd3897ce8a 100644 --- a/services/gundeck/gundeck.integration.yaml +++ b/services/gundeck/gundeck.integration.yaml @@ -24,3 +24,6 @@ settings: httpPoolSize: 1024 notificationTTL: 24192200 bulkPush: true + +logLevel: Info +logNetStrings: false diff --git a/services/gundeck/src/Gundeck/Env.hs b/services/gundeck/src/Gundeck/Env.hs index c9a30ec3d44..bfbf946c1ae 100644 --- a/services/gundeck/src/Gundeck/Env.hs +++ b/services/gundeck/src/Gundeck/Env.hs @@ -40,9 +40,16 @@ makeLenses ''Env schemaVersion :: Int32 schemaVersion = 7 +mkLogger :: Opts -> IO Logger +mkLogger opts = Logger.new $ Logger.defSettings + & Logger.setLogLevel (opts ^. optLogLevel) + & Logger.setOutput Logger.StdOut + & Logger.setFormat Nothing + & Logger.setNetStrings (opts ^. optLogNetStrings) + createEnv :: Metrics -> Opts -> IO Env createEnv m o = do - l <- new $ setOutput StdOut . setFormat Nothing $ defSettings + l <- mkLogger o c <- maybe (C.initialContactsPlain (o^.optCassandra.casEndpoint.epHost)) (C.initialContactsDisco "cassandra_gundeck") (unpack <$> o^.optDiscoUrl) diff --git a/services/gundeck/src/Gundeck/Options.hs b/services/gundeck/src/Gundeck/Options.hs index db8317c2da4..87fcad453b0 100644 --- a/services/gundeck/src/Gundeck/Options.hs +++ b/services/gundeck/src/Gundeck/Options.hs @@ -3,12 +3,11 @@ module Gundeck.Options where import Imports -import Control.Lens +import Control.Lens hiding (Level) import Data.Aeson.TH import Data.Yaml (FromJSON) import Gundeck.Aws.Arn -import Options.Applicative -import Options.Applicative.Types +import System.Logger (Level) import Util.Options import Util.Options.Common @@ -17,10 +16,10 @@ newtype NotificationTTL = NotificationTTL deriving (Eq, Ord, Show, Generic, FromJSON) data AWSOpts = AWSOpts - { _awsAccount :: !Account - , _awsRegion :: !Region - , _awsArnEnv :: !ArnEnv - , _awsQueueName :: !Text + { _awsAccount :: !Account -- ^ AWS account + , _awsRegion :: !Region -- ^ AWS region name + , _awsArnEnv :: !ArnEnv -- ^ Environment name to scope ARNs to + , _awsQueueName :: !Text -- ^ SQS queue name , _awsSqsEndpoint :: !AWSEndpoint , _awsSnsEndpoint :: !AWSEndpoint } deriving (Show, Generic) @@ -29,8 +28,13 @@ deriveFromJSON toOptionFieldName ''AWSOpts makeLenses ''AWSOpts data Settings = Settings - { _setHttpPoolSize :: !Int + { + -- | Number of connections to keep open in the http-client pool + _setHttpPoolSize :: !Int + -- | TTL (seconds) of stored notifications , _setNotificationTTL :: !NotificationTTL + -- | Use this option to group push notifications and send them in bulk to Cannon, instead + -- of in individual requests , _setBulkPush :: !Bool } deriving (Show, Generic) @@ -38,110 +42,17 @@ deriveFromJSON toOptionFieldName ''Settings makeLenses ''Settings data Opts = Opts - { _optGundeck :: !Endpoint + { _optGundeck :: !Endpoint -- ^ Hostname and port to bind to , _optCassandra :: !CassandraOpts , _optRedis :: !Endpoint , _optAws :: !AWSOpts , _optDiscoUrl :: !(Maybe Text) , _optSettings :: !Settings + -- Logging + , _optLogLevel :: !Level -- ^ Log level (Debug, Info, etc) + , _optLogNetStrings :: !Bool -- ^ Use netstrings encoding: + -- } deriving (Show, Generic) deriveFromJSON toOptionFieldName ''Opts makeLenses ''Opts - -parseOptions :: IO Opts -parseOptions = execParser (info (helper <*> optsParser) desc) - where - desc = header "Gundeck - Push Notifications" <> fullDesc - -optsParser :: Parser Opts -optsParser = Opts <$> - (Endpoint <$> - (textOption $ - long "host" - <> value "*4" - <> showDefault - <> metavar "HOSTNAME" - <> help "Hostname or address to bind to") - <*> - (option auto $ - long "port" - <> short 'p' - <> metavar "PORT" - <> help "Port to listen on")) - <*> cassandraParser - <*> redisParser - <*> awsParser - <*> optional discoUrlParser - <*> settingsParser - where - redisParser :: Parser Endpoint - redisParser = Endpoint <$> - (textOption $ - long "redis-host" - <> metavar "HOSTNAME" - <> help "Redis hostname") - <*> - (option auto $ - long "redis-port" - <> metavar "PORT" - <> help "Redis port") - - awsParser :: Parser AWSOpts - awsParser = AWSOpts <$> - (fmap Account . textOption $ - long "aws-account" - <> metavar "STRING" - <> help "aws account") - <*> - (option parseRegion $ - long "aws-region" - <> metavar "STRING" - <> help "aws region name") - <*> - (fmap ArnEnv . textOption $ - long "aws-arn-env" - <> metavar "STRING" - <> help "environment name to scope ARNs to") - <*> - (textOption $ - long "event-queue-name" - <> metavar "STRING" - <> help "sqs queue name") - <*> - (option parseAWSEndpoint $ - long "aws-sqs-endpoint" - <> metavar "STRING" - <> value (AWSEndpoint "sqs.eu-west-1.amazonaws.com" True 443) - <> showDefault - <> help "aws SQS endpoint") - <*> - (option parseAWSEndpoint $ - long "aws-sns-endpoint" - <> metavar "STRING" - <> value (AWSEndpoint "sns.eu-west-1.amazonaws.com" True 443) - <> showDefault - <> help "aws SNS endpoint") - - settingsParser :: Parser Settings - settingsParser = Settings <$> - (option auto $ - long "http-pool-size" - <> metavar "SIZE" - <> showDefault - <> help "number of connections for the http client pool" - <> value 128) - <*> - (fmap NotificationTTL . option auto $ - long "notification-ttl" - <> metavar "SIZE" - <> showDefault - <> help "TTL (seconds) of stored notifications" - <> value 86400) - <*> - (switch $ - long "bulk-push" - <> help ("Use this option to group push notifications and send them " <> - "in bulk to Cannon, instead of in individual requests.")) - - parseRegion = readerAsk >>= either readerError return . fromText . fromString diff --git a/services/gundeck/src/Main.hs b/services/gundeck/src/Main.hs index cc7472472d0..4eb72df51b4 100644 --- a/services/gundeck/src/Main.hs +++ b/services/gundeck/src/Main.hs @@ -4,12 +4,11 @@ import Imports import Gundeck.API import OpenSSL (withOpenSSL) -import Gundeck.Options import Util.Options main :: IO () main = withOpenSSL $ do - options <- getOptions desc (Just optsParser) defaultPath + options <- getOptions desc Nothing defaultPath runServer options where desc = "Gundeck - Push Notification Hub Service" diff --git a/services/integration.sh b/services/integration.sh index d7656898fbf..bd246fa011f 100755 --- a/services/integration.sh +++ b/services/integration.sh @@ -87,7 +87,7 @@ check_prerequisites run brig "" ${green} run galley "" ${yellow} -run gundeck "" ${blue} Info +run gundeck "" ${blue} run cannon "" ${orange} run cannon "2" ${orange} run cargohold "" ${purpleish} Info diff --git a/services/spar/package.yaml b/services/spar/package.yaml index d02e11e46c9..c3936bfe898 100644 --- a/services/spar/package.yaml +++ b/services/spar/package.yaml @@ -33,12 +33,15 @@ dependencies: - cookie - cryptonite - data-default + - email-validate - errors - exceptions # (for MonadClient, which in turn needs MonadCatch) - extra - galley-types - ghc-prim + - hscim - HsOpenSSL + - http-api-data - http-client - http-client-tls - http-types @@ -66,6 +69,7 @@ dependencies: - tinylog - transformers - types-common + - unordered-containers - uri-bytestring - uuid - wai @@ -75,9 +79,6 @@ dependencies: - x509 - xml-conduit - yaml - - hscim - - email-validate - - http-api-data library: source-dirs: diff --git a/services/spar/spar.integration.yaml b/services/spar/spar.integration.yaml index d6b8de5fdfc..fe60f6e27ba 100644 --- a/services/spar/spar.integration.yaml +++ b/services/spar/spar.integration.yaml @@ -35,5 +35,6 @@ maxttlAuthreq: 5 # seconds. don't set this too large, it is also the run time maxttlAuthresp: 7200 # seconds. do not set this to 1h or less, as that is what the mock idp wants. maxScimTokens: 2 +richInfoLimit: 5000 # should be in sync with Brig logNetStrings: False # log using netstrings encoding (see http://cr.yp.to/proto/netstrings.txt) diff --git a/services/spar/src/Spar/Data.hs b/services/spar/src/Spar/Data.hs index 5e579883e5a..1961d99bafe 100644 --- a/services/spar/src/Spar/Data.hs +++ b/services/spar/src/Spar/Data.hs @@ -49,6 +49,7 @@ import Data.X509 (SignedCertificate) import GHC.TypeLits (KnownSymbol) import Spar.Data.Instances (VerdictFormatRow, VerdictFormatCon, fromVerdictFormat, toVerdictFormat) import Spar.Types +import Spar.Scim.Types import URI.ByteString import qualified Data.List.NonEmpty as NL @@ -476,29 +477,31 @@ deleteTeamScimTokens team = do -- in a separate column otherwise, allowing for fast version filtering on the database. insertScimUser :: (HasCallStack, MonadClient m) - => UserId -> ScimC.User.StoredUser -> m () + => UserId -> ScimC.User.StoredUser ScimUserExtra -> m () insertScimUser uid usr = retry x5 . write ins $ params Quorum (uid, usr) where - ins :: PrepQuery W (UserId, ScimC.User.StoredUser) () + ins :: PrepQuery W (UserId, ScimC.User.StoredUser ScimUserExtra) () ins = "INSERT INTO scim_user (id, json) VALUES (?, ?)" getScimUser :: (HasCallStack, MonadClient m) - => UserId -> m (Maybe ScimC.User.StoredUser) + => UserId -> m (Maybe (ScimC.User.StoredUser ScimUserExtra)) getScimUser uid = runIdentity <$$> (retry x1 . query1 sel $ params Quorum (Identity uid)) where - sel :: PrepQuery R (Identity UserId) (Identity ScimC.User.StoredUser) + sel :: PrepQuery R (Identity UserId) + (Identity (ScimC.User.StoredUser ScimUserExtra)) sel = "SELECT json FROM scim_user WHERE id = ?" -- | Return all users that can be found under a given list of 'UserId's. If some cannot be found, -- the output list will just be shorter (no errors). getScimUsers :: (HasCallStack, MonadClient m) - => [UserId] -> m [ScimC.User.StoredUser] + => [UserId] -> m [ScimC.User.StoredUser ScimUserExtra] getScimUsers uids = runIdentity <$$> retry x1 (query sel (params Quorum (Identity uids))) where - sel :: PrepQuery R (Identity [UserId]) (Identity ScimC.User.StoredUser) + sel :: PrepQuery R (Identity [UserId]) + (Identity (ScimC.User.StoredUser ScimUserExtra)) sel = "SELECT json FROM scim_user WHERE id in ?" diff --git a/services/spar/src/Spar/Data/Instances.hs b/services/spar/src/Spar/Data/Instances.hs index db72573f120..962f2bc22af 100644 --- a/services/spar/src/Spar/Data/Instances.hs +++ b/services/spar/src/Spar/Data/Instances.hs @@ -16,6 +16,7 @@ module Spar.Data.Instances import Imports import Cassandra as Cas +import Data.Aeson (FromJSON, ToJSON) import Data.String.Conversions import Data.X509 (SignedCertificate) import SAML2.Util (parseURI') @@ -85,7 +86,7 @@ toVerdictFormat (VerdictFormatConMobile, Just succredir, Just errredir) = Just $ toVerdictFormat _ = Nothing deriving instance Cql ScimToken -instance Cql Scim.StoredUser where +instance (FromJSON extra, ToJSON extra) => Cql (Scim.StoredUser extra) where ctype = Tagged BlobColumn toCql = CqlBlob . Aeson.encode diff --git a/services/spar/src/Spar/Intra/Brig.hs b/services/spar/src/Spar/Intra/Brig.hs index 5b875774bde..d4b5b790060 100644 --- a/services/spar/src/Spar/Intra/Brig.hs +++ b/services/spar/src/Spar/Intra/Brig.hs @@ -212,6 +212,21 @@ setManagedBy buid managedBy = do | otherwise -> throwSpar . SparBrigError . cs $ "set managedBy failed with status " <> show (statusCode resp) +-- | Set user's richInfo. Fails with status <500 if brig fails with <500, and with 500 if +-- brig fails with >= 500. +setRichInfo :: (HasCallStack, MonadSparToBrig m) => UserId -> RichInfo -> m () +setRichInfo buid richInfo = do + resp <- call + $ method PUT + . paths ["i", "users", toByteString' buid, "rich-info"] + . json (RichInfoUpdate richInfo) + if | statusCode resp < 300 + -> pure () + | inRange (400, 499) (statusCode resp) + -> throwSpar . SparBrigErrorWith (responseStatus resp) $ "set richInfo failed" + | otherwise + -> throwSpar . SparBrigError . cs $ "set richInfo failed with status " <> show (statusCode resp) + -- | This works under the assumption that the user must exist on brig. If it does not, brig -- responds with 404 and this function returns 'False'. bindUser :: (HasCallStack, MonadSparToBrig m) => UserId -> SAML.UserRef -> m Bool diff --git a/services/spar/src/Spar/Scim.hs b/services/spar/src/Spar/Scim.hs index b19a05be56c..d5a04fbfb5a 100644 --- a/services/spar/src/Spar/Scim.hs +++ b/services/spar/src/Spar/Scim.hs @@ -80,7 +80,7 @@ apiScim :: ServerT APIScim Spar apiScim = hoistScim (toServant (Scim.siteServer configuration)) :<|> apiScimToken where - hoistScim = hoistServer (Proxy @(Scim.SiteAPI ScimToken)) + hoistScim = hoistServer (Proxy @(Scim.SiteAPI ScimToken ScimUserExtra)) (Scim.fromScimHandler fromError) fromError = throwError . SAML.CustomServant . Scim.scimToServantErr diff --git a/services/spar/src/Spar/Scim/Types.hs b/services/spar/src/Spar/Scim/Types.hs index 3652c7e74c6..ce2598c8e54 100644 --- a/services/spar/src/Spar/Scim/Types.hs +++ b/services/spar/src/Spar/Scim/Types.hs @@ -5,7 +5,6 @@ {-# LANGUAGE InstanceSigs #-} {-# LANGUAGE LambdaCase #-} {-# LANGUAGE NamedFieldPuns #-} -{-# LANGUAGE OverloadedLists #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE PackageImports #-} {-# LANGUAGE RecordWildCards #-} @@ -18,6 +17,7 @@ -- | This module contains several categories of SCIM-related types: -- +-- * Extensions for @hscim@ types (like 'ScimUserExtra'). -- * Our wrappers over @hscim@ types (like 'ValidScimUser'). -- * Servant-based API types. -- * Request and response types for SCIM-related endpoints. @@ -27,23 +27,83 @@ import Imports import Brig.Types.User as Brig import Control.Lens hiding ((.=), Strict) import Data.Aeson as Aeson +import Data.Aeson.Types as Aeson import Data.Id import Servant import Spar.API.Util import Spar.Types -import qualified SAML2.WebSSO as SAML +import qualified Data.HashMap.Strict as HM +import qualified Data.Text as T +import qualified SAML2.WebSSO as SAML import qualified Web.Scim.Schema.User as Scim.User +import qualified Web.Scim.Schema.Schema as Scim import qualified Web.Scim.Server as Scim +---------------------------------------------------------------------------- +-- Schemas + +userSchemas :: [Scim.Schema] +userSchemas = [Scim.User20, Scim.CustomSchema userExtraURN] + +-- | Schema identifier for extra Wire data. +userExtraURN :: Text +userExtraURN = "urn:wire:scim:schemas:profile:1.0" + +---------------------------------------------------------------------------- +-- @hscim@ extensions and wrappers + +-- | Extra Wire-specific data contained in a SCIM user profile. +data ScimUserExtra = ScimUserExtra + { _sueRichInfo :: RichInfo + } + deriving (Eq, Show) + +makeLenses ''ScimUserExtra + +instance FromJSON ScimUserExtra where + parseJSON = withObject "ScimUserExtra" $ \(lowercase -> o) -> do + o .:? T.toLower userExtraURN >>= \case + Nothing -> pure (ScimUserExtra emptyRichInfo) + Just (lowercase -> o2) -> do + _sueRichInfo <- parseRichInfo =<< o2 .: "richinfo" + pure ScimUserExtra{..} + where + lowercase = HM.fromList . map (over _1 T.toLower) . HM.toList + +instance ToJSON ScimUserExtra where + toJSON v = object + [ userExtraURN .= object + [ "richInfo" .= _sueRichInfo v + ] + ] + +-- | Parse 'RichInfo', trying several formats in a row. We have to know how to parse different +-- formats, because not all provisioning agents can send us information in the canonical +-- @ToJSON RichInfo@ format. +-- +-- FUTUREWORK: allow more formats. In particular, something needs to be figured out for Okta, +-- which can not send objects or lists of objects (as of Feb 26, 2019). +parseRichInfo :: Aeson.Value -> Aeson.Parser RichInfo +parseRichInfo v = + normalizeRichInfo <$> + asum [ + -- Canonical format + parseJSON @RichInfo v + -- A list of {type, value} 'RichField's + , parseJSON @[RichField] v <&> \xs -> RichInfo { richInfoFields = xs } + -- Otherwise we fail + , fail "couldn't parse RichInfo" + ] + -- | SCIM user with 'SAML.UserRef' and mapping to 'Brig.User'. Constructed by 'validateScimUser'. -- -- Data contained in '_vsuHandle' and '_vsuName' is guaranteed to a) correspond to the data in -- the 'Scim.User.User' and b) be valid in regard to our own user schema requirements (only -- certain characters allowed in handles, etc). data ValidScimUser = ValidScimUser - { _vsuUser :: Scim.User.User + { _vsuUser :: Scim.User.User ScimUserExtra -- SAML SSO , _vsuSAMLUserRef :: SAML.UserRef @@ -53,6 +113,7 @@ data ValidScimUser = ValidScimUser -- mapping to 'Brig.User' , _vsuHandle :: Handle , _vsuName :: Maybe Name + , _vsuRichInfo :: RichInfo } deriving (Eq, Show) @@ -119,7 +180,7 @@ instance ToJSON ScimTokenList where -- Servant APIs type APIScim - = OmitDocs :> "v2" :> Scim.SiteAPI ScimToken + = OmitDocs :> "v2" :> Scim.SiteAPI ScimToken ScimUserExtra :<|> "auth-tokens" :> APIScimToken type APIScimToken diff --git a/services/spar/src/Spar/Scim/User.hs b/services/spar/src/Spar/Scim/User.hs index b70fcd241e4..9cec8927499 100644 --- a/services/spar/src/Spar/Scim/User.hs +++ b/services/spar/src/Spar/Scim/User.hs @@ -61,16 +61,18 @@ import qualified Web.Scim.Schema.User as Scim -- UserDB instance instance Scim.UserDB Spar where + type UserExtra Spar = ScimUserExtra + -- | List all users, possibly filtered by some predicate. list :: ScimTokenInfo -> Maybe Scim.Filter - -> Scim.ScimHandler Spar (Scim.ListResponse Scim.StoredUser) + -> Scim.ScimHandler Spar (Scim.ListResponse (Scim.StoredUser ScimUserExtra)) list ScimTokenInfo{stiTeam} mbFilter = do members <- lift $ getTeamMembers stiTeam brigusers :: [User] <- filter (not . userDeleted) <$> lift (Intra.Brig.getUsers ((^. Galley.userId) <$> members)) - scimusers :: [Scim.StoredUser] + scimusers :: [Scim.StoredUser ScimUserExtra] <- lift . wrapMonadClient . Data.getScimUsers $ Brig.userId <$> brigusers let check user = case mbFilter of Nothing -> pure True @@ -86,7 +88,7 @@ instance Scim.UserDB Spar where -- | Get a single user by its ID. get :: ScimTokenInfo -> Text - -> Scim.ScimHandler Spar (Maybe Scim.StoredUser) + -> Scim.ScimHandler Spar (Maybe (Scim.StoredUser ScimUserExtra)) get ScimTokenInfo{stiTeam} uidText = do uid <- parseUid uidText mbBrigUser <- lift (Intra.Brig.getUser uid) @@ -96,15 +98,15 @@ instance Scim.UserDB Spar where -- | Create a new user. create :: ScimTokenInfo - -> Scim.User - -> Scim.ScimHandler Spar Scim.StoredUser + -> Scim.User ScimUserExtra + -> Scim.ScimHandler Spar (Scim.StoredUser ScimUserExtra) create tokinfo user = createValidScimUser =<< validateScimUser tokinfo user update :: ScimTokenInfo -> Text - -> Scim.User - -> Scim.ScimHandler Spar Scim.StoredUser + -> Scim.User ScimUserExtra + -> Scim.ScimHandler Spar (Scim.StoredUser ScimUserExtra) update tokinfo uidText newScimUser = updateValidScimUser tokinfo uidText =<< validateScimUser tokinfo newScimUser @@ -131,7 +133,7 @@ instance Scim.UserDB Spar where validateScimUser :: forall m. (m ~ Scim.ScimHandler Spar) => ScimTokenInfo -- ^ Used to decide what IdP to assign the user to - -> Scim.User + -> Scim.User ScimUserExtra -> m ValidScimUser validateScimUser ScimTokenInfo{stiIdP} user = do idp <- case stiIdP of @@ -141,7 +143,8 @@ validateScimUser ScimTokenInfo{stiIdP} user = do Nothing -> throwError $ Scim.serverError "The IdP configured for this provisioning token not found" Just idpConfig -> pure idpConfig - validateScimUser' idp user + richInfoLimit <- lift $ asks (richInfoLimit . sparCtxOpts) + validateScimUser' idp richInfoLimit user -- | Map the SCIM data on the spar and brig schemata, and throw errors if the SCIM data does -- not comply with the standard / our constraints. See also: 'ValidScimUser'. @@ -170,9 +173,10 @@ validateScimUser ScimTokenInfo{stiIdP} user = do validateScimUser' :: forall m. (MonadError Scim.ScimError m) => IdP -- ^ IdP that the resulting user will be assigned to - -> Scim.User + -> Int -- ^ Rich info limit + -> Scim.User ScimUserExtra -> m ValidScimUser -validateScimUser' idp user = do +validateScimUser' idp richInfoLimit user = do uref :: SAML.UserRef <- case Scim.externalId user of Just subjectTxt -> do let issuer = idp ^. SAML.idpMetadata . SAML.edIssuer @@ -182,7 +186,8 @@ validateScimUser' idp user = do (Just "externalId is required for SAML users") handl <- validateHandle (Scim.userName user) mbName <- mapM validateName (Scim.displayName user) - pure $ ValidScimUser user uref handl mbName + richInfo <- validateRichInfo (Scim.extra user ^. sueRichInfo) + pure $ ValidScimUser user uref handl mbName richInfo where -- Validate a subject ID (@externalId@). @@ -217,13 +222,25 @@ validateScimUser' idp user = do Left err -> throwError $ Scim.badRequest Scim.InvalidValue (Just ("displayName must be a valid Wire name, but: " <> Text.pack err)) + -- Validate rich info (@richInfo@). It must not exceed the rich info limit. + validateRichInfo :: RichInfo -> m RichInfo + validateRichInfo richInfo = do + let size = richInfoSize richInfo + when (size > richInfoLimit) $ throwError $ + (Scim.badRequest Scim.InvalidValue + (Just . cs $ + "richInfo exceeds the limit: max " <> show richInfoLimit <> + " characters, but got " <> show size)) + { Scim.status = Scim.Status 413 } + pure richInfo + -- | We only allow SCIM users that authenticate via SAML. (This is by no means necessary, -- though. It can be relaxed to allow creating users with password authentication if that is a -- requirement.) createValidScimUser :: forall m. (m ~ Scim.ScimHandler Spar) - => ValidScimUser -> m Scim.StoredUser -createValidScimUser (ValidScimUser user uref handl mbName) = do + => ValidScimUser -> m (Scim.StoredUser ScimUserExtra) +createValidScimUser (ValidScimUser user uref handl mbName richInfo) = do -- FUTUREWORK: The @hscim@ library checks that the handle is not taken before 'create' is -- even called. However, it does that in an inefficient manner. We should remove the check -- from @hscim@ and do it here instead. @@ -237,10 +254,17 @@ createValidScimUser (ValidScimUser user uref handl mbName) = do storedUser <- lift $ toScimStoredUser buid user lift . wrapMonadClient $ Data.insertScimUser buid storedUser -- Create SAML user here in spar, which in turn creates a brig user. + -- + -- FUTUREWORK: it's annoying that we have duplicate checks (handles, rich info, etc are + -- validated both by Spar and by Brig), and we should somehow get rid of them. We could do + -- that by switching the order of 'createUser_' and 'insertScimUser', but then if Spar + -- crashes after 'insertScimUser', we would never finish creating that user. lift $ createUser_ buid uref mbName ManagedByScim -- Set user handle on brig (which can't be done during user creation yet). -- TODO: handle errors better here? lift $ Intra.Brig.setHandle buid handl + -- Set rich info on brig + lift $ Intra.Brig.setRichInfo buid richInfo pure storedUser @@ -249,7 +273,7 @@ createValidScimUser (ValidScimUser user uref handl mbName) = do updateValidScimUser :: forall m. (m ~ Scim.ScimHandler Spar) - => ScimTokenInfo -> Text -> ValidScimUser -> m Scim.StoredUser + => ScimTokenInfo -> Text -> ValidScimUser -> m (Scim.StoredUser ScimUserExtra) updateValidScimUser tokinfo uidText newScimUser = do -- TODO: currently the types in @hscim@ are constructed in such a way that @@ -265,14 +289,14 @@ updateValidScimUser tokinfo uidText newScimUser = do -- construct old and new user values with metadata. uid :: UserId <- parseUid uidText - oldScimStoredUser :: Scim.StoredUser + oldScimStoredUser :: Scim.StoredUser ScimUserExtra <- let err = throwError $ Scim.notFound "user" uidText in maybe err pure =<< Scim.get tokinfo uidText if Scim.value (Scim.thing oldScimStoredUser) == (newScimUser ^. vsuUser) then pure oldScimStoredUser else do - newScimStoredUser :: Scim.StoredUser + newScimStoredUser :: Scim.StoredUser ScimUserExtra <- lift $ updScimStoredUser (newScimUser ^. vsuUser) oldScimStoredUser -- update 'SAML.UserRef' @@ -286,6 +310,7 @@ updateValidScimUser tokinfo uidText newScimUser = do maybe (pure ()) (lift . Intra.Brig.setName uid) $ newScimUser ^. vsuName lift . Intra.Brig.setHandle uid $ newScimUser ^. vsuHandle + lift . Intra.Brig.setRichInfo uid $ newScimUser ^. vsuRichInfo -- store new user value to scim_user table (spar). (this must happen last, so in case -- of crash the client can repeat the operation and it won't be considered a noop.) @@ -296,7 +321,7 @@ updateValidScimUser tokinfo uidText newScimUser = do toScimStoredUser :: forall m. (SAML.HasNow m, MonadReader Env m) - => UserId -> Scim.User -> m Scim.StoredUser + => UserId -> Scim.User ScimUserExtra -> m (Scim.StoredUser ScimUserExtra) toScimStoredUser uid usr = do now <- SAML.getNow baseuri <- asks $ derivedOptsScimBaseURI . derivedOpts . sparCtxOpts @@ -304,7 +329,11 @@ toScimStoredUser uid usr = do toScimStoredUser' :: HasCallStack - => SAML.Time -> URIBS.URI -> UserId -> Scim.User -> Scim.StoredUser + => SAML.Time + -> URIBS.URI + -> UserId + -> Scim.User ScimUserExtra + -> Scim.StoredUser ScimUserExtra toScimStoredUser' (SAML.Time now) baseuri (idToText -> uid) usr = Scim.WithMeta meta (Scim.WithId uid usr) where @@ -326,16 +355,18 @@ toScimStoredUser' (SAML.Time now) baseuri (idToText -> uid) usr = updScimStoredUser :: forall m. (SAML.HasNow m) - => Scim.User -> Scim.StoredUser -> m Scim.StoredUser + => Scim.User ScimUserExtra + -> Scim.StoredUser ScimUserExtra + -> m (Scim.StoredUser ScimUserExtra) updScimStoredUser usr storedusr = do now <- SAML.getNow pure $ updScimStoredUser' now usr storedusr updScimStoredUser' :: SAML.Time - -> Scim.User - -> Scim.StoredUser - -> Scim.StoredUser + -> Scim.User ScimUserExtra + -> Scim.StoredUser ScimUserExtra + -> Scim.StoredUser ScimUserExtra updScimStoredUser' (SAML.Time moddate) usr (Scim.WithMeta meta (Scim.WithId scimuid _)) = Scim.WithMeta meta' (Scim.WithId scimuid usr) where @@ -365,7 +396,7 @@ parseUid uidText = maybe err pure $ readMaybe (Text.unpack uidText) -- requirements of strong ETags ("same resources have the same version"). calculateVersion :: Text -- ^ User ID - -> Scim.User + -> Scim.User ScimUserExtra -> Scim.ETag calculateVersion uidText usr = Scim.Weak (Text.pack (show h)) where diff --git a/services/spar/src/Spar/Types.hs b/services/spar/src/Spar/Types.hs index 2700519cb47..4c7617eec94 100644 --- a/services/spar/src/Spar/Types.hs +++ b/services/spar/src/Spar/Types.hs @@ -155,6 +155,8 @@ data Opts' a = Opts , maxttlAuthresp :: !(TTL "authresp") -- | The maximum number of SCIM tokens that we will allow teams to have. , maxScimTokens :: !Int + -- | The maximum size of rich info. Should be in sync with 'Brig.Types.richInfoLimit'. + , richInfoLimit :: !Int -- | Wire/AWS specific; optional; used to discover Cassandra instance -- IPs using describe-instances. , discoUrl :: !(Maybe Text) diff --git a/services/spar/test-integration/Test/Spar/APISpec.hs b/services/spar/test-integration/Test/Spar/APISpec.hs index da0b28e1802..6724d114a49 100644 --- a/services/spar/test-integration/Test/Spar/APISpec.hs +++ b/services/spar/test-integration/Test/Spar/APISpec.hs @@ -26,7 +26,6 @@ import qualified Galley.Types.Teams as Galley import qualified Spar.Intra.Brig as Intra import qualified Util.Scim as ScimT import qualified Web.Cookie as Cky -import qualified Web.Scim.Class.User as Scim spec :: SpecWith TestEnv @@ -665,7 +664,7 @@ specScimAndSAML = do -- create a user via scim (tok, (_, _, idp)) <- ScimT.registerIdPAndScimToken (usr, subj) <- ScimT.randomScimUserWithSubject - scimStoredUser :: Scim.StoredUser <- ScimT.createUser tok usr + scimStoredUser <- ScimT.createUser tok usr let userid :: UserId = ScimT.scimUserId scimStoredUser userref :: UserRef = UserRef tenant subject tenant :: Issuer = idp ^. idpMetadata . edIssuer diff --git a/services/spar/test-integration/Test/Spar/Scim/UserSpec.hs b/services/spar/test-integration/Test/Spar/Scim/UserSpec.hs index 1c658471036..b11361faa86 100644 --- a/services/spar/test-integration/Test/Spar/Scim/UserSpec.hs +++ b/services/spar/test-integration/Test/Spar/Scim/UserSpec.hs @@ -10,16 +10,17 @@ import Bilge.Assert import Brig.Types.User as Brig import Control.Lens import Data.ByteString.Conversion +import Data.Id (UserId) import Data.Ix (inRange) import Spar.Scim import Util import qualified Spar.Data as Data +import qualified Web.Scim.Class.User as Scim.UserC import qualified Web.Scim.Schema.Common as Scim import qualified Web.Scim.Schema.Meta as Scim import qualified Web.Scim.Schema.User as Scim.User - -- | Tests for @\/scim\/v2\/Users@. spec :: SpecWith TestEnv spec = do @@ -50,6 +51,7 @@ specCreateUser = describe "POST /Users" $ do it "allows an occupied externalId when the IdP is different" $ testCreateSameExternalIds it "provides a correct location in the 'meta' field" $ testLocation + it "handles rich info correctly (this also tests put, get)" $ testRichInfo it "gives created user a valid 'SAML.UserRef' for SSO" $ pending it "attributes of {brig, scim, saml} user are mapped as documented" $ pending it "writes all the stuff to all the places" $ @@ -162,6 +164,58 @@ testLocation = do r <- call (get (const req)) Scim.UserC.StoredUser ScimUserExtra -> RichInfo -> TestSpar () + checkStoredUser storedUser rinf = liftIO $ do + (Scim.User.extra . Scim.value . Scim.thing) storedUser + `shouldBe` (ScimUserExtra rinf) + + -- validate server state after the fact + probeUser + :: HasCallStack + => UserId -> RichInfo -> TestSpar () + probeUser uid rinf = do + -- get scim user yields correct rich info. + scimStoredUser' <- getUser tok uid + checkStoredUser scimStoredUser' rinf + + -- get rich info end-point on brig yields correct rich info. + resp <- call $ get ( brig + . paths ["users", toByteString' uid, "rich-info"] + . zUser owner + ) + liftIO $ do + statusCode resp `shouldBe` 200 + decodeBody resp `shouldBe` Right rinf + + -- post response contains correct rich info. + scimStoredUser <- createUser tok user + checkStoredUser scimStoredUser richInfo + + -- post updates the backend as expected. + probeUser (scimUserId scimStoredUser) richInfo + + -- put response contains correct rich info. + scimStoredUser' <- updateUser tok (scimUserId scimStoredUser) user' + checkStoredUser scimStoredUser' richInfo' + + -- post updates the backend as expected. + liftIO $ scimUserId scimStoredUser' `shouldBe` scimUserId scimStoredUser + probeUser (scimUserId scimStoredUser) richInfo' + ---------------------------------------------------------------------------- -- Listing users @@ -406,7 +460,8 @@ testUpdateUserRefIndex = do -- Overwrite the user with another randomly-generated user user' <- randomScimUser _ <- updateUser tok userid user' - vuser' <- either (error . show) pure $ validateScimUser' idp user' + vuser' <- either (error . show) pure $ + validateScimUser' idp 999999 user' -- 999999 = some big number muserid' <- runSparCass $ Data.getUser (vuser' ^. vsuSAMLUserRef) liftIO $ do muserid' `shouldBe` Just userid @@ -420,7 +475,8 @@ testBrigSideIsUpdated = do user' <- randomScimUser let userid = scimUserId storedUser _ <- updateUser tok userid user' - validScimUser <- either (error . show) pure $ validateScimUser' idp user' + validScimUser <- either (error . show) pure $ + validateScimUser' idp 999999 user' brigUser <- maybe (error "no brig user") pure =<< getSelf userid brigUser `userShouldMatch` validScimUser diff --git a/services/spar/test-integration/Util/Scim.hs b/services/spar/test-integration/Util/Scim.hs index 13fcb352a03..c3ec8a19ffa 100644 --- a/services/spar/test-integration/Util/Scim.hs +++ b/services/spar/test-integration/Util/Scim.hs @@ -69,16 +69,27 @@ registerScimToken teamid midpid = do -- -- FUTUREWORK: make this more exhaustive. change everything that can be changed! move this to the -- hspec package when done. -randomScimUser :: MonadRandom m => m Scim.User.User +randomScimUser :: MonadRandom m => m (Scim.User.User ScimUserExtra) randomScimUser = fst <$> randomScimUserWithSubject -- | Like 'randomScimUser', but also returns the intended subject ID that the user should -- have. It's already available as 'Scim.User.externalId' but it's not structured. randomScimUserWithSubject - :: (HasCallStack, MonadRandom m) - => m (Scim.User.User, SAML.UnqualifiedNameID) + :: (HasCallStack, MonadRandom m) + => m (Scim.User.User ScimUserExtra, SAML.UnqualifiedNameID) randomScimUserWithSubject = do - suffix <- cs <$> replicateM 5 (getRandomR ('0', '9')) + fieldCount <- getRandomR (0, 3) + fields <- replicateM fieldCount $ + RichField <$> (cs <$> replicateM 10 (getRandomR ('A', 'z'))) + <*> (cs <$> replicateM 3 (getRandomR ('A', 'z'))) + randomScimUserWithSubjectAndRichInfo (RichInfo fields) + +-- | See 'randomScimUser', 'randomScimUserWithSubject'. +randomScimUserWithSubjectAndRichInfo + :: MonadRandom m + => RichInfo -> m (Scim.User.User ScimUserExtra, SAML.UnqualifiedNameID) +randomScimUserWithSubjectAndRichInfo richInfo = do + suffix <- cs <$> replicateM 7 (getRandomR ('0', '9')) emails <- getRandomR (0, 3) >>= \n -> replicateM n randomScimEmail phones <- getRandomR (0, 3) >>= \n -> replicateM n randomScimPhone -- Related, but non-trivial to re-use here: 'nextSubject' @@ -91,7 +102,7 @@ randomScimUserWithSubject = do , SAML.mkUNameIDUnspecified ("scimuser_extid_" <> suffix) ) _ -> error "randomScimUserWithSubject: impossible" - pure ( Scim.User.empty + pure ( (Scim.User.empty userSchemas (ScimUserExtra richInfo)) { Scim.User.userName = "scimuser_" <> suffix , Scim.User.displayName = Just ("Scim User #" <> suffix) , Scim.User.externalId = Just externalId @@ -129,8 +140,8 @@ randomScimPhone = do createUser :: HasCallStack => ScimToken - -> Scim.User.User - -> TestSpar Scim.StoredUser + -> Scim.User.User ScimUserExtra + -> TestSpar (Scim.StoredUser ScimUserExtra) createUser tok user = do env <- ask r <- createUser_ @@ -145,8 +156,8 @@ updateUser :: HasCallStack => ScimToken -> UserId - -> Scim.User.User - -> TestSpar Scim.StoredUser + -> Scim.User.User ScimUserExtra + -> TestSpar (Scim.StoredUser ScimUserExtra) updateUser tok userid user = do env <- ask r <- updateUser_ @@ -162,7 +173,7 @@ deleteUser :: HasCallStack => ScimToken -> UserId - -> TestSpar Scim.StoredUser + -> TestSpar (Scim.StoredUser ScimUserExtra) deleteUser tok userid = do env <- ask r <- deleteUser_ @@ -177,7 +188,7 @@ listUsers :: HasCallStack => ScimToken -> Maybe Scim.Filter - -> TestSpar [Scim.StoredUser] + -> TestSpar [(Scim.StoredUser ScimUserExtra)] listUsers tok mbFilter = do env <- ask r <- listUsers_ @@ -196,7 +207,7 @@ getUser :: HasCallStack => ScimToken -> UserId - -> TestSpar Scim.StoredUser + -> TestSpar (Scim.StoredUser ScimUserExtra) getUser tok userid = do env <- ask r <- getUser_ @@ -253,9 +264,9 @@ listTokens zusr = do -- | Create a user. createUser_ - :: Maybe ScimToken -- ^ Authentication - -> Scim.User.User -- ^ User data - -> SparReq -- ^ Spar endpoint + :: Maybe ScimToken -- ^ Authentication + -> Scim.User.User ScimUserExtra -- ^ User data + -> SparReq -- ^ Spar endpoint -> TestSpar ResponseLBS createUser_ auth user spar_ = do -- NB: we don't use 'mkEmailRandomLocalSuffix' here, because emails @@ -276,10 +287,11 @@ createUser_ auth user spar_ = do -- | Update a user. updateUser_ - :: Maybe ScimToken -- ^ Authentication - -> Maybe UserId -- ^ User to update; when not provided, the request will return 4xx - -> Scim.User.User -- ^ User data - -> SparReq -- ^ Spar endpoint + :: Maybe ScimToken -- ^ Authentication + -> Maybe UserId -- ^ User to update; when not provided, the request will + -- return 4xx + -> Scim.User.User ScimUserExtra -- ^ User data + -> SparReq -- ^ Spar endpoint -> TestSpar ResponseLBS updateUser_ auth muid user spar_ = do call . put $ @@ -394,7 +406,7 @@ acceptScim :: Request -> Request acceptScim = accept "application/scim+json" -- | Get ID of a user returned from SCIM. -scimUserId :: Scim.StoredUser -> UserId +scimUserId :: Scim.StoredUser ScimUserExtra -> UserId scimUserId storedUser = either err id (readEither id_) where id_ = cs (Scim.id (Scim.thing storedUser)) @@ -409,6 +421,9 @@ scimUserId storedUser = either err id (readEither id_) -- In cases like 'maybeUserId' the accessor returns a raw value, because a user always has a -- 'UserId'. In cases like 'maybeHandle' the accessor returns a 'Maybe', because a user may or -- may not have a handle. +-- +-- Note: we don't compare rich info here, because 'User' doesn't contain it. However, we have +-- separate tests for rich info that cover that. class IsUser u where maybeUserId :: Maybe (u -> UserId) maybeHandle :: Maybe (u -> Maybe Handle) @@ -431,7 +446,7 @@ instance IsUser ValidScimUser where maybeSubject = Just (Just . view (vsuSAMLUserRef . SAML.uidSubject)) maybeSubjectRaw = Just (SAML.shortShowNameID . view (vsuSAMLUserRef . SAML.uidSubject)) -instance IsUser Scim.StoredUser where +instance IsUser (Scim.StoredUser ScimUserExtra) where maybeUserId = Just scimUserId maybeHandle = maybeHandle <&> \f -> f . Scim.value . Scim.thing maybeName = maybeName <&> \f -> f . Scim.value . Scim.thing @@ -439,7 +454,7 @@ instance IsUser Scim.StoredUser where maybeSubject = maybeSubject <&> \f -> f . Scim.value . Scim.thing maybeSubjectRaw = maybeSubjectRaw <&> \f -> f . Scim.value . Scim.thing -instance IsUser Scim.User.User where +instance IsUser (Scim.User.User ScimUserExtra) where maybeUserId = Nothing maybeHandle = Just (Just . Handle . Scim.User.userName) maybeName = Just (fmap Name . Scim.User.displayName) diff --git a/services/spar/test/Test/Spar/ScimSpec.hs b/services/spar/test/Test/Spar/ScimSpec.hs index 1c6f6f53188..cc6de1c761b 100644 --- a/services/spar/test/Test/Spar/ScimSpec.hs +++ b/services/spar/test/Test/Spar/ScimSpec.hs @@ -11,6 +11,7 @@ module Test.Spar.ScimSpec where import Imports +import Brig.Types.User (emptyRichInfo) import Data.Id import Network.URI (parseURI) import Spar.Scim @@ -22,6 +23,7 @@ import qualified SAML2.WebSSO as SAML import qualified Web.Scim.Class.User as ScimC import qualified Web.Scim.Schema.Common as Scim import qualified Web.Scim.Schema.Meta as Scim +import qualified Web.Scim.Schema.Schema as Scim import qualified Web.Scim.Schema.ResourceType as ScimR import qualified Web.Scim.Schema.User as Scim import qualified Web.Scim.Schema.User.Name as ScimN @@ -30,9 +32,11 @@ import qualified Web.Scim.Schema.User.Name as ScimN spec :: Spec spec = describe "toScimStoredUser'" $ do it "works" $ do - let usr :: Scim.User + let usr :: Scim.User ScimUserExtra usr = Scim.User - { Scim.userName = "02b35298-088f-11e9-b4a4-478635dd0d2b" + { Scim.schemas = [Scim.User20, + Scim.CustomSchema "urn:wire:scim:schemas:profile:1.0"] + , Scim.userName = "02b35298-088f-11e9-b4a4-478635dd0d2b" , Scim.externalId = Just "c1704a48-0a1e-11e9-9186-9b185fe892e8" , Scim.name = Just (ScimN.Name { ScimN.formatted = Nothing , ScimN.familyName = Just "" @@ -58,6 +62,7 @@ spec = describe "toScimStoredUser'" $ do , Scim.entitlements = [] , Scim.roles = [] , Scim.x509Certificates = [] + , Scim.extra = ScimUserExtra emptyRichInfo } meta :: Scim.Meta @@ -65,7 +70,7 @@ spec = describe "toScimStoredUser'" $ do { Scim.resourceType = ScimR.UserResource , Scim.created = now , Scim.lastModified = now - , Scim.version = Scim.Weak "e5442c575adce7a7affbb2f744ab0825c553c9e6ce5dafdee8789364d824614e" + , Scim.version = Scim.Weak "cd79ccdd2cff3eeb01bce976f586b086547325907e0a3a7303ecaa61a04635da" , Scim.location = Scim.URI . fromJust $ Network.URI.parseURI "https://127.0.0.1/scim/v2/Users/90b5ee1c-088e-11e9-9a16-73f80f483813" } @@ -75,7 +80,7 @@ spec = describe "toScimStoredUser'" $ do URI.ByteString.parseURI laxURIParserOptions "https://127.0.0.1/scim/v2/" uid = Id . fromJust . UUID.fromText $ "90b5ee1c-088e-11e9-9a16-73f80f483813" - result :: ScimC.StoredUser + result :: ScimC.StoredUser ScimUserExtra result = toScimStoredUser' now' baseuri uid usr Scim.meta result `shouldBe` meta diff --git a/stack.yaml b/stack.yaml index d8b487cb561..819a6b79a8c 100644 --- a/stack.yaml +++ b/stack.yaml @@ -40,7 +40,7 @@ extra-deps: - git: https://github.com/wireapp/saml2-web-sso commit: c03d17d656ac467350c983d5f844c199e5daceea # master (Feb 21, 2019) - git: https://github.com/wireapp/hscim - commit: 53db8029e17e7085322e7055f71efb5e7058d4a5 # master (Jan 23, 2019) + commit: 42f6018812bf0f04741231b67b1f5e790ce0d489 # master (Feb 25, 2019) flags: types-common: