Commit Graph

84 Commits

Author SHA1 Message Date
Matthew McPherrin b26b116861
Update certificate-transparency-go for bugfix (#8160)
This updates to current `master`,
bc7acd89f703743d050f5cd4a3b9746808e0fdae

Notably, it includes a bug-fix to error handling in the HTTP client,
which we found was hiding errors from CT logs, hindering our debugging.

That fix is
https://github.com/google/certificate-transparency-go/pull/1695

No release has been tagged since this PR merged, so using the `master`
commit.

A few mutual dependencies used by both Boulder and ct-go are updated,
including mysql, otel, and grpc.
2025-05-06 12:10:53 -07:00
Aaron Gable 1c1c4dcfef
Update certificate-transparency-go to get static/tiled log support (#8150)
Update github.com/google/certificate-transparency-go from v1.1.6 to
v1.3.1. This updates the loglist file schema to recognize logs which are
tagged as being tiled logs / implementing the static CT API.

Transitively update:
- github.com/go-sql-driver/mysql from v1.7.1 to v1.8.1
- github.com/prometheus/client_golang from v1.15.1 to v1.22.0
- github.com/prometheus/client_model from v0.4.0 to v0.6.1
- go.opentelemetry.io/otel from v1.30.0 to v1.31.0
- google.golang.org/grpc from v1.66.1 to v1.69.4
- google.golang.org/protobuf from v1.34.2 to v1.36.5
- and a variety of indirect dependencies

Remove one indirect dependency:
- github.com/matttproud/golang_protobuf_extensions

Add two new indirect dependencies:
- filippo.io/edwards25519@v1.1.0 (used by go-sql-driver to handle
mariadb's custom encryption implementation)
- github.com/munnerz/goautoneg@v0.0.0-20191010083416-a7dc8b61c822
(previously inlined into prometheus/common)

Also fix two unit tests which need minor modifications to work with
updated type signatures and behavior.

Part of https://github.com/letsencrypt/boulder/issues/7872
2025-04-30 15:56:31 -07:00
dependabot[bot] 1ce439bc92
build(deps): bump golang.org/x/net from 0.37.0 to 0.38.0 (#8125)
Bumps https://github.com/golang/net from 0.37.0 to 0.38.0. This
resolves a minor vulnerability that does not directly affect Boulder.

Changelog: https://github.com/golang/net/compare/v0.37.0...v0.38.0
2025-04-21 13:56:26 -07:00
Samantha Frank 098cf91e99
dependencies: Update v4.0.5 to v4.1.0 (#8106)
Diff: https://github.com/go-jose/go-jose/compare/v4.0.5...v4.1.0
2025-04-07 18:03:53 -04:00
Aaron Gable ad651d4a3d
Update PSL (#8050)
Update the Public Suffix List (last updated in August 2024).

Transitively update various golang.org/x/ packages, as used by the
publicsuffix-go repo:
- /x/crypto: v0.32.0 -> v0.36.0
- /x/net: v0.29.0 -> v0.37.0
- /x/sync: v0.10.0 -> v0.12.0
- /x/term: v0.28.0 -> v0.30.0
- /x/text: v0.21.0 -> v0.23.0
- /x/sys: v0.29.0 -> v0.31.0
2025-03-10 12:58:44 -07:00
Samantha Frank 6b85b3480b
email/exporter: Add email.Exporter gRPC service (#8017)
Initial implementation of the email.Exporter gRPC service to be used by
the new cmd/email-exporter.

Part of #7966
2025-03-05 12:18:32 -05:00
dependabot[bot] 888581b386
build(deps): bump golang.org/x/sys from 0.25.0 to 0.29.0 (#7927)
Updates /x/sys from v0.25.0 to v0.29.0.
- Changelog: https://go.googlesource.com/sys/+log/v0.25.0..v0.29.0
- Diff: https://go.googlesource.com/sys/+diff/v0.25.0..v0.29.0

Also updates these transitive dependencies, none of which result in any changes to our vendored code:
- /x/crypto from v0.27.0 to v0.32.0
- /x/sync from v0.8.0 to v0.10.0
- /x/term from v0.24.0 to v0.28.0
- /x/text from v0.18.0 to v0.21.0
2025-01-27 14:49:45 -08:00
Eng Zer Jun 13db2a252f
refactor: remove usages of experimental maps package (#7849)
All 4 usages of the `maps.Keys` function from the
`golang.org/x/exp/maps` package can be refactored to a simpler
alternative. If we need it in the future, it is available in the
standard library since Go 1.23.
2024-12-06 11:50:32 -08:00
dependabot[bot] 61ff7f606d
Update OTel dependencies (#7713)
Updates:
- go.opentelemetry.io/contrib/instrumentation (and subpackages) from 0.52.0 to 0.55.0
- go.opentelemetry.io/otel (and subpackages) from 1.27.0 to 1.30.0

Upstream release notes:
https://github.com/open-telemetry/opentelemetry-go-contrib/releases

Also transitively updates a few golang.org/x/ dependencies, and the grpc and protobuf
dependencies.
2024-10-07 13:22:08 -07:00
Adin Schmahmann 9b08fa52ca
Update public suffix list (#7672)
Updates:

github.com/weppos/publicsuffix-go from
v0.30.3-0.20240510084413-5f1d03393b3d to
v0.40.3-0.20240815124645-a8ed110559c9
golang.org/x/crypto from v0.24.0 to v0.26.0
golang.org/x/net from v0.26.0 to v0.28.0
golang.org/x/sync from v0.7.0 to v0.8.0
golang.org/x/term from v0.21.0 to v0.23.0
golang.org/x/text from v0.16.0 to v0.17.0
golang.org/x/sys from v0.21.0 to v0.23.0
2024-08-19 14:03:03 -04:00
Phil Porada f2e46486f9
Upgrade miekg/dns from v1.1.58 to v1.1.61 (#7592)
Diff: [here](https://github.com/miekg/dns/compare/v1.1.58..v1.1.61).
2024-07-16 11:56:16 -04:00
Phil Porada 472effbb9b
grpc: Switch to go-grpc-middleware/providers/prometheus (#7588)
While investigating #6384, I noticed that
[go-grpc-prometheus](https://github.com/grpc-ecosystem/go-grpc-prometheus?tab=readme-ov-file)
was deprecated last year and users should switch to
[go-grpc-middleware](https://github.com/grpc-ecosystem/go-grpc-middleware)
instead. The default prometheus histogram buckets will continue to be
used and [can be found
here](6e3f4b1091/prometheus/histogram.go (L261-L265)).
2024-07-12 15:02:37 -04:00
Samantha Frank 6e2a07d58d
dependencies: Update grpc-go from v1.64 to v1.64.1 (#7578) 2024-07-09 16:56:48 -04:00
Aaron Gable 6ee675f2f0
Update public suffix list (#7484)
It's been one month since the last PSL update.

Update:
- github.com/weppos/publicsuffix-go from
v0.30.3-0.20240411085455-21202160c2ed to
v0.30.3-0.20240510084413-5f1d03393b3d
- golang.org/x/crypto from v0.22.0 to v0.23.0 (no changes)
- golang.org/x/net from v0.24.0 to v0.25.0
- golang.org/x/term from v0.19.0 to v0.20.0 (no changes)
- golang.org/x/text from v0.14.0 to v0.15.0 (no changes)
- golang.org/x/sys from v0.19.0 to v0.20.0

Fixes https://github.com/letsencrypt/boulder/issues/7483
2024-05-14 10:10:20 -04:00
Aaron Gable 2b8dea9821
Update publicsuffix-go (#7429)
We last updated the PSL two months ago, and the latest officially-tagged
release of publicsuffic-go is just one month old, but the domain
prompting the latest request to update the PSL landed just a few days
ago, so update to the latest commit rather than the latest release.

Also incidentally updates x/crypto, x/net, x/term, and x/sys, but brings
in no meaningful updates for any of them.

Fixes https://github.com/letsencrypt/boulder/issues/7428
2024-04-15 11:37:11 -07:00
dependabot[bot] 393beac0a1
build(deps): bump golang.org/x/sync from 0.6.0 to 0.7.0 (#7426)
Bumps [golang.org/x/sync](https://github.com/golang/sync) from 0.6.0 to
0.7.0.

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-12 12:30:55 -04:00
Aaron Gable 7086537553
Update golang.org/x/net for security advisory (#7413)
This will fix the error govulncheck is reporting.
2024-04-04 12:50:42 -04:00
Phil Porada 5f616ccdb9
Upgrade go-jose from v2.6.1 to v.4.0.1 (#7345)
Upgrade from the old go-jose v2.6.1 to the newly minted go-jose v4.0.1. 
Cleans up old code now that `jose.ParseSigned` can take a list of
supported signature algorithms.

Fixes https://github.com/letsencrypt/boulder/issues/7390

---------

Co-authored-by: Aaron Gable <aaron@letsencrypt.org>
2024-04-02 17:49:51 -04:00
Aaron Gable 10e894a172
Create new admin tool (#7276)
Create a new administration tool "bin/admin" as a successor to and
replacement of "admin-revoker".

This new tool supports all the same fundamental capabilities as the old
admin-revoker, including:
- Revoking by serial, by batch of serials, by incident table, and by
private key
- Blocking a key to let bad-key-revoker take care of revocation
- Clearing email addresses from all accounts that use them

Improvements over the old admin-revoker include:
- All commands run in "dry-run" mode by default, to prevent accidental
executions
- All revocation mechanisms allow setting the revocation reason,
skipping blocking the key, indicating that the certificate is malformed,
and controlling the number of parallel workers conducting revocation
- All revocation mechanisms do not parse the cert in question, leaving
that to the RA
- Autogenerated usage information for all subcommands
- A much more modular structure to simplify adding more capabilities in
the future
- Significantly simplified tests with smaller mocks

The new tool has analogues of all of admin-revokers unit tests, and all
integration tests have been updated to use the new tool instead. A
future PR will remove admin-revoker, once we're sure SRE has had time to
update all of their playbooks.

Fixes https://github.com/letsencrypt/boulder/issues/7135
Fixes https://github.com/letsencrypt/boulder/issues/7269
Fixes https://github.com/letsencrypt/boulder/issues/7268
Fixes https://github.com/letsencrypt/boulder/issues/6927
Part of https://github.com/letsencrypt/boulder/issues/6840
2024-02-07 09:35:18 -08:00
dependabot[bot] 7fa2237417
build(deps): bump github.com/miekg/dns from 1.1.55 to 1.1.58 (#7279)
Bumps [github.com/miekg/dns](https://github.com/miekg/dns) from 1.1.55
to 1.1.58.
2024-02-02 13:28:05 -05:00
Matthew McPherrin 56c10c613c
Update zlint (#7252)
Upgrade to zlint v3.6.0

Two new lints are triggered in various places:
aia_contains_internal_names is ignored in integration test
configurations, and unit tests are updated to have more realistic URLs.
The w_subject_common_name_included lint needs to be ignored where we'd
ignored n_subject_common_name_included before.

Related to https://github.com/letsencrypt/boulder/issues/7261
2024-01-16 11:50:37 -08:00
dependabot[bot] 238518da55
build(deps): bump golang.org/x/crypto from 0.15.0 to 0.17.0 (#7223)
Changelog: https://github.com/golang/crypto/compare/v0.15.0...v0.17.0
2023-12-20 11:38:15 -08:00
dependabot[bot] 289284ad6e
build(deps): bump golang.org/x/term from 0.13.0 to 0.15.0 (#7210)
Updates golang.org/x/term and golang.org/x/sys. Changelogs:
- https://github.com/golang/term/compare/v0.13.0...v0.15.0
- https://github.com/golang/sys/compare/v0.13.0...v0.15.0
2023-12-13 16:23:01 -08:00
Aaron Gable eda6e4cb4a
Update OTel dependencies to latest (#7206)
This resolves https://github.com/advisories/GHSA-8pgv-569h-w5rw and
https://github.com/advisories/GHSA-rcjv-mgp8-qvmr, both DoS attacks via
metric cardinality explosion in the default OTel http and gRPC
middleware.
2023-12-13 09:33:39 -05:00
dependabot[bot] 03b0258b53
build(deps): bump golang.org/x/text from 0.13.0 to 0.14.0 (#7160)
Bumps [golang.org/x/text](https://github.com/golang/text) from 0.13.0 to
0.14.0.

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-12-04 15:58:15 -05:00
Aaron Gable 617b6edea4
Update google.golang.org/grpc to v1.59.0 (#7130)
This version contains mitigations for the HTTP/2 rapid-reset DoS vector.
See https://github.com/advisories/GHSA-m425-mq94-257g for details.

Changelog: https://github.com/grpc/grpc-go/compare/v1.54.0...v1.59.0
2023-11-02 10:20:14 -04:00
dependabot[bot] 1aa304063d
build(deps): bump golang.org/x/net from 0.11.0 to 0.17.0 (#7113)
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.11.0 to 0.17.0.
2023-10-19 11:52:58 -04:00
Aaron Gable a70fc604a3
Use go1.21's stdlib slices package (#7074)
As of go1.21, there's a new standard library package which provides
basically the same (generic!) methods as the x/exp/slices package has
been. Now that we're on go1.21, let's use the more stable package.

Fixes https://github.com/letsencrypt/boulder/issues/6951
Fixes https://github.com/letsencrypt/boulder/issues/7032
2023-09-08 13:46:46 -07:00
dependabot[bot] fa028b4394
build(deps): bump golang.org/x/term from 0.9.0 to 0.11.0 (#7046)
Bumps [golang.org/x/term](https://github.com/golang/term) from 0.9.0 to
0.11.0.

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-01 13:40:17 -04:00
dependabot[bot] 11fe943577
update golang.org/x/crypto, net, term, and text (#6949)
Updates:
- https://github.com/golang/crypto from 0.8.0 to 0.10.0.
- https://github.com/golang/net from 0.9.0 to 0.11.0.
- https://github.com/golang/term from 0.7.0 to 0.9.0.
- https://github.com/golang/text from 0.9.0 to 0.10.0.
2023-06-21 13:26:26 -04:00
Matthew McPherrin 0060e695b5
Introduce OpenTelemetry Tracing (#6750)
Add a new shared config stanza which all boulder components can use to
configure their Open Telemetry tracing. This allows components to
specify where their traces should be sent, what their sampling ratio
should be, and whether or not they should respect their parent's
sampling decisions (so that web front-ends can ignore sampling info
coming from outside our infrastructure). It's likely we'll need to
evolve this configuration over time, but this is a good starting point.

Add basic Open Telemetry setup to our existing cmd.StatsAndLogging
helper, so that it gets initialized at the same time as our other
observability helpers. This sets certain default fields on all
traces/spans generated by the service. Currently these include the
service name, the service version, and information about the telemetry
SDK itself. In the future we'll likely augment this with information
about the host and process.

Finally, add instrumentation for the HTTP servers and grpc
clients/servers. This gives us a starting point of being able to monitor
Boulder, but is fairly minimal as this PR is already somewhat unwieldy:
It's really only enough to understand that everything is wired up
properly in the configuration. In subsequent work we'll enhance those
spans with more data, and add more spans for things not automatically
traced here.

Fixes https://github.com/letsencrypt/boulder/issues/6361

---------

Co-authored-by: Aaron Gable <aaron@aarongable.com>
2023-04-21 10:46:59 -07:00
dependabot[bot] c21ebb9f61
Bump golang.org/x/ deps to latest (#6814)
Update all golang.org/x/ deps to their latest available version:
- https://golang.org/x/crypto from 0.7.0 to 0.8.0
- https://golang.org/x/exp from v0.0.0-20230118134722-a68e582fa157 to
v0.0.0-20230321023759-10a507213a29
- https://golang.org/x/net from 0.8.0 to 0.9.0
- https://golang.org/x/text from 0.8.0 to 0.9.0
- https://golang.org/x/mod from 0.8.0 to 0.10.0
- https://golang.org/x/tools from 0.6.0 to 0.8.0

This only affects vendored files for /x/exp, /x/net/, and /x/tools/.

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Aaron Gable <aaron@letsencrypt.org>
2023-04-17 16:48:57 -04:00
dependabot[bot] ee16f965e2
build(deps): Bump golang.org/x/sys from 0.6.0 to 0.7.0 (#6797)
Bumps https://github.com/golang/sys from 0.6.0 to 0.7.0.
Also does the same version update for /x/text, but that update
does not affect any of our vendored files.

Diff: https://github.com/golang/sys/compare/v0.6.0...v0.7.0
2023-04-06 14:50:17 -07:00
dependabot[bot] 3850ab3bd8
build(deps): Bump golang.org/x/crypto from 0.1.0 to 0.7.0 (#6776)
Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.1.0
to 0.7.0.

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-29 19:08:32 -04:00
dependabot[bot] 88569e618b
build(deps): Bump golang.org/x/term from 0.5.0 to 0.6.0 (#6728)
Bumps https://github.com/golang/term from 0.5.0 to 0.6.0.
- Commits: https://github.com/golang/term/compare/v0.5.0..v0.6.0

Updated transitive dependencies:
- https://pkg.go.dev/golang.org/x/sys
2023-03-09 15:16:28 -08:00
dependabot[bot] 2be64b5b3a
build(deps): Bump golang.org/x/text from 0.7.0 to 0.8.0 (#6729)
Bumps https://github.com/golang/text from 0.7.0 to 0.8.0.
- Commits: https://github.com/golang/text/compare/v0.7.0...v0.8.0
2023-03-08 13:46:28 -08:00
dependabot[bot] 95c354f6bd
build(deps): Bump golang.org/x/net from 0.1.0 to 0.7.0 (#6677)
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.1.0 to
0.7.0.
- [Commits](https://github.com/golang/net/compare/v0.1.0...v0.7.0)
2023-02-21 15:29:05 -05:00
dependabot[bot] 86e1009ffe
build(deps): Bump golang.org/x/text from 0.4.0 to 0.6.0 (#6606)
Bumps [golang.org/x/text](https://github.com/golang/text) from 0.4.0 to
0.6.0.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="ec5565b1b7"><code>ec5565b</code></a>
README.md: update documentation of module versioning</li>
<li><a
href="c8236a6712"><code>c8236a6</code></a>
unicode/bidi: remove unused global</li>
<li><a
href="ada7473102"><code>ada7473</code></a>
all: remove redundant type conversion</li>
<li>See full diff in <a
href="https://github.com/golang/text/compare/v0.4.0...v0.6.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=golang.org/x/text&package-manager=go_modules&previous-version=0.4.0&new-version=0.6.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-01-26 21:10:12 -05:00
Aaron Gable 1b7eb3d978
RA: Simplify FinalizeOrder flow (#6588)
Simplify the control flow of the FinalizeOrder handler to make it easier
to read and reason about:
- Move all validation to before we set the order to Processing, and put
it all in a single helper funcion.
- Move almost all logEvent/trace handling directly into FinalizeOrder so
it cannot be missed.
- Flatten issueCertificate and issueCertificateInner into a single
helper function, now that they're no longer being called from both
ACMEv1 and v2 entry points.
- Other minor cleanups, such as making SolvedBy not return a pointer and
making matchesCSR private.

This paves the way for making both issueCertificateInner and failOrder
asynchronous, which we plan to do in the near future.

Part of #6575
2023-01-25 17:59:54 -08:00
Aaron Gable b55499f2d8
Update golang.org/x/ deps to tagged versions (#6596) 2023-01-23 12:34:06 -05:00
Jacob Hoffman-Andrews fe2cf7d136
ocsp: add load shedding for live signer (#6523)
In live.go we use a semaphore to limit how many inflight signing
requests we can have, so a flood of OCSP traffic doesn't flood our CA
instances. If traffic exceeds our capacity to sign responses for long
enough, we want to eventually start fast-rejecting inbound requests that
are unlikely to get serviced before their deadline is reached. To do
that, add a MaxSigningWaiters config field to the OCSP responder.

Note that the files in //semaphore are forked from x/sync/semaphore,
with modifications to add the MaxWaiters field and functionality.

Fixes #6392
2022-12-12 15:48:44 -08:00
dependabot[bot] 0ca01ea962
build(deps): bump golang.org/x/text from 0.3.7 to 0.3.8 (#6444)
Bumps [golang.org/x/text](https://github.com/golang/text) from 0.3.7 to 0.3.8.
- [Release notes](https://github.com/golang/text/releases)
- [Commits](https://github.com/golang/text/compare/v0.3.7...v0.3.8)

This also transitively updates x/tools and x/sync, which is good because those
are unversioned packages which are otherwise ignored by dependabot.

Note that we are not affected by the vulnerability which prompted the release
of version 0.3.8; the affected files are in the language subpackage which we
do not use or vendor.
2022-10-11 18:27:59 -07:00
Aaron Gable a3ddc42c86
Update Public Suffix List (#6429)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2022-10-03 10:05:21 -07:00
dependabot[bot] 97a862555e
build(deps): bump github.com/honeycombio/beeline-go from 1.1.1 to 1.10.0 (#6326)
Bumps [github.com/honeycombio/beeline-go](https://github.com/honeycombio/beeline-go) from 1.1.1 to 1.10.0.
- [Release notes](https://github.com/honeycombio/beeline-go/releases)
- [Changelog](https://github.com/honeycombio/beeline-go/blob/main/CHANGELOG.md)
- [Commits](https://github.com/honeycombio/beeline-go/compare/v1.1.1...v1.10.0)

---
updated-dependencies:
- dependency-name: github.com/honeycombio/beeline-go
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-09-01 17:29:16 -07:00
Jacob Hoffman-Andrews dd1c52573e
log: allow logging to stdout/stderr instead of syslog (#6307)
Right now, Boulder expects to be able to connect to syslog, and panics
if it's not available. We'd like to be able to log to stdout/stderr as a
replacement for syslog.

- Add a detailed timestamp (down to microseconds, same as we collect in
prod via syslog).
- Remove the escape codes for colorizing output.
- Report the severity level numerically rather than with a letter prefix.

Add locking for stdout/stderr and syslog logs. Neither the [syslog] package
nor the [os] package document concurrency-safety, and the Go rule is: if
it's not documented to be concurrent-safe, it's not. Notably the [log.Logger]
package is documented to be concurrent-safe, and a look at its implementation
shows it uses a Mutex internally.

Remove places that use the singleton `blog.Get()`, and instead pass through
a logger from main in all the places that need it.

[syslog]: https://pkg.go.dev/log/syslog
[os]: https://pkg.go.dev/os
[log.Logger]: https://pkg.go.dev/log#Logger
2022-08-29 06:19:22 -07:00
dependabot[bot] 31c57b7f70
build(deps): bump github.com/prometheus/client_golang (#6314)
Bumps [github.com/prometheus/client_golang](https://github.com/prometheus/client_golang) from 1.12.2 to 1.13.0.
- [Release notes](https://github.com/prometheus/client_golang/releases)
- [Changelog](https://github.com/prometheus/client_golang/blob/main/CHANGELOG.md)
- [Commits](https://github.com/prometheus/client_golang/compare/v1.12.2...v1.13.0)

---
updated-dependencies:
- dependency-name: github.com/prometheus/client_golang
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-25 16:30:02 -07:00
Jacob Hoffman-Andrews b724671435
ocsp/responder: add live source (#6200)
Note this is not yet plumbed up into cmd/ocsp-responder/main.go,
because we will want do that with it wrapped in a Redis caching layer.

Fixes #6190.
2022-06-30 11:46:24 -07:00
Aaron Gable c97d98d5f5
Fork CRL-specific subset of stdlib's crypto/x509 (#6198)
Fork the pieces of the Go standard library's crypto/x509
package which are relevant to parsing, handling, and
signing CRLs.

In our fork, fix an upstream parsing bug, hoist the reasonCode
out of the crlEntryExtensions for easier usability, and enforce
that CRL Numbers are never longer than 20 octets.

Part of #6199
2022-06-29 18:03:45 -07:00
dependabot[bot] 7bb573ca94
Bump github.com/prometheus/client_golang from 1.7.1 to 1.12.1 (#5974)
Diff: https://github.com/prometheus/client_golang/compare/v1.7.1...v1.12.1

Changes:
* 1.12.1 / 2022-01-29
  - [BUGFIX] Make the Go 1.17 collector concurrency-safe
  - Use simpler locking in the Go 1.17 collector
  - [BUGFIX] Reduce granularity of histogram buckets for Go 1.17 collector
  - [ENHANCEMENT] API client: make HTTP reads more efficient
* 1.12.0 / 2022-01-19
  - [CHANGE] example/random: Move flags and metrics into main()
  - [FEATURE] API client: Support wal replay status api
  - [FEATURE] Use the runtime/metrics package for the Go collector for 1.17+
  - [ENHANCEMENT] API client: Update /api/v1/status/tsdb to include headStats
  - [ENHANCEMENT] promhttp: Check validity of method and code label values
* 1.11.0 / 2021-06-07
  - [CHANGE] Add new collectors package.
  - [CHANGE] prometheus.NewExpvarCollector is deprecated, use collectors.NewExpvarCollector instead.
  - [CHANGE] prometheus.NewGoCollector is deprecated, use collectors.NewGoCollector instead.
  - [CHANGE] prometheus.NewBuildInfoCollector is deprecated, use collectors.NewBuildInfoCollector instead.
  - [FEATURE] Add new collector for database/sql#DBStats.
  - [FEATURE] API client: Add exemplars API support.
  - [ENHANCEMENT] API client: Add newer fields to Rules API.
  - [ENHANCEMENT] API client: Add missing fields to Targets API.
* 1.10.0 / 2021-03-18
  - [CHANGE] Minimum required Go version is now 1.13.
  - [CHANGE] API client: Add matchers to LabelNames and LabesValues.
  - [FEATURE] API client: Add buildinfo call.
  - [BUGFIX] Fix build on riscv64.
* 1.9.0 / 2020-12-17
  - [FEATURE] NewPidFileFn helper to create process collectors for processes whose PID is read from a file.
  - [BUGFIX] promhttp: Prevent endless loop in InstrumentHandler... middlewares with invalid metric or label names.
* 1.8.0 / 2020-10-15
  - [CHANGE] API client: Use time.Time rather than string for timestamps in RuntimeinfoResult.
  - [FEATURE] Export MetricVec to facilitate implementation of vectors of custom Metric types.
  - [FEATURE] API client: Support /status/tsdb endpoint.
  - [ENHANCEMENT] API client: Enable GET fallback on status code 501.
  - [ENHANCEMENT] Remove Metric references after reslicing to free up more memory.

Additional transitive dependency updates:
* https://github.com/prometheus/common/compare/v0.10.0...v0.32.1
* https://github.com/prometheus/procfs/compare/v0.1.3...v0.7.3
* https://github.com/golang/appengine/compare/v1.6.5...v1.6.6
* cb27e3aa20...8632dd7979
* 0f9fa26af8...5a964db013
2022-03-30 09:49:40 -07:00
Aaron Gable e15bb89347
Update miekg/dns from v1.1.30 to v1.1.45 (#5972)
Changelog: https://github.com/miekg/dns/compare/v1.1.30...v1.1.45

Brings in several small changes, but more importantly brings Boulder
up to (and past) the version used by pebble/challtestsrv.
2022-03-02 09:03:13 -08:00