libtld 是一个用来从 URI 中抽取 TLD(顶级域名) 信息的 C 库。你可以提取域名、子域名等信息
libtld 1.2.0 改进内容:
- Added support for exceptions so we now properly support .uk for domains such as nic.uk, but forbid it for all the sites that are not exceptions.
- Updated the tests accordingly.
- Added a test for the XML file to make sure it respects the DTD.
- Fixed the offsets of the data table, since these are unsigned short, -1 is not the best value to use to represent an invalid value. Instead we use USHRT_MAX now.
- Completed the .us entries.
libtld下载地址请点这里
