summaryrefslogtreecommitdiff
path: root/source4/lib/socket
AgeCommit message (Collapse)AuthorFilesLines
2007-10-10r12498: Eliminate INIT_OBJ_FILES and ADD_OBJ_FILES. We were not usingJelmer Vernooij1-6/+5
the difference between these at all, and in the future the fact that INIT_OBJ_FILES include smb_build.h will be sufficient to have recompiles at the right time. (This used to be commit b24f2583edee38abafa58578d8b5c4b43e517def)
2007-10-10r12239: as we only get error from our events system when we wait for read ↵Stefan Metzmacher1-1/+1
events, we need to initialy ask for read events too, otherwise we'll never get an error back from socket_connect() metze (This used to be commit 7d94054d0fc954e6d810573430f2c5d35b73125d)
2007-10-10r12116: got rid of composite_trigger_done() and composite_trigger_error(), andAndrew Tridgell2-2/+2
instead make the normal composite_done() and composite_error() functions automatically trigger a delayed callback if the caller has had no opportunity to setup a async callback this removes one of the common mistakes in writing a composite function (This used to be commit f9413ce792ded682e05134b66d433eeec293e6f1)
2007-10-10r11823: make the socket_connect_send() context a child of the local stateAndrew Tridgell1-0/+1
this fixes a valgrind error (This used to be commit db9c0887bd24de4d81b5afa2ff096b3ba65c9720)
2007-10-10r11822: reworked the socket_connect_multi() code so it is built on top ofAndrew Tridgell1-144/+149
socket_connect_send() rather than the lower level socket code. Also simplified the state structures a fair bit, and added name resolution, fixing a bug where the multi-port connect code did a separate name resolution for each port being tried. (This used to be commit 3e6888156c1b2d24fe0d46940773560d219498b3)
2007-10-10r11821: got rid of two more unnecessary variables and made the variable namesAndrew Tridgell1-60/+58
a bit more consistent (This used to be commit 4b6e9c7c978dfca54c05ed2d8995d1333ed21b02)
2007-10-10r11820: fixed some problems with the socket socket.c code.Andrew Tridgell1-68/+72
- removed the duplicate calls to socket_connect(), instead creating a common function socket_send_connect() used by both code paths - fixed some NULL ptr checks (probably was cut-and-paste bugs) - ensure we use the result of the name resolution - added a few comments - use 'fde' for the file description event. The variable name 'connect_ev' immediately made me think of an event context, not a fde. Using common variable name conventions makes code a bit easier to read (This used to be commit 37b73521b4c858c78013279daaa71352c704551d)
2007-10-10r11811: Revert 11808, this broke the selftest. No idea why though. Why do we ↵Volker Lendecke1-2/+2
to the resolve_name if it's not used? I know this is my code, but I don't understand why it breaks tests. Volker (This used to be commit 577a5639d3fc008480e988864bb4fb59939bc2d8)
2007-10-10r11808: Fix socket_connect_evVolker Lendecke1-2/+2
(This used to be commit 95bd3ffaf7efb117206c83f7c75c302b54e6d059)
2007-10-10r11382: Require number of required M4 macrosJelmer Vernooij1-4/+4
Make MODULE handling a bit more like BINARY, LIBRARY and SUBSYSTEM Add some more PUBLIC_HEADERS (This used to be commit 875eb8f4cc658e6aebab070029fd499a726ad520)
2007-10-10r11369: Implement socket_connect_multi: Connect to multiple ipv4 tcp ports inVolker Lendecke3-0/+282
sequence, with a 2-millisecond timeout between firing the syn packets. Build smbcli_sock_connect_send upon that. Volker (This used to be commit 5718df44d90d113304c5deed1e2e7f82ff9e928f)
2007-10-10r11274: Start a connection attempt to the DC's port 389. To do this ↵Volker Lendecke2-63/+175
properly, make socket_connect and ldap_connect properly async. Volker (This used to be commit bcc71fc1deeed443d7cf00220ce264011ddf588d)
2007-10-10r11244: Relative path names in .mk filesJelmer Vernooij1-6/+6
(This used to be commit 24e10300906c380919d2d631bfb3b8fd6b3f54ba)
2007-10-10r11214: Remove scons files (see ↵Jelmer Vernooij1-64/+0
http://lists.samba.org/archive/samba-technical/2005-October/043443.html) (This used to be commit 7fffc5c9178158249be632ac0ca179c13bd1f98f)
2007-10-10r11052: bring samba4 uptodate with the samba4-winsrepl branch,Stefan Metzmacher1-0/+1
before the bad merge metze (This used to be commit 471c0ca4abb17fb5f73c0efed195c67628c1c06e)
2007-10-10r11037:Stefan Metzmacher1-1/+0
(This used to be commit 6913e338405a5aca5c70cf6e022532c596ed0a36)
2007-10-10r10586: Add MergedObject() builder. Default to Library() ratherJelmer Vernooij1-4/+4
then StaticLibrary() (This used to be commit b53313dc517986c69a4e4cb8fe3885b696f8faa1)
2007-10-10r10531: (hopefully) improve detection of socket-related functions in ↵Jelmer Vernooij2-22/+4
external libraries (This used to be commit 20a1aba500c64dc530271a96af8d557bc54af960)
2007-10-10r10509: Some more sconscript fixes. Now getting to link stage for smbclientJelmer Vernooij1-4/+4
(This used to be commit 6df956edbab7ad5e72b2f20e74ab0f0d62528932)
2007-10-10r10456: More SCons fixes:Jelmer Vernooij1-0/+59
- Add framework for fallback generating code - Move pread / pwrite replacement functions to libreplace - Support pidl builds correctly - Support asn1 builds correctly - Move OS-specific checks to lib/replace/SConscript (This used to be commit fbbfad0a1f7dedbf48e835a864f8285f283d72f3)
2007-10-10r10452: Couple of small scons updates - ignore .sconsign filesJelmer Vernooij1-13/+0
(This used to be commit b2d2b4f23393c727ae3feeaf4b4b65bc03a673f7)
2007-10-10r10348: Add scons scripts for remaining subsystems. Most subsystems build now,Jelmer Vernooij1-1/+0
but final linking still fails (as does generating files asn1, et, idl and proto files) (This used to be commit 4f0d7f75b99c7f4388d8acb0838577d86baf68b5)
2007-10-10r10336: Add sconscript for a couple more subsystems.Jelmer Vernooij1-0/+6
(This used to be commit 59d4450453c25f5cce9b67b808ff0c4433c1d194)
2007-10-10r10200: added a composite_trigger_done() call that allows a composite functionAndrew Tridgell1-5/+0
to cause an event to happen immediately. This allows metzes patch for recognising IPs in resolve_name() to work, and also allows us to remove some of the other code where we currently do specific checks for is_ipaddress(). (This used to be commit 9cc000d868e1257ef6429f6f6f1f9d3c28ca330f)
2007-10-10r9705: r9685@blu: tridge | 2005-08-27 19:43:44 +1000Andrew Tridgell4-0/+4
set the backend_name on socket_accept() too (This used to be commit 10ac2732881ac73dd9cb8162beb1efd741bfe3d2)
2007-10-10r9704: r9684@blu: tridge | 2005-08-27 19:38:31 +1000Andrew Tridgell5-5/+17
don't try to call the name resolver on non-ipv4 names! (This used to be commit 4bb3d36fe6705bc625fe4122500f681ab7f2dc53)
2007-10-10r9702: r9680@blu: tridge | 2005-08-27 18:45:08 +1000Andrew Tridgell1-0/+33
- fixed ncacn_ip_tcp to use the generic async name resolution methods, so NBT names now work (as requested several times by abartlet!) - changed resolve_name() to take an event_context, so it doesn't cause the whole process to block - cleaned up the talloc_find_parent_bytype() calls to go via a cleaner event_context_find() call (This used to be commit b3d491b210a8b889a25efcb273e70fefbd01b7f7)
2007-10-10r9110: use printf againStefan Metzmacher1-2/+2
metyze (This used to be commit 99537d35cb7c2561a7ce47ac7ad602496afe3475)
2007-10-10r9106: look for something more usefull in the -lnslStefan Metzmacher1-2/+2
(this is for solaris) metze (This used to be commit f37bb2a838b83e70d50a0ed036e641ced16d8a7b)
2007-10-10r9063: - don't pollute the global $LIBS variable with -ldlStefan Metzmacher2-1/+92
- -lresolve seems to not being needed any more (it's actually not used, and the build farm seem to happy with it) - move socket and netif configure test to seperate files - don't pollute the global $LIBS variable with -lsocket ... - actually make use of the -lsocket when needed (should fix the solaris build) metze (This used to be commit adebd56be6f62323d56b6666ca0e02f85a33438e)
2007-10-10r8408: its quite common in our code to free up a connection when we get anAndrew Tridgell1-0/+27
error, but sometimes a socket option may then happen on the NULL socket. This has been handled by the individual libraries up to now, but its cleaner to centralise it here (This used to be commit d9864e1f9aac1fb19f054c2da996a5099e90941e)
2007-10-10r8394: Make sure the argument to ctype is*(3) macros are unsigned char asLove Hörnquist Åstrand1-1/+1
required by ISO C99. (This used to be commit 56fd21c806e816cf4c3d23881f26474f858b45e2)
2007-10-10r8044: give a better error codeStefan Metzmacher1-3/+3
metze (This used to be commit fdbf822f1c90cba110d91720ea586ceef9de38b2)
2007-10-10r7668: - setup HAVE_ILDAP to enable the ildap backend in ldbAndrew Tridgell1-1/+2
- fixed a bug in socket_connect_ev() (This used to be commit 3f77b879a035929a843e02b798d54eba6625bde7)
2007-10-10r7660: improved error handling in socket_connect_ev() (it matters when nameAndrew Tridgell1-0/+3
resolution fails) (This used to be commit 4013c2ddea0cd03f875e2acf40d2a34344017d05)
2007-10-10r7626: a new ldap client library. Main features are:Andrew Tridgell4-5/+82
- hooked into events system, so requests can be truly async and won't interfere with other processing happening at the same time - uses NTSTATUS codes for errors (previously errors were mostly ignored). In a similar fashion to the DOS error handling, I have reserved a range of the NTSTATUS code 32 bit space for LDAP error codes, so a function can return a LDAP error code in a NTSTATUS - much cleaner packet handling (This used to be commit 2e3c660b2fc20e046d82bf1cc296422b6e7dfad0)
2007-10-10r7476: ensure dgram sockets are created non-blocking. As they usually skipAndrew Tridgell1-0/+6
the connect() stage, we were missing this (This used to be commit f5102b886c10fead0f6bcdc4460584ae53912ebc)
2007-10-10r7227: added a socket_pending() call to abstract away the FIONREAD ioctl. ItAndrew Tridgell4-0/+40
will be interesting to see if this causes any portability problems, as it is a less commonly used call. (This used to be commit f6993db31d93059c70b44a23005ba444e205870f)
2007-10-10r7205: added support for sendto() on unix domain socketsAndrew Tridgell1-0/+32
(This used to be commit 35ef6e3b153f527f79539b2d99c5ff1cd034ba4b)
2007-10-10r6795: Make some functions static and remove some unused ones.Jelmer Vernooij2-7/+0
(This used to be commit 46509eb89980bfe6dabd71264d570ea356ee5a22)
2007-10-10r6562: added support for datagram unix domain sockets in the socket libraryAndrew Tridgell2-9/+26
(This used to be commit 23b2046dcb5c4593cba6964f400a2e5246fb35f7)
2007-10-10r6070: Fix typo's and fallback to "" as default user name if noJelmer Vernooij1-1/+0
other username could be guessed. (This used to be commit 7fe77cd65901776b5a78e8398547f364379259d3)
2007-10-10r5903: While I can't test IPv6, metze asked me to commit a matching changeAndrew Bartlett1-0/+3
for unknown hosts that I just did for IPv4. Andrew Bartlett (This used to be commit 7e1d82a200b3c679b727e0ef28a245389708ae2f)
2007-10-10r5898: Handle errors in the 'sync' name and IP address handling code.Andrew Bartlett1-0/+3
Andrew Bartlett (This used to be commit 6b8b40f73bd8b7ce23effc8eb1d808db77bcbf8b)
2007-10-10r5304: removed lib/socket/socket.h from includes.hAndrew Tridgell7-0/+49
(This used to be commit b902ea546d2d1327b23f40ddaeeaa8e7e3662454)
2007-10-10r5298: - got rid of pstring.h from includes.h. This at least makes it a bitAndrew Tridgell4-0/+4
less likely that anyone will use pstring for new code - got rid of winbind_client.h from includes.h. This one triggered a huge change, as winbind_client.h was including system/filesys.h and defining the old uint32 and uint16 types, as well as its own pstring and fstring. (This used to be commit 9db6c79e902ec538108d6b7d3324039aabe1704f)
2007-10-10r5108: the beginnings of a nbtd server for Samba4. Currently just displaysAndrew Tridgell2-0/+4
the packets it receives, but it at least shows how the server structure will work. To implement it I extended the libcli/nbt/ library to allow for an incoming packet handler to be registered. That allows the nbt client library to be used for low level processing of the nbtd server packets. Other changes: - made the socket library always set SO_REUSEADDR when binding to an interface, to ensure that restarts of a server don't have to wait for a couple of minutes. - made the nbt port configurable. Defaults to 137, but other ports will be useful for testing. (This used to be commit 2fedca6adfd4df9e85cc86896dfa79630777a917)
2007-10-10r5037: got rid of all of the TALLOC_DEPRECATED stuff. My apologies for theAndrew Tridgell3-3/+3
large commit. I thought this was worthwhile to get done for consistency. (This used to be commit ec32b22ed5ec224f6324f5e069d15e92e38e15c0)
2007-10-10r4831: added udp support to our generic sockets library.Andrew Tridgell5-78/+208
I decided to incorporate the udp support into the socket_ipv4.c backend (and later in socket_ipv6.c) rather than doing a separate backend, as so much of the code is shareable. Basically this adds a socket_sendto() and a socket_recvfrom() call and not much all. For udp servers, I decided to keep the call as socket_listen(), even though dgram servers don't actually call listen(). This keeps the API consistent. I also added a simple local sockets testsuite in smbtorture, LOCAL-SOCKET (This used to be commit 9f12a45a05c5c447fb4ec18c8dd28f70e90e32a5)
2007-10-10r4753: added the ability for the generic socket library to handle asyncAndrew Tridgell5-30/+104
connect(). This required a small API change (the addition of a socket_connect_complete() method) (This used to be commit b787dd166f5cca82b3710802eefb41e0a8851fc3)