Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
10cd1e89
Commit
10cd1e89
authored
Jan 23, 2006
by
Mike Hibler
Browse files
Return the control net router MAC address as a firewall variable.
parent
e9581fd0
Changes
1
Hide whitespace changes
Inline
Side-by-side
tmcd/tmcd.c
View file @
10cd1e89
/*
* EMULAB-COPYRIGHT
* Copyright (c) 2000-200
5
University of Utah and the Flux Group.
* Copyright (c) 2000-200
6
University of Utah and the Flux Group.
* All rights reserved.
*/
...
...
@@ -5373,6 +5373,24 @@ COMMAND_PROTOTYPE(dofwinfo)
* Return firewall variables
*/
if
(
vers
>
21
)
{
/*
* Grab the node gateway MAC which is not currently part
* of the firewall variables table.
*/
res
=
mydb_query
(
"select value from sitevariables "
"where name='node/gw_mac'"
,
1
);
if
(
res
&&
mysql_num_rows
(
res
)
>
0
)
{
row
=
mysql_fetch_row
(
res
);
if
(
row
[
0
])
{
OUTPUT
(
buf
,
sizeof
(
buf
),
"VAR=EMULAB_GWMAC VALUE=
\"
%s
\"\n
"
,
row
[
0
]);
client_writeback
(
sock
,
buf
,
strlen
(
buf
),
tcp
);
}
}
if
(
res
)
mysql_free_result
(
res
);
res
=
mydb_query
(
"select name,value from default_firewall_vars"
,
2
);
if
(
!
res
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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