Documentation ¶
Overview ¶
Raw implements a "raw" sandbox.
The sandbox does NOT prevent against ANY malicious attacks, not even a single shell command. Therefore this is NOT RECOMMENDED to run an online judge with this box UNLESS you ABSOLUTELY TRUST all the users.
That said, it is useful if somehow you want to use this alone when you don't have access to a sandbox like isolate.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Sandbox ¶
type Sandbox struct{}
Sandbox implements worker.Sandbox.
func (*Sandbox) Run ¶
func (s *Sandbox) Run(input *worker.SandboxInput) (*worker.SandboxOutput, error)
Run implements Sandbox.Run
func (*Sandbox) RunFrom ¶
func (s *Sandbox) RunFrom(cwd string, input *worker.SandboxInput) (*worker.SandboxOutput, error)
RunFrom runs the input, assuming that it has write access to "cwd".
Raw sandbox assumes that:
- MEMORY LIMITS ARE NOT SET. It always reports a memory usage of 0 (it cannot measure them).
- THE PROGRAM DOES NOT MESS WITH THE COMPUTER. LMAO
- The folder will be thrown away later.
Click to show internal directories.
Click to hide internal directories.