Enabled xml doc generation

This commit is contained in:
Ajay Bhargav Baaskaran 2016-02-17 16:30:00 -08:00
parent ec5808f8b6
commit 3007398648
20 changed files with 58 additions and 32 deletions

View File

@ -1,12 +1,7 @@
{
"adx": { // Packages written by the ADX team and that ship on NuGet.org
"rules": [
"AssemblyHasDocumentFileRule",
"AssemblyHasVersionAttributesRule",
"AssemblyHasServicingAttributeRule",
"AssemblyHasNeutralResourcesLanguageAttributeRule",
"SatellitePackageRule",
"StrictSemanticVersionValidationRule"
"AdxVerificationCompositeRule"
],
"packages": {
"Microsoft.AspNetCore.Cryptography.Internal": { },
@ -25,12 +20,7 @@
},
"Default": { // Rules to run for packages not listed in any other set.
"rules": [
"AssemblyHasDocumentFileRule",
"AssemblyHasVersionAttributesRule",
"AssemblyHasServicingAttributeRule",
"AssemblyHasNeutralResourcesLanguageAttributeRule",
"SatellitePackageRule",
"StrictSemanticVersionValidationRule"
"DefaultCompositeRule"
]
}
}

View File

@ -21,6 +21,8 @@
"compilationOptions": {
"allowUnsafe": true,
"warningsAsErrors": true,
"keyFile": "../../tools/Key.snk"
"keyFile": "../../tools/Key.snk",
"nowarn": [ "CS1591" ],
"xmlDoc": true
}
}

View File

@ -21,6 +21,8 @@
"compilationOptions": {
"allowUnsafe": true,
"warningsAsErrors": true,
"keyFile": "../../tools/Key.snk"
"keyFile": "../../tools/Key.snk",
"nowarn": [ "CS1591" ],
"xmlDoc": true
}
}

View File

@ -248,7 +248,7 @@ namespace Microsoft.AspNetCore.DataProtection
/// <param name="protector">The data protector to use for this operation.</param>
/// <param name="protectedData">The protected data to unprotect.</param>
/// <returns>The plaintext form of the protected data.</returns>
/// <exception cref="CryptographicException">
/// <exception cref="System.Security.Cryptography.CryptographicException">
/// Thrown if <paramref name="protectedData"/> is invalid or malformed.
/// </exception>
public static string Unprotect(this IDataProtector protector, string protectedData)

View File

@ -11,7 +11,7 @@ namespace Microsoft.AspNetCore.DataProtection
/// <summary>
/// Creates an <see cref="IDataProtector"/> given a purpose.
/// </summary>
/// <param name="purposes">
/// <param name="purpose">
/// The purpose to be assigned to the newly-created <see cref="IDataProtector"/>.
/// </param>
/// <returns>An IDataProtector tied to the provided purpose.</returns>

View File

@ -20,7 +20,7 @@ namespace Microsoft.AspNetCore.DataProtection
/// </summary>
/// <param name="protectedData">The protected data to unprotect.</param>
/// <returns>The plaintext form of the protected data.</returns>
/// <exception cref="CryptographicException">
/// <exception cref="System.Security.Cryptography.CryptographicException">
/// Thrown if the protected data is invalid or malformed.
/// </exception>
byte[] Unprotect(byte[] protectedData);

View File

@ -23,6 +23,8 @@
},
"compilationOptions": {
"warningsAsErrors": true,
"keyFile": "../../tools/Key.snk"
"keyFile": "../../tools/Key.snk",
"nowarn": [ "CS1591" ],
"xmlDoc": true
}
}

View File

@ -101,7 +101,7 @@ namespace Microsoft.AspNetCore.DataProtection
/// <param name="expiration">An 'out' parameter which upon a successful unprotect
/// operation receives the expiration date of the payload.</param>
/// <returns>The plaintext form of the protected data.</returns>
/// <exception cref="CryptographicException">
/// <exception cref="System.Security.Cryptography.CryptographicException">
/// Thrown if <paramref name="protectedData"/> is invalid, malformed, or expired.
/// </exception>
public static string Unprotect(this ITimeLimitedDataProtector protector, string protectedData, out DateTimeOffset expiration)

View File

@ -19,7 +19,7 @@ namespace Microsoft.AspNetCore.DataProtection
/// <summary>
/// Creates an <see cref="ITimeLimitedDataProtector"/> given a purpose.
/// </summary>
/// <param name="purposes">
/// <param name="purpose">
/// The purpose to be assigned to the newly-created <see cref="ITimeLimitedDataProtector"/>.
/// </param>
/// <returns>An <see cref="ITimeLimitedDataProtector"/> tied to the provided purpose.</returns>
@ -47,7 +47,7 @@ namespace Microsoft.AspNetCore.DataProtection
/// <param name="expiration">An 'out' parameter which upon a successful unprotect
/// operation receives the expiration date of the payload.</param>
/// <returns>The plaintext form of the protected data.</returns>
/// <exception cref="CryptographicException">
/// <exception cref="System.Security.Cryptography.CryptographicException">
/// Thrown if <paramref name="protectedData"/> is invalid, malformed, or expired.
/// </exception>
byte[] Unprotect(byte[] protectedData, out DateTimeOffset expiration);

View File

@ -19,6 +19,8 @@
},
"compilationOptions": {
"warningsAsErrors": true,
"keyFile": "../../tools/Key.snk"
"keyFile": "../../tools/Key.snk",
"nowarn": [ "CS1591" ],
"xmlDoc": true
}
}

View File

@ -20,7 +20,9 @@
},
"compilationOptions": {
"warningsAsErrors": true,
"keyFile": "../../tools/Key.snk"
"keyFile": "../../tools/Key.snk",
"nowarn": [ "CS1591" ],
"xmlDoc": true
},
"packInclude": {
"content/net451/": "web.config.transform"

View File

@ -7,7 +7,8 @@ namespace Microsoft.AspNetCore.DataProtection.AuthenticatedEncryption.Configurat
{
/// <summary>
/// Represents a configured authenticated encryption mechanism which uses
/// managed <see cref="SymmetricAlgorithm"/> and <see cref="KeyedHashAlgorithm"/> types.
/// managed <see cref="System.Security.Cryptography.SymmetricAlgorithm"/> and
/// <see cref="System.Security.Cryptography.KeyedHashAlgorithm"/> types.
/// </summary>
public sealed class ManagedAuthenticatedEncryptorConfiguration : IAuthenticatedEncryptorConfiguration, IInternalAuthenticatedEncryptorConfiguration
{

View File

@ -17,6 +17,7 @@ using System.Security.Cryptography.X509Certificates;
namespace Microsoft.AspNetCore.DataProtection
{
#if !DOTNET5_4
/// <summary>
/// Provides access to configuration for the data protection system, which allows the
/// developer to configure default cryptographic algorithms, key storage locations,
@ -26,7 +27,7 @@ namespace Microsoft.AspNetCore.DataProtection
/// <para>
/// If the developer changes the at-rest key protection mechanism, it is intended that
/// he also change the key storage location, and vice versa. For instance, a call to
/// <see cref="ProtectKeysWithCertificate(string)"/> should generally be accompanied by
/// <see cref="ProtectKeysWithCertificate(string)" /> should generally be accompanied by
/// a call to <see cref="PersistKeysToFileSystem(DirectoryInfo)"/>, or exceptions may
/// occur at runtime due to the data protection system not knowing where to persist keys.
/// </para>
@ -43,6 +44,31 @@ namespace Microsoft.AspNetCore.DataProtection
/// contain existing keys that use older algorithms or protection mechanisms.
/// </para>
/// </remarks>
#else
/// <summary>
/// Provides access to configuration for the data protection system, which allows the
/// developer to configure default cryptographic algorithms, key storage locations,
/// and the mechanism by which keys are protected at rest.
/// </summary>
/// <remarks>
/// <para>
/// If the developer changes the at-rest key protection mechanism, it is intended that
/// he also change the key storage location, and vice versa.
/// </para>
/// <para>
/// Similarly, when a developer modifies the default protected payload cryptographic
/// algorithms, it is intended that he also select an explitiy key storage location.
/// A call to <see cref="UseCryptographicAlgorithms(AuthenticatedEncryptionOptions)"/>
/// should therefore generally be paired with a call to <see cref="PersistKeysToFileSystem(DirectoryInfo)"/>,
/// for example.
/// </para>
/// <para>
/// When the default cryptographic algorithms or at-rest key protection mechanisms are
/// changed, they only affect <strong>new</strong> keys in the repository. The repository may
/// contain existing keys that use older algorithms or protection mechanisms.
/// </para>
/// </remarks>
#endif
public class DataProtectionConfiguration
{
/// <summary>
@ -284,7 +310,7 @@ namespace Microsoft.AspNetCore.DataProtection
/// <remarks>
/// See https://msdn.microsoft.com/en-us/library/windows/desktop/hh769091(v=vs.85).aspx
/// and https://msdn.microsoft.com/en-us/library/windows/desktop/hh706800(v=vs.85).aspx
/// for more information on valid values for the the <paramref name="descriptor"/>
/// for more information on valid values for the the <paramref name="protectionDescriptorRule"/>
/// and <paramref name="flags"/> arguments.
/// This API is only supported on Windows 8 / Windows Server 2012 and higher.
/// </remarks>

View File

@ -81,7 +81,7 @@ namespace Microsoft.AspNetCore.DataProtection
}
/// <summary>
/// Returns a <see cref="Policy"/> object from the default registry location.
/// Returns an array of <see cref="ServiceDescriptor"/>s from the default registry location.
/// </summary>
public static ServiceDescriptor[] ResolveDefaultPolicy()
{

View File

@ -39,6 +39,7 @@ namespace Microsoft.AspNetCore.DataProtection.Repositories
/// Creates a <see cref="RegistryXmlRepository"/> with keys stored in the given registry key.
/// </summary>
/// <param name="registryKey">The registry key in which to persist key material.</param>
/// <param name="services">The <see cref="IServiceProvider"/> used to resolve services.</param>
public RegistryXmlRepository(RegistryKey registryKey, IServiceProvider services)
{
if (registryKey == null)

View File

@ -43,7 +43,6 @@ namespace Microsoft.AspNetCore.DataProtection.XmlEncryption
/// </summary>
/// <param name="encryptedElement">An encrypted XML element.</param>
/// <returns>The decrypted form of <paramref name="encryptedElement"/>.</returns>
/// <remarks>
public XElement Decrypt(XElement encryptedElement)
{
if (encryptedElement == null)

View File

@ -40,7 +40,6 @@ namespace Microsoft.AspNetCore.DataProtection.XmlEncryption
/// </summary>
/// <param name="encryptedElement">An encrypted XML element.</param>
/// <returns>The decrypted form of <paramref name="encryptedElement"/>.</returns>
/// <remarks>
public XElement Decrypt(XElement encryptedElement)
{
if (encryptedElement == null)

View File

@ -40,7 +40,6 @@ namespace Microsoft.AspNetCore.DataProtection.XmlEncryption
/// </summary>
/// <param name="encryptedElement">An encrypted XML element.</param>
/// <returns>The decrypted form of <paramref name="encryptedElement"/>.</returns>
/// <remarks>
public XElement Decrypt(XElement encryptedElement)
{
if (encryptedElement == null)

View File

@ -17,7 +17,6 @@ namespace Microsoft.AspNetCore.DataProtection.XmlEncryption
/// </summary>
/// <param name="encryptedElement">An encrypted XML element.</param>
/// <returns>The decrypted form of <paramref name="encryptedElement"/>.</returns>
/// <remarks>
public XElement Decrypt(XElement encryptedElement)
{
if (encryptedElement == null)

View File

@ -38,6 +38,8 @@
"compilationOptions": {
"allowUnsafe": true,
"warningsAsErrors": true,
"keyFile": "../../tools/Key.snk"
"keyFile": "../../tools/Key.snk",
"nowarn": [ "CS1591" ],
"xmlDoc": true
}
}