25 lines
463 B
Bash
25 lines
463 B
Bash
#!/bin/sh
|
|
|
|
post_install() {
|
|
post_upgrade
|
|
cat 1>&2 <<EOF
|
|
*
|
|
* If you want to run wireshark as an unprivileged user
|
|
* then you must add that user to the group "wireshark".
|
|
*
|
|
* # passwd -a <user> wireshark
|
|
*
|
|
EOF
|
|
}
|
|
|
|
post_upgrade() {
|
|
setcap cap_net_raw,cap_net_admin,cap_dac_override+eip usr/bin/dumpcap
|
|
if ! (grep -q wireshark /etc/group); then
|
|
groupadd --gid 150 wireshark >/dev/null 2>&1;
|
|
fi
|
|
}
|
|
|
|
pre_remove() {
|
|
groupdel wireshark > /dev/null 2>&1
|
|
}
|