Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
eduroam
radsecproxy
Commits
81c711a7
Commit
81c711a7
authored
Apr 12, 2012
by
Linus Nordberg
Browse files
Use built-in echo rather than /bin/echo.
`-e' to /bin/echo isn't portable. The BSD's lacks it for instance.
parent
7758dd38
Changes
1
Hide whitespace changes
Inline
Side-by-side
tools/naptr-eduroam.sh
View file @
81c711a7
...
...
@@ -8,7 +8,7 @@
# For host command this is column 5, for dig it is column 1.
usage
()
{
/bin/
echo
"Usage:
${
0
}
<realm>"
echo
"Usage:
${
0
}
<realm>"
exit
1
}
...
...
@@ -22,7 +22,7 @@ dig_it_srv() {
${
DIGCMD
}
+short srv
$SRV_HOST
|
sort
-n
-k1
|
while
read
line
;
do
set
$line
;
PORT
=
$3
;
HOST
=
$4
/bin/
echo
-e
"
\t
host
${
HOST
%.
}
:
${
PORT
}
"
echo
-e
"
\t
host
${
HOST
%.
}
:
${
PORT
}
"
done
}
...
...
@@ -41,7 +41,7 @@ host_it_srv() {
${
HOSTCMD
}
-t
srv
$SRV_HOST
|
sort
-n
-k5
|
while
read
line
;
do
set
$line
;
PORT
=
$7
;
HOST
=
$8
/bin/
echo
-e
"
\t
host
${
HOST
%.
}
:
${
PORT
}
"
echo
-e
"
\t
host
${
HOST
%.
}
:
${
PORT
}
"
done
}
...
...
@@ -61,12 +61,12 @@ if [ -x "${DIGCMD}" ]; then
elif
[
-x
"
${
HOSTCMD
}
"
]
;
then
SERVERS
=
$(
host_it_naptr
)
else
/bin/
echo
"
${
0
}
requires either
\"
dig
\"
or
\"
host
\"
command."
echo
"
${
0
}
requires either
\"
dig
\"
or
\"
host
\"
command."
exit
1
fi
if
[
-n
"
${
SERVERS
}
"
]
;
then
/bin/
echo
-e
"server dynamic_radsec.
${
REALM
}
{
\n
${
SERVERS
}
\n\t
type TLS
\n
}"
echo
-e
"server dynamic_radsec.
${
REALM
}
{
\n
${
SERVERS
}
\n\t
type TLS
\n
}"
exit
0
fi
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment