Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 585766 - net-analyzer/sguil-sensor-0.9.0 does not install split agents
Summary: net-analyzer/sguil-sensor-0.9.0 does not install split agents
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Netmon Herd
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks: 585768
  Show dependency tree
 
Reported: 2016-06-13 02:30 UTC by Patrick Michaelis
Modified: 2016-06-14 22:43 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
patch for sguil-sensor-0.9.0.ebuild (sguil-sensor-0.9.0.agent_split.diff,3.09 KB, patch)
2016-06-13 02:30 UTC, Patrick Michaelis
Details | Diff
pads_agent.initd (pads_agent.initd,745 bytes, text/plain)
2016-06-13 02:31 UTC, Patrick Michaelis
Details
pcap_agent.initd (pcap_agent.initd,745 bytes, text/plain)
2016-06-13 02:32 UTC, Patrick Michaelis
Details
pcap_agent-sancp.initd (pcap_agent-sancp.initd,775 bytes, text/plain)
2016-06-13 02:33 UTC, Patrick Michaelis
Details
sancp_agent.initd (sancp_agent.initd,750 bytes, text/plain)
2016-06-13 02:33 UTC, Patrick Michaelis
Details
snort_agent.initd (snort_agent.initd,750 bytes, text/plain)
2016-06-13 02:33 UTC, Patrick Michaelis
Details
patch for sguil-sensor-0.9.0.ebuild, v2 (sguil-sensor-0.9.0.agent_split.diff,3.87 KB, patch)
2016-06-14 22:39 UTC, Patrick Michaelis
Details | Diff
pads_agent.initd v2 (pads_agent.initd,833 bytes, text/plain)
2016-06-14 22:40 UTC, Patrick Michaelis
Details
pcap_agent.initd v2 (pcap_agent.initd,875 bytes, text/plain)
2016-06-14 22:41 UTC, Patrick Michaelis
Details
sancp_agent.initd v2 (sancp_agent.initd,880 bytes, text/plain)
2016-06-14 22:41 UTC, Patrick Michaelis
Details
snort_agent.initd v2 (snort_agent.initd,880 bytes, text/plain)
2016-06-14 22:42 UTC, Patrick Michaelis
Details
sguil-sensor-0.9.0-r1.ebuild (patched ebuild) (sguil-sensor-0.9.0-r1.ebuild,3.53 KB, text/plain)
2016-06-14 22:43 UTC, Patrick Michaelis
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick Michaelis 2016-06-13 02:30:11 UTC
Created attachment 437306 [details, diff]
patch for sguil-sensor-0.9.0.ebuild

Some time before version 0.9.0 upstream has split the sensor_agent into several distinct agents for different tasks. Because the sensor_agent.tcl executable is still in the source code the ebuild did not break. However, it is only there to print a deprecation notice. Therefore the current ebuild is quite useless.

Attached is a patch to sguil-sensor-0.9.0.ebuild to reflect the changes, as well as init scripts for each agent. The init scripts are basically all the same as the sensor_agent script was before. Only the executable names differ.

Note: I did not thorowly test the init scripts, as I am using systemd on all my mashines, but as they all do just start a deamon I assume they work. I'm also working on systemd units, which I will post in a separate bug report.
Comment 1 Patrick Michaelis 2016-06-13 02:31:47 UTC
Created attachment 437308 [details]
pads_agent.initd
Comment 2 Patrick Michaelis 2016-06-13 02:32:17 UTC
Created attachment 437310 [details]
pcap_agent.initd
Comment 3 Patrick Michaelis 2016-06-13 02:33:10 UTC
Created attachment 437312 [details]
pcap_agent-sancp.initd
Comment 4 Patrick Michaelis 2016-06-13 02:33:37 UTC
Created attachment 437314 [details]
sancp_agent.initd
Comment 5 Patrick Michaelis 2016-06-13 02:33:59 UTC
Created attachment 437316 [details]
snort_agent.initd
Comment 6 Patrick Michaelis 2016-06-14 22:39:32 UTC
Created attachment 437574 [details, diff]
patch for sguil-sensor-0.9.0.ebuild, v2

updated patch for the ebuild:

Additional changes to the previous patch are:

* added IUSE flag "sancp" to properly depend on sancp when needed, and only install either the sancp variants of the agents, or the normal ones. (they are mutually exclusive).

* removed the pcap_agent-sancp.initd init scripts again in favor of installing the sancp variants with the same name as the usual agent names when the sancp use flag is set.

* removed the "sed" dance messing with the agent source files in src_prepare(). Instead, I added the set PIDFILE option to all config files. This appears to me as a cleaner way to set the pid file pathes.

* moved all pidfiles from /run/sguil-NAME.pid to run/sguil/NAME.pid. This is not strictly neccessary with the current init scripts, but will be useful when running the daemons as a non-root user (this will be done in the systemd units, see bug #585768)

* added notice about agent split in pkg_postinst(), as well as a reference to the INSTALL doc file. 

* Fixed misleading variable name from HOSTNAME to SERVER_HOST in post_inst() from previous ebuild.
Comment 7 Patrick Michaelis 2016-06-14 22:40:13 UTC
Created attachment 437576 [details]
pads_agent.initd v2
Comment 8 Patrick Michaelis 2016-06-14 22:41:21 UTC
Created attachment 437578 [details]
pcap_agent.initd v2
Comment 9 Patrick Michaelis 2016-06-14 22:41:47 UTC
Created attachment 437580 [details]
sancp_agent.initd v2
Comment 10 Patrick Michaelis 2016-06-14 22:42:12 UTC
Created attachment 437582 [details]
snort_agent.initd v2
Comment 11 Patrick Michaelis 2016-06-14 22:43:49 UTC
Created attachment 437584 [details]
sguil-sensor-0.9.0-r1.ebuild (patched ebuild)

And finally for convinience, the ebuild with the patch applied.