]> git.armaanb.net Git - opendoas.git/blob - README.md
Add the XKCD comic to README.
[opendoas.git] / README.md
1 # OpenDoas: a portable version of OpenBSD's `doas` command
2
3 ![sandwich](https://cloud.githubusercontent.com/assets/13654546/9128676/a583cd0a-3c9a-11e5-9b4f-e03ab0ba37d7.png)
4
5 Apologies to [Randall Monroe](http://www.xkcd.org/149/). This work is
6 licensed under a [Creative Commons Attribution-NonCommercial 2.5 License](http://creativecommons.org/licenses/by-nc/2.5/).
7
8 `doas` is a minimal replacement for the venerable `sudo`. It was
9 initially [written by Ted Unangst](http://www.tedunangst.com/flak/post/doas)
10 of the OpenBSD project to provide 95% of the features of `sudo` with a
11 fraction of the codebase.
12
13 This is still a work in progress! Please do not deploy yet in a critical
14 environment! Of note, `doas` semantics may yet change, and I haven't
15 performed even a trivial security audit of my additions.
16
17 ## Building and installing
18
19 Building `doas` should be just a simple `make` away.
20
21 The included makefile also has an installation target. Installation
22 requires root access to properly set the executable permissions. You'll
23 also need to install a `doas.conf` file:
24
25 ```
26 make && sudo make install
27 echo "permit :admin" | sudo tee /etc/doas.conf
28 ```
29
30 Oh the irony, using `sudo` to install `doas`!
31
32 ## About the port
33
34 As much as possible I've attempted to stick to `doas` as tedu desired
35 it. As things stand it's essentially just code lifted from OpenBSD with
36 PAM based authentication glommed on to it.
37
38 I've used cvsync and git-cvsimport to retain the history of the core
39 source files. I may choose to go back and do the same with some of the
40 compatibility functions (such as reallocarray.c).
41
42 I have found it necessary to make some fixes to the codebase. One was
43 a segfault due to differences in yacc/bison, others were just minor
44 fixes to warnings. Once this appears stable, I may try to upstream some
45 of these.
46
47 Currently, this is only tested on MacOSX 10.10 with Clang. My next goal
48 is support for Fedora Linux as well. Contributions gladly accepted. ;-)
49
50 ## Copyright
51
52 All code from OpenBSD is licensed under the BSD license, please see
53 individual files for details as the specific text varies from file to
54 file.
55
56 All code I've written is licensed with the 2-clause BSD.