Class HttpObfuscationHelpers
Static class that provides helper functions for HTTP Logging.
Inherited Members
Namespace: Microsoft.Graph.Communications.Common.Telemetry.HttpLogging
Assembly: Microsoft.Graph.Communications.Common.dll
Syntax
public static class HttpObfuscationHelpers
Methods
GetUrlText(Uri, Boolean, IEnumerable<UriFilter>, IObfuscationEngine)
Converts the URL to its representation depending on the filters.
Declaration
public static string GetUrlText(Uri url, bool obfuscationEnabled, IEnumerable<UriFilter> uriFilters = null, IObfuscationEngine engine = null)
Parameters
Type | Name | Description |
---|---|---|
Uri | url | The URL. |
Boolean | obfuscationEnabled | if set to |
IEnumerable<UriFilter> | uriFilters | The URI filters. |
IObfuscationEngine | engine | Custom obfuscation engine. If null, use (redacted) |
Returns
Type | Description |
---|---|
String | String representation |
LogHeaderText(ObfuscationConfiguration, IEnumerable<KeyValuePair<String, IEnumerable<String>>>)
Logs the header text.
Declaration
public static IEnumerable<string> LogHeaderText(this ObfuscationConfiguration configuration, IEnumerable<KeyValuePair<string, IEnumerable<string>>> headers)
Parameters
Type | Name | Description |
---|---|---|
ObfuscationConfiguration | configuration | The configuration. |
IEnumerable<KeyValuePair<String, IEnumerable<String>>> | headers | The headers. |
Returns
Type | Description |
---|---|
IEnumerable<String> | The obfuscated header and value pairs. |
LogHeaderText(ObfuscationConfiguration, String, IEnumerable<String>)
Logs the header text.
Declaration
public static string LogHeaderText(this ObfuscationConfiguration configuration, string headerName, IEnumerable<string> headerValues)
Parameters
Type | Name | Description |
---|---|---|
ObfuscationConfiguration | configuration | The configuration. |
String | headerName | Name of the header. |
IEnumerable<String> | headerValues | The header values. |
Returns
Type | Description |
---|---|
String | The obfuscated header and value pair. |