Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required (VERSION 3.9...3.30)

project(maxminddb
LANGUAGES C
VERSION 1.12.2
VERSION 1.13.1
)
set(MAXMINDDB_SOVERSION 0.0.7)
set(CMAKE_C_STANDARD 99)
Expand Down
6 changes: 5 additions & 1 deletion Changes.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
## 1.13.0
## 1.13.1 - 2026-02-24

- Re-release for Ubuntu PPA. No code changes.

## 1.13.0 - 2026-02-24

- `MMDB_get_entry_data_list()` now validates that the claimed array/map size is
plausible given the remaining bytes in the data section. A crafted database
Expand Down
2 changes: 1 addition & 1 deletion NOTICE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright 2013-2025 MaxMind, Inc.
Copyright 2013-2026 MaxMind, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
5 changes: 2 additions & 3 deletions README.dev.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,8 @@ version updated promptly for some reason.

# Prerequisites for releasing

- Required packages (Ubuntu Artful): vim git-core dput build-essential autoconf
automake libtool git-buildpackage libfile-slurp-perl pandoc dirmngr
libfile-slurp-tiny-perl libdatetime-perl debhelper dh-autoreconf
- Required packages (Ubuntu 25.10): vim git-core dput build-essential autoconf
automake libtool git-buildpackage lowdown dirmngr debhelper dh-autoreconf
libipc-run3-perl libtest-output-perl devscripts
- Install [gh](https://github.com/cli/cli/releases).
- GitHub ssh key (e.g. in `~/.ssh/id_rsa`)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ Use `make safedist` to check the resulting tarball.

# Copyright and License

Copyright 2013-2025 MaxMind, Inc.
Copyright 2013-2026 MaxMind, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of the
Expand Down
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Process this file with autoconf to produce a configure script.

AC_PREREQ([2.63])
AC_INIT([libmaxminddb], [1.12.2], [support@maxmind.com])
AC_INIT([libmaxminddb], [1.13.1], [support@maxmind.com])
AC_CONFIG_SRCDIR([include/maxminddb.h])
AC_CONFIG_HEADERS([config.h include/maxminddb_config.h])

Expand Down
28 changes: 19 additions & 9 deletions dev-bin/ppa-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,22 @@ set -e
set -x
set -u

DISTS=( groovy focal bionic xenial trusty )
DISTS=( questing noble jammy )

VERSION=$(perl -MFile::Slurp::Tiny=read_file -MDateTime <<EOF
use v5.16;
my \$log = read_file(q{Changes.md});
\$log =~ /^## (\d+\.\d+\.\d+) - (\d{4}-\d{2}-\d{2})/;
die 'Release time is not today!' unless DateTime->now->ymd eq \$2;
say \$1;
EOF
)
changelog_header=$(head -n 3 Changes.md)
if [[ ! $changelog_header =~ ^##\ ([0-9]+\.[0-9]+\.[0-9]+)\ -\ ([0-9]{4}-[0-9]{2}-[0-9]{2}) ]]; then
echo "Could not find version in Changes.md!"
exit 1
fi
VERSION="${BASH_REMATCH[1]}"
Comment on lines +9 to +14

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

This change removes the check that ensures the release date in Changes.md is today. This was present in the previous Perl implementation and is a useful safeguard. Additionally, the version parsing regex has a few issues: it doesn't handle pre-release versions, and it uses . which matches any character instead of a literal dot (\.). Using head -n 1 is also more direct than head -n 3. I suggest restoring the date check and using a more robust and correct regex for consistency and safety.

Suggested change
changelog_header=$(head -n 3 Changes.md)
if [[ ! $changelog_header =~ ^##\ ([0-9]+\.[0-9]+\.[0-9]+)\ -\ ([0-9]{4}-[0-9]{2}-[0-9]{2}) ]]; then
echo "Could not find version in Changes.md!"
exit 1
fi
VERSION="${BASH_REMATCH[1]}"
changelog_header=$(head -n 1 Changes.md)
if [[ ! $changelog_header =~ ^##\ ([0-9]+\\.[0-9]+\\.[0-9]+(?:-[a-zA-Z0-9.-]*)?)\ -\ ([0-9]{4}-[0-9]{2}-[0-9]{2}) ]]; then
echo "Could not find version and date in Changes.md header!"
exit 1
fi
VERSION="${BASH_REMATCH[1]}"
DATE="${BASH_REMATCH[2]}"
if [[ "$DATE" != "$(date +"%Y-%m-%d")" ]]; then
echo "Release date ($DATE) in Changes.md is not today!"
exit 1
fi

DATE="${BASH_REMATCH[2]}"

if [[ "$DATE" != "$(date +"%Y-%m-%d")" ]]; then
echo "$DATE is not today!"
exit 1
fi

git push

RESULTS=/tmp/build-libmaxminddb-results/
SRCDIR="$RESULTS/libmaxminddb"
Expand Down Expand Up @@ -51,3 +57,7 @@ dch -v "$VERSION-0+maxmind1" -D "${DISTS[0]}" -u low "New upstream release."
git add debian/changelog
git commit -m "Update debian/changelog for $VERSION"
git push

popd

git pull
17 changes: 7 additions & 10 deletions dev-bin/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -81,17 +81,14 @@ if [ -n "$(git status --porcelain)" ]; then
exit 1
fi

old_version=$(
perl -MFile::Slurp=read_file <<EOF
use v5.16;
my \$conf = read_file(q{configure.ac});
\$conf =~ /AC_INIT.+\[(\d+\.\d+\.\d+)\]/;
say \$1;
EOF
)
ac_init=$(grep AC_INIT configure.ac)
if [[ ! $ac_init =~ \[([0-9]+\.[0-9]+\.[0-9]+)\] ]]; then

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The regex for extracting the old version from configure.ac has a couple of issues: it doesn't account for pre-release tags (e.g., 1.13.0-alpha.1), and it uses . which matches any character instead of a literal dot (\.). To make the script more robust and consistent with how the new version is parsed from Changes.md, consider updating the regex.

Suggested change
if [[ ! $ac_init =~ \[([0-9]+\.[0-9]+\.[0-9]+)\] ]]; then
if [[ ! $ac_init =~ \["([0-9]+\\.[0-9]+\\.[0-9]+(?:-[a-zA-Z0-9.-]*)?)"\] ]]; then

echo "Could not find version in configure.ac!"
exit 1
fi
old_version="${BASH_REMATCH[1]}"

perl -MFile::Slurp=edit_file -e \
"edit_file { s/\Q$old_version/$version/g } \$_ for qw( configure.ac include/maxminddb.h CMakeLists.txt )"
perl -pi -e "s/\Q$old_version/$version/g" configure.ac include/maxminddb.h CMakeLists.txt

if [ -n "$(git status --porcelain)" ]; then
git diff
Expand Down
2 changes: 1 addition & 1 deletion doc/libmaxminddb.md
Original file line number Diff line number Diff line change
Expand Up @@ -896,7 +896,7 @@ This library was written by Boris Zentner (bzentner@maxmind.com) and Dave Rolsky

# COPYRIGHT AND LICENSE

Copyright 2013-2025 MaxMind, Inc.
Copyright 2013-2026 MaxMind, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of the
Expand Down
2 changes: 1 addition & 1 deletion doc/mmdblookup.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ This utility was written by Boris Zentner (bzentner@maxmind.com) and Dave Rolsky

# COPYRIGHT AND LICENSE

Copyright 2013-2025 MaxMind, Inc.
Copyright 2013-2026 MaxMind, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of the
Expand Down
Loading