XML::IDMEF

XML::IDMEF is a module for building/parsing IDMEF messages.
Download

XML::IDMEF Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Erwan Lemonnier
  • Publisher web site:
  • http://search.cpan.org/~erwan/Sub-Contract-0.09/lib/Sub/Contract.pm

XML::IDMEF Tags


XML::IDMEF Description

XML::IDMEF is a module for building/parsing IDMEF messages. XML::IDMEF is a module for building/parsing IDMEF messages.QUICK STARTBelow is an example of an Alert IDMEF message. < ?xml version="1.0" encoding="UTF-8"? > < !DOCTYPE IDMEF-Message PUBLIC "-//IETF//DTD RFC XXXX IDMEF v1.0//EN" "idmef-message.dtd" > < IDMEF-Message > < Alert > < Analyzer model="myids"/ > < Target > < Node > < name >mynode< /name > < /Node > < /Target > < AdditionalData meaning="data2" type="string" >value2< /AdditionalData > < AdditionalData meaning="data1" type="string" >value1< /AdditionalData > < /Alert > < /IDMEF-Message >The previous IDMEF message can be built with the following code snipset: use XML::IDMEF; my $idmef = new XML::IDMEF(); $idmef->add("AlertTargetNodename", "mynode"); $idmef->add("AlertAdditionalData", "value1", "data1"); $idmef->add("AlertAdditionalData", "value2", "data2"); $idmef->add("AlertAnalyzermodel", "myids"); print $idmef->out();To automatically insert an Alert ident tag and set the CreateTime class to the current time, add the 2 lines: $idmef->create_ident(); $idmef->create_time();and you will get (for example): < ?xml version="1.0" encoding="UTF-8"?> < !DOCTYPE IDMEF-Message PUBLIC "-//IETF//DTD RFC XXXX IDMEF v1.0//EN" "idmef-message.dtd"> < IDMEF-Message> < Alert ident="00003EDDDB4F10115110000780D0002"> < Analyzer model="myids"/> < CreateTime ntpstamp="0xc28859cf.0x0">2003-06-04-T11:43:11Z < Target> < Node> < name>mynode< /name> < /Node> < /Target> < AdditionalData meaning="data2" type="string">value2 < AdditionalData meaning="data1" type="string">value1 < /Alert> < /IDMEF-Message> Requirements: · Perl


XML::IDMEF Related Software