Go to file
Tanay Parikh b124d508b8
Stop throwing exception when writing 0 length buffers (#32277) (#32470)
## Description
Update guard logic to permit writing 0 length buffers. This can happen in certain globalized scenarios (ex. `¿` with Portugese) where the first char needs to be encoded.

Patch https://github.com/dotnet/aspnetcore/issues/31299 for 5.0 by cherry-picking the https://github.com/dotnet/aspnetcore/pull/32277 squash commit.


## Customer Impact
Writing 0-length char buffers leads to an ArgumentOutOfRangeException. This may occur in a globalization context with certain chars such as `¿`.

https://github.com/dotnet/aspnetcore/issues/31299#issuecomment-833078949

Also impacts Orchard: https://github.com/dotnet/aspnetcore/issues/31299#issue-842325059


## Regression?
- [ ] Yes
- [x] No

[If yes, specify the version the behavior has regressed from]

## Risk
- [ ] High
- [ ] Medium
- [x] Low

Low risk as we've just updated the logic slightly to permit 0 length buffers.

## Verification
- [x] Manual (required)
- [x] Automated

## Packaging changes reviewed?
- [ ] Yes
- [ ] No
- [x] N/A


Addresses https://github.com/dotnet/aspnetcore/issues/31299
2021-05-08 20:26:58 -07:00
.azure/pipelines Use Ubuntu18.04 (#31620) 2021-04-08 15:25:06 -07:00
.config Update dependencies from https://github.com/dotnet/efcore build 20201110.8 (#27708) 2020-11-11 06:20:15 +00:00
.github React to runtime release branch rename (#25026) 2020-08-19 01:25:51 +00:00
.vscode Quarantined flaky RazorSDK tests (#22553) 2020-06-04 22:24:23 +00:00
docs Fix invalid Build command (#24771) 2020-08-11 18:27:46 +00:00
eng [release/5.0] Remove MusicStore (#31818) 2021-05-04 16:05:13 -07:00
src Stop throwing exception when writing 0 length buffers (#32277) (#32470) 2021-05-08 20:26:58 -07:00
.editorconfig Enable FxCop Analyzers for the repo (#23709) 2020-07-08 15:26:22 -07:00
.gitattributes Update .gitattributes to include jQuery files (#20537) 2020-06-17 06:17:29 -07:00
.gitignore
.gitmodules
.vsconfig
AspNetCore.sln [release/5.0] Remove MusicStore (#31818) 2021-05-04 16:05:13 -07:00
CODE-OF-CONDUCT.md
CONTRIBUTING.md More updates docs (#20513) 2020-04-03 22:09:36 +00:00
Directory.Build.props [release/5.0] Enable MUSL ARM support (#27942) 2020-11-23 11:49:10 -08:00
Directory.Build.targets [release/5.0] Update API baseline files (#27653) 2020-11-12 10:28:52 -08:00
LICENSE.txt
NuGet.config [internal/release/5.0] Update dependencies from dnceng/internal/dotnet-runtime 2021-03-17 20:13:50 +00:00
README.md Added the link to the IssueManagementPolicies document (#24591) 2020-08-05 15:03:59 -07:00
SECURITY.md
THIRD-PARTY-NOTICES.txt Add Swashbuckle to Third-Party-Notices.txt (#26012) 2020-09-17 13:19:55 -07:00
activate.ps1
activate.sh
build.cmd
build.ps1 Enable ARM64 installers build. (#25579) 2020-09-10 10:59:37 -07:00
build.sh Enable `/warnAsError` (#23072) 2020-06-18 15:59:34 -07:00
clean.cmd
clean.ps1
clean.sh
dockerbuild.sh Pass through BUILD_REPOSITORY_NAME to docker containers (#25620) 2020-09-04 10:07:31 -07:00
global.json Merge pull request #31763 from dotnet/wtgodbe/505Merge 2021-04-13 14:03:15 -07:00
restore.cmd
restore.sh
startvs.cmd

README.md

ASP.NET Core

ASP.NET Core is an open-source and cross-platform framework for building modern cloud based internet connected applications, such as web apps, IoT apps and mobile backends. ASP.NET Core apps run on .NET Core, a free, cross-platform and open-source application runtime. It was architected to provide an optimized development framework for apps that are deployed to the cloud or run on-premises. It consists of modular components with minimal overhead, so you retain flexibility while constructing your solutions. You can develop and run your ASP.NET Core apps cross-platform on Windows, Mac and Linux. Learn more about ASP.NET Core.

Get Started

Follow the Getting Started instructions in the ASP.NET Core docs.

Also check out the .NET Homepage for released versions of .NET, getting started guides, and learning resources.

See the Triage Process document for more information on how we handle incoming issues.

How to Engage, Contribute, and Give Feedback

Some of the best ways to contribute are to try things out, file issues, join in design conversations, and make pull-requests.

Reporting security issues and bugs

Security issues and bugs should be reported privately, via email, to the Microsoft Security Response Center (MSRC) secure@microsoft.com. You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Further information, including the MSRC PGP key, can be found in the Security TechCenter.

These are some other repos for related projects:

Code of conduct

See CODE-OF-CONDUCT