> I was thinking along similar line, using XML as the configuration
> file. The front end (Menu/Script/GUI) can use this XML conf. file to
> display & allow for modifications. This also allows an external
> generator (script/utility...) to transform this XML file into specific
> rules file to be consumed by the router/firewall module. The
> flexibility
> of XML makes sense for this kind of presentation. However, to achieve
> the most values that XML brings to the table, it encourages
> all modules
> to have the ability to parse & process XML! This is the problem that
> troubles me in using XML. I don't have an answer yet, and
> would like to
> hear others' opinion on this.
>
for that I suggest a collection of modules/functions:
- question functions, like is_element;
- return functions, returns the value(str) of an element;
- set functions, creates or sets an element value;
- validate functions, to validate the whole file.
then you encapsulate this functions in some higher level functions, and use
them in the create/read/modify processes all around, the same way you call
system objects to write the file to disk.
ps: forgive my lack of linux programming experience, some terms might be
incorrect :)
ps2: XML parsers aren't that dificult to build, but it's a long work!
> Config Util <----> XML <----> router/firewall modules
>
> Regards,
> Ly Vuong
> ----
>
> [EMAIL PROTECTED] wrote:
> > ...
> > pardon my intromission,
> > but this is exactly the kind of use XML was made for, if
> you create a
> > 'schema' for it, all applications can rightly use/modify
> the .conf file
> > (provided that the app knows the schema)
> >
> > pedro
>
> _______________________________________________
> Leaf-devel mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/mailman/listinfo/leaf-devel
>
_______________________________________________
Leaf-devel mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/mailman/listinfo/leaf-devel