Skip to main content

Security at Samarohh

Last updated: November 2026 — the engineering controls that are actually shipped, described without certifications we do not hold.

Samarohh protects wedding guest data with HttpOnly session cookies, AES-256-GCM encryption for guest contact fields, keyed HMAC-SHA-256 blind indexes for lookup, and verification of every Razorpay and Meta webhook. Guest records are anonymised past the 365-day retention window in line with India's DPDP Act 2023.

Our Security Commitment

Samarohh handles event data, guest contact details and payment transactions. This page describes the controls the platform actually uses today. It is not a claim of SOC 2, ISO 27001 or any other certification we do not hold, and it is not a warranty that a particular attack is impossible.

If you believe you have found a vulnerability, please see the Vulnerability Disclosure section below.

Controls at a glance

The table summarises the controls that ship today. Each row is expanded in the sections below.

AreaWhat ships todayEnforced by
Sessions15-minute access token; 7-day rotating refresh token; HttpOnly, SameSite=Lax cookiesAuthCookieUtil, JWT filter
Guest PIIAES-256-GCM with a random IV per write; HMAC-SHA-256 blind indexApplication layer
WebhooksRazorpay HMAC-SHA256 and Meta X-Hub-Signature-256 verified; replay de-duplicatedprocessed_webhook_events
TransportHTTPS enforced; one-year HSTS with preload; strict CSPSecurity chain
Retention365-day guest and audit retention; 730-day dormant events; ledger protected by ON DELETE RESTRICTScheduled jobs, Postgres FKs
DisclosureAcknowledged within 3 business days; no legal action for good-faith researchsecurity@samarohh.com

Authentication and Sessions

Samarohh issues a 15-minute JWT access token and a 7-day rotating refresh token, both in HttpOnly, SameSite=Lax cookies. Refresh tokens are stored only as SHA-256 hashes, rotation has a 60-second device-bound grace window, and a replay outside that window revokes the token family.

  • Short-lived access tokens: the JWT access token expires after 15 minutes (proactively refreshed in the background every 5 minutes) and is delivered in an HttpOnly, Secure (in production), SameSite=Lax cookie. It is never stored in browser storage.
  • Rotating refresh tokens: the refresh token lasts 7 days, is rotated on use, and is stored server-side only as a SHA-256 hash. The raw value is never written to the database.
  • Rotation grace and replay detection: a duplicate refresh within a 60-second window, from the same device fingerprint, resolves to the live successor. A replay outside that window, or from a different fingerprint, revokes the entire token family and is logged as a security event.
  • Account state on every request: the JWT filter rejects a disabled, locked, rejected or unapproved account, and requires email verification. Deactivation and lockout are not merely cosmetic.
  • OTP recovery is purpose-bound: an OTP is bound to the account's email and to the purpose it was minted for: PASSWORD_RESET or CONFIG_UPDATE. A challenge minted for a weaker purpose cannot be replayed to reset a password. OTP codes are bcrypt-hashed, single-use, expire after 300 seconds, allow at most 3 attempts, and are rate-limited.
  • Account lockout and session controls: repeated failed sign-ins trigger a temporary lockout. You can view and revoke active sessions, and concurrent sessions are capped.

The platform does not currently offer app-based two-factor authentication. Do not rely on a 2FA claim that is not present in the product.

Authorization and Tenant Isolation

  • Role hierarchy: a role-hierarchy service resolves administrative roles, and admin-only paths are separately gated in the security chain.
  • Per-event sub-user permissions: guests, events and invitations are guarded by explicit permissions such as VIEW_GUESTS, EDIT_EVENTS and SEND_INVITATIONS.
  • Enforcement beyond the page: the same guards are applied to APIs, scheduled sends, template operations and exports. A sub-user with read-only guest access cannot schedule a send merely by calling the endpoint.
  • Ownership checks: a purchasing or deleting action is checked against the event owner, not only against the account's role.

Data Protection and Integrity

Guest phone numbers, email addresses and outbox recipients are encrypted at the application layer with AES-256-GCM, with a fresh 12-byte IV per write and a 128-bit authentication tag. A keyed HMAC-SHA-256 blind index supports equality lookup and de-duplication without decrypting rows or storing a plain hash.

  • Column encryption: guest phone numbers and email addresses, account contact fields and outbox recipients are encrypted at the application layer with AES-256-GCM. Each write gets a fresh 12-byte random IV, and the ciphertext carries a 128-bit authentication tag.
  • Keyed blind indexes: a separate HMAC-SHA-256 index supports equality lookup, de-duplication, phone-based opt-out matching and email uniqueness without decrypting rows or storing a plain hash of a low-entropy value.
  • Password hashing: passwords are hashed with bcrypt at cost 12. Plaintext passwords are never stored or logged.
  • Financial ledger protection: the payment, invoice and refund tables are protected by ON DELETE RESTRICT. A user erasure path cannot silently delete the 7-year GST money trail; the database fails the delete instead.
  • Upload containment: local upload keys are resolved against a fixed root and rejected if the normalized path escapes it, which blocks../ traversal. XLSX and vCard imports are streamed through a bounded reader with ZipSecureFile ZIP-bomb limits, a 10 MiB file ceiling and a 5,000-row cap.
  • Least data in logs: audit views mask identifiers, and raw gateway payloads are summarized rather than stored verbatim. Account erasure also scrubs outbox and message-log personal data.

