Skip to content

Releases

0.33.0

Choose a tag to compare

@oschwald oschwald released this 12 Nov 14:44
Immutable release. Only release title and notes can be modified.
a784433
  • Breaking: deserialize_newtype_struct now calls the visitor's
    visit_newtype_struct. Before, it passed the inner value straight to
    methods such as visit_str or visit_map. Derived Serde newtypes around
    scalars, strings, and records now deserialize, including nested wrappers
    and pointer-backed values. A hand-written visitor that does not implement
    visit_newtype_struct now fails with an invalid type error. See
    UPGRADING.md.
  • Declared a minimum supported Rust version (MSRV) of 1.77 in Cargo.toml.
    CI now builds the library with that version.
  • Fixed networks() and within() dropping IPv6 networks that share a terminal
    data record or no-data sentinel with the IPv4 search start. IPv4 subtree
    aliases are still filtered by default.
  • Fixed decoding of four-byte data pointers with control bytes 0x3D-0x3F.
    The decoder read their ignored low bits as an extended payload length and
    could return the wrong value or an error. Four-byte pointers with other
    control bytes decoded correctly.
  • Added automatic prefix tables to speed up lookups, using 1,360 bytes per
    reader (8 IPv4 bits and 4 IPv6 bits). Building them adds a small one-time
    cost to opening a reader.
  • Reduced decoder error-handling code on successful paths. Validation and
    error behavior are unchanged.
  • Added a workload benchmark that separates tree traversal, record decoding,
    and reader construction, with hit counts and JSON timing results.

0.32.0

Choose a tag to compare

@oschwald oschwald released this 12 Sep 17:22
Immutable release. Only release title and notes can be modified.
b0e5d54
  • Reused precharged map-key bytes for raw identifier decoding, avoiding a
    second header parse while preserving payload limits and other Serde entry
    points. Added raw-string adapter and generic JSON decoding benchmarks.
  • Breaking: Removed the simdutf8 feature and its optional dependency. It did
    not improve lookup performance in benchmarks using production GeoIP2 City
    and Country databases. Remove simdutf8 from dependency feature lists when
    upgrading.
  • Improved record decoding performance by reducing internal error storage
    and streamlining pointer and payload decoding. Public error types and
    validation limits are unchanged.
  • Fixed decoder cursor restoration when a typed pointer exceeds the nesting
    limit.
  • Improved search-tree lookup performance for 24-bit and 28-bit databases
    by reading each child pointer from a single word within the node.
  • Improved decode_path() performance by specializing map-key header
    decoding for inline strings and all pointer widths, including long keys.

0.31.0

Choose a tag to compare

@oschwald oschwald released this 07 Sep 17:04
Immutable release. Only release title and notes can be modified.
68a981d
  • Fixed a denial-of-service issue when decoding records or metadata. A
    crafted database could repeatedly reference shared data, causing excessive
    CPU and memory use. Decoding now limits the number of values and the amount
    of string and byte data expanded in a single operation. Operations that
    exceed these limits return MaxMindDbError::ResourceLimit.
  • Limited subdivision lists in the built-in City and Enterprise types to 32
    entries to prevent excessive allocation from untrusted data.
  • Reader::verify() now checks data referenced by unknown metadata fields.
  • Limited the work performed by Reader::verify() to prevent excessive CPU
    use from databases with overlapping string payloads. Verification returns
    MaxMindDbError::ResourceLimit when this limit is exceeded.
  • Improved record decoding performance by accelerating short ASCII string
    validation and inlining decoding entry points.

0.30.3

Choose a tag to compare

@oschwald oschwald released this 24 Aug 02:51
Immutable release. Only release title and notes can be modified.
36fe9cd
  • Fixed typed decoding of malformed overflowing extended types to consistently
    return an InvalidDatabase error.

0.30.2

Choose a tag to compare

@oschwald oschwald released this 24 Aug 01:39
Immutable release. Only release title and notes can be modified.
bcae3e0
  • No user-visible changes. This release republishes 0.30.1 because its
    immutable GitHub release was deleted.

0.30.0

Choose a tag to compare

@oschwald oschwald released this 19 Jul 00:39
Immutable release. Only release title and notes can be modified.
fceaa66
  • Added deserialize_any_with_raw_strings() for Serde-based format adapters
    to validate MMDB strings while constructing another runtime's native string
    type, avoiding duplicate UTF-8 validation without unsafe Rust. Adapters
    remain responsible for strict UTF-8 validation.
  • Fixed network iteration on cyclic or over-deep corrupt search trees so it
    returns an error instead of looping indefinitely.
  • Fixed decode_path() error rendering for extreme negative indexes and
    reduced path traversal header parsing.
  • Removed decoder logging checks from hot deserialization paths.
  • Fixed verify() to validate shared data-section pointer targets once, reject
    pointer cycles, invalid scalar encodings, and impossible container sizes.

0.29.0

Choose a tag to compare

@oschwald oschwald released this 28 Jun 23:05
Immutable release. Only release title and notes can be modified.
5c656d4
  • Breaking: Metadata::build_time() now returns
    Result<SystemTime, MaxMindDbError> instead of panicking on
    unrepresentable timestamps, and databases whose build_epoch cannot be
    represented as SystemTime are rejected as invalid during open and verify.
  • Breaking: Reader::metadata is now private. Use Reader::metadata() to
    access validated metadata by shared reference.
  • Breaking: Opening a database now rejects unsupported major format versions,
    unsupported IP versions, and zero-node search trees. Minor format versions
    are still accepted for forward compatibility.
  • Fixed: within() and networks() now handle IPv6 databases without an
    IPv4 subtree without reading terminal data nodes as tree nodes or
    panicking while formatting low IPv6 networks.
  • Fixed: Skipping ignored or unknown fields now enforces data-section
    bounds and the maximum nesting depth instead of accepting truncated
    values or overflowing the stack on deeply nested corrupt data.
  • Internal: Added focused benchmarks for network iteration and serde
    unknown-field skipping, plus metadata build-time conversion, to guard
    performance-sensitive fixes.
  • Documentation: Fixed intra-doc links so docs build with warnings denied,
    and added a CI check to keep them passing.

0.28.1

Choose a tag to compare

@oschwald oschwald released this 26 Apr 19:58
Immutable release. Only release title and notes can be modified.
8e86128
  • Fixed: Databases with an impossible declared search tree size are now
    rejected during open/verify instead of causing runaway allocation
    during validation.
  • Fixed: within() now rejects IPv6 CIDRs on IPv4-only databases instead
    of yielding unrelated networks.
  • Fixed: Verification now rejects truncated scalar/string payloads instead
    of skipping past them and reporting the database as valid.
  • Fixed: LookupResult::network() now uses the reader's measured IPv4
    subtree depth instead of assuming it always begins at bit 96.

0.28.0

Choose a tag to compare

@oschwald oschwald released this 25 Apr 18:12
Immutable release. Only release title and notes can be modified.
429baa5
  • Performance improvement: Faster search-tree traversal by dispatching
    on the database's record size to monomorphized node readers, replacing
    per-step branching on the record size.
  • Performance improvement: Direct deserialization of scalars, sequences,
    maps, and structs through dedicated fast paths instead of routing
    through deserialize_any.
  • Performance improvement: IPv4 and IPv6 lookups dispatch to dedicated
    paths, avoiding per-call address-kind checks on the hot path.
  • Behavior change: Deserializing a database array into a tuple or
    tuple struct now returns a decoding error when the lengths do not
    match. Previously the mismatch was silently ignored.
  • Fixed: A corrupt data pointer that would underflow during resolution
    now returns an InvalidDatabase error instead of panicking.

0.27.3

Choose a tag to compare

@oschwald oschwald released this 16 Feb 14:29
Immutable release. Only release title and notes can be modified.
15b48e9
  • Removed the release_max_level_info feature from the log dependency, as
    libraries should not set a global release log-level cap. Pull request by
    monosans. GitHub #110.