Skip to content

Trim trailing SP and HTAB for header value on HTTP/1.1#77030

Merged
MihaZupan merged 4 commits intodotnet:mainfrom
Marusyk:rmarusyk/77001
Nov 1, 2022
Merged

Trim trailing SP and HTAB for header value on HTTP/1.1#77030
MihaZupan merged 4 commits intodotnet:mainfrom
Marusyk:rmarusyk/77001

Conversation

@Marusyk
Copy link
Member

@Marusyk Marusyk commented Oct 13, 2022

Trim trailing SP and HTAB for header value on HTTP/1.1

Fixes #77001

Please review
Thank you in advance

@ghost ghost added area-System.Net.Http community-contribution Indicates that the PR has been added by a community member labels Oct 13, 2022
@ghost
Copy link

ghost commented Oct 13, 2022

Tagging subscribers to this area: @dotnet/ncl
See info in area-owners.md if you want to be subscribed.

Issue Details

Trim trailing SP and HTAB for header value on HTTP/1.1

Fixes #77001

Please review
Thank you in advance

Author: Marusyk
Assignees: -
Labels:

area-System.Net.Http

Milestone: -

@build-analysis build-analysis bot mentioned this pull request Oct 14, 2022
2 tasks
@karelz
Copy link
Member

karelz commented Oct 14, 2022

Thanks @Marusyk for your PR! That was fast :)
Would you mind also adding tests for some interesting cases?

Co-authored-by: Miha Zupan <mihazupan.zupan1@gmail.com>
@Marusyk
Copy link
Member Author

Marusyk commented Oct 17, 2022

@MihaZupan
Copy link
Member

MihaZupan commented Oct 17, 2022

I would make this a [Theory] and add more cases to it:

[Fact]
public async Task ResponseHeaders_ExtraWhitespace_Trimmed()

…pHandlerTest.cs

Co-authored-by: Miha Zupan <mihazupan.zupan1@gmail.com>
@MihaZupan MihaZupan added this to the 8.0.0 milestone Nov 1, 2022
@MihaZupan MihaZupan merged commit 5de806e into dotnet:main Nov 1, 2022
@ghost ghost locked as resolved and limited conversation to collaborators Dec 1, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-System.Net.Http community-contribution Indicates that the PR has been added by a community member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SocketsHttpHandler is inconsistent with header value trimming on HTTP/1.1

3 participants