1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

237 Commits

Author SHA1 Message Date
Stefan Metzmacher
6c4be5073d r11673: - update the max_version of the owner when we get some records
in the sgroup_merge test, so that we don't see old records as new ones
- finish the owned,sgroup,active vs. sgroup * section

metze
(This used to be commit 534e34a1a1)
2007-10-10 13:46:11 -05:00
Stefan Metzmacher
087577e47b r11672: - add support for special group merge tests
- add owned,sgroup,active vs. replica,sgroup,active test

metze
(This used to be commit 938853dc50)
2007-10-10 13:46:11 -05:00
Stefan Metzmacher
4f78115d6d r11489: add the one replication cycle test to NBT-WINSREPLICATION-QUICK
metze
(This used to be commit fc53eab2f1)
2007-10-10 13:45:44 -05:00
Stefan Metzmacher
0a4de40a0b r11488: handle the stupid name release demand a windows there send...
metze
(This used to be commit 1b62959a3d)
2007-10-10 13:45:44 -05:00
Stefan Metzmacher
b69e508381 r11484: test some multi homed record merging
metze
(This used to be commit 630f571934)
2007-10-10 13:45:43 -05:00
Stefan Metzmacher
36729384f3 r11480: demonstrate the only the positive name query response cares,
not the addresses that are returned in it

metze
(This used to be commit 82e19d6808)
2007-10-10 13:45:43 -05:00
Stefan Metzmacher
580cfbb23a r11478: add owned,active,multi homed vs. * section
metze
(This used to be commit 0231926e0a)
2007-10-10 13:45:42 -05:00
Stefan Metzmacher
187b7a9e53 r11429: - add owned,active,sgroup vs. unique, group and mhomed replica
special group vs. special group will be done later

metze
(This used to be commit 25a35c6977)
2007-10-10 13:45:36 -05:00
Stefan Metzmacher
18a98ecd7a r11426: add owned,active,normalgroup vs. * replica sections
metze
(This used to be commit 70166bb2a9)
2007-10-10 13:45:36 -05:00
Stefan Metzmacher
e173352f1b r11425: add owned,active,unique vs. multi homed section
metze
(This used to be commit a70cf6f87b)
2007-10-10 13:45:36 -05:00
Stefan Metzmacher
f07cb3f35f r11419: add owned,unique,active vs. special group replica section
metze
(This used to be commit 061e2e67da)
2007-10-10 13:45:35 -05:00
Stefan Metzmacher
bc5e112f5b r11418: - add unique,owned,active vs. normal group section
- we handle incoming release demands for that

metze
(This used to be commit 1db4d8e456)
2007-10-10 13:45:35 -05:00
Stefan Metzmacher
4400cf2c31 r11416: add some more comments
metze
(This used to be commit dccaceee18)
2007-10-10 13:45:35 -05:00
Stefan Metzmacher
7675309bd7 r11415: - create a seperate nbt socket for handling incoming packets
- remove useless .release attribute, we have seperate tests for this
  now
- add first owned,active vs. replica test, including handling incoming
  name queries from the server

metze
(This used to be commit 7843b6c5c8)
2007-10-10 13:45:34 -05:00
Stefan Metzmacher
7ec41c9424 r11330: - split up owned,active vs replica and owned,released vs. replica
- complete owned,released tests

metze
(This used to be commit ba82ffb261)
2007-10-10 13:45:20 -05:00
Stefan Metzmacher
2d1aa2954b r11265: add a bunch of owned vs. replica conflict tests
metze
(This used to be commit c8d3c2f1a1)
2007-10-10 13:45:10 -05:00
Stefan Metzmacher
bc43d1b6f0 r11189: add some more special group vs. special group tests,
to make sure that replicas from the same owner are blinding overwritten
in all cases

metze
(This used to be commit 466baf737a)
2007-10-10 13:44:58 -05:00
Stefan Metzmacher
47c0c176e9 r11188: - add multi homed vs. multi homed section
metze
(This used to be commit 838323e58f)
2007-10-10 13:44:58 -05:00
Stefan Metzmacher
7e3d377b1d r11186: - get rid of some .extra = True cases
- add multihomed vs unique section
- update conflict handling for the above case

metze
(This used to be commit c043e56efd)
2007-10-10 13:44:58 -05:00
Stefan Metzmacher
e8118ad3b0 r11177: move unique vs * and normal group vs * into this form
ACTIVE		vs ACTIVE
ACTIVE  	vs TOMBSTONE
RELEASED	vs ACTIVE
RELEASED	vs TOMBSTONE
TOMBSTONE	vs ACTIVE
TOMBSTONE	vs TOMBSTONE

as it seems that is all we need to test,
and w2k3 only decides between ACTIVE and NON-ACTIVE (REALEASED or TOMBSTONE)
when it gets new replica objects

also I have removed all the extra test, we only test the worst cases now,
and this will make the algorithms more clear when you look at the output
of the NBT-WINSREPLICATION torture test

metze
(This used to be commit 7545e4e716)
2007-10-10 13:44:56 -05:00
Stefan Metzmacher
4043d03ef0 r11176: - add multi homed vs. special group section
metze
(This used to be commit 62ddca0e1f)
2007-10-10 13:44:56 -05:00
Stefan Metzmacher
9334501ccb r11175: - add multi homed vs. normal group section
metze
(This used to be commit 891416b79e)
2007-10-10 13:44:55 -05:00
Stefan Metzmacher
3464d409af r11174: - add special group vs. multi homed section
- disable special group vs. special group,
  I need to look closer at this, as I'm getting strange timeouts
  randomly, so the server might be doing some challegnes while
  doing the merging of special group records, witch reaches
  timeouts

metze
(This used to be commit 7479760cbf)
2007-10-10 13:44:55 -05:00
Stefan Metzmacher
4c242c96e0 r11173: print out the correct messages
metze
(This used to be commit d8e7e914bf)
2007-10-10 13:44:55 -05:00
Stefan Metzmacher
8c8c40ecaa r11172: - start with special group vs. special group testing
metze
(This used to be commit ba2c100be6)
2007-10-10 13:44:55 -05:00
Stefan Metzmacher
64b0c02e8b r11146: make sure we get the expected amount of addresses
metze
(This used to be commit 9903a47151)
2007-10-10 13:44:54 -05:00
Stefan Metzmacher
abe4ee3d43 r11144: - add special group vs. normal group section
metze
(This used to be commit 03a8ff89d0)
2007-10-10 13:44:54 -05:00
Stefan Metzmacher
4a8bdae155 r11142: - add special group vs. unique section
metze
(This used to be commit ba17276236)
2007-10-10 13:44:54 -05:00
Stefan Metzmacher
2038e9a698 r11121: - add normal groups vs. multihomed section
- make sure we test the worst case,
  so that we don't need to test everything...
  - same ip(s)		=> not replace
  - different ip(s)	=> replace

metze
(This used to be commit 4a22ce09b4)
2007-10-10 13:44:53 -05:00
Stefan Metzmacher
c4927c843d r11119: add normal group vs. special group section
metze
(This used to be commit 13703b5c35)
2007-10-10 13:44:53 -05:00
Stefan Metzmacher
70be12593a r11117: add a normal group vs. normal group section
metze
(This used to be commit 9a7689c745)
2007-10-10 13:44:52 -05:00
Stefan Metzmacher
80cd8936fa r11116: - don't display cleanup updates
- add unique vs. multi homed section

metze
(This used to be commit 7f8c26cd33)
2007-10-10 13:44:52 -05:00
Stefan Metzmacher
e7238b9306 r11115: add unique vs special group section
metze
(This used to be commit 980e1a39eb)
2007-10-10 13:44:52 -05:00
Stefan Metzmacher
91366a1c96 r11108: - always test the old and new record
- check that the record is the same as what we pushed to the server
  (we need to verify the ip-addresses later too...)

