Commit 938da66c authored by Brickner_cp's avatar Brickner_cp

Warnings, Code Analysis and Documentation. 465 warnings left.

parent 75720163
...@@ -158,7 +158,7 @@ namespace PcapDotNet.Core.Test ...@@ -158,7 +158,7 @@ namespace PcapDotNet.Core.Test
case "dns.qry.type": case "dns.qry.type":
case "dns.resp.type": case "dns.resp.type":
resourceRecordAttributeField.AssertShowHex((ushort)resourceRecord.Type); resourceRecordAttributeField.AssertShowHex((ushort)resourceRecord.DnsType);
break; break;
case "dns.qry.class": case "dns.qry.class":
...@@ -198,7 +198,7 @@ namespace PcapDotNet.Core.Test ...@@ -198,7 +198,7 @@ namespace PcapDotNet.Core.Test
string dataFieldName = dataField.Name(); string dataFieldName = dataField.Name();
string dataFieldShow = dataField.Show(); string dataFieldShow = dataField.Show();
string dataFieldShowUntilColon = dataFieldShow.Split(':')[0]; string dataFieldShowUntilColon = dataFieldShow.Split(':')[0];
switch (resourceRecord.Type) switch (resourceRecord.DnsType)
{ {
case DnsType.A: case DnsType.A:
switch (dataFieldName) switch (dataFieldName)
......
...@@ -83,7 +83,7 @@ namespace PcapDotNet.Packets.Test ...@@ -83,7 +83,7 @@ namespace PcapDotNet.Packets.Test
Assert.AreEqual(dnsLayer, actualLayer, "DNS Layer"); Assert.AreEqual(dnsLayer, actualLayer, "DNS Layer");
Assert.IsTrue(packet.Ethernet.IpV4.Udp.Dns.IsValid); Assert.IsTrue(packet.Ethernet.IpV4.Udp.Dns.IsValid);
DnsDataResourceRecord opt = packet.Ethernet.IpV4.Udp.Dns.Additionals.FirstOrDefault(additional => additional.Type == DnsType.Opt); DnsDataResourceRecord opt = packet.Ethernet.IpV4.Udp.Dns.Additionals.FirstOrDefault(additional => additional.DnsType == DnsType.Opt);
Assert.AreEqual(opt, packet.Ethernet.IpV4.Udp.Dns.OptionsRecord); Assert.AreEqual(opt, packet.Ethernet.IpV4.Udp.Dns.OptionsRecord);
foreach (var record in packet.Ethernet.IpV4.Udp.Dns.ResourceRecords) foreach (var record in packet.Ethernet.IpV4.Udp.Dns.ResourceRecords)
...@@ -97,7 +97,7 @@ namespace PcapDotNet.Packets.Test ...@@ -97,7 +97,7 @@ namespace PcapDotNet.Packets.Test
{ {
MoreAssert.IsBiggerOrEqual(9, record.ToString().Length); MoreAssert.IsBiggerOrEqual(9, record.ToString().Length);
Assert.IsTrue(record.Equals((object)record)); Assert.IsTrue(record.Equals((object)record));
Assert.IsInstanceOfType(record.Data, DnsResourceData.GetDnsResourceDataType(record.Type) ?? typeof(DnsResourceDataAnything)); Assert.IsInstanceOfType(record.Data, DnsResourceData.GetDnsResourceDataType(record.DnsType) ?? typeof(DnsResourceDataAnything));
Assert.IsTrue(record.DomainName.Equals((object)record.DomainName)); Assert.IsTrue(record.DomainName.Equals((object)record.DomainName));
} }
} }
......
...@@ -183,7 +183,7 @@ namespace PcapDotNet.Packets.TestUtils ...@@ -183,7 +183,7 @@ namespace PcapDotNet.Packets.TestUtils
case DnsType.Key: case DnsType.Key:
return new DnsResourceDataKey(random.NextBool(), random.NextBool(), random.NextBool(), random.NextBool(), random.NextBool(), return new DnsResourceDataKey(random.NextBool(), random.NextBool(), random.NextBool(), random.NextBool(), random.NextBool(),
random.NextBool(), random.NextEnum<DnsKeyNameType>(), random.NextFlags<DnsKeySignatory>(), random.NextBool(), random.NextEnum<DnsKeyNameType>(), random.NextFlags<DnsKeySignatoryAttributes>(),
random.NextEnum<DnsKeyProtocol>(), random.NextEnum<DnsAlgorithm>(), random.NextEnum<DnsKeyProtocol>(), random.NextEnum<DnsAlgorithm>(),
random.NextBool() ? (ushort?)random.NextUShort() : null, random.NextDataSegment(random.Next(100))); random.NextBool() ? (ushort?)random.NextUShort() : null, random.NextDataSegment(random.Next(100)));
......
...@@ -320,6 +320,7 @@ namespace PcapDotNet.Packets ...@@ -320,6 +320,7 @@ namespace PcapDotNet.Packets
return result; return result;
} }
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1720:IdentifiersShouldNotContainTypeNames", MessageId = "long")]
public static long ReadLong(this byte[] buffer, int offset, Endianity endianity) public static long ReadLong(this byte[] buffer, int offset, Endianity endianity)
{ {
long value = ReadLong(buffer, offset); long value = ReadLong(buffer, offset);
...@@ -328,6 +329,7 @@ namespace PcapDotNet.Packets ...@@ -328,6 +329,7 @@ namespace PcapDotNet.Packets
return value; return value;
} }
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1720:IdentifiersShouldNotContainTypeNames", MessageId = "ulong")]
public static ulong ReadULong(this byte[] buffer, int offset, Endianity endianity) public static ulong ReadULong(this byte[] buffer, int offset, Endianity endianity)
{ {
return (ulong)buffer.ReadLong(offset, endianity); return (ulong)buffer.ReadLong(offset, endianity);
......
...@@ -477,7 +477,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -477,7 +477,7 @@ namespace PcapDotNet.Packets.Dns
if (ParseRecords(AdditionalsOffset, () => AdditionalCount, DnsDataResourceRecord.Parse, ref _additionals, ref nextOffset) && if (ParseRecords(AdditionalsOffset, () => AdditionalCount, DnsDataResourceRecord.Parse, ref _additionals, ref nextOffset) &&
_additionals != null) _additionals != null)
{ {
_options = (DnsOptResourceRecord)_additionals.FirstOrDefault(additional => additional.Type == DnsType.Opt); _options = (DnsOptResourceRecord)_additionals.FirstOrDefault(additional => additional.DnsType == DnsType.Opt);
} }
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
namespace PcapDotNet.Packets.Dns namespace PcapDotNet.Packets.Dns
{ {
[Flags] [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags"), Flags]
public enum DnsOptFlags : ushort public enum DnsOptFlags : ushort
{ {
DnsSecOk = 0x8000, DnsSecOk = 0x8000,
......
...@@ -28,6 +28,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -28,6 +28,7 @@ namespace PcapDotNet.Packets.Dns
/// </summary> /// </summary>
public sealed class DnsOptResourceRecord : DnsDataResourceRecord public sealed class DnsOptResourceRecord : DnsDataResourceRecord
{ {
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "flags")]
public DnsOptResourceRecord(DnsDomainName domainName, ushort sendersUdpPayloadSize, byte extendedReturnCode, DnsOptVersion version, DnsOptFlags flags, DnsResourceDataOptions data) public DnsOptResourceRecord(DnsDomainName domainName, ushort sendersUdpPayloadSize, byte extendedReturnCode, DnsOptVersion version, DnsOptFlags flags, DnsResourceDataOptions data)
: this(domainName, (DnsClass)sendersUdpPayloadSize, (int)BitSequence.Merge(extendedReturnCode, (byte)version, (ushort)flags), data) : this(domainName, (DnsClass)sendersUdpPayloadSize, (int)BitSequence.Merge(extendedReturnCode, (byte)version, (ushort)flags), data)
{ {
...@@ -54,6 +55,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -54,6 +55,7 @@ namespace PcapDotNet.Packets.Dns
/// </summary> /// </summary>
public DnsOptVersion Version { get { return (DnsOptVersion)(Ttl >> 16); }} public DnsOptVersion Version { get { return (DnsOptVersion)(Ttl >> 16); }}
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags")]
public DnsOptFlags Flags { get { return (DnsOptFlags)Ttl; } } public DnsOptFlags Flags { get { return (DnsOptFlags)Ttl; } }
internal DnsOptResourceRecord(DnsDomainName domainName, DnsClass dnsClass, int ttl, DnsResourceData data) internal DnsOptResourceRecord(DnsDomainName domainName, DnsClass dnsClass, int ttl, DnsResourceData data)
......
...@@ -46,7 +46,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -46,7 +46,7 @@ namespace PcapDotNet.Packets.Dns
/// <summary> /// <summary>
/// Two octets containing one of the RR TYPE codes. /// Two octets containing one of the RR TYPE codes.
/// </summary> /// </summary>
public DnsType Type { get; private set; } public DnsType DnsType { get; private set; }
public DnsClass DnsClass { get; private set; } public DnsClass DnsClass { get; private set; }
...@@ -69,13 +69,13 @@ namespace PcapDotNet.Packets.Dns ...@@ -69,13 +69,13 @@ namespace PcapDotNet.Packets.Dns
public override string ToString() public override string ToString()
{ {
return DomainName + " " + Type + " " + DnsClass; return DomainName + " " + DnsType + " " + DnsClass;
} }
protected DnsResourceRecord(DnsDomainName domainName, DnsType type, DnsClass dnsClass) protected DnsResourceRecord(DnsDomainName domainName, DnsType type, DnsClass dnsClass)
{ {
DomainName = domainName; DomainName = domainName;
Type = type; DnsType = type;
DnsClass = dnsClass; DnsClass = dnsClass;
} }
...@@ -83,13 +83,13 @@ namespace PcapDotNet.Packets.Dns ...@@ -83,13 +83,13 @@ namespace PcapDotNet.Packets.Dns
{ {
return other != null && return other != null &&
DomainName.Equals(other.DomainName) && DomainName.Equals(other.DomainName) &&
Type.Equals(other.Type) && DnsType.Equals(other.DnsType) &&
DnsClass.Equals(other.DnsClass); DnsClass.Equals(other.DnsClass);
} }
internal int GetHashCodeBase() internal int GetHashCodeBase()
{ {
return Sequence.GetHashCode(DomainName, BitSequence.Merge((ushort)Type, (ushort)DnsClass)); return Sequence.GetHashCode(DomainName, BitSequence.Merge((ushort)DnsType, (ushort)DnsClass));
} }
internal static bool TryParseBase(DnsDatagram dns, int offsetInDns, internal static bool TryParseBase(DnsDatagram dns, int offsetInDns,
...@@ -120,7 +120,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -120,7 +120,7 @@ namespace PcapDotNet.Packets.Dns
{ {
int length = 0; int length = 0;
length += DomainName.Write(buffer, dnsOffset, compressionData, offsetInDns + length); length += DomainName.Write(buffer, dnsOffset, compressionData, offsetInDns + length);
buffer.Write(dnsOffset + offsetInDns + length, (ushort)Type, Endianity.Big); buffer.Write(dnsOffset + offsetInDns + length, (ushort)DnsType, Endianity.Big);
length += sizeof(ushort); length += sizeof(ushort);
buffer.Write(dnsOffset + offsetInDns + length, (ushort)DnsClass, Endianity.Big); buffer.Write(dnsOffset + offsetInDns + length, (ushort)DnsClass, Endianity.Big);
length += sizeof(ushort); length += sizeof(ushort);
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
namespace PcapDotNet.Packets.Dns namespace PcapDotNet.Packets.Dns
{ {
[Flags] [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags"), Flags]
public enum DnsCertificationAuthorityAuthorizationFlags : byte public enum DnsCertificationAuthorityAuthorizationFlags : byte
{ {
/// <summary> /// <summary>
......
...@@ -8,7 +8,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -8,7 +8,7 @@ namespace PcapDotNet.Packets.Dns
{ {
public static DnsGatewayNone None { get { return _none; } } public static DnsGatewayNone None { get { return _none; } }
public abstract DnsGatewayType Type { get; } public abstract DnsGatewayType GatewayType { get; }
public abstract int Length { get; } public abstract int Length { get; }
...@@ -21,7 +21,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -21,7 +21,7 @@ namespace PcapDotNet.Packets.Dns
public override int GetHashCode() public override int GetHashCode()
{ {
return Type.GetHashCode() ^ DataGetHashCode(); return GatewayType.GetHashCode() ^ DataGetHashCode();
} }
internal abstract int DataGetHashCode(); internal abstract int DataGetHashCode();
......
...@@ -11,7 +11,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -11,7 +11,7 @@ namespace PcapDotNet.Packets.Dns
public DnsDomainName Value { get; private set; } public DnsDomainName Value { get; private set; }
public override DnsGatewayType Type public override DnsGatewayType GatewayType
{ {
get { return DnsGatewayType.DomainName; } get { return DnsGatewayType.DomainName; }
} }
......
...@@ -12,7 +12,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -12,7 +12,7 @@ namespace PcapDotNet.Packets.Dns
public IpV4Address Value { get; private set; } public IpV4Address Value { get; private set; }
public override DnsGatewayType Type public override DnsGatewayType GatewayType
{ {
get { return DnsGatewayType.IpV4; } get { return DnsGatewayType.IpV4; }
} }
......
...@@ -12,7 +12,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -12,7 +12,7 @@ namespace PcapDotNet.Packets.Dns
public IpV6Address Value { get; private set; } public IpV6Address Value { get; private set; }
public override DnsGatewayType Type public override DnsGatewayType GatewayType
{ {
get { return DnsGatewayType.IpV6; } get { return DnsGatewayType.IpV6; }
} }
......
...@@ -4,7 +4,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -4,7 +4,7 @@ namespace PcapDotNet.Packets.Dns
{ {
public class DnsGatewayNone : DnsGateway, IEquatable<DnsGatewayNone> public class DnsGatewayNone : DnsGateway, IEquatable<DnsGatewayNone>
{ {
public override DnsGatewayType Type public override DnsGatewayType GatewayType
{ {
get { return DnsGatewayType.None; } get { return DnsGatewayType.None; }
} }
......
...@@ -6,7 +6,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -6,7 +6,7 @@ namespace PcapDotNet.Packets.Dns
/// RFC 2137. /// RFC 2137.
/// </summary> /// </summary>
[Flags] [Flags]
public enum DnsKeySignatory : byte public enum DnsKeySignatoryAttributes : byte
{ {
/// <summary> /// <summary>
/// The general update signatory field bit has no special meaning. /// The general update signatory field bit has no special meaning.
......
...@@ -83,9 +83,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -83,9 +83,9 @@ namespace PcapDotNet.Packets.Dns
PrefixName.Equals(other.PrefixName); PrefixName.Equals(other.PrefixName);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataA6); return Equals(obj as DnsResourceDataA6);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -45,9 +45,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -45,9 +45,9 @@ namespace PcapDotNet.Packets.Dns
Items.SequenceEqual(other.Items); Items.SequenceEqual(other.Items);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataAddressPrefixList); return Equals(obj as DnsResourceDataAddressPrefixList);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -29,9 +29,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -29,9 +29,9 @@ namespace PcapDotNet.Packets.Dns
return other != null && Data.Equals(other.Data); return other != null && Data.Equals(other.Data);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataAnything); return Equals(obj as DnsResourceDataAnything);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -54,9 +54,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -54,9 +54,9 @@ namespace PcapDotNet.Packets.Dns
Address.Equals(other.Address); Address.Equals(other.Address);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataAtmAddress); return Equals(obj as DnsResourceDataAtmAddress);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -76,9 +76,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -76,9 +76,9 @@ namespace PcapDotNet.Packets.Dns
Certificate.Equals(other.Certificate); Certificate.Equals(other.Certificate);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataCertificate); return Equals(obj as DnsResourceDataCertificate);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -32,6 +32,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -32,6 +32,7 @@ namespace PcapDotNet.Packets.Dns
private const int ConstantPartLength = Offset.Tag; private const int ConstantPartLength = Offset.Tag;
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "flags")]
public DnsResourceDataCertificationAuthorityAuthorization(DnsCertificationAuthorityAuthorizationFlags flags, DataSegment tag, DataSegment value) public DnsResourceDataCertificationAuthorityAuthorization(DnsCertificationAuthorityAuthorizationFlags flags, DataSegment tag, DataSegment value)
{ {
if (tag == null) if (tag == null)
...@@ -48,6 +49,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -48,6 +49,7 @@ namespace PcapDotNet.Packets.Dns
/// <summary> /// <summary>
/// Flags of the record. /// Flags of the record.
/// </summary> /// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags")]
public DnsCertificationAuthorityAuthorizationFlags Flags { get; private set; } public DnsCertificationAuthorityAuthorizationFlags Flags { get; private set; }
/// <summary> /// <summary>
...@@ -72,9 +74,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -72,9 +74,9 @@ namespace PcapDotNet.Packets.Dns
Value.SequenceEqual(other.Value); Value.SequenceEqual(other.Value);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataCertificationAuthorityAuthorization); return Equals(obj as DnsResourceDataCertificationAuthorityAuthorization);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -99,9 +99,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -99,9 +99,9 @@ namespace PcapDotNet.Packets.Dns
Digest.Equals(other.Digest); Digest.Equals(other.Digest);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataDelegationSigner); return Equals(obj as DnsResourceDataDelegationSigner);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -101,9 +101,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -101,9 +101,9 @@ namespace PcapDotNet.Packets.Dns
PublicKey.Equals(other.PublicKey); PublicKey.Equals(other.PublicKey);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataDnsKey); return Equals(obj as DnsResourceDataDnsKey);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -34,9 +34,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -34,9 +34,9 @@ namespace PcapDotNet.Packets.Dns
return other != null && Data.Equals(other.Data); return other != null && Data.Equals(other.Data);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataDomainName); return Equals(obj as DnsResourceDataDomainName);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -18,9 +18,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -18,9 +18,9 @@ namespace PcapDotNet.Packets.Dns
DomainNames.SequenceEqual(other.DomainNames); DomainNames.SequenceEqual(other.DomainNames);
} }
public sealed override bool Equals(object other) public sealed override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataDomainNames); return Equals(obj as DnsResourceDataDomainNames);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -56,9 +56,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -56,9 +56,9 @@ namespace PcapDotNet.Packets.Dns
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataGeographicalPosition); return Equals(obj as DnsResourceDataGeographicalPosition);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -94,9 +94,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -94,9 +94,9 @@ namespace PcapDotNet.Packets.Dns
RendezvousServers.SequenceEqual(RendezvousServers); RendezvousServers.SequenceEqual(RendezvousServers);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataHostIdentityProtocol); return Equals(obj as DnsResourceDataHostIdentityProtocol);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -54,7 +54,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -54,7 +54,7 @@ namespace PcapDotNet.Packets.Dns
/// <summary> /// <summary>
/// Indicates the format of the information that is stored in the gateway field. /// Indicates the format of the information that is stored in the gateway field.
/// </summary> /// </summary>
public DnsGatewayType GatewayType { get { return Gateway.Type; } } public DnsGatewayType GatewayType { get { return Gateway.GatewayType; } }
/// <summary> /// <summary>
/// Indicates a gateway to which an IPsec tunnel may be created in order to reach the entity named by this resource record. /// Indicates a gateway to which an IPsec tunnel may be created in order to reach the entity named by this resource record.
...@@ -80,9 +80,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -80,9 +80,9 @@ namespace PcapDotNet.Packets.Dns
PublicKey.Equals(other.PublicKey); PublicKey.Equals(other.PublicKey);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataIpSecKey); return Equals(obj as DnsResourceDataIpSecKey);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -28,9 +28,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -28,9 +28,9 @@ namespace PcapDotNet.Packets.Dns
return other != null && Data.Equals(other.Data); return other != null && Data.Equals(other.Data);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataIpV4); return Equals(obj as DnsResourceDataIpV4);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -28,9 +28,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -28,9 +28,9 @@ namespace PcapDotNet.Packets.Dns
return other != null && Data.Equals(other.Data); return other != null && Data.Equals(other.Data);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataIpV6); return Equals(obj as DnsResourceDataIpV6);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -56,8 +56,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -56,8 +56,9 @@ namespace PcapDotNet.Packets.Dns
private const int ConstantPartLength = Offset.FlagsExtension; private const int ConstantPartLength = Offset.FlagsExtension;
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "flags")]
public DnsResourceDataKey(bool authenticationProhibited, bool confidentialityProhibited, bool experimental, bool userAssociated, bool ipSec, bool email, public DnsResourceDataKey(bool authenticationProhibited, bool confidentialityProhibited, bool experimental, bool userAssociated, bool ipSec, bool email,
DnsKeyNameType nameType, DnsKeySignatory signatory, DnsKeyProtocol protocol, DnsAlgorithm algorithm, ushort? flagsExtension, DnsKeyNameType nameType, DnsKeySignatoryAttributes signatory, DnsKeyProtocol protocol, DnsAlgorithm algorithm, ushort? flagsExtension,
DataSegment publicKey) DataSegment publicKey)
{ {
AuthenticationProhibited = authenticationProhibited; AuthenticationProhibited = authenticationProhibited;
...@@ -130,7 +131,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -130,7 +131,7 @@ namespace PcapDotNet.Packets.Dns
/// If non-zero, indicates that the key can validly sign things as specified in DNS dynamic update. /// If non-zero, indicates that the key can validly sign things as specified in DNS dynamic update.
/// Note that zone keys always have authority to sign any RRs in the zone regardless of the value of the signatory field. /// Note that zone keys always have authority to sign any RRs in the zone regardless of the value of the signatory field.
/// </summary> /// </summary>
public DnsKeySignatory Signatory { get; private set; } public DnsKeySignatoryAttributes Signatory { get; private set; }
/// <summary> /// <summary>
/// It is anticipated that keys stored in DNS will be used in conjunction with a variety of Internet protocols. /// It is anticipated that keys stored in DNS will be used in conjunction with a variety of Internet protocols.
...@@ -147,6 +148,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -147,6 +148,7 @@ namespace PcapDotNet.Packets.Dns
/// Optional second 16 bit flag field after the algorithm octet and before the key data. /// Optional second 16 bit flag field after the algorithm octet and before the key data.
/// Must not be non-null unless one or more such additional bits have been defined and are non-zero. /// Must not be non-null unless one or more such additional bits have been defined and are non-zero.
/// </summary> /// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags")]
public ushort? FlagsExtension { get; private set; } public ushort? FlagsExtension { get; private set; }
/// <summary> /// <summary>
...@@ -173,9 +175,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -173,9 +175,9 @@ namespace PcapDotNet.Packets.Dns
PublicKey.Equals(other.PublicKey); PublicKey.Equals(other.PublicKey);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataKey); return Equals(obj as DnsResourceDataKey);
} }
public override int GetHashCode() public override int GetHashCode()
...@@ -189,7 +191,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -189,7 +191,7 @@ namespace PcapDotNet.Packets.Dns
} }
internal DnsResourceDataKey() internal DnsResourceDataKey()
: this(false, false, false, false, false, false, DnsKeyNameType.ZoneKey, DnsKeySignatory.Zone, DnsKeyProtocol.All, DnsAlgorithm.None, null, : this(false, false, false, false, false, false, DnsKeyNameType.ZoneKey, DnsKeySignatoryAttributes.Zone, DnsKeyProtocol.All, DnsAlgorithm.None, null,
DataSegment.Empty) DataSegment.Empty)
{ {
} }
...@@ -245,7 +247,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -245,7 +247,7 @@ namespace PcapDotNet.Packets.Dns
bool ipSec = data.ReadBool(Offset.IpSec, Mask.IpSec); bool ipSec = data.ReadBool(Offset.IpSec, Mask.IpSec);
bool email = data.ReadBool(Offset.Email, Mask.Email); bool email = data.ReadBool(Offset.Email, Mask.Email);
DnsKeyNameType nameType = (DnsKeyNameType)(data[Offset.NameType] & Mask.NameType); DnsKeyNameType nameType = (DnsKeyNameType)(data[Offset.NameType] & Mask.NameType);
DnsKeySignatory signatory = (DnsKeySignatory)(data[Offset.Signatory] & Mask.Signatory); DnsKeySignatoryAttributes signatory = (DnsKeySignatoryAttributes)(data[Offset.Signatory] & Mask.Signatory);
DnsKeyProtocol protocol = (DnsKeyProtocol)data[Offset.Protocol]; DnsKeyProtocol protocol = (DnsKeyProtocol)data[Offset.Protocol];
DnsAlgorithm algorithm = (DnsAlgorithm)data[Offset.Algorithm]; DnsAlgorithm algorithm = (DnsAlgorithm)data[Offset.Algorithm];
ushort? flagsExtension = (isFlagsExtension ? ((ushort?)data.ReadUShort(Offset.FlagsExtension, Endianity.Big)) : null); ushort? flagsExtension = (isFlagsExtension ? ((ushort?)data.ReadUShort(Offset.FlagsExtension, Endianity.Big)) : null);
......
...@@ -130,9 +130,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -130,9 +130,9 @@ namespace PcapDotNet.Packets.Dns
Altitude.Equals(other.Altitude); Altitude.Equals(other.Altitude);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataLocationInformation); return Equals(obj as DnsResourceDataLocationInformation);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -41,6 +41,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -41,6 +41,7 @@ namespace PcapDotNet.Packets.Dns
private const int ConstantPartLength = Offset.Flags; private const int ConstantPartLength = Offset.Flags;
private const int MinimumLength = ConstantPartLength + StringMinimumLength + StringMinimumLength + StringMinimumLength + DnsDomainName.RootLength; private const int MinimumLength = ConstantPartLength + StringMinimumLength + StringMinimumLength + StringMinimumLength + DnsDomainName.RootLength;
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "flags")]
public DnsResourceDataNamingAuthorityPointer(ushort order, ushort preference, DataSegment flags, DataSegment services, DataSegment regularExpression, DnsDomainName replacement) public DnsResourceDataNamingAuthorityPointer(ushort order, ushort preference, DataSegment flags, DataSegment services, DataSegment regularExpression, DnsDomainName replacement)
{ {
if (flags == null) if (flags == null)
...@@ -94,6 +95,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -94,6 +95,7 @@ namespace PcapDotNet.Packets.Dns
/// It is up to the Application specifying how it is using this Database to define the Flags in this field. /// It is up to the Application specifying how it is using this Database to define the Flags in this field.
/// It must define which ones are terminal and which ones are not. /// It must define which ones are terminal and which ones are not.
/// </summary> /// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags")]
public DataSegment Flags { get; private set; } public DataSegment Flags { get; private set; }
/// <summary> /// <summary>
...@@ -135,9 +137,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -135,9 +137,9 @@ namespace PcapDotNet.Packets.Dns
Replacement.Equals(other.Replacement); Replacement.Equals(other.Replacement);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataNamingAuthorityPointer); return Equals(obj as DnsResourceDataNamingAuthorityPointer);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -85,9 +85,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -85,9 +85,9 @@ namespace PcapDotNet.Packets.Dns
Selector.Equals(other.Selector); Selector.Equals(other.Selector);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataNetworkServiceAccessPoint); return Equals(obj as DnsResourceDataNetworkServiceAccessPoint);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -121,9 +121,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -121,9 +121,9 @@ namespace PcapDotNet.Packets.Dns
TypeBitmap.Equals(other.TypeBitmap); TypeBitmap.Equals(other.TypeBitmap);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataNextDomain); return Equals(obj as DnsResourceDataNextDomain);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -53,9 +53,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -53,9 +53,9 @@ namespace PcapDotNet.Packets.Dns
_typeBitmaps.Equals(other._typeBitmaps); _typeBitmaps.Equals(other._typeBitmaps);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataNextDomainSecure); return Equals(obj as DnsResourceDataNextDomainSecure);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -30,6 +30,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -30,6 +30,7 @@ namespace PcapDotNet.Packets.Dns
[DnsTypeRegistration(Type = DnsType.NSec3)] [DnsTypeRegistration(Type = DnsType.NSec3)]
public sealed class DnsResourceDataNextDomainSecure3 : DnsResourceDataNextDomainSecure3Base, IEquatable<DnsResourceDataNextDomainSecure3> public sealed class DnsResourceDataNextDomainSecure3 : DnsResourceDataNextDomainSecure3Base, IEquatable<DnsResourceDataNextDomainSecure3>
{ {
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "flags")]
public DnsResourceDataNextDomainSecure3(DnsSecNSec3HashAlgorithm hashAlgorithm, DnsSecNSec3Flags flags, ushort iterations, DataSegment salt, public DnsResourceDataNextDomainSecure3(DnsSecNSec3HashAlgorithm hashAlgorithm, DnsSecNSec3Flags flags, ushort iterations, DataSegment salt,
DataSegment nextHashedOwnerName, IEnumerable<DnsType> existTypes) DataSegment nextHashedOwnerName, IEnumerable<DnsType> existTypes)
: this(hashAlgorithm, flags, iterations, salt, nextHashedOwnerName, new DnsTypeBitmaps(existTypes)) : this(hashAlgorithm, flags, iterations, salt, nextHashedOwnerName, new DnsTypeBitmaps(existTypes))
...@@ -58,9 +59,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -58,9 +59,9 @@ namespace PcapDotNet.Packets.Dns
_typeBitmaps.Equals(other._typeBitmaps); _typeBitmaps.Equals(other._typeBitmaps);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataNextDomainSecure3); return Equals(obj as DnsResourceDataNextDomainSecure3);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -42,6 +42,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -42,6 +42,7 @@ namespace PcapDotNet.Packets.Dns
/// Can be used to indicate different processing. /// Can be used to indicate different processing.
/// All undefined flags must be zero. /// All undefined flags must be zero.
/// </summary> /// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags")]
public DnsSecNSec3Flags Flags { get; private set; } public DnsSecNSec3Flags Flags { get; private set; }
/// <summary> /// <summary>
......
...@@ -19,6 +19,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -19,6 +19,7 @@ namespace PcapDotNet.Packets.Dns
[DnsTypeRegistration(Type = DnsType.NSec3Parameters)] [DnsTypeRegistration(Type = DnsType.NSec3Parameters)]
public sealed class DnsResourceDataNextDomainSecure3Parameters : DnsResourceDataNextDomainSecure3Base, IEquatable<DnsResourceDataNextDomainSecure3Parameters> public sealed class DnsResourceDataNextDomainSecure3Parameters : DnsResourceDataNextDomainSecure3Base, IEquatable<DnsResourceDataNextDomainSecure3Parameters>
{ {
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "flags")]
public DnsResourceDataNextDomainSecure3Parameters(DnsSecNSec3HashAlgorithm hashAlgorithm, DnsSecNSec3Flags flags, ushort iterations, DataSegment salt) public DnsResourceDataNextDomainSecure3Parameters(DnsSecNSec3HashAlgorithm hashAlgorithm, DnsSecNSec3Flags flags, ushort iterations, DataSegment salt)
: base(hashAlgorithm, flags, iterations, salt) : base(hashAlgorithm, flags, iterations, salt)
{ {
...@@ -29,9 +30,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -29,9 +30,9 @@ namespace PcapDotNet.Packets.Dns
return EqualsParameters(other); return EqualsParameters(other);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataNextDomainSecure3Parameters); return Equals(obj as DnsResourceDataNextDomainSecure3Parameters);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -34,9 +34,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -34,9 +34,9 @@ namespace PcapDotNet.Packets.Dns
Options.Equals(other.Options); Options.Equals(other.Options);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataOptions); return Equals(obj as DnsResourceDataOptions);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -29,6 +29,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -29,6 +29,7 @@ namespace PcapDotNet.Packets.Dns
private const int ConstantPartLength = Offset.PublicKey; private const int ConstantPartLength = Offset.PublicKey;
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "flags")]
public DnsResourceDataRKey(ushort flags, byte protocol, DnsAlgorithm algorithm, DataSegment publicKey) public DnsResourceDataRKey(ushort flags, byte protocol, DnsAlgorithm algorithm, DataSegment publicKey)
{ {
Flags = flags; Flags = flags;
...@@ -40,6 +41,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -40,6 +41,7 @@ namespace PcapDotNet.Packets.Dns
/// <summary> /// <summary>
/// Reserved and must be zero. /// Reserved and must be zero.
/// </summary> /// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags")]
public ushort Flags { get; private set; } public ushort Flags { get; private set; }
/// <summary> /// <summary>
...@@ -66,9 +68,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -66,9 +68,9 @@ namespace PcapDotNet.Packets.Dns
PublicKey.Equals(other.PublicKey); PublicKey.Equals(other.PublicKey);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataRKey); return Equals(obj as DnsResourceDataRKey);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -98,9 +98,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -98,9 +98,9 @@ namespace PcapDotNet.Packets.Dns
return Sequence.GetHashCode(BitSequence.Merge(Priority, Weight), Port, Target); return Sequence.GetHashCode(BitSequence.Merge(Priority, Weight), Port, Target);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataServerSelection); return Equals(obj as DnsResourceDataServerSelection);
} }
internal DnsResourceDataServerSelection() internal DnsResourceDataServerSelection()
......
...@@ -159,9 +159,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -159,9 +159,9 @@ namespace PcapDotNet.Packets.Dns
KeyTag, SignersName, Signature); KeyTag, SignersName, Signature);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataSignature); return Equals(obj as DnsResourceDataSignature);
} }
internal DnsResourceDataSignature() internal DnsResourceDataSignature()
......
...@@ -76,9 +76,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -76,9 +76,9 @@ namespace PcapDotNet.Packets.Dns
Data.Equals(other.Data); Data.Equals(other.Data);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataSink); return Equals(obj as DnsResourceDataSink);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -59,9 +59,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -59,9 +59,9 @@ namespace PcapDotNet.Packets.Dns
Fingerprint.Equals(other.Fingerprint); Fingerprint.Equals(other.Fingerprint);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataSshFingerprint); return Equals(obj as DnsResourceDataSshFingerprint);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -107,9 +107,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -107,9 +107,9 @@ namespace PcapDotNet.Packets.Dns
return Sequence.GetHashCode(MainNameServer, ResponsibleMailbox, Serial, Refresh, Retry, Expire, MinimumTtl); return Sequence.GetHashCode(MainNameServer, ResponsibleMailbox, Serial, Refresh, Retry, Expire, MinimumTtl);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataStartOfAuthority); return Equals(obj as DnsResourceDataStartOfAuthority);
} }
internal DnsResourceDataStartOfAuthority() internal DnsResourceDataStartOfAuthority()
......
...@@ -23,9 +23,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -23,9 +23,9 @@ namespace PcapDotNet.Packets.Dns
String.Equals(other.String); String.Equals(other.String);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataString); return Equals(obj as DnsResourceDataString);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -20,9 +20,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -20,9 +20,9 @@ namespace PcapDotNet.Packets.Dns
Strings.SequenceEqual(other.Strings); Strings.SequenceEqual(other.Strings);
} }
public sealed override bool Equals(object other) public sealed override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataStrings); return Equals(obj as DnsResourceDataStrings);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -135,9 +135,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -135,9 +135,9 @@ namespace PcapDotNet.Packets.Dns
Other.Equals(other.Other); Other.Equals(other.Other);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataTransactionKey); return Equals(obj as DnsResourceDataTransactionKey);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -118,9 +118,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -118,9 +118,9 @@ namespace PcapDotNet.Packets.Dns
Other.Equals(other.Other); Other.Equals(other.Other);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataTransactionSignature); return Equals(obj as DnsResourceDataTransactionSignature);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -41,9 +41,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -41,9 +41,9 @@ namespace PcapDotNet.Packets.Dns
Next.Equals(other.Next); Next.Equals(other.Next);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataTrustAnchorLink); return Equals(obj as DnsResourceDataTrustAnchorLink);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -34,9 +34,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -34,9 +34,9 @@ namespace PcapDotNet.Packets.Dns
DomainName.Equals(other.DomainName); DomainName.Equals(other.DomainName);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataUShortDomainName); return Equals(obj as DnsResourceDataUShortDomainName);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -66,9 +66,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -66,9 +66,9 @@ namespace PcapDotNet.Packets.Dns
Target.SequenceEqual(other.Target); Target.SequenceEqual(other.Target);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataUri); return Equals(obj as DnsResourceDataUri);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -58,9 +58,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -58,9 +58,9 @@ namespace PcapDotNet.Packets.Dns
Bitmap.Equals(other.Bitmap); Bitmap.Equals(other.Bitmap);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataWellKnownService); return Equals(obj as DnsResourceDataWellKnownService);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -62,9 +62,9 @@ namespace PcapDotNet.Packets.Dns ...@@ -62,9 +62,9 @@ namespace PcapDotNet.Packets.Dns
MapX400.Equals(other.MapX400); MapX400.Equals(other.MapX400);
} }
public override bool Equals(object other) public override bool Equals(object obj)
{ {
return Equals(other as DnsResourceDataX400Pointer); return Equals(obj as DnsResourceDataX400Pointer);
} }
public override int GetHashCode() public override int GetHashCode()
......
...@@ -5,7 +5,7 @@ namespace PcapDotNet.Packets.Dns ...@@ -5,7 +5,7 @@ namespace PcapDotNet.Packets.Dns
/// <summary> /// <summary>
/// RFC 5155. /// RFC 5155.
/// </summary> /// </summary>
[Flags] [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1726:UsePreferredTerms", MessageId = "Flags"), Flags]
public enum DnsSecNSec3Flags : byte public enum DnsSecNSec3Flags : byte
{ {
None = 0x00, None = 0x00,
......
...@@ -123,7 +123,7 @@ ...@@ -123,7 +123,7 @@
<Compile Include="Dns\ResourceData\DnsGatewayType.cs" /> <Compile Include="Dns\ResourceData\DnsGatewayType.cs" />
<Compile Include="Dns\ResourceData\DnsKeyNameType.cs" /> <Compile Include="Dns\ResourceData\DnsKeyNameType.cs" />
<Compile Include="Dns\ResourceData\DnsKeyProtocol.cs" /> <Compile Include="Dns\ResourceData\DnsKeyProtocol.cs" />
<Compile Include="Dns\ResourceData\DnsKeySignatory.cs" /> <Compile Include="Dns\ResourceData\DnsKeySignatoryAttributes.cs" />
<Compile Include="Dns\ResourceData\DnsLongLivedQueryErrorCode.cs" /> <Compile Include="Dns\ResourceData\DnsLongLivedQueryErrorCode.cs" />
<Compile Include="Dns\ResourceData\DnsLongLivedQueryOpcode.cs" /> <Compile Include="Dns\ResourceData\DnsLongLivedQueryOpcode.cs" />
<Compile Include="Dns\ResourceData\DnsOption.cs" /> <Compile Include="Dns\ResourceData\DnsOption.cs" />
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment