翻译NetBIOS域名成FQDN(完全合格域名)域名、合格、NetBIOS、FQDN

2023-09-08 12:37:51 作者:假裝狠快樂

在短期 - ?我该如何翻译NetBIOS域名为FQDN

In short - How do I translate a NETBIOS domain to a FQDN ?

详细信息: 假设我在域A和我有域B具有与域A的信任关系的用户凭据(我可以验证凭据)。 如何获得域B的FQDN当所有我已经从该域的一些身份验证的用户的凭据,包括NetBIOS域名?

Details: Assuming I'm in domain A and I have user credentials for domain B which has a trust relationship with domain A (I can authenticate the credentials). How do I get domain B's FQDN when all I have are the credentials of some authenticated user from that domain, including the netbios domain name?

我编码在C#中,但一个COM / WMI / Win32的解决方案将受到欢迎也是如此。

I'm coding in C# but a COM/WMI/Win32 solution would be welcomed as well.

推荐答案

这可能不是最优的,但它看起来像你可以做一个NetBIOS名称查询,以获得一个IP地址,然后做一个反向DNS查找来获得从...的FQDN

This probably isn't optimal, but it look like you could do a NetBIOS name query to get an IP address, and then do a reverse DNS lookup to get an FQDN from that...

http://www.protocolbase.net/protocols/protocol_NBNS.php

(反向DNS步骤是容易查找)

(The reverse DNS step is easy to look up)