1
0
mirror of https://github.com/samba-team/samba.git synced 2025-07-30 19:42:05 +03:00
Commit Graph

408 Commits

Author SHA1 Message Date
e897a57067 r8236: fixed support for arrays of structures
(This used to be commit cbe5289ac9)
2007-10-10 13:19:23 -05:00
f55b2b9610 r8233: - added support for more base types in pidl ejs
- added auto generation of a header with prototypes for public ejs functions

- make public functions non-static

- fixed allocation of fixed sized arrays

- added 'noejs' flag indicating that a typedef will be handled manually by ejs

- added manual functions for sid and GUID, so they show up as nice
  strings in ejs scripts

This allows ejs to bring in samr, security, lsa and misc IDL functions
(This used to be commit a8cb2dbdcc)
2007-10-10 13:19:23 -05:00
c851532bec r8230: prevent authentication dying on a NULL domain
(This used to be commit e1cfc6d032)
2007-10-10 13:19:22 -05:00
c11204339a r8220: added auto-generation of ENUM constants in ejs wrapper. So we can now use the enum name
instead of a integer in ejs scripts making rpc calls
(This used to be commit a61cdee384)
2007-10-10 13:19:21 -05:00
5fa5eb1da0 r8216: - handle union pull in ejs pidl generation
- added debugging calls for missing structure/union elements
(This used to be commit f3ff48204c)
2007-10-10 13:19:20 -05:00
7fded3c856 r8215: switched the pull side of the ejs generator over to the recursive LEVELS based approach.
This allows for much more complex structure mappings to be generated.
(This used to be commit 49fc14d132)
2007-10-10 13:19:20 -05:00
ceb277ced9 r8213: I've started to understand the LEVELS stuff in pidl much better now,
and have re-coded the push side of the ejs generator to use it
properly. It ends up being very neat and small, and should handle much
more complex structures (like arrays of pointers to unions etc).

Also added push side support for unions. This should get more of the
echo pipe working via ejs.
(This used to be commit 2e306be1d8)
2007-10-10 13:19:20 -05:00
65ddc6e9b9 r8200: - added stub functions for union pull/push
- kill the js interpreter with an exception on internal errors
(This used to be commit 5f062d7148)
2007-10-10 13:19:19 -05:00
f44b9ae3e6 r8198: - handled push/pull of simple strings in ejs
- improved the error handling, so the ejs wrappers don't just ignore a type they
  don't handle, instead an exception is issued saying what isn't handled
(This used to be commit a77c2aa860)
2007-10-10 13:19:19 -05:00
74ac1686d5 r8195: - fixed handling of simple arrays. To keep the logic simple, I moved to making all push
functions taking a constant pointer to the type rather than having a different calling
  convention for scalars and pointers

- fixed the setting of the 'length' element in arrays
(This used to be commit 431b4b6888)
2007-10-10 13:19:18 -05:00
3605d2d7ab r8194: delete the old hand-written ejs code for echo_AddOne. This is now
autogenerated by pidl
(This used to be commit 697b67ed57)
2007-10-10 13:19:18 -05:00
7c3fc18315 r8192: updated the glue code for the generated ejs functions from pidl
only handles a small subset of all IDL files so far
(This used to be commit 14b6436cc5)
2007-10-10 13:19:18 -05:00
319f19eb90 r8114: fixed the build after tpots ejs commit ....
(This used to be commit 8649945cf9)
2007-10-10 13:19:10 -05:00
766e8e1acb r8105: Add ejsrpc push/pull functions for uint16 and uint8.
(This used to be commit ee27943e21)
2007-10-10 13:19:08 -05:00
9331714787 r8073: a successful rpc call from ejs!
the ejs_echo.c code is the stuff that needs to be auto-generated by
pidl. It only does echo_AddOne so far.

We also need a table for registering these calls. The code is
hard-wired for echo_AddOne for now.
(This used to be commit b1ea58ddc4)
2007-10-10 13:19:05 -05:00
643e5d8239 r8069: the beginnings of code to allow rpc calls to be made from ejs
tpot, note that this shows how you can modify passed in MprVar
variables in C call
(This used to be commit a782541db3)
2007-10-10 13:19:04 -05:00
c36e1ae46c r7928: Add rename, unlink and list commands.
list() returns a list of strings, but maybe it should be a list of
objects with size, attrib, short name etc.
(This used to be commit 696aa182d5)
2007-10-10 13:18:51 -05:00
ae73a40ad4 r7924: Add mkdir() and rmdir() functions.
Write a macro to check tree handle parameters.
(This used to be commit 043feb131f)
2007-10-10 13:18:51 -05:00
864de2a4ab r7922: Comment out complicated connect/session/tree API for the moment. Replace
with tree_connect() and tree_disconnect() functions.
(This used to be commit 9ed763f7fa)
2007-10-10 13:18:50 -05:00
af237084ec r7633: this patch started as an attempt to make the dcerpc code use a given
event_context for the socket_connect() call, so that when things that
use dcerpc are running alongside anything else it doesn't block the
whole process during a connect.

Then of course I needed to change any code that created a dcerpc
connection (such as the auth code) to also take an event context, and
anything that called that and so on .... thus the size of the patch.

There were 3 places where I punted:

  - abartlet wanted me to add a gensec_set_event_context() call
    instead of adding it to the gensec init calls. Andrew, my
    apologies for not doing this. I didn't do it as adding a new
    parameter allowed me to catch all the callers with the
    compiler. Now that its done, we could go back and use
    gensec_set_event_context()

  - the ejs code calls auth initialisation, which means it should pass
    in the event context from the web server. I punted on that. Needs fixing.

  - I used a NULL event context in dcom_get_pipe(). This is equivalent
    to what we did already, but should be fixed to use a callers event
    context. Jelmer, can you think of a clean way to do that?

I also cleaned up a couple of things:

 - libnet_context_destroy() makes no sense. I removed it.

 - removed some unused vars in various places
(This used to be commit 3a3025485b)
2007-10-10 13:18:15 -05:00
487d1afe30 r7570: Add tree, session and socket disconnect ejs functions.
(This used to be commit 63577628b0)
2007-10-10 13:18:10 -05:00
00e2b7c1b4 r7530: Simply calling convention of lp_load().
This always loads all the services, as we now don't have an easy way
to split out smbd.

Andrew Bartlett
(This used to be commit 990e061939)
2007-10-10 13:18:07 -05:00
fb3874bfac r7505: Add more argument forms for session_setup().
Throw an exception if tree connect fails.
(This used to be commit 5b67f2c3d9)
2007-10-10 13:18:01 -05:00
ae23fe35e2 r7501: Fix credential initialisation in ejs session setup. Implement four
arg and anonymous version of command.

Implement ejs tconx.
(This used to be commit 3b7df1037d)
2007-10-10 13:18:01 -05:00
9e555f75e2 r7500: Initialise module subsystems.
(This used to be commit 564dfe14d0)
2007-10-10 13:18:01 -05:00
16a5d7c175 r7477: Add MPR_TYPE_PTR to ejs_typeof().
(This used to be commit 8574f64ca2)
2007-10-10 13:17:57 -05:00
6ef2a41aa1 r7461: this is the start of some code for mapping IDL onto ejs. This is hand
written code, and it doesn't work or even compile yet. I am committing
it to make it easier to discuss the approach with jelmer and tpot.

The intention is that this code will eventually end up being mostly
auto-generated (with the utility functions split out, just like
librpc/ndr/*.c)
(This used to be commit 30e876e9c2)
2007-10-10 13:17:55 -05:00
aa7b6b3ea5 r7457: Return an ejs C pointer object from the ejs connect() function.
Add a session_setup() function that does an anonymous session setup.  Will
add credential passing later.
(This used to be commit 832332de5d)
2007-10-10 13:17:55 -05:00
0b119901d8 r7422: Create a ejs object to wrap a smbcli_transport pointer.
(This used to be commit a55e40651d)
2007-10-10 13:17:51 -05:00
6eae7eb3c4 r7351: Start of ejs smb client library. I need to figure out a nice API here
that doesn't expose too much of the cifs protocol but still allows
people to do neat things.

Also, talloc lifetimes need to be thought about properly.
(This used to be commit 8062e808ef)
2007-10-10 13:17:45 -05:00
8a2e208e45 r7350: Remove unused label.
(This used to be commit ada0045957)
2007-10-10 13:17:45 -05:00
791db4bf72 r7268: allocate the strings to avoid them disappearing under our feet
(This used to be commit ddd7454cb3)
2007-10-10 13:17:34 -05:00
b7bc13209f r7267: REMOTE_HOST is a better choice
(This used to be commit 41bae267e2)
2007-10-10 13:17:34 -05:00
f84d007c43 r7266: Split the different types of js function defines into separate files,
as there are going to be a lot more of them.
(This used to be commit b086768589)
2007-10-10 13:17:34 -05:00
32f2e9806b r7263: Exit smbscript with the intepreter return value (defaults to 0).
Change the exit value for an exception, usage error and other non-js
errors to 127 which is kinda like the return value for the system(3)
function.
(This used to be commit c77a232b11)
2007-10-10 13:17:33 -05:00
d6555cadb7 r7262: Add a length property to ARGV array.
(This used to be commit 4b775c619b)
2007-10-10 13:17:33 -05:00
b124351079 r7261: Pass by reference is done in js via MPR_TYPE_OBJECT. Update argument
parsing and example for resolveName().
(This used to be commit 1a4a549317)
2007-10-10 13:17:33 -05:00
383c5fb68a r7255: Change syntax of resolveName() js function to be more like the
resolve_name() C function.  I can't figure out how to return variables
by reference though.  Writing to argv[] doesn't seem to work.
(This used to be commit aef99859f2)
2007-10-10 13:17:32 -05:00
384ad5c71b r7254: Add a mprWERROR() function with the same attributes as mprNTSTATUS.
(This used to be commit 2fa6f7bb2b)
2007-10-10 13:17:32 -05:00
266c37e5dc r7238: Add pam auth support in swat
(This used to be commit 8a98572a3b)
2007-10-10 13:17:30 -05:00
e8cbe7f3a4 r7225: Create a MprVar object from a NTSTATUS, e.g:
res: {
  is_err: true,
  is_ok: false,
  errstr: "NT_STATUS_IO_TIMEOUT",
  v: -1073741643
}
(This used to be commit d81d5f8317)
2007-10-10 13:17:28 -05:00
c1b95bd467 r7223: Advance script past interpreter line.
(This used to be commit 31b9fadbed)
2007-10-10 13:17:27 -05:00
afeaf137c4 r7215: Convert smbscript to use ejsEvalScript() and file_load() instead of
ejsEvalFile().

Still need to add advancement of the script past the hash-bang line but
it's home time now!!
(This used to be commit 14a2053c04)
2007-10-10 13:17:27 -05:00
a05bd5e9d6 r7135: make typeof() complient with ECMA 11.4.3
(This used to be commit 29ab4cc6cb)
2007-10-10 13:17:21 -05:00
4f1a5b7169 r7083: Add a ejs hook to the resolve_name() function.
We need to figure out what the best way to return NTSTATUS codes.  In the
Python wrappers I threw an exception which could be caught by some code,
but I'm not sure whether this is possible in ejs.
(This used to be commit 6911e46c6a)
2007-10-10 13:17:14 -05:00
520e2258c9 r7082: Call load_interfaces() in smbscript initialisation.
(This used to be commit 54051bf8bb)
2007-10-10 13:17:13 -05:00
18fa5ea9ef r7081: Add mprToInt() function.
(This used to be commit 790a46f53b)
2007-10-10 13:17:13 -05:00
0b2f972c8a r7080: Fix typo in error message.
(This used to be commit fcf177c86e)
2007-10-10 13:17:13 -05:00
09e00bbdc1 r7078: - fix an uninitialised variable in smbscript
- fixed handle passing in the smb/ejs interface calls, so they can be called
  safely from esp
(This used to be commit 45ea1b6441)
2007-10-10 13:17:13 -05:00
f477a74129 r7075: added support for ARGV[] in ejs scripts
(This used to be commit 3db568eb6b)
2007-10-10 13:17:12 -05:00