Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fips: allow to customize provider vendor name #24368

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

xnox
Copy link
Contributor

@xnox xnox commented May 10, 2024

FIPS providers need to specify identifiable names and versions. Allow to customize the fips provider name prefix, via VERSION.dat which already allows to customize version & buildinfo. With this patch in-place it removes the need of patching code to set customized provider name.

E.g. echo FIPSVENDOR=ACME >> VERSION.dat, results in

$ OPENSSL_CONF=fips-and-base.cnf ../util/wrap.pl ../apps/openssl list -providers --verbose
Providers:
  base
    name: OpenSSL Base Provider
    version: 3.4.0
    status: active
    build info: 3.4.0-dev
    gettable provider parameters:
      name: pointer to a UTF8 encoded string (arbitrary size)
      version: pointer to a UTF8 encoded string (arbitrary size)
      buildinfo: pointer to a UTF8 encoded string (arbitrary size)
      status: integer (arbitrary size)
  fips
    name: ACME OpenSSL FIPS Provider
    version: 3.4.0
    status: active
    build info: 3.4.0-dev
    gettable provider parameters:
      name: pointer to a UTF8 encoded string (arbitrary size)
      version: pointer to a UTF8 encoded string (arbitrary size)
      buildinfo: pointer to a UTF8 encoded string (arbitrary size)
      status: integer (arbitrary size)
      security-checks: integer (arbitrary size)
      tls1-prf-ems-check: integer (arbitrary size)
      drbg-no-trunc-md: integer (arbitrary size)

FIPS providers need to specify identifiable names and versions. Allow
to customize the fips provider name prefix, via VERSION.dat which
already allows to customize version & buildinfo. With this patch
in-place it removes the need of patching code to set customized
provider name.

E.g. echo FIPSVENDOR=ACME >> VERSION.dat, results in

```
$ OPENSSL_CONF=fips-and-base.cnf ../util/wrap.pl ../apps/openssl list -providers --verbose
Providers:
  base
    name: OpenSSL Base Provider
    version: 3.4.0
    status: active
    build info: 3.4.0-dev
    gettable provider parameters:
      name: pointer to a UTF8 encoded string (arbitrary size)
      version: pointer to a UTF8 encoded string (arbitrary size)
      buildinfo: pointer to a UTF8 encoded string (arbitrary size)
      status: integer (arbitrary size)
  fips
    name: ACME OpenSSL FIPS Provider
    version: 3.4.0
    status: active
    build info: 3.4.0-dev
    gettable provider parameters:
      name: pointer to a UTF8 encoded string (arbitrary size)
      version: pointer to a UTF8 encoded string (arbitrary size)
      buildinfo: pointer to a UTF8 encoded string (arbitrary size)
      status: integer (arbitrary size)
      security-checks: integer (arbitrary size)
      tls1-prf-ems-check: integer (arbitrary size)
      drbg-no-trunc-md: integer (arbitrary size)
```
@github-actions github-actions bot added the severity: fips change The pull request changes FIPS provider sources label May 10, 2024
@t8m t8m added branch: master Merge to master branch approval: review pending This pull request needs review by a committer approval: otc review pending This pull request needs review by an OTC member triaged: feature The issue/pr requests/adds a feature labels May 13, 2024
@t8m t8m added the hold: needs tests The PR needs tests to be added to it label May 13, 2024
@paulidale
Copy link
Contributor

Does this intersect the trademark discussions?

@xnox
Copy link
Contributor Author

xnox commented May 13, 2024

Does this intersect the trademark discussions?

I'm not aware or part of any discussions. So either this question is not addressed to me, or please make me aware of the context.

I am assuming the 37 and 21 submissions mentioning OpenSSL are all in compliance with the trademark policy and/or requested permission to use it. This patch simplifies achieving unique naming of individual builds/submissions.

If you prefer this to be "fipsname=" override, rather than prefix-prepend, I can change the patch to do that.

@xnox xnox force-pushed the fips-vendor-name branch 2 times, most recently from 54a5c15 to d4f1e00 Compare May 13, 2024 19:46
Add workflow test that verifies custom FIPSVENDOR name.
@xnox xnox requested a review from t8m May 13, 2024 21:48
@paulidale
Copy link
Contributor

It was a note for the @openssl/omc ...

@t8m t8m added tests: present The PR has suitable tests present and removed hold: needs tests The PR needs tests to be added to it labels May 14, 2024
@@ -360,6 +360,8 @@ $config{release_date} = $version{RELEASE_DATE} // 'xx XXX xxxx';

$config{version} = "$config{major}.$config{minor}.$config{patch}";
$config{full_version} = "$config{version}$config{prerelease}$config{build_metadata}";
$config{FIPSVENDOR} =
(defined $version{FIPSVENDOR} ? "$version{FIPSVENDOR} " : "") . "OpenSSL FIPS Provider";
Copy link
Member

Choose a reason for hiding this comment

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

The exact form of this wording needs internal discussion. That might take a while.

@mattcaswell mattcaswell added the hold: need omc decision The OMC needs to make a decision label May 14, 2024
@mattcaswell
Copy link
Member

Placing a hold on this until internal discussions are held.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approval: otc review pending This pull request needs review by an OTC member approval: review pending This pull request needs review by a committer branch: master Merge to master branch hold: need omc decision The OMC needs to make a decision severity: fips change The pull request changes FIPS provider sources tests: present The PR has suitable tests present triaged: feature The issue/pr requests/adds a feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants