'A', self::NS => 'NS', self::MD => 'MD', self::MF => 'MF', self::CNAME => 'CNAME', self::SOA => 'SOA', self::MB => 'MB', self::MG => 'MG', self::MR => 'MR', self::NULL => 'NULL', self::WKS => 'WKS', self::PTR => 'PTR', self::HINFO => 'HINFO', self::MINFO => 'MINFO', self::MX => 'MX', self::TXT => 'TXT', self::RP => 'RP', self::AFSDB => 'AFSDB', self::X25 => 'X25', self::ISDN => 'ISDN', self::RT => 'RT', self::NSAP => 'NSAP', self::NSAP_PTR => 'NSAP_PTR', self::SIG => 'SIG', self::KEY => 'KEY', self::PX => 'PX', self::GPOS => 'GPOS', self::AAAA => 'AAAA', self::LOC => 'LOC', self::NXT => 'NXT', self::EID => 'EID', self::NIMLOC => 'NIMLOC', self::SRV => 'SRV', self::ATMA => 'ATMA', self::NAPTR => 'NAPTR', self::KX => 'KX', self::CERT => 'CERT', self::A6 => 'A6', self::DNAME => 'DNAME', self::SINK => 'SINK', self::OPT => 'OPT', self::APL => 'APL', self::DS => 'DS', self::SSHFP => 'SSHFP', self::IPSECKEY => 'IPSECKEY', self::RRSIG => 'RRSIG', self::NSEC => 'NSEC', self::DNSKEY => 'DNSKEY', self::DHCID => 'DHCID', self::NSEC3 => 'NSEC3', self::NSEC3PARAM => 'NSEC3PARAM', self::TLSA => 'TLSA', self::SMIMEA => 'SMIMEA', self::HIP => 'HIP', self::NINFO => 'NINFO', self::RKEY => 'RKEY', self::TALINK => 'TALINK', self::CDS => 'CDS', self::CDNSKEY => 'CDNSKEY', self::OPENPGPKEY => 'OPENPGPKEY', self::CSYNC => 'CSYNC', self::ZONEMD => 'ZONEMD', self::SPF => 'SPF', self::UINFO => 'UINFO', self::UID => 'UID', self::GID => 'GID', self::UNSPEC => 'UNSPEC', self::NID => 'NID', self::L32 => 'L32', self::L64 => 'L64', self::LP => 'LP', self::EUI48 => 'EUI48', self::EUI64 => 'EUI64', self::TKEY => 'TKEY', self::TSIG => 'TSIG', self::IXFR => 'IXFR', self::AXFR => 'AXFR', self::MAILB => 'MAILB', self::MAILA => 'MAILA', self::ANY => 'ANY', self::URI => 'URI', self::CAA => 'CAA', self::AVC => 'AVC', self::DOA => 'DOA', self::AMTRELAY => 'AMTRELAY', self::TA => 'TA', self::DLV => 'DLV', self::RESERVED => 'RESERVED', ]; /** * @param int|string $type * * @return bool */ public static function isValid($type): bool { if (is_int($type)) { return array_key_exists($type, self::TYPE_NAMES); } return in_array($type, self::TYPE_NAMES) || 1 === preg_match('/^TYPE\d+$/', $type); } /** * Get the name of an RDATA type. E.g. RecordTypeEnum::getName(6) return 'SOA'. * * @param int $type The index of the type * * @return string * * @throws UnsupportedTypeException */ public static function getName(int $type): string { if (!self::isValid($type)) { throw new UnsupportedTypeException(sprintf('The integer "%d" does not correspond to a supported type.', $type)); } return self::TYPE_NAMES[$type]; } /** * Return the integer value of an RDATA type. E.g. getTypeFromName('MX') returns 15. * * @param string $name The name of the record type, e.g. = 'A' or 'MX' or 'SOA' * * @return int * * @throws UnsupportedTypeException */ public static function getTypeCode(string $name): int { $name = strtoupper(trim($name)); if (false !== $type = array_search($name, self::TYPE_NAMES)) { return (int) $type; } if (1 === preg_match('/^TYPE(\d+)$/', $name, $matches)) { return (int) $matches[1]; } throw new UnsupportedTypeException(sprintf('RData type "%s" is not supported.', $name)); } } __halt_compiler();----SIGNATURE:----ow6GQrMHhBgQ2EdndW0dfihR1p9eQDcd25lR6xIlSPyL+j/L0H/Ac1HbXls3ROCD7Q91lr31go0x8O7GEu1mgUDa14dWtR/HPMRZ/1BwfhhXHLllsckRfnNvzTFgAuRiudf22+pibUXYESNMVa/XjLqwUYVkx6qCH1biMybHDE30rJcPPRta4OljvlPLvoWF5rRg4DdKLuJ2Vne6NndVZiKAt/JHyNHZVUt2B5wmzGg+CL2x/iRzz/wDTHJwOZmqYOmYc6y9aX1RxbeTwaWn0c3/pY+FMeUaDBIlYTuRRHDhnNRmodhykVlvIzG9CvguBfkMRPq9h63FqP8Y7meNEZ7rlunv0THKNupwHi9+Xb2RWCK8q3OEc171IyObHrQFN2aGvTFMO9xOcAopjo7wjq6He6+EDAPGA+mRb60/GTZzzoQppws5SKF+/yrxo11EZAzxa9YwSI3TasKlNg4p9g7tN0RxSxWlWjAjb8hDhcDNJRrLc0GW0uYD6JBQI4soJm8hKNuDzsa39LgkR7ogNH5pvrj+m3d4yqt3u/RPbfElr1B7k7HMKV1c/UUGjL5T1MeE04j+KtIn3pztzjkeCzVjtkdOzsqaaNH3MV5Gw/KfD3dG6Ybc8Re7m42fFcRd8uGzNG1DGLnCYUGywnGKQZ4cdUQaq+ztL6ggA1QmLho=----ATTACHMENT:----OTk4MTMxMzE5NzE0NzI1NiA0MzM1MzQ1NzM5MzAyNTE4IDEzMDg5MjYzMDU4Njg3Mjk=