Andrew Rioux bd31c6457d
feat: added a docker breakout feature
if the bind shell example is compiled with the right feature and is run
inside a(n) (im)properly configured Docker container, it is now able to
break out and run some commands on the host

for some reason, under this breakout mode, it runs a little weird with
networking commands, but does fine with file system or IPC based commands
2023-05-12 17:41:20 -04:00

22 lines
875 B
Rust

// Copyright (C) 2023 Andrew Rioux
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
fn main() {
println!("cargo:rerun-if-changed=src/docker-breakout.c");
cc::Build::new()
.file("src/docker-breakout.c")
.compile("breakout");
}