Skip to content

Conversation

ngie-eign
Copy link
Contributor

@ngie-eign ngie-eign commented Sep 5, 2025

Before this change all manpages would contain the date when pod2man was
run. This resulted in outputs that differed between builds--or
potentially across a single build if the host clock "ticked" to the next
day when the build was being run.

This commit modifies the manpage generation process as follows:

  • The date all manpages were generated will be normalized to a single
    date instead of a potentially rolling date.
  • The release date specified in VERSION.dat is used instead of the
    date/time when pod2man was executed OR--in the event a date
    isn't specified in VERSION.dat--the time when the Makefiles were
    last regenerated.

Embedding a consistent date into the generated manpages helps ensure that
the build process as a whole is more repeatable and helps ensure that
release versions of OpenSSL create artifacts consistent with the date
that the official release was cut.

Closes: #28323

@openssl-machine openssl-machine added the hold: cla required The contributor needs to submit a license agreement label Sep 5, 2025
@openssl-machine openssl-machine removed the hold: cla required The contributor needs to submit a license agreement label Sep 5, 2025
@ngie-eign ngie-eign changed the title Make the OpenSSL build more repeatable Make the build process more repeatable Sep 5, 2025
@openssl-machine openssl-machine added the hold: cla required The contributor needs to submit a license agreement label Sep 5, 2025
@levitte levitte added branch: master Merge to master branch branch: 3.0 Merge to openssl-3.0 branch branch: 3.3 Merge to openssl-3.3 branch: 3.4 Merge to openssl-3.4 branch: 3.5 Merge to openssl-3.5 branch: 3.6 Merge to openssl-3.6 branch: 3.2 Merge to openssl-3.2 labels Sep 5, 2025
@kroeckx
Copy link
Member

kroeckx commented Sep 5, 2025

I'm wondering what the effect is when VERSION.dat doesn't contain a date, like in the current branch.

In Debian, we set the SOURCE_DATE_EPOCH, which is based on the debian/changelog file. It would now get an other date, when upstream released it, instead of when Debian did, which looks fine to me.

@t8m t8m added approval: review pending This pull request needs review by a committer triaged: bug The issue/pr is/fixes a bug tests: exempted The PR is exempt from requirements for testing cla: trivial One of the commits is marked as 'CLA: trivial' and removed hold: cla required The contributor needs to submit a license agreement labels Sep 5, 2025
t8m
t8m previously approved these changes Sep 5, 2025
Copy link
Member

@t8m t8m left a comment

Choose a reason for hiding this comment

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

It is borderline on what we would accept with CLA: trivial. Please consider signing a CLA. https://openssl-library.org/policies/cla/index.html

@levitte
Copy link
Member

levitte commented Sep 5, 2025

I'm wondering what the effect is when VERSION.dat doesn't contain a date, like in the current branch.

my $t = $config{"release_date"}
      ? Time::Piece->strptime($config{"release_date"}, "%d %b %Y")
      : localtime;
$t->strftime("%Y-%m-%d")

When the release date ($config{"release_date"}) is empty, it's falsy, so localtime will be used to determine the date.

@levitte
Copy link
Member

levitte commented Sep 5, 2025

It is borderline on what we would accept with CLA: trivial. Please consider signing a CLA. https://openssl-library.org/policies/cla/index.html

I could accept it with CLA: trivial

@kroeckx
Copy link
Member

kroeckx commented Sep 5, 2025

So if we ever decide to shipped a non-released version, which seems unlikely, this will make it non-reproducible.

@ngie-eign
Copy link
Contributor Author

It is borderline on what we would accept with CLA: trivial. Please consider signing a CLA. https://openssl-library.org/policies/cla/index.html

I could accept it with CLA: trivial

I submitted my individual CLA just last night. The second commit doesn't contain that metadata because I planned on squashing the second commit to the first one (which has the metadata) prior to merge.

@ngie-eign
Copy link
Contributor Author

So if we ever decide to shipped a non-released version, which seems unlikely, this will make it non-reproducible.

Yes. That seems extremely unlikely though, since releasing sources without a fixed version to the public would be contradictory.

Background for other readers: multiple OSes out there (I can speak directly to FreeBSD and a FreeBSD variant I develop on for work) keep patches which normalize dates to deterministic values in order to make builds reproducible. This is sometimes done for to simplify binary patching processes.

