Contributing: Fixed some typos (#18331)
This commit is contained in:
parent
6dd3d6ec49
commit
116799fa70
|
|
@ -54,7 +54,7 @@ Write-Output "Watching processes $($CandidateProcessNames -join ', ')";
|
||||||
# This script registers as a scheduled job. This scheduled job executes after $WakeTime.
|
# This script registers as a scheduled job. This scheduled job executes after $WakeTime.
|
||||||
# When the scheduled job executes, it runs procdump on all alive processes whose name matches $CandidateProcessNames.
|
# When the scheduled job executes, it runs procdump on all alive processes whose name matches $CandidateProcessNames.
|
||||||
# The dumps are placed in $ProcDumpOutputPath
|
# The dumps are placed in $ProcDumpOutputPath
|
||||||
# If the build completes sucessfully in less than $WakeTime, a final step unregisters the job.
|
# If the build completes successfully in less than $WakeTime, a final step unregisters the job.
|
||||||
|
|
||||||
# Create a unique identifier for the job name
|
# Create a unique identifier for the job name
|
||||||
$JobName = "CaptureDumps" + (New-Guid).ToString("N");
|
$JobName = "CaptureDumps" + (New-Guid).ToString("N");
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ namespace Microsoft.AspNetCore.Components.Server.Circuits
|
||||||
private bool _disposing = false;
|
private bool _disposing = false;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Notifies when a rendering exception occured.
|
/// Notifies when a rendering exception occurred.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public event EventHandler<Exception> UnhandledException;
|
public event EventHandler<Exception> UnhandledException;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -302,7 +302,7 @@ namespace Microsoft.AspNetCore.Components.Server
|
||||||
LoggerMessage.Define<CircuitId, string, string>(LogLevel.Debug, new EventId(7, "CreatedCircuit"), "Created circuit '{CircuitId}' with secret '{CircuitIdSecret}' for '{ConnectionId}'");
|
LoggerMessage.Define<CircuitId, string, string>(LogLevel.Debug, new EventId(7, "CreatedCircuit"), "Created circuit '{CircuitId}' with secret '{CircuitIdSecret}' for '{ConnectionId}'");
|
||||||
|
|
||||||
private static readonly Action<ILogger, string, Exception> _invalidCircuitId =
|
private static readonly Action<ILogger, string, Exception> _invalidCircuitId =
|
||||||
LoggerMessage.Define<string>(LogLevel.Debug, new EventId(8, "InvalidCircuitId"), "ConnectAsync recieved an invalid circuit id '{CircuitIdSecret}'");
|
LoggerMessage.Define<string>(LogLevel.Debug, new EventId(8, "InvalidCircuitId"), "ConnectAsync received an invalid circuit id '{CircuitIdSecret}'");
|
||||||
|
|
||||||
public static void ReceivedConfirmationForBatch(ILogger logger, long batchId) => _receivedConfirmationForBatch(logger, batchId, null);
|
public static void ReceivedConfirmationForBatch(ILogger logger, long batchId) => _receivedConfirmationForBatch(logger, batchId, null);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -90,7 +90,7 @@ namespace BlazingPizza.Server
|
||||||
},
|
},
|
||||||
new Topping()
|
new Topping()
|
||||||
{
|
{
|
||||||
Name = "Fresh tomatos",
|
Name = "Fresh tomatoes",
|
||||||
Price = 1.50m,
|
Price = 1.50m,
|
||||||
},
|
},
|
||||||
new Topping()
|
new Topping()
|
||||||
|
|
|
||||||
|
|
@ -147,7 +147,7 @@ namespace Microsoft.AspNetCore.JsonPatch.IntegrationTests
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact]
|
[Fact]
|
||||||
public void TestStringProperty_IsSucessful()
|
public void TestStringProperty_IsSuccessful()
|
||||||
{
|
{
|
||||||
// Arrange
|
// Arrange
|
||||||
var targetObject = new
|
var targetObject = new
|
||||||
|
|
|
||||||
|
|
@ -106,7 +106,7 @@ namespace Microsoft.AspNetCore.JsonPatch.IntegrationTests
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact]
|
[Fact]
|
||||||
public void TestIntegerProperty_IsSucessful()
|
public void TestIntegerProperty_IsSuccessful()
|
||||||
{
|
{
|
||||||
// Arrange
|
// Arrange
|
||||||
dynamic targetObject = new ExpandoObject();
|
dynamic targetObject = new ExpandoObject();
|
||||||
|
|
|
||||||
|
|
@ -91,7 +91,7 @@ namespace Microsoft.AspNetCore.Hosting
|
||||||
var startTimestamp = context.StartTimestamp;
|
var startTimestamp = context.StartTimestamp;
|
||||||
long currentTimestamp = 0;
|
long currentTimestamp = 0;
|
||||||
|
|
||||||
// If startTimestamp was 0, then Information logging wasn't enabled at for this request (and calcuated time will be wildly wrong)
|
// If startTimestamp was 0, then Information logging wasn't enabled at for this request (and calculated time will be wildly wrong)
|
||||||
// Is used as proxy to reduce calls to virtual: _logger.IsEnabled(LogLevel.Information)
|
// Is used as proxy to reduce calls to virtual: _logger.IsEnabled(LogLevel.Information)
|
||||||
if (startTimestamp != 0)
|
if (startTimestamp != 0)
|
||||||
{
|
{
|
||||||
|
|
@ -109,7 +109,7 @@ namespace Microsoft.AspNetCore.Hosting
|
||||||
|
|
||||||
if (exception == null)
|
if (exception == null)
|
||||||
{
|
{
|
||||||
// No exception was thrown, request was sucessful
|
// No exception was thrown, request was successful
|
||||||
if (_diagnosticListener.IsEnabled(DeprecatedDiagnosticsEndRequestKey))
|
if (_diagnosticListener.IsEnabled(DeprecatedDiagnosticsEndRequestKey))
|
||||||
{
|
{
|
||||||
// Diagnostics is enabled for EndRequest, but it may not be for BeginRequest
|
// Diagnostics is enabled for EndRequest, but it may not be for BeginRequest
|
||||||
|
|
|
||||||
|
|
@ -383,7 +383,7 @@ namespace Microsoft.AspNetCore.Routing
|
||||||
LogLevel.Debug,
|
LogLevel.Debug,
|
||||||
EventIds.TemplateFailedExpansion,
|
EventIds.TemplateFailedExpansion,
|
||||||
"Failed to process the template {Template} for {Endpoint}. " +
|
"Failed to process the template {Template} for {Endpoint}. " +
|
||||||
"The failure occured while expanding the template with values {Values} " +
|
"The failure occurred while expanding the template with values {Values} " +
|
||||||
"This is usually due to a missing or empty value in a complex segment");
|
"This is usually due to a missing or empty value in a complex segment");
|
||||||
|
|
||||||
private static readonly Action<ILogger, IEnumerable<string>, string, Exception> _linkGenerationSucceeded = LoggerMessage.Define<IEnumerable<string>, string>(
|
private static readonly Action<ILogger, IEnumerable<string>, string, Exception> _linkGenerationSucceeded = LoggerMessage.Define<IEnumerable<string>, string>(
|
||||||
|
|
@ -442,7 +442,7 @@ namespace Microsoft.AspNetCore.Routing
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void LinkGenerationSucceeded(ILogger logger, IEnumerable<Endpoint> endpoints, string uri)
|
public static void LinkGenerationSucceeded(ILogger logger, IEnumerable<Endpoint> endpoints, string uri)
|
||||||
{
|
{
|
||||||
// Checking level again to avoid allocation on the common path
|
// Checking level again to avoid allocation on the common path
|
||||||
if (logger.IsEnabled(LogLevel.Debug))
|
if (logger.IsEnabled(LogLevel.Debug))
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ namespace Microsoft.AspNetCore.Routing.Matching
|
||||||
|
|
||||||
// Route values not supported
|
// Route values not supported
|
||||||
[Fact]
|
[Fact]
|
||||||
public override Task Match_SingleParameter_WierdNames()
|
public override Task Match_SingleParameter_WeirdNames()
|
||||||
{
|
{
|
||||||
return Task.CompletedTask;
|
return Task.CompletedTask;
|
||||||
}
|
}
|
||||||
|
|
@ -35,7 +35,7 @@ namespace Microsoft.AspNetCore.Routing.Matching
|
||||||
[InlineData(null, null, null, null)]
|
[InlineData(null, null, null, null)]
|
||||||
public override Task Match_MultipleParameters(string template, string path, string[] keys, string[] values)
|
public override Task Match_MultipleParameters(string template, string path, string[] keys, string[] values)
|
||||||
{
|
{
|
||||||
GC.KeepAlive(new object [] { template, path, keys, values });
|
GC.KeepAlive(new object[] { template, path, keys, values });
|
||||||
return Task.CompletedTask;
|
return Task.CompletedTask;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -173,7 +173,7 @@ namespace Microsoft.AspNetCore.Routing.Matching
|
||||||
|
|
||||||
// Historically catchall segments don't match an empty segment, but only if it's
|
// Historically catchall segments don't match an empty segment, but only if it's
|
||||||
// the first one. So `/a/b//` would match, but `/a//` would not. This is pretty
|
// the first one. So `/a/b//` would match, but `/a//` would not. This is pretty
|
||||||
// wierd and inconsistent with the intent of using a catch all. The DfaMatcher
|
// weird and inconsistent with the intent of using a catch all. The DfaMatcher
|
||||||
// fixes this issue.
|
// fixes this issue.
|
||||||
[Theory]
|
[Theory]
|
||||||
[InlineData("/{a}/{*b=b}", "/a///", new[] { "a", "b", }, new[] { "a", "//" })]
|
[InlineData("/{a}/{*b=b}", "/a///", new[] { "a", "b", }, new[] { "a", "//" })]
|
||||||
|
|
@ -313,7 +313,7 @@ namespace Microsoft.AspNetCore.Routing.Matching
|
||||||
[InlineData("(Controller).mvc", "/(Controller).mvc", new string[] { }, new string[] { })]
|
[InlineData("(Controller).mvc", "/(Controller).mvc", new string[] { }, new string[] { })]
|
||||||
[InlineData("Controller.mvc/ ", "/Controller.mvc/ ", new string[] { }, new string[] { })]
|
[InlineData("Controller.mvc/ ", "/Controller.mvc/ ", new string[] { }, new string[] { })]
|
||||||
[InlineData("Controller.mvc ", "/Controller.mvc ", new string[] { }, new string[] { })]
|
[InlineData("Controller.mvc ", "/Controller.mvc ", new string[] { }, new string[] { })]
|
||||||
public virtual async Task Match_WierdCharacterCases(string template, string path, string[] keys, string[] values)
|
public virtual async Task Match_WeirdCharacterCases(string template, string path, string[] keys, string[] values)
|
||||||
{
|
{
|
||||||
// Arrange
|
// Arrange
|
||||||
var (matcher, endpoint) = CreateMatcher(template);
|
var (matcher, endpoint) = CreateMatcher(template);
|
||||||
|
|
|
||||||
|
|
@ -239,7 +239,7 @@ namespace Microsoft.AspNetCore.Routing.Matching
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact]
|
[Fact]
|
||||||
public virtual async Task Match_SingleParameter_WierdNames()
|
public virtual async Task Match_SingleParameter_WeirdNames()
|
||||||
{
|
{
|
||||||
// Arrange
|
// Arrange
|
||||||
var (matcher, endpoint) = CreateMatcher("/foo/{ }/{.!$%}/{dynamic.data}");
|
var (matcher, endpoint) = CreateMatcher("/foo/{ }/{.!$%}/{dynamic.data}");
|
||||||
|
|
|
||||||
|
|
@ -239,7 +239,7 @@ namespace Microsoft.AspNetCore.Routing.Patterns
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact]
|
[Fact]
|
||||||
public void Parse_ComplexSegment_ThreeParametersSeperatedByPeriod()
|
public void Parse_ComplexSegment_ThreeParametersSeparatedByPeriod()
|
||||||
{
|
{
|
||||||
// Arrange
|
// Arrange
|
||||||
var template = "{p1}.{p2}.{p3}";
|
var template = "{p1}.{p2}.{p3}";
|
||||||
|
|
@ -352,7 +352,7 @@ namespace Microsoft.AspNetCore.Routing.Patterns
|
||||||
[Theory]
|
[Theory]
|
||||||
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}}$)}")] // extra }
|
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}}$)}")] // extra }
|
||||||
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}$)}}")] // extra } at the end
|
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}$)}}")] // extra } at the end
|
||||||
[InlineData(@"{{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}$)}")] // extra { at the begining
|
[InlineData(@"{{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}$)}")] // extra { at the beginning
|
||||||
[InlineData(@"{p1:regex(([}])\w+}")] // Not escaped }
|
[InlineData(@"{p1:regex(([}])\w+}")] // Not escaped }
|
||||||
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}$)}")] // Not escaped }
|
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}$)}")] // Not escaped }
|
||||||
[InlineData(@"{p1:regex(abc)")]
|
[InlineData(@"{p1:regex(abc)")]
|
||||||
|
|
@ -400,7 +400,7 @@ namespace Microsoft.AspNetCore.Routing.Patterns
|
||||||
[InlineData("..{p2?}", "..")]
|
[InlineData("..{p2?}", "..")]
|
||||||
[InlineData("{p1}.abc.{p2?}", ".abc.")]
|
[InlineData("{p1}.abc.{p2?}", ".abc.")]
|
||||||
[InlineData("{p1}{p2?}", "{p1}")]
|
[InlineData("{p1}{p2?}", "{p1}")]
|
||||||
public void Parse_ComplexSegment_OptionalParametersSeperatedByPeriod_Invalid(string template, string parameter)
|
public void Parse_ComplexSegment_OptionalParametersSeparatedByPeriod_Invalid(string template, string parameter)
|
||||||
{
|
{
|
||||||
// Act and Assert
|
// Act and Assert
|
||||||
ExceptionAssert.Throws<RoutePatternException>(
|
ExceptionAssert.Throws<RoutePatternException>(
|
||||||
|
|
|
||||||
|
|
@ -325,7 +325,7 @@ namespace Microsoft.AspNetCore.Routing.Template.Tests
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact]
|
[Fact]
|
||||||
public void Parse_ComplexSegment_ThreeParametersSeperatedByPeriod()
|
public void Parse_ComplexSegment_ThreeParametersSeparatedByPeriod()
|
||||||
{
|
{
|
||||||
// Arrange
|
// Arrange
|
||||||
var template = "{p1}.{p2}.{p3}";
|
var template = "{p1}.{p2}.{p3}";
|
||||||
|
|
@ -498,7 +498,7 @@ namespace Microsoft.AspNetCore.Routing.Template.Tests
|
||||||
[Theory]
|
[Theory]
|
||||||
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}}$)}")] // extra }
|
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}}$)}")] // extra }
|
||||||
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}$)}}")] // extra } at the end
|
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}$)}}")] // extra } at the end
|
||||||
[InlineData(@"{{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}$)}")] // extra { at the begining
|
[InlineData(@"{{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}}$)}")] // extra { at the beginning
|
||||||
[InlineData(@"{p1:regex(([}])\w+}")] // Not escaped }
|
[InlineData(@"{p1:regex(([}])\w+}")] // Not escaped }
|
||||||
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}$)}")] // Not escaped }
|
[InlineData(@"{p1:regex(^\d{{3}}-\d{{3}}-\d{{4}$)}")] // Not escaped }
|
||||||
[InlineData(@"{p1:regex(abc)")]
|
[InlineData(@"{p1:regex(abc)")]
|
||||||
|
|
@ -550,7 +550,7 @@ namespace Microsoft.AspNetCore.Routing.Template.Tests
|
||||||
[InlineData("{p1}.abc.{p2?}", ".abc.")]
|
[InlineData("{p1}.abc.{p2?}", ".abc.")]
|
||||||
[InlineData("{p1}{p2?}", "{p1}")]
|
[InlineData("{p1}{p2?}", "{p1}")]
|
||||||
[ReplaceCulture]
|
[ReplaceCulture]
|
||||||
public void Parse_ComplexSegment_OptionalParametersSeperatedByPeriod_Invalid(string template, string parameter)
|
public void Parse_ComplexSegment_OptionalParametersSeparatedByPeriod_Invalid(string template, string parameter)
|
||||||
{
|
{
|
||||||
// Act and Assert
|
// Act and Assert
|
||||||
ExceptionAssert.Throws<ArgumentException>(
|
ExceptionAssert.Throws<ArgumentException>(
|
||||||
|
|
|
||||||
|
|
@ -167,7 +167,7 @@ namespace Microsoft.AspNetCore.WebUtilities
|
||||||
// If we're not in the final block, then consume nothing
|
// If we're not in the final block, then consume nothing
|
||||||
if (!isFinalBlock)
|
if (!isFinalBlock)
|
||||||
{
|
{
|
||||||
// Don't buffer indefinately
|
// Don't buffer indefinitely
|
||||||
if ((uint)span.Length > (uint)KeyLengthLimit + (uint)ValueLengthLimit)
|
if ((uint)span.Length > (uint)KeyLengthLimit + (uint)ValueLengthLimit)
|
||||||
{
|
{
|
||||||
ThrowKeyOrValueTooLargeException();
|
ThrowKeyOrValueTooLargeException();
|
||||||
|
|
@ -236,7 +236,7 @@ namespace Microsoft.AspNetCore.WebUtilities
|
||||||
{
|
{
|
||||||
if (!isFinalBlock)
|
if (!isFinalBlock)
|
||||||
{
|
{
|
||||||
// Don't buffer indefinately
|
// Don't buffer indefinitely
|
||||||
if ((uint)(sequenceReader.Consumed - consumedBytes) > (uint)KeyLengthLimit + (uint)ValueLengthLimit)
|
if ((uint)(sequenceReader.Consumed - consumedBytes) > (uint)KeyLengthLimit + (uint)ValueLengthLimit)
|
||||||
{
|
{
|
||||||
ThrowKeyOrValueTooLargeException();
|
ThrowKeyOrValueTooLargeException();
|
||||||
|
|
|
||||||
|
|
@ -85,7 +85,7 @@ namespace Microsoft.AspNetCore.WebUtilities
|
||||||
var anchorIndex = uri.IndexOf('#');
|
var anchorIndex = uri.IndexOf('#');
|
||||||
var uriToBeAppended = uri;
|
var uriToBeAppended = uri;
|
||||||
var anchorText = "";
|
var anchorText = "";
|
||||||
// If there is an anchor, then the query string must be inserted before its first occurence.
|
// If there is an anchor, then the query string must be inserted before its first occurrence.
|
||||||
if (anchorIndex != -1)
|
if (anchorIndex != -1)
|
||||||
{
|
{
|
||||||
anchorText = uri.Substring(anchorIndex);
|
anchorText = uri.Substring(anchorIndex);
|
||||||
|
|
|
||||||
|
|
@ -406,7 +406,7 @@ HASH_TABLE<_Record,_Key>::InsertRecord(
|
||||||
)
|
)
|
||||||
/*++
|
/*++
|
||||||
This method inserts a node for this record and also empty nodes for paths
|
This method inserts a node for this record and also empty nodes for paths
|
||||||
in the heirarchy leading upto this path
|
in the hierarchy leading upto this path
|
||||||
|
|
||||||
The insert is done under only a read-lock - this is possible by keeping
|
The insert is done under only a read-lock - this is possible by keeping
|
||||||
the hashes in a bucket in increasing order and using interlocked operations
|
the hashes in a bucket in increasing order and using interlocked operations
|
||||||
|
|
|
||||||
|
|
@ -582,7 +582,7 @@ typedef enum _HTTP_LOGGING_ROLLOVER_TYPE
|
||||||
// log file rollovers happen by GMT time.
|
// log file rollovers happen by GMT time.
|
||||||
//
|
//
|
||||||
// HTTP_LOGGING_FLAG_USE_UTF8_CONVERSION - When set the unicode fields
|
// HTTP_LOGGING_FLAG_USE_UTF8_CONVERSION - When set the unicode fields
|
||||||
// will be converted to UTF8 multibytes when writting to the log
|
// will be converted to UTF8 multibytes when writing to the log
|
||||||
// files. When this flag is not present, the local code page
|
// files. When this flag is not present, the local code page
|
||||||
// conversion happens.
|
// conversion happens.
|
||||||
//
|
//
|
||||||
|
|
|
||||||
|
|
@ -79,7 +79,7 @@ private:
|
||||||
);
|
);
|
||||||
|
|
||||||
//
|
//
|
||||||
// Pointer to the begining of the inlined array.
|
// Pointer to the beginning of the inlined array.
|
||||||
//
|
//
|
||||||
PVOID m_pVariables;
|
PVOID m_pVariables;
|
||||||
SIZE_T m_Alignment;
|
SIZE_T m_Alignment;
|
||||||
|
|
|
||||||
|
|
@ -519,7 +519,7 @@ TREE_HASH_TABLE<_Record>::InsertRecord(
|
||||||
)
|
)
|
||||||
/*++
|
/*++
|
||||||
This method inserts a node for this record and also empty nodes for paths
|
This method inserts a node for this record and also empty nodes for paths
|
||||||
in the heirarchy leading upto this path
|
in the hierarchy leading upto this path
|
||||||
|
|
||||||
The insert is done under only a read-lock - this is possible by keeping
|
The insert is done under only a read-lock - this is possible by keeping
|
||||||
the hashes in a bucket in increasing order and using interlocked operations
|
the hashes in a bucket in increasing order and using interlocked operations
|
||||||
|
|
|
||||||
|
|
@ -1637,7 +1637,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the first character occurence in the string.
|
The index for the first character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
@ -1684,7 +1684,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the first character occurence in the string.
|
The index for the first character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
@ -1733,7 +1733,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the last character occurence in the string.
|
The index for the last character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1083,7 +1083,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the first character occurence in the string.
|
The index for the first character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
@ -1130,7 +1130,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the first character occurence in the string.
|
The index for the first character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
@ -1179,7 +1179,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the last character occurence in the string.
|
The index for the last character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ enum SETUP_LOG_SEVERITY
|
||||||
//consider using an IIS prefix for Msi* methods - they conflict with MSI apis
|
//consider using an IIS prefix for Msi* methods - they conflict with MSI apis
|
||||||
|
|
||||||
//
|
//
|
||||||
// Initalize logging once at begining of CA
|
// Initialize logging once at beginning of CA
|
||||||
//
|
//
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
|
|
|
||||||
|
|
@ -72,12 +72,12 @@ namespace Microsoft.AspNetCore.SpaServices
|
||||||
public string SourcePath { get; set; }
|
public string SourcePath { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Controls wether the development server should be used with a dynamic or fixed port.
|
/// Controls whether the development server should be used with a dynamic or fixed port.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public int DevServerPort { get; set; } = default(int);
|
public int DevServerPort { get; set; } = default(int);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the name of the package manager executible, (e.g npm,
|
/// Gets or sets the name of the package manager executable, (e.g npm,
|
||||||
/// yarn) to run the SPA.
|
/// yarn) to run the SPA.
|
||||||
///
|
///
|
||||||
/// The default value is 'npm'.
|
/// The default value is 'npm'.
|
||||||
|
|
|
||||||
|
|
@ -140,13 +140,13 @@ $.extend($.fn, {
|
||||||
return valid;
|
return valid;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// attributes: space seperated list of attributes to retrieve and remove
|
// attributes: space separated list of attributes to retrieve and remove
|
||||||
removeAttrs: function(attributes) {
|
removeAttrs: function(attributes) {
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Remove the specified attributes from the first matched element and return them.
|
/// Remove the specified attributes from the first matched element and return them.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="attributes" type="String">
|
/// <param name="attributes" type="String">
|
||||||
/// A space-seperated list of attribute names to remove.
|
/// A space-separated list of attribute names to remove.
|
||||||
/// </param>
|
/// </param>
|
||||||
|
|
||||||
var result = {},
|
var result = {},
|
||||||
|
|
|
||||||
|
|
@ -122,7 +122,7 @@ $.extend($.fn, {
|
||||||
return valid;
|
return valid;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// attributes: space seperated list of attributes to retrieve and remove
|
// attributes: space separated list of attributes to retrieve and remove
|
||||||
removeAttrs: function( attributes ) {
|
removeAttrs: function( attributes ) {
|
||||||
var result = {},
|
var result = {},
|
||||||
$element = this;
|
$element = this;
|
||||||
|
|
|
||||||
|
|
@ -6,12 +6,12 @@ using System;
|
||||||
namespace Microsoft.AspNetCore.Mvc.ModelBinding
|
namespace Microsoft.AspNetCore.Mvc.ModelBinding
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// An error that occured during model binding and validation.
|
/// An error that occurred during model binding and validation.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class ModelError
|
public class ModelError
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Intiializes a new instance of <see cref="ModelError"/> with the specified <paramref name="exception"/>.
|
/// Initializes a new instance of <see cref="ModelError"/> with the specified <paramref name="exception"/>.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="exception">The <see cref="System.Exception"/>.</param>
|
/// <param name="exception">The <see cref="System.Exception"/>.</param>
|
||||||
public ModelError(Exception exception)
|
public ModelError(Exception exception)
|
||||||
|
|
@ -20,7 +20,7 @@ namespace Microsoft.AspNetCore.Mvc.ModelBinding
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Intiializes a new instance of <see cref="ModelError"/> with the specified <paramref name="exception"/>
|
/// Initializes a new instance of <see cref="ModelError"/> with the specified <paramref name="exception"/>
|
||||||
/// and specified <paramref name="errorMessage"/>.
|
/// and specified <paramref name="errorMessage"/>.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="exception">The <see cref="System.Exception"/>.</param>
|
/// <param name="exception">The <see cref="System.Exception"/>.</param>
|
||||||
|
|
|
||||||
|
|
@ -511,7 +511,7 @@
|
||||||
<value>Unexcepted end when reading JSON.</value>
|
<value>Unexcepted end when reading JSON.</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="ApiConventions_Title_500" xml:space="preserve">
|
<data name="ApiConventions_Title_500" xml:space="preserve">
|
||||||
<value>An error occured while processing your request.</value>
|
<value>An error occurred while processing your request.</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="FailedToReadRequestForm" xml:space="preserve">
|
<data name="FailedToReadRequestForm" xml:space="preserve">
|
||||||
<value>Failed to read the request form. {0}</value>
|
<value>Failed to read the request form. {0}</value>
|
||||||
|
|
|
||||||
|
|
@ -2416,7 +2416,7 @@ namespace Microsoft.AspNetCore.Mvc.Core.Test
|
||||||
var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value);
|
var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value);
|
||||||
Assert.Equal(500, actionResult.StatusCode);
|
Assert.Equal(500, actionResult.StatusCode);
|
||||||
Assert.Equal(500, problemDetails.Status);
|
Assert.Equal(500, problemDetails.Status);
|
||||||
Assert.Equal("An error occured while processing your request.", problemDetails.Title);
|
Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
|
||||||
Assert.Equal("https://tools.ietf.org/html/rfc7231#section-6.6.1", problemDetails.Type);
|
Assert.Equal("https://tools.ietf.org/html/rfc7231#section-6.6.1", problemDetails.Type);
|
||||||
Assert.Equal("some-trace", problemDetails.Extensions["traceId"]);
|
Assert.Equal("some-trace", problemDetails.Extensions["traceId"]);
|
||||||
}
|
}
|
||||||
|
|
@ -2488,7 +2488,7 @@ namespace Microsoft.AspNetCore.Mvc.Core.Test
|
||||||
},
|
},
|
||||||
[500] = new ClientErrorData
|
[500] = new ClientErrorData
|
||||||
{
|
{
|
||||||
Title = "An error occured while processing your request.",
|
Title = "An error occurred while processing your request.",
|
||||||
Link = "https://tools.ietf.org/html/rfc7231#section-6.6.1"
|
Link = "https://tools.ietf.org/html/rfc7231#section-6.6.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@ namespace Microsoft.AspNetCore.Mvc.Infrastructure
|
||||||
|
|
||||||
// Assert
|
// Assert
|
||||||
Assert.Equal(500, problemDetails.Status);
|
Assert.Equal(500, problemDetails.Status);
|
||||||
Assert.Equal("An error occured while processing your request.", problemDetails.Title);
|
Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
|
||||||
Assert.Equal("https://tools.ietf.org/html/rfc7231#section-6.6.1", problemDetails.Type);
|
Assert.Equal("https://tools.ietf.org/html/rfc7231#section-6.6.1", problemDetails.Type);
|
||||||
Assert.Null(problemDetails.Instance);
|
Assert.Null(problemDetails.Instance);
|
||||||
Assert.Null(problemDetails.Detail);
|
Assert.Null(problemDetails.Detail);
|
||||||
|
|
|
||||||
|
|
@ -101,7 +101,7 @@ export class LoginComponent implements OnInit {
|
||||||
|
|
||||||
private getReturnUrl(state?: INavigationState): string {
|
private getReturnUrl(state?: INavigationState): string {
|
||||||
const fromQuery = (this.activatedRoute.snapshot.queryParams as INavigationState).returnUrl;
|
const fromQuery = (this.activatedRoute.snapshot.queryParams as INavigationState).returnUrl;
|
||||||
// If the url is comming from the query string, check that is either
|
// If the url is coming from the query string, check that is either
|
||||||
// a relative url or an absolute url
|
// a relative url or an absolute url
|
||||||
if (fromQuery &&
|
if (fromQuery &&
|
||||||
!(fromQuery.startsWith(`${window.location.origin}/`) ||
|
!(fromQuery.startsWith(`${window.location.origin}/`) ||
|
||||||
|
|
|
||||||
|
|
@ -95,7 +95,7 @@ export class LogoutComponent implements OnInit {
|
||||||
|
|
||||||
private getReturnUrl(state?: INavigationState): string {
|
private getReturnUrl(state?: INavigationState): string {
|
||||||
const fromQuery = (this.activatedRoute.snapshot.queryParams as INavigationState).returnUrl;
|
const fromQuery = (this.activatedRoute.snapshot.queryParams as INavigationState).returnUrl;
|
||||||
// If the url is comming from the query string, check that is either
|
// If the url is coming from the query string, check that is either
|
||||||
// a relative url or an absolute url
|
// a relative url or an absolute url
|
||||||
if (fromQuery &&
|
if (fromQuery &&
|
||||||
!(fromQuery.startsWith(`${window.location.origin}/`) ||
|
!(fromQuery.startsWith(`${window.location.origin}/`) ||
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
: base(context, scheme, options, properties: null) { }
|
: base(context, scheme, options, properties: null) { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The exception that occured while processing the authentication.
|
/// The exception that occurred while processing the authentication.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public Exception Exception { get; set; }
|
public Exception Exception { get; set; }
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -123,7 +123,7 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
errorCode = SecurityStatusPalErrorCode.UnknownCredentials;
|
errorCode = SecurityStatusPalErrorCode.UnknownCredentials;
|
||||||
}
|
}
|
||||||
|
|
||||||
error = new Exception($"An authentication exception occured (0x{majorStatus:X}/0x{minorStatus:X}).", error);
|
error = new Exception($"An authentication exception occurred (0x{majorStatus:X}/0x{minorStatus:X}).", error);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (errorCode == SecurityStatusPalErrorCode.OK
|
if (errorCode == SecurityStatusPalErrorCode.OK
|
||||||
|
|
|
||||||
|
|
@ -131,7 +131,7 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
{
|
{
|
||||||
eventInvoked++;
|
eventInvoked++;
|
||||||
Assert.IsType<Exception>(context.Exception);
|
Assert.IsType<Exception>(context.Exception);
|
||||||
Assert.Equal("A test other error occured", context.Exception.Message);
|
Assert.Equal("A test other error occurred", context.Exception.Message);
|
||||||
return Task.CompletedTask;
|
return Task.CompletedTask;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
@ -140,7 +140,7 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
|
|
||||||
var ex = await Assert.ThrowsAsync<Exception>(() =>
|
var ex = await Assert.ThrowsAsync<Exception>(() =>
|
||||||
SendAsync(server, "/404", new TestConnection(), "Negotiate OtherError"));
|
SendAsync(server, "/404", new TestConnection(), "Negotiate OtherError"));
|
||||||
Assert.Equal("A test other error occured", ex.Message);
|
Assert.Equal("A test other error occurred", ex.Message);
|
||||||
Assert.Equal(1, eventInvoked);
|
Assert.Equal(1, eventInvoked);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -182,7 +182,7 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
{
|
{
|
||||||
eventInvoked++;
|
eventInvoked++;
|
||||||
Assert.IsType<Exception>(context.Exception);
|
Assert.IsType<Exception>(context.Exception);
|
||||||
Assert.Equal("A test credential error occured", context.Exception.Message);
|
Assert.Equal("A test credential error occurred", context.Exception.Message);
|
||||||
return Task.CompletedTask;
|
return Task.CompletedTask;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
@ -232,7 +232,7 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
{
|
{
|
||||||
eventInvoked++;
|
eventInvoked++;
|
||||||
Assert.IsType<Exception>(context.Exception);
|
Assert.IsType<Exception>(context.Exception);
|
||||||
Assert.Equal("A test client error occured", context.Exception.Message);
|
Assert.Equal("A test client error occurred", context.Exception.Message);
|
||||||
return Task.CompletedTask;
|
return Task.CompletedTask;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
@ -555,15 +555,15 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
return "ServerKerberosBlob2";
|
return "ServerKerberosBlob2";
|
||||||
case "CredentialError":
|
case "CredentialError":
|
||||||
errorType = BlobErrorType.CredentialError;
|
errorType = BlobErrorType.CredentialError;
|
||||||
ex = new Exception("A test credential error occured");
|
ex = new Exception("A test credential error occurred");
|
||||||
return null;
|
return null;
|
||||||
case "ClientError":
|
case "ClientError":
|
||||||
errorType = BlobErrorType.ClientError;
|
errorType = BlobErrorType.ClientError;
|
||||||
ex = new Exception("A test client error occured");
|
ex = new Exception("A test client error occurred");
|
||||||
return null;
|
return null;
|
||||||
case "OtherError":
|
case "OtherError":
|
||||||
errorType = BlobErrorType.Other;
|
errorType = BlobErrorType.Other;
|
||||||
ex = new Exception("A test other error occured");
|
ex = new Exception("A test other error occurred");
|
||||||
return null;
|
return null;
|
||||||
default:
|
default:
|
||||||
errorType = BlobErrorType.Other;
|
errorType = BlobErrorType.Other;
|
||||||
|
|
|
||||||
|
|
@ -301,7 +301,7 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
var testConnection = new TestConnection();
|
var testConnection = new TestConnection();
|
||||||
|
|
||||||
var ex = await Assert.ThrowsAsync<Exception>(() => SendAsync(server, "/404", testConnection, "Negotiate OtherError"));
|
var ex = await Assert.ThrowsAsync<Exception>(() => SendAsync(server, "/404", testConnection, "Negotiate OtherError"));
|
||||||
Assert.Equal("A test other error occured", ex.Message);
|
Assert.Equal("A test other error occurred", ex.Message);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Single Stage
|
// Single Stage
|
||||||
|
|
@ -552,15 +552,15 @@ namespace Microsoft.AspNetCore.Authentication.Negotiate
|
||||||
return "ServerKerberosBlob2";
|
return "ServerKerberosBlob2";
|
||||||
case "CredentialError":
|
case "CredentialError":
|
||||||
errorType = BlobErrorType.CredentialError;
|
errorType = BlobErrorType.CredentialError;
|
||||||
ex = new Exception("A test credential error occured");
|
ex = new Exception("A test credential error occurred");
|
||||||
return null;
|
return null;
|
||||||
case "ClientError":
|
case "ClientError":
|
||||||
errorType = BlobErrorType.ClientError;
|
errorType = BlobErrorType.ClientError;
|
||||||
ex = new Exception("A test client error occured");
|
ex = new Exception("A test client error occurred");
|
||||||
return null;
|
return null;
|
||||||
case "OtherError":
|
case "OtherError":
|
||||||
errorType = BlobErrorType.Other;
|
errorType = BlobErrorType.Other;
|
||||||
ex = new Exception("A test other error occured");
|
ex = new Exception("A test other error occurred");
|
||||||
return null;
|
return null;
|
||||||
default:
|
default:
|
||||||
errorType = BlobErrorType.Other;
|
errorType = BlobErrorType.Other;
|
||||||
|
|
|
||||||
|
|
@ -148,7 +148,7 @@ namespace OpenIdConnect.AzureAdSample
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
await response.WriteAsync($"AquireToken error: {ex.Message}");
|
await response.WriteAsync($"AcquireToken error: {ex.Message}");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -48,7 +48,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedValidWithClientEku);
|
Certificates.SelfSignedValidWithClientEku);
|
||||||
|
|
||||||
|
|
@ -63,7 +63,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedValidWithNoEku);
|
Certificates.SelfSignedValidWithNoEku);
|
||||||
|
|
||||||
|
|
@ -92,7 +92,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.Chained,
|
AllowedCertificateTypes = CertificateTypes.Chained,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedValidWithNoEku);
|
Certificates.SelfSignedValidWithNoEku);
|
||||||
|
|
||||||
|
|
@ -107,7 +107,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedValidWithServerEku);
|
Certificates.SelfSignedValidWithServerEku);
|
||||||
|
|
||||||
|
|
@ -123,7 +123,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
ValidateCertificateUse = false,
|
ValidateCertificateUse = false,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedValidWithServerEku);
|
Certificates.SelfSignedValidWithServerEku);
|
||||||
|
|
||||||
|
|
@ -139,7 +139,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.Chained,
|
AllowedCertificateTypes = CertificateTypes.Chained,
|
||||||
ValidateCertificateUse = false,
|
ValidateCertificateUse = false,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedValidWithServerEku);
|
Certificates.SelfSignedValidWithServerEku);
|
||||||
|
|
||||||
|
|
@ -155,7 +155,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
ValidateCertificateUse = false,
|
ValidateCertificateUse = false,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedExpired);
|
Certificates.SelfSignedExpired);
|
||||||
|
|
||||||
|
|
@ -171,7 +171,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
ValidateValidityPeriod = false,
|
ValidateValidityPeriod = false,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedExpired);
|
Certificates.SelfSignedExpired);
|
||||||
|
|
||||||
|
|
@ -187,7 +187,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
ValidateCertificateUse = false,
|
ValidateCertificateUse = false,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedNotYetValid);
|
Certificates.SelfSignedNotYetValid);
|
||||||
|
|
||||||
|
|
@ -203,7 +203,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
ValidateValidityPeriod = false,
|
ValidateValidityPeriod = false,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
Certificates.SelfSignedNotYetValid);
|
Certificates.SelfSignedNotYetValid);
|
||||||
|
|
||||||
|
|
@ -248,7 +248,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
var server = CreateServer(
|
var server = CreateServer(
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
});
|
});
|
||||||
|
|
||||||
var response = await server.CreateClient().GetAsync("https://example.com/");
|
var response = await server.CreateClient().GetAsync("https://example.com/");
|
||||||
|
|
@ -262,9 +262,9 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
wireUpHeaderMiddleware : true);
|
wireUpHeaderMiddleware: true);
|
||||||
|
|
||||||
var client = server.CreateClient();
|
var client = server.CreateClient();
|
||||||
client.DefaultRequestHeaders.Add("X-Client-Cert", Convert.ToBase64String(Certificates.SelfSignedValidWithNoEku.RawData));
|
client.DefaultRequestHeaders.Add("X-Client-Cert", Convert.ToBase64String(Certificates.SelfSignedValidWithNoEku.RawData));
|
||||||
|
|
@ -278,7 +278,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
var server = CreateServer(
|
var server = CreateServer(
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
wireUpHeaderMiddleware: true);
|
wireUpHeaderMiddleware: true);
|
||||||
|
|
||||||
|
|
@ -295,7 +295,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
AllowedCertificateTypes = CertificateTypes.SelfSigned,
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
wireUpHeaderMiddleware: true,
|
wireUpHeaderMiddleware: true,
|
||||||
headerName: "X-ARR-ClientCert");
|
headerName: "X-ARR-ClientCert");
|
||||||
|
|
@ -312,7 +312,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
var server = CreateServer(
|
var server = CreateServer(
|
||||||
new CertificateAuthenticationOptions
|
new CertificateAuthenticationOptions
|
||||||
{
|
{
|
||||||
Events = sucessfulValidationEvents
|
Events = successfulValidationEvents
|
||||||
},
|
},
|
||||||
wireUpHeaderMiddleware: true,
|
wireUpHeaderMiddleware: true,
|
||||||
headerName: "X-ARR-ClientCert");
|
headerName: "X-ARR-ClientCert");
|
||||||
|
|
@ -564,7 +564,7 @@ namespace Microsoft.AspNetCore.Authentication.Certificate.Test
|
||||||
return server;
|
return server;
|
||||||
}
|
}
|
||||||
|
|
||||||
private CertificateAuthenticationEvents sucessfulValidationEvents = new CertificateAuthenticationEvents()
|
private CertificateAuthenticationEvents successfulValidationEvents = new CertificateAuthenticationEvents()
|
||||||
{
|
{
|
||||||
OnCertificateValidated = context =>
|
OnCertificateValidated = context =>
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -148,6 +148,6 @@
|
||||||
<value>The given IAsyncResult does not match this opperation.</value>
|
<value>The given IAsyncResult does not match this opperation.</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="Warning_ExceptionInOnResponseCompletedAction" xml:space="preserve">
|
<data name="Warning_ExceptionInOnResponseCompletedAction" xml:space="preserve">
|
||||||
<value>An exception occured while running an action registered with {0}.</value>
|
<value>An exception occurred while running an action registered with {0}.</value>
|
||||||
</data>
|
</data>
|
||||||
</root>
|
</root>
|
||||||
|
|
@ -266,7 +266,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys
|
||||||
|
|
||||||
[ConditionalFact]
|
[ConditionalFact]
|
||||||
[MinimumOSVersion(OperatingSystems.Windows, "10.0.19529", SkipReason = "Requires HTTP/2 Trailers support.")]
|
[MinimumOSVersion(OperatingSystems.Windows, "10.0.19529", SkipReason = "Requires HTTP/2 Trailers support.")]
|
||||||
public async Task ResponseTrailers_MultipleValues_SentAsSeperateHeaders()
|
public async Task ResponseTrailers_MultipleValues_SentAsSeparateHeaders()
|
||||||
{
|
{
|
||||||
using (Utilities.CreateDynamicHttpsServer(out var address, httpContext =>
|
using (Utilities.CreateDynamicHttpsServer(out var address, httpContext =>
|
||||||
{
|
{
|
||||||
|
|
@ -278,7 +278,7 @@ namespace Microsoft.AspNetCore.Server.HttpSys
|
||||||
response.EnsureSuccessStatusCode();
|
response.EnsureSuccessStatusCode();
|
||||||
Assert.Equal(HttpVersion.Version20, response.Version);
|
Assert.Equal(HttpVersion.Version20, response.Version);
|
||||||
Assert.NotEmpty(response.TrailingHeaders);
|
Assert.NotEmpty(response.TrailingHeaders);
|
||||||
// We can't actually assert they are sent as seperate headers using HttpClient, we'd have to write a lower level test
|
// We can't actually assert they are sent as separate headers using HttpClient, we'd have to write a lower level test
|
||||||
// that read the header frames directly.
|
// that read the header frames directly.
|
||||||
Assert.Equal(new[] { "TrailerValue0", "TrailerValue1" }, response.TrailingHeaders.GetValues("TrailerName"));
|
Assert.Equal(new[] { "TrailerValue0", "TrailerValue1" }, response.TrailingHeaders.GetValues("TrailerName"));
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ class ConfigurationLoadException: public std::runtime_error
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
ConfigurationLoadException(std::wstring msg)
|
ConfigurationLoadException(std::wstring msg)
|
||||||
: runtime_error("Configuration load exception has occured"), message(std::move(msg))
|
: runtime_error("Configuration load exception has occurred"), message(std::move(msg))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -406,7 +406,7 @@ HASH_TABLE<_Record,_Key>::InsertRecord(
|
||||||
)
|
)
|
||||||
/*++
|
/*++
|
||||||
This method inserts a node for this record and also empty nodes for paths
|
This method inserts a node for this record and also empty nodes for paths
|
||||||
in the heirarchy leading upto this path
|
in the hierarchy leading upto this path
|
||||||
|
|
||||||
The insert is done under only a read-lock - this is possible by keeping
|
The insert is done under only a read-lock - this is possible by keeping
|
||||||
the hashes in a bucket in increasing order and using interlocked operations
|
the hashes in a bucket in increasing order and using interlocked operations
|
||||||
|
|
|
||||||
|
|
@ -82,7 +82,7 @@ private:
|
||||||
);
|
);
|
||||||
|
|
||||||
//
|
//
|
||||||
// Pointer to the begining of the inlined array.
|
// Pointer to the beginning of the inlined array.
|
||||||
//
|
//
|
||||||
PVOID m_pVariables;
|
PVOID m_pVariables;
|
||||||
SIZE_T m_Alignment;
|
SIZE_T m_Alignment;
|
||||||
|
|
|
||||||
|
|
@ -1637,7 +1637,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the first character occurence in the string.
|
The index for the first character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
@ -1684,7 +1684,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the first character occurence in the string.
|
The index for the first character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
@ -1733,7 +1733,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the last character occurence in the string.
|
The index for the last character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1065,7 +1065,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the first character occurence in the string.
|
The index for the first character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
@ -1112,7 +1112,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the first character occurence in the string.
|
The index for the first character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
@ -1161,7 +1161,7 @@ Arguments:
|
||||||
|
|
||||||
Return Value:
|
Return Value:
|
||||||
|
|
||||||
The index for the last character occurence in the string.
|
The index for the last character occurrence in the string.
|
||||||
|
|
||||||
-1 if not found.
|
-1 if not found.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -417,7 +417,7 @@ TREE_HASH_TABLE<_Record>::AddNodeInternal(
|
||||||
TREE_HASH_NODE<_Record> ** ppNewNode
|
TREE_HASH_NODE<_Record> ** ppNewNode
|
||||||
)
|
)
|
||||||
/*++
|
/*++
|
||||||
Return value is HRESULT indicating sucess or failure
|
Return value is HRESULT indicating success or failure
|
||||||
pszPath, dwHash, pRecord - path, hash value and record to be inserted
|
pszPath, dwHash, pRecord - path, hash value and record to be inserted
|
||||||
pParentNode - this will be the parent of the node being inserted
|
pParentNode - this will be the parent of the node being inserted
|
||||||
ppNewNode - on successful return, the new node created and inserted
|
ppNewNode - on successful return, the new node created and inserted
|
||||||
|
|
@ -519,7 +519,7 @@ TREE_HASH_TABLE<_Record>::InsertRecord(
|
||||||
)
|
)
|
||||||
/*++
|
/*++
|
||||||
This method inserts a node for this record and also empty nodes for paths
|
This method inserts a node for this record and also empty nodes for paths
|
||||||
in the heirarchy leading upto this path
|
in the hierarchy leading upto this path
|
||||||
|
|
||||||
The insert is done under only a read-lock - this is possible by keeping
|
The insert is done under only a read-lock - this is possible by keeping
|
||||||
the hashes in a bucket in increasing order and using interlocked operations
|
the hashes in a bucket in increasing order and using interlocked operations
|
||||||
|
|
|
||||||
|
|
@ -247,13 +247,13 @@ IN_PROCESS_APPLICATION::ExecuteApplication()
|
||||||
auto startupReturnCode = context->m_hostFxr.InitializeForApp(context->m_argc, context->m_argv.get(), m_dotnetExeKnownLocation);
|
auto startupReturnCode = context->m_hostFxr.InitializeForApp(context->m_argc, context->m_argv.get(), m_dotnetExeKnownLocation);
|
||||||
if (startupReturnCode != 0)
|
if (startupReturnCode != 0)
|
||||||
{
|
{
|
||||||
throw InvalidOperationException(format(L"Error occured when initializing inprocess application, Return code: 0x%x", startupReturnCode));
|
throw InvalidOperationException(format(L"Error occurred when initializing in-process application, Return code: 0x%x", startupReturnCode));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_pConfig->QueryCallStartupHook())
|
if (m_pConfig->QueryCallStartupHook())
|
||||||
{
|
{
|
||||||
PWSTR startupHookValue = NULL;
|
PWSTR startupHookValue = NULL;
|
||||||
// Will get property not found if the enviroment variable isn't set.
|
// Will get property not found if the environment variable isn't set.
|
||||||
context->m_hostFxr.GetRuntimePropertyValue(DOTNETCORE_STARTUP_HOOK, &startupHookValue);
|
context->m_hostFxr.GetRuntimePropertyValue(DOTNETCORE_STARTUP_HOOK, &startupHookValue);
|
||||||
|
|
||||||
if (startupHookValue == NULL)
|
if (startupHookValue == NULL)
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http
|
||||||
|
|
||||||
for (shift = total; shift >= 0; shift -= 4)
|
for (shift = total; shift >= 0; shift -= 4)
|
||||||
{
|
{
|
||||||
// Using Unsafe.Add to elide the bounds check on _hex as the & 0x0f definately
|
// Using Unsafe.Add to elide the bounds check on _hex as the & 0x0f definitely
|
||||||
// constrains it to the range 0x0 - 0xf, matching the bounds of the array
|
// constrains it to the range 0x0 - 0xf, matching the bounds of the array
|
||||||
span[offset] = Unsafe.Add(ref startHex, ((dataCount >> shift) & 0x0f));
|
span[offset] = Unsafe.Add(ref startHex, ((dataCount >> shift) & 0x0f));
|
||||||
offset++;
|
offset++;
|
||||||
|
|
@ -56,7 +56,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http
|
||||||
// bytes for the chunked prefix, so we would have to copy once we call advance. Therefore, to avoid this scenario,
|
// bytes for the chunked prefix, so we would have to copy once we call advance. Therefore, to avoid this scenario,
|
||||||
// we slice the memory by one byte.
|
// we slice the memory by one byte.
|
||||||
|
|
||||||
// See https://gist.github.com/halter73/af2b9f78978f83813b19e187c4e5309e if you would like to tweek the algorithm at all.
|
// See https://gist.github.com/halter73/af2b9f78978f83813b19e187c4e5309e if you would like to tweak the algorithm at all.
|
||||||
|
|
||||||
if (length <= 65544)
|
if (length <= 65544)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -241,7 +241,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http
|
||||||
{
|
{
|
||||||
TakeSingleHeader(pHeader, length, handler);
|
TakeSingleHeader(pHeader, length, handler);
|
||||||
}
|
}
|
||||||
// Read the header sucessfully, skip the reader forward past the header line.
|
// Read the header successfully, skip the reader forward past the header line.
|
||||||
reader.Advance(length);
|
reader.Advance(length);
|
||||||
span = span.Slice(length);
|
span = span.Slice(length);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -197,7 +197,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http2
|
||||||
var result = await Input.ReadAsync();
|
var result = await Input.ReadAsync();
|
||||||
var buffer = result.Buffer;
|
var buffer = result.Buffer;
|
||||||
|
|
||||||
// Call UpdateCompletedStreams() prior to frame processing in order to remove any streams that have exceded their drain timeouts.
|
// Call UpdateCompletedStreams() prior to frame processing in order to remove any streams that have exceeded their drain timeouts.
|
||||||
UpdateCompletedStreams();
|
UpdateCompletedStreams();
|
||||||
|
|
||||||
try
|
try
|
||||||
|
|
@ -921,7 +921,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http2
|
||||||
|
|
||||||
if (_clientActiveStreamCount > _serverSettings.MaxConcurrentStreams)
|
if (_clientActiveStreamCount > _serverSettings.MaxConcurrentStreams)
|
||||||
{
|
{
|
||||||
// The protocol default stream limit is infinite so the client can excede our limit at the start of the connection.
|
// The protocol default stream limit is infinite so the client can exceed our limit at the start of the connection.
|
||||||
// Refused streams can be retried, by which time the client must have received our settings frame with our limit information.
|
// Refused streams can be retried, by which time the client must have received our settings frame with our limit information.
|
||||||
throw new Http2StreamErrorException(_currentHeadersStream.StreamId, CoreStrings.Http2ErrorMaxStreams, Http2ErrorCode.REFUSED_STREAM);
|
throw new Http2StreamErrorException(_currentHeadersStream.StreamId, CoreStrings.Http2ErrorMaxStreams, Http2ErrorCode.REFUSED_STREAM);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -124,7 +124,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
Logger.LogError(ex, "An error occured running an IConnectionCompleteFeature.OnCompleted callback.");
|
Logger.LogError(ex, "An error occurred running an IConnectionCompleteFeature.OnCompleted callback.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -139,7 +139,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
Logger.LogError(ex, "An error occured running an IConnectionCompleteFeature.OnCompleted callback.");
|
Logger.LogError(ex, "An error occurred running an IConnectionCompleteFeature.OnCompleted callback.");
|
||||||
}
|
}
|
||||||
|
|
||||||
while (onCompleted.TryPop(out var entry))
|
while (onCompleted.TryPop(out var entry))
|
||||||
|
|
@ -150,7 +150,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
Logger.LogError(ex, "An error occured running an IConnectionCompleteFeature.OnCompleted callback.");
|
Logger.LogError(ex, "An error occurred running an IConnectionCompleteFeature.OnCompleted callback.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -114,7 +114,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Tests
|
||||||
Assert.Equal(stateObject, callbackState);
|
Assert.Equal(stateObject, callbackState);
|
||||||
var errors = logger.Messages.Where(e => e.LogLevel >= LogLevel.Error).ToArray();
|
var errors = logger.Messages.Where(e => e.LogLevel >= LogLevel.Error).ToArray();
|
||||||
Assert.Single(errors);
|
Assert.Single(errors);
|
||||||
Assert.Equal("An error occured running an IConnectionCompleteFeature.OnCompleted callback.", errors[0].Message);
|
Assert.Equal("An error occurred running an IConnectionCompleteFeature.OnCompleted callback.", errors[0].Message);
|
||||||
}
|
}
|
||||||
|
|
||||||
private class ThrowingListener : IConnectionListener
|
private class ThrowingListener : IConnectionListener
|
||||||
|
|
|
||||||
|
|
@ -201,7 +201,7 @@ namespace Interop.FunctionalTests
|
||||||
private class BulkContent : HttpContent
|
private class BulkContent : HttpContent
|
||||||
{
|
{
|
||||||
private static readonly byte[] Content;
|
private static readonly byte[] Content;
|
||||||
private static readonly int Repititions = 200;
|
private static readonly int Repetitions = 200;
|
||||||
|
|
||||||
static BulkContent()
|
static BulkContent()
|
||||||
{
|
{
|
||||||
|
|
@ -214,7 +214,7 @@ namespace Interop.FunctionalTests
|
||||||
|
|
||||||
protected override async Task SerializeToStreamAsync(Stream stream, TransportContext context)
|
protected override async Task SerializeToStreamAsync(Stream stream, TransportContext context)
|
||||||
{
|
{
|
||||||
for (var i = 0; i < Repititions; i++)
|
for (var i = 0; i < Repetitions; i++)
|
||||||
{
|
{
|
||||||
using (var timer = new CancellationTokenSource(TimeSpan.FromSeconds(30)))
|
using (var timer = new CancellationTokenSource(TimeSpan.FromSeconds(30)))
|
||||||
{
|
{
|
||||||
|
|
@ -244,7 +244,7 @@ namespace Interop.FunctionalTests
|
||||||
while (read > 0)
|
while (read > 0)
|
||||||
{
|
{
|
||||||
totalRead += read;
|
totalRead += read;
|
||||||
Assert.True(totalRead <= Repititions * Content.Length, "Too Long");
|
Assert.True(totalRead <= Repetitions * Content.Length, "Too Long");
|
||||||
|
|
||||||
for (var offset = 0; offset < read; offset++)
|
for (var offset = 0; offset < read; offset++)
|
||||||
{
|
{
|
||||||
|
|
@ -256,7 +256,7 @@ namespace Interop.FunctionalTests
|
||||||
read = await stream.ReadAsync(buffer, 0, buffer.Length, timer.Token).DefaultTimeout();
|
read = await stream.ReadAsync(buffer, 0, buffer.Length, timer.Token).DefaultTimeout();
|
||||||
}
|
}
|
||||||
|
|
||||||
Assert.True(totalRead == Repititions * Content.Length, "Too Short");
|
Assert.True(totalRead == Repetitions * Content.Length, "Too Short");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1064,7 +1064,7 @@ namespace Interop.FunctionalTests
|
||||||
{
|
{
|
||||||
request.Headers.Add("header" + i, oneKbString + i);
|
request.Headers.Add("header" + i, oneKbString + i);
|
||||||
}
|
}
|
||||||
request.Headers.Host = "localhost"; // The default Host header has a random port value wich can cause the length to vary.
|
request.Headers.Host = "localhost"; // The default Host header has a random port value which can cause the length to vary.
|
||||||
var requestTask = client.SendAsync(request);
|
var requestTask = client.SendAsync(request);
|
||||||
var response = await requestTask.DefaultTimeout();
|
var response = await requestTask.DefaultTimeout();
|
||||||
await serverResult.Task.DefaultTimeout();
|
await serverResult.Task.DefaultTimeout();
|
||||||
|
|
@ -1128,7 +1128,7 @@ namespace Interop.FunctionalTests
|
||||||
[Theory]
|
[Theory]
|
||||||
// Expect this to change when the client implements dynamic request header compression.
|
// Expect this to change when the client implements dynamic request header compression.
|
||||||
// Will the client send the first headers before receiving our settings frame?
|
// Will the client send the first headers before receiving our settings frame?
|
||||||
// We'll probobly need to ensure the settings changes are ack'd before enforcing them.
|
// We'll probably need to ensure the settings changes are ack'd before enforcing them.
|
||||||
[MemberData(nameof(SupportedSchemes))]
|
[MemberData(nameof(SupportedSchemes))]
|
||||||
public async Task Settings_HeaderTableSize_CanBeReduced_Server(string scheme)
|
public async Task Settings_HeaderTableSize_CanBeReduced_Server(string scheme)
|
||||||
{
|
{
|
||||||
|
|
@ -1186,7 +1186,7 @@ namespace Interop.FunctionalTests
|
||||||
}
|
}
|
||||||
|
|
||||||
// Settings_HeaderTableSize_CanBeReduced_Client - The client uses the default 4k HPACK dynamic table size and it cannot be changed.
|
// Settings_HeaderTableSize_CanBeReduced_Client - The client uses the default 4k HPACK dynamic table size and it cannot be changed.
|
||||||
// Nor does Kestrel yet support sending dynaimc table updates, so there's nothing to test here. https://github.com/dotnet/aspnetcore/issues/4715
|
// Nor does Kestrel yet support sending dynamic table updates, so there's nothing to test here. https://github.com/dotnet/aspnetcore/issues/4715
|
||||||
|
|
||||||
[Theory]
|
[Theory]
|
||||||
[MemberData(nameof(SupportedSchemes))]
|
[MemberData(nameof(SupportedSchemes))]
|
||||||
|
|
@ -1243,7 +1243,7 @@ namespace Interop.FunctionalTests
|
||||||
|
|
||||||
// SKIP: https://github.com/dotnet/aspnetcore/issues/17842
|
// SKIP: https://github.com/dotnet/aspnetcore/issues/17842
|
||||||
// The client initially issues all 10 requests before receiving the settings, has 5 refused (after receiving the settings),
|
// The client initially issues all 10 requests before receiving the settings, has 5 refused (after receiving the settings),
|
||||||
// waits for the first 5 to finish, retries the refused 5, and in the end each request completes sucesfully despite the logged errors.
|
// waits for the first 5 to finish, retries the refused 5, and in the end each request completes successfully despite the logged errors.
|
||||||
// Assert.Empty(TestSink.Writes.Where(context => context.Message.Contains("HTTP/2 stream error")));
|
// Assert.Empty(TestSink.Writes.Where(context => context.Message.Contains("HTTP/2 stream error")));
|
||||||
|
|
||||||
await host.StopAsync().DefaultTimeout();
|
await host.StopAsync().DefaultTimeout();
|
||||||
|
|
@ -1304,7 +1304,7 @@ namespace Interop.FunctionalTests
|
||||||
|
|
||||||
// SKIP: https://github.com/dotnet/aspnetcore/issues/17842
|
// SKIP: https://github.com/dotnet/aspnetcore/issues/17842
|
||||||
// The client initially issues all 10 requests before receiving the settings, has 5 refused (after receiving the settings),
|
// The client initially issues all 10 requests before receiving the settings, has 5 refused (after receiving the settings),
|
||||||
// waits for the first 5 to finish, retries the refused 5, and in the end each request completes sucesfully despite the logged errors.
|
// waits for the first 5 to finish, retries the refused 5, and in the end each request completes successfully despite the logged errors.
|
||||||
// Assert.Empty(TestSink.Writes.Where(context => context.Message.Contains("HTTP/2 stream error")));
|
// Assert.Empty(TestSink.Writes.Where(context => context.Message.Contains("HTTP/2 stream error")));
|
||||||
|
|
||||||
await host.StopAsync().DefaultTimeout();
|
await host.StopAsync().DefaultTimeout();
|
||||||
|
|
@ -1356,7 +1356,7 @@ namespace Interop.FunctionalTests
|
||||||
{
|
{
|
||||||
ConfigureKestrel(webHostBuilder, scheme);
|
ConfigureKestrel(webHostBuilder, scheme);
|
||||||
webHostBuilder.ConfigureServices(AddTestLogging)
|
webHostBuilder.ConfigureServices(AddTestLogging)
|
||||||
.Configure(app => app.Run(context => throw new NotImplementedException() ));
|
.Configure(app => app.Run(context => throw new NotImplementedException()));
|
||||||
});
|
});
|
||||||
using var host = await hostBuilder.StartAsync().DefaultTimeout();
|
using var host = await hostBuilder.StartAsync().DefaultTimeout();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -102,11 +102,11 @@ namespace Microsoft.AspNetCore.DiagnosticsViewPage.Views
|
||||||
|
|
||||||
private string AttributeEnding { get; set; }
|
private string AttributeEnding { get; set; }
|
||||||
|
|
||||||
protected void BeginWriteAttribute(string name, string begining, int startPosition, string ending, int endPosition, int thingy)
|
protected void BeginWriteAttribute(string name, string beginning, int startPosition, string ending, int endPosition, int thingy)
|
||||||
{
|
{
|
||||||
Debug.Assert(string.IsNullOrEmpty(AttributeEnding));
|
Debug.Assert(string.IsNullOrEmpty(AttributeEnding));
|
||||||
|
|
||||||
Output.Write(begining);
|
Output.Write(beginning);
|
||||||
AttributeEnding = ending;
|
AttributeEnding = ending;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -149,11 +149,11 @@ namespace Microsoft.Extensions.RazorViews
|
||||||
|
|
||||||
private string AttributeEnding { get; set; }
|
private string AttributeEnding { get; set; }
|
||||||
|
|
||||||
protected void BeginWriteAttribute(string name, string begining, int startPosition, string ending, int endPosition, int thingy)
|
protected void BeginWriteAttribute(string name, string beginning, int startPosition, string ending, int endPosition, int thingy)
|
||||||
{
|
{
|
||||||
Debug.Assert(string.IsNullOrEmpty(AttributeEnding));
|
Debug.Assert(string.IsNullOrEmpty(AttributeEnding));
|
||||||
|
|
||||||
Output.Write(begining);
|
Output.Write(beginning);
|
||||||
AttributeEnding = ending;
|
AttributeEnding = ending;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -132,13 +132,13 @@ namespace Microsoft.AspNetCore.SignalR.Internal
|
||||||
|
|
||||||
var genericMethodInfo = adapterMethodInfo.MakeGenericMethod(streamReturnType);
|
var genericMethodInfo = adapterMethodInfo.MakeGenericMethod(streamReturnType);
|
||||||
var methodParameters = genericMethodInfo.GetParameters();
|
var methodParameters = genericMethodInfo.GetParameters();
|
||||||
var methodArguements = new Expression[]
|
var methodArguments = new Expression[]
|
||||||
{
|
{
|
||||||
Expression.Convert(parameters[0], methodParameters[0].ParameterType),
|
Expression.Convert(parameters[0], methodParameters[0].ParameterType),
|
||||||
parameters[1],
|
parameters[1],
|
||||||
};
|
};
|
||||||
|
|
||||||
var methodCall = Expression.Call(null, genericMethodInfo, methodArguements);
|
var methodCall = Expression.Call(null, genericMethodInfo, methodArguments);
|
||||||
var lambda = Expression.Lambda<Func<object, CancellationToken, IAsyncEnumerable<object>>>(methodCall, parameters);
|
var lambda = Expression.Lambda<Func<object, CancellationToken, IAsyncEnumerable<object>>>(methodCall, parameters);
|
||||||
return lambda.Compile();
|
return lambda.Compile();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -667,7 +667,7 @@ namespace Microsoft.AspNetCore.SignalR.Tests
|
||||||
return new AsyncEnumerableImpl<string>(CounterAsyncEnumerable(count));
|
return new AsyncEnumerableImpl<string>(CounterAsyncEnumerable(count));
|
||||||
}
|
}
|
||||||
|
|
||||||
public AsyncEnumerableImplChannelThrows<string> AsyncEnumerableIsPreferedOverChannelReader(int count)
|
public AsyncEnumerableImplChannelThrows<string> AsyncEnumerableIsPreferredOverChannelReader(int count)
|
||||||
{
|
{
|
||||||
return new AsyncEnumerableImplChannelThrows<string>(CounterChannel(count));
|
return new AsyncEnumerableImplChannelThrows<string>(CounterChannel(count));
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2136,7 +2136,7 @@ namespace Microsoft.AspNetCore.SignalR.Tests
|
||||||
nameof(StreamingHub.CounterAsyncEnumerable),
|
nameof(StreamingHub.CounterAsyncEnumerable),
|
||||||
nameof(StreamingHub.CounterAsyncEnumerableAsync),
|
nameof(StreamingHub.CounterAsyncEnumerableAsync),
|
||||||
nameof(StreamingHub.CounterAsyncEnumerableImpl),
|
nameof(StreamingHub.CounterAsyncEnumerableImpl),
|
||||||
nameof(StreamingHub.AsyncEnumerableIsPreferedOverChannelReader),
|
nameof(StreamingHub.AsyncEnumerableIsPreferredOverChannelReader),
|
||||||
};
|
};
|
||||||
|
|
||||||
foreach (var method in methods)
|
foreach (var method in methods)
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ namespace Microsoft.AspNetCore.SignalR.StackExchangeRedis
|
||||||
|
|
||||||
internal async Task<IConnectionMultiplexer> ConnectAsync(TextWriter log)
|
internal async Task<IConnectionMultiplexer> ConnectAsync(TextWriter log)
|
||||||
{
|
{
|
||||||
// Factory is publically settable. Assigning to a local variable before null check for thread safety.
|
// Factory is publicly settable. Assigning to a local variable before null check for thread safety.
|
||||||
var factory = ConnectionFactory;
|
var factory = ConnectionFactory;
|
||||||
if (factory == null)
|
if (factory == null)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue