pledge

  1. pledge
  2. Description
  3. Usage
    1. API
  4. Author
  5. License

Description

This extension provides bindings to OpenBSD's pledge(2) system call.

The source for this egg is available here.

Usage

A single procedure is provided, which has the same interface as the system call.

(import (pledge))
(pledge "rpath")

API

[procedure] (pledge promises #!optional execpromises) => fixnum

Restricts the current process to the capabilities specified by promises, which should be a string.

On success, 0 is returned. On error, -1 is returned and errno should be consulted.

Refer to pledge(2) for more information.

Author

Evan Hanson

License

3-Clause BSD