summaryrefslogtreecommitdiffstats
path: root/source/utils/nmblookup.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove the char[1024] strings from dynconfig. ReplaceJeremy Allison2007-12-101-2/+2
| | | | | | them with malloc'ing accessor functions. Should save a lot of static space :-). Jeremy.
* Add MAX_DNS_NAME_LENGTH, remove more pstrings.Jeremy Allison2007-11-151-1/+1
| | | | Jeremy.
* Remove more static data from lib/util_sock.c andJeremy Allison2007-11-031-1/+1
| | | | | callers. Jeremy.
* Forgot one more getnameinfo.Jeremy Allison2007-11-021-1/+1
| | | | Jeremy.
* Fix popt bool problems (need POPT_ARG_NONE, not POPT_ARG_VALUE).Jeremy Allison2007-10-261-4/+4
| | | | | Reported by kukks - thanks ! Jeremy.
* This is a large patch (sorry). Migrate from struct in_addrJeremy Allison2007-10-241-175/+225
| | | | | | | | | | | | | to struct sockaddr_storage in most places that matter (ie. not the nmbd and NetBIOS lookups). This passes make test on an IPv4 box, but I'll have to do more work/testing on IPv6 enabled boxes. This should now give us a framework for testing and finishing the IPv6 migration. It's at the state where someone with a working IPv6 setup should (theorecically) be able to type : smbclient //ipv6-address/share and have it work. Jeremy.
* Fix the popt / bool issues. Some places we used BOOLJeremy Allison2007-10-191-7/+25
| | | | | | where we meant int. Fix this. Thanks to metze for pointing this out. Jeremy.
* RIP BOOL. Convert BOOL -> bool. I found a few interestingJeremy Allison2007-10-181-11/+11
| | | | | | | bugs in various places whilst doing this (places that assumed BOOL == int). I also need to fix the Samba4 pidl generation (next checkin). Jeremy.
* Add start of IPv6 implementation. Currently most of this is avoidingJeremy Allison2007-10-101-2/+5
| | | | | | | | | | IPv6 in winbindd, but moves most of the socket functions that were wrongly in lib/util.c into lib/util_sock.c and provides generic IPv4/6 independent versions of most things. Still lots of work to do, but now I can see how I'll fix the access check code. Nasty part that remains is the name resolution code which is used to returning arrays of in_addr structs. Jeremy.
* r24943: Some stackframesVolker Lendecke2007-10-101-1/+2
|
* r23784: use the GPLv3 boilerplate as recommended by the FSF and the license textAndrew Tridgell2007-10-101-2/+1
|
* r23779: Change from v2 or later to v3 or later.Jeremy Allison2007-10-101-1/+1
| | | | Jeremy.
* r13530: Fix from William Jojo for #1970. Make nmblookup doJeremy Allison2007-10-101-7/+6
| | | | | a node status on all IP's when requested. Jeremy.
* r13212: r12414@cabra: derrell | 2006-01-28 17:52:17 -0500Derrell Lipman2007-10-101-1/+1
| | | | | | | | | | | | lp_load() could not be called multiple times to modify parameter settings based on reading from multiple configuration settings. Each time, it initialized all of the settings back to their defaults before reading the specified configuration file. This patch adds a parameter to lp_load() specifying whether the settings should be initialized. It does, however, still force the settings to be initialized the first time, even if the request was to not initialize them. (Not doing so could wreak havoc due to uninitialized values.)
* r12678: One moreVolker Lendecke2007-10-101-0/+2
|
* r8572: Remove crufty #define NO_SYSLOG as it's not used at all anymore.Tim Potter2007-10-101-2/+0
|
* r7882: Looks like a large patch - but what it actually does is make SambaJeremy Allison2007-10-101-1/+1
| | | | | | safe for using our headers and linking with C++ modules. Stops us from using C++ reserved keywords in our code. Jeremy
* r2706: The code that prints the remote MAC address (from the statistics sectionChristopher R. Hertel2007-10-101-4/+7
| | | | | | | | | | | | of the response packet) was outside of the if() that determined whether the query was successful or not. As a result, the MAC address would print out even if there was no MAC address. At least the garbage it printed was relatively consistent. :) I moved the MAC printing into the if() block and added an 'else' to print "No reply..." if the query fails. Chris -)-----
* r248: Add support for printing out the MAC address on nmblookup.Richard Sharpe2007-10-101-1/+5
|
* Ensure nmblookup correctly converts from CH_DOS to CH_UNIX when displayingJeremy Allison2003-08-221-1/+1
| | | | | a printable name on node status. Jeremy.
* Reverse previous patch from Stefan and me after comments by Andrew BartlettJelmer Vernooij2003-05-101-2/+0
|
* Patch from metze and me that adds dummy smb_register_*() functions soJelmer Vernooij2003-05-101-0/+2
| | | | | that is now possible to, for example, load a module which contains an auth method into a binary without the auth/ subsystem built in.
* Merge:Tim Potter2003-04-141-136/+88
| | | | - Jelmer's latest popt changes
* Merge from HEAD:Andrew Bartlett2003-01-141-1/+1
| | | | | | | | | - fstring/pstring mixups - the detection code that found them (disabled) - a bit of whitespace - a static Andrew Bartlett
* Merge from HEAD - make Samba compile with -Wwrite-strings without additionalAndrew Bartlett2003-01-031-2/+2
| | | | | | warnings. (Adds a lot of const). Andrew Bartlett
* Removed global_myworkgroup, global_myname, global_myscope. Added liberalJeremy Allison2002-11-121-6/+2
| | | | | | dashes of const. This is a rather large check-in, some things may break. It does compile though :-). Jeremy.
* Sync with HEADJelmer Vernooij2002-10-281-1/+1
|
* updated the 3.0 branch from the head branch - ready for alpha18Andrew Tridgell2002-07-151-4/+30
|
* Removed version number from file header.Tim Potter2002-01-301-2/+1
| | | | Changed "SMB/Netbios" to "SMB/CIFS" in file header.
* merge changes from 2.2 branch to prevent smb.conf from changing debug levelHerb Lewis2002-01-071-0/+5
| | | | of commands when specified on command line.
* Got medieval on another pointless extern. Removed extern struct ipzeroTim Potter2001-11-261-2/+0
| | | | | | | and replaced with two functions: void zero_ip(struct in_adder *ip); BOOL is_zero_ip(struct in_addr ip);
* Removed TimeInit() call from every client program (except for one placeTim Potter2001-11-231-2/+0
| | | | | in smbd/process.c where the timezone is reinitialised. Was replaced with check for a static is_initialised boolean.
* Store some path names in global variables initialized to configureMartin Pool2001-11-191-4/+3
| | | | default, rather than in preprocessor macros.
* Removed 'extern int DEBUGLEVEL' as it is now in the smb.h header.Tim Potter2001-10-021-2/+0
|
* move to SAFE_FREE()Simo Sorce2001-09-171-1/+1
|
* convert more code to using d_printfAndrew Tridgell2001-09-081-26/+26
|
* Fuss, fuss, fuss...Christopher R. Hertel2001-08-291-1/+1
| | | | | | | | | | Function name_status_query() performs a node status query, so it really should be called "node_status_query()" just to be consistent. Yeah, minor... but it's looking as though an overhaul of namequery.c is in order and I am trying to do the tiny changes that impact other stuff first. Chris -)-----
* strchr and strrchr are macros when compiling with optimisation in gcc, so we ↵Andrew Tridgell2001-07-041-1/+1
| | | | can't redefine them. damn.
* The big character set handling changeover!Andrew Tridgell2001-07-041-2/+0
| | | | | | | This commit gets rid of all our old codepage handling and replaces it with iconv. All internal strings in Samba are now in "unix" charset, which may be multi-byte. See internals.doc and my posting to samba-technical for a more complete explanation.
* rpcclient/rpcclient.c: Non-void return in void function.Jeremy Allison2001-04-281-1/+1
| | | | | | | smbd/sec_ctx.c: Fixed potential memory leak spotted by Kenichi Okuyama@Tokyo Research Lab, IBM-Japan, Co. utils/nmblookup.c: gcc warning on Solaris fix. Jeremy.
* implemented a much nicer name_status() interface. It now returns aAndrew Tridgell2000-12-201-6/+51
| | | | | | | list of structures rather than the dodgy parsing code we had before this also gets smbw working correctly with no initial workgroup (using name_status_find on __MSBROWSE__ returns)
* Simple cleanup, but I also changed the value of the dlevel parameter passedChristopher R. Hertel2000-10-111-5/+5
| | | | | | | | | | to open_socket_in() from within the open_sockets() function. This has some effect on the way port numbers are assigned. Basically, if we use the -r switch we are saying 'use port 137'. If we can't do that, there should be an error message and a failure. If we don't use -r then we simply select the first available port. The way it was working, if we selected -r and port 137 was in use, wierd things would happen as open_socket_in() tried to find another port.
* If I use nmblookup to search for node ZOOB#1B and there is no such nameChristopher R. Hertel2000-06-131-4/+6
| | | | | | | | | | | | | | | registered within the search space, nmblookup would report name_query failed to find name ZOOB I've changed it to report any non-zero type, so the above message becomes name_query failed to find name ZOOB#1B If the query is for ZOOB or even ZOOB#00 then the old style error message is given. Chris -)-----
* fixed a memory leak in nmblookupAndrew Tridgell2000-04-251-0/+2
|
* this looks like a big commit, but it isn't really :)Andrew Tridgell2000-01-071-5/+6
| | | | | | | | This fixes our netbios scope handling. We now have a 'netbios scope' option in smb.conf and the scope option is removed from make_nmb_name() this was prompted by a bug in our PDC finding code where it didn't append the scope to the query of the '*' name.
* added the unexpected packet database (unexpected.tdb)Andrew Tridgell2000-01-031-4/+4
| | | | | | | | | | | | this means "nmblookup -S" now always works, even with broken servers the database stores all unexpected replies and these can be accessed by any client. while doing this I cleaned up a couple of functions, and put in place a better trn_id generator. in most places the code got quite a bit simpler due to the addition of simple helper functions. I haven't yet put the code in to take advantage of this for pdc replies - that will be next. Jeremys pdc finding code will then work :)
* first pass at updating head branch to be to be the same as the SAMBA_2_0 branchAndrew Tridgell1999-12-131-63/+88
|
* jeremy is going to hate me for this.Luke Leighton1999-12-041-11/+15
| | | | | | | | | | | created an "nmb-agent" utility that, yes: it connects to the 137 socket and accepts unix socket connections which it redirects onto port 137. it uses the name_trn_id field to filter requests to the correct location. name_query() and name_status() are the first victims to use this feature (by specifying a file descriptor of -1).
* Makefile.in configure configure.in include/proto.h smbd/noquotas.c ↵Jeremy Allison1998-11-031-0/+3
| | | | | | | | | | | | smbd/quotas.c: Added quotas patch for autoconf from Dejan Ilic <svedja@lysator.liu.se>. printing/printing.c: Filenames with spaces patch from Allan Bjorklund <allan@umich.edu> utils/nmblookup.c: Fix usage() function. smbd/reply.c: Split out the security=server and security=domain checks into check_server_security() and check_domain_security() to aid the writing of the 'hack' appliance mode invented by John Schimmel. Jeremy.
* set recursion desired for bcast name queryAndrew Tridgell1998-10-141-1/+2
|