When a police request or a DoT query asks “who used this IP address at this time?”, an ISP must be able to answer. If many customers share one public IP address through NAT, the answer depends on logs that most small ISPs never check until the day they need them. This guide explains which logs an ISP in India should keep, for how long under the licence text, why NAT logs need ports and accurate time, and how to store logs safely so they are complete when someone asks.
This is general information based on the DoT Unified Licence (updated to 31 March 2024) and CERT-In’s 2022 directions. Your exact duties depend on your licence or authorisation and current instructions. It is not legal advice.
Which logs an ISP needs to keep
| Log | What it shows | Minimum period in the licence text |
|---|---|---|
| IPDR (IP Detail Record) | Records of internet use, kept in the format DoT sets through its instructions | At least two years (Internet Service clause 7.1) |
| Log-in and log-out details | When each subscriber connected and disconnected, for services such as internet access | At least two years (Internet Service clause 7.2) |
| Commercial records, CDR, EDR and IPDR | Records of communications on the network | Archived for at least two years (general clause 39.20) |
| ILL customer’s NAT syslog | Which user inside the customer’s network used the IP, where many users share one internet leased line | The ISP must advise the ILL customer to keep it for at least one year (Internet Service clause 7.4) |
| Logs of your ICT systems | Logs from systems such as firewalls, servers and network devices | A rolling 180 days under CERT-In’s 2022 directions, for entities covered by them |
DoT raised the IPDR and log-in/log-out period from one year to two years through licence amendments around December 2021 and January 2022. The licence also says that IPDR parameters are set by DoT’s directions from time to time, so the exact fields come from those instructions, not from the licence text alone.
New authorisation and migration rules were notified in June 2026. If your ISP has migrated, or is working under a newer authorisation, check the terms that apply to you. If you work as a franchise or partner of a licensed ISP, agree in writing who keeps which logs.
Why NAT makes logging harder
With NAT, many customers share one public IP address. When an outside website or agency gives you a public IP address and a time, the IP alone cannot tell you which customer it was. You need to match the public IP, the port and the exact time to the customer’s private IP, and then the private IP to the customer’s login.
| Step | Record needed | Example question it answers |
|---|---|---|
| 1 | NAT log: public IP, public port, private IP, start and end time | Which private IP used public IP 203.0.113.10, port 40512, at 10:15:30? |
| 2 | Session log: private IP, username, start and end time | Which subscriber had private IP 100.64.12.5 at that time? |
| 3 | Subscriber record: username to customer details | Who is the customer behind username ABC123? |
The IP addresses above are documentation examples. If any link in the chain is missing, such as ports not logged, wrong time on the router or sessions not recorded, you may not be able to identify the user.
The same applies to an internet leased line used by many people inside an office. That is why the licence asks the ISP to advise ILL customers to keep their own NAT logs. See our guide to selling broadband to shops and offices for more on ILL duties.
What a useful log record should contain
Follow the fields set by DoT’s IPDR instructions. As a practical check, make sure each type of record lets you answer the questions above:
- Session logs: username or customer ID, private or public IP assigned, start time, end time, NAS or access device, and the device identifier your network records, such as a MAC address.
- NAT logs: private IP and port, public IP and port, protocol, and the start and end time of the translation or port block.
- Time: date, time and time zone on every record.
- Source: which router or device created the record.
Some routers can assign a block of ports to each user instead of logging every single connection. This can reduce log volume a lot. If you use it, make sure the block start and end times are logged, and check the approach against DoT’s instructions.
Get the time right
A log that is a few minutes wrong can point to the wrong customer, especially with NAT where ports are reused quickly.
- Sync every router, NAS, server and log system with a reliable time source using NTP.
- Use one time zone for all logs, or record the time zone with every entry.
- Check the time on your devices regularly, especially after a power cut or reboot.
- When answering a request, confirm the time zone in the request before searching.
Store logs safely
Logs contain personal data and are evidence. Treat them carefully.
- Send logs off the router. Routers have little storage and may lose logs on restart. Send them to a separate log server or system.
- Keep more than one copy. Keep a backup on a different system or location, and test that you can restore it.
- Limit access. Only a few named people should be able to search logs. Record who searched what and when.
- Protect from changes. Store logs so they cannot be edited, and protect them with checksums or write-once storage where possible.
- Watch for gaps. Set an alert if logs stop arriving from any router.
- Delete on schedule. Keep logs for the required period, then delete them, unless you have been asked to preserve them for longer.
Under the Digital Personal Data Protection Act, 2023, personal data should be kept only as long as needed or required by law. A clear retention schedule helps with both duties.
Plan your storage
NAT logs can grow very fast. To estimate your storage:
- Measure how many log lines each router creates in a normal busy day.
- Multiply by the size of one compressed line and by the number of days you must keep.
- Add space for backups and growth in subscribers.
- Review the estimate every few months.
Compressing old logs and using port block allocation can make a large difference. Test that compressed logs can still be searched quickly.
How to answer a log request
- Check the request. Confirm it comes through your nodal officer or the proper channel, and is from an authorised agency.
- Note the details. Public IP, port, date, time and time zone. Ask for the port if it is missing and you use NAT.
- Search carefully. Match NAT logs to session logs to the subscriber record, using a small time window.
- Record your work. Note who searched, what was found and what was shared.
- Share only what is asked, through the secure channel required.
- Preserve records related to the request if you are asked to.
Have a written procedure and train at least two people, so requests are handled correctly when one person is away.
Common mistakes
- Keeping logs only on the router, where they are lost on restart or overwritten.
- Not logging ports with NAT, so a public IP cannot be matched to one user.
- Wrong or unsynced time on routers and servers.
- No alert when logging stops, so gaps are found only when a request comes.
- Giving many staff access to search logs.
- Forgetting ILL customers, who must be advised to keep their own NAT logs where many users share the line.
- Never testing a search until a real request arrives.
Log retention checklist
| Task | Done? |
|---|---|
| Confirm which licence or authorisation terms apply to your ISP | ☐ |
| Session logs with username, IP and start and end time | ☐ |
| NAT logs with public and private IP, ports and time, if you use NAT | ☐ |
| IPDR kept in the format set by DoT’s instructions | ☐ |
| All devices synced with NTP, with a clear time zone | ☐ |
| Logs sent off the router to a separate system, with a backup | ☐ |
| Access limited and searches recorded | ☐ |
| Alert set if logs stop arriving | ☐ |
| Storage planned for the full retention period | ☐ |
| ILL customers advised in writing to keep NAT logs | ☐ |
| Written procedure for log requests, with two trained people | ☐ |
| A test search done every quarter | ☐ |
How ISPMate helps with logs
ISPMate is cloud-based ISP billing software for internet service providers in India. Its logs and usage features include:
- CTS/NAT logs stored and searchable
- Auth logs for every login attempt
- Concurrent session logs
- Real-time and history usage graph for each subscriber
- Subscriber records with digital CAF and KYC documents, linked to each connection
- RADIUS integration with MikroTik and other NAS
During the demo, tell us your network setup and how long you need to keep logs. We will show how ISPMate stores and searches them for your network.
Frequently asked questions
How long must an ISP in India keep IPDR and login logs?
The DoT Unified Licence, updated to 31 March 2024, says ISPs must keep IPDR for internet and the log-in and log-out details of subscribers for at least two years. Check the terms of your own licence or authorisation and current DoT instructions.
Why do NAT logs need port numbers?
With NAT, many customers share one public IP address. To find which customer used it at a given moment, you need the public IP, the port and the exact time, matched to the customer’s private IP and login. Without ports, the public IP may point to many customers.
Do internet leased line customers need to keep NAT logs?
Where many users share one internet leased line, the Unified Licence asks the ISP to advise the ILL customer to keep IP usage or NAT syslog for at least one year, and to take steps to make sure they do.
What is the CERT-In 180-day log rule?
CERT-In’s directions of 28 April 2022 require covered entities, including service providers, to enable logs of their ICT systems and keep them securely for a rolling 180 days. This is separate from the licence duty to keep IPDR and login logs for two years.
How should ISPs store logs safely?
Send logs off routers to a separate system, sync device time with NTP, keep a backup, limit and record who can search logs, protect logs from changes, set alerts for gaps, and delete them on schedule after the required period.
Need searchable session and NAT logs linked to every subscriber? Book a free ISPMate demo or call +91-9310313545.
Sources: DoT Unified Licence agreement, updated to 31 March 2024 (clause 39.20 and Internet Service clauses 7.1, 7.2 and 7.4); CERT-In directions under section 70B(6) of the IT Act, 28 April 2022, and CERT-In FAQs, 18 May 2022; DoT press release on authorisations and licence migration, 25 June 2026. This is general information, not legal advice. Last reviewed: December 2026.
