WebCalendar <= 1.2.4 (pref.php) Local File Inclusion Vulnerability
The pref.php script in WebCalendar does not properly sanitise the pref_THEME parameter, allowing directory traversal and URL-encoded NULL bytes. An attacker could include arbitrary local files, potentially executing code or disclosing file contents accessible to the web server.
karmainsecurity.com
Published on karmainsecurity.com
WebCalendar contains a flaw that may allow a remote attacker to execute arbitrary commands or code. The issue is due to the pref.php script not properly sanitizing user-supplied input to the ‘prefTHEME’ parameter.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the pref_THEME parameter is passed to a file include function without validation, allowing directory traversal and NULL byte injection.
Impact
An attacker could execute arbitrary commands or code and disclose the contents of any file on the system accessible by the web server.
What the attacker needed
Access to pref.php; ability to set pref_THEME parameter
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
WebCalendar is a web-based calendar application. A file inclusion bug means the program lets a user influence which file on the server it loads, so an attacker can point it at a different file than intended. Here the theme setting is not checked, so an attacker can use path tricks to load other files, which may run code or reveal sensitive data.
What is Path traversal?
Input that builds a file path escapes the intended folder, reading or writing files the application should never touch.