Skip to content

GeoIP processor: Option to enable private IP address lookupsΒ #6079

Closed

Description

Is your feature request related to a problem? Please describe.
Currently, the GeoIP processor in Data Prepper ignores private IP addresses. This makes it difficult to enrich internal network traffic (e.g., NetFlow or audit logs) with metadata from an internal IP Address Management (IPAM) system, such as office, datacenter, or department information

Describe the solution you'd like
Introduce a configuration option in the geoip_service that allows processing of private IP addresses. For example:

extensions:
  geoip_service:
    maxmind:
      lookup_private_addresses: true

This would require an update to GeoInetAddress.java

class GeoInetAddress {

    static Optional<InetAddress> usableInetFromString(final String ipAddress) {
        final InetAddress address;
        try {
            address = InetAddresses.forString(ipAddress);
        } catch (final IllegalArgumentException e) {
            return Optional.empty();
        }
        if (isPublicIpAddress(address) OR LOOKUP_PRIVATE_ADDRESS)
            return Optional.of(address);
        return Optional.empty();
    }

Describe alternatives you've considered (Optional)
An alternative is to use the add_entries processor in combination with add_when and cidrContains()
However, this approach is significantly slower and becomes impractical with large numbers of CIDR ranges, especially for NetFlow enrichment.

Additional context
It is straightforward to enrich MMDB files with internal IPAM data using scripts like
Enriching MMDB files with your own data using Go

As a further enhancement, it would be useful to allow reading custom fields from MMDB files (not only geo-related data). This would make it possible to attach metadata such as department or business unit information to a given CIDR block.

Activity

  1. graytaylor0 commented on Sep 16, 2025

    @graytaylor0
    Member

    Thanks for creating this issue! Would you be interested in creating a pull request for this enhancement?

  2. srikanthpadakanti commented on Apr 5, 2026

    @srikanthpadakanti
    Collaborator

    @graytaylor0 Please assign this to me. Thanks

  3. dlvenable commented on Apr 6, 2026

    @dlvenable
    Member

    @srikanthpadakanti , Thanks for working this. Are you going to work on the lookup_private_addresses part or the custom MMDB lookup part?

  4. srikanthpadakanti commented on Apr 6, 2026

    @srikanthpadakanti
    Collaborator

    @dlvenable I'll be working on the lookup_private_addresses part. The custom MMDB field lookup mentioned in the issue is a separate enhancement and can be tracked in its own issue.

  5. added this to the v2.16 milestone on Jul 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type

Projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions