Mailing List Archive

NASL2 reference manual
Any comment on this?
It is far from finished, (and I already know that I triggered some bugs
in Lyx with the funny >> and >>> operators)
Re: NASL2 reference manual [ In reply to ]
> Any comment on this?

Better with an URL, I suppose :-(
http://mapage.noos.fr/arboi/nasl2_reference/

The Lyx source is in the CVS repository...
Re: NASL2 reference manual [ In reply to ]
This basically looks good to me so far, but I do have a couple of comments:

http://mapage.noos.fr/arboi/nasl2_reference/node32.html

I notice that the progress function (scanner_status) is specific to
scanners and cannot be used by other types of plugin. How about making
it into a more generic function eg. plugin_status so that plugins which
can take a long time (such as the web mirroring script) can also make
use of it. The meaning of the two arguments would have to change to be
the amount of work done and the total amount rather than refering
specifically to ports.

Another related idea is having a heartbeat function which would allow a
plugin to remind the system that it is alive. This even could be used in
combination with the timeout stuff perhaps (maybe temporarily supressing
it).

Cheers

Rich.
Re: NASL2 reference manual [ In reply to ]
Richard Moore <rich@westpoint.ltd.uk> writes:

> I notice that the progress function (scanner_status) is specific to
> scanners and cannot be used by other types of plugin. How about making
> it into a more generic function eg. plugin_status so that plugins
> which can take a long time (such as the web mirroring script) can also
> make use of it.

Well, 1st, a scanner can say "I have done 55% of the port range", most
plugins (like webmirror.nasl) cannot. 2nd, sooner or later, the
"current" plugin name will not be displayed any more, because it is
not "current" and there is no simple way it can be.

> Another related idea is having a heartbeat function which would allow
> a plugin to remind the system that it is alive. This even could be
> used in combination with the timeout stuff perhaps (maybe temporarily
> supressing it).

A well designed plugin should not need it. And a badly designed plugin
with keep saying "I'm working! I'm working!".
What's the difference with a big timeout?
Re: NASL2 reference manual [ In reply to ]
Michel Arboi wrote:
> Richard Moore <rich@westpoint.ltd.uk> writes:
>
>
>>I notice that the progress function (scanner_status) is specific to
>>scanners and cannot be used by other types of plugin. How about making
>>it into a more generic function eg. plugin_status so that plugins
>>which can take a long time (such as the web mirroring script) can also
>>make use of it.
>
>
> Well, 1st, a scanner can say "I have done 55% of the port range", most
> plugins (like webmirror.nasl) cannot. 2nd, sooner or later, the
> "current" plugin name will not be displayed any more, because it is
> not "current" and there is no simple way it can be.
>

I would have thought the webmirror plugin could do this because it knows
how many documents it is allowed to fetch, I'm sure there are other
possible plugins that this could be true of. Either way, it was just a
suggestion.

>
>>Another related idea is having a heartbeat function which would allow
>>a plugin to remind the system that it is alive. This even could be
>>used in combination with the timeout stuff perhaps (maybe temporarily
>>supressing it).
>
>
> A well designed plugin should not need it. And a badly designed plugin
> with keep saying "I'm working! I'm working!".
> What's the difference with a big timeout?
>

Well, I'm thinking about what happens when you are scanning machines on
very slow networks. I take the points you make though, and perhaps it
isn't worthwhile.

Cheers

Rich.
Re: NASL2 reference manual [ In reply to ]
On Thu, 2003-02-06 at 11:18, Richard Moore wrote:
> I would have thought the webmirror plugin could do this because it knows
> how many documents it is allowed to fetch

Actually, we limited webmirror.nasl because it is very slow. IMHO it
should be rewritten in NASL2 and enhanced (e.g. with eregmatch)