Skip to content

M7-S2 — Applied security design: grants, protected fields, automations and credentials

Section titled “M7-S2 — Applied security design: grants, protected fields, automations and credentials”
ModuleM7 — Secure the solution
After this session you canDesign and apply the security of a whole suite, people and programs together, and show that it holds.
TimeFacilitated: 51 min · On your own: 51 min
Before you startM7-S1 if you came through ACD. Everything you built in Modules 2 to 6. Signed in as yourself; Hala Mansour in a private window; TOKEN, FEED and .tokens.json in your terminal.
Go deeperProtect a field · Sensitive and encrypted fields: model and API · The security boundary

◆ Orientation (1 min) — Security is a design, not a switch

Section titled “◆ Orientation (1 min) — Security is a design, not a switch”

The suite now has two modules, a Function, a webhook, two OAuth programs, an API token and a public form. Each opens a way to the candidates’ data. R-13 and R-14 ask for protected salaries and passports and a form bots cannot flood, but the real requirement behind them is broader: every person and every program reaches exactly what it needs, and nothing leaks through the side doors you built in Modules 3 to 6. In this session you write that design, apply it, and test it.

▤ Concept (6 min) — The four layers of a suite’s security

Section titled “▤ Concept (6 min) — The four layers of a suite’s security”

Layer 1: grants, as the product really behaves

Section titled “Layer 1: grants, as the product really behaves”

The full ladder of permission levels is ACSA’s subject; the design uses these facts, verified on the running product:

  • There is no deny. Access from every source adds up and the highest grant wins. Removing a grant removes only that grant; choosing Restricted on an entity takes back the access given there, and the person falls back to their system level.
  • Edit includes everything Developer can do, plus browsing and changing records in Administration. Listing records in Administration needs Edit on the entity or its module; View is not enough. People normally work through views, which have their own access.
  • System level Restricted hides the Services menu. Anyone who must apply for or act on a request in the portal needs at least View, which also shows a reduced Administration menu.
  • Developer access is a builder’s power. A Developer on an entity writes its reactions, expressions and formulas, including reactions that run as System. Give it to trusted builders only, and review System reactions as you would review code.

Layer 2: protected fields, everywhere the value travels

Section titled “Layer 2: protected fields, everywhere the value travels”

A Sensitive value is masked in lists, the record, its history, reports and exports. Through the API, a read lists the fields the caller may not read in sensitiveMaskedFields; a filter on a sensitive field the caller cannot read is refused with 400 SENSITIVE_FIELD_QUERY_NOT_ALLOWED; a view’s OpenAPI document names a sensitive field but never shows its value. An encrypted field goes further: nobody can filter, search, sum or group it, it cannot be used in reaction conditions, reports or as a main title, it arrives empty in notification and email text, and document templates show it masked. Turning Encrypt on or off for an entity that has records is a structure change: those records must be upgraded, which encrypts or decrypts their stored values.

Layer 3: what automations and integrations may reveal

Section titled “Layer 3: what automations and integrations may reveal”

A reaction, a document template or a summary often runs for someone else. On an entity with a protected field, each has a Sensitive Data Access Policy:

PolicyThe element seesChoose it for
Privileged (the default)Always the real valueAn automation that must use the value, deliberately
ProhibitedAlways ****Anything that never needs it, such as a webhook to a third party
User-BasedWhat the person who set it off may seeActions a person triggers; not offered for System, Timer or On Time Exceeded
AutoPrivileged when the platform runs it, User-Based when a person doesMixed triggers; not offered on summaries

Under a masking policy, an action that would write a mask over a real value, or send one out by Call API or email, fails instead; notifications, files and announcements may pass the mask on. Values from protected fields never appear in a reaction’s history in clear.

One application user per integration per environment, reaching one view each; OAuth for people, whose own access applies (scopes release claims, they do not narrow data); anonymous tokens and Anonymous views for visitors, showing only fields meant for the public; Human Verification on public forms; tokens kept in configuration, rotated on a schedule, revoked knowing the five-minute delay. The gateway strips identity headers, so a client can never claim to be someone else.

A threat model lists, for each way in, what could go wrong and what stops it. For the suite:

ThreatMitigation in the design
The careers token leaksIts user reaches two views only; per-environment users; regenerate, or archive to revoke
Bots flood the public formHuman Verification on the public view; the validator refuses impossible values
A webhook leaks personal dataThe payload is built only from mapped fields; its policy is Prohibited
An over-privileged automationSystem executor used once, named, reviewed; everything else Executor or default
A curious colleagueSensitive and Encrypt with grants to HR only; every reveal is audited
A client claims another identity or tenantThe gateway overwrites identity headers and takes the tenant from the host
A public view shows too muchA separate public view with public fields only; never reuse an internal view

⛏ Lab (36 min) — Protect, restrict and prove

Section titled “⛏ Lab (36 min) — Protect, restrict and prove”

Goal. Salaries visible to HR only, passport numbers encrypted, the payroll webhook unable to leak a protected value, the public form behind human verification, and proof from three sides.

Before you start. Signed in as yourself.

Protect the fields

  1. Edit Job Application. Open Expected salary, turn on Sensitive, and in Select groups choose HR.
  2. In the Job offer details block, add a Text field Passport number. Turn on Encrypt, and in Select groups choose HR. Select Save and Save Changes.
  3. If the designer reports records to upgrade, select Upgrade Records for them.

Decide what automations may reveal

  1. Open the reaction Notify payroll of a hire. Its form now shows a Sensitive Data Access Policy: choose Prohibited. Confirm.
  2. Open Calculate offer package and Call Start onboarding: neither uses a protected field; set Prohibited on both too, so a later edit cannot leak one by accident.

Close the public door

  1. Open the view that offers the Job Application form to visitors, go to its Access Permission settings, make sure Anonymous is on, and turn on Human Verification.

Screenshot pending The Expected salary field settings with Sensitive on and the HR group selected, and the Passport number field with Encrypt on What to notice: turning on Encrypt turns Sensitive and Searchable off; the two protections never sit on one field.

Prove it from three sides

  1. A person without access. As yourself, a system administrator outside HR, open Tariq Mansour’s application: Expected salary shows ****, with no way to reveal it.

  2. A person with access. As Hala Mansour, open the same application. Expected salary shows **** until she selects Unmask and confirms who she is; then she sees 15000.

  3. A program. With the careers token, read Careers feed once more: nothing changed, because that view never showed a protected field. Then read one application as Hala through HR view without unmasking:

    Terminal window
    curl -s -G "$BASE/api/v1/v/$HRVIEW/v3/entities/job_application/entries" \
    -H "Authorization: Bearer $(jq -r .access_token .tokens.json)" \
    --data-urlencode 'search=Tariq' --data-urlencode 'filterCriteria={"limit":1}' \
    | jq '.entries[0] | {salary: .value.expected_salary}'

    The salary comes back masked, not 15000. A list read does not say which fields are masked; a read of the single record does, on its entity: a field Hala could unmask is listed in sensitiveMaskedFieldsWithUserAccess, a field she has no grant for in sensitiveMaskedFields.

  4. The webhook. Edit Notify payroll of a hire and, as a test, add "salary": "{{salary}}" to its payload, mapped to Expected salary. Sign Nour Hamdan’s contract as Hala Mansour: the call fails rather than send a mask, and HR is notified by your failure branch. Remove the line again.

Write the design

  1. Write Meridian’s security design on one page: a table with one row per audience and per program (HR, IT, interviewers, candidates, the careers site, payroll, the wall screen, builders), and the columns Reaches · Through · Protected fields seen · Credential · Why; then the threat table for the suite.

Check.

  • Expected salary is Sensitive for HR; Passport number is Encrypted for HR.
  • The payroll, offer and onboarding reactions are Prohibited.
  • The public form has Human Verification.
  • You saw **** as yourself, the value only after Unmask as Hala, and the value masked through the API.
  • The test webhook with the salary failed and reached the failure branch, and is restored.
  • Your design covers every audience and program, with a reason for each.

Pass condition. The three proofs match the design: no one outside HR can see a salary or a passport number by any route, no automation can send one out, and the design explains every grant.

If something goes wrong

What you seeWhat to do
Encrypt turns itself off after savingThe field type cannot be encrypted (reference, block, switch, category). Use a Text field.
Encrypted values cannot be savedYour operator has not set up the encryption keys for this environment. Ask; note it in your design.
No Sensitive Data Access Policy on a reactionThe entity has no protected field yet: save step 1 first.
Hala sees **** and no UnmaskShe is not in HR, or the grant is on another field.
The test webhook succeeded and sent ****Its policy is not Prohibited, or not saved.
Model answer

Security design (extract).

WhoReachesThroughProtected fields seenCredentialWhy
HRApplications, jobs, worklistHR view, HR worklist, InboxSalary (after Unmask), passport (one at a time)Their own sign-inThey run hiring
ITNew hires, checklistsIT onboarding deskNoneTheir own sign-inOnboarding needs no salary
InterviewersTheir own stepsInboxNoneTheir own sign-inThey judge candidates, not pay
CandidatesThe public form, open jobsAvailable jobs, the serviceNoneNone (anonymous), with human verificationPublic
Careers siteOpen jobs; new applicationsCareers feed, Careers intakeNoneAPI token of Careers Site, per environmentThe narrowest door that works
PayrollNothing in the suiteIt receives noticesNone (policy Prohibited)A key it issued, in a headerWe call it
Wall screenHR’s worklist, liveHR worklist, live channelNoneA kiosk account’s OAuth sessionLive channel needs OAuth
BuildersThe designAdministrationNoneDeveloper on the two modulesExpressions and System reactions are code

