6 <h1>Samba4 ldb test</h1>
8 <form name="LdbTest" method="POST" action="@@request['SCRIPT_NAME']">
9 <input name="submit" type="submit" value="Cancel"><br>
13 if (request['REQUEST_METHOD'] == "POST") {
14 /* if they cancelled then take them back to the list of tests */
15 if (form['submit'] == "Cancel") {
16 redirect("index.esp");
21 hmm, this gets fairly involved ...
23 function showLdbRes(res) {
28 if (typeof(a) == "object") {
30 write(j + "[" + k + "]=" + a[k] + "<br>\n");
33 write(j + "=" + r[j] + "<br>\n");
42 Trying a attribute constrained search on samdb:<p>
45 var dbfile = lpGet("sam database");
46 var attrs = new Array("name", "dnsDomain", "objectSid");
48 res = ldbSearch(dbfile, "(objectClass=domain)", attrs);
52 and now an unconstrained search:<p>
55 var dbfile = lpGet("sam database");
57 res = ldbSearch(dbfile, "(objectClass=domain)");