2017-04-28 05:02:06 -05:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
|
|
|
/*
|
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
*/
|
2020-04-18 03:39:50 -05:00
|
|
|
|
|
|
|
#pragma once
|
2017-04-28 05:02:06 -05:00
|
|
|
|
2020-02-28 03:50:58 -06:00
|
|
|
#include <Protocol.hpp>
|
2018-06-04 15:47:39 -05:00
|
|
|
|
2017-04-28 05:02:06 -05:00
|
|
|
namespace Seccomp {
|
|
|
|
enum Type { KIT, WSD };
|
|
|
|
|
|
|
|
/// Lock-down a process hard - @returns true on success.
|
|
|
|
bool lockdown(Type type);
|
2017-06-30 05:10:38 -05:00
|
|
|
};
|
2017-06-10 19:41:30 -05:00
|
|
|
|
2017-06-30 05:10:38 -05:00
|
|
|
namespace Rlimit {
|
2017-06-10 19:41:30 -05:00
|
|
|
/// Handles setconfig command with limit_... subcommands.
|
|
|
|
/// Returns true iff it handled the command, regardless of success/failure.
|
2020-02-28 03:50:58 -06:00
|
|
|
bool handleSetrlimitCommand(const StringVector& tokens);
|
2017-04-28 05:02:06 -05:00
|
|
|
};
|
|
|
|
|
|
|
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|