Skip to content

Update cargo dependencies - #5055

Merged
pfcoperez merged 9 commits into
mainfrom
renovate/cargo
Nov 19, 2026
Merged

pfcoperez merged 9 commits into
mainfrom
renovate/cargo

Conversation

@renovate

@renovate renovate Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

This PR contains the following updates:

Package Type Update Change Pending
base64 dependencies minor 0.22 → 0.23
pbjson dependencies minor 0.8 → 0.9
pbjson-types dependencies minor 0.8 → 0.9
pgwire workspace.dependencies minor 0.36 → 0.42 0.42.3 (+1)
reqwest dependencies minor 0.12 → 0.13
rsa dependencies minor 0.9.2 → 0.10.0
sqlparser dependencies minor 0.62 → 0.63 0.64.0
sqlparser workspace.dependencies minor 0.62 → 0.63 0.64.0

Release Notes

marshallpierce/rust-base64 (base64)

v0.23.1

Compare Source

  • Make the tests build again on non-SIMD architectures

v0.23.0

Compare Source

  • Added more consts for preconfigured configs and engines
  • Make DecodeError::InvalidLastSymbol more clear by including the decoded value
  • Added SIMD-accelerated engines behind the default-on simd-unsafe feature: Simd picks the best
    instruction set at runtime (AVX2 on x86_64, NEON on aarch64) and falls back to the scalar
    GeneralPurpose engine, while Avx2 and Neon target one instruction set with no runtime
    detection and work in no_std. The engines support the standard and URL-safe alphabets.
  • Update MSRV to 1.71.0
  • Add support for custom padding symbols
sunng87/pgwire (pgwire)

v0.42.1

Compare Source

