Card testing log analysis is the review of payment gateway, authorization, and web server logs to find the small, rapid, repeated transaction attempts that fraudsters use to check whether stolen card numbers are valid. The analysis focuses on decline rates, BIN diversity, IP velocity, and attempt timing rather than on individual orders. Done well, it converts raw log lines into an early warning that lets a merchant block an attack before the fraudster moves to high-value purchases.
What does card testing look like in transaction logs?
Card testing produces a signature that is easy to miss if you only review completed sales. The pattern is volume without intent: many attempts, tiny amounts, and a high share of declines.
Log Analysis for Card Testing Detection: A Practical Guide
- A sharp rise in authorization attempts from a small set of IP addresses, devices, or ASNs.
- Many different card BINs used against one merchant account in a short window.
- Repeated low-value amounts, often under a few dollars, with no shipping or account history.
- High rates of CVV mismatch, AVS failure, or do-not-honor response codes.
- Near-identical user agents, headers, or checkout timing across many attempts.
- Sequential or auto-generated email addresses, or guest checkout used almost exclusively.
Which log sources do you need for card testing analysis?
Detection improves when payment data is joined to the request data that produced it. A single source rarely shows the whole pattern.
- Gateway and processor authorization logs, including response codes and decline reasons.
- Web and application server logs with IP, user agent, session, and endpoint paths.
- WAF, CDN, and bot-management logs that show request velocity and reputation signals.
- Order and account tables linking attempts to emails, devices, and payment methods.
Which metrics reveal card testing in a log file?
Metrics matter more than any single suspicious record, because legitimate customers can also trigger a decline. Track these per IP, device fingerprint, and email over rolling windows.
How to Analyze Logs for Card Testing: A Merchant Detection Guide
- Authorization attempts per identifier per hour and per day.
- Decline rate per identifier, compared with the merchant baseline.
- Count of unique BINs and unique card fingerprints per identifier.
- Median seconds between consecutive attempts from the same source.
- Share of attempts at the lowest configured price point or minimum amount.
- Ratio of checkout page loads to completed payment submissions.
How do you build a card testing detection query?
- Normalize timestamps and IP formats across gateway and server logs.
- Extract a stable key: IP, device ID, email, or card fingerprint.
- Group attempts by that key into five-minute and one-hour buckets.
- Compute attempt counts, decline rate, and unique BIN counts per bucket.
- Flag buckets that exceed your baseline thresholds by a set margin.
- Join flagged buckets to order data to separate attacks from real customer friction.
What thresholds and baselines should you set?
There is no universal number, because normal decline rates vary by industry, geography, and payment method. Establish a 30-day baseline per merchant account, then alert on deviations such as a decline rate several times the norm or a sudden rise in unique BINs from one source. Tune thresholds monthly so legitimate bulk buyers and subscription retries do not generate noise.
How should you respond to a confirmed card testing attack?
- Rate limit or block the offending IPs, ASNs, and device fingerprints.
- Add a challenge such as CAPTCHA or device verification at checkout.
- Raise the minimum transaction amount temporarily to remove the attacker's economics.
- Notify your acquirer and payment processor with the log evidence.
- Refund and void affected authorizations, then monitor for a shift to new identifiers.
What mistakes weaken card testing log analysis?
Reviewing only successful orders hides the attack, because most test attempts are declined. Short log retention, usually under 30 days, makes it impossible to compare against a baseline. Alerting on raw volume alone floods analysts with false positives, so pair volume with decline rate and BIN diversity before escalating.
How long should you retain logs for card testing analysis?
Retain authorization and access logs for at least 90 days, and keep aggregated metrics for a year. Card testing campaigns often return with new infrastructure, and historical baselines are what let you recognize the same pattern quickly.