[tac_plus] Escaping special characters within double quotes
Viswanathan, Vasanth
vasanth.viswanathan at hpe.com
Fri Sep 13 00:06:06 UTC 2019
Hi,
I am using tac_plus version F4.0.4.28. tac_plus man page suggests to use double-quotes when a string has white spaces. Here is an example of command authorization in tac_plus.conf file –
cmd = ping {
permit “10\.10\.10\.[2-9]+ -c 10” # allow 10 pings
deny “10\.10\.10\.[2-9]+ -c 100” # don’t allow 100 pings
}
I have to enclose the regex in double-quotes because it has multiple arguments. But this causes tac_plus to not start due to parsing error.
However this works (without double-quotes) –
cmd = ping {
permit 10\.10\.10\.[2-9]+
deny 10\.10\.10\.[20-30]+
}
I looked the source code and it seems like tac_plus only allows backslash/quote/newline character after a backslash within a double-quoted string. I am trying to understand why we have this restriction.
Thanks!
Vasanth
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.shrubbery.net/pipermail/tac_plus/attachments/20190913/dbc324c2/attachment.html>
More information about the tac_plus
mailing list