Nager.PublicSuffix 3.1.0

The ID prefix of this package has been reserved for one of the owners of this package by NuGet.org. Prefix Reserved
dotnet add package Nager.PublicSuffix --version 3.1.0
NuGet\Install-Package Nager.PublicSuffix -Version 3.1.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Nager.PublicSuffix" Version="3.1.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Nager.PublicSuffix --version 3.1.0
#r "nuget: Nager.PublicSuffix, 3.1.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Nager.PublicSuffix as a Cake Addin
#addin nuget:?package=Nager.PublicSuffix&version=3.1.0

// Install Nager.PublicSuffix as a Cake Tool
#tool nuget:?package=Nager.PublicSuffix&version=3.1.0

Nager.PublicSuffix (PSL)

With so many different endings for domain names, it's hard to know if they're valid or not. This project uses a list from publicsuffix.org, which keeps track of all the common endings like .com or .org. It checks domain names against this list to see if they're okay. Then, it splits the domain into three parts: the ending (like .com), the main part (like google), and any subparts (like www). You can find the list on GitHub under publicsuffix list repository.

Use cases

  • Cookie restriction for browsers
  • Domain highlighting in the URL bar of browsers
  • DMARC E-Mail Security
  • Certificate requests (ACME)
  • Determining Valid Wildcard Certificates
  • Two-factor authentication (FIDO)

Code Examples

Analyze domain

var ruleProvider = new LocalFileRuleProvider("public_suffix_list.dat");
await ruleProvider.BuildAsync();

var domainParser = new DomainParser(ruleProvider);

var domainInfo = domainParser.Parse("sub.test.co.uk");
//domainInfo.Domain = "test";
//domainInfo.FullyQualifiedDomainName = "sub.test.co.uk";
//domainInfo.RegistrableDomain = "test.co.uk";
//domainInfo.Subdomain = "sub";
//domainInfo.TopLevelDomain = "co.uk";
Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.1 is compatible. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (8)

Showing the top 5 NuGet packages that depend on Nager.PublicSuffix:

Package Downloads
SharpPulsar

SharpPulsar is Apache Pulsar Client built using Akka.net

Newguys.Sport

Package Description

AnimeDl

AnimeDl scrapes animes from sites for streaming or downloading.

Rsk.AspNetCore.Fido The ID prefix of this package has been reserved for one of the owners of this package by NuGet.org.

Allows your ASP.NET Core .NET 6.0 or .NET 8.0 website to act as a FIDO2 Relying Party. Certified by the FIDO Alliance. To purchase a license or get a demo license, contact sales@identityserver.com.

DR.Networking

A small networking library to make get & post requests

GitHub repositories (3)

Showing the top 3 popular GitHub repositories that depend on Nager.PublicSuffix:

Repository Stars
win-acme/win-acme
A simple ACME client for Windows (for use with Let's Encrypt et al.)
Flangvik/TeamFiltration
TeamFiltration is a cross-platform framework for enumerating, spraying, exfiltrating, and backdooring O365 AAD accounts
Stratus-Security/Subdominator
The Internets #1 Subdomain Takeover Tool
Version Downloads Last updated
3.1.0 1,657 3/24/2024
3.0.1 3,368 2/20/2024
3.0.0 619 2/15/2024
2.4.0 827,757 5/31/2022
2.3.0 213,397 2/18/2022
2.2.2 540,004 2/9/2021
2.0.3 64,757 12/30/2020
1.5.1 464,990 2/10/2020
1.5.0 73,856 10/1/2019
1.3.1 70,895 6/28/2019
1.3.0 112,837 11/1/2018
1.2.2 45,485 6/30/2018
1.2.0 11,598 3/12/2018
1.1.1 1,959 3/7/2018
1.1.0 11,986 9/27/2017
1.0.4 32,531 6/17/2017
1.0.3 3,049 3/12/2017
1.0.2 2,815 12/2/2016
1.0.0 3,469 10/27/2016