Fixed
  • SCRAM channel binding negotiation and proof validation, aligning with
    RFC 5802 section 6. [#​476]
    • reject a p= gs2 channel binding flag in the client-first message
      when no server certificate is configured, or when it names a binding
      type other than tls-server-end-point; previously a client could
      request an unsupported channel binding on the plain SCRAM-SHA-256
      mechanism and still authenticate
    • reject the y gs2 flag when the server supports channel binding,
      preventing downgrade attacks where a MITM strips the -PLUS
      mechanism from the advertisement
    • reject overlong or short client proofs on the verifier-based path;
      the proof must be exactly one hash output long (32 bytes for
      SHA-256). Previously trailing bytes were silently truncated by the
      proof verification, so a valid proof with appended junk still
      authenticated

v0.42.0

Compare Source

Added
  • Composable startup authentication API. [#​469]
    • AuthMechanism: stateful, per-connection authentication state
      machines, driven by begin/next until AuthState::Ok or
      AuthState::Failed
    • AuthMechanismFactory: creates a fresh mechanism per connection;
      implemented by CleartextPasswordAuth, Md5PasswordAuth, the
      SaslMechanisms registry, ScramAuth and Oauth
    • AuthDriver: reusable mechanism driver for custom StartupHandler
      implementations; runs the mechanism state machine and completes the
      startup protocol
  • AuthSource::get_scram_secret returning ScramSecret: servers that
    only store postgres-style SCRAM verifiers (stored_key/server_key)
    can now authenticate without password material. [#​469]
  • PgWireError::NoAuthenticationInProgress, returned when a
    password-family message arrives while no authentication handshake is
    running. [#​469]
  • LoginInfo now carries the TLS context (sni_server_name,
    client_certificates), so AuthSource implementations can make
    certificate-based decisions
  • AuthSource is now identity-aware (AuthSource<I>):
    verify_password delegates verification to the source and returns
    the authenticated identity (default: compare against
    get_password); get_scram_secret returns the identity alongside
    the credential.
Changed
  • CleartextPasswordAuthStartupHandler, Md5PasswordAuthStartupHandler
    and SASLAuthStartupHandler are now implemented over AuthDriver and
    the mechanism API. Per-connection authentication state no longer lives
    in the shared handler, fixing interleaved authentication state when a
    single handler serves concurrent connections. [#​469]
  • SCRAM parser strictness, aligning with postgres and RFC5802:
    • reject non-empty authzid in the client-first message
    • reject the reserved m= attribute in client-first and server-first
      messages
    • reject selections of non-advertised SASL mechanism names
    • verify the client-final nonce against the server-first nonce
  • SCRAM proofs are now verified against the messages exactly as
    transmitted, so clients sending optional RFC5802 extensions no longer
    fail authentication. Both server and client sides.

v0.41.2

Compare Source

v0.41.1

Compare Source

Changed
  • Set tcp_nodelay for client socket. client-api. [#​464]
  • Reject messages other than Sync and Flush during COPY FROM STDIN. [#​465],[#​466]

v0.41.0

Compare Source

Added
  • Client API: transaction status tracking. ClientInfo::transaction_status
    reports the status carried by the last ReadyForQuery message (idle, in
    transaction, or in a failed transaction), updated automatically on every
    code path: startup, simple and extended query, and the error-recovery
    drains.
  • Client API: protocol version negotiation. Config::protocol_version
    selects the version to advertise in the startup message, defaulting to 3.0.
    Following libpq, a test version 3.9999 is available to request the newest
    minor version a server supports: the client handles the server's
    NegotiateProtocolVersion response (both the full 32-bit version form used
    by PostgreSQL 18+ and the minor-only form used by older servers) and adopts
    the negotiated version for the rest of the connection.
Changed
  • Breaking: QueryParser::parse_sql now returns
    PgWireResult<Option<Self::Statement>>, and StoredStatement::parse
    correspondingly returns Option<StoredStatement<S>>. None denotes an
    empty query: it is stored as an empty statement and executes to
    EmptyQueryResponse. This allows a query parser to report its own notion
    of empty query; syntactically empty queries (semicolons and whitespace
    only) are still never passed to the parser.
  • Breaking: PortalStore now represents empty statements and portals.
    get_statement returns Option<Entry<StoredStatement<S>>> and
    get_portal returns Option<Entry<Portal<S>>>: the new Entry::Empty
    variant marks a name under which an empty prepared statement or portal is
    stored, alongside the new put_empty_statement/put_empty_portal
    methods. Like every put_*, storing an empty entry replaces whatever was
    previously stored under that name, and rm_*/clear_portals remove
    empty entries along with regular ones. StoredStatement and Portal
    themselves are unchanged — the impact is limited to PortalStore
    implementors and code calling get_statement/get_portal directly
    (Entry::value helps with the migration).
  • Updated pg_interval to 0.6
Fixed
  • Extended query protocol: empty queries (a query string without any
    statement, such as "" or ";;") are now handled like PostgreSQL instead
    of being dispatched to the query parser: Parse succeeds without calling
    QueryParser and stores an empty statement, Describe answers
    ParameterDescription (no parameters) + NoData, Bind succeeds
    (rejecting bound parameters with 08P01) and stores an empty portal, and
    Execute returns EmptyQueryResponse without reaching do_query. An
    empty Parse replaces any statement previously stored under the same
    name, and Close/Sync drop empty statements and the unnamed empty
    portal like real ones. Behavior verified message-for-message against
    PostgreSQL 18.
  • Client API: backend messages are now decoded with the rules of the protocol
    version the client actually advertised, instead of always 3.2. Previously a
    4-byte protocol 3.0 cancel key was decoded as SecretKey::Bytes instead of
    SecretKey::I32.

v0.40.7

Compare Source

Fixed
  • Treat semicolons-only query strings (e.g. ;;, ;;;, ; ;) as empty queries
    in the simple query protocol, returning EmptyQueryResponse like PostgreSQL.
    Previously only the empty string and a single ; were recognized as empty.

v0.40.6

Compare Source

Changed
  • Add strict check for count based decoding [#​451]
  • Combine a few socket writes into batch [#​452]

v0.40.5

Compare Source

Fixed
  • Customisible type size and modifier for RowDescription [#​449]

v0.40.4

Compare Source

Fixed
  • Panic when retrieve mTLS client ceritificates [#​446]

v0.40.3

Compare Source

Changed
  • Revert pg_interval 0.6 update.

v0.40.2

Compare Source

Fixed
  • CopyFail message codec error. [#​442]

v0.40.1

Compare Source

Fixed
  • Use full version number in protocol negotiation. [#​439]
  • Close socket when client sends Termination [#​438]

v0.40.0

Compare Source

Added
  • APIs on Portal to support cursor operations. [#​433]
Changed
  • Changed default PID generate use sequential number [#​431]
  • Switch pg_interval crate to original [#​432]
Fixed
  • Sync message will no longer clear all portals but unnamed portal. [#​433]

v0.39.0

Compare Source

Added
  • New ConnectionManager, PidSecretKeyGenerator and new
    DefaultCancelHandler for our high-level query cancellation support. By
    configuring ConnectionManager and DefaultCancelHandler, we will provide
    default implementation for query cancel. See examples/cancel.rs for
    instance. [#​427]
  • Add Any trait to PortalStore trait to allow downcast and usage in
    SimpleQueryHandler [#​421]
  • Add more error fields [#​423]
  • Add session_extension mechanism for extending ClientInfo [#​409]
  • Experimental client API for extended query [#​250]
Changed
  • Make StoredStatement::parse public for writing custom ExtendedQueryHandler
    [#​425]

v0.38.3

Compare Source

Fixed
  • Cleanup portals on SYNC message [#​424]

v0.38.2

Compare Source

Changed
  • Removed size limit for ParameterDescription message [#​418]

v0.38.1

Compare Source

Added
  • Client API: SCRAM authentication [#​414]
Fixed
  • Added more ISO datetime string format for timestamp, timestamptz and date types [#​417]
  • Panic when parsing non null terminated cstring [#​407]

v0.38.0

Compare Source

Added
  • CopyEncoder, PGCOPY protocol and full Copy out API support [#​403]
Fixed
  • TLS handshake in client API [#​400]
  • ClientConfig compilation on Windows [#​392]
  • Resetting DecodeContext fields [#​394]
Changed
  • FromSqlText is no longer implemented for Vec<T>, use Vec<Option<T>>
    instead [#​395]
  • standard_string_conforming is always on now [#​388]

v0.37.3

Compare Source

Fixed
  • Issue with postgres DateStyle [#​387]

v0.37.2

Compare Source

Changed
  • Add auto FromSqlText implementation for Vec<Option<T>> where T is
    FromSqlText. We are going to remove FromSqlText for Vec<T> in
    next breaking release due to conflicts and lack of NULL semantic. [#​385]

v0.37.1

Compare Source

Added
  • New data type supported: PostGIS types [#​382]
  • New data type supported: Interval [#​383]
  • UDS server and client socket support [#​381] [#​379]

v0.37.0

Compare Source

Added
  • Postgres 18 OAuth Authentication support [#​349]
  • More ToSqlText implementations [#​364]
Changed
  • Deprecated finish() and make DataRowEncoder reusable for a massive
    performance gain [#​366]
  • Parameter type and result schema functions added to QueryParser trait,
    for default implementation of describe statement and portal in
    ExtendedQueryHandler. This change allow us to provide postgres compatible
    default behavior for describing statement.[#​356]
seanmonstar/reqwest (reqwest)

v0.13.5

Compare Source

  • Add Error::is_dns() to identify errors caused by DNS resolution failures.
  • Add ClientBuilder::http1_max_headers(usize) to configure the maximum number of headers accepted in an HTTP/1 response (default 100).
  • Add TLS version to TlsInfo extension.
  • Fix hickory-dns feature to use Ipv6AndIpv4 strategy to prefer IPv6.
  • Fix sending wrong proxy-auth if multiple proxies intercept a given URL.

v0.13.4

Compare Source

  • Add ClientBuilder::tls_sslkeylogfile(bool) option to allow using the related environment variable.
  • Add ClientBuilder::http2_keep_alive_* options for the blocking client.
  • Add TLS 1.3 support when using native-tls backend.
  • Fix redirect handling to strip sensitive headers when the scheme changes.
  • Fix HTTP/3 happy-eyeball connection creation.
  • Upgrade hickory-resolver to 0.26.

v0.13.3

Compare Source

  • Fix CertificateRevocationList parsing of PEM values.
  • Fix logging in resolver to only show host, not full URL.
  • Fix hickory-dns to fallback to a default if /etc/resolv.conf fails.
  • Fix HTTP/3 to handle STOP_SENDING as not an error.
  • Fix HTTP/3 pool to remove timed out QUIC connections.
  • Fix HTTP/3 connection establishment picking IPv4 and IPv6.
  • Upgrade rustls-platform-verifier.
  • (wasm) Only use wasm-bindgen on unknown-* targets.

v0.13.2

Compare Source

  • Fix HTTP/2 and native-tls ALPN feature combinations.
  • Fix HTTP/3 to send h3 ALPN.
  • (wasm) fix RequestBuilder::json() from override previously set content-type.

v0.13.1

Compare Source

  • Fixes compiling with rustls on Android targets.

v0.13.0

Compare Source

  • Breaking changes:
    • rustls is now the default TLS backend, instead of native-tls.
    • rustls crypto provider defaults to aws-lc instead of ring. (rustls-no-provider exists if you want a different crypto provider)
    • rustls-tls has been renamed to rustls.
    • rustls roots features removed, rustls-platform-verifier is used by default.
      • To use different roots, call tls_certs_only(your_roots).
    • native-tls now includes ALPN. To disable, use native-tls-no-alpn.
    • query and form are now crate features, disabled by default.
    • Long-deprecated methods and crate features have been removed (such as trust-dns, which was renamed hickory-dns a while ago).
  • Many TLS-related methods renamed to improve autocompletion and discovery, but previous name left in place with a "soft" deprecation. (just documented, no warnings)
    • For example, prefer tls_backend_rustls() over use_rustls_tls().

v0.12.28

  • Fix compiling on Windows if TLS and SOCKS features are not enabled.

v0.12.27

  • Add ClientBuilder::windows_named_pipe(name) option that will force all requests over that Windows Named Piper.

v0.12.26

  • Fix sending Accept-Encoding header only with values configured with reqwest, regardless of underlying tower-http config.

v0.12.25

  • Add Error::is_upgrade() to determine if the error was from an HTTP upgrade.
  • Fix sending Proxy-Authorization if only username is configured.
  • Fix sending Proxy-Authorization to HTTPS proxies when the target is HTTP.
  • Refactor internal decompression handling to use tower-http.

v0.12.24

  • Refactor cookie handling to an internal middleware.
  • Refactor internal random generator.
  • Refactor base64 encoding to reduce a copy.
  • Documentation updates.

v0.12.23

  • Add ClientBuilder::unix_socket(path) option that will force all requests over that Unix Domain Socket.
  • Add ClientBuilder::retry(policy) and reqwest::retry::Builder to configure automatic retries.
  • Add ClientBuilder::dns_resolver2() with more ergonomic argument bounds, allowing more resolver implementations.
  • Add http3_* options to blocking::ClientBuilder.
  • Fix default TCP timeout values to enabled and faster.
  • Fix SOCKS proxies to default to port 1080
  • (wasm) Add cache methods to RequestBuilder.

v0.12.22

  • Fix socks proxies when resolving IPv6 destinations.

v0.12.21

  • Fix socks proxy to use socks4a:// instead of socks4h://.
  • Fix Error::is_timeout() to check for hyper and IO timeouts too.
  • Fix request Error to again include URLs when possible.
  • Fix socks connect error to include more context.
  • (wasm) implement Default for Body.

v0.12.20

  • Add ClientBuilder::tcp_user_timeout(Duration) option to set TCP_USER_TIMEOUT.
  • Fix proxy headers only using the first matched proxy.
  • (wasm) Fix re-adding Error::is_status().

v0.12.19

  • Fix redirect that changes the method to GET should remove payload headers.
  • Fix redirect to only check the next scheme if the policy action is to follow.
  • (wasm) Fix compilation error if cookies feature is enabled (by the way, it's a noop feature in wasm).

v0.12.18

  • Fix compilation when socks enabled without TLS.

v0.12.17

  • Fix compilation on macOS.

v0.12.16

  • Add ClientBuilder::http3_congestion_bbr() to enable BBR congestion control.
  • Add ClientBuilder::http3_send_grease() to configure whether to send use QUIC grease.
  • Add ClientBuilder::http3_max_field_section_size() to configure the maximum response headers.
  • Add ClientBuilder::tcp_keepalive_interval() to configure TCP probe interval.
  • Add ClientBuilder::tcp_keepalive_retries() to configure TCP probe count.
  • Add Proxy::headers() to add extra headers that should be sent to a proxy.
  • Fix redirect::Policy::limit() which had an off-by-1 error, allowing 1 more redirect than specified.
  • Fix HTTP/3 to support streaming request bodies.
  • (wasm) Fix null bodies when calling Response::bytes_stream().

v0.12.15

  • Fix Windows to support both ProxyOverride and NO_PROXY.
  • Fix http3 to support streaming response bodies.
  • Fix http3 dependency from public API misuse.

v0.12.14

  • Fix missing fetch_mode_no_cors(), marking as deprecated when not on WASM.

v0.12.13

  • Add Form::into_reader() for blocking multipart forms.
  • Add Form::into_stream() for async multipart forms.
  • Add support for SOCKS4a proxies.
  • Fix decoding responses with multiple zstd frames.
  • Fix RequestBuilder::form() from overwriting a previously set Content-Type header, like the other builder methods.
  • Fix cloning of request timeout in blocking::Request.
  • Fix http3 synchronization of connection creation, reducing unneccesary extra connections.
  • Fix Windows system proxy to use ProxyOverride as a NO_PROXY value.
  • Fix blocking read to correctly reserve and zero read buffer.
  • (wasm) Add support for request timeouts.
  • (wasm) Fix Error::is_timeout() to return true when from a request timeout.

v0.12.12

  • (wasm) Fix compilation by not compiler tokio/time on WASM.

v0.12.11

  • Fix decompression returning an error when HTTP/2 ends with an empty data frame.

v0.12.10

  • Add ClientBuilder::connector_layer() to allow customizing the connector stack.
  • Add ClientBuilder::http2_max_header_list_size() option.
  • Fix propagating body size hint (content-length) information when wrapping bodies.
  • Fix decompression of chunked bodies so the connections can be reused more often.

v0.12.9

  • Add tls::CertificateRevocationLists support.
  • Add crate features to enable webpki roots without selecting a rustls provider.
  • Fix connection_verbose() to output read logs.
  • Fix multipart::Part::file() to automatically include content-length.
  • Fix proxy to internally no longer cache system proxy settings.

v0.12.8

  • Add support for SOCKS4 proxies.
  • Add multipart::Form::file() method for adding files easily.
  • Add Body::wrap() to wrap any http_body::Body type.
  • Fix the pool configuration to use a timer to remove expired connections.

v0.12.7

  • Revert adding impl Service<http::Request<_>> for Client.

v0.12.6

  • Add support for danger_accept_invalid_hostnames for rustls.
  • Add impl Service<http::Request<Body>> for Client and &'_ Client.
  • Add support for !Sync bodies in Body::wrap_stream().
  • Enable happy eyeballs when hickory-dns is used.
  • Fix Proxy so that HTTP(S)_PROXY values take precedence over ALL_PROXY.
  • Fix blocking::RequestBuilder::header() from unsetting sensitive on passed header values.

v0.12.5

  • Add blocking::ClientBuilder::dns_resolver() method to change DNS resolver in blocking client.
  • Add http3 feature back, still requiring reqwest_unstable.
  • Add rustls-tls-no-provider Cargo feature to use rustls without a crypto provider.
  • Fix Accept-Encoding header combinations.
  • Fix http3 resolving IPv6 addresses.
  • Internal: upgrade to rustls 0.23.

v0.12.4

  • Add zstd support, enabled with zstd Cargo feature.
  • Add ClientBuilder::read_timeout(Duration), which applies the duration for each read operation. The timeout resets after a successful read.

v0.12.3

  • Add FromStr for dns::Name.
  • Add ClientBuilder::built_in_webpki_certs(bool) to enable them separately.
  • Add ClientBuilder::built_in_native_certs(bool) to enable them separately.
  • Fix sending content-length: 0 for GET requests.
  • Fix response body content_length() to return value when timeout is configured.
  • Fix ClientBuilder::resolve() to use lowercase domain names.

v0.12.2

  • Fix missing ALPN when connecting to socks5 proxy with rustls.
  • Fix TLS version limits with rustls.
  • Fix not detected ALPN h2 from server with native-tls.

v0.12.1

  • Fix ClientBuilder::interface() when no TLS is enabled.
  • Fix TlsInfo::peer_certificate() being truncated with rustls.
  • Fix panic if http2 feature disabled but TLS negotiated h2 in ALPN.
  • Fix Display for Error to not include its source error.
RustCrypto/RSA (rsa)

v0.10.0

Compare Source

Security
Added
  • PKCS#8/SPKI decoding for PSS keys, including id-RSASSA-PSS algorithm identifiers (#​424)
  • pss::VerifyingKey::salt_len and opt-in automatic salt-length detection via
    new_with_auto_salt_len (#​448, #​546)
  • Wycheproof test coverage for PKCS#1 v1.5, PSS, and OAEP (#​477, #​740)
  • PublicKeyParts::n_bytes and e_bytes serialization helpers (#​519)
  • Multipart signing trait implementations for PKCS#1 v1.5 and PSS (#​525)
  • Clone and core::error::Error implementations for Error (#​530, #​694)
  • PrivateKey::as_public_key accessor (#​592)
  • Algorithm-specific inherent methods on PrivateKey and PublicKey for OAEP encryption/decryption
    and PKCS#1 v1.5/PSS signing/verification, including prehash and explicit-RNG variants (#​638)
  • PrivateKey::from_components_with_large_exponent, gated on hazmat (#​648)
  • Constant-time validation harness using cargo checkct/BINSEC (#​732, #​733, #​749, #​756,
    #​771, #​773)
  • PrivateKey::from_components_with_wide_primes for unbalanced two-prime keys, which ordinary
    constructors now reject (#​755)
  • TryFrom<BitStringRef<'_>> for PKCS#1 v1.5 and PSS signatures (#​764)
  • crypto_common::Generate implementation and Generate re-export for generating 3072-bit keys
    with public exponent 65537 (#​780)
Changed
  • Replace BigUint in the public API with BoxedUint; return NonZero<BoxedUint> for the modulus
    and Odd<BoxedUint> for prime factors (#​394, #​735)
  • Use crypto-primes for prime generation (#​394)
  • Use DER-based key encodings and hex-or-binary serde representations via serdect; extend serde
    support to OAEP, PKCS#1 v1.5, and PSS wrapper types (#​420)
  • Accept arbitrary byte strings as OAEP labels (#​467)
  • Gate PKCS#1/PKCS#8/SPKI support on the default-enabled encoding feature; std no longer
    implicitly enables encoding dependencies (#​537, #​543)
  • Enforce a 1024-bit minimum for key generation and default public-key construction/decoding; add
    PublicKey::new_with_size_limits and hazmat-gated unchecked key generation (#​576, #​760)
  • Bump pkcs1 to v0.8; pkcs8 to v0.11; spki to v0.8; serdect to v0.4 (#​584, #​684, #​688,
    #​766)
  • Make Oaep and Pss generic over their digest types instead of using DynDigest (#​593)
  • Bump rand_core to v0.10, crypto-common to v0.2, digest to v0.11, and signature to v3
    (#​650, #​671, #​693)
  • Remove a redundant allocation during OAEP decryption (#​659)
  • Improve encryption and verification performance by bounding exponentiation to the public
    exponent's bit length (#​662)
  • Bump crypto-bigint to v0.7.10 and crypto-primes to v0.7 (#​673, #​766)
  • Raise the default maximum public-key modulus size to 8192 bits (#​681)
  • Bump sha1 and sha2 to v0.11 (#​683)
  • Store PKCS#1 v1.5 and PSS signatures as byte strings, preserving their encoded width (#​722,
    #​723)
  • MSRV 1.87; Rust 2024 edition (#​731, #​757)
  • Enable getrandom by default and use the system RNG for blinding in default decryption and
    signing paths (#​739, #​758)
  • Limit signature decoding to 1024 bytes by default; add Signature::from_bytes_with_max_len for
    explicit limits (#​767)
  • Require the opt-in pkcs1v15 feature for PKCS#1 v1.5 encryption and signatures (#​778)
  • Accept fallible RNGs through TryCryptoRng and propagate RNG failures as errors (#​779)
  • Rename RsaPrivateKey and RsaPublicKey to PrivateKey and PublicKey, retaining the old names
    as deprecated aliases (#​781)
Deprecated
  • pss::BlindedSigningKey in favor of pss::SigningKey, which now applies blinding by
    default (#​758)
  • PublicKey::new_with_max_size in favor of PublicKey::new_with_size_limits (#​760)
Removed
  • nightly and u64_digit features associated with num-bigint-dig (#​394)
  • Deprecated Pkcs1v15Sign::new_raw and pkcs1v15 *_with_prefix constructors (#​524)
  • Separate pem feature; PEM support is included with encoding (#​537)
  • Optional sha2 feature; SHA-2 support is now always enabled (#​749)
Fixed
  • Honor explicit larger-key construction limits during cryptographic operations, including OAEP
    decryption (#​441, #​595)
  • PKCS#1 v1.5 SigningKey::from and VerifyingKey::from now use the digest prefix consistently
    with new (#​472, #​498)
  • Check the modulus's actual bit length instead of its storage precision when enforcing size limits
    (#​529)
  • Retry zero blinding factors instead of replacing them with one (#​653)
  • Reject private-key factors less than or equal to one, even or repeated factors, and private
    exponents greater than or equal to the modulus (#​655, #​738, #​772, #​774)
  • Reject PSS salt lengths that cannot be represented by the AlgorithmIdentifier encoder instead of
    truncating them (#​704)
  • Apply RFC 8017 encoded-message width rules for PSS, including moduli whose bit length is congruent
    to 1 modulo 8 (#​725)
  • Return verification errors instead of panicking for undersized PSS encoded messages and
    overflowing salt lengths (#​769)
  • Propagate CRT precomputation errors from private-key constructors (#​782)
apache/datafusion-sqlparser-rs (sqlparser)

v0.63.0

Compare Source


Configuration

📅 Schedule: (in timezone Etc/UTC)

  • Branch creation
    • "after 5pm on monday"
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Enabled.

♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate
renovate Bot requested a review from a team as a code owner November 9, 2026 17:34
@renovate renovate Bot added the dependencies Pull requests that update a dependency file label Nov 9, 2026
@renovate
renovate Bot enabled auto-merge (squash) November 9, 2026 17:34
@renovate
renovate Bot requested a review from a team November 9, 2026 17:34
@renovate

renovate Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor Author

⚠️ Artifact update problem

Renovate failed to update artifacts related to this branch. You probably do not want to merge this PR as-is.

♻ Renovate will retry this branch, including artifacts, only when one of the following happens:

  • any of the package files in this branch needs updating, or
  • the branch becomes conflicted, or
  • you click the rebase/retry checkbox if found above, or
  • you rename this PR's title to start with "rebase!" to trigger it manually

The artifact failure details are included below:

File name: nexus/Cargo.lock
    Updating crates.io index
error: failed to select a version for `rsa`.
    ... required by package `peer-snowflake v0.1.0 (/tmp/renovate/repos/github/PeerDB-io/peerdb/nexus/peer-snowflake)`
versions that meet the requirements `^0.10.0` are: 0.10.0

package `peer-snowflake` depends on `rsa` with feature `pem` but `rsa` does not have that feature.
help: there is a feature `std` with a similar name


failed to select a version for `rsa` which could resolve this conflict

File name: nexus/Cargo.lock
    Updating crates.io index
error: failed to select a version for `rsa`.
    ... required by package `peer-snowflake v0.1.0 (/tmp/renovate/repos/github/PeerDB-io/peerdb/nexus/peer-snowflake)`
versions that meet the requirements `^0.10.0` are: 0.10.0

package `peer-snowflake` depends on `rsa` with feature `pem` but `rsa` does not have that feature.
help: there is a feature `std` with a similar name


failed to select a version for `rsa` which could resolve this conflict

File name: nexus/parser/Cargo.lock
    Updating crates.io index
error: failed to select a version for `rsa`.
    ... required by package `peer-snowflake v0.1.0 (/tmp/renovate/repos/github/PeerDB-io/peerdb/nexus/peer-snowflake)`
versions that meet the requirements `^0.10.0` are: 0.10.0

package `peer-snowflake` depends on `rsa` with feature `pem` but `rsa` does not have that feature.
help: there is a feature `std` with a similar name


failed to select a version for `rsa` which could resolve this conflict

File name: nexus/Cargo.lock
    Updating crates.io index
error: failed to select a version for `rsa`.
    ... required by package `peer-snowflake v0.1.0 (/tmp/renovate/repos/github/PeerDB-io/peerdb/nexus/peer-snowflake)`
versions that meet the requirements `^0.10.0` are: 0.10.0

package `peer-snowflake` depends on `rsa` with feature `pem` but `rsa` does not have that feature.
help: there is a feature `std` with a similar name


failed to select a version for `rsa` which could resolve this conflict

File name: nexus/Cargo.lock
    Updating crates.io index
error: failed to select a version for `rsa`.
    ... required by package `peer-snowflake v0.1.0 (/tmp/renovate/repos/github/PeerDB-io/peerdb/nexus/peer-snowflake)`
versions that meet the requirements `^0.10.0` are: 0.10.0

package `peer-snowflake` depends on `rsa` with feature `pem` but `rsa` does not have that feature.
help: there is a feature `std` with a similar name


failed to select a version for `rsa` which could resolve this conflict

File name: nexus/Cargo.lock
    Updating crates.io index
error: failed to select a version for `rsa`.
    ... required by package `peer-snowflake v0.1.0 (/tmp/renovate/repos/github/PeerDB-io/peerdb/nexus/peer-snowflake)`
versions that meet the requirements `^0.10.0` are: 0.10.0

package `peer-snowflake` depends on `rsa` with feature `pem` but `rsa` does not have that feature.
help: there is a feature `std` with a similar name


failed to select a version for `rsa` which could resolve this conflict

File name: nexus/Cargo.lock
    Updating crates.io index
error: failed to select a version for `rsa`.
    ... required by package `peer-snowflake v0.1.0 (/tmp/renovate/repos/github/PeerDB-io/peerdb/nexus/peer-snowflake)`
versions that meet the requirements `^0.10.0` are: 0.10.0

package `peer-snowflake` depends on `rsa` with feature `pem` but `rsa` does not have that feature.
help: there is a feature `std` with a similar name


failed to select a version for `rsa` which could resolve this conflict

Comment thread nexus/catalog/Cargo.toml Outdated
aws-config = { version = "1", optional = true }
aws-sdk-kms = { version = "1", default-features = false, features = ["default-https-client", "rt-tokio"], optional = true }
reqwest = { version = "0.12", default-features = false, features = ["json", "rustls-tls"], optional = true }
reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-tls"], optional = true }

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Build break — already confirmed by CI. reqwest 0.13 renamed the rustls-tls feature to rustls, so this fails during dependency resolution (clippy job):

error: failed to select a version for reqwest.
    ... required by package catalog v0.1.0
package catalog depends on reqwest with feature rustls-tls but reqwest does not have that feature.

This needs features = ["json", "rustls"].

Note that because resolution aborts here, this one error masks every other breakage in the PR. Fixing just the feature name will not turn CI green — see the other inline comments.

Two behaviour changes ride along with the rename, both relevant since this client talks to GCP KMS:

  • The rustls crypto provider now defaults to aws-lc instead of ring. That matches the rest of nexus (pgwire uses server-api-aws-lc-rs, rustls uses aws-lc-rs), so it is an improvement, but it does change what gets linked.
  • Root certificates now come from rustls-platform-verifier by default; the old rustls roots features were removed outright. Since this dependency uses default-features = false, no roots feature was previously enabled, so after the bump trust decisions get delegated to the host platform store. Worth confirming the images nexus ships in actually have a usable system trust store — otherwise KMS calls start failing TLS verification at runtime rather than at build time. tls_certs_only(roots) is the escape hatch if you want roots pinned explicitly.

Comment thread nexus/peer-snowflake/Cargo.toml Outdated
pgwire.workspace = true
pt = { path = "../pt" }
reqwest = { version = "0.12", default-features = false, features = ["json", "gzip", "rustls-tls"] }
reqwest = { version = "0.13", default-features = false, features = ["json", "gzip", "rustls-tls"] }

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Two build breaks on this line.

  1. Same as catalog: rustls-tls was renamed to rustls in reqwest 0.13.

  2. reqwest 0.13 also moved query and form behind opt-in crate features (changelog: "query and form are now crate features, disabled by default"). RequestBuilder::query is now gated on #[cfg(feature = "query")], and this crate calls it in two places:

    • nexus/peer-snowflake/src/lib.rs:163 — .query(&[("async", "true")])
    • nexus/peer-snowflake/src/stream.rs:233 — .query(&[("partition", partition_number.to_string())])

    So this line needs features = ["json", "gzip", "rustls", "query"]. Without it you get no method named query found for struct RequestBuilder. Worth noting the async=true parameter is what makes Snowflake statement submission asynchronous, so this is not a cosmetic call site — it would be easy to "fix" the build by dropping the call.

The default-root-store change described on nexus/catalog/Cargo.toml applies to the Snowflake API client here too.

Comment thread nexus/Cargo.toml Resolved
Comment thread nexus/catalog/Cargo.toml Outdated
reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-tls"], optional = true }
async-trait = "0.1"
base64 = "0.22"
base64 = "0.23"

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

base64 0.23 is API-compatible with how nexus uses it, so no code change is needed. BASE64_STANDARD, the Engine trait and engine::general_purpose::STANDARD are all unchanged across the five call sites (catalog/src/lib.rs:10, value/src/lib.rs:2, value/src/array.rs:3, postgres-connection/src/lib.rs:1, peer-snowflake/src/auth.rs:4), and nothing in the tree matches on DecodeError::InvalidLastSymbol, whose shape changed in this release.

Two things from the release notes worth a deliberate decision rather than a default:

  • 0.23 adds SIMD-accelerated engines behind a default-on simd-unsafe feature (runtime AVX2/NEON dispatch). Every crate here takes base64 with default features, so this pulls new unsafe code into the decode path of, among other things, Snowflake private-key parsing at postgres-connection/src/lib.rs:98. None of these are hot paths — if you would rather not take new unsafe code for no throughput benefit, default-features = false, features = ["std"] keeps the scalar engine.
  • MSRV moved to 1.71.0, comfortably below what the edition-2024 crates in this workspace already require.

Minor lockfile note: expect base64 to appear twice in the regenerated Cargo.lock for a while, since pbjson pulls its own copy.

Comment thread nexus/pt/Cargo.toml Resolved
Comment thread nexus/parser/Cargo.toml Resolved
@claude

claude Bot commented Nov 9, 2026

Copy link
Copy Markdown

Reviewed this Renovate bump against the upstream release notes and commit logs for each crate. Details are in the inline comments; this is the overview plus the one finding that has no line to anchor to.

This does not build as-is. All five bumps are 0.x minors, which are semver-breaking, and the PR carries no source changes.

nexus/Cargo.lock was not regenerated. The renovate/artifacts check failed with "Artifact file update failure", so the lockfile still pins the old versions — pgwire 0.36.3, reqwest 0.12.28, pbjson 0.8.0, base64 0.22.1. That needs to land in this PR.

CI already confirms the first break (clippy): reqwest no longer has a rustls-tls feature. Because that error aborts dependency resolution, it masks everything downstream — renaming the feature alone will not turn CI green.

Crate Range Impact
reqwest 0.12 to 0.13 Breaks build. rustls-tls renamed to rustls; query and form became opt-in features (peer-snowflake calls .query() twice); default roots switched to rustls-platform-verifier
pgwire 0.36 to 0.42 Breaks build. Six breaking minors: QueryParser::parse_sql returns Option and gained two required methods, DataRowEncoder::finish() deprecated (fatal under -D warnings), SCRAM strictness tightened
base64 0.22 to 0.23 Compiles unchanged. New default-on simd-unsafe feature pulls in unsafe SIMD; MSRV 1.71
pbjson 0.8 to 0.9 Compiles unchanged. Edition 2024 plus one feature; the pinned codegen plugin in buf.gen.yaml should track it
sqlparser 0.62 to 0.63 Compiles unchanged. Additive only, and the nexus matches are non-exhaustive

Two things worth a maintainer decision beyond making it compile, both detailed inline: the pgwire SCRAM parser changes are real security fixes but will reject some clients that authenticate today, and nexus/server/src/main.rs:84 Debug-logs LoginInfo at info level, which in 0.42 now carries TLS context including client certificates.

No file in this diff falls under a docs/tricky-areas.md section, and the diff itself introduces no PII or secret logging.

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: Infrastructure flake, not a code bug: five matrix jobs all failed in the pre-test "install lib-geos and pg_dump" setup step with curl: (56) Failure when receiving data from the peer while fetching the PGDG signing key from postgresql.org (no retry flags on that curl), while sibling jobs running the identical step passed and no tests ever executed.
Confidence: 0.97

✅ Automatically retrying the workflow

View workflow run

@claude

claude Bot commented Nov 9, 2026

Copy link
Copy Markdown

Code review — reviewed this Renovate bump per the repo review guidelines (read the upstream release notes for each bumped range). Two blocking issues found.

1. reqwest 0.13 has no rustls-tls feature — the whole nexus workspace fails dependency resolution

The reqwest v0.13.0 changelog lists among its breaking changes: "rustls-tls has been renamed to rustls". These two lines keep the old feature name with default-features = false, so cargo errors out before compiling anything — this is why the clippy/build/docker-build checks are red, and why Renovate's artifact step failed and never regenerated nexus/Cargo.lock (it still pins reqwest 0.12.28, pgwire 0.36.3, sqlparser 0.62.0, pbjson 0.8.0):

aws-sdk-kms = { version = "1", default-features = false, features = ["default-https-client", "rt-tokio"], optional = true }
reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-tls"], optional = true }
async-trait = "0.1"

pt = { path = "../pt" }
reqwest = { version = "0.13", default-features = false, features = ["json", "gzip", "rustls-tls"] }
rsa = { version = "0.9.2", features = ["pem", "pkcs5"] }

Fix: rename "rustls-tls" → "rustls" in both files and regenerate nexus/Cargo.lock. Note the behavior change that comes with it: 0.13 removed the rustls roots features and validates certificates via rustls-platform-verifier by default (instead of webpki roots), which affects the Snowflake REST client and the catalog GCP token fetch.

2. pgwire 0.36 → 0.42 has breaking API changes but the PR contains no source changes — nexus won't compile even after the reqwest blocker is fixed

From the pgwire 0.41.0 changelog: "Breaking: QueryParser::parse_sql now returns PgWireResult<Option<Self::Statement>>" (and PortalStore::get_statement/get_portal now return Option<Entry<…>>). QueryRouter's trait impl still returns PgWireResult<Self::Statement> — a guaranteed trait-signature mismatch:

#[async_trait]
impl QueryParser for QueryRouter {
type Statement = ParsedStatement;
async fn parse_sql<C>(
&self,
_client: &C,
sql: &str,
_types: &[Option<Type>],
) -> PgWireResult<Self::Statement>
where
C: ClientInfo + Unpin + Send + Sync,
{

Also in the bumped range, worth attention during migration:

  • pgwire 0.42.0 rebuilds SASL/SCRAM startup auth on the new AuthMechanism/AuthDriver API and tightens SCRAM channel-binding/strictness checks — PeerDB uses SASLAuthStartupHandler/ScramAuth directly:
    fn startup_handler(&self) -> Arc<impl StartupHandler> {
    Arc::new(
    SASLAuthStartupHandler::new(self.authenticator.1.clone())
    .with_scram(ScramAuth::new(self.authenticator.0.clone())),
    )
  • pbjson/pbjson-types 0.8 → 0.9 bumps the runtime while the generated code in nexus/pt/src/gen comes from the neoeinstein-prost-serde buf plugin pinned at v0.4.0 in buf.gen.yaml; pbjson-generated code is version-coupled to the runtime crate, so this needs a compile check once the workspace resolves again.
  • sqlparser 0.62 → 0.63: the release-notes section in this PR body is empty; AST churn risk for nexus/parser/nexus/analyzer is unverified and will surface in the same compile run.

Recommendation: fix the reqwest feature rename + lockfile, and land the pgwire bump together with the required source migration (or split it out of this PR).

Checked for bugs and CLAUDE.md compliance — no CLAUDE.md violations found.

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: Not a test failure at all — the cockroachdb-v24_ch-lts job died during CI setup when curl got "Recv failure: Connection reset by peer" (exit 56) fetching the PostgreSQL PGDG apt signing key from postgresql.org, so no tests ever ran while all ~28 sibling matrix jobs passed.
Confidence: 0.97

✅ Automatically retrying the workflow

View workflow run

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: Infrastructure flake, not a test or code failure: the mongo-6_ch-lts job died in the "install lib-geos and pg_dump" setup step when an un-retried curl of the PostgreSQL PGDG signing key stalled and returned error 56 ("Failure when receiving data from the peer"), while all 19 other matrix jobs running the identical step passed on this cargo-only Renovate PR.
Confidence: 0.97

✅ Automatically retrying the workflow

View workflow run

Comment thread nexus/Cargo.toml Resolved
@github-actions

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: The single failure is a 4-minute EnvWaitFor timeout waiting for a post-column-drop row to propagate through BigQuery CDC in Test_BigQuery_CDC_Source_Column_Dropped_Mid_CDC, on a Rust-only renovate/cargo PR where the identical test selection passed on the bigquery_ch-lts and bigquery_ch-latest jobs — external BigQuery/ClickHouse propagation latency, not a code defect.
Confidence: 0.92

✅ Automatically retrying the workflow

View workflow run

Comment thread nexus/catalog/Cargo.toml Outdated
aws-config = { version = "1", optional = true }
aws-sdk-kms = { version = "1", default-features = false, features = ["default-https-client", "rt-tokio"], optional = true }
reqwest = { version = "0.12", default-features = false, features = ["json", "rustls-tls"], optional = true }
reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-tls"], optional = true }

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Build break — confirmed by CI. reqwest 0.13 renamed the rustls-tls feature to rustls, so dependency resolution fails before anything compiles:

error: failed to select a version for `reqwest`.
    ... required by package `catalog v0.1.0`
package `catalog` depends on `reqwest` with feature `rustls-tls` but `reqwest` does not have that feature.

That is the cause of both the clippy and docker-build failures on this PR.

It is not a pure rename, though — the trust store changes too. In 0.13 the rustls feature pulls in rustls-platform-verifier, so certificate validation moves to the OS trust store instead of the roots that rustls-tls bundled in 0.12. This code path calls metadata.google.internal and cloudkms.googleapis.com, so please confirm the runtime image can still verify those. stacks/peerdb-server.Dockerfile does apk add --no-cache ca-certificates on Alpine, which should satisfy the platform verifier on musl — but it is a behavioural change that deserves an explicit check rather than an assumption. If you would rather keep bundled roots, add webpki-roots explicitly.

Comment thread nexus/peer-snowflake/Cargo.toml Outdated
pgwire.workspace = true
pt = { path = "../pt" }
reqwest = { version = "0.12", default-features = false, features = ["json", "gzip", "rustls-tls"] }
reqwest = { version = "0.13", default-features = false, features = ["json", "gzip", "rustls-tls"] }

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Two build breaks here, not one.

  1. Same as catalog: rustls-tls no longer exists in reqwest 0.13 — it is now rustls.

  2. The query feature is now required. reqwest 0.13 moved RequestBuilder::query behind a feature that is not in the default set. In 0.13 the defaults are only default-tls, charset, http2, system-proxy, and query = ["dep:serde", "dep:serde_urlencoded"] must be opted into. In 0.12 .query() was compiled unconditionally.

    This crate sets default-features = false and calls it in two places:

    • nexus/peer-snowflake/src/lib.rs:163 — .query(&[("async", "true")])
    • nexus/peer-snowflake/src/stream.rs:233 — .query(&[("partition", partition_number.to_string())])

    So the feature list needs to become roughly ["json", "gzip", "query", "rustls"]. The resolver error on catalog masks this one today — it will only surface once the TLS feature name is fixed.

The trust-anchor change described on nexus/catalog/Cargo.toml applies to the Snowflake HTTPS client as well.

Comment thread nexus/Cargo.toml Resolved
Comment thread nexus/pt/Cargo.toml Resolved
Comment thread nexus/catalog/Cargo.toml Outdated
reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-tls"], optional = true }
async-trait = "0.1"
base64 = "0.22"
base64 = "0.23"

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Heads-up on what base64 0.23 turns on by default — this applies to all four crates bumped in this PR (catalog, peer-snowflake, postgres-connection, value).

0.23 added SIMD-accelerated engines behind a simd-unsafe feature, and that feature is in default (default = ["std", "simd-unsafe"]). Upstream describes it as "the only feature that introduces unsafe; with it disabled the crate is #![forbid(unsafe_code)]" — note the adjacent comment claiming it is off by default is stale, it is in the default set.

So this bump quietly moves base64 from a forbid(unsafe_code) crate to one with hand-written AVX2/NEON intrinsics, on a .0 release, in paths that decode externally-influenced input: catalog/src/lib.rs (KMS payloads), postgres-connection/src/lib.rs:98 (private key material), and value/ (wire values).

The performance win is real and this is not a blocker, but given it is brand-new unsafe code it is worth making an explicit decision rather than inheriting the default — you can keep the old guarantee with default-features = false plus the std feature. The existing call sites (base64::prelude::BASE64_STANDARD / Engine, base64::engine::general_purpose::STANDARD) work either way.

@claude

claude Bot commented Nov 10, 2026

Copy link
Copy Markdown

Dependency bump review

Reviewed all 7 crate bumps against upstream release notes and the Nexus call sites. This PR does not build as-is — clippy and docker-build are both already red, and renovate/artifacts failed so nexus/Cargo.lock was never regenerated. Findings are posted inline; summary:

Crate Range Verdict
reqwest 0.12 → 0.13 Breaks build — rustls-tls renamed to rustls; query dropped from default features (needed by peer-snowflake); trust anchors move to the platform verifier
pgwire 0.36 → 0.42 Breaks build — QueryParser reshaped in 0.41 (new return type + 2 new required methods); DataRowEncoder::finish() deprecated in 0.37 and clippy runs -D warnings
pbjson / pbjson-types 0.8 → 0.9 Runtime bumped, but the pinned neoeinstein-prost-serde:v0.4.0 codegen plugin in buf.gen.yaml was not
base64 0.22 → 0.23 New default-on simd-unsafe feature introduces unsafe SIMD into base64 decode paths
sqlparser 0.62 → 0.63 No breaking changes documented upstream; needs a green build to confirm

nexus/Cargo.lock still pins pgwire 0.36.3, reqwest 0.12.28, sqlparser 0.62.0 and pbjson 0.8.0 — it has to be regenerated and committed with the manifests.

Two notes that are not objections:

  • pgwire 0.42.1 is a SCRAM security hardening release (RFC 5802 §6): it rejects p= channel-binding flags when no server certificate is configured, rejects the y downgrade flag that let a MITM strip the -PLUS mechanism, and rejects over-long client proofs whose trailing bytes were previously silently truncated. Nexus authenticates with SASLAuthStartupHandler + ScramAuth in nexus/server/src/main.rs, so this bump is worth landing — it just needs the call-site migration first.
  • I verified the pgwire features Nexus requests (server-api-aws-lc-rs, pg-type-chrono) still exist in 0.42, and that the AuthSource and SASLAuthStartupHandler signatures Nexus uses are still compatible, so the pgwire migration is narrower than the six-release span suggests.

No secrets or PII logging is introduced — there are no source changes in this PR — and no files under a docs/tricky-areas.md path are touched.

@github-actions

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: Timing-dependent duplicate in TestCockroachDBSuite/Test_CDC_Exactly_Once_Across_Batches on the cockroachdb-v26 job — a stalled resolved timestamp under parallel-subtest load trips the connector's documented force-emit-past-checkpoint fallback, and the PR is a Rust-only Renovate bump that passed the same test on the v24/v25 jobs.
Confidence: 0.85

✅ Automatically retrying the workflow

View workflow run

@renovate renovate Bot added the ai-fix-me Ask the PR Doctor (peerdb-nerve) to fix this PR's failing build label Nov 10, 2026

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Renovate Rust dependency bump - review

Reviewed all eight bumps against upstream release notes and the nexus call sites. This PR is not mergeable as-is: it fails dependency resolution, so none of the bumps have been compiled or type-checked. clippy and docker-build are both red, and Renovate own renovate/artifacts check failed, which is why nexus/Cargo.lock is absent from the diff.

Blocking (confirmed by CI)

  1. rsa 0.10 removed the pem feature -> resolution error in peer-snowflake. It also turns RsaPrivateKey into a deprecated alias, which is fatal under -D warnings.
  2. reqwest 0.13 renamed rustls-tls -> rustls, so both catalog and peer-snowflake fail to resolve; peer-snowflake additionally needs the now-opt-in query feature for its two .query() call sites.
  3. pgwire 0.36 -> 0.42 is six breaking minors with zero code changes: QueryParser::parse_sql signature, two new required QueryParser methods, AuthSource<I>, PortalStore entry types, and a deprecated DataRowEncoder::finish().
  4. nexus/Cargo.lock is out of sync with every manifest in the diff.

Regressions worth a deliberate decision

  • base64 0.23 enables brand-new hand-written unsafe SIMD engines by default (simd-unsafe), including on paths that decode untrusted input.
  • reqwest 0.13 moves rustls trust roots to the OS store via rustls-platform-verifier - fine for the shipped Alpine image, which installs ca-certificates, but a runtime-only failure on minimal bases.
  • pgwire 0.42 adds client TLS certificates to LoginInfo Debug output, which the existing debug-format tracing::info! at server/src/main.rs:84 would then write to logs at info level.

Low risk

  • sqlparser 0.62 -> 0.63: no documented breaking AST changes, but untested here.
  • pbjson / pbjson-types 0.8 -> 0.9: no upstream release notes exist; no generator/runtime skew, since pbjson-build is only a transitive dependency.

Counterpoint in favour of the pgwire bump

0.42.1 fixes genuine SCRAM auth weaknesses that Nexus is directly exposed to via SASLAuthStartupHandler + ScramAuth - channel-binding downgrade when a MITM strips the -PLUS mechanism, and client proofs with appended junk still authenticating. That is worth landing properly rather than losing when this batch is reset.

Suggested split: let base64 / pbjson / sqlparser go through on their own once the lockfile regenerates, and take pgwire, reqwest and rsa as three separate migration PRs.

Per-dependency detail is in the six inline comments. No file in this diff falls under a docs/tricky-areas.md section, so that rule does not apply here.

@github-actions

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: All six failing jobs aborted during CI setup with curl: (56) Failure when receiving data from the peer while downloading the PostgreSQL APT signing key from www.postgresql.org — a transient external network outage unrelated to the Renovate Cargo dependency bump, with no tests ever executing.
Confidence: 0.97

✅ Automatically retrying the workflow

View workflow run

@github-actions

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: Infrastructure flake, not a test failure: the "install lib-geos and pg_dump" setup step's unretried curl of the PGDG signing key from postgresql.org stalled at 0 bytes for ~3 minutes and died with "curl: (56) Failure when receiving data from the peer", killing the postgres-17_other job before any test ran, while all other matrix jobs on the same commit passed.
Confidence: 0.97

✅ Automatically retrying the workflow

View workflow run

peerdb-nerve and others added 7 commits November 16, 2026 17:42
PR doctor for #5055. The bump fails dependency resolution in clippy,
Build and Test and Dev Docker Images: reqwest 0.13 has no `rustls-tls`
feature ("package `catalog` depends on `reqwest` with feature
`rustls-tls` but `reqwest` does not have that feature").

- catalog, peer-snowflake: `rustls-tls` -> `rustls` (renamed in 0.13).
- peer-snowflake: enable `query`, which 0.13 dropped from the default
  features; RequestBuilder::query is used in src/lib.rs and src/stream.rs.

Release notes: https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PR doctor for #5055. Once dependency resolution passes, query-router and
peer-cursor fail to build against pgwire 0.42:

- query-router: QueryParser::parse_sql now returns
  PgWireResult<Option<Statement>>; the existing results are wrapped in
  Some, so empty input still routes to Route::Empty.
- query-router: get_parameter_types and get_result_schema are now
  required. pgwire calls them only from its default
  do_describe_statement/do_describe_portal, which NexusBackend overrides
  (server/src/main.rs), so they return an explicit ApiError instead of
  an empty description that would be silently wrong (claude[bot] review).
- peer-cursor: DataRowEncoder::finish is deprecated since 0.37 (fatal
  under clippy -D warnings); use Ok(encoder.take_row()).

Release notes: https://github.com/sunng87/pgwire/blob/master/CHANGELOG.md

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PR doctor for #5055. sqlparser 0.63 removed the `array` field of
Expr::Cast, so peer-mysql fails to build (E0559 at src/ast.rs:28).
Drop the field; it was `false`, which is the only behaviour 0.63 has.

Changelog: https://github.com/apache/datafusion-sqlparser-rs/tree/main/changelog

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PR doctor for #5055 (keep legacy behaviour). base64 0.23 adds a default
`simd-unsafe` feature with new unsafe SIMD engines. Declare
`default-features = false, features = ["std"]` in catalog,
peer-snowflake, postgres-connection and value, so nexus asks for the
0.22 feature set (claude[bot] review).

Nexus only uses the scalar general_purpose STANDARD engine, which 0.23
leaves unchanged. pgwire, reqwest and hyper-util still enable base64's
default features, so the feature itself remains compiled into the
binary through Cargo feature unification.

Release notes: https://github.com/marshallpierce/rust-base64/blob/master/RELEASE-NOTES.md

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
reqwest 0.13 verifies TLS against the OS trust store
(rustls-platform-verifier), while gcp-bigquery-client is still on
reqwest 0.12, whose rustls-tls feature trusts the bundled Mozilla
roots (webpki-roots), as do the AWS SDK clients. Use
ClientBuilder::tls_certs_only with webpki-root-certs at the four
client-build sites (GCP KMS in catalog, Snowflake query executor and
partition fetch) so every HTTPS client in nexus keeps one common trust
store, as before the upgrade.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PR doctor for #5055. The bump fails dependency resolution in clippy,
Build and Test (PG 14-18) and Dev Docker Images: rsa 0.10 has no `pem`
feature ("package `peer-snowflake` depends on `rsa` with feature `pem`
but `rsa` does not have that feature").

- peer-snowflake/Cargo.toml: drop `pem`; 0.10 folds PEM into the
  `encoding` feature. Keep the 0.9 feature set otherwise:
  `default-features = false, features = ["std", "encoding", "pkcs5"]`,
  so the new default `getrandom` feature (system-RNG blinding in the
  default decrypt/sign paths) stays off, as in 0.9. peer-snowflake only
  decodes PKCS#8 keys and re-encodes them, it does no RSA operation.
- auth.rs: `RsaPrivateKey` -> `PrivateKey`. The old name is a
  deprecated alias in 0.10, which `cargo clippy -- -D warnings` rejects.

Release notes: https://github.com/RustCrypto/RSA/blob/master/CHANGELOG.md

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PR doctor for #5055. renovate/artifacts failed ("Artifact file update
failure": cargo could not resolve rsa's `pem` feature), so the lockfile
still pinned pgwire 0.36, reqwest 0.12, sqlparser 0.62, pbjson 0.8 and
rsa 0.9. Regenerated by cargo for the bumped manifests (pgwire resolves
to 0.42.3, rsa to 0.10.0, one rsa version in the tree); all new sources
are crates.io. webpki-root-certs pinned to 1.0.11, the same CCADB
snapshot as the webpki-roots 1.0.11 already in the lockfile.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PR doctor for #5055. Review finding on the pgwire bump: 0.42 added
`sni_server_name` and `client_certificates` to `LoginInfo`, which
derives Debug, so `tracing::info!("login info: {:?}", login_info)` in
FixedPasswordAuthSource::get_password starts logging the TLS SNI name
the client dialed (and would log client certificates if client auth is
ever enabled; today the acceptor uses with_no_client_auth).

Log the three fields LoginInfo had in 0.36 (user, database, host) in
the same format, so the line stays byte-identical to the old output.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@peerdb-nerve

Copy link
Copy Markdown
Collaborator

PR Doctor: summary of changes

This round answers the review request from 15:56Z. When stop-updating was removed at 15:55Z, Renovate recreated the branch as one commit (7b5327e, rebased on main e0f79a2). That dropped the earlier doctor commits and turned auto-merge back on. On top of the earlier failures, the new head also bumps rsa 0.9.2 → 0.10.0.

I re-applied the earlier per-dependency commits by cherry-pick. They are unchanged: main has not touched nexus/ since 85c7c42. Then I added the rsa unit, a new behaviour unit for the pgwire log line, and the regenerated lockfile. All of it went out as fast-forward pushes 7b5327e..c37d9e0 and c37d9e0..dced9ce, with no force.

Commits, in push order:

  • d77d6ace reqwest 0.12 → 0.13: in catalog/Cargo.toml and peer-snowflake/Cargo.toml, the rustls-tls feature becomes rustls, and peer-snowflake adds query. 0.13 renamed the feature, and query is no longer a default feature. Same as the earlier 016bdfb.
  • f2fc9172 pgwire 0.36 → 0.42:
    • query-router/src/lib.rs: parse_sql now returns Option, and get_parameter_types/get_result_schema return an explicit ApiError.
    • peer-cursor/src/util.rs: finish() becomes take_row().
    • These follow the 0.41 QueryParser change and the 0.37 deprecation. Same as the earlier 06adc33.
  • 992cfa2d sqlparser 0.62 → 0.63: peer-mysql/src/ast.rs drops Expr::Cast::array, because 0.63 removed the field. Same as the earlier 9c1c3b9.
  • f7cac53d base64 0.22 → 0.23: four manifests get default-features = false, features = ["std"], which keeps the new default simd-unsafe engines off, as before the bump. Same as the earlier 2289240.
  • 0e2f4108 reqwest 0.13 TLS roots: catalog gcp_kms_decrypt and the peer-snowflake clients use tls_certs_only with webpki-root-certs, which keeps the bundled roots reqwest 0.12 used. The trust store choice is discussion_r4537431310. Same as the earlier 2f49608.
  • 4a953239 rsa 0.9.2 → 0.10.0 (new):
    • peer-snowflake/Cargo.toml: rsa 0.10 removed the pem feature (PEM now comes with encoding), so the dependency becomes default-features = false, features = ["std", "encoding", "pkcs5"]. This also keeps the new default getrandom feature off.
    • peer-snowflake/src/auth.rs: RsaPrivateKey becomes PrivateKey. The old name is a deprecated alias, which fails under clippy -D warnings.
  • c37d9e0e lockfile: nexus/Cargo.lock regenerated by cargo, with the following resolved versions:
    • pgwire 0.42.3 (0.42.3 only fixes panics on truncated frames).
    • rsa 0.10.0, the only rsa in the tree.
    • webpki-root-certs pinned to 1.0.11, the same CCADB snapshot as webpki-roots 1.0.11.
    • All sources are crates.io. renovate/artifacts could not produce this file, because resolution fails on rsa's pem feature.
  • dced9cef pgwire 0.42 LoginInfo Debug (new, a behaviour unit): in server/src/main.rs:84, the login info log line now prints only user, database and host, in the old format. pgwire 0.42 added sni_server_name and client_certificates to the derived Debug output, so the unchanged line would have started logging both fields.
Details

Failing checks on 7b5327e

These are all the same resolution error:

error: failed to select a version for `rsa`.
package `peer-snowflake` depends on `rsa` with feature `pem` but `rsa` does not have that feature.

The two flaky-test detector comments at 16:11Z and 16:19Z are about run 43902211527 on 7b5327e: a curl of the PGDG APT key failed during setup. That failure has nothing to do with this diff, and the run is superseded by the new head.

Root causes

  • nexus/peer-snowflake/Cargo.toml:20: pem does not exist in rsa 0.10.0. Its features are default = [std, encoding, getrandom], encoding, pkcs5, pkcs1v15, hazmat, serde and sha1. pkcs1 and pkcs8 are pulled in with pem from encoding.
  • nexus/peer-snowflake/src/auth.rs:6,27,90: these lines use the deprecated rsa::RsaPrivateKey alias.
  • nexus/server/src/main.rs:84: this line logs {:?} of LoginInfo. Since 0.42 that struct has two extra fields under _aws-lc-rs, which server-api-aws-lc-rs enables.
  • The earlier units are unchanged; see Update cargo dependencies #5055 (comment) and Update cargo dependencies #5055 (comment).

Local runs

Toolchain: Rust 1.99.1. The catalog is PG18, migrated with go run . migrate.

cargo check --workspace                           (7b5327e6, reproduction)  RC=101  rsa `pem` error as in CI
cargo check --locked                              (dced9cef)                RC=0
cargo clippy --locked -- -D warnings              (dced9cef)                RC=0, 0 warnings
cargo clippy --locked --workspace --all-features -- -D warnings (dced9cef)  RC=0, 0 warnings
cargo test --locked -- --test-threads=1           (dced9cef, PG18 catalog)  RC=0  (24 + 1 + 1 passed, 3 ignored)
rustfmt --check --edition 2024 peer-snowflake/src/auth.rs server/src/main.rs RC=0

rsa 0.9.10 vs 0.10.0 decode parity

I ran a throwaway harness, not committed, on keys freshly generated by openssl. It decodes each key the way SnowflakeAuth::new does: from_pkcs8_pem or from_pkcs8_encrypted_pem, then to_pkcs1_der and to_public_key().to_public_key_der().

  • PKCS#8 keys of 512, 1024, 2048, 4096 and 8192 bits, and encrypted PKCS#8 with AES-256-CBC and with scrypt, decode on both versions with byte-identical PKCS#1 and SPKI DER. For 2048 bits, the output equals openssl rsa -traditional -outform DER and openssl pkey -pubout -outform DER.

  • Some inputs are rejected on both versions:

    • PKCS#1 BEGIN RSA PRIVATE KEY
    • PBES2 with DES-EDE3-CBC (-v2 des3): unsupported OID on both, so this already failed before the bump.
    • a wrong password

    Only the error text differs slightly.

  • A throwaway SnowflakeAuth test on the new head, also not committed, covered the plain key and both encrypted keys. The fingerprint equals SHA256: + base64(sha256(openssl SPKI DER)). The JWT verifies with the openssl public key, with iss and sub as expected.

  • The pgwire throwaway test shows that 0.42 Debug prints LoginInfo { user: Some("alice"), database: Some("db"), host: "127.0.0.1", sni_server_name: None, client_certificates: None }. The new line prints exactly the 0.36 form, LoginInfo { user: Some("alice"), database: Some("db"), host: "127.0.0.1" }.

Not verified locally

  • The docker image build.
  • The PG14-17 legs (I ran PG18 only; CI covers them).
  • A live Snowflake login, because there are no credentials here.
  • A psql smoke test against pgwire 0.42.3. That test was done on 0.42.2 in the earlier round, and 0.42.3 is decode hardening only.

Not committed

rsa 0.10 behaviour change, which I confirmed but did not adapt. PKCS#8 private-key decode now goes through stricter validation:

  • two-prime keys must have balanced primes, each at most ceil(bits/2) (from_components, rsa src/private_key.rs:372);
  • d < n;
  • distinct primes.

The openssl-generated keys above all pass, because openssl generates balanced primes. I did not test a key with unbalanced primes. The closest-to-legacy option would be to decode PKCS#8 by hand and call PrivateKey::from_components_with_wide_primes. That is about 25 lines of key parsing on the credential path, and upstream documents it as a public configuration choice, not a fallback. So I left it out. I can add it if a maintainer wants it.

Bot findings on 7b5327e

  • discussion_r4588187419, rsa: used.
    • pem removed: fixed in 4a95323. I chose default-features = false, ["std", "encoding", "pkcs5"] over the suggested ["pkcs5"] so that the new default getrandom stays off, the closest match to 0.9.
    • Deprecated RsaPrivateKey: fixed in 4a95323.
    • pkcs1v15 not needed: confirmed. The crate builds without it; to_pkcs1_der comes from pkcs1::EncodeRsaPrivateKey.
    • Not confirmed for this path: the 1024-bit minimum and 8192-bit maximum "on key decoding". Those limits apply to PublicKey::new. PKCS#8 private-key decode calls PrivateKey::from_components, which runs check_public with no size limit (rsa src/public_key.rs:227), and the 512-bit and 8192-bit keys above decode on 0.10.0.
  • discussion_r4588188872 and discussion_r4588190643, reqwest:
    • Feature rename and query: used in d77d6ac.
    • OS trust store: handled by 0e2f410 (bundled roots, per the maintainer decision on 11-11).
  • discussion_r4588193100, pgwire:
    • QueryParser, the two new required methods and finish(): used in f2fc917.
    • PortalStore Entry types, AuthSource<I> and FromSqlText for Vec<T>: no source change needed. The workspace builds and passes clippy -D warnings and the tests.
    • LoginInfo Debug logging: confirmed and used in dced9ce. One correction: client certificates are not reachable today, because the TLS acceptor uses with_no_client_auth() (server/src/main.rs:1085). The SNI name and the changed log format are reachable.
  • discussion_r4588194829, base64 simd-unsafe on by default: used in f7cac53.
  • discussion_r4588197267: the lockfile is in c37d9e0, and auto-merge is off (below). Splitting the bump into separate PRs is a maintainer decision, so I did not act on it.
  • Findings from 11-11 that were not committed then (the JWT println! at peer-snowflake/src/stream.rs:230, root parsing per partition in stream.rs, the duplicated client helper) are unchanged. See Update cargo dependencies #5055 (comment).

Notes for the reviewer

  • I added stop-updating again, so Renovate keeps these commits. Removing the label lets Renovate reset the branch, which drops them again, as happened at 15:57Z.
  • Each unit has now used 2 of its 2 PR Doctor attempts, except rsa and the log line. After another reset, I would comment instead of re-applying.

Auto-merge was disabled before these commits and left off.

@github-actions

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: Infrastructure flake, not a test failure: the "install lib-geos and pg_dump" setup step in one matrix job failed with curl (56) after an 87-second stall downloading the PGDG apt signing key from postgresql.org, and fail-fast then canceled all other matrix jobs before any test ran.
Confidence: 0.97

✅ Automatically retrying the workflow

View workflow run

.iter()
.map(|cert| reqwest::Certificate::from_der(cert))
.collect::<reqwest::Result<Vec<_>>>()?;
Ok(reqwest::Client::builder().tls_certs_only(roots))

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

tls_certs_only pins these clients to the Mozilla bundle and discards the OS trust store, which makes this the one spot where the upgrade ends up stricter than reqwest 0.13 default behaviour. The comment acknowledges the tradeoff, but it looks avoidable.

The nexus runtime image does ship an OS trust store (apk add ca-certificates in stacks/peerdb-server.Dockerfile), and bind-mounting an internal or TLS-intercepting proxy CA into /etc/ssl/certs is a common enterprise deployment, so losing platform roots has a real (if niche) blast radius.

ClientBuilder::tls_certs_merge() gets you both halves of the stated goal. In reqwest 0.13 rustls path it routes to rustls_platform_verifier::Verifier::new_with_extra_roots(certs, provider) instead of erroring, so the bundled Mozilla roots are guaranteed present and OS roots keep working:

Ok(reqwest::Client::builder().tls_certs_merge(roots))

Same one-line change applies to catalog/src/lib.rs:87.

Not a regression against 0.12 (which was webpki-roots only), so this is a suggestion rather than a blocker. If you do keep tls_certs_only, it would help to say in the comment why the OS store is deliberately excluded rather than only noting that it is given up.

let url = self.endpoint_url.clone();
println!("Secret: {secret:#?}");
let response = reqwest::Client::new()
let response = crate::http_client_builder()?

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This builds a brand-new reqwest::Client for every partition fetch, and http_client_builder() re-parses all ~150 webpki root certs and constructs a fresh rustls ClientConfig each time. The old reqwest::Client::new() was also per-call, but it had no root-store setup cost, so the bump adds real per-partition overhead (on top of the cold connection pool, which already meant a fresh TLS handshake to Snowflake per partition) on the result-streaming hot path.

SnowflakeQueryExecutor already holds a configured client (lib.rs:113). Threading self.reqwest_client.clone() through SnowflakeRecordStream::new (lib.rs:312 and :335) into SnowflakeRecordStreamInner reuses both the TLS config and the connection pool. It would also enable gzip on partition fetches, which the per-request user-agent override here does not affect.

If that is more churn than you want inside a dependency bump, a std::sync::LazyLock<reqwest::Client> next to http_client_builder() is the one-line version.

catalog::http_client() has the same shape: a fresh client plus a full root-store parse on every gcp_kms_decrypt call.

@@ -228,7 +228,8 @@ impl SnowflakeRecordStreamInner {
let statement_handle = self.result_set.statementHandle.clone();
let url = self.endpoint_url.clone();
println!("Secret: {secret:#?}");

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pre-existing, not introduced by this PR, but it is the line directly above your change so it is worth removing while you are in the file: this prints the Snowflake bearer JWT to stdout on every partition fetch. secret is self.auth.get_jwt()?.expose_secret(), so the secrecy::SecretString wrapper is fully defeated and the credential lands in container logs.

println!("Response: {:#?}", response.data) on line 243 is the same class of problem for customer row data.

Both should just be deleted, or demoted to tracing::debug! with the token elided.

@@ -228,7 +228,8 @@ impl SnowflakeRecordStreamInner {
let statement_handle = self.result_set.statementHandle.clone();
let url = self.endpoint_url.clone();
println!("Secret: {secret:#?}");

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

High severity — credential written to stdout. secret here is self.auth.get_jwt()?.expose_secret(), the Snowflake JWT that is used verbatim as the Authorization: Bearer token three lines below. This println! writes a live credential to the Nexus container stdout, where it reaches Docker/Kubernetes logs and any log shipper attached to them.

This predates the PR, but .claude/REVIEW.md treats secrets on stdout as a high-severity issue, this PR already does secret hygiene one file over (it narrows the LoginInfo logging in server/src/main.rs), and the line immediately below it is being edited here — so please drop it in this PR rather than leaving it for a follow-up:

Suggested change
println!("Secret: {secret:#?}");

If a diagnostic is genuinely wanted at this point, tracing::debug! on partition_number keeps the useful part without the token.

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Renovate bump review: nexus Cargo dependencies

Checked each bumped range against upstream release notes and commit logs for regressions, and verified the hand-written adaptation commits. CI is green (clippy, build = cargo check + cargo test, docker-build), so this review is about semantics rather than compilation. Three inline comments, none blocking.

Worth highlighting: pgwire 0.36 to 0.42 carries security fixes

This is the biggest hop (6 minor versions) and it is clearly net-positive to take:

  • 0.42.2, GHSA-95f6-gpr7-g65r (CVE-2021-23214 shape): plaintext pipelined between SSLRequest and the TLS handshake was carried across the upgrade and executed as if the authenticated TLS client had sent it, with is_secure() reporting true. Introduced in 0.34.2, so nexus on 0.36 is affected today.
  • 0.42.1: SCRAM channel-binding negotiation and proof-validation fixes (-PLUS stripping downgrade, overlong proofs still authenticating). nexus uses SASLAuthStartupHandler + ScramAuth (server/src/main.rs:1127), so this path is live.
  • 0.42.0: per-connection auth state moved out of the shared handler, fixing interleaved authentication state when one handler serves concurrent connections. nexus shares a single startup handler, so this is a real bug fix for us.
  • 0.42.3: errors instead of panics on truncated or malformed frontend message bodies.

Breaking-change adaptations verified

  • DataRowEncoder::finish() to take_row() (deprecated in 0.37): correct. take_row(&mut self) -> DataRow and the encoder is still built per row, so behaviour is unchanged (the 0.37 reuse win is left on the table, but that matches the old code).
  • QueryParser::parse_sql to PgWireResult<Option<_>> (0.41): returning Some(Route::Empty) rather than None preserves the existing nexus empty-query path. Still reachable for comment-only query strings, since pgwire only short-circuits whitespace/semicolon-only input.
  • The new get_parameter_types / get_result_schema stubs returning ApiError: I checked pgwire 0.42.3 src/api/query.rs. Both are only called from the default do_describe_statement / do_describe_portal, and NexusBackend overrides both (server/src/main.rs:876, :893). The stubs are genuinely unreachable and the comment is accurate.
  • AuthSource became AuthSource<I = ()> in 0.42, and the default type parameter is why FixedPasswordAuthSource needed no signature change.
  • LoginInfo gained sni_server_name / client_certificates in its derived Debug, which get_password logs. Already handled in dced9ce by logging the three pre-0.42 fields explicitly. Worth noting the acceptor is with_no_client_auth() (main.rs:1085), so certificates were never actually reachable, but pinning the format is the right call.

Other bumps

  • reqwest 0.12 to 0.13: rustls-tls to rustls, and query is now opt-in (correctly added for peer-snowflake .query(&[...]), correctly omitted for catalog which only uses .json()). Both crates already set default-features = false, so 0.13 gating http2 / charset / system-proxy is not a regression: 0.12 had the identical default list and those were already off. Crypto provider moves ring to aws-lc-rs, which matches the rest of nexus (pgwire server-api-aws-lc-rs, postgres-connection, mysql_async). See the inline note on the trust-store choice.
  • rsa 0.9 to 0.10: RsaPrivateKey to PrivateKey, and encoding now gates PKCS#1/PKCS#8/SPKI plus PEM (std no longer implies it), so the new feature set is right. Dropping the default getrandom feature is safe here: peer-snowflake only decodes a key and derives the public key. It never generates keys or signs with rsa (jsonwebtoken signs via aws-lc-rs from the PKCS#1 DER), so no RNG-dependent path is touched.
  • base64 0.22 to 0.23: default-features = false, features = ["std"] opts out of the default-on simd-unsafe engines that are the headline of 0.23. If that is a deliberate no-unsafe-SIMD call, a one-line comment in the manifest would save the next reader the lookup. Either way it is not a regression against 0.22.
  • sqlparser 0.62 to 0.63: the Expr::Cast { array } field removal is handled in peer-mysql/src/ast.rs. The other behavioural changes in 0.63 (MySQL/Redshift left-associative joins without parens, GLOB/REGEXP/MATCH/IS DISTINCT FROM/DIV precedence, BigQuery FROM-first SELECT, Redshift INTERVAL as a column name) do not touch the PostgreSQL dialect path nexus parses with. Note 0.64.0 is already out, per the Renovate Pending column.
  • pbjson / pbjson-types 0.8 to 0.9: generated-code only, no source changes needed.

Lockfile

rustls-platform-verifier plus its rustls-platform-verifier-android / jni / jni-sys / simd_cesu8 tree now compiles in even though tls_certs_only bypasses the verifier. That is unavoidable: reqwest 0.13 declares dep:rustls-platform-verifier unconditionally under the rustls feature. Two reqwest majors also build into the server now (gcp-bigquery-client 0.28 is still on 0.12), worth watching on the next bump.

.iter()
.map(|cert| reqwest::Certificate::from_der(cert))
.collect::<reqwest::Result<Vec<_>>>()?;
Ok(reqwest::Client::builder().tls_certs_only(roots))

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Efficiency — the root store is rebuilt on every call. TLS_SERVER_ROOT_CERTS holds roughly 160 certificates, and this maps and allocates a fresh Vec<reqwest::Certificate> each time the helper runs. SnowflakeQueryExecutor::new calls it once, which is fine, but stream.rs:231 calls http_client_builder()?.build()? per partition fetch — so a multi-partition result set re-parses the whole root store and builds a brand-new Client (new connection pool, new TLS session cache, full handshake) for every partition. Same shape in catalog/src/lib.rs:82, where http_client() runs on each gcp_kms_decrypt.

Hoisting the parsed roots into a LazyLock<reqwest::Result<Vec<reqwest::Certificate>>> and cloning from it here makes them a one-time cost with no behaviour change.

Separately: the stream.rs client is built without the gzip(true) and the default_headers User-Agent that new() sets up, and the comment at that call site says that Snowflake needs a user agent. That asymmetry is pre-existing (it used to be reqwest::Client::new()), but now that a shared builder exists it would be cheap to thread the already-configured reqwest_client from the executor into the stream instead, fixing pooling, gzip and the User-Agent in one move.

Nit: the five-line rationale comment and the helper body are duplicated verbatim here and in catalog/src/lib.rs, so the next reqwest bump has to be applied in two places.

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Reviewed the bumped ranges against upstream release notes and sources. Build, clippy and docker-build are green, so this review focuses on behaviour the compiler cannot check. Two inline findings are posted; the rest checks out.

Verified against upstream

  • pgwire 0.36 → 0.42.3 — the three adaptations map to real breaking changes: finish() → take_row() (deprecated in 0.37 when DataRowEncoder became reusable), QueryParser::parse_sql returning Option (0.41), and get_parameter_types / get_result_schema becoming required trait methods. I confirmed in pgwire 0.42.3 src/api/query.rs that those two are called only from the default do_describe_statement / do_describe_portal, both of which NexusBackend overrides, and that StoredStatement::parse does not call get_parameter_types — so the error stubs added in query-router are safe. Returning Some(Route::Empty) rather than None for empty queries keeps the pre-0.41 path, and it still lands on Response::EmptyQuery plus no_data(), which matches Postgres. Bonus from the range: 0.42.1 hardens SCRAM channel-binding validation and 0.42.2 refuses plaintext injected between SSLRequest and the TLS handshake (CVE-2021-23214), both relevant to Nexus, which runs SCRAM over TLS.
  • LoginInfo logging — LoginInfo in 0.42 does expose sni_server_name() and client_certificates() through its Debug impl, so narrowing the tracing::info! in server/src/main.rs is a correct and welcome call.
  • reqwest 0.12 → 0.13 — the rustls feature selects aws-lc-rs plus rustls-platform-verifier (consistent with the aws-lc-rs already used by postgres-connection and pgwire), tls_certs_only() exists and disables native and built-in roots exactly as the new comment claims, and .query() did move behind the new query feature, which is added only to peer-snowflake, the one crate that uses it. Pinning to webpki-root-certs reproduces the webpki-roots behaviour of the old rustls-tls feature, so this is a no-op for trust rather than a regression, and every reqwest construction site under nexus/ now goes through the new helpers with none left on Client::new().
  • rsa 0.9 → 0.10 — the RsaPrivateKey to PrivateKey rename is real, pem was folded into encoding, and pkcs5 is still required for from_pkcs8_encrypted_pem. The new 1024-bit minimum on decode is a non-issue since Snowflake mandates 2048-bit or larger key-pair keys. Upside: the move from num-bigint-dig to crypto-bigint brings constant-time modexp, and private-key components are now redacted from Debug output.
  • sqlparser 0.62 → 0.63 — confirmed that Expr::Cast no longer carries an array field, so the peer-mysql/src/ast.rs deletion is required rather than a dropped field.
  • base64 0.22 → 0.23 — disabling default features and enabling only std opts out of the new default-on simd-unsafe engine, so behaviour matches 0.22 without the new SIMD speedup. Reasonable for a crate that does not want fresh unsafe code pulled in.

Note, not blocking: the tree now links reqwest 0.12 and 0.13 side by side, since gcp-bigquery-client still pins 0.12. Worth a follow-up to drop the duplicate HTTP and TLS stack once that dependency moves.

@github-actions

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: Not a test failure at all — four jobs died in the install lib-geos and pg_dump setup step with curl: (56) Failure when receiving data from the peer while downloading the PostgreSQL PGDG signing key, a transient network flake confirmed by 14+ sibling jobs passing the identical step in the same run on an unrelated Renovate Cargo dependency PR.
Confidence: 0.98

✅ Automatically retrying the workflow

View workflow run

@github-actions

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: No tests ran — the postgres-16_ch-lts job failed in CI setup when curl stalled fetching the PGDG apt signing key from www.postgresql.org and exited 56 ("Failure when receiving data from the peer"), a transient network error unrelated to the Renovate cargo bump, while all 20 other matrix jobs running the same step passed.
Confidence: 0.97

✅ Automatically retrying the workflow

View workflow run

@peerdb-nerve

Copy link
Copy Markdown
Collaborator

PR Doctor: All flow test jobs succeeded on dced9ce is not caused by this PR

Failing check: All flow test jobs succeeded in Flow build and test run https://github.com/PeerDB-io/peerdb/actions/runs/43912665433 (head dced9cef). No test job failed. All 21 tilt jobs ended cancelled between 17:00:00Z and 17:00:16Z, in "Start requested ancillary services", before any test ran. Each job carries this annotation:

Canceling since a higher priority waiting request for tilt-flow-5055-postgres-16_ch-lts-imresamu/postgis:16-3.5-alpine-----clickhouse/clickhouse-server:26.8-- exists

Cause (CI scheduling, not the diff):

  1. Run https://github.com/PeerDB-io/peerdb/actions/runs/43912163172 for the previous head c37d9e0e failed at 16:57:30Z: 2 jobs failed in the setup step install lib-geos and pg_dump with curl: (56) Failure when receiving data from the peer, while fetching the PGDG apt key. Fail-fast cancelled the rest.
  2. Auto-Retry Flaky Tests (https://github.com/PeerDB-io/peerdb/actions/runs/43913189892) classified that run as an infra flake. At 16:59:48Z it ran gh run rerun 43912163172 --failed, although c37d9e0e was no longer the PR head.
  3. tilt-flow.yml keys its concurrency group per PR and per input combination (tilt-flow-${{ github.event.pull_request.number || github.ref }}-…), with cancel-in-progress for non-push events. The re-run jobs for the old head therefore joined the same groups as the current head's jobs and cancelled the in-progress jobs of run 43912665433.
  4. The old head's run then needed attempts 2 to 4: the same curl (56) setup failure hit 4 jobs, then 1 job. Attempt 4 passed all 21 tilt jobs (17:20:56Z).

Auto-Retry only re-runs runs that end in failure, so it will not pick up the cancelled run on dced9cef.

Why the current head is expected to pass: git diff c37d9e0e dced9cef touches only nexus/server/src/main.rs (the LoginInfo log line) and nothing under flow/. The tilt jobs run with PEERDB_CI=1, which skips nexus. On dced9cef, Build and Test (cargo check + test), clippy, docker-build, Unit tests (no services) and Test selection coverage are green.

Why I am not committing: the failure is not caused by the PR's diff. What it needs is a re-run of the cancelled run: gh run rerun 43912665433 --failed, or "Re-run failed jobs" in the UI. I leave that to a maintainer.

Bot findings on dced9cef (reviews 17:04Z to 17:05Z):

  • tls_certs_only vs tls_certs_merge (peer-snowflake/src/lib.rs:33, catalog/src/lib.rs). The facts are confirmed, but I am not making the change. On main, reqwest 0.12 rustls-tls trusted the bundled Mozilla roots only, and pinning the 0.13 clients to those roots was the maintainer decision for this PR on 2026-11-11. tls_certs_merge would add the OS trust store, which is new behaviour.
  • Client built per partition fetch (peer-snowflake/src/stream.rs:231, catalog::http_client()). Confirmed in part, not committed. main already built a fresh reqwest::Client per partition fetch. What is new is that each build now loads about 150 roots through tls_certs_only. In reqwest 0.13.5, Certificate::from_der only copies the DER bytes, and the X.509 parse (RootCertStore::add) runs inside ClientBuilder::build(). So caching the Vec<Certificate> in a LazyLock, as one review suggests, would not remove the parse. Only reusing a built client would: either a LazyLock<reqwest::Client>, or passing the executor's client into the stream. Passing the executor's client also changes gzip, the default User-Agent and connection pooling. This is an efficiency trade-off, not a CI failure or a semantic change, so I leave the choice to the maintainers. A comment from a write-access member asking for it is enough for me to commit it.
  • println!("Secret: {secret:#?}") at peer-snowflake/src/stream.rs:230 (and println!("Response: …") at :242). Confirmed: the JWT reaches stdout. Both lines are pre-existing on main at the same place, and this PR's diff does not touch them, so they are out of scope for the PR Doctor here. They should get their own fix.
  • The pgwire, rsa, base64 and sqlparser parts of the reviews request no change and agree with the earlier PR Doctor commits.

Notes for the reviewer:

  • Auto-Retry will cancel the current head's tilt jobs whenever it re-runs a superseded head while a newer run is in flight. Checking github.event.workflow_run.head_sha against the PR's current head before gh run rerun would avoid that.
  • The pull_request_target runs of Flow build and test and Deprecated connector on this branch have ended in startup_failure ("workflow file issue") on both of my pushes since 16:51Z today. Renovate's push at 15:58Z ran fine. pull_request_target runs use main's workflow files and report no checks on this PR, so the PR's diff does not cause these either.

No commits, labels or auto-merge changes in this round.

@github-actions

Copy link
Copy Markdown
Contributor

🔄 Flaky Test Detected

Analysis: Four matrix jobs failed in the "install lib-geos and pg_dump" setup step with curl: (56) Failure when receiving data from the peer while fetching the PGDG signing key from www.postgresql.org — a transient network fault in a non-retried curl that hit all four jobs within the same 12-second window, before any test executed; sibling jobs and unit tests in the same run passed, and the PR only bumps Rust dependencies.
Confidence: 0.97

✅ Automatically retrying the workflow

View workflow run

@pfcoperez
pfcoperez merged commit 16faa02 into main Nov 19, 2026
88 of 115 checks passed
@pfcoperez
pfcoperez deleted the renovate/cargo branch November 19, 2026 09:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai-fix PR Doctor (peerdb-nerve) pushed a fix to this PR ai-fix-me Ask the PR Doctor (peerdb-nerve) to fix this PR's failing build dependencies Pull requests that update a dependency file stop-updating

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants