From 6abb1393bf7fcb32bbd7ee58158e0e62f90be5f8 Mon Sep 17 00:00:00 2001 From: Jeremy Barton Date: Thu, 8 Jan 2026 20:30:52 +0000 Subject: [PATCH 01/11] Fix the type of exception thrown when decoding bad headers CoseMessage's Decode routines say that any failure is a CryptographicException, but some of the validation failures leak out ArgumentException from the validation in CoseHeaderMap. --- .../Security/Cryptography/Cose/CoseMessage.cs | 56 ++++++-- .../tests/CoseMessageTests.DecodeMultiSign.cs | 126 ++++++++++++++++++ .../tests/CoseMessageTests.DecodeSign1.cs | 125 +++++++++++++++++ .../CoseMessageTests.Sign.CustomHeaderMaps.cs | 55 +++++--- 4 files changed, 333 insertions(+), 29 deletions(-) diff --git a/src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseMessage.cs b/src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseMessage.cs index 6395c966246ff1..39cb6a0a874f7d 100644 --- a/src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseMessage.cs +++ b/src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseMessage.cs @@ -295,10 +295,19 @@ private static void DecodeUnprotectedBucket(CborReader reader, CoseHeaderMap hea private static void DecodeBucket(CborReader reader, CoseHeaderMap headerParameters) { - int? length = reader.ReadStartMap(); - for (int i = 0; i < length; i++) + reader.ReadStartMap(); + + while (true) { - CoseHeaderLabel label = reader.PeekState() switch + CborReaderState state = reader.PeekState(); + + if (state == CborReaderState.EndMap) + { + reader.ReadEndMap(); + break; + } + + CoseHeaderLabel label = state switch { CborReaderState.UnsignedInteger or CborReaderState.NegativeInteger => new CoseHeaderLabel(reader.ReadInt32()), CborReaderState.TextString => new CoseHeaderLabel(reader.ReadTextString()), @@ -306,9 +315,23 @@ private static void DecodeBucket(CborReader reader, CoseHeaderMap headerParamete }; CoseHeaderValue value = CoseHeaderValue.FromEncodedValue(reader.ReadEncodedValue().Span); - headerParameters.Add(label, value); + + try + { + headerParameters.Add(label, value); + } + catch (ArgumentException e) + { + // Lift the well-known header value validation into a CryptographicException. + if (e.ParamName == "value") + { + throw new CryptographicException(e.Message); + } + + Debug.Fail("Unexpected ArgumentException from CoseHeaderMap.Add"); + throw new CryptographicException(SR.DecodeErrorWhileDecodingSeeInnerEx, e); + } } - reader.ReadEndMap(); } private static byte[]? DecodePayload(CborReader reader) @@ -563,13 +586,23 @@ internal static bool MissingCriticalHeaders(CoseHeaderMap? protectedHeders, out return false; } + bool empty = true; + var reader = new CborReader(critHeaderValue.EncodedValue); - int length = reader.ReadStartArray().GetValueOrDefault(); - Debug.Assert(length > 0); + reader.ReadStartArray(); - for (int i = 0; i < length; i++) + while (true) { - CoseHeaderLabel label = reader.PeekState() switch + CborReaderState state = reader.PeekState(); + + if (state == CborReaderState.EndArray) + { + reader.ReadEndArray(); + break; + } + + empty = false; + CoseHeaderLabel label = state switch { CborReaderState.UnsignedInteger or CborReaderState.NegativeInteger => new CoseHeaderLabel(reader.ReadInt32()), CborReaderState.TextString => new CoseHeaderLabel(reader.ReadTextString()), @@ -583,6 +616,11 @@ internal static bool MissingCriticalHeaders(CoseHeaderMap? protectedHeders, out } } + if (empty) + { + throw new CryptographicException(SR.CriticalHeadersMustBeArrayOfAtLeastOne); + } + labelName = null; return false; } diff --git a/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeMultiSign.cs b/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeMultiSign.cs index 57fd753af4c011..229ef187377512 100644 --- a/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeMultiSign.cs +++ b/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeMultiSign.cs @@ -144,5 +144,131 @@ public void DecodeMultiSign_IndefiniteLengthArray_ShorterByOne(string hexCborPay CryptographicException ex = Assert.Throws(() => CoseMessage.DecodeMultiSign(cborPayload)); Assert.Null(ex.InnerException); } + + [Theory] + [InlineData(true, true)] + [InlineData(true, false)] + [InlineData(false, false)] + [InlineData(false, true)] + public void DecodeMultiSignThrowsIfCriticalHeaderIsMissing(bool detached, bool useIndefiniteLength) + { + const string AttachedDefiniteHex = + "D8628440A054546869732069732074686520636F6E74656E742E818347A20126" + + "0281182AA05840ECB8C39BE15156FB6567C33634C75396D7FE1042C84FE54B9C" + + "EFA51E674C0CB227A8C08E558B6047668BBE3311749776670D1583A14B3A2DD8" + + "7F63F0FA298452"; + + const string AttachedIndefiniteHex = + "D8628440A054546869732069732074686520636F6E74656E742E818348A20126" + + "029F182AFFA05840F62CB760AC27D393D88ED392D5D4D55A02B0BB75261E75FE" + + "9B346C280DA6B93BE7F5B1B66B74561513EA52CAA2C66FE7474010035C678DA6" + + "B3549D3E671166EB"; + + const string DetachedDefiniteHex = + "D8628440A0F6818347A201260281182AA05840F96CE3D0999F34BE0E3FC62AE2" + + "AB25DD8D88F7154E6FADD5FFFEAF78F89DB97AC3E599ADB555C8442BD520F3F4" + + "8CB6A320B864677E26D1FA79FEDD79C3BCA927"; + + const string DetachedIndefiniteHex = + "D8628440A0F6818348A20126029F182AFFA0584028E95F7F9267CED0061339A7" + + "6602D823774EDA3E8D53B0A4FA436B71B0DBCA6F03F561A67355374AF494648C" + + "941558146F9C22B17542EBAF23497D27635A1829"; + + string inputHex = (detached, useIndefiniteLength) switch + { + (false, false) => AttachedDefiniteHex, + (false, true) => AttachedIndefiniteHex, + (true, false) => DetachedDefiniteHex, + (true, true) => DetachedIndefiniteHex, + }; + + AssertExtensions.ThrowsContains( + () => CoseMessage.DecodeMultiSign(ByteUtils.HexToByteArray(inputHex)), + "Critical Header '42' missing from protected map."); + } + + [Theory] + [InlineData(true, true)] + [InlineData(true, false)] + [InlineData(false, false)] + [InlineData(false, true)] + public void DecodeMultiSignThrowsIfCriticalHeadersIsEmpty(bool detached, bool useIndefiniteLength) + { + const string AttachedDefiniteHex = + "D8628440A054546869732069732074686520636F6E74656E742E818345A20126" + + "0280A05840B5F9E21078643A74B181ED294AC72C71F20AC5CA7AD037F559C68E" + + "06148429396A4194133763AB6918D747ACEE820CC430C2E891E3E2D5EECF6126" + + "1CEA33C6D4"; + + const string AttachedIndefiniteHex = + "D8628440A054546869732069732074686520636F6E74656E742E818346A20126" + + "029FFFA05840DDF3C0B85415AD1628C0B50C0F3FEDE675C1003484687CDFA3FA" + + "09285D5A31D48ADF11744BE0AE87F0189408A9CF38F0572537E8A786D505B6A6" + + "EE2008B91C74"; + + const string DetachedDefiniteHex = + "D8628440A0F6818345A201260280A05840EB66EE9E064CAB2E2F50244661734D" + + "9AEBD959BD21278E8D4827870DFE10C27B52E3E21D29185FC64526DC3B80C108" + + "548E956E9DBDDC7B23D100C17715AEE163"; + + const string DetachedIndefiniteHex = + "D8628440A0F6818346A20126029FFFA05840FC954ABD1611F7C6EEDD7FE71C3F" + + "62821AD46ED1988500F3309D0C607F0F151A69D0FC7BC968B2C36AEE68AC2B9A" + + "9580DFE1244F6E5F834183497F21EA5900C1"; + + string inputHex = (detached, useIndefiniteLength) switch + { + (false, false) => AttachedDefiniteHex, + (false, true) => AttachedIndefiniteHex, + (true, false) => DetachedDefiniteHex, + (true, true) => DetachedIndefiniteHex, + }; + + AssertExtensions.ThrowsContains( + () => CoseMessage.DecodeMultiSign(ByteUtils.HexToByteArray(inputHex)), + "Critical Headers must be a CBOR array of at least one element."); + } + + [Theory] + [InlineData(true, true)] + [InlineData(true, false)] + [InlineData(false, false)] + [InlineData(false, true)] + public void DecodeMultiSignThrowsIfCriticalHeaderIsOfUnknownType(bool detached, bool useIndefiniteLength) + { + const string AttachedDefiniteHex = + "D8628440A054546869732069732074686520636F6E74656E742E818347A20126" + + "0281412AA05840FCAFEDBE41693C7BA43FB58E2CF06182BE1BF340122CC5AFD4" + + "F59172C7E95166FF8E98FE9A0C2BEFEA135FD800DE6CA9A281D49B141CB93B17" + + "D992E693540F8A"; + + const string AttachedIndefiniteHex = + "D8628440A054546869732069732074686520636F6E74656E742E818348A20126" + + "029F412AFFA058400D3F4426B26007D731677D99B542E524847FF3927BCA74E4" + + "1823B09D6CA57A0E107F93DFE5DB851F4CEE8C0E4AF83E3540848F026FCD761F" + + "91CA2ED8D5F98134"; + + const string DetachedDefiniteHex = + "D8628440A0F6818347A201260281412AA0584008E0EEF66622FEC926CB651E90" + + "13D8628AB72581533761EDE52972FE6DFBF2C4BADB6C218E8AD1E28F8192DFB2" + + "8A82A4444A74C370AEA6C63AC982EABCD52874"; + + const string DetachedIndefiniteHex = + "D8628440A0F6818348A20126029F412AFFA05840C6DDCA2F35B7B285AB594963" + + "E9DB43CBDC77842256A7D1D31704749C7446AD5A67BBC02F9DBAF8F394ECCCA7" + + "8E8B63E5BB746F0205EE5732DFB2E00EBA3D5F48"; + + string inputHex = (detached, useIndefiniteLength) switch + { + (false, false) => AttachedDefiniteHex, + (false, true) => AttachedIndefiniteHex, + (true, false) => DetachedDefiniteHex, + (true, true) => DetachedIndefiniteHex, + }; + + AssertExtensions.ThrowsContains( + () => CoseMessage.DecodeMultiSign(ByteUtils.HexToByteArray(inputHex)), + "Header '2' does not accept the specified value."); + } } } diff --git a/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeSign1.cs b/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeSign1.cs index 8d3fdb27ad5dea..f06db0413a97b2 100644 --- a/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeSign1.cs +++ b/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeSign1.cs @@ -102,5 +102,130 @@ public void DecodeSign1_IndefiniteLengthArray_ShorterByOne() CryptographicException ex = Assert.Throws(() => CoseMessage.DecodeSign1(cborPayload)); Assert.Null(ex.InnerException); } + + [Theory] + [InlineData(true, true)] + [InlineData(true, false)] + [InlineData(false, false)] + [InlineData(false, true)] + public void DecodeSign1ThrowsIfCriticalHeaderIsMissing(bool detached, bool useIndefiniteLength) + { + const string AttachedDefiniteHex = + "D28447A201260281182AA054546869732069732074686520636F6E74656E742E" + + "5840F78745BDFA8CDF90ED6EC130BC8D97F43C8A52899920221832A1E758A1E7" + + "590827148F6D1A76673E7E9615F628730B19F07707B6FB1C9CD7B6D4E2B3C3F0" + + "DEAD"; + + const string AttachedIndefiniteHex = + "D28448A20126029F182AFFA054546869732069732074686520636F6E74656E74" + + "2E58408B07F60298F64453356EAF005C630A4576AF4C66E0327579BB81B5D726" + + "3836AA9419B1312298DD47BC10BA22D6DEEE35F1526948BF098915816149B46A" + + "3C9981"; + + const string DetachedDefiniteHex = + "D28447A201260281182AA0F6584089B093A038B0636940F9273EF11214B64CC1" + + "BB862305EDEC9C772A3D5089A54A6CBBA00323FA59A593A828F157653DEE15B0" + + "EBBDC070D02CDFD13E8A9F2ECA1B"; + + const string DetachedIndefiniteHex = + "D28448A20126029F182AFFA0F658409B35B9FD294BDF36EEF7494D0EC9E19F6A2" + + "106638FD4A2A31B816FED80493772DCEA8B64F6618119E278379F83E1A62BA382" + + "21B9F1AC705FAD8612DC6B0478A0"; + + string inputHex = (detached, useIndefiniteLength) switch + { + (false, false) => AttachedDefiniteHex, + (false, true) => AttachedIndefiniteHex, + (true, false) => DetachedDefiniteHex, + (true, true) => DetachedIndefiniteHex, + }; + + AssertExtensions.ThrowsContains( + () => CoseMessage.DecodeSign1(ByteUtils.HexToByteArray(inputHex)), + "Critical Header '42' missing from protected map."); + } + + [Theory] + [InlineData(true, true)] + [InlineData(true, false)] + [InlineData(false, false)] + [InlineData(false, true)] + public void DecodeSign1ThrowsIfCriticalHeadersIsEmpty(bool detached, bool useIndefiniteLength) + { + const string AttachedDefiniteHex = + "D28445A201260280A054546869732069732074686520636F6E74656E742E5840" + + "57C7EE86AF06B1ABB002480CE148DFDA06C2CA4AFE83E9C7AE3493EA13E06E9B" + + "0A4C713F7FDCDD2F8731103CDA28B83313E411988B88AC7716E43307B5AF22FD"; + + const string AttachedIndefiniteHex = + "D28446A20126029FFFA054546869732069732074686520636F6E74656E742E58" + + "401B941A9C799270827BE5139EC5F3DE4E072913F6473C7278E691D6C58D407A" + + "23DB3176383E8429AA558418EE33CB7DFFD2CF251EEC93B6CFC300D0D9679CE5" + + "42"; + + const string DetachedDefiniteHex = + "D28445A201260280A0F658409B0EBC937A969A7D4BB2AA0B1004091EDAA00AE2" + + "BBCCBB994B7278C9E50C6C734B3A53CB5B87A99E75F63D16B73757CA23C99CF0" + + "8F8F909A1332DAC05D9DB1C0"; + + const string DetachedIndefiniteHex = + "D28446A20126029FFFA0F65840CA96F1292FEE2B787DC75D91553024E70DD62B" + + "EA0BFE284024385C6D9493EEF6F055825E79244B63E76F69A419C3A36B3B1F18" + + "34789A23983D685B7CDA231E86"; + + string inputHex = (detached, useIndefiniteLength) switch + { + (false, false) => AttachedDefiniteHex, + (false, true) => AttachedIndefiniteHex, + (true, false) => DetachedDefiniteHex, + (true, true) => DetachedIndefiniteHex, + }; + + AssertExtensions.ThrowsContains( + () => CoseMessage.DecodeSign1(ByteUtils.HexToByteArray(inputHex)), + "Critical Headers must be a CBOR array of at least one element."); + } + + [Theory] + [InlineData(true, true)] + [InlineData(true, false)] + [InlineData(false, false)] + [InlineData(false, true)] + public void DecodeSign1ThrowsIfCriticalHeaderIsOfUnknownType(bool detached, bool useIndefiniteLength) + { + const string AttachedDefiniteHex = + "D28447A201260281412AA054546869732069732074686520636F6E74656E742E" + + "58403529AC69F69A80B4055CFFCA88F010390509E0A9D4D0083F23DF46841144" + + "B7E9D7CC11E90D0D51103672083449B439B71EAF6B922C011CC471D8E1D577C6" + + "B954"; + + const string AttachedIndefiniteHex = + "D28448A20126029F412AFFA054546869732069732074686520636F6E74656E74" + + "2E5840FE8A2CBBBA2A154361BEF0892D11FF621A1DBDCBD1A955020DD7D85ED8" + + "15C43B3AB39A32561AAEF679D08FD561339AC9A4E537B2E91DC120A32F406455" + + "F3353F"; + + const string DetachedDefiniteHex = + "D28447A201260281412AA0F65840AB87DA5ABA5A470C7508F5F1724744458407" + + "897746890428F877AD593F9D90E5503A6D1B3369AF77952223D5C474CBB8EC62" + + "9726F967921A4AB91DC8F86DA1CF"; + + const string DetachedIndefiniteHex = + "D28448A20126029F412AFFA0F658409613065203B619BE9CEC1CC596F59C7395" + + "5AEE8BD492F16B72D2C0F443AE70E5E5B1D615A06A90145078B41A1CA12D4067" + + "D6C6CEEB2C19B3747A0926305EBA09"; + + string inputHex = (detached, useIndefiniteLength) switch + { + (false, false) => AttachedDefiniteHex, + (false, true) => AttachedIndefiniteHex, + (true, false) => DetachedDefiniteHex, + (true, true) => DetachedIndefiniteHex, + }; + + AssertExtensions.ThrowsContains( + () => CoseMessage.DecodeSign1(ByteUtils.HexToByteArray(inputHex)), + "Header '2' does not accept the specified value."); + } } } diff --git a/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.Sign.CustomHeaderMaps.cs b/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.Sign.CustomHeaderMaps.cs index e7e3fe1ca782b3..af02047626165c 100644 --- a/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.Sign.CustomHeaderMaps.cs +++ b/src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.Sign.CustomHeaderMaps.cs @@ -517,12 +517,14 @@ public void SignWithCborNegativeIntegerRepresentationAlgorithmHeaderValue(ulong Assert.Throws(() => Sign(s_sampleContent, DefaultKey, DefaultHash, protectedHeaders)); } - [Fact] - public void SignWithCriticalHeaders() + [Theory] + [InlineData(false)] + [InlineData(true)] + public void SignWithCriticalHeaders(bool useIndefiniteLength) { CoseHeaderMap protectedHeaders = GetHeaderMapWithAlgorithm(DefaultAlgorithm); List<(CoseHeaderLabel, ReadOnlyMemory)> expectedProtectedHeaders = GetExpectedProtectedHeaders(DefaultAlgorithm); - AddCriticalHeaders(protectedHeaders, expectedProtectedHeaders, includeSpecifiedCritHeader: true); + AddCriticalHeaders(protectedHeaders, expectedProtectedHeaders, includeSpecifiedCritHeader: true, useIndefiniteLength); CoseSigner signer = GetCoseSigner(DefaultKey, DefaultHash, protectedHeaders); ReadOnlySpan encodedMessage = Sign(s_sampleContent, signer); @@ -530,18 +532,22 @@ public void SignWithCriticalHeaders() AssertCoseSignMessage(encodedMessage, s_sampleContent, DefaultKey, DefaultAlgorithm, expectedProtectedHeaders); } - [Fact] - public void SignWithCriticalHeaders_NotTransportingTheSpecifiedCriticalHeaderThrows() + [Theory] + [InlineData(false)] + [InlineData(true)] + public void SignWithCriticalHeaders_NotTransportingTheSpecifiedCriticalHeaderThrows(bool useIndefiniteLength) { CoseHeaderMap protectedHeaders = GetHeaderMapWithAlgorithm(DefaultAlgorithm); - AddCriticalHeaders(protectedHeaders, null, includeSpecifiedCritHeader: false); + AddCriticalHeaders(protectedHeaders, null, includeSpecifiedCritHeader: false, useIndefiniteLength); CoseSigner signer = GetCoseSigner(DefaultKey, DefaultHash, protectedHeaders); Assert.Throws("signer", () => Sign(s_sampleContent, signer)); } - [Fact] - public void MultiSign_SignWithCriticalHeaders_BodyHeaders() + [Theory] + [InlineData(false)] + [InlineData(true)] + public void MultiSign_SignWithCriticalHeaders_BodyHeaders(bool useIndefiniteLength) { if (MessageKind != CoseMessageKind.MultiSign) { @@ -550,7 +556,7 @@ public void MultiSign_SignWithCriticalHeaders_BodyHeaders() CoseHeaderMap bodyProtectedHeaders = GetEmptyHeaderMap(); List<(CoseHeaderLabel, ReadOnlyMemory)> expectedBodyProtected = GetEmptyExpectedHeaders(); - AddCriticalHeaders(bodyProtectedHeaders, expectedBodyProtected, includeSpecifiedCritHeader: true); + AddCriticalHeaders(bodyProtectedHeaders, expectedBodyProtected, includeSpecifiedCritHeader: true, useIndefiniteLength); CoseSigner signer = GetCoseSigner(DefaultKey, DefaultHash); ReadOnlySpan encodedMessage = Sign(s_sampleContent, signer, bodyProtectedHeaders); @@ -558,8 +564,10 @@ public void MultiSign_SignWithCriticalHeaders_BodyHeaders() AssertCoseSignMessage(encodedMessage, s_sampleContent, DefaultKey, DefaultAlgorithm, expectedMultiSignBodyProtectedHeaders: expectedBodyProtected); } - [Fact] - public void MultiSign_SignWithCriticalHeaders_NotTransportingTheSpecifiedCriticalHeaderThrows_BodyHeaders() + [Theory] + [InlineData(false)] + [InlineData(true)] + public void MultiSign_SignWithCriticalHeaders_NotTransportingTheSpecifiedCriticalHeaderThrows_BodyHeaders(bool useIndefiniteLength) { if (MessageKind != CoseMessageKind.MultiSign) { @@ -567,14 +575,16 @@ public void MultiSign_SignWithCriticalHeaders_NotTransportingTheSpecifiedCritica } CoseHeaderMap bodyProtectedHeaders = GetEmptyHeaderMap(); - AddCriticalHeaders(bodyProtectedHeaders, null, includeSpecifiedCritHeader: false); + AddCriticalHeaders(bodyProtectedHeaders, null, includeSpecifiedCritHeader: false, useIndefiniteLength); CoseSigner signer = GetCoseSigner(DefaultKey, DefaultHash); Assert.Throws("protectedHeaders", () => Sign(s_sampleContent, signer, bodyProtectedHeaders)); } - [Fact] - public void MultiSign_SignWithCriticalHeaders_AddSignature() + [Theory] + [InlineData(false)] + [InlineData(true)] + public void MultiSign_SignWithCriticalHeaders_AddSignature(bool useIndefiniteLength) { if (MessageKind != CoseMessageKind.MultiSign) { @@ -588,7 +598,7 @@ public void MultiSign_SignWithCriticalHeaders_AddSignature() CoseHeaderMap signProtectedHeaders = GetHeaderMapWithAlgorithm(DefaultAlgorithm); List<(CoseHeaderLabel, ReadOnlyMemory)> expectedSignProtected = GetExpectedProtectedHeaders(DefaultAlgorithm); - AddCriticalHeaders(signProtectedHeaders, expectedSignProtected, includeSpecifiedCritHeader: true); + AddCriticalHeaders(signProtectedHeaders, expectedSignProtected, includeSpecifiedCritHeader: true, useIndefiniteLength); CoseSigner signer = GetCoseSigner(DefaultKey, DefaultHash, signProtectedHeaders); AddSignature(multiSignMsg, s_sampleContent, signer); @@ -596,8 +606,10 @@ public void MultiSign_SignWithCriticalHeaders_AddSignature() AssertCoseSignMessage(multiSignMsg.Encode(), s_sampleContent, DefaultKey, DefaultAlgorithm, expectedProtectedHeaders: expectedSignProtected); } - [Fact] - public void MultiSign_SignWithCriticalHeaders_NotTransportingTheSpecifiedCriticalHeaderThrows_AddSignature() + [Theory] + [InlineData(false)] + [InlineData(true)] + public void MultiSign_SignWithCriticalHeaders_NotTransportingTheSpecifiedCriticalHeaderThrows_AddSignature(bool useIndefiniteLength) { if (MessageKind != CoseMessageKind.MultiSign) { @@ -610,18 +622,21 @@ public void MultiSign_SignWithCriticalHeaders_NotTransportingTheSpecifiedCritica multiSignMsg.RemoveSignature(0); CoseHeaderMap signProtectedHeaders = GetHeaderMapWithAlgorithm(DefaultAlgorithm); - AddCriticalHeaders(signProtectedHeaders, null, includeSpecifiedCritHeader: false); + AddCriticalHeaders(signProtectedHeaders, null, includeSpecifiedCritHeader: false, useIndefiniteLength); CoseSigner signer = GetCoseSigner(DefaultKey, DefaultHash, signProtectedHeaders); Assert.Throws("signer", () => AddSignature(multiSignMsg, s_sampleContent, signer)); } private static void AddCriticalHeaders( - CoseHeaderMap protectedHeaders, List<(CoseHeaderLabel, ReadOnlyMemory)>? expectedHeaders, bool includeSpecifiedCritHeader) + CoseHeaderMap protectedHeaders, + List<(CoseHeaderLabel, ReadOnlyMemory)>? expectedHeaders, + bool includeSpecifiedCritHeader, + bool useIndefiniteLength) { Assert.Equal(expectedHeaders != null, includeSpecifiedCritHeader); - CoseHeaderValue critValue = CoseHeaderValue.FromEncodedValue(GetDummyCritHeaderValue()); + CoseHeaderValue critValue = CoseHeaderValue.FromEncodedValue(GetDummyCritHeaderValue(useIndefiniteLength)); protectedHeaders[CoseHeaderLabel.CriticalHeaders] = critValue; expectedHeaders?.Add((CoseHeaderLabel.CriticalHeaders, critValue.EncodedValue)); From 9387001e1f26d9dd07fb0e922db3c2dea4edf78b Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Wed, 11 Feb 2026 16:27:52 -0600 Subject: [PATCH 02/11] [release/9.0] Update dependencies from dotnet/emsdk (#124048) This pull request updates the following dependencies [marker]: <> (Begin:f85f62c8-5e7d-4706-1003-08dcbc30275f) ## From https://github.com/dotnet/emsdk - **Subscription**: [f85f62c8-5e7d-4706-1003-08dcbc30275f](https://maestro.dot.net/subscriptions?search=f85f62c8-5e7d-4706-1003-08dcbc30275f) - **Build**: [20260210.3](https://dev.azure.com/dnceng/internal/_build/results?buildId=2900196) ([301162](https://maestro.dot.net/channel/3883/github:dotnet:emsdk/build/301162)) - **Date Produced**: February 10, 2026 4:20:20 PM UTC - **Commit**: [fb1326b0f4622f04f21584dc133f1c71f7554509](https://github.com/dotnet/emsdk/commit/fb1326b0f4622f04f21584dc133f1c71f7554509) - **Branch**: [release/9.0](https://github.com/dotnet/emsdk/tree/release/9.0) [DependencyUpdate]: <> (Begin) - **Dependency Updates**: - From [9.0.14-servicing.26102.1 to 9.0.14-servicing.26110.3][4] - Microsoft.SourceBuild.Intermediate.emsdk - Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport - From [9.0.14 to 9.0.14][4] - Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100 [4]: https://github.com/dotnet/emsdk/compare/c66fdc1df7...fb1326b0f4 [DependencyUpdate]: <> (End) [marker]: <> (End:f85f62c8-5e7d-4706-1003-08dcbc30275f) [marker]: <> (Begin:Coherency Updates) ## Coherency Updates The following updates ensure that dependencies with a *CoherentParentDependency* attribute were produced in a build used as input to the parent dependency's build. See [Dependency Description Format](https://github.com/dotnet/arcade/blob/master/Documentation/DependencyDescriptionFormat.md#dependency-description-overview) [DependencyUpdate]: <> (Begin) - **Coherency Updates**: - **runtime.linux-arm64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-x64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-x64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.win-arm64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.win-x64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-arm64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-x64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26071.2 to 19.1.0-alpha.1.26104.3 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) [DependencyUpdate]: <> (End) [marker]: <> (End:Coherency Updates) --------- Co-authored-by: dotnet-maestro[bot] --- NuGet.config | 2 +- eng/Version.Details.xml | 98 ++++++++++++++++++++--------------------- eng/Versions.props | 46 +++++++++---------- 3 files changed, 73 insertions(+), 73 deletions(-) diff --git a/NuGet.config b/NuGet.config index b539231b1b50c3..638a9d1e79789c 100644 --- a/NuGet.config +++ b/NuGet.config @@ -9,7 +9,7 @@ - + diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 1d8e72889f59ac..3b924c0f1fef4c 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -12,37 +12,37 @@ https://github.com/dotnet/wcf 7f504aabb1988e9a093c1e74d8040bd52feb2f01 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 https://github.com/dotnet/command-line-api @@ -64,18 +64,18 @@ 1f9985e482df7a0dee94854226d0aecad102ac15 - + https://github.com/dotnet/emsdk - c66fdc1df74783ebdae3c67033c5a9b41aae3bd3 + fb1326b0f4622f04f21584dc133f1c71f7554509 https://github.com/dotnet/emsdk - c66fdc1df74783ebdae3c67033c5a9b41aae3bd3 + fb1326b0f4622f04f21584dc133f1c71f7554509 - + https://github.com/dotnet/emsdk - c66fdc1df74783ebdae3c67033c5a9b41aae3bd3 + fb1326b0f4622f04f21584dc133f1c71f7554509 @@ -226,61 +226,61 @@ https://github.com/dotnet/runtime-assets 70d5fa7d7d041da17e6f3827f55d7d9ceaffdb12 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 - + https://github.com/dotnet/llvm-project - c373980dd30f821fbbdeeb316b839d6efbf688b1 + d34917598a46b95346f56f91006cf9c7f9cb27b3 https://github.com/dotnet/runtime diff --git a/eng/Versions.props b/eng/Versions.props index 045ad89db20dc9..36da101023fe09 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -231,25 +231,25 @@ 2.4.8 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 - 9.0.14-servicing.26102.1 + 9.0.14-servicing.26110.3 9.0.14 $(MicrosoftNETWorkloadEmscriptenCurrentManifest90100Version) - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 - 19.1.0-alpha.1.26071.2 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26104.3 3.1.7 1.0.406601 From cbb9e77463cad3f0023d485f0abd540d5b8ea697 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Cant=C3=BA?= Date: Wed, 11 Feb 2026 20:10:56 -0600 Subject: [PATCH 03/11] [manual] Merge release/9.0-staging into release/9.0 (#124305) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com> Co-authored-by: richlander <2608468+richlander@users.noreply.github.com> Co-authored-by: Miha Zupan Co-authored-by: dotnet-maestro[bot] <42748379+dotnet-maestro[bot]@users.noreply.github.com> Co-authored-by: dotnet-maestro[bot] Co-authored-by: Sven Boemer Co-authored-by: Vladimir Sadov Co-authored-by: Steve Pfister Co-authored-by: Alexander Köplinger Co-authored-by: Jeff Handley Co-authored-by: elinor-fung <47805090+elinor-fung@users.noreply.github.com> Co-authored-by: Elinor Fung Co-authored-by: Andy Gocke Co-authored-by: Eric StJohn Co-authored-by: Matous Kozak Co-authored-by: Filip Navara Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: Larry Ewing Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Jeremy Koritzinsky Co-authored-by: Marie Píchová <11718369+ManickaP@users.noreply.github.com> --- .config/dotnet-tools.json | 2 +- eng/common/core-templates/job/source-build.yml | 2 +- .../coreclr/templates/helix-queues-setup.yml | 12 ++++++------ eng/pipelines/libraries/helix-queues-setup.yml | 8 ++++---- src/coreclr/scripts/superpmi_collect_setup.py | 2 +- src/tests/Interop/COM/ComWrappers/API/Program.cs | 2 +- 6 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json index 8bfe2b1d047a4c..d3371222d3daf5 100644 --- a/.config/dotnet-tools.json +++ b/.config/dotnet-tools.json @@ -15,7 +15,7 @@ ] }, "microsoft.dotnet.xharness.cli": { - "version": "9.0.0-prerelease.25615.2", + "version": "11.0.0-prerelease.26064.3", "commands": [ "xharness" ] diff --git a/eng/common/core-templates/job/source-build.yml b/eng/common/core-templates/job/source-build.yml index 0e5458e1f46cd5..1037ccedcb556c 100644 --- a/eng/common/core-templates/job/source-build.yml +++ b/eng/common/core-templates/job/source-build.yml @@ -65,7 +65,7 @@ jobs: demands: ImageOverride -equals build.ubuntu.2004.amd64 ${{ if eq(variables['System.TeamProject'], 'internal') }}: name: $[replace(replace(eq(contains(coalesce(variables['System.PullRequest.TargetBranch'], variables['Build.SourceBranch'], 'refs/heads/main'), 'release'), 'true'), True, 'NetCore1ESPool-Svc-Internal'), False, 'NetCore1ESPool-Internal')] - image: Azure-Linux-3-Amd64 + image: 1es-azurelinux-3 os: linux ${{ else }}: pool: diff --git a/eng/pipelines/coreclr/templates/helix-queues-setup.yml b/eng/pipelines/coreclr/templates/helix-queues-setup.yml index 402275a132e24f..d345553843d941 100644 --- a/eng/pipelines/coreclr/templates/helix-queues-setup.yml +++ b/eng/pipelines/coreclr/templates/helix-queues-setup.yml @@ -54,11 +54,11 @@ jobs: # iOS devices - ${{ if in(parameters.platform, 'ios_arm64') }}: - - OSX.13.Amd64.Iphone.Open + - OSX.15.Amd64.Iphone.Open # tvOS devices - ${{ if in(parameters.platform, 'tvos_arm64') }}: - - OSX.13.Amd64.AppleTV.Open + - OSX.15.Amd64.AppleTV.Open # Linux arm - ${{ if eq(parameters.platform, 'linux_arm') }}: @@ -105,16 +105,16 @@ jobs: # OSX arm64 - ${{ if eq(parameters.platform, 'osx_arm64') }}: - ${{ if eq(variables['System.TeamProject'], 'public') }}: - - OSX.13.ARM64.Open + - OSX.15.ARM64.Open - ${{ if eq(variables['System.TeamProject'], 'internal') }}: - - OSX.13.ARM64 + - OSX.15.ARM64 # OSX x64 - ${{ if eq(parameters.platform, 'osx_x64') }}: - ${{ if eq(variables['System.TeamProject'], 'public') }}: - - OSX.13.Amd64.Open + - OSX.15.Amd64.Open - ${{ if eq(variables['System.TeamProject'], 'internal') }}: - - OSX.13.Amd64 + - OSX.15.Amd64 # windows x64 - ${{ if eq(parameters.platform, 'windows_x64') }}: diff --git a/eng/pipelines/libraries/helix-queues-setup.yml b/eng/pipelines/libraries/helix-queues-setup.yml index 6bb27678d48dcc..64212601ae5bf8 100644 --- a/eng/pipelines/libraries/helix-queues-setup.yml +++ b/eng/pipelines/libraries/helix-queues-setup.yml @@ -73,11 +73,11 @@ jobs: # OSX arm64 - ${{ if eq(parameters.platform, 'osx_arm64') }}: - - OSX.13.ARM64.Open + - OSX.15.ARM64.Open # OSX x64 - ${{ if eq(parameters.platform, 'osx_x64') }}: - - OSX.13.Amd64.Open + - OSX.15.Amd64.Open # Android - ${{ if in(parameters.platform, 'android_x86', 'android_x64', 'linux_bionic_x64') }}: @@ -95,11 +95,11 @@ jobs: # iOS devices - ${{ if in(parameters.platform, 'ios_arm64') }}: - - OSX.13.Amd64.Iphone.Open + - OSX.15.Amd64.Iphone.Open # tvOS devices - ${{ if in(parameters.platform, 'tvos_arm64') }}: - - OSX.13.Amd64.AppleTV.Open + - OSX.15.Amd64.AppleTV.Open # windows x64 - ${{ if eq(parameters.platform, 'windows_x64') }}: diff --git a/src/coreclr/scripts/superpmi_collect_setup.py b/src/coreclr/scripts/superpmi_collect_setup.py index d1eb398ecace9f..fa885e730e10db 100644 --- a/src/coreclr/scripts/superpmi_collect_setup.py +++ b/src/coreclr/scripts/superpmi_collect_setup.py @@ -465,7 +465,7 @@ def main(main_args): else: helix_queue = "Ubuntu.2204.Amd64" elif platform_name == "osx": - helix_queue = "OSX.13.ARM64" if arch == "arm64" else "OSX.13.Amd64" + helix_queue = "OSX.15.ARM64" if arch == "arm64" else "OSX.15.Amd64" # Copy the superpmi scripts diff --git a/src/tests/Interop/COM/ComWrappers/API/Program.cs b/src/tests/Interop/COM/ComWrappers/API/Program.cs index 3ed01e8604ad3e..8204ce75f6a903 100644 --- a/src/tests/Interop/COM/ComWrappers/API/Program.cs +++ b/src/tests/Interop/COM/ComWrappers/API/Program.cs @@ -1121,7 +1121,7 @@ CustomQueryInterfaceResult ICustomQueryInterface.GetInterface(ref Guid iid, out } } - return CustomQueryInterfaceResult.Failed; + return CustomQueryInterfaceResult.NotHandled; } } } From 0e878939dc69e4b83e17b928e7eddffeb932aaa1 Mon Sep 17 00:00:00 2001 From: Rahul Bhandari Date: Wed, 11 Feb 2026 18:44:33 -0800 Subject: [PATCH 04/11] Revert "[manual] Merge release/9.0-staging into release/9.0 (#124305)" This reverts commit cbb9e77463cad3f0023d485f0abd540d5b8ea697. --- .config/dotnet-tools.json | 2 +- eng/common/core-templates/job/source-build.yml | 2 +- .../coreclr/templates/helix-queues-setup.yml | 12 ++++++------ eng/pipelines/libraries/helix-queues-setup.yml | 8 ++++---- src/coreclr/scripts/superpmi_collect_setup.py | 2 +- src/tests/Interop/COM/ComWrappers/API/Program.cs | 2 +- 6 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json index d3371222d3daf5..8bfe2b1d047a4c 100644 --- a/.config/dotnet-tools.json +++ b/.config/dotnet-tools.json @@ -15,7 +15,7 @@ ] }, "microsoft.dotnet.xharness.cli": { - "version": "11.0.0-prerelease.26064.3", + "version": "9.0.0-prerelease.25615.2", "commands": [ "xharness" ] diff --git a/eng/common/core-templates/job/source-build.yml b/eng/common/core-templates/job/source-build.yml index 1037ccedcb556c..0e5458e1f46cd5 100644 --- a/eng/common/core-templates/job/source-build.yml +++ b/eng/common/core-templates/job/source-build.yml @@ -65,7 +65,7 @@ jobs: demands: ImageOverride -equals build.ubuntu.2004.amd64 ${{ if eq(variables['System.TeamProject'], 'internal') }}: name: $[replace(replace(eq(contains(coalesce(variables['System.PullRequest.TargetBranch'], variables['Build.SourceBranch'], 'refs/heads/main'), 'release'), 'true'), True, 'NetCore1ESPool-Svc-Internal'), False, 'NetCore1ESPool-Internal')] - image: 1es-azurelinux-3 + image: Azure-Linux-3-Amd64 os: linux ${{ else }}: pool: diff --git a/eng/pipelines/coreclr/templates/helix-queues-setup.yml b/eng/pipelines/coreclr/templates/helix-queues-setup.yml index d345553843d941..402275a132e24f 100644 --- a/eng/pipelines/coreclr/templates/helix-queues-setup.yml +++ b/eng/pipelines/coreclr/templates/helix-queues-setup.yml @@ -54,11 +54,11 @@ jobs: # iOS devices - ${{ if in(parameters.platform, 'ios_arm64') }}: - - OSX.15.Amd64.Iphone.Open + - OSX.13.Amd64.Iphone.Open # tvOS devices - ${{ if in(parameters.platform, 'tvos_arm64') }}: - - OSX.15.Amd64.AppleTV.Open + - OSX.13.Amd64.AppleTV.Open # Linux arm - ${{ if eq(parameters.platform, 'linux_arm') }}: @@ -105,16 +105,16 @@ jobs: # OSX arm64 - ${{ if eq(parameters.platform, 'osx_arm64') }}: - ${{ if eq(variables['System.TeamProject'], 'public') }}: - - OSX.15.ARM64.Open + - OSX.13.ARM64.Open - ${{ if eq(variables['System.TeamProject'], 'internal') }}: - - OSX.15.ARM64 + - OSX.13.ARM64 # OSX x64 - ${{ if eq(parameters.platform, 'osx_x64') }}: - ${{ if eq(variables['System.TeamProject'], 'public') }}: - - OSX.15.Amd64.Open + - OSX.13.Amd64.Open - ${{ if eq(variables['System.TeamProject'], 'internal') }}: - - OSX.15.Amd64 + - OSX.13.Amd64 # windows x64 - ${{ if eq(parameters.platform, 'windows_x64') }}: diff --git a/eng/pipelines/libraries/helix-queues-setup.yml b/eng/pipelines/libraries/helix-queues-setup.yml index 64212601ae5bf8..6bb27678d48dcc 100644 --- a/eng/pipelines/libraries/helix-queues-setup.yml +++ b/eng/pipelines/libraries/helix-queues-setup.yml @@ -73,11 +73,11 @@ jobs: # OSX arm64 - ${{ if eq(parameters.platform, 'osx_arm64') }}: - - OSX.15.ARM64.Open + - OSX.13.ARM64.Open # OSX x64 - ${{ if eq(parameters.platform, 'osx_x64') }}: - - OSX.15.Amd64.Open + - OSX.13.Amd64.Open # Android - ${{ if in(parameters.platform, 'android_x86', 'android_x64', 'linux_bionic_x64') }}: @@ -95,11 +95,11 @@ jobs: # iOS devices - ${{ if in(parameters.platform, 'ios_arm64') }}: - - OSX.15.Amd64.Iphone.Open + - OSX.13.Amd64.Iphone.Open # tvOS devices - ${{ if in(parameters.platform, 'tvos_arm64') }}: - - OSX.15.Amd64.AppleTV.Open + - OSX.13.Amd64.AppleTV.Open # windows x64 - ${{ if eq(parameters.platform, 'windows_x64') }}: diff --git a/src/coreclr/scripts/superpmi_collect_setup.py b/src/coreclr/scripts/superpmi_collect_setup.py index fa885e730e10db..d1eb398ecace9f 100644 --- a/src/coreclr/scripts/superpmi_collect_setup.py +++ b/src/coreclr/scripts/superpmi_collect_setup.py @@ -465,7 +465,7 @@ def main(main_args): else: helix_queue = "Ubuntu.2204.Amd64" elif platform_name == "osx": - helix_queue = "OSX.15.ARM64" if arch == "arm64" else "OSX.15.Amd64" + helix_queue = "OSX.13.ARM64" if arch == "arm64" else "OSX.13.Amd64" # Copy the superpmi scripts diff --git a/src/tests/Interop/COM/ComWrappers/API/Program.cs b/src/tests/Interop/COM/ComWrappers/API/Program.cs index 8204ce75f6a903..3ed01e8604ad3e 100644 --- a/src/tests/Interop/COM/ComWrappers/API/Program.cs +++ b/src/tests/Interop/COM/ComWrappers/API/Program.cs @@ -1121,7 +1121,7 @@ CustomQueryInterfaceResult ICustomQueryInterface.GetInterface(ref Guid iid, out } } - return CustomQueryInterfaceResult.NotHandled; + return CustomQueryInterfaceResult.Failed; } } } From b5da1db952b59e29ff3f410dbc37859422b2ba00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tam=C3=A1s=20Csala?= Date: Thu, 19 Feb 2026 04:05:19 +0100 Subject: [PATCH 05/11] #124513 - Guard Base64Url.DecodeFromChars against non-ASCII input (#124540) Base64Url.DecodeFromChars in Microsoft.Bcl.Memory has an out-of-bounds read bug: DecodeFrom uses Unsafe.Add with raw char values as indices into a 256-element DecodingMap without checking the DecodeRemaining return value first. Non-ASCII chars (value > ~2048) cause an AccessViolationException on .NET 8. Workaround: Add System.Text.Ascii.IsValid check before decoding to reject non-ASCII input early. Base64/Base64Url only uses ASCII characters, so any non-ASCII input is inherently invalid. Fixes #124513 --------- Co-authored-by: t.csala --- .../tests/Base64Url/Base64UrlUnicodeAPIsUnitTests.cs | 5 +++-- .../System/Buffers/Text/Base64Helper/Base64DecoderHelper.cs | 5 +++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/libraries/System.Memory/tests/Base64Url/Base64UrlUnicodeAPIsUnitTests.cs b/src/libraries/System.Memory/tests/Base64Url/Base64UrlUnicodeAPIsUnitTests.cs index 0d39bc7854bc24..f90a01e9668f13 100644 --- a/src/libraries/System.Memory/tests/Base64Url/Base64UrlUnicodeAPIsUnitTests.cs +++ b/src/libraries/System.Memory/tests/Base64Url/Base64UrlUnicodeAPIsUnitTests.cs @@ -1,4 +1,4 @@ -// Licensed to the .NET Foundation under one or more agreements. +// Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. using System.Collections.Generic; @@ -196,7 +196,8 @@ public static IEnumerable EncodeToStringTests_TestData() } [Theory] - [InlineData("\u5948cz_T", 0, 0)] // scalar code-path + [InlineData("AB\u1000D", 0, 0)] // scalar code-path, non-ASCII char > 255 (https://github.com/dotnet/runtime/issues/124513) + [InlineData("\u5948cz_T", 0, 0)] // scalar code-path [InlineData("z_Ta123\u5948", 4, 3)] [InlineData("\u5948z_T-H7sqEkerqMweH1uSw==", 0, 0)] // Vector128 code-path [InlineData("z_T-H7sqEkerqMweH1uSw\u5948==", 20, 15)] diff --git a/src/libraries/System.Private.CoreLib/src/System/Buffers/Text/Base64Helper/Base64DecoderHelper.cs b/src/libraries/System.Private.CoreLib/src/System/Buffers/Text/Base64Helper/Base64DecoderHelper.cs index 97765e340acff0..b78e89b0fe6962 100644 --- a/src/libraries/System.Private.CoreLib/src/System/Buffers/Text/Base64Helper/Base64DecoderHelper.cs +++ b/src/libraries/System.Private.CoreLib/src/System/Buffers/Text/Base64Helper/Base64DecoderHelper.cs @@ -167,6 +167,11 @@ internal static unsafe OperationStatus DecodeFrom(TBase64Deco Debug.Assert(typeof(TBase64Decoder) == typeof(Base64DecoderByte) ? remaining == 4 : remaining < 8); int i0 = decoder.DecodeRemaining(srcEnd, ref decodingMap, remaining, out uint t2, out uint t3); + if (i0 < 0) + { + goto InvalidDataExit; + } + byte* destMax = destBytes + (uint)destLength; if (!decoder.IsValidPadding(t3)) From 4ba092c40c8d5812b9fd5198f6daecbd282df7a9 Mon Sep 17 00:00:00 2001 From: Copilot <198982749+Copilot@users.noreply.github.com> Date: Thu, 26 Feb 2026 08:56:49 -0800 Subject: [PATCH 06/11] [release/9.0] Disable ResolveLinkTarget_Succeeds returnFinalTarget=true for UNC paths (#124867) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `ResolveLinkTarget_Succeeds` fails with `IOException: The specified network name is no longer available` on Windows versions that have UNC access disabled, because `SymbolicLink_ResolveLinkTarget_PathToTarget_Data` was yielding UNC paths with `returnFinalTarget=true`, causing Windows to actually attempt to resolve `\\LOCALHOST\share\path`. main PR # Description - In `BaseSymbolicLinks.cs`, split `SymbolicLink_ResolveLinkTarget_PathToTarget_Data` to iterate `PathToTargetData` with both `returnFinalTarget=false/true`, but restrict `PathToTargetUncData` to `returnFinalTarget=false` only - Non-UNC path behavior is unchanged; UNC paths still get basic symlink target verification without the network resolution step that fails on restricted machines ```csharp foreach (string path in PathToTargetData) { yield return new object[] { path, false }; yield return new object[] { path, true }; } // UNC paths are excluded from the returnFinalTarget=true case since // they throw "The specified network name is no longer available" in // various Windows versions. https://github.com/dotnet/runtime/issues/120380 foreach (string path in PathToTargetUncData) { yield return new object[] { path, false }; } ``` # Customer Impact Tests in `FileInfo_SymbolicLinks`, `File_SymbolicLinks`, `DirectoryInfo_SymbolicLinks`, and `Directory_SymbolicLinks` are failing on affected Windows machines, blocking CI. # Regression Not a product regression — test infrastructure issue. Triggered by Windows policy changes disabling UNC paths on certain machines. # Testing Minimal test-only change. The fix narrows the test matrix for UNC paths to avoid exercising the network resolution path that is unavailable on restricted machines. # Risk Very low. Single-line logic change scoped entirely to test data generation. No production code touched. Reduces test coverage only for a scenario (`returnFinalTarget=true` on UNC paths) that cannot reliably run in affected environments. # Package authoring no longer needed in .NET 9 IMPORTANT: Starting with .NET 9, you no longer need to edit a NuGet package's csproj to enable building and bump the version. Keep in mind that we still need package authoring in .NET 8 and older versions.
Original prompt > ## Problem > > As reported in https://github.com/dotnet/runtime/issues/120380, the test `ResolveLinkTarget_Succeeds` (used by `FileInfo_SymbolicLinks`, `File_SymbolicLinks`, `DirectoryInfo_SymbolicLinks`, `Directory_SymbolicLinks`) is failing on various Windows versions that have recently disabled UNC paths with: > > ``` > System.IO.IOException : The specified network name is no longer available > ``` > > The failure occurs because `SymbolicLink_ResolveLinkTarget_PathToTarget_Data` in `BaseSymbolicLinks.cs` yields UNC paths (from `PathToTargetUncData`) with `returnFinalTarget=true`. When resolving a symlink target with `returnFinalTarget=true`, Windows tries to actually resolve the UNC path `\\LOCALHOST\share\path`, which fails on machines where UNC is disabled. > > ## Fix > > In the file `src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Base/SymbolicLinks/BaseSymbolicLinks.cs`, modify the `SymbolicLink_ResolveLinkTarget_PathToTarget_Data` property (lines 56-66) so that UNC paths only yield test cases with `returnFinalTarget=false`, not `true`. > > Current code (lines 56-66): > ```csharp > public static IEnumerable SymbolicLink_ResolveLinkTarget_PathToTarget_Data > { > get > { > foreach (string path in PathToTargetData.Union(PathToTargetUncData)) > { > yield return new object[] { path, false }; > yield return new object[] { path, true }; > } > } > } > ``` > > The fix should change this to iterate `PathToTargetData` with both `false` and `true`, but iterate `PathToTargetUncData` with only `false`: > > ```csharp > public static IEnumerable SymbolicLink_ResolveLinkTarget_PathToTarget_Data > { > get > { > foreach (string path in PathToTargetData) > { > yield return new object[] { path, false }; > yield return new object[] { path, true }; > } > // UNC paths are excluded from the returnFinalTarget=true case since > // they throw "The specified network name is no longer available" in > // various Windows versions. https://github.com/dotnet/runtime/issues/120380 > foreach (string path in PathToTargetUncData) > { > yield return new object[] { path, false }; > } > } > } > ``` > > Only this one property needs to change. The other data properties (`SymbolicLink_LinkTarget_PathToTarget_Data`, `Junction_*`) should remain unchanged.
*This pull request was created from Copilot chat.* > --- 💬 We'd love your input! Share your thoughts on Copilot coding agent in our [2 minute survey](https://gh.io/copilot-coding-agent-survey). --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: jozkee <16040868+jozkee@users.noreply.github.com> --- .../Base/SymbolicLinks/BaseSymbolicLinks.cs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Base/SymbolicLinks/BaseSymbolicLinks.cs b/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Base/SymbolicLinks/BaseSymbolicLinks.cs index adaec2b9094f00..f08d4a0ce2dcc2 100644 --- a/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Base/SymbolicLinks/BaseSymbolicLinks.cs +++ b/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Base/SymbolicLinks/BaseSymbolicLinks.cs @@ -57,11 +57,18 @@ public static IEnumerable SymbolicLink_ResolveLinkTarget_PathToTarget_ { get { - foreach (string path in PathToTargetData.Union(PathToTargetUncData)) + foreach (string path in PathToTargetData) { yield return new object[] { path, false }; yield return new object[] { path, true }; } + // UNC paths are excluded from the returnFinalTarget=true case since + // they throw "The specified network name is no longer available" in + // various Windows versions. https://github.com/dotnet/runtime/issues/120380 + foreach (string path in PathToTargetUncData) + { + yield return new object[] { path, false }; + } } } From 618aa189cda6bdcdfaff78ecb3a93bd9d40a2f77 Mon Sep 17 00:00:00 2001 From: vseanreesermsft <78103370+vseanreesermsft@users.noreply.github.com> Date: Tue, 3 Mar 2026 14:34:36 -0800 Subject: [PATCH 07/11] [release/9.0] Update branding to 9.0.15 (#125131) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This PR updates version branding on branch `release/9.0`. **Changes:** - Repository: runtime - PatchVersion: `14` → `15` **Files Modified:** - eng/Versions.props (+2 -2) --- eng/Versions.props | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/eng/Versions.props b/eng/Versions.props index 36da101023fe09..7435fcc8dfefdb 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -1,11 +1,11 @@ - 9.0.14 + 9.0.15 9 0 - 14 + 15 9.0.100 8.0.$([MSBuild]::Add($(PatchVersion),11)) 7.0.20 From a42ba886bd029ded095c7005a6d8b48a19d272a3 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Wed, 11 Mar 2026 09:30:22 -0700 Subject: [PATCH 08/11] [release/9.0] Update dependencies from dotnet/emsdk (#124464) This pull request updates the following dependencies [marker]: <> (Begin:f85f62c8-5e7d-4706-1003-08dcbc30275f) ## From https://github.com/dotnet/emsdk - **Subscription**: [f85f62c8-5e7d-4706-1003-08dcbc30275f](https://maestro.dot.net/subscriptions?search=f85f62c8-5e7d-4706-1003-08dcbc30275f) - **Build**: [20260310.4](https://dev.azure.com/dnceng/internal/_build/results?buildId=2922894) ([305459](https://maestro.dot.net/channel/3883/github:dotnet:emsdk/build/305459)) - **Date Produced**: March 10, 2026 1:10:37 PM UTC - **Commit**: [dee978139950436eec13cadd76e9a438bdb26d4b](https://github.com/dotnet/emsdk/commit/dee978139950436eec13cadd76e9a438bdb26d4b) - **Branch**: [release/9.0](https://github.com/dotnet/emsdk/tree/release/9.0) [DependencyUpdate]: <> (Begin) - **Dependency Updates**: - From [9.0.14-servicing.26110.3 to 9.0.16-servicing.26160.4][10] - Microsoft.SourceBuild.Intermediate.emsdk - Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport - From [9.0.14 to 9.0.16][10] - Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100 [10]: https://github.com/dotnet/emsdk/compare/fb1326b0f4...dee9781399 [DependencyUpdate]: <> (End) [marker]: <> (End:f85f62c8-5e7d-4706-1003-08dcbc30275f) [marker]: <> (Begin:Coherency Updates) ## Coherency Updates The following updates ensure that dependencies with a *CoherentParentDependency* attribute were produced in a build used as input to the parent dependency's build. See [Dependency Description Format](https://github.com/dotnet/arcade/blob/master/Documentation/DependencyDescriptionFormat.md#dependency-description-overview) [DependencyUpdate]: <> (Begin) - **Coherency Updates**: - **runtime.linux-arm64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-x64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-x64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.win-arm64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.win-x64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-arm64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-x64.Microsoft.NETCore.Runtime.JIT.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.linux-musl-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) - **runtime.osx-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools**: from 19.1.0-alpha.1.26104.3 to 19.1.0-alpha.1.26152.4 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-9.0.100.Transport) [DependencyUpdate]: <> (End) [marker]: <> (End:Coherency Updates) --------- Co-authored-by: dotnet-maestro[bot] Co-authored-by: Larry Ewing --- NuGet.config | 2 +- eng/Version.Details.xml | 100 ++++++++++++++++++++-------------------- eng/Versions.props | 48 +++++++++---------- 3 files changed, 75 insertions(+), 75 deletions(-) diff --git a/NuGet.config b/NuGet.config index 638a9d1e79789c..10d96cfd9794d4 100644 --- a/NuGet.config +++ b/NuGet.config @@ -9,7 +9,7 @@ - + diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 3b924c0f1fef4c..1933e2021da48f 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -12,37 +12,37 @@ https://github.com/dotnet/wcf 7f504aabb1988e9a093c1e74d8040bd52feb2f01
- + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 https://github.com/dotnet/command-line-api @@ -64,18 +64,18 @@ 1f9985e482df7a0dee94854226d0aecad102ac15 - + https://github.com/dotnet/emsdk - fb1326b0f4622f04f21584dc133f1c71f7554509 + dee978139950436eec13cadd76e9a438bdb26d4b - + https://github.com/dotnet/emsdk - fb1326b0f4622f04f21584dc133f1c71f7554509 + dee978139950436eec13cadd76e9a438bdb26d4b - + https://github.com/dotnet/emsdk - fb1326b0f4622f04f21584dc133f1c71f7554509 + dee978139950436eec13cadd76e9a438bdb26d4b @@ -226,61 +226,61 @@ https://github.com/dotnet/runtime-assets 70d5fa7d7d041da17e6f3827f55d7d9ceaffdb12 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 - + https://github.com/dotnet/llvm-project - d34917598a46b95346f56f91006cf9c7f9cb27b3 + ec2b6cf0d0cacbcd527f193599b04725617897a3 https://github.com/dotnet/runtime diff --git a/eng/Versions.props b/eng/Versions.props index 7435fcc8dfefdb..fd6f34bb7c11ea 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -231,26 +231,26 @@ 2.4.8 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 - 9.0.14-servicing.26110.3 - 9.0.14 + 9.0.16-servicing.26160.4 + 9.0.16 $(MicrosoftNETWorkloadEmscriptenCurrentManifest90100Version) - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 - 19.1.0-alpha.1.26104.3 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 + 19.1.0-alpha.1.26152.4 3.1.7 1.0.406601 From a45b4e35a0cdc50fd32a76a2cfa8a80017bcd6c9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 11 Mar 2026 16:00:51 -0700 Subject: [PATCH 09/11] [release/9.0] fix xharness (#125462) Backport of #114746 to release/9.0 /cc @jozkee @pavelsavara Test only change to unblock CI, most likely broken by https://github.com/dotnet/runtime/pull/123122#issuecomment-4042612775. Co-authored-by: pavelsavara --- .../Common/XHarnessRunnerLibrary/GeneratedTestRunner.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/tests/Common/XHarnessRunnerLibrary/GeneratedTestRunner.cs b/src/tests/Common/XHarnessRunnerLibrary/GeneratedTestRunner.cs index 1ef8476239e869..8bce452f9a87c5 100644 --- a/src/tests/Common/XHarnessRunnerLibrary/GeneratedTestRunner.cs +++ b/src/tests/Common/XHarnessRunnerLibrary/GeneratedTestRunner.cs @@ -50,14 +50,14 @@ public override Task Run(IEnumerable testAssemblies) return Task.CompletedTask; } - public override string WriteResultsToFile(XmlResultJargon xmlResultJargon) + public override Task WriteResultsToFile(XmlResultJargon xmlResultJargon) { Debug.Assert(xmlResultJargon == XmlResultJargon.xUnit); File.WriteAllText(ResultsFileName, LastTestRun.GetTestResultOutput(_assemblyName)); - return ResultsFileName; + return Task.FromResult(ResultsFileName); } - public override void WriteResultsToFile(TextWriter writer, XmlResultJargon jargon) + public override Task WriteResultsToFile(TextWriter writer, XmlResultJargon jargon) { Debug.Assert(jargon == XmlResultJargon.xUnit); string lastTestResults = LastTestRun.GetTestResultOutput(_assemblyName); @@ -71,6 +71,7 @@ public override void WriteResultsToFile(TextWriter writer, XmlResultJargon jargo { writer.WriteLine(lastTestResults); } + return Task.CompletedTask; } public override void SkipTests(IEnumerable tests) From 4a0bd270bfced73752fde0a0534c883c64959bc8 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 12 Mar 2026 17:30:50 -0700 Subject: [PATCH 10/11] [release/9.0-staging] Deny unmasked frame receive for WebSocket Server (#123661) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Backport of #123485 to release/9.0-staging /cc @liveans Increasing RFC compliance for WebSocket ## Customer Impact RFC compliance ## Regression No ## Testing Manual verification + automated tests ## Risk Low, the change only affects non‑compliant WebSocket clients sending unmasked frames, which is explicitly disallowed by RFC 6455. No behavior change is expected for compliant clients. --------- Co-authored-by: Ahmet İbrahim Aksoy Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- .../src/Resources/Strings.resx | 3 +++ .../src/System/Net/WebSockets/ManagedWebSocket.cs | 5 +++++ .../System.Net.WebSockets/tests/WebSocketTests.cs | 14 ++++++++++++++ 3 files changed, 22 insertions(+) diff --git a/src/libraries/System.Net.WebSockets/src/Resources/Strings.resx b/src/libraries/System.Net.WebSockets/src/Resources/Strings.resx index a57e81b239a92c..a6033ed9cf8313 100644 --- a/src/libraries/System.Net.WebSockets/src/Resources/Strings.resx +++ b/src/libraries/System.Net.WebSockets/src/Resources/Strings.resx @@ -117,6 +117,9 @@ The WebSocket server sent a masked frame. + + The WebSocket client sent an unmasked frame. + The WebSocket received a continuation frame from a previous final message. diff --git a/src/libraries/System.Net.WebSockets/src/System/Net/WebSockets/ManagedWebSocket.cs b/src/libraries/System.Net.WebSockets/src/System/Net/WebSockets/ManagedWebSocket.cs index 8a26a4c29e2eb0..1e80e82bdde01a 100644 --- a/src/libraries/System.Net.WebSockets/src/System/Net/WebSockets/ManagedWebSocket.cs +++ b/src/libraries/System.Net.WebSockets/src/System/Net/WebSockets/ManagedWebSocket.cs @@ -1366,6 +1366,11 @@ private async ValueTask CloseWithReceiveErrorAndThrowAsync( // Consume the mask bytes ConsumeFromBuffer(4); } + else if (_isServer) + { + resultHeader = default; + return SR.net_Websockets_ServerReceivedUnmaskedFrame; + } // Do basic validation of the header switch (header.Opcode) diff --git a/src/libraries/System.Net.WebSockets/tests/WebSocketTests.cs b/src/libraries/System.Net.WebSockets/tests/WebSocketTests.cs index 73e84998a94197..41c7fe341d266d 100644 --- a/src/libraries/System.Net.WebSockets/tests/WebSocketTests.cs +++ b/src/libraries/System.Net.WebSockets/tests/WebSocketTests.cs @@ -182,6 +182,20 @@ public async Task ThrowWhenContinuationWithDifferentCompressionFlags() client.SendAsync(Memory.Empty, WebSocketMessageType.Binary, WebSocketMessageFlags.EndOfMessage, default)); } + [Fact] + public async Task ReceiveAsync_ServerUnmaskedFrame_ThrowsWebSocketException() + { + byte[] frame = { 0x81, 0x05, 0x48, 0x65, 0x6C, 0x6C, 0x6F }; + using var stream = new MemoryStream(); + stream.Write(frame, 0, frame.Length); + stream.Position = 0; + using WebSocket websocket = WebSocket.CreateFromStream(stream, new WebSocketCreationOptions { IsServer = true }); + WebSocketException exception = await Assert.ThrowsAsync(() => + websocket.ReceiveAsync(new byte[5], CancellationToken.None)); + Assert.Equal(SR.net_Websockets_ServerReceivedUnmaskedFrame, exception.Message); + Assert.Equal(WebSocketState.Aborted, websocket.State); + } + [Fact] public async Task ReceiveAsync_WhenDisposedInParallel_DoesNotGetStuck() { From ef7db8d8bffdec68b4ffc583d9447c96dc90799d Mon Sep 17 00:00:00 2001 From: Larry Ewing Date: Sun, 15 Mar 2026 13:29:08 -0500 Subject: [PATCH 11/11] [release/9.0] Disable Datagram_UDP_AccessDenied_Throws_DoesNotBind on all macOS/MacCatalyst (#125568) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Summary macOS 15+ returns `EHOSTUNREACH` instead of `EACCES` for UDP broadcast without `SO_BROADCAST` due to Apple's [Local Network privacy feature](https://developer.apple.com/forums/thread/765285). The test expects `SocketError.AccessDenied` but gets `SocketError.HostUnreachable`. The existing `ActiveIssue` (from #113313) only disabled on MacCatalyst x64. The failure affects all macOS 15+ platforms — confirmed on `osx.15.amd64` in both coreclr and Mono legs in [#125564](https://github.com/dotnet/runtime/pull/125564). ## Change Broadens the `ActiveIssue` from: ```csharp [ActiveIssue("...", typeof(PlatformDetection), nameof(PlatformDetection.IsMacCatalyst), nameof(PlatformDetection.IsX64Process))] ``` to: ```csharp [ActiveIssue("...", TestPlatforms.OSX | TestPlatforms.MacCatalyst)] ``` @ManickaP requested this backport in https://github.com/dotnet/runtime/issues/114450#issuecomment-3846729058. Fixes #114450 on release/9.0. cc @liveans @kotlarmilos @ManickaP Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../System.Net.Sockets/tests/FunctionalTests/SendTo.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libraries/System.Net.Sockets/tests/FunctionalTests/SendTo.cs b/src/libraries/System.Net.Sockets/tests/FunctionalTests/SendTo.cs index 0b01469e574e91..5e8928818e7909 100644 --- a/src/libraries/System.Net.Sockets/tests/FunctionalTests/SendTo.cs +++ b/src/libraries/System.Net.Sockets/tests/FunctionalTests/SendTo.cs @@ -95,7 +95,7 @@ public async Task Datagram_UDP_ShouldImplicitlyBindLocalEndpoint() [Fact] [SkipOnPlatform(TestPlatforms.FreeBSD, "FreeBSD allows sendto() to broadcast")] - [ActiveIssue("https://github.com/dotnet/runtime/issues/114450", typeof(PlatformDetection), nameof(PlatformDetection.IsMacCatalyst), nameof(PlatformDetection.IsX64Process))] + [ActiveIssue("https://github.com/dotnet/runtime/issues/114450", TestPlatforms.OSX | TestPlatforms.MacCatalyst)] public async Task Datagram_UDP_AccessDenied_Throws_DoesNotBind() { IPEndPoint invalidEndpoint = new IPEndPoint(IPAddress.Broadcast, 1234);