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

[Bug]: Giant psbts cause crash #5768

Closed
1 task done
Kukks opened this issue Feb 19, 2024 · 0 comments
Closed
1 task done

[Bug]: Giant psbts cause crash #5768

Kukks opened this issue Feb 19, 2024 · 0 comments

Comments

@Kukks
Copy link
Member

Kukks commented Feb 19, 2024

What is your BTCPay version?

latest

How did you deploy BTCPay Server?

n/a

What happened?

500 error

How did you encounter this bug?

create a massive psbt using the wallet send

Relevant log output

System.IO.InvalidDataException: Form key length limit 2048 or value length limit 4194304 exceeded.
   at Microsoft.AspNetCore.WebUtilities.FormPipeReader.ThrowKeyOrValueTooLargeException()
   at Microsoft.AspNetCore.WebUtilities.FormPipeReader.ParseValuesSlow(ReadOnlySequence`1& buffer, KeyValueAccumulator& accumulator, Boolean isFinalBlock)
   at Microsoft.AspNetCore.WebUtilities.FormPipeReader.ParseFormValues(ReadOnlySequence`1& buffer, KeyValueAccumulator& accumulator, Boolean isFinalBlock)
   at Microsoft.AspNetCore.WebUtilities.FormPipeReader.ReadFormAsync(CancellationToken cancellationToken)
   at Microsoft.AspNetCore.Http.Features.FormFeature.InnerReadFormAsync(CancellationToken cancellationToken)
   at Microsoft.AspNetCore.Http.Features.FormFeature.ReadForm()
   at BTCPayServer.Security.SecurityExtensions.GetImplicitStoreId(HttpContext httpContext) in /source/BTCPayServer/Security/SecurityExtensions.cs:line 38
   at BTCPayServer.Security.CookieAuthorizationHandler.HandleRequirementAsync(AuthorizationHandlerContext context, PolicyRequirement requirement) in /source/BTCPayServer/Security/CookieAuthorizationHandler.cs:line 69
   at Microsoft.AspNetCore.Authorization.AuthorizationHandler`1.HandleAsync(AuthorizationHandlerContext context)
   at Microsoft.AspNetCore.Authorization.DefaultAuthorizationService.AuthorizeAsync(ClaimsPrincipal user, Object resource, IEnumerable`1 requirements)
   at Microsoft.AspNetCore.Authorization.Policy.PolicyEvaluator.AuthorizeAsync(AuthorizationPolicy policy, AuthenticateResult authenticationResult, HttpContext context, Object resource)
   at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
   at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
   at BTCPayServer.Hosting.BTCPayMiddleware.Invoke(HttpContext httpContext) in /source/BTCPayServer/Hosting/BTCpayMiddleware.cs:line 97
   at BTCPayServer.Hosting.GreenfieldMiddleware.Invoke(HttpContext httpContext) in /source/BTCPayServer/Hosting/GreenfieldMiddleware.cs:line 30
   at Microsoft.AspNetCore.Diagnostics.StatusCodePagesMiddleware.Invoke(HttpContext context)
   at BTCPayServer.Hosting.HeadersOverrideMiddleware.Invoke(HttpContext httpContext) in /source/BTCPayServer/Hosting/HeadersOverrideMiddleware.cs:line 29
   at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.ProcessRequests[TContext](IHttpApplication`1 application)

What browser do you use?

No response

Additional information

No response

Are you sure this is a bug report?

  • I confirm this is a bug report
@Kukks Kukks closed this as completed in 214d4b0 Feb 19, 2024
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

No branches or pull requests

1 participant