The threat table is the one in the applied threat model, with one addition found in the lab: the webhook test proved that a masking policy turns an accidental leak into a visible failure.

◇ Worked scenario (1 min) — The analytics request

Section titled “◇ Worked scenario (1 min) — The analytics request”

Finance asks for a nightly export of every application, with expected salaries, to their analytics tool, “to model hiring costs”. Decide before reading on.

Do they need salaries per person? They need costs by department and month. Decision: a statistic summary of Expected salary grouped by department, whose policy is Privileged because it shows only totals, published to Finance; no per-person salary leaves HR.

If they insist on records. Decision: a dedicated application user Finance analytics with a view showing department, month and salary, granted Expected salary access deliberately and documented in the design, a nightly read over the API, and a review date.

What never happens. A shared HR token, or a webhook that sends salaries out with a Privileged policy because “it is only internal”. Every exception is a row in the design.

✓ Practice (6 min) — Check your design

Section titled “✓ Practice (6 min) — Check your design”
PracticeChoose one answer.

A colleague proposes None on a contractor for Applications to “make sure” he never sees them, though his group grants View. What happens?

  1. Explanation for A

    ✗ Incorrect

    Not this one: there is no deny; the group’s grant still applies. See layer 1: grants.

  2. Explanation for B

    ✓ Correct

    Correct: to take access away, remove the grant that gives it, here the group’s. See layer 1: grants.

  3. Explanation for C

    ✗ Incorrect

    Not this one: a None setting removes only a direct grant, which he did not have. See layer 1: grants.

Check your answer

The correct answer is B. Open the explanation under each option to see why.

PracticeChoose one answer.

A webhook to an insurance partner must never send a salary. Which setting makes an accidental leak fail loudly instead?

  1. Explanation for A

    ✗ Incorrect

    Not this one: Privileged always sends the real value. See layer 3.

  2. Explanation for B

    ✓ Correct

    Correct: under a masking policy, Call API refuses to send a protected value, so the run fails and the failure branch tells someone. See layer 3.

  3. Explanation for C

    ✗ Incorrect

    Not this one: it depends on the person who set it off, and a hire may be set off by someone with access. See layer 3.

Check your answer

The correct answer is B. Open the explanation under each option to see why.

PracticeChoose one answer.

An HR dashboard sums Monthly allowance by department. Security asks to encrypt the field. What do you answer?

  1. Explanation for A

    ✗ Incorrect

    Not this one: an encrypted field cannot be summed or grouped by anyone. See layer 2.

  2. Explanation for B

    ✓ Correct

    Correct: Sensitive keeps filtering and totals for people with access; Encrypt rules them out. See layer 2.

  3. Explanation for C

    ✗ Incorrect

    Not this one: a policy cannot make the database read an encrypted value. See layer 2.

Check your answer

The correct answer is B. Open the explanation under each option to see why.

PracticeChoose one answer.

Which mitigation answers “a leaked integration token”?

  1. Explanation for A

    ✗ Incorrect

    Not this one: the token is already a long random secret; length does not limit the damage. See the applied threat model.

  2. Explanation for B

    ✓ Correct

    Correct: least privilege limits what a leak exposes, and revoking the user ends it within minutes. See the applied threat model.

  3. Explanation for C

    ✗ Incorrect

    Not this one: interceptors fail open and cannot be a security control. See M4-S2.

Check your answer

The correct answer is B. Open the explanation under each option to see why.

PracticeChoose one answer.

Interviewers must approve applications in their Inbox. Their base level is Restricted. What happens?

  1. Explanation for A

    ✓ Correct

    Correct: anyone who acts on requests needs at least View. See layer 1: grants.

  2. Explanation for B

    ✗ Incorrect

    Not this one: without the Services menu they cannot reach the Inbox at all. See layer 1: grants.

  3. Explanation for C

    ✗ Incorrect

    Not this one: the whole Services menu is hidden at Restricted. See layer 1: grants.

Check your answer

The correct answer is A. Open the explanation under each option to see why.

You wrote and applied a security design across people, automations and programs, and proved it from three sides. After Module 7 you can secure a solution: least-privilege grants, protected fields, what automations and integrations may reveal, and the right credential for every caller, with the threats each choice answers.

Next. Module 8 ships it: the two modules, their Functions and their reactions, packaged and promoted to another environment.