metze
(This used to be commit f59e90299d)
2007-10-10 13:44:51 -05:00
Stefan Metzmacher
f8a3335cb4 r11091: add a NBT-WINSREPLICATION-QUICK test that passed the current samba4 server
metze
(This used to be commit 772467c8d4)
2007-10-10 13:44:47 -05:00
Stefan Metzmacher
cffd522b5c r11052: bring samba4 uptodate with the samba4-winsrepl branch,
before the bad merge

metze
(This used to be commit 471c0ca4ab)
2007-10-10 13:44:43 -05:00
Stefan Metzmacher
fccbbf3546 r10997: r11980@SERNOX (orig r10037): metze | 2005-09-05 14:21:40 +0200
add struct nbt_peer_socket and use it instead of passing const char *addr, uint16 port everyhwere

 (tridge: can you review this please, (make test works)

 metze
(This used to be commit a599d7a4ae)
2007-10-10 13:39:52 -05:00
Stefan Metzmacher
0b0c38d899 r10995: fix released vs. released
metze
(This used to be commit 573c2df2ba)
2007-10-10 13:39:52 -05:00
Stefan Metzmacher
00ef27d754 r10993: - make us able to check released records, we can only do that by finding out the old record was gone
- add more printf(), so -d 10 isn't needed any more

metze
(This used to be commit afe5d2ab85)
2007-10-10 13:39:52 -05:00
Stefan Metzmacher
9dff4c464a r10973: - make debugging a bit easier
- add unique vs. normal group section in replica vs replica conflict testing

metze
(This used to be commit b94be6b119)
2007-10-10 13:39:49 -05:00
Stefan Metzmacher
2ac7af20a0 r10971: - test static records with the same owner too
- test with different owners, and all combinations
  of unique records

metze
(This used to be commit 8df80c5649)
2007-10-10 13:39:49 -05:00
Stefan Metzmacher
a53bec24c1 r10967: move the function in the order they are used
metze
(This used to be commit 6f44ae5a69)
2007-10-10 13:39:49 -05:00
Stefan Metzmacher
3158f35256 r10965: - only run the cross connection assoc test when running with -X
this sometimes crashes the windows server
- add the first replication conflict tests
  we now test that replica records are always overwritten
  when the owner is the same

metze
(This used to be commit f93353ac41)
2007-10-10 13:39:49 -05:00
Stefan Metzmacher
6799fde75d r10766: - make it possible to mark a wrepl_request as send only,
used for WREPL_REPL_INFORM* messsages
- make it possible to close the connection after a request was send
  used for WREPL_ASSOCIATION_STOP
- fix the torture test that tests the assoc context handling
  between connections, you can issue a request and get the reply
  on another connection, I think we should not implement that in our server
  code, as I think it's a security hole, you can cause a windows server
  to send the replies to someone another client, that doesn't wait for data,
  and as there're no massage_id in the protocol the client would be confused
  by a replies that doesn't belong to a query

metze
(This used to be commit dfc95de8fa)
2007-10-10 13:39:28 -05:00
Andrew Bartlett
099c3d5327 r10697: Change the torture join code to return a credentials structure, as
that is what most of the callers want anyway.

Remove and re-add the account for the torture case, rather than just
modify it.

Test with a user account (needs work to change the password).

Andrew Bartlett
(This used to be commit 38bebef024)
2007-10-10 13:39:20 -05:00
Stefan Metzmacher
c2d7914428 r10627: - use a wrepl specific enum for the node type
- the unknown flag 0x10 seems to mean that this name was localy registered on this
  currently asked server, that flag is not present in replica records

metze
(This used to be commit ba3685c41d)
2007-10-10 13:39:13 -05:00
Stefan Metzmacher
08f16292a0 r10608: - fix hierachical memory handling in ndr_pull_nbt_name
- add wrepl_nbt_name scalar type and do the pull/push in the ndr layer
  instead of the caller
- give the flags and group_flag in the wrepl_name a meaning

metze
(This used to be commit b98efc2905)
2007-10-10 13:39:12 -05:00
Stefan Metzmacher
f7c5e5a398 r10569: add all info that we have to wrepl_name, as we need it for replication :-)
metze
(This used to be commit bfd548ca10)
2007-10-10 13:39:06 -05:00
Volker Lendecke
9593101ec1 r10491: First step towards wbinfo -t: This issues a name request for the primary
domain and gets the DC's name via a mailslot call.

Metze, I renamed wbsrv_queue_reply to wbsrv_send_reply in accordance with
irpc_send_reply. Having _queue_ here and _send_ there is a bit confusing. And
as everything is async anyway, the semantics should not be too much of a
problem.

Volker
(This used to be commit 4637964b19)
2007-10-10 13:38:54 -05:00
Andrew Bartlett
5a522b3100 r10486: This is a merge of Brad Henry's 'net join' rework, to better perform
an ADS join, particularly as a DC.  This represents the bulk of his
Google SOC work, and I'm very pleased to intergrate it into the tree.
(Metze will intergrate the DRSUAPI work later).

Both metze and myself have also put a lot of time into this patch, and
in mentoring Brad in general.  In return, Brad has been a very good
student, and has taken the comments well.

Since it's last appearance on samba-technical@, I have made
correctness and valgrind fixups, as well as adding a new 'BINDING'
mode to the libnet_rpc routines.  This allows the exact binding string
to be passed down from the torture code, including options and exact
target host.

Andrew Bartlett
(This used to be commit d6fa105fda)
2007-10-10 13:38:53 -05:00
Stefan Metzmacher
76277d1813 r10167: add a test to check if we always get the same assoc_ctx, on one connection.
metze
(This used to be commit 589541b740)
2007-10-10 13:38:05 -05:00
Stefan Metzmacher
5c7de96d2c r10164: - add first assoc_ctx test
- handle the case where we're no valid pull partner of the tested server

metze
(This used to be commit d2e62dc205)
2007-10-10 13:38:05 -05:00
Stefan Metzmacher
63ef3c7fdc r10113: rename libcli/wins to libcli/wrepl
metze
(This used to be commit d8b84112bb)
2007-10-10 13:38:00 -05:00
Jelmer Vernooij
b674411eb4 r9792: Rename StrCaseCmp -> strcasecmp_m. All these years I was thinking
StrCaseCmp was sys_strcasecmp, while it is in fact strcasecmp_m!
(This used to be commit 200a8f6652)
2007-10-10 13:35:01 -05:00
Andrew Tridgell
c98c6aa561 r9702: r9680@blu: tridge | 2005-08-27 18:45:08 +1000
- 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 b3d491b210)
2007-10-10 13:34:51 -05:00
Andrew Tridgell
e835621799 r8520: fixed a pile of warnings from the build farm gcc -Wall output on
S390. This is an attempt to avoid the panic we're seeing in the
automatic builds.

The main fixes are:

 - assumptions that sizeof(size_t) == sizeof(int), mostly in printf formats

 - use of NULL format statements to perform dn searches.

 - assumption that sizeof() returns an int
