7 More Discussions You Might Find Interesting
1. Ubuntu
hello everybody,
i'm a beginner in ash and i want to convert this bash script to ash.
this script send a xml file to a nagios server :
#!/bin/bash
PROGNAME=$(basename $0)
RELEASE="Revision 0.3"
print_release() {
echo "$RELEASE"
}
print_usage() {
echo ""
echo "$PROGNAME... (6 Replies)
Discussion started by: mdijoux25
6 Replies
2. Ubuntu
I'm trying to convert this working bash script into an Ash script,
read -p "Username:" _username
if ! ]]; then
echo "Valid"
else
echo "INVALID"
fi
However, Ash does not recognize the "=~" character.
How can I do this?
Also, is there a good reference guide, so I... (5 Replies)
Discussion started by: fzivkovi
5 Replies
3. Ubuntu
I wrote Bash script and now I want to convert it to Ash. One headache is this function:
do_adduser() {
setaddprompt
_arr_add=("Add manually" "Add via TXT" "return to main menu" "exit program")
select add_action in "${_arr_add}"
do
case "$REPLY" in
1)... (7 Replies)
Discussion started by: fzivkovi
7 Replies
4. Shell Programming and Scripting
Hi All,
I have a script that I wrote on a bash shell, I use it to sort files from a directory into various other directories. I have an variable set, which is an array of strings, I then check each file against the array and if it is in there the script sorts it into the correct folder.
But... (5 Replies)
Discussion started by: sgtbobie
5 Replies
5. Shell Programming and Scripting
I have a script that has to execute a read command in a function, this is in an ash busybox.
The code is...
trapcatch () { echo "Ctl-c Detected, what do you want to do?"
echo "Please choose the number of one of the following options"
echo "1. Jump past this Set"
echo "2. Exit... (8 Replies)
Discussion started by: tesser
8 Replies
6. Shell Programming and Scripting
I am trying to debug something using gdbserver, after the successful/YET REALLY SLOW debug session i see that the ash shell on the the target under debug is messed up.
Probably because gdbserver tries to open the core file which is binary. How do i recover from it?
Also any ideas to speed up... (2 Replies)
Discussion started by: dragonpoint
2 Replies
7. UNIX for Dummies Questions & Answers
Guys
I now have a script that's working in a BASH environment, however one line doesn't appear to be working on an embedded device that has a busybox therefore ASH shell. I've googled but there's very little I can find regarding the ASH shell.
In BASH the following line works...
if ] ;... (6 Replies)
Discussion started by: Bashingaway
6 Replies
LEARN ABOUT DEBIAN
courier::filter::module::clamavd
Courier::Filter::Module::ClamAVd(3pm) User Contributed Perl Documentation Courier::Filter::Module::ClamAVd(3pm)
NAME
Courier::Filter::Module::ClamAVd - ClamAV clamd filter module for the Courier::Filter framework
SYNOPSIS
use Courier::Filter::Module::ClamAVd;
my $module = Courier::Filter::Module::ClamAVd->new(
# See the socket options description for details.
socket_name => '/var/run/clamav/clamd.ctl',
socket_host => 'clamav.example.com',
socket_port => '3310',
max_message_size
=> $max_message_size,
max_part_size => $max_part_size,
response => $response_text,
logger => $logger,
inverse => 0,
trusting => 0,
testing => 0,
debugging => 0
);
my $filter = Courier::Filter->new(
...
modules => [ $module ],
...
);
DESCRIPTION
This class is a filter module class for use with Courier::Filter. It matches a message if the configured ClamAV "clamd" daemon detects
malware in it.
Constructor
The following constructor is provided:
new(%options): returns Courier::Filter::Module::ClamAVd
Creates a new ClamAVd filter module.
%options is a list of key/value pairs representing any of the following options:
socket_name
socket_host
socket_port
These options describe the Unix domain or TCP/IP socket that should be used to connect to the ClamAV daemon. If no socket options
are specified, first the socket options from the local "clamd.conf" configuration file are tried, then the Unix domain socket
/var/run/clamav/clamd.ctl is tried, then finally the TCP/IP socket at 127.0.0.1 on port 3310 is tried. If either Unix domain or
TCP/IP socket options are explicitly specified, only these are used.
max_message_size
An integer value controlling the maximum size (in bytes) of the overall message text for a message to be processed by this filter
module. Messages larger than this value will never be processed, and thus will never match. If undef, there is no size limit.
Defaults to 1024**2(1MB).
As MIME multipart processing can be quite CPU- and memory-intensive, you should definitely restrict the message size to some
sensible value that easily fits in your server's memory. 1024**2(1MB) should be appropriate for most uses of this filter module.
max_part_size
An integer value controlling the maximum size (in bytes) of any single MIME part for that part to be processed by this filter
module. Parts larger than this value will never be processed, and thus will never match. If undef, there is no size limit.
Defaults to the value of the "max_message_size" option, so you don't really need to specify a part size limit if you are
comfortable with using the same value for both. See the "max_message_size" option for its default.
response
A string that is to be returned as the match result in case of a match. The name of the detected malware is appended to the
response text. Defaults to "Malware detected:".
All options of the Courier::Filter::Module constructor are also supported by the constructor of the ClamAVd filter module. Please see
"new" in Courier::Filter::Module for their descriptions.
Instance methods
See "Instance methods" in Courier::Filter::Module for a description of the provided instance methods.
SEE ALSO
Courier::Filter::Module, Courier::Filter::Overview.
For AVAILABILITY, SUPPORT, and LICENSE information, see Courier::Filter::Overview.
AUTHOR
Julian Mehnle <julian@mehnle.net>
perl v5.14.2 2011-12-27 Courier::Filter::Module::ClamAVd(3pm)