Skip to content

y2038: tests should not be failing if system date is set to after 2038 #21671

@kanavin

Description

@kanavin

To test the readiness of Yocto stack for Y2038 we run qemu virtual machines with RTC set to some day in 2040. This causes a few of openssl's tests to fail on both 32 bit and 64 bit systems: the reason is that test data, certificates in particular, seem to set their expiry date to 2035 or so.

I would propose to set the expiry date to far enough in the future that it won't have to be tweaked in our lifetimes: this way real Y2038 issues in openssl (or in things it depends on) can be exposed and fixed (it's well possible there are none, but that needs confirmation too).

Failures seen:

Test Summary Report
-------------------
80-test_cmp_http.t               (Wstat: 1280 (exited 5) Tests: 6 Failed: 5)
  Failed tests:  1-5
  Non-zero exit status: 5
80-test_cms.t                    (Wstat: 256 (exited 1) Tests: 16 Failed: 1)
  Failed test:  1
  Non-zero exit status: 1
90-test_sslapi.t                 (Wstat: 256 (exited 1) Tests: 3 Failed: 1)
  Failed test:  1
  Non-zero exit status: 1

If there's agreement on this, I can prepare the patch, but I need guidance as to how to regenerate the data correctly (there seem to be no way of doing it with a script from metadata, rather the data is simply stored in git).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions