Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

chore(deps): update dependency sentry-sdk to v1.14.0 [security] #5355

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Oct 24, 2023

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
sentry-sdk (changelog) ==1.1.0 -> ==1.14.0 age adoption passing confidence

GitHub Vulnerability Alerts

CVE-2023-28117

Impact

When using the Django integration of the Sentry SDK in a specific configuration it is possible to leak sensitive cookies values, including the session cookie to Sentry. These sensitive cookies could then be used by someone with access to your Sentry issues to impersonate or escalate their privileges within your application.

The below must be true in order for these sensitive values to be leaked:

  1. Your Sentry SDK configuration has sendDefaultPII set to True
  2. You are using a custom name for either of the cookies below in your Django settings.
  1. You are not configured in your organization or project settings to use our data scrubbing features to account for the custom cookie names

Patches

As of version 1.14.0, the Django integration of the sentry-sdk will detect the custom cookie names based on your Django settings and will remove the values from the payload before sending the data to Sentry.

Workarounds

If you can not update your sentry-sdk to a patched version than you can use the SDKs filtering mechanism to remove the cookies from the payload that is sent to Sentry. For error events this can be done with the before_send callback method and for performance related events (transactions) you can use the before_send_transaction callback method.

If you'd like to handle filtering of these values on the server-side, you can also use our advanced data scrubbing feature to account for the custom cookie names. Look for the $http.cookies, $http.headers, $request.cookies, or $request.headers fields to target with your scrubbing rule.

References

Credits


Release Notes

getsentry/sentry-python (sentry-sdk)

v1.14.0

Compare Source

Various fixes & improvements
  • Add before_send_transaction (#​1840) by @​antonpirker

    Adds a hook (similar to before_send) that is called for all transaction events (performance releated data).

    Usage:

      import sentry_sdk
    
      def strip_sensitive_data(event, hint):

modify event here (or return None if you want to drop the event entirely)

    return event

sentry_sdk.init(

...

    before_send_transaction=strip_sensitive_data,
)

See also: https://docs.sentry.io/platforms/python/configuration/filtering/#using-platformidentifier-namebefore-send-transaction-

- Django: Always remove values of Django session related cookies. (#​1842) by @​antonpirker
- Profiling: Enable profiling for ASGI frameworks (#​1824) by @​Zylphrex
- Profiling: Better gevent support (#​1822) by @​Zylphrex
- Profiling: Add profile context to transaction (#​1860) by @​Zylphrex
- Profiling: Use co_qualname in python 3.11 (#​1831) by @​Zylphrex
- OpenTelemetry: fix Use dict for sentry-trace context instead of tuple (#​1847) by @​AbhiPrasad
- OpenTelemetry: fix extra dependency (#​1825) by @​bernardotorres
- OpenTelemetry: fix NoOpSpan updates scope (#​1834) by @​Zylphrex
- OpenTelemetry: Make sure to noop when there is no DSN (#​1852) by @​antonpirker
- FastAPI: Fix middleware being patched multiple times (#​1841) by @​JohnnyDeuss
- Starlette: Avoid import of pkg_resource with Starlette integration (#​1836) by @​mgu
- Removed code coverage target (#​1862) by @​antonpirker

v1.13.0

Compare Source

Various fixes & improvements

v1.12.1

Compare Source

Various fixes & improvements

v1.12.0

Compare Source

Basic OTel support

This adds support to automatically integrate OpenTelemetry performance tracing with Sentry.

See the documentation on how to set it up:
https://docs.sentry.io/platforms/python/performance/instrumentation/opentelemetry/

Give it a try and let us know if you have any feedback or problems with using it.

By: @​antonpirker (#​1772, #​1766, #​1765)

Various fixes & improvements

v1.11.1

Compare Source

Various fixes & improvements

v1.11.0

Compare Source

Various fixes & improvements

v1.10.1

Compare Source

Various fixes & improvements

v1.10.0

Compare Source

Various fixes & improvements

v1.9.10

Compare Source

Various fixes & improvements

v1.9.9

Compare Source

Django update (ongoing)
  • Instrument Django Signals so they show up in "Performance" view (#​1526) by @​BeryJu
  • include other Django enhancements brought up by the community
Various fixes & improvements

v1.9.8

Compare Source

Various fixes & improvements
  • Baggage creation for head of trace (#​1589) by @​sl0thentr0py
    • The SDK now also generates new baggage entries for dynamic sampling when it is the first (head) SDK in the pipeline.

v1.9.7

Compare Source

Various fixes & improvements

Note: The last version 1.9.6 introduced a breaking change where projects that used Starlette or FastAPI
and had manually setup SentryAsgiMiddleware could not start. This versions fixes this behaviour.
With this version if you have a manual SentryAsgiMiddleware setup and are using Starlette or FastAPI
everything just works out of the box.

Sorry for any inconveniences the last version might have brought to you.

We can do better and in the future we will do our best to not break your code again.

v1.9.6

Compare Source

Various fixes & improvements

v1.9.5

Compare Source

Various fixes & improvements

v1.9.4

Compare Source

Various fixes & improvements

v1.9.3

Compare Source

Various fixes & improvements

v1.9.2

Compare Source

Various fixes & improvements

v1.9.1

Compare Source

Various fixes & improvements

v1.9.0

Compare Source

Various fixes & improvements

v1.8.0

Compare Source

Various fixes & improvements
  • feat(starlette): add Starlette integration (#​1441) by @​sl0thentr0py
    Important: Remove manual usage of SentryAsgiMiddleware! This is now done by the Starlette integration.
    Usage:

    from starlette.applications import Starlette
    
    from sentry_sdk.integrations.starlette import StarletteIntegration
    
    sentry_sdk.init(
        dsn="...",
        integrations=[StarletteIntegration()],
    )
    
    app = Starlette(debug=True, routes=[...])
  • feat(fastapi): add FastAPI integration (#​829) by @​antonpirker

    Important: Remove manual usage of SentryAsgiMiddleware! This is now done by the FastAPI integration.

    Usage:

    from fastapi import FastAPI
    
    from sentry_sdk.integrations.starlette import StarletteIntegration
    from sentry_sdk.integrations.fastapi import FastApiIntegration
    
    sentry_sdk.init(
        dsn="...",
        integrations=[StarletteIntegration(), FastApiIntegration()],
    )
    
    app = FastAPI()

    Yes, you have to add both, the StarletteIntegration AND the FastApiIntegration!

  • fix: avoid sending empty Baggage header (#​1507) by @​intgr

  • fix: properly freeze Baggage object (#​1508) by @​intgr

  • docs: fix simple typo, collecter | collector (#​1505) by @​timgates42

v1.7.2

Compare Source

Various fixes & improvements

v1.7.1

Compare Source

Various fixes & improvements

v1.7.0

Compare Source

Various fixes & improvements
  • feat(tracing): Dynamic Sampling Context / Baggage continuation (#​1485) by @​sl0thentr0py

    The SDK now propagates the W3C Baggage Header from
    incoming transactions to outgoing requests.
    It also extracts Sentry specific sampling information
    and adds it to the transaction headers to enable Dynamic Sampling in the product.

v1.6.0

Compare Source

Various fixes & improvements

v1.5.12

Compare Source

Various fixes & improvements

v1.5.11

Compare Source

Various fixes & improvements

v1.5.10

Compare Source

Various fixes & improvements

v1.5.9

Compare Source

Various fixes & improvements

v1.5.8

Compare Source

Various fixes & improvements

v1.5.7

Compare Source

Various fixes & improvements

v1.5.6

Compare Source

Various fixes & improvements

v1.5.5

Compare Source

  • Add session tracking to ASGI integration (#​1329)
  • Pinning test requirements versions (#​1330)
  • Allow classes to short circuit serializer with sentry_repr (#​1322)
  • Set default on json.dumps in compute_tracestate_value to ensure string conversion (#​1318)

Work in this release contributed by @​tomchuk. Thank you for your contribution!

v1.5.4

Compare Source

  • Add Python 3.10 to test suite (#​1309)
  • Capture only 5xx HTTP errors in Falcon Integration (#​1314)
  • Attempt custom urlconf resolve in got_request_exception as well (#​1317)

v1.5.3

Compare Source

  • Pick up custom urlconf set by Django middlewares from request if any (#​1308)

v1.5.2

Compare Source

Work in this release contributed by @​johnzeringue, @​pgjones and @​ahopkins. Thank you for your contribution!

v1.5.1

Compare Source

Various fixes & improvements

v1.5.0

Compare Source

  • Also record client outcomes for before send #​1211
  • Add support for implicitly sized envelope items #​1229
  • Fix integration with Apache Beam 2.32, 2.33 #​1233
  • Remove Python 2.7 support for AWS Lambda layers in craft config #​1241
  • Refactor Sanic integration for v21.9 support #​1212
  • AWS Lambda Python 3.9 runtime support #​1239
  • Fix "shutdown_timeout" typing #​1256

Work in this release contributed by @​galuszkak, @​kianmeng, @​ahopkins, @​razumeiko, @​tomscytale, and @​seedofjoy. Thank you for your contribution!

v1.4.3

Compare Source

  • Turned client reports on by default.

v1.4.2

Compare Source

  • Made envelope modifications in the HTTP transport non observable #​1206

v1.4.1

Compare Source

  • Fix race condition between finish and start_child in tracing #​1203

v1.4.0

Compare Source

  • No longer set the last event id for transactions #​1186
  • Added support for client reports (disabled by default for now) #​1181
  • Added tracestate header handling #​1179
  • Added real ip detection to asgi integration #​1199

v1.3.1

Compare Source

  • Fix detection of contextvars compatibility with Gevent versions >=20.9.0 #​1157

v1.3.0

Compare Source

  • Add support for Sanic versions 20 and 21 #​1146

v1.2.0

Compare Source

  • Fix for AWSLambda Integration to handle other path formats for function initial handler #​1139
  • Fix for worker to set daemon attribute instead of deprecated setDaemon method #​1093
  • Fix for bottle Integration that discards -dev for version extraction #​1085
  • Fix for transport that adds a unified hook for capturing metrics about dropped events #​1100
  • Add Httpx Integration #​1119
  • Add support for china domains in AWSLambda Integration #​1051

Configuration

📅 Schedule: Branch creation - "" in timezone US/Eastern, Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

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

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • 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 force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 2 times, most recently from 9ac6bb1 to f972494 Compare February 6, 2024 16:16
@renovate renovate bot changed the title chore(deps): update dependency sentry-sdk to v1.14.0 [security] Update dependency sentry-sdk to v1.14.0 [SECURITY] Feb 6, 2024
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 3 times, most recently from 0e7b516 to 4a0c0fc Compare March 6, 2024 13:53
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 2 times, most recently from 6f9bf17 to a0e7e1c Compare March 26, 2024 12:42
@renovate renovate bot changed the title Update dependency sentry-sdk to v1.14.0 [SECURITY] chore(deps): update dependency sentry-sdk to v1.14.0 [security] Mar 26, 2024
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from a0e7e1c to 56dfaea Compare March 26, 2024 14:37
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from 56dfaea to fd84d11 Compare April 2, 2024 15:05
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 2 times, most recently from b3bd715 to ebb843e Compare April 17, 2024 12:03
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 4 times, most recently from dcf7ab4 to c8e46c4 Compare April 25, 2024 18:07
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from c8e46c4 to 1780d37 Compare May 3, 2024 15:46
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 2 times, most recently from 60ffe11 to d846004 Compare May 20, 2024 19:53
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from d846004 to c9e9232 Compare May 28, 2024 20:06
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 2 times, most recently from b0dda72 to 4811f4e Compare June 17, 2024 15:12
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from 4811f4e to 3ec9fb3 Compare July 18, 2024 17:46
@renovate renovate bot changed the title chore(deps): update dependency sentry-sdk to v1.14.0 [security] chore(deps): update dependency sentry-sdk to v2 [security] Jul 18, 2024
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from 3ec9fb3 to 5ac896d Compare August 6, 2024 09:41
@renovate renovate bot changed the title chore(deps): update dependency sentry-sdk to v2 [security] chore(deps): update dependency sentry-sdk to v1.14.0 [security] Aug 6, 2024
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 3 times, most recently from 7e95a2b to e479682 Compare October 7, 2024 19:19
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from e479682 to 17c93d7 Compare October 17, 2024 14:05
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from 17c93d7 to 2412d6f Compare October 25, 2024 12:21
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 3 times, most recently from 9f6addb to f9e70ca Compare November 25, 2024 15:53
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 3 times, most recently from 5018ce0 to 490810b Compare December 10, 2024 19:04
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch 2 times, most recently from ce99d82 to 9384bba Compare January 13, 2025 16:09
@renovate renovate bot force-pushed the renovate/pypi-sentry-sdk-vulnerability branch from 9384bba to 0569194 Compare January 13, 2025 16:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants