Skip to content
Back to Blog
·15 min read·technology

API Security Checklist for Indian Fintech

Indian fintech APIs handle ₹100+ lakh crore annually. This comprehensive checklist covers authentication, rate limiting, input validation, and RBI compliance...

Shouvik Mukherjee, Founder of Bachao.AI

Shouvik Mukherjee

Founder

Test Your Application
API Security Checklist for Indian Fintech

Security exposure this creates

Unpatched vulnerabilities in your tech stack are the #1 entry point for breaches targeting Indian businesses. Here's what to watch.

India's fintech revolution is built on APIs. UPI, BBPS, Account Aggregator, ONDC — every major financial innovation is API-first. But with great connectivity comes great responsibility. Indian fintech APIs process over ₹100 lakh crore annually, and they're under constant attack.

Having assessed APIs for multiple Indian fintech companies, I've compiled this comprehensive security checklist. It's organized by priority and maps to both OWASP API Top 10 and RBI's cybersecurity framework.

- ₹100+ lakh crore — annual value processed through Indian fintech APIs
- 94% of fintech apps tested had at least one critical API vulnerability (Bachao.AI internal data)
- BOLA (Broken Object Level Authorization) found in 68% of Indian fintech APIs tested
- 43% of Indian fintech APIs lack proper rate limiting
- 6 hours — CERT-In mandatory incident reporting time for financial sector

The Fintech API Threat Landscape

flowchart TD A[Fintech API Threats] --> B[Authentication Attacks] A --> C[Authorization Flaws] A --> D[Data Exposure] A --> E[Injection Attacks] A --> F[Rate Limiting Bypass] B --> B1[Brute Force OTP] B --> B2[JWT Manipulation] B --> B3[Session Fixation] C --> C1[BOLA/IDOR] C --> C2[Privilege Escalation] C --> C3[Function Level Access] D --> D1[Excessive Data in Response] D --> D2[PII in Logs] D --> D3[Debug Endpoints Exposed] E --> E1[SQL Injection] E --> E2[NoSQL Injection] E --> E3[Command Injection] F --> F1[OTP Flood] F --> F2[Transaction Replay] F --> F3[Account Enumeration]

The Checklist

Section 1: Authentication & Session Management

#CheckPriorityOWASP APIStatus
1.1OAuth 2.0 / OpenID Connect for user authCriticalAPI2
1.2JWT tokens signed with RS256 (not HS256)CriticalAPI2
1.3Token expiry ≤ 15 minutes for access tokensHighAPI2
1.4Refresh token rotation on every useHighAPI2
1.5OTP rate limiting (max 5 attempts per 10 min)CriticalAPI4
1.6OTP expiry ≤ 5 minutesHighAPI2
1.7No OTP in API response bodyCriticalAPI3
1.8API key rotation mechanism in placeMediumAPI2
1.9Multi-factor auth for high-value transactionsHighAPI2
1.10Session invalidation on password changeHighAPI2
🛡️
SECURITY
The #1 fintech API vulnerability in India: OTP in API response. I've seen this in at least 30% of Indian fintech apps. The server sends the OTP back in the HTTP response body during the verification flow, thinking the frontend needs it for "validation." An attacker just reads the response and bypasses OTP entirely.
bash
# BAD: OTP returned in response
POST /api/auth/send-otp
Response: {"status": "sent", "otp": "482910"}  # NEVER DO THIS

# GOOD: Only status returned
POST /api/auth/send-otp
Response: {"status": "sent", "expiresIn": 300}

Section 2: Authorization (BOLA/IDOR Prevention)

#CheckPriorityOWASP APIStatus
2.1Object-level authorization on every endpointCriticalAPI1
2.2Use UUIDs instead of sequential IDsHighAPI1
2.3Server-side ownership validationCriticalAPI1
2.4Function-level access control (admin vs user)CriticalAPI5
2.5No horizontal privilege escalation possibleCriticalAPI1
typescript
// BAD: No authorization check
app.get('/api/transactions/:id', async (req, res) => {
  const transaction = await db.findTransaction(req.params.id);
  res.json(transaction); // Any user can see any transaction!
});

// GOOD: Authorization check
app.get('/api/transactions/:id', async (req, res) => {
  const transaction = await db.findTransaction(req.params.id);
  if (transaction.userId !== req.user.id) {
    return res.status(403).json({ error: 'Forbidden' });
  }
  res.json(transaction);
});
⚠️
WARNING
BOLA (Broken Object Level Authorization) is the #1 vulnerability in the OWASP API Top 10 for a reason. In fintech, this means User A can see User B's transactions, balance, KYC documents, or even initiate transfers. Always validate that the requesting user owns the resource.

Section 3: Input Validation & Data Handling

#CheckPriorityOWASP APIStatus
3.1Schema validation on all inputs (Zod/Joi)CriticalAPI8
3.2Amount fields validated as positive numbersCriticalAPI8
3.3UPI ID format validation (regex)HighAPI8
3.4PAN/Aadhaar format validationHighAPI8
3.5File upload type and size validationHighAPI8
3.6SQL parameterized queries (no string concat)CriticalAPI8
3.7NoSQL injection preventionHighAPI8
3.8Request body size limitsMediumAPI4
typescript
// Input validation example with Zod (recommended for Indian fintech)
import { z } from 'zod';

const transferSchema = z.object({
  amount: z.number()
    .positive('Amount must be positive')
    .max(500000, 'Single transaction limit exceeded')  // RBI UPI limit
    .multipleOf(0.01, 'Invalid decimal places'),
  upiId: z.string()
    .regex(/^[a-zA-Z0-9._-]+@[a-zA-Z0-9]+$/, 'Invalid UPI ID format'),
  note: z.string()
    .max(50, 'Note too long')
    .regex(/^[a-zA-Z0-9\s]+$/, 'Special characters not allowed'),
  pin: z.string()
    .length(6, 'PIN must be 6 digits')
    .regex(/^\d{6}$/, 'PIN must be numeric'),
});

Section 4: Rate Limiting & Throttling

#CheckPriorityOWASP APIStatus
4.1Global rate limit per IPCriticalAPI4
4.2Per-user rate limit for authenticated endpointsCriticalAPI4
4.3Stricter limits on auth endpoints (login/OTP)CriticalAPI4
4.4Transaction amount-based throttlingHighAPI4
4.5Rate limit headers in responseMediumAPI4
4.6Exponential backoff on auth failuresHighAPI4
bash
# Recommended rate limits for fintech APIs:

# Authentication endpoints
/api/auth/send-otp     → 5 requests per 10 minutes per phone
/api/auth/verify-otp   → 5 attempts per OTP per phone
/api/auth/login         → 10 requests per minute per IP

# Transaction endpoints
/api/transfer           → 30 per hour per user
/api/beneficiary/add    → 5 per day per user

# Query endpoints
/api/balance            → 60 per minute per user
/api/transactions       → 30 per minute per user
💡
TIP
Use Redis-backed rate limiting, not in-memory counters. In a multi-instance deployment (which every fintech should have), in-memory counters don't share state across instances. An attacker can simply rotate between instances to bypass limits.

Section 5: Data Exposure Prevention

#CheckPriorityOWASP APIStatus
5.1No PII in URL parametersCriticalAPI3
5.2Mask Aadhaar (show last 4 digits only)CriticalAPI3
5.3Mask PAN (show first and last 2 chars)CriticalAPI3
5.4No sensitive data in logsCriticalAPI3
5.5API responses return only required fieldsHighAPI3
5.6Encrypt sensitive fields at rest (AES-256)HighAPI3
5.7TLS 1.2+ enforced on all endpointsCriticalAPI7
typescript
// Data masking utility for Indian fintech
const mask = {
  aadhaar: (num: string) => 'XXXX-XXXX-' + num.slice(-4),
  pan: (pan: string) => pan.slice(0, 2) + 'XXXXXX' + pan.slice(-2),
  phone: (phone: string) => 'XXXXX' + phone.slice(-5),
  email: (email: string) => {
    const [user, domain] = email.split('@');
    return user[0] + '***@' + domain;
  },
  account: (acc: string) => 'XXXXXXXXXX' + acc.slice(-4),
  upi: (upi: string) => upi.split('@')[0].slice(0, 2) + '***@' + upi.split('@')[1],
};

// Usage in API response
res.json({
  name: user.name,
  aadhaar: mask.aadhaar(user.aadhaar), // XXXX-XXXX-4589
  pan: mask.pan(user.pan),              // AB XXXXXX9Z
  phone: mask.phone(user.phone),        // XXXXX67890
});

Section 6: Logging & Monitoring (RBI/CERT-In Compliance)

#CheckPriorityRegulationStatus
6.1Log all authentication attemptsCriticalRBI
6.2Log all transaction API callsCriticalRBI
6.3Log all admin actionsCriticalRBI
6.4No sensitive data in logs (PII, tokens)CriticalDPDP
6.5Log retention ≥ 180 daysHighCERT-In
6.6Tamper-proof log storageHighRBI
6.7Real-time alerting on anomaliesHighRBI
6.86-hour incident reporting capabilityCriticalCERT-In
sequenceDiagram participant User participant API participant Logger participant SIEM participant Alert User->>API: POST /api/transfer API->>Logger: Log request (masked PII) API->>API: Process transaction API->>Logger: Log response + status Logger->>SIEM: Forward logs SIEM->>SIEM: Anomaly detection alt Anomaly Detected SIEM->>Alert: Trigger alert Alert->>Alert: Notify security team end API-->>User: Response

Section 7: Infrastructure Security

#CheckPriorityStatus
7.1API gateway with WAF enabledCritical
7.2DDoS protection (CloudFlare/AWS Shield)Critical
7.3Separate API domain (api.yourdomain.com)High
7.4API versioning (/v1/, /v2/)Medium
7.5Health/debug endpoints not publicly accessibleCritical
7.6CORS configured for specific origins onlyHigh
7.7API documentation not publicly accessibleMedium
ℹ️
INFO
RBI's cybersecurity framework mandates that all regulated entities must conduct VAPT assessments at least once a year for critical systems. For fintech operating under PPI, NBFC, or payment aggregator licenses, API security testing is not optional — it's a regulatory requirement.

Know your vulnerabilities before attackers do

Run a free VAPT scan — takes 5 minutes, no signup required.

Book Your Free Scan

RBI Compliance Mapping

RBI RequirementAPI Security Measure
Strong authenticationOAuth 2.0 + MFA for high-value transactions
Transaction monitoringReal-time API logging + anomaly detection
Data encryptionTLS 1.2+ in transit, AES-256 at rest
Access controlRBAC + object-level authorization
Incident reporting6-hour CERT-In notification pipeline
Audit trailImmutable API request/response logs
Vendor risk managementThird-party API security assessment
🎯Key Takeaway
Key Takeaways:
  1. BOLA/IDOR is the #1 fintech API vulnerability — check every endpoint for authorization
  2. Never return OTP in the API response — this is shockingly common in Indian fintech
  3. Implement Redis-backed rate limiting — in-memory counters fail in multi-instance deployments
  4. Mask all PII in API responses — Aadhaar, PAN, phone numbers, account numbers
  5. Log everything but log safely — no PII in logs, 180-day retention for CERT-In
  6. RBI mandates annual VAPT for regulated entities — API testing is a regulatory requirement
  7. Use schema validation (Zod/Joi) on every input — never trust the client

Building a fintech product? Get a free API security assessment from Bachao.AI — we test against OWASP API Top 10 and RBI compliance requirements.

Shouvik Mukherjee, Founder of Bachao.AI

Shouvik Mukherjee

Founder

Ex-enterprise architect turned cybersecurity founder. Built systems for Fortune 500s, now making enterprise-grade security accessible to every Indian business. Writes about threats targeting Indian SMBs, practical defenses, and the DPDP Act.

Connect on LinkedIn

Get cybersecurity insights for Indian SMBs

Weekly vulnerability alerts, DPDP compliance tips, and security guides. No spam — unsubscribe anytime.

We respect your privacy. Your email is never shared.

Application-layer testing against the OWASP Top 10

Free automated scan — risk score in under 2 hours. No credit card required.

Test Your Application
Find your vulnerabilitiesStart free scan →