Webhook and Messaging Safety

  • Razorpay webhooks: the signature is verified with HMAC-SHA256 before processing, and a signed-payload de-duplication ledger (processed_webhook_events) prevents a replayed state-changing event from being applied twice. A refund carries a unique client receipt so a retried create call and a late webhook resolve to the same reservation.
  • Meta webhooks: X-Hub-Signature-256 is verified with the app secret, and template status updates are scoped to the platform's own WhatsApp Business Account by WABA id or phone-number id. A status event from a tenant's separate WABA cannot mutate the platform gallery.
  • Durable outboxes: WhatsApp and email sends are persisted in whatsapp_outbox and email_outbox and drained by workers with retry and idempotency keys, rather than fired from a request thread and lost on a crash.
  • Global STOP enforcement: every promotional send is checked against whatsapp_opt_out before delivery. A row queued before a STOP is failed at send time with the opt-out reason, not delivered.

Transport and Browser Controls

Production traffic is forced to HTTPS with a one-year HSTS policy, a strict Content-Security-Policy, X-Frame-Options: DENY, X-Content-Type-Options: nosniff, and a restrictive referrer and permissions policy. Authentication cookies stay HttpOnly, Secure in production and SameSite=Lax.

  • Production traffic is forced to HTTPS by the security chain
  • HSTS is sent for one year with includeSubDomains and preload
  • A strict Content-Security-Policy limits scripts, styles, images, frames and connections to the application and Razorpay's checkout, sets frame-ancestors 'none', object-src 'none' and base-uri 'self'
  • X-Frame-Options: DENY, X-Content-Type-Options: nosniff, a strict referrer policy and a restrictive permissions policy
  • Authentication cookies are HttpOnly, Secure in production, SameSite=Lax, and scoped to the narrowest path that works

Audit, Retention and Erasure

Privileged operations are written to audit_logs and retained for 365 days. Guest PII is anonymised in place after 365 days, or 730 days after an event ends, and account erasure scrubs personal fields while preserving the financial ledger the GST rules require.

  • Privileged operations are written to audit_logs with actor, timestamp and change details. Audit rows are retained for 365 days and deleted in bounded batches.
  • Guest PII past its retention window is anonymised in place: soft-deleted guests after 365 days, and guests of an event that ended more than 730 days (2 years) ago.
  • WhatsApp message logs and terminal outbox rows are retained for 365 days; recipient phone numbers are anonymised so historical delivery counts remain accurate without keeping the identifier.
  • Account erasure anonymises the user row, revokes and anonymises refresh tokens, scrubs outbox and message-log PII, and clears raw gateway payloads, while preserving the financial ledger required by law.

Infrastructure and Build Controls

  • Database schema migrations are applied by Flyway and validated at boot, so a mapping that disagrees with the schema fails the deploy rather than reshaping production
  • The build runs dependency vulnerability scanning (OWASP dependency-check) and migration/schema integration tests against a real PostgreSQL instance
  • Database connections use bounded pools, statement and lock timeouts, and an idle-in-transaction timeout to stop a stuck query from pinning the service
  • Backups and operational logging are handled by the hosting infrastructure under access controls

Incident Response

If a security incident or personal data breach occurs, we:

  • Contain the incident and assess its scope and impact
  • Notify the Data Protection Board of India and affected Data Principals without undue delay in the manner prescribed by the DPDP Act
  • Give affected users the information they need to protect themselves where a risk of harm exists
  • Carry out a root-cause review and remediation, and keep an internal incident record

Vulnerability Disclosure

We welcome reports from the security community. If you discover a potential vulnerability in Samarohh, please:

  1. Email security@samarohh.com with the subject Security Disclosure
  2. Include a description of the vulnerability, steps to reproduce and potential impact
  3. Do not publicly disclose the issue before we have had a chance to investigate and release a fix
  4. Do not access or modify user data beyond what is necessary to demonstrate the issue

We commit to:

  • Acknowledge your report within 3 business days
  • Investigate credible reports promptly
  • Keep you informed of our progress
  • Not pursue legal action against good-faith security researchers

Compliance

  • Personal-data handling is designed around the DPDP Act 2023, including purpose limitation, consent withdrawal and the rights described in our Privacy Policy
  • Razorpay is a PCI DSS Level 1 certified payment processor; Samarohh does not store raw card data
  • Financial and GST records are retained for the statutory period and protected by ON DELETE RESTRICT
  • We do not claim SOC 2, ISO 27001 or a similar certification that we have not obtained

Contact

For security concerns or questions about these controls:

Security: security@samarohh.com

Support: support@samarohh.com

Subject: Security Disclosure

Samarohh is a product of Avartana Labs LLP. For enterprise security inquiries, use the security email above.