No description
  • C 76.6%
  • Standard ML 13%
  • Shell 6.7%
  • Meson 3.7%
Find a file
2020-05-31 18:31:12 +02:00
examples Squashed commit of the following: 2020-04-04 21:33:54 +02:00
fuzz Remove input device creation from fuzz-parse.c 2020-05-29 15:10:45 +02:00
keys Release 1.0.0 2020-02-17 17:28:35 +00:00
man Reword manpage 2020-05-25 21:16:59 +02:00
signatures Update signatures 2020-05-25 23:01:42 +02:00
.clang-format Release 1.0.0 2020-02-17 17:28:35 +00:00
.gitignore Release 1.0.0 2020-02-17 17:28:35 +00:00
Bugs.md Fix typo 2020-05-25 22:57:56 +02:00
cagebreak.c Fix permission dropping 2020-05-29 16:13:52 +02:00
config.h.in Fix compilation under clang 2020-05-21 19:36:35 +02:00
idle_inhibit_v1.c Fix compilation under clang 2020-05-21 19:36:35 +02:00
idle_inhibit_v1.h Release 1.0.0 2020-02-17 17:28:35 +00:00
ipc_server.c Apply clang-format 2020-05-25 20:13:33 +02:00
ipc_server.h Apply clang-format 2020-05-25 20:13:33 +02:00
keybinding.c Apply clang-format 2020-05-20 19:35:16 +02:00
keybinding.h Apply clang-format 2020-03-21 14:31:06 +01:00
LICENSE Release 1.0.0 2020-02-17 17:28:35 +00:00
meson.build Ameliorate meson.build 2020-05-26 14:16:58 +02:00
meson_options.txt Merge 1.0.6 for compatibility testing 2020-03-29 11:47:44 +00:00
message.c Fix compilation under clang 2020-05-21 19:36:35 +02:00
message.h Release 1.0.0 2020-02-17 17:28:35 +00:00
output.c Fix compilation under clang 2020-05-21 19:36:35 +02:00
output.h Apply clang-format 2020-05-20 19:35:16 +02:00
pango.c Fix conventions for system include 2020-03-21 09:51:05 +01:00
pango.h Release 1.0.0 2020-02-17 17:28:35 +00:00
parse.c Apply clang-format 2020-05-25 20:13:33 +02:00
parse.h Apply clang-format 2020-05-25 20:13:33 +02:00
README.md Add more detailed installation instructions 2020-05-31 18:31:12 +02:00
render.c Release 1.0.0 2020-02-17 17:28:35 +00:00
render.h Release 1.0.0 2020-02-17 17:28:35 +00:00
seat.c Remove keyboard group from list on destroy 2020-04-12 09:07:54 +02:00
seat.h Merge 1.0.6 for compatibility testing 2020-03-29 11:47:44 +00:00
server.c Release 1.0.0 2020-02-17 17:28:35 +00:00
server.h Add ipc capability 2020-05-21 23:04:45 +02:00
util.c Release 1.0.0 2020-02-17 17:28:35 +00:00
util.h Release 1.0.0 2020-02-17 17:28:35 +00:00
view.c Fix indentiing issues 2020-05-28 15:03:59 +02:00
view.h Release 1.0.0 2020-02-17 17:28:35 +00:00
workspace.c Fix compilation under clang 2020-05-21 19:36:35 +02:00
workspace.h Apply clang-format 2020-05-20 19:35:16 +02:00
xdg_shell.c Fix compilation under clang 2020-05-21 19:36:35 +02:00
xdg_shell.h Release 1.0.0 2020-02-17 17:28:35 +00:00
xwayland.c Apply clang-format 2020-02-22 16:37:31 +01:00
xwayland.h Release 1.0.0 2020-02-17 17:28:35 +00:00

Cagebreak: A Wayland Tiling Compositor Inspired by Ratpoison

This is Cagebreak, a Wayland tiling compositor. The goal of this project is to provide a successor to ratpoison for Wayland users. However, this is no reimplementation of ratpoison. Should you like to know if a feature will be implemented, open an issue or get in touch with the development team.

This README is only relevant for development resources and instructions. For documentation of Cagebreak, please see the man pages for cagebreak and cagebreak configuration and the Wiki.

Cagebreak is based on Cage, a Wayland kiosk compositor.

Installation

Obtaining Source Code

There are different ways to obtain cagebreak source:

  • git clone (for all releases)
  • download release asset tarballs (starting at release 1.2.1)

Verifying Source Code

There are corresponding methods of verifying you obtained the correct code:

  • our git history includes signed tags for releases
  • release assets starting at release 1.2.1 contain a signature for the tarball

Building Cagebreak

Simply execute the following steps to build Cagebreak:

$ meson build
$ ninja -C build

Release Build

By default, this builds a debug build. To build a release build, use meson build --buildtype=release.

Xwayland Support

Cagebreak comes with compile-time support for XWayland. To enable this, first make sure that your version of wlroots is compiled with this option. Then, add -Dxwayland=true to the meson command above. Note that you'll need to have the XWayland binary installed on your system for this to work.

Running Cagebreak

You can start Cagebreak by running ./build/cagebreak. If you run it from within an existing X11 or Wayland session, it will open in a virtual output as a window in your existing session. If you run it in a TTY, it'll run with the KMS+DRM backend. For more configuration options, see the man pages.

Contributing to Cagebreak

Cagebreak is currently developed to fit the needs of its creators. Should you desire to implement a feature, please let us know in advance by opening an issue. However, the feature set is intentionally limited (i.e. we removed support for a desktop background) and will continue to be so in the future.

Nonetheless, don't be intimidated by the (slightly lengthy) release checklist or any other part of this file. Do what you can, open an issue and we will collaborate toward a solution.

Branching Strategy and Versioning

All features are to be developed on feature branches, named after the feature.

There exists a branch development to which all reasonable feature branches are merged for final testing.

Once development is ready for a release, meaning that the release checklist is fulfilled, it is merged into master, creating a new release, which is tagged and signed.

All releases are tagged according to semantic versioning guidelines.

In the past, our git history did not perfectly reflect this scheme.

Releases

The release checklist has to be completely fullfilled in one run for a release to occur. Once any failure occurs the entire checklist has to be completed again.

  • git checkout development
  • git pull origin development
  • git push origin development
  • Check cage for possible code merges
  • ninja -C build clang-format
  • Determine new version number according to semantic versioning guidelines
  • Relevant Documentation
    • New features documented
      • man pages
        • man/cagebreak
        • man/cagebreak-config
      • wiki
      • README.md Changelog
    • Document fixed bugs in Bugs.md
  • Testing
    • Manual testing
    • Libfuzzer testing
  • Version Number
    • meson.build
    • git tag
    • man pages
  • git add relevant files
  • git commit
  • git push origin development
  • Check reproducibility on multiple machines
  • Document Reproducible Builds Artefacts
    • Add hashes of the binary
    • Rename cagebreak.sig to previous_signature.sig
    • Add signature of the binary as cagebreak.sig
  • Determine commit and tag message (Start with "Release version_number\n\n")
  • git checkout master
  • git merge --squash development
  • git commit and insert message
  • git tag -u keyid version HEAD and insert message
  • git tag -v version and check signing key
  • git push --tags origin master
  • git checkout development
  • git merge master
  • git push --tags origin development
  • git archive --prefix=cagebreak/ -o release_version.tar.gz tags/version .
  • Check archive
    • tar -xvf release_version.tar.gz
    • cd cagebreak
    • meson build --buildtype=release
    • ninja -C build
    • gpg --verify ../signatures/cagebreak.sig build/cagebreak
    • cd ..
    • rm -rf cagebreak
  • gpg --detach-sign -u keyid release_version.tar.gz
  • Upload archive and signature as release assets

Reproducible Builds

Cagebreak offers reproducible builds given the exact library versions specified in meson.build. Should a version mismatch occur, a warning will be emitted. We have decided on this compromise to allow flexibility and security. In general we will adapt the versions to the packages available under arch linux at the time of release.

There are reproducibility issues up to and including release 1.2.0. See Issue 5 in Bugs.md.

Reproducible Build Instructions

All hashes and signatures are provided for the following build instructions.

meson build -Dxwayland=true --buildtype=release
ninja -C build

Hashes for Builds

For every release after 1.0.5, hashes will be provided.

1.3.0

  • sha 256: aecc5292f56f7250d777110cee1f11a92018a9eb2117d7d37cd51d7d3a5cbae0
  • sha 512: 1d2d220f44787a97359a32f305e33185f0369551e61a9d7066023bfa43de50849eba5bcbb0083d2dc563ac993b8d51dd733afa0adb2a823ef50ecfee5624bbc0

1.2.1

  • sha 256: 803f7667dc4997062f9ec95afcdca0cac68c82a7cf057cef83fe1ccfee33b8bc
  • sha 512: 4d6b7efea10d190a153f893123b1715f290f4b131b490f3d23f489e2dd8edbb886001282849aad9575ad2f40375bbbded59c1cb6157115fcc14dd6a2a061b103

1.2.0

  • sha 256: b3c6135833001a0ef600ea9628cca11f4130a524ebe748929d8f7bad034f2bf0
  • sha 512: c044a086a9f65b0d27d05e2f12a20fe5d77386fc5682991c13a1894a84804bcd337c9167235869661d6e6581133521bd710ef2330066a5d2e2703d1630042f3f

1.1.0

  • sha 256: fc393e225c549f893b9e21e8b904e546d5857bac1d905b3d26334c8f8a1cda11
  • sha 512: 8b94b1069e767202bcab087cb592eadc42f0453d17ee119d48760be00bc66278cf0fa60bb09308d30cb551df6a7a3e26e2ab8b29c04f0e953cc6906542cd2d6f

1.0.6

  • sha 256: 712ae9a8f17a9e589e108f0d503da203cc5eaf1c4a6ca6efb5b4c83b432ce0b8
  • sha 512: d574003023a00cfd6623aac986a5a7f397cfd0bc9114017629a8c72731b0df3977c4a31768502dfa8a6607be06930089b2ccf6ffca9b5bcd1096b7ca0aede226

GPG Signatures

For every release after 1.0.5, a GPG signature will be provided in signatures.

The current signature is called cagebreak.sig, whereas all older signatures will be named after their release version.

Signing Key

All releases are signed by at least one of the following collection of keys.

  • E79F6D9E113529F4B1FFE4D5C4F974D70CEC2C5B
  • 4739D329C9187A1C2795C20A02ABFDEC3A40545F

Should we at any point retire a key, we will only replace it with keys signed by at least one of the above collection.

Should we at any point have official mail addresses, their keys will be signed by a valid key noted above.

The full public keys can be found in keys/ along with any revocation certificates.

GCC and -fanalyzer

Cagebreak should compile with any reasonably new gcc or clang. Consider a gcc version of at least 10.1 if you want to get the benefit of the brand-new -fanalyzer flag. However, this new flag sometimes produces false-postives and we selectively disable warnings for affected code segments as described below.

Meson is configured to set CG_HAS_FANALYZE if -fanalyzer is available. Therefore, to maintain portability, false-positive fanalyzer warnings are to be disabled using the following syntax:

#if CG_HAS_FANALYZE
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "WARNING OPTION"
#endif

and after

#if CG_HAS_FANALYZE
#pragma GCC diagnostic pop
#endif

Fuzzing

Along with the project source code, a fuzzing framework based on libfuzzer is supplied. This allows for the testing of the parsing code responsible for reading the cagebreak configuration file. When libfuzzer is available (please use the clang compiler to enable it), building the fuzz-testing software can be enabled by passing -Dfuzz=true to meson. This generates a build/fuzz/fuzz-parse binary according to the libfuzzer specifications. Further documentation on how to run this binary can be found here.

Here is an example workflow:

rm -rf build
CC=clang meson build -Dfuzz=true -Db_sanitize=address,undefined -Db_lundef=false
ninja -C build/
mkdir build/fuzz_corpus
cp examples/config build/fuzz_corpus/
WLR_BACKENDS=headless ./build/fuzz/fuzz-parse -jobs=12 -max_len=50000 -close_fd_mask=3 build/fuzz_corpus/

You may want to tweak -jobs or add other options depending on your own setup. We have found code path discovery to increase rapidly when the fuzzer is supplied with an initial config file. We are working on improving our fuzzing coverage to find bugs in other areas of the code.

Bugs

For any bug, please create an issue on GitHub.

Fixed bugs are to be assigned a number and summarized inside Bugs.md for future reference independent of github, in case this service is unavailable.

Changelog

Release 1.0.0

Adds basic tiling window manager functionality to cage.

Release 1.1.0

Unifies commands and actions. See Issue 4 in Bugs.md.

Release 1.2.0

Adds output configuration as described in the man pages.

Release 1.3.0

Adds IPC as described in the man pages.

License

Please see LICENSE