CHMOD-CALCULATOR · UTILITY
Permissions you can read at a glance.
The original index.html becomes a two-way calculator: build the mode with the matrix or paste it in octal and symbolic form, get both chmod commands for your file and review the risks before copying. No frameworks, no server and no leaving the browser.
- Base bits
- 9
- Special bits
- 3
- Presets
- 8
- Server
- 0
What it is and what it is for
The Linux CHMOD Calculator builds permissions in octal (755, 644, 4755…) and symbolic (rwxr-xr-x) form plus the two real chmod commands, numeric and letter-based, from read, write and execute boxes for user, group and others.
It supports the special bits: SUID (4000) to run with the owner’s privileges, SGID (2000) to run with the group’s or inherit the group in folders, and sticky (1000), which in a directory only lets each owner delete their own files, as in /tmp.
The original is a static page in a single index.html with embedded CSS and JavaScript, no frameworks, with a dark technical-panel UI: boxes on the left and copyable results on the right.
When to use it
Setting permissions before deploying
Work out the exact mode of a script or shared folder and copy the command.
Reading permissions in a CTF
Translate an rwsr-xr-x found on a SUID binary into octal on the fly and understand what it implies.
Learning the permission model
See how each box adds 4, 2 or 1 and how special bits turn x into s or t.
How it works
Permission matrix
Nine boxes (r, w, x for user, group and others) plus SUID, SGID and sticky.
Sum per class
Each class adds read 4, write 2 and execute 1; the specials make up the leading digit (4, 2 and 1).
Results
Octal, symbolic (with s/S and t/T) and both chmod commands are shown, ready to copy.
What changes on pwn3d.es
- The pwn3d.es calculator is bidirectional: besides the boxes, it accepts an octal mode or a 9-character symbolic mode and rebuilds the matrix, with error validation.
- The symbolic command always assigns all three classes (u=, g=, o=) to match the octal one; the original left empty classes out and could keep earlier permissions.
- It adds presets, a safely quoted file name and risk warnings (world-writable, SUID, SGID, sticky, 000); external Hack Nerd Font and Font Awesome are not loaded.
Installation and usage
Installation
git clone https://github.com/D1se0/chmod-calculator.git
xdg-open chmod-calculator/index.htmlUsage
chmod 4755 archivo # SUID
chmod 2775 carpeta # SGID
chmod 1777 /tmp # stickyReal examples
755 rwxr-xr-x 644 rw-r--r-- 700 rwx------ 4755 rwsr-xr-x 1777 rwxrwxrwt
Stack and dependencies
- HTML
- A single index.html
- CSS
- Dark technical-panel theme with glassmorphism
- JavaScript
- Calculation and clipboard copy, no frameworks
git · repository code
Explore the repository
Related tools
Rewrite of the original repository's 477-line index.html. Neither Hack Nerd Font nor Font Awesome is loaded: the interface uses the site tokens and every calculation happens in the browser.