(This used to be commit a58ea6b385)
2007-10-10 13:29:34 -05:00
Tim Potter
2b7fe67f4d r6933: Add a couple of helper functions for creating nbt names.
(This used to be commit b896daf11c)
2007-10-10 13:16:58 -05:00
Andrew Tridgell
e284a26294 r6338: ADS style GETDC response now works well enough that WinXP can join
Samba4 without Samba3 nmbd
(This used to be commit f4d07d7d3b)
2007-10-10 13:11:33 -05:00
Andrew Tridgell
8d0a36366c r6331: added IDL and test suite for the ADS style response to a datagram netlogon query.
Note that this response is almost identical to the CLDAP netlogon
response, so adding that will now be quite easy.
(This used to be commit 1ea4ed4ad1)
2007-10-10 13:11:32 -05:00
Andrew Tridgell
f06e39e308 r6321: added IDL and test suite for NBT dgram 'sam logon' request (sent by
clients when a user tries to login)
(This used to be commit 08ded62156)
2007-10-10 13:11:31 -05:00
Andrew Tridgell
b708e87a63 r6288: the nbt dgram server now responds to GETDC requests. It works with our
test suite, but doesn't yet seem to satisfy a nt4 client. I'm
investigating.
(This used to be commit 406217262d)
2007-10-10 13:11:29 -05:00
Andrew Tridgell
b0ca8ed455 r6247: added the server side code for receiving mailslot requests, and
parsing incoming netlogon requests. No replies are sent yet.
(This used to be commit 3b34df6a67)
2007-10-10 13:11:28 -05:00
Andrew Tridgell
866c62f26d r6246: stop waiting when we get a reply
(This used to be commit 8b9a5d8336)
2007-10-10 13:11:28 -05:00
Andrew Tridgell
f83e6ded9d r6245: receive and parse the GETDC response in the NBT-DGRAM test. The test
now tries to bind to port 138 if possible, so if you run it as root
and smbd/nmbd is not running then it works against windows servers
(This used to be commit 52ccdb79bc)
2007-10-10 13:11:28 -05:00
Andrew Tridgell
7c6c366150 r6223: added a bit more datagram infrastructure and the beginnings of a test
suite. The NBT-DGRAM test does a UDP/138 netlogon request, to which a
windows server sends a reply, but the windows server sends the reply
to the wrong port (it always sends to 138), so the test suite doesn't
see it.
(This used to be commit a7634625db)
2007-10-10 13:11:27 -05:00
Andrew Tridgell
42d6a4c4f0 r5451: - added separate wrepl_associate(), wrepl_pull_table() and wrepl_pull_names() functions, with reasonable
parameters, so callers don't need to deal directly with wins replication packet structures

- converted the NBT-WINSREPLICATION torture test to use the new APIs
(This used to be commit cec1672662)
2007-10-10 13:10:47 -05:00
Andrew Tridgell
97dcee677e r5416: nicer output when trying to replicate with a server that hasn't been setup as
a partner
(This used to be commit b94301b357)
2007-10-10 13:10:44 -05:00
Andrew Tridgell
14bd4b8184 r5415: added a NBT-WINSREPLICATION torture test. It asks the server for the
list of partners, and for each partner dumps the complete list of
names
(This used to be commit dacf5f166a)
2007-10-10 13:10:44 -05:00
Andrew Tridgell
4c7c38e930 r5411: make network interface selection a bit saner
- if we have no configured network interfaces, then don't start nbtd (when I add dynamic
  interface loading this will change to a delay until a network interface comes up)

- choose the best interface by netmask for torture tests that need a
  specific IP (such as the WINS test). Added iface_best_ip() for that.

- if specific interfaces are chosen in smb.conf, then keep that ordering, and
  default to the first one listed
(This used to be commit 4d08c11407)
2007-10-10 13:10:43 -05:00
Andrew Tridgell
39713c703d r5408: - added testing for the behaviour of the special 0x1c name
- added WINS server support for the 0x1c name
(This used to be commit 1558a54528)
2007-10-10 13:10:43 -05:00
Andrew Tridgell
82e6a6e46b r5403: a simple WINS benchmarking program
(This used to be commit d0f8b5bc6d)
2007-10-10 13:10:42 -05:00
Andrew Tridgell
97b2a6f7ed r5397: added testing and server support for the special handling required for the 0x1d local master browser name
in WINS
(This used to be commit 2650b43ca9)
2007-10-10 13:09:51 -05:00
Andrew Tridgell
bd00b5bd20 r5386: added testing of registration of group names
(This used to be commit 8afe4bd599)
2007-10-10 13:09:49 -05:00
Andrew Tridgell
7b8f58c37c r5352: added a function nbt_name_string() that formats a nbt_name structure
as a human readable string. The format is designed to be able to be
used as the DN for the WINS database as well, while coping with
arbitrary bytes in the name (except nul bytes)
(This used to be commit aac3090e35)
2007-10-10 13:09:45 -05:00
Andrew Tridgell
64ad8e52ec r5347: fixed the NBT-REGISTER test now that the nbt layer is case sensitive
(This used to be commit ae514f0762)
2007-10-10 13:09:44 -05:00
Andrew Tridgell
5e9c09ef25 r5333: weird, w2k3 always sends a positive name release response, even for names that
have never been registered. I wonder if there is some reason?
(This used to be commit dbef4fd5c3)
2007-10-10 13:09:43 -05:00
Andrew Tridgell
dd689afdc8 r5328: - allow case sensitive nbt name lookups
- added --case-sensitive option to nmblookup

 - added case sensitivity tests to the NBT-WINS test
(This used to be commit 80a95d5688)
2007-10-10 13:09:42 -05:00
Andrew Tridgell
82fd60e904 r5325: - expanded the NBT-WINS test to include scopes
- fixed the bugs that the new test found
(This used to be commit 6d775f1216)
2007-10-10 13:09:41 -05:00
Andrew Tridgell
bed7c9ec32 r5304: removed lib/socket/socket.h from includes.h
(This used to be commit b902ea546d)
2007-10-10 13:09:39 -05:00
Andrew Tridgell
b9bb7f596d r5294: - added a separate NBT-WINS test for WINS operations (register, refresh, release and query)
- change the iface_n_*() functions to return a "const char *" instead of a "struct ipv4_addr"
  I think that in general we should move towards "const char *" for
  all IP addresses, as this makes IPv6 much easier, and is also easier
  to debug. Andrew, when you get a chance, could you fix some of the
  auth code to use strings for IPs ?

- return a NTSTATUS error on bad name queries and node status instead
  of using rcode. This makes the calling code simpler.

- added low level name release code in libcli/nbt/

- use a real IP in the register and wins nbt torture tests, as w2k3
  WINS server silently rejects some operations that don't come from the
  IP being used (eg. it says "yes" to a release, but does not in fact
  release the name)
(This used to be commit bb1ab11d8e)
2007-10-10 13:09:37 -05:00
Andrew Tridgell
63438299ae r5277: initialise the multi_homed flag in the name registration test
(This used to be commit d51fcee29a)
2007-10-10 13:09:36 -05:00
Andrew Tridgell
7f10614e94 r5252: - fixed nmblookup for the nbt api changes
- added a simple WINS server name registration and query test
(This used to be commit d56e68ebf5)
2007-10-10 13:09:34 -05:00
Andrew Tridgell
131dc76d56 r5197: moved events code to lib/events/ (suggestion from metze)
(This used to be commit 7f54c8a339)
2007-10-10 13:09:30 -05:00
Andrew Tridgell
0798d54b4f r5195: most events don't need the time of the event, so save a gettimeofday() call
and just use timeval_current() when its actually needed
(This used to be commit 236403cc4d)
2007-10-10 13:09:30 -05:00
Andrew Tridgell
66170ef8b3 r5185: make all the events data structures private to events.c. This will
make it possible to add optimisations to the events code such as
keeping the next timed event in a sorted list, and using epoll for
file descriptor events.

I also removed the loop events code, as it wasn't being used anywhere,
and changed timed events to always be one-shot (as adding a new timed
event in the event handler is so easy to do if needed)
(This used to be commit d7b4b6de51)
2007-10-10 13:09:29 -05:00
Andrew Tridgell
831e06810a r5156: started on test driven development of the nbt server. This adds a
NBT-REGISTER test that tests that a server correctly defends its name
against broadcast name registrations.

Jeremy, you might like to look at this. Samba3 nmbd fails to respond.
(This used to be commit bb1298a2eb)
2007-10-10 13:09:28 -05:00
Andrew Tridgell
75049fb66f r5130: added a single NBT name query benchmark. It keeps 10 queries in flight at a time.
(This used to be commit 2d23c665ff)
2007-10-10 13:09:25 -05:00