Data handling and security

A precise description of how the connection service, the Workforce Intelligence inference service and the account portal handle data, and the protections around them, for security reviewers.

Effective · Last updated

Summary#

We run two products that handle data differently.

  • The connection service passes a person's authorization result from a provider to the installation that asked for it. It keeps nothing beyond a sealed, single-use hand-off record that is accepted for at most 5 minutes. It never reads the content of connected accounts.
  • The Workforce Intelligence inference service and account portal answer an installation's requests for model responses and bill for them. Prompts and responses are processed to produce the response and are never stored. We keep usage records, account details and invoice records, which hold no prompt or response.

This page is for security and compliance reviewers; the Privacy Policy covers the same facts in policy form and the Terms of Service describe the rules for using the products.

Data categories at a glance#

This table covers the Workforce Intelligence inference service and account portal. The connection service is described in the sections that follow.

Data Stored? Where How long Who else sees it
Prompts, instructions, tool definitions, images and files in a request No Memory of the serving task while the request runs Gone when the request ends The model provider(s) that answer it; Amazon Web Services, which hosts the service
Responses No Memory of the serving task while the request runs Gone when the request ends The model provider(s) that produced it
Usage record for each request (identifiers, model names, token counts, amounts, time, status, whether an equivalent model answered) and month totals Yes Ledger table; daily export Not deleted automatically; table history 35 days Amazon Web Services; the account holder (statements); our operators
Email address and password hash Yes Ledger table; daily export Until removed on request Amazon Web Services; our operators (email address)
Sessions (hash of the cookie) Yes Ledger table 1 hour idle, 12 hours at most, then removed by the database Amazon Web Services
Confirmation and reset links Hash only Ledger table Usable once, 24 hours (confirmation) or one hour (reset) Amazon Web Services; the link itself goes to the account's email address
API keys Prefix, hash, name and times only Ledger table; daily export Kept after revocation, marked revoked Amazon Web Services
Billing state (Stripe customer identifier, card on file or not) and invoice records Yes Ledger table; daily export Not deleted automatically Stripe; Amazon Web Services; our operators
Card number No Stripe only Per Stripe Stripe
Spend limit, account change records and operator records Yes Ledger table; daily export Not deleted automatically Amazon Web Services; our operators
Payment event records (type and state) Yes Ledger table 90 days Amazon Web Services
Emails we send No copy kept Delivered through Amazon Simple Email Service Not kept by us Amazon Web Services; the recipient's mail provider
Bug report from an installation with sharing turned on (kind of sender, category, time, version, for an empty model response the provider and model names, stop reason, token counts and trace identifier, and, only when an installation administrator reviewed and approved it, text written by a person, a Coworker or an app: a summary and a detail) Yes Bug-report table 180 days, then removed by the database Amazon Web Services; our operators
Deployment identity of an installation (a public key, the identifier derived from it, the company name the installation sends, when it enrolled, when we last heard from it and whether it is active or revoked) Yes Deployments table Until an operator removes it; table history 35 days Amazon Web Services; our operators
Operational logs Yes Log storage One month Amazon Web Services
Network metadata (address, headers) Sample only Web firewall Three hours Amazon Web Services

The connection flow#

  1. The installation sends the person's browser to the service, naming the provider, a return address, an opaque attempt value, the permissions needed and a one-way challenge (a SHA-256 fingerprint of a secret that stays in the installation).
  2. The service validates every field, then redirects the browser to the provider with a signed state value. The signed state carries the provider, an expiry, a one-time nonce, the challenge, the attempt value and the return address.
  3. The service records the one-time nonce for at most 10 minutes.
  4. The person approves access at the provider, which redirects the browser back to the service with an authorization code.
  5. The service verifies the signed state, takes the nonce (so a replay finds nothing), and exchanges the code for tokens at the provider using the service's own client credentials.
  6. The service seals the result, stores the sealed record under a random 256-bit identifier, and redirects the browser to the installation with only that identifier and the attempt value.
  7. The installation's server presents the identifier and its secret to the service. The service deletes the record, checks the secret against the challenge and returns the result. The browser never sees a code or token.

What is sealed, and for how long#

  • The result is encrypted with AES-GCM before it is stored. The key is held in a managed secrets store and delivered to the running service as a secret, never written into the task definition or the image.
  • The hand-off identifier is bound to the ciphertext as associated data, so a sealed record copied to another identifier does not open.
  • The database holds only the ciphertext, encrypted at rest. The hand-off table has no backups.
  • The sealed result is accepted for at most 5 minutes. The pending-attempt nonce is accepted for at most 10 minutes.
  • The record is deleted on the first attempt to collect it, whether or not that attempt succeeds. A wrong secret burns the record.
  • After 5 minutes (10 for a nonce) a record is rejected on read. The database then removes expired records physically; Amazon Web Services documents that it deletes expired items "typically within a few days after their expiration". Until removal a record remains encrypted.

