[Plugin] DNS Plugin
#1

DNS Plugin

This plugin provides functionality for DNS lookups and reverse DNS lookups.

Natives
  • dns(const host[], extra = 0);
    • Resolves the hostname to an IP address

  • rdns(const ip[], extra = 0);
    • Resolves the IP address to a hostname
Note that extra is an optional argument that can pass an integer, such as a player ID, to the callbacks.

Callbacks
  • OnDNS(host[], ip[], extra);
    • Called upon DNS lookup

  • OnReverseDNS(ip[], host[], extra);
    • Called upon reverse DNS lookup
Stock Function
  • GetPlayerHost(playerid);
    • Wrapper for rdns that can obtain a player's hostname
Instructions

Create a directory called "plugins" inside of the server directory if one does not already exist. Place the plugin file (dns.dll or dns.so) inside of this directory.

Add the following line to server.cfg so that the plugin will load the next time the server starts:

Windows:
Код:
plugins dns.dll
Linux:
Код:
plugins dns.so
On Windows, add dns.inc to the pawno\include folder. Include this file in any of the scripts the server is running:

pawn Код:
#include <dns>
Recompile the scripts with any desired natives and callbacks provided by the include file. Start the server.

Download

The latest compiled binaries will always be here:

GitHub Releases Page

The source can be browsed here. This repository can also be cloned.

The Windows version requires the Microsoft Visual C++ 2010 Redistributable Package.
Reply


Messages In This Thread
DNS Plugin - by Incognito - 03.05.2009, 06:46
Re: [REL] DNS Plugin - by shitbird - 03.05.2009, 08:39
Re: [REL] DNS Plugin - by Incognito - 03.05.2009, 09:42
Re: [REL] DNS Plugin - by boylett - 03.05.2009, 09:45
Re: [REL] DNS Plugin - by Joske_Vermeulen - 03.05.2009, 10:35
Re: [REL] DNS Plugin - by kasco - 03.05.2009, 10:39
Re: [REL] DNS Plugin - by Incognito - 03.05.2009, 11:47
Re: [REL] DNS Plugin - by Kalcor - 03.05.2009, 12:30
Re: [REL] DNS Plugin - by pspleo - 03.05.2009, 13:15
Re: [REL] DNS Plugin - by Incognito - 04.05.2009, 04:28
Re: [REL] DNS Plugin - by [LF]Sagat - 13.05.2009, 08:14
Re: [REL] DNS Plugin - by Slice - 13.05.2009, 10:11
Re: [REL] DNS Plugin v2 - by Incognito - 17.05.2009, 03:41
Re: [REL] DNS Plugin - by Joske_Vermeulen - 17.05.2009, 09:25
Re: [REL] DNS Plugin v2 - by Incognito - 17.05.2009, 10:00
Re: [REL] DNS Plugin v2 - by Slice - 17.05.2009, 11:16
Re: [REL] DNS Plugin v2 - by Joske_Vermeulen - 20.05.2009, 10:56
Re: [REL] DNS Plugin v2 - by Incognito - 20.05.2009, 21:49
Re: [REL] DNS Plugin v2 - by Joske_Vermeulen - 21.05.2009, 08:08
Re: [REL] DNS Plugin v2 - by Incognito - 21.05.2009, 17:47
Re: [REL] DNS Plugin v2 - by Joske_Vermeulen - 21.05.2009, 19:50
Re: [REL] DNS Plugin v2 - by Joske_Vermeulen - 22.05.2009, 16:28
Re: [REL] DNS Plugin v2 - by watkijkje - 25.05.2009, 14:32
Re: [REL] DNS Plugin v2 - by Joske_Vermeulen - 25.05.2009, 16:26
Re: [REL] DNS Plugin v2 - by Incognito - 27.05.2009, 22:49
Re: [REL] DNS Plugin - by SMX - 29.05.2009, 21:23
Re: [REL] DNS Plugin v2.1 - by Incognito - 02.06.2009, 06:44
Re: [REL] DNS Plugin v2.1 - by hansen111 - 02.06.2009, 11:57
Re: [REL] DNS Plugin v2.1 - by Littl3j0hNy - 02.06.2009, 14:24
Respuesta: [REL] DNS Plugin v2.4 - by DarkChildren - 09.08.2010, 16:27
Re: [REL] DNS Plugin v2.4 - by BP13 - 09.08.2010, 16:57
Re: [REL] DNS Plugin v2.4 - by nemesis- - 15.08.2010, 04:55
Re: [REL] DNS Plugin v2.4 - by TheInnocentOne - 09.09.2010, 09:17
Re: [REL] DNS Plugin v2.4 - by nemesis- - 09.09.2010, 17:29
Re: [REL] DNS Plugin v2.4 - by sarahlatigresse - 04.01.2011, 19:44
Re: [REL] DNS Plugin v2.4 - by Sunday_Driver - 11.08.2011, 10:21
Re: [REL] DNS Plugin v2.4 - by EviLpRo - 11.08.2011, 11:30
Respuesta: [REL] DNS Plugin v2.4 - by RcoN! - 02.09.2011, 19:49
Re: [REL] DNS Plugin v2.4 - by GangsTa_ - 03.09.2011, 09:35
Re: [REL] DNS Plugin - by leong124 - 18.10.2011, 08:38
Respuesta: [REL] DNS Plugin v2.4 - by [Nikk] - 03.01.2012, 04:26
Re: [REL] DNS Plugin v2.4 - by Rambo_John - 19.03.2012, 15:18
Re: [REL] DNS Plugin v2.4 - by MadSkillz - 07.08.2012, 08:57
Re: [REL] DNS Plugin v2.4 - by Mishima - 08.08.2012, 12:34
AW: [REL] DNS Plugin v2.4 - by BiosMarcel - 05.09.2012, 13:55
Re: [REL] DNS Plugin v2.4 - by JaKe Elite - 03.11.2012, 06:27
Re: [REL] DNS Plugin v2.4 - by KingHual - 03.11.2012, 11:45
Re: [REL] DNS Plugin v2.4 - by JaKe Elite - 03.11.2012, 11:49
AW: Re: [REL] DNS Plugin v2.4 - by Johndaonee - 03.11.2012, 12:07
Respuesta: [REL] DNS Plugin v2.4 - by 50jaker - 21.03.2013, 15:32
Re: DNS Plugin - by exclide1 - 14.08.2013, 13:32
Re: DNS Plugin - by Vin Diesel - 28.01.2017, 16:54

Forum Jump:


Users browsing this thread: 1 Guest(s)