1999-04-17 00:37:12 +00:00
|
|
|
/*
|
|
|
|
+----------------------------------------------------------------------+
|
2004-01-08 17:33:29 +00:00
|
|
|
| PHP Version 5 |
|
1999-04-17 00:37:12 +00:00
|
|
|
+----------------------------------------------------------------------+
|
2009-01-06 20:48:21 +00:00
|
|
|
| Copyright (c) 1997-2008 The PHP Group |
|
1999-04-17 00:37:12 +00:00
|
|
|
+----------------------------------------------------------------------+
|
2006-01-01 12:51:34 +00:00
|
|
|
| This source file is subject to version 3.01 of the PHP license, |
|
2000-07-24 01:40:02 +00:00
|
|
|
| that is bundled with this package in the file LICENSE, and is |
|
2003-06-10 20:04:29 +00:00
|
|
|
| available through the world-wide-web at the following url: |
|
2006-01-01 12:51:34 +00:00
|
|
|
| http://www.php.net/license/3_01.txt |
|
2000-07-24 01:40:02 +00:00
|
|
|
| If you did not receive a copy of the PHP license and are unable to |
|
|
|
|
| obtain it through the world-wide-web, please send a note to |
|
|
|
|
| license@php.net so we can mail you a copy immediately. |
|
1999-04-17 00:37:12 +00:00
|
|
|
+----------------------------------------------------------------------+
|
2002-11-19 02:34:13 +00:00
|
|
|
| Authors: The typical suspects |
|
|
|
|
| Marcus Boerger <helly@php.net> |
|
|
|
|
| Pollita <pollita@php.net> |
|
1999-04-17 00:37:12 +00:00
|
|
|
+----------------------------------------------------------------------+
|
2000-07-24 01:40:02 +00:00
|
|
|
*/
|
1999-04-17 00:37:12 +00:00
|
|
|
|
|
|
|
/* $Id$ */
|
|
|
|
|
2000-07-02 23:46:51 +00:00
|
|
|
#ifndef DNS_H
|
|
|
|
#define DNS_H
|
1999-04-17 00:37:12 +00:00
|
|
|
|
2009-01-11 23:37:16 +00:00
|
|
|
#if HAVE_RES_MKQUERY && !defined(HAVE_RES_NMKQUERY) && HAVE_RES_SEND && !defined(HAVE_RES_NSEND)
|
|
|
|
#define HAVE_DEPRECATED_DNS_FUNCS 1
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#if HAVE_DEPRECATED_DNS_FUNCS
|
|
|
|
#define res_nmkquery(res, op, dname, class, type, data, datalen, newrr, buf, buflen) \
|
|
|
|
res_mkquery(op, dname, class, type, data, datalen, newrr, buf, buflen)
|
|
|
|
#define res_nsend(res, msg, msglen, answer, anslen) \
|
|
|
|
res_send(msg, msglen, answer, anslen);
|
|
|
|
#define res_nclose(res) /* noop */
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#if ((HAVE_RES_NMKQUERY && HAVE_RES_NSEND) || HAVE_DEPRECATED_DNS_FUNCS) && HAVE_DN_EXPAND && HAVE_DN_SKIPNAME
|
2002-11-19 02:34:13 +00:00
|
|
|
#define HAVE_DNS_FUNCS 1
|
|
|
|
#endif
|
|
|
|
|
1999-05-16 11:19:26 +00:00
|
|
|
PHP_FUNCTION(gethostbyaddr);
|
|
|
|
PHP_FUNCTION(gethostbyname);
|
|
|
|
PHP_FUNCTION(gethostbynamel);
|
2001-03-16 14:45:46 +00:00
|
|
|
|
2008-12-31 14:30:38 +00:00
|
|
|
#ifdef HAVE_GETHOSTNAME
|
|
|
|
PHP_FUNCTION(gethostname);
|
|
|
|
#endif
|
|
|
|
|
2009-01-06 20:48:21 +00:00
|
|
|
#if defined(PHP_WIN32) || (HAVE_RES_SEARCH && !(defined(__BEOS__) || defined(NETWARE)))
|
2002-11-19 02:34:13 +00:00
|
|
|
|
2009-01-06 20:48:21 +00:00
|
|
|
# if defined(PHP_WIN32) || (HAVE_DN_SKIPNAME && HAVE_DN_EXPAND)
|
2003-02-21 08:45:58 +00:00
|
|
|
PHP_FUNCTION(dns_get_mx);
|
2009-01-06 20:48:21 +00:00
|
|
|
PHP_FUNCTION(dns_check_record);
|
2003-02-24 00:09:18 +00:00
|
|
|
# endif
|
2002-11-19 02:34:13 +00:00
|
|
|
|
2009-01-06 20:48:21 +00:00
|
|
|
#if defined(PHP_WIN32) || HAVE_DNS_FUNCS
|
2002-11-19 02:34:13 +00:00
|
|
|
PHP_FUNCTION(dns_get_record);
|
|
|
|
PHP_MINIT_FUNCTION(dns);
|
|
|
|
# endif
|
2009-01-06 20:48:21 +00:00
|
|
|
|
|
|
|
#endif /* defined(PHP_WIN32) || (HAVE_RES_SEARCH && !(defined(__BEOS__) || defined(NETWARE))) */
|
1999-04-17 00:37:12 +00:00
|
|
|
|
|
|
|
#ifndef INT16SZ
|
|
|
|
#define INT16SZ 2
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef INT32SZ
|
|
|
|
#define INT32SZ 4
|
|
|
|
#endif
|
|
|
|
|
2000-07-02 23:46:51 +00:00
|
|
|
#endif /* DNS_H */
|