The inference flow#

  1. The installation sends a request with its API key. The service finds the key by its prefix, verifies the rest against a one-way argon2id hash and may remember a successful check in memory for about a minute, so a revoked key stops working within about a minute.
  2. The service checks the per-key request rate, then whether the account is suspended, whether a card is on file, the spend limit and the pacing level. A refused request gets a plain error and nothing is recorded about its content.
  3. The service chooses the model that answers, using the model name in the request, and opens a request to that provider with our own credentials. The request carries the content and the output limit; it carries no name, email address, account identifier or API key of the customer.
  4. The response is streamed back as it arrives. If the first provider cannot start the response (it is unavailable or overloaded, rejects our credentials, has no usable account with us, or times out), the service tries the next candidate before any part of the response has been sent. That candidate can be the same model through Amazon Bedrock, or it can be an equivalent model of a different provider: a limited number of attempts is made, and the same model through the same provider and credentials is never tried twice. The request is never moved to another provider after the first part of the response has been sent. If a response fails part way, it ends with an error and the usage the provider reported, if any, is billed.
  5. When the request ends, the service writes one usage record and adds to the month totals in a single transaction. The record holds identifiers, model names (including the model that answered when it differs from the one requested), token counts, amounts, time, status, whether an equivalent model answered and the key prefix, in fields that cannot hold free text. No prompt, response or file is written.

Prompts and responses exist only in memory for the length of the request. They are not written to the database, the export, logs or trace data; automated tests check this by sending a distinctive prompt and searching every stored item, log line and trace attribute for it.

Refreshing a connection#

The installation holds both tokens and sends the refresh token to the service. The service adds its client credentials, refreshes at the provider and returns the new tokens in the response. It stores nothing: no record, no nonce, no copy of either token.

Transport security#

  • Every connection to the service uses HTTPS. Plain HTTP requests are redirected to HTTPS at the load balancer.
  • In production the service sends an HTTP Strict Transport Security header with a one-year lifetime that includes subdomains.
  • Responses carry a strict Content Security Policy, a no-sniff header and frame restrictions. Connection routes, inference responses and portal pages are never cached.
  • The portal's session and security cookies are readable only by the server, are marked secure, use the __Host- cookie prefix in production, which ties them to this host, and are sent with a same-site restriction. Portal forms carry a security token tied to the session.

Web firewall#

A web application firewall sits in front of the service:

  • A per-address rate limit of 2,000 requests per five minutes.
  • A separate per-address rate limit of 30,000 requests per five minutes for the inference service, so that long streamed responses cannot trip the stricter limit.
  • AWS managed rule sets: Common, Known Bad Inputs, SQL Injection and Amazon IP Reputation. The Common and SQL Injection sets are not applied to the inference service or to Stripe's payment notifications, because prompts and payment payloads are free-form content; the Known Bad Inputs and IP Reputation sets still apply to them. On the bug-report endpoint alone, the Common set's 8 KB request-body size rule is counted rather than blocking, so that the endpoint can enforce its own 32 KB limit; every other Common rule still applies there.
  • A separate per-address rate limit of 300 requests per five minutes for the bug-report endpoint, which sits outside the inference service's limit and keeps every managed rule set (with the one body-size exception above).
  • A separate per-address rate limit of 120 requests per five minutes for the deployment enrollment endpoint, which also sits outside the inference service's limit and keeps every managed rule set.
  • A country allow-list for the United States, Canada and the member states of the European Union. The connection routes are exempt from the country allow-list, because people and installations that use them can be anywhere; the rate limit and managed rule sets still apply to them. The bug-report endpoint and the deployment enrollment endpoint, each at exactly its own address, are exempt for the same reason, and only from the allow-list. The inference service and the account portal are not exempt.

Bug reports from an installation#

Sharing bug reports is optional. It is off by default in every installation, and an administrator turns it on, and can turn it off, in the installation's settings. We also have to enable the receiving endpoint (POST /v1/bug-reports); while we have not, it answers 404 exactly like an address that does not exist, never a placeholder success.

  1. The installation builds the report by copying a fixed list of fields into a new record. It never edits a stored report down. A value that does not fit its field's strict format is left out rather than sent.
  2. The service reads at most 32,768 bytes. Anything larger is refused with 413, a body that is not a JSON object with 400, and a report with an unknown field, a wrong type or a value outside its format with 422. The answer to a refused report names the fields and the kind of fault, never a submitted value.
  3. A valid report is written to the bug-report table with an expiry 180 days after it arrives, keyed by its identifier, and answered with 202. Sending the same identifier again also gets 202 and adds nothing, so a retry cannot create a second record.
  4. An installation treats any other answer, a timeout or a connection error as a failed send. The report stays in the installation, nothing is lost or blocked, and the installation's administrator sees the outcome there.

By default a report holds no free text, so it cannot hold the content of a conversation, document or file, a name, an email address or a page address. The exception is two optional text fields that an installation's administrator can approve for one report: a description of at most 2,000 characters and a detail of at most 4,000 characters (both checked after Unicode normalization, with control characters other than newline and tab refused). The text is written by a person, a Coworker or an app. The administrator sees exactly what would be sent and may edit it before it is sent, and nothing is sent without that approval. A description is accepted on a report from a person, a Coworker or an app, and a detail only on a report from a Coworker or an app; reports from automatic services stay fixed-field only (a report that includes text where it is not accepted is refused with 422). The detail is plain text and the service never parses it. Because it is whatever was written, the text can contain anything, including personal data or business information. Operators can read it on the bug-report page, which shows it as plain text. It is kept 180 days like the rest of the report, and a person can ask us to delete it sooner by contacting us as described under "Contact" in the privacy notice. The other fields are the report identifier, the time it was filed, the kind of sender (person, coworker, app or service, never a name), a category from a fixed list, the version, and, for an empty model response only, the provider name, the requested and answering model names, the stop reason, token counts and the trace identifier. Each text field is either a fixed list or a strict short pattern. The service logs the category of an accepted report and whether it was a repeat, never any other part of its content, and never a description or a detail. A refused report's answer names the field and the kind of fault only. Automated tests send distinctive values, including a distinctive description and detail, and check that they appear in no response and no log line.

Only operators can read stored reports. The service's access role can add reports, read one by identifier and list a day's reports, and cannot delete from or scan the table.

Deployment identity#

An installation proves who it is to us with a key pair, so that the services that accept calls from installations can tell one installation from another and an operator can stop one that misbehaves. We hold no account, host name, address or other customer data for this. The installation also sends its company name every time it sends its identifier, so that our operators can tell whose installation a request came from; we store it as display-only information.

  1. At first start an installation creates an Ed25519 key pair and keeps the private key to itself. It sends us the public key and a signature made with the private key that proves it holds it (POST /v1/deployments). The first installation to claim an identifier keeps it. The identifier is the first 32 hexadecimal characters of a SHA-256 hash of the public key, so it is derived rather than chosen, and nobody can take another installation's identifier without holding its key. Sending the same key again changes nothing. A new key is a new identifier. While we have not enabled enrollment, the address answers 404 exactly like an address that does not exist.
  2. The enrollment request, which may carry the optional company name (at most 100 characters once control characters are removed), is at most 2,048 bytes, and anything that does not fit the strict format is refused with 400, 413 or 422 naming only the field and the kind of fault, never a submitted value. Enrollment is limited per address.
  3. The deployments table holds, per installation, the public key, the identifier, the company name, when it enrolled, when we last heard from it (updated at most once an hour) and whether it is active or revoked. The company name is shown only to our operators and never affects what an installation may do; a changed name sent later replaces the stored one. It holds no customer data, and a public key is not a secret.
  4. Afterwards the installation signs each call to the bug-report endpoint and to the connection service's token refresh with four headers: its identifier, a timestamp, a random single-use value and a signature over the method, the path, the timestamp, the random value and a SHA-256 hash of the exact request body. We check the signature before we read the body. A call with a missing, malformed, stale (more than 300 seconds from our clock), unknown or wrongly signed identifier, or a reused random value, is refused with 401 and the same answer in every case. Reused random values are remembered for 10 minutes by each serving task, so a captured request replayed to a different task within the five-minute window would pass that one check; the endpoints that use signing are built so that this does nothing (a bug report is stored once by its identifier, and a refresh repeats a refresh the installation asked for). A token refresh is not tied to an installation: only the signature is checked. Each installation is rate limited, and 429 answers carry a Retry-After header.
  5. An operator can revoke an installation and restore it, each action needing a second secret code and being recorded. A revoked installation's next signed call is refused with 403, and it cannot enroll again; nothing is cached, so this applies at once. Only a caller holding the key learns that an identifier is revoked.
  6. The service logs enrollments and refusals with the identifier and a fixed reason word, never a key, signature or body.

Request validation#

  • The state value is signed with HMAC-SHA256 and expires after 10 minutes.
  • The return address must be an HTTPS address with no embedded credentials and no fragment, within a length limit and a strict character set.
  • Each nonce is single use.
  • Requested permissions must be a subset of what the service allows for that provider.
  • Failures at collection are uniform: an unknown, expired, replayed or wrong-secret request all receive the same response, so nothing is revealed about which one occurred.
  • A failed callback shows a plain error page and never redirects.

Logging and tracing#

Logs contain the request path, method, status, duration, provider name, outcome and stable error codes or types. For deployment enrollment and signed calls a log line carries the deployment identifier and a fixed reason word, never a key, signature, company name or body. For the bug-report endpoint a log line carries the category of an accepted report and whether it repeated an earlier one, and never anything else from the report. For the inference service and the portal they also carry the request, account and model identifiers, token counts, amounts and status. They never contain tokens, authorization codes, client secrets, handoff identifiers, verifier secrets, keys, passwords, confirmation or reset links, prompts, responses or query strings. Request tracing excludes the connection routes and the email confirmation pages, and any query string is removed from trace data of the connection routes if one is ever recorded. Logs are kept for one month, including the logs of the scheduled month-close job. We have not turned on load balancer access logs or web firewall request logging.

Secrets and access#

  • Provider client secrets and the keys for signing and sealing are held in a managed secrets store and are sent only to the provider's token endpoint. They are never sent to an installation or a browser.
  • Our keys for the model providers, the Stripe keys and the operator codes are also held in the managed secrets store and delivered to the running service as secrets. Model provider keys are sent only to that provider. They are never sent to an installation or a browser. Requests to Amazon Bedrock are signed with the service's own access role, so no key for Bedrock is stored.
  • The service runs with an access role limited to reading, writing and deleting records in the hand-off table and checking its status, and to reading, adding, updating and querying records in the ledger table that holds accounts and usage records. The role cannot delete from the ledger table, so the service can add to and update its records but not remove them. For the bug-report table it can only add a report, read one and list a day's reports. For the deployments table it can only add an installation, read one, update its status or last-seen time and list by status, and it cannot delete or scan. It can send email only from our own sender address. It can call Amazon Bedrock only for the models the service offers, list the models Bedrock offers, and read Amazon Web Services price lists.
  • Staff with operator access sign in to the portal with a confirmed email address on a domain we have approved. Actions that change an account need a second secret code, and each such action and each code attempt is recorded.

Backups and exports#

  • The hand-off table has no backups, by design: its records live minutes and a restore would bring back sealed tokens.
  • The bug-report table has no backups, by design: reports are diagnostic records that expire after 180 days, and a restore would bring back reports we have already removed.
  • The table that holds deployment identities has point-in-time recovery, which lets Amazon Web Services restore it to any second in the previous 35 days. It is kept because losing it would make every installation enroll again and would forget which identifiers an operator revoked. It holds public keys, identifiers and company names only, and nothing else about an installation.
  • The ledger table that holds accounts, usage records and invoice records has point-in-time recovery, which lets Amazon Web Services restore it to any second in the previous 35 days. We have not shortened that default window.
  • Once a day, at 04:00 UTC, the whole ledger table is exported to a private storage bucket. The bucket blocks public access, encrypts its contents, accepts only encrypted connections, keeps versions, moves objects to colder storage (Glacier Instant Retrieval) after 90 days, expires old versions of replaced or deleted files after 90 days and has no rule that deletes an export. An alarm tells us if the daily export cannot be started.
  • The export holds the same records as the table, including email addresses and password hashes, and no prompts or responses.

Availability#

The connection service is hosted on Amazon Web Services in the United States, and its data is processed only there. The inference service and account portal are hosted there too, and the account and usage data they hold is stored and processed only there. Requests sent to Amazon Bedrock are processed by Amazon Web Services in the United States: we call Bedrock only in its regions in the United States and through its inference profiles for the United States, which keep requests within the United States. The other model providers and Stripe process the data we send them in their own locations.

Installations do not depend on the connection service to run. If it is unavailable, an installation keeps working and offers its own alternative for connecting accounts. If the inference service is unavailable, requests that use it fail; models an installation reaches with its own provider keys are not affected. The service runs as at least two copies, and when one is replaced, requests already streaming are given time to finish.

Revoking access#

  • In your Workforce Intelligence installation, disconnect the account.
  • In the portal, revoke an API key to stop it working within about a minute.
  • In the outside service's own account settings (for example a security or connected-apps page), remove the Workforce Intelligence application. This ends access at the provider regardless of what any installation holds.

Reporting a security issue#

Write to privacy@getwi.com with the details. Please do not test against the service in ways that affect other people, and give us reasonable time to respond before disclosing publicly.