Skip to main content
Authorized operations guide

Browser automation for financial portals.

Authorized portal automation can remove repetitive work. It should never inherit financial authority. Transaction approval needs a separate control.

Treat authenticated browser state as sensitive. Separate accounts by operational role. Keep state outside source control.

Automate preparation before commitment. Require explicit approval for consequential actions. Record the operator and final details.

Published byLegbaReviewed byAakash HarishSecurity Research Contributor, LegbaReviewed 2026-08-28 · Updated 2026-08-28

The short version

Automation can accelerate routine browser work. It cannot create legitimate authority. Approval boundaries must remain explicit.

Begin with explicit authority.

Automate only permitted financial portal work. Document authority for each portal and account. Portal terms and contracts still apply. Internal approval should precede implementation.

Write the permitted scope plainly. Name portals, accounts, and actions. Name prohibited actions equally clearly. Ambiguity creates dangerous operational drift.

Start with lower-mutation retrieval work. Balance reviews and statements still expose confidential data. Payment preparation needs tighter controls. Final submission deserves separate approval.

Authority can change over time. Staff roles change and contracts expire. Portal permissions can also change. Revalidate scope after every material change.

  • Document authority for each portal.
  • Review applicable portal terms.
  • Name permitted accounts precisely.
  • Name permitted actions precisely.
  • Name prohibited actions precisely.
  • Assign one accountable owner.

SourcesNational Institute of Standards and TechnologyOWASP FoundationFederal Trade Commission

Separate five operating controls.

Browser automation performs defined interactions. Authentication establishes an account session. Authorization permits portal actions. Approval confirms a financial commitment.

Browser isolation changes an execution boundary. It does not replace the other controls. Playwright browser contexts isolate test state. They are not remote browsers.

NIST treats authentication and authorization separately. OWASP also separates login and transaction authorization. Scripts should preserve both distinctions. Human approval should remain visible.

Evidence forms the fifth operating control. Every consequential run needs accountable records. Logs should identify scope and outcomes. Sensitive data should remain minimized.

  • Automation performs defined interactions.
  • Authentication establishes account identity.
  • Authorization permits specific portal actions.
  • Approval confirms transaction details.
  • Isolation creates an execution boundary.
  • Evidence records accountable outcomes.

SourcesPlaywrightNational Institute of Standards and TechnologyOWASP FoundationChromium

Inventory portals before automating.

Each portal carries unique behavior. Authentication flows and roles differ. File formats and session lifetimes differ. Maintenance windows can also differ.

Build one inventory before writing scripts. Record the accountable business role. Record data classes and actions. Record portal support contacts.

Separate retrieval from mutation. Reading balances carries lower mutation risk. It still exposes confidential information. Reads may change sessions and audit records. Uploading documents changes portal state and data exposure.

Portal inventories reduce hidden scope. They also expose duplicate access. Operators can remove stale accounts. Security teams can prioritize reviews.

  • Record accountable portal roles.
  • Record authorized account roles.
  • Classify readable customer information.
  • Classify every state-changing action.
  • Record session and timeout behavior.
  • Record support escalation paths.

SourcesFederal Trade CommissionElectronic Code of Federal RegulationsNational Institute of Standards and Technology

Understand browser context isolation.

Playwright creates clean browser contexts for tests. Each context gets separate cookies and storage. Contexts improve reproducibility and failure isolation. They remain inside the running browser.

Context isolation differs from remote isolation. Chrome Site Isolation separates renderer processes. Remote browser isolation moves selected execution elsewhere. These boundaries serve different jobs.

Use separate contexts for separate roles. Do not mix administrator and operator state. Do not reuse customer-specific state broadly. Close contexts after defined work.

Context separation still needs identity controls. A context cannot grant portal permission. It cannot approve a transaction. It cannot establish compliance.

  • Separate contexts by account role.
  • Separate contexts by customer boundary.
  • Close contexts after defined work.
  • Do not confuse local isolation.
  • Remote isolation remains another boundary.

SourcesPlaywrightChromium

Treat authentication state as sensitive.

Playwright can save authenticated browser state. That state may contain cookies and headers. Playwright warns those files enable account impersonation. Source repositories are inappropriate storage.

Playwright recommends a dedicated auth directory. Its example adds that directory to gitignore. That step prevents accidental commits. It does not secure the file itself.

Operational automation needs stronger state handling. Restrict file access and retention. Use dedicated accounts where supported. Revoke state after suspected exposure.

Shared state creates accountability problems. Parallel state changes create more risk. Playwright recommends separate accounts for state-changing tests. Production policy needs independent review.

  • Exclude auth state from repositories.
  • Restrict state file access.
  • Use dedicated operational accounts.
  • Separate state-changing workflows.
  • Expire state after defined use.
  • Revoke suspected exposed state.

SourcesPlaywrightNational Institute of Standards and Technology

Use the action-authority matrix.

This matrix separates preparation from commitment. It assigns a sample control posture. Organizations should adapt every row. Portal capabilities and risk decide final policy.

The matrix reduces decision ambiguity. Scripts receive a defined stopping point. Humans receive a clear approval point. Evidence connects both stages.

Map portal actions to automation, approval, and evidence.
FactorAutomation postureRequired approvalRequired evidenceFailure response
Read account balancePermit within documented scope.No transaction approval applies.Record account and retrieval time.Stop on identity mismatch.
Download statementPermit for authorized accounts.Data handling policy applies.Record file and account context.Quarantine unexpected file types.
Upload supporting documentPrepare after content validation.Required workflow approver confirms destination.Record file hash and target.Stop on destination changes.
Change account profileRequire narrow explicit scope.Required account approver confirms changes.Record previous and final values.Revoke access after anomalies.
Prepare paymentAllow draft preparation only.Authorized approver reviews final details.Record amount and destination.Stop when details change.
Submit paymentStop automation before commitment.Separate authorized approval remains required.Record approver and final details.Abort after approval mismatch.
Change approval methodKeep outside routine automation.Required approver authorizes method changes.Record approver and method change.Escalate every unexpected request.

Build durable portal interactions.

Playwright locators find current page elements. The documentation favors user-facing attributes. Roles and labels often reflect user intent. Explicit contracts provide another option.

Avoid brittle position-based selectors. Portal layouts can change without warning. Visible labels can also change. Maintain a small selector inventory.

Playwright performs actionability checks before actions. Elements need suitable visible and stable states. Click targets must receive events. Inputs must remain editable.

Forced actions disable some checks. Avoid them for consequential workflows. A failed check should stop execution. Operators should review the changed portal.

  • Prefer role-based locators.
  • Prefer clearly labeled controls.
  • Use explicit portal contracts.
  • Avoid brittle layout selectors.
  • Keep actionability checks enabled.
  • Stop after unexpected page changes.

SourcesPlaywrightPlaywright

Stop before financial commitment.

OWASP distinguishes authentication from transaction authorization. Users should understand which action occurs. Significant transaction details need confirmation. Amount and destination often matter.

Transaction authorization should remain server-side. Each transaction needs valid approval. State transitions should follow enforced order. Browser scripts should not weaken those controls.

Automation can prepare transaction drafts. It can collect supporting evidence. An authorized person should review final details. The portal should enforce the commitment.

Approval should become invalid after detail changes. Scripts should detect those changes. The operator should restart review. Evidence should preserve the final version.

  • Separate login from transaction approval.
  • Display significant transaction details.
  • Require an authorized approver.
  • Keep enforcement server-side.
  • Invalidate changed transaction details.
  • Record final approval evidence.

SourcesOWASP FoundationNational Institute of Standards and Technology

Run the authorized automation checklist.

This checklist turns authority into repeatable evidence. Each step creates one reviewable artifact. Teams can stop before unsafe ambiguity. The script remains the smallest component.

Run the checklist before production use. Repeat it after portal changes. Repeat it after role changes. Repeat it after authentication changes.

  1. 01

    Confirm written authority.

    Record portals, accounts, and permitted actions. Review current terms.

  2. 02

    Inventory portal behavior.

    Map authentication, sessions, roles, and files. Mark financial commitments.

  3. 03

    Create dedicated accounts.

    Use narrow permissions and accountable identities. Avoid casual state sharing.

  4. 04

    Protect authentication state.

    Exclude state from repositories. Restrict access and retention.

  5. 05

    Build durable locators.

    Prefer roles, labels, and explicit contracts. Keep checks enabled.

  6. 06

    Define stopping points.

    Stop before commitments and authority changes. Preserve human review.

  7. 07

    Capture minimal evidence.

    Record identities, actions, approvals, and outcomes. Minimize customer information.

  8. 08

    Test failure recovery.

    Practice session revocation and account disablement. Confirm escalation paths.

  9. 09

    Approve controlled rollout.

    Require every mandatory outcome. Keep unresolved gaps visible.

SourcesPlaywrightPlaywrightPlaywrightPlaywrightOWASP FoundationNational Institute of Standards and TechnologyFederal Trade Commission

Keep evidence useful and limited.

Covered financial institutions need risk-based safeguards. FTC guidance addresses access controls and inventories. It also addresses application assessment. Authorized user activity needs logging.

Automation logs should identify accountable runs. Record the portal and account role. Record each state-changing action. Link approvals with final outcomes.

Do not capture everything by default. Screenshots can contain customer information. Traces can contain sensitive portal content. Retention needs explicit purpose and access.

Compliance depends on the broader program. A script cannot establish it. Legal scope needs qualified assessment. Organizational controls still determine outcomes.

  • Log accountable automation identities.
  • Log every state-changing action.
  • Link approvals with final outcomes.
  • Minimize screenshots and traces.
  • Restrict evidence access.
  • Define evidence retention periods.

SourcesFederal Trade CommissionElectronic Code of Federal Regulations

Design for portal changes.

Financial portals change without your schedule. Labels move and roles evolve. Authentication flows can also change. Automation should fail closed.

A timeout is operational evidence. An unexpected locator is another signal. Never retry an uncertain financial commitment. Inspect portal history first.

Maintain one change record per portal. Note selector and workflow changes. Note permission and authentication changes. Re-run approval tests afterward.

Recovery needs practiced actions. Revoke browser state when exposed. Disable automation accounts when necessary. Preserve useful evidence for review.

  1. 01

    Detect unexpected state.

    Compare page identity and expected controls. Stop after mismatches.

  2. 02

    Preserve minimal evidence.

    Record time, portal, account, and failure. Avoid unnecessary customer data.

  3. 03

    Revoke exposed state.

    Invalidate affected sessions and credentials. Follow organizational procedures.

  4. 04

    Review portal changes.

    Update selectors and permissions deliberately. Require independent review.

  5. 05

    Retest before release.

    Run read-only and approval scenarios. Confirm every stopping point.

SourcesPlaywrightPlaywrightPlaywrightNational Institute of Standards and TechnologyFederal Trade Commission

Where Legba can fit.

Legba's agent skill exposes routing to agents. It also exposes isolated browser sessions. Those capabilities remain narrowly scoped. They do not create portal authority.

The agent skill does not approve transactions. It does not establish compliance. Playwright compatibility is not claimed. Portal compatibility still needs direct testing.

The portal still controls authentication. Organizational policy still controls authorization. Documented financial controls govern transaction approval. Those boundaries remain external.

Use the skill inside documented authority. Keep stored state restricted. Preserve required user-presence steps. Stop before every financial commitment.

  • Agent-callable routing is supported.
  • Agent-callable isolation is supported.
  • Portal authority is not provided.
  • Transaction approval is not provided.
  • Playwright compatibility is not claimed.
  • Compliance remains organizational.

SourcesLegbaOWASP FoundationPlaywright

FAQs.

References

  1. 01
    LegbaLegba
  2. 02
    AuthenticationPlaywright
  3. 03
    IsolationPlaywright
  4. 04
    Auto-waitingPlaywright
  5. 05
    LocatorsPlaywright
  6. 06
  7. 07
    16 CFR Part 314Electronic Code of Federal Regulations
  8. 08
    NIST SP 800-207: Zero Trust ArchitectureNational Institute of Standards and Technology
  9. 09
    NIST SP 800-63B: Authentication and Authenticator ManagementNational Institute of Standards and Technology
  10. 10
  11. 11

Keep exploring