1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-21 15:09:02 +00:00
Commit Graph

46 Commits

Author SHA1 Message Date
david
2f2e826487 Remove OpenSSL directory, moved to /nmap-mswin32-aux. 2012-10-02 00:53:12 +00:00
david
7e5c9a8914 Regen with Autoconf 2.68 and aclocal 1.11.6.
for DIR in . nbase ncat nsock/src nping;
	do (echo $DIR; cd $DIR && aclocal --force && autoconf --force);
done
2012-09-19 16:41:35 +00:00
david
ddc37e6e39 AM_CONFIG_HEADER → AC_CONFIG_HEADER(config.h).
aclocal.m4 said that AM_CONFIG_HEADER was obsolete; with
AC_CONFIG_HEADER aclocal.m4 is not even needed.
2012-09-19 16:41:27 +00:00
david
0bf004cf6b Move acinclude.m4 inclusion from aclocal.m4 to configure.ac.
aclocal.m4 is autogenerated, so running aclocal would remove the
m4_include of acinclude.m4.

The exceptions are at the top of the source tree and in nsock/src, where
an acinclude.m4 lives; aclocal notices it there and automatically adds
an inclusion to the end of aclocal.m4, so no inclusion is needed in
configure.ac.
2012-09-19 16:41:25 +00:00
fyodor
57973b0c60 Added a new legal notices section to the Ncat man page which is basically the same as that section in the Nmap man page (in fact it links to that section to avoid copy and pasting a bunch of text. As part of this, I had to make an enclosure file (ncatmanhtml.xml) for the ncat.xml. Otherwise I can't use things like –. And this is consistent with how we deal with the nping man page, though I'm fine with getting rid of the enclosure in both cases if there is a good way to do so 2012-09-18 08:58:41 +00:00
david
d319f8bf56 Uniformity and style in resolve functions. 2012-09-15 17:56:16 +00:00
david
40eb708922 Show gai_strerror in some error messages. 2012-09-15 17:56:14 +00:00
david
113e0b975f Break out resolve and resolve_numeric.
Besides the confusingness of the nodns argument being negatively
phrased, it had the value 0 in every existing call. Split out the nodns
special case into a separate function resolve_numeric.

This also has the side effect of changing the number of parameters to
the resolve function, which will cause a compile error for any calls I
might have missed changing when I changed the return code meaning in the
previous commit.

Ncat has its own copy of resolve, which obeys the global o.nodns rather
than a parameter. I'm leaving that alone for now. But give it the same
resolve_internal function, and make resolve call it with different flags
depending on the value of o.nodns.
2012-09-15 17:56:11 +00:00
david
0e738370ee Make resolve return a getaddrinfo error code.
The only error we can have apart from a getaddrinfo error is a list of
zero addresses; return EAI_NONAME in that case.

This unfortunately inverts the truth value of the return code of
resolve; 0 now means success.
2012-09-15 17:56:08 +00:00
david
739aca56d4 Whitespace. 2012-09-12 04:54:19 +00:00
henri
7dc93e0935 Close connection endpoint when receiving EOF on stdin. Patch by Michal Hlavinka. 2012-09-10 20:41:46 +00:00
david
cb68c85409 Don't use exit in PCAP_IS_SUITABLE.
John Spencer reported that musl libc doesn't automatically include
<stdlib.h>, as Glibc does, so the configure check was wrongly failing.

conftest.c: In function 'main':
conftest.c:35:5: error: implicit declaration of function 'exit'
2012-09-08 19:44:24 +00:00
david
3ae9ba63be Make sockets temporarily blocking in ncat_send and ncat_broadcast.
It is possible to send so quickly that we start getting EAGAIN on sends.
In listen mode, this means that some sends can get lost. This patch,
adapted from one by Alex Weber, makes sockets blocking for the duration
of the send. This is not as nice as retrying the send through an event
mechanism, but should at least be correct.

http://seclists.org/nmap-dev/2012/q3/670

Compare a similar patch in r13552, which applied to --exec mode.
2012-09-06 18:17:27 +00:00
david
39f2e06d42 Return size, not 0, in ncat_broadcast when o.recvonly is true.
This is what ncat_send does.
2012-09-06 18:17:21 +00:00
david
3931741c1d Fix format string errors in Ncat logging functions. 2012-08-28 14:30:08 +00:00
david
13c19f637e Add noreturn and format annotations for Ncat logging functions. 2012-08-28 14:29:49 +00:00
david
f9867163da Use bye in place of fatal. 2012-08-28 14:29:37 +00:00
henri
af2f0960ab Automatically enforce the use of the nsock select engine if we detect that stdin
is a regular file.

Under linux, that provides epoll(7), this allows proper behavior when
redirecting a regular file to stdin (e.g.: 'ncat localhost < file.txt').

Bug was reported by Michal Hlavinka. See
http://seclists.org/nmap-dev/2012/q3/490 for more details.
2012-08-18 16:25:50 +00:00
henri
f66e0fcfb9 Ensure that inheritable_socket() returned a valid FD before passing it to Setsockopt(). 2012-07-12 17:17:46 +00:00
david
7f5d53184c Uniform handling of makefile.dep in makefiles.
"make clean" keeps makefile.dep and "make distclean" deletes it. This
patch is by Michael McTiernan.

http://seclists.org/nmap-dev/2012/q2/827
2012-06-19 14:06:49 +00:00
david
f7d8aa212f Remove Recvfrom wrapper. 2012-06-19 02:53:01 +00:00
david
c5b818fdce Remove Recv wrapper. 2012-06-19 02:53:00 +00:00
david
04e0503135 recv and send error checking in ncat_listen_dgram. 2012-06-19 02:52:58 +00:00
david
a9a621f5bd Make ncat --output logging work in UDP mode. 2012-06-19 02:52:57 +00:00
david
9e553a2203 Add test for --output logging.
Fails for UDP, as reported at http://seclists.org/nmap-dev/2012/q2/805.
2012-06-19 02:52:56 +00:00
sean
957c035603 Added a patch to correct the warning
"test/test-wildcard.c: In function ‘test’:
test/test-wildcard.c:159:5: warning: value computed is not used [-Wunused-value]
I simpily voided the BIO_destroy_bio_pair return value which was a long wrapped value from OPENSSL.
2012-06-19 02:13:08 +00:00
david
607b209fd4 Whitespace.
indent -kr -i4 -nut -l0 -ss -T size_t *.c
with manual adjustments.
2012-06-19 00:21:27 +00:00
fyodor
b70e4f71cf Bump the Nmap version number in SVN up to 6.02 2012-06-16 19:44:58 +00:00
fyodor
528c87ddb3 Latest builds of man pages 2012-05-30 21:56:09 +00:00
fyodor
22c7faa94b move the svn version number up to 6.01 and rebuild 2012-05-22 09:51:42 +00:00
david
ed35bfcfc9 Add an #ifdef guard around the use of IPV6_V6ONLY.
This definition is missing on Solaris 9. This was initially reported by
Dagobert Michelsen.
http://seclists.org/nmap-dev/2011/q4/15
2012-04-10 03:19:39 +00:00
fyodor
426a8f03d2 Update version number for 5.61TEST5 release 2012-03-09 02:17:53 +00:00
david
894f858fd4 Include <sys/types.h> in the PCAP_IS_SUITABLE test.
The lack of this was causing PCAP_IS_SUITABLE to fail on Arch Linux, at
least. I think that in some cases this caused both -L../libpcap and
-lpcap to be added to the linker line, which could cause an error
because of the need to link with -lnl. (We check for -lnl when
--with-libpcap=included is used (since r23163), but the PCAP_IS_SUITABLE
failure went around this check and allowed linking with the included
libpcap without checking whether -lnl is required.)

Here are reported build failures and responses:
http://seclists.org/nmap-dev/2011/q3/449
http://seclists.org/nmap-dev/2011/q4/33
http://seclists.org/nmap-dev/2012/q1/369
2012-03-04 05:18:08 +00:00
henri
b1086ac340 Added a --nsock-engine option to nmap, nping and ncat to enforce use of a
given nsock IO engine. [Henri]
2012-03-01 09:05:02 +00:00
fyodor
684f42c4ad One more adjustment to the license text. Notes that Zenmap, Ncat, and Nping use this license. Note that contributions made directly in the src repository are treated the same as those in the mailing list. 2012-03-01 06:53:35 +00:00
fyodor
e96a7b7b24 Update the headers for each code file. This updates code copyright dates to 2012, notes the awesome NSE in the list of technology, and slightly rewords the derivative works clarification 2012-03-01 06:32:23 +00:00
fyodor
389fcf4bfc Update a link to Nmap's HACKING file in svn 2012-02-16 07:35:41 +00:00
fyodor
c5effdfb4f Update the Nmap version number to 5.61TEST4 2012-01-02 00:45:04 +00:00
fyodor
158b912bf8 Some more improvements to the CHANGELOG 2012-01-02 00:35:16 +00:00
david
a725ad4248 Whitespace. 2011-12-22 02:37:40 +00:00
fyodor
5c2ddb3c6e latest generated docs 2011-12-19 21:07:38 +00:00
david
5c0b85261b Allow a challenge with no auth-params. 2011-12-19 19:12:49 +00:00
david
3d1e1f1233 Add tests that Proxy-Authenticate can be without auth-params.
See http://seclists.org/nmap-dev/2011/q4/560 for the impetus for this
change.
2011-12-19 19:12:48 +00:00
henri
f74851d638 Removed "n_w" and "numready" variables to get rid of GCC (4.6.1) warnings
concerning set but never used variables.
2011-12-14 15:09:09 +00:00
david
42fa95c755 Update path in comment. 2011-12-09 18:39:03 +00:00
david
ed2ba4e168 Copy nping, nsock, nbase, zenmap, ncat from their homes in /.
If you have trouble updating after this revision you need to follow
these instructions. You have probably just seen an error like this:

svn: URL 'svn://svn.insecure.org/nping' of existing directory 'nping'
does not match expected URL 'svn://svn.insecure.org/nmap/nping'

This is caused by the replacement of SVN externals.

Here's what you need to do. First, save any local changes you might have
in the nping, nsock, nbase, ncat, and zenmap directories. (For example
by running "cd nping; svn diff > ../nping.diff".) If you don't have any
local changes you can skip this step.

Then run these commands:

rm -rf nping/ nsock/ nbase/ ncat/ zenmap/
svn update
svn cleanup

If all else fails, you can just delete your whole working directory and
check out anew:

svn co --username guest --password "" svn://svn.insecure.org/nmap

There may be further discussion in the mailing list thread at
http://seclists.org/nmap-dev/2011/q4/303.
2011-11-16 21:49:44 +00:00