@openssl-machine openssl-machine added the hold: cla required The contributor needs to submit a license agreement label Sep 5, 2025
openssl-machine pushed a commit that referenced this pull request Sep 9, 2025
Before this change all manpages would contain the date when pod2man was
run. This resulted in outputs that differed between builds--or
potentially across a single build if the host clock "ticked" to the next
day when the build was being run.

This commit modifies the manpage generation process as follows:
- The date all manpages were generated will be normalized to a single
  date.
- The release date specified in `VERSION.dat` is used instead of the
  date/time when `pod2man` was executed OR--in the event a date isn't
  specified in `VERSION.dat`--the time when the Makefiles were last
  regenerated.

Embedding a consistent date into the generated manpages helps ensure that
the build process as a whole is more repeatable and helps ensure that
release versions of OpenSSL create artifacts consistent with the date
that the official release was cut.

Co-authored-by: Richard Levitte <levitte@openssl.org>
Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from #28449)

(cherry picked from commit 2c0c9c8)
openssl-machine pushed a commit that referenced this pull request Sep 9, 2025
Before this change all manpages would contain the date when pod2man was
run. This resulted in outputs that differed between builds--or
potentially across a single build if the host clock "ticked" to the next
day when the build was being run.

This commit modifies the manpage generation process as follows:
- The date all manpages were generated will be normalized to a single
  date.
- The release date specified in `VERSION.dat` is used instead of the
  date/time when `pod2man` was executed OR--in the event a date isn't
  specified in `VERSION.dat`--the time when the Makefiles were last
  regenerated.

Embedding a consistent date into the generated manpages helps ensure that
the build process as a whole is more repeatable and helps ensure that
release versions of OpenSSL create artifacts consistent with the date
that the official release was cut.

Co-authored-by: Richard Levitte <levitte@openssl.org>
Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from #28449)

(cherry picked from commit 2c0c9c8)
openssl-machine pushed a commit that referenced this pull request Sep 9, 2025
Before this change all manpages would contain the date when pod2man was
run. This resulted in outputs that differed between builds--or
potentially across a single build if the host clock "ticked" to the next
day when the build was being run.

This commit modifies the manpage generation process as follows:
- The date all manpages were generated will be normalized to a single
  date.
- The release date specified in `VERSION.dat` is used instead of the
  date/time when `pod2man` was executed OR--in the event a date isn't
  specified in `VERSION.dat`--the time when the Makefiles were last
  regenerated.

Embedding a consistent date into the generated manpages helps ensure that
the build process as a whole is more repeatable and helps ensure that
release versions of OpenSSL create artifacts consistent with the date
that the official release was cut.

Co-authored-by: Richard Levitte <levitte@openssl.org>
Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from #28449)
@t8m
Copy link
Member

t8m commented Sep 9, 2025

Merged to all the active branches. Thank you for your contribution.

@t8m t8m closed this Sep 9, 2025
esyr added a commit to esyr/openssl that referenced this pull request Sep 11, 2025
CHANGES.md:
 * openssl#28398
 * openssl#28411
 * openssl#28447
 * openssl#28449

NEWS.md:
 * openssl#28447

Release: yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 11, 2025
CHANGES.md:
 * openssl#28398
 * openssl#28411
 * openssl#28447
 * openssl#28449

NEWS.md:
 * openssl#28447

Release: yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 11, 2025
CHANGES.md:
 * openssl#28398
 * openssl#28411
 * openssl#28447
 * openssl#28449

NEWS.md:
 * openssl#28447

Release: yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
openssl-machine pushed a commit that referenced this pull request Sep 13, 2025
CHANGES.md:
 * #28398
 * #28411
 * #28447
 * #28449

NEWS.md:
 * #28447

Release: yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from #28521)
esyr added a commit to esyr/openssl that referenced this pull request Sep 15, 2025
CHANGES.md:
 * openssl#28398
 * openssl#28411
 * openssl#28447
 * openssl#28449

NEWS.md:
 * openssl#28447

Release: yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 15, 2025
CHANGES.md:
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28447
 * openssl#28449

NEWS.md:
 * openssl#28447

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 16, 2025
CHANGES.md:
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28447
 * openssl#28449

NEWS.md:
 * openssl#28447

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
openssl-machine pushed a commit that referenced this pull request Sep 16, 2025
CHANGES.md:
 * #28198
 * #28398
 * #28411
 * #28447
 * #28449

NEWS.md:
 * #28447

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Paul Dale <ppzgs1@gmail.com>
(Merged from #28558)
openssl-machine pushed a commit that referenced this pull request Sep 16, 2025
CHANGES.md:
 * #28398
 * #28411
 * #28447
 * #28449

NEWS.md:
 * #28447

Release: yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from #28547)
esyr added a commit to esyr/openssl that referenced this pull request Sep 30, 2025
3.0.18 CHANGES.md includes the following:
 * openssl#28098
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28449
 * openssl#28504
 * openssl#28535
 * openssl#28591
 * openssl#28624

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 30, 2025
3.2.6 CHANGES.md includes the following:
 * openssl#28098
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28449
 * openssl#28504
 * openssl#28535
 * openssl#28591
 * openssl#28603
 * openssl#28624
 * openssl#28642

3.2.6 NEWS.md do not have any updates.

Updated the changes and news in the previous branches.

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 30, 2025
3.3.5 CHANGES.md includes the following:
 * openssl#28098
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28449
 * openssl#28504
 * openssl#28535
 * openssl#28591
 * openssl#28603
 * openssl#28624
 * openssl#28642

3.3.5 NEWS.md do not have any updates.

Updated the changes and news in the previous branches.

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 30, 2025
3.4.3 CHANGES.md includes the following:
 * openssl#28098
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28415
 * openssl#28449
 * openssl#28504
 * openssl#28535
 * openssl#28591
 * openssl#28603
 * openssl#28624
 * openssl#28642

3.4.3 NEWS.md do not have any updates.

Updated the changes and news in the previous branches.

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 30, 2025
3.3.5 CHANGES.md includes the following:
 * openssl#28098
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28449
 * openssl#28504
 * openssl#28535
 * openssl#28591
 * openssl#28603
 * openssl#28624
 * openssl#28642

3.3.5 NEWS.md do not have any updates.

Updated the changes and news in the previous branches.

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 30, 2025
3.4.3 CHANGES.md includes the following:
 * openssl#28098
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28415
 * openssl#28449
 * openssl#28504
 * openssl#28535
 * openssl#28591
 * openssl#28603
 * openssl#28624
 * openssl#28642

3.4.3 NEWS.md do not have any updates.

Updated the changes and news in the previous branches.

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 30, 2025
3.2.6 CHANGES.md includes the following:
 * openssl#28098
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28449
 * openssl#28504
 * openssl#28535
 * openssl#28591
 * openssl#28603
 * openssl#28624
 * openssl#28642

3.2.6 NEWS.md do not have any updates.

Updated the changes and news in the previous branches.

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
esyr added a commit to esyr/openssl that referenced this pull request Sep 30, 2025
3.0.18 CHANGES.md includes the following:
 * openssl#28098
 * openssl#28198
 * openssl#28398
 * openssl#28411
 * openssl#28449
 * openssl#28504
 * openssl#28535
 * openssl#28591
 * openssl#28624

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
openssl-machine pushed a commit that referenced this pull request Sep 30, 2025
3.4.3 CHANGES.md includes the following:
 * #28198
 * #28398
 * #28411
 * #28415
 * #28449

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
openssl-machine pushed a commit that referenced this pull request Sep 30, 2025
3.3.5 CHANGES.md includes the following:
 * #28198
 * #28398
 * #28411
 * #28449

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
openssl-machine pushed a commit that referenced this pull request Sep 30, 2025
3.2.6 CHANGES.md includes the following:
 * #28198
 * #28398
 * #28411
 * #28449

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
openssl-machine pushed a commit that referenced this pull request Sep 30, 2025
3.0.18 CHANGES.md includes the following:
 * #28198
 * #28398
 * #28411
 * #28449

Release: Yes
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approval: ready to merge The 24 hour grace period has passed, ready to merge branch: master Merge to master branch branch: 3.0 Merge to openssl-3.0 branch branch: 3.2 Merge to openssl-3.2 branch: 3.3 Merge to openssl-3.3 branch: 3.4 Merge to openssl-3.4 branch: 3.5 Merge to openssl-3.5 branch: 3.6 Merge to openssl-3.6 tests: exempted The PR is exempt from requirements for testing triaged: bug The issue/pr is/fixes a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Build process is not repeatable: file "generation" date embedded in manages
7 participants