Ethereal-dev: Re: [Ethereal-dev] Re: [Ethereal-cvs] rev 17057: /trunk/plugins/lua/: Makefile.a
LEGO wrote:
> I find out about lua while trying to get Scite to compile on my mac...
> and guess what... I did not make it to have scite running on my mac.
>
Just using SciTE on Win32 for quite a while, installation wasn't a problem.
That's why I like binary Win32 installers a lot ;-)
I'm using it as a quick loading editor for the small everyday ASCII files.
> There are libraries with which to add this kind of features to lua, if
> they aren't at least it's easy to extend.
Again, in my eyes scripting is about easily extending Ethereal with functions not yet available.
Example problem could be: Send an E-Mail if a special packet was captured.
"lua solution": Find a suitable SMTP library, find out how to add it to lua and then find out how
to use it within lua
... doesn't seem to be the "easiest way" ;-)
>
> I do not know if having a language that can do syscallls embeded into
> ethereal would be a good idea. Remember that on linux (AFAIK) if you
> want to capture you must be root so adding such features by default
> would be like having a setuid shell available to the users.
Work on capturing using (setuid'ed) dumpcap for (t)ethereal is on the way, so this hopefully won't be a problem in the "near" future as Ethereal itself (especially epan) won't need to be running "root'ed" any longer, see also: http://wiki.ethereal.com/Development/PrivilegeSeparation
Having a script language without the ability to do syscalls (and alike) seems to be limiting the general scripting usage a lot.
Hmmm, lua can also do the "trick" anyway: os.execute (command)
http://www.lua.org/manual/5.0/manual.html#5.7: "It passes command to be executed by an operating system shell"
> OK, there are things like erlang, scheme or lisp that are different in
> naure and you need to "think different" to code in them but I see
> perl, python and lua as different languages that express preety much
> the same concepts.
That way you could argue "why not using C". A lot of work while programming is not
about the concepts of the language itself, but the work required to learn the surroundings, e.g.
installation, find docs, learn which extension module is suitable and how to work with it, surround design flaws and all that stuff.
> For every answer I looked for while looking into embeding python I got
> more questions... It is probably my problem but if I cannot get my
> answers I get frustrated after little time.
No, that's a very common problem to people (including myself) and I already guessed that it was your main reason, the lua instructions looking pretty easy for this task :-)
I had a short look into the python docs regarding the C embedding and was confused as well :-(
> It's in my very nature to move in many directions, so it's probable I
> take rigth ones... and wrong ones as well.
>
I show the same behaviour "to move in many directions", especially on some special saturday nights ;-)
As I said before, using an existing scripting language is far better than creating a new one (no need to reinvent the wheel).
The selection of the "right" scripting language will be biased on many things and a "straightforward" approach is often simply the right choice :-)
So as you are doing all the work for now, it's obviously up to you ;-)))
Regards, ULFL
______________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193