summaryrefslogtreecommitdiff
path: root/app
AgeCommit message (Collapse)Author
2022-06-04allowMouseOps default is disabled. adjust documentation.Theo de Raadt
2022-05-22Document removal of exec-formatted(), exec-selectable() andMatthieu Herrb
spawn-new-terminal() functions.
2022-05-22Back in darker times, xterm was setuid root to add a user entry to theTheo de Raadt
utmp and wtmp files at startup. real-uid / effective-uid flipping was used to cleanup the records in these two files at logout-time. Over time it was recognized that setuid root is too dangerous, later on even uid flipping became an unacceptable practice (because an attacker who finds a bug will simply flip the uid back to root before continuing exploitation). Some OS's helped xterm (and other similar login-related tooling) by making utmp writeable by a new utmp group, but most did not do the same for wtmp. xterm started using this new utmp gid, and the wtmp code moved to "try, and if it fails, ignore the failure". The obvious way to use this uid is for xterm to open the utmp file for write (early on), discard the egid, and keep the file descriptor around until utmp cleanup at termination. 10-20 lines of code, maybe. But no,.... that's not what happened. The previous setuid root flipping code (which is nearly a hundred lines of #ifdef-wrapped code for portability reasons) was copied and repurposed by adding new #ifdef code for setgid utmp flipping, and thus nearly a hundred lines of #ifdef-wrapped code was added). setgid flipping has less severe security risks than setuid flipping, but it is remains an excessively strong and unneccessary power (compared to a single writeable fd). When pledge() arrived on the scene, "wpath" was required so that the utmp file could be opened late, and "id" was required to support egid flipping. unveil() arrived on the scene, and the utmp path was added to the list of viable paths, once again not considering that an incorrect approach was being taken by the code. I tried rewriting the portable USE_UTMP_SETGID code to follow the open-drop-reuse-fd approach, to help out upstream xterm, but it is such a brain-melting shitshow I gave up, we'll have a (small) intrusive patch which opens utmp early, drops the gid, and reuses the fd later on. Maybe upstream will take care of this eventually to reduce the risk of egid other operating systems. ok matthieu, much feedback from millert
2022-05-22Disable wtmp support on OpenBSD, it hasn't worked in nearly two decadesTheo de Raadt
because we dropped setuid root around the, but the code to attempt it it was erroneously left behind ok matthieu
2022-05-22Disable the exec-formatted and exec-selectable strictlyTheo de Raadt
ok matthieu
2022-05-22Avoid snprintf truncation near environment variablesTheo de Raadt
ok matthieu
2022-05-22A few support functions can be hidden using OPT_EXEC_XTERM, becauseTheo de Raadt
the top-level features are disabled because our xterm uses pledge without "exec" support. ok matthieu
2022-04-25Update to xterm 372. ok tb@, naddy@. Tested by others too.Matthieu Herrb
2022-04-03MFC: TI mode: correct key color highlightingMatthieu Herrb
Commit 19eb8cef by Alan Coopersmith.
2022-02-27cycling fix: when no client is active, warp pointer to last active;Okan Demirmen
from Walter Alejandro Iglesias.
2022-02-26whitespaceOkan Demirmen
2022-02-26Fix spelling of some unused MWM hints; from Sean C. Farley.Okan Demirmen
While here, flesh out the rest of the MWM hints.
2022-02-21Merge Upstream fix for buffer overflow in sixel code.Matthieu Herrb
This code is not compiled on OpenBSD so the shipped xterm are not vulnerable to this (which is CVE-2022-24130) Committing the fix in case someone uses this for builds with sixel enabled.
2022-01-27Add group-last command that shows only the previously active group; ok okanop
2022-01-06stop chowning old drm device nodesJonathan Gray
2021-12-24Allow bare numbers for key and mouse bindings; taken from similarOkan Demirmen
support in other parse.y's; from Leon Fischer <lfischer@airmail.cc>.
2021-11-30switch away from using tradcpp(1) to cpp(1)Robert Nagy
2021-11-22sync parse.y changes from base; ok naddy@Okan Demirmen
original from naddy@: > Don't declare variables as "unsigned char *" that are passed to > functions that take "char *" arguments. Where such chars are > assigned to int or passed to ctype functions, explicitly cast them > to unsigned char. > > For OpenBSD's clang, -Wpointer-sign has been disabled by default, > but when the parse.y code was built elsewhere, the compiler would > complain. > > With help from millert@ > ok benno@ deraadt@
2021-11-19Do not attempt to grab keys without a keycode; this incidentally allowsOkan Demirmen
XF86 keys support. found and fix by Luis Henriques <henrix@camandro.org>
2021-10-31Disable mouse tracking by default.Matthieu Herrb
This causes extra control sequences to be sent to the shell when an application that has it enabled crashes. Discussed with deraadt@
2021-10-25Remove 3rd argument to open() when flags don't include O_CREATMatthieu Herrb
2021-10-25Remove 3rd argument to open() when flags don't include O_CREATMatthieu Herrb
ok deraadt@ ian@
2021-10-17Update to xterm 369. Tested by many.Matthieu Herrb
2021-09-20Allow login when ~/.Xauthority does not existGeorge Koehler
If you had no .Xauthority, you needed to log in twice, because xenodm created .Xauthority after your 1st session failed. problem found by solene@ ok matthieu@ deraadt@
2021-09-15oops typoMatthieu Herrb
2021-09-15Explicitely disable dmx supportMatthieu Herrb
2021-09-06Don't exit if unveil() fails. ok deraadt@Matthieu Herrb
2021-09-03remove useless <sys/param.h> includeMatthieu Herrb
2021-09-02Unveil paths needed by xterm at run-time. work with tb@ and deraadt@Matthieu Herrb
Only in (default) case where there are no exec-formatted or exec-selected resources set. In those case the commands and their arguments could be anywhere.
2021-08-31Make xterm use my_wcwidth unconditionally again.Martijn van Duren
CharWidth is a conditional wrapper that assumes that all wide characters in the range 32-126 and 160-255) are latin-1 characters and are identical with the unicode (UTF-8) codepoints and result in a width of 1. This is correct in so far that the names of these code-points are identical, but for SHY (soft-hyphen) the explanation of how it should be used differs between unicode and latin-1. Latin-1 assumes that it's always displayed, for unicode it should only be displayed after local grammar rules apply. This wrapper got introduced in xterm #334 and is on the short-list of Thomas Dickey to fix. Since we don't know when the next release is going to be, commit this one now, so we have it fixed before 7.0. Originally discrepency between xterm and wcwidth(3) pointed out by Lauri Tirkkonen (lauri <at> hacktheplanet <dot> fi). OK matthieu@
2021-08-30zap trailing white spaceMatthieu Herrb
2021-08-30Make DEF_SERVER configurable.Matthieu Herrb
2021-08-30Generate all the config scripts to avoid hard-coding /usr/X11R6.Matthieu Herrb
This was already done partially.
2021-08-29Update to twm 1.0.11Matthieu Herrb
2021-08-29Update to xwd 1.0.8Matthieu Herrb
2021-08-29Update to xkbcomp 1.4.5Matthieu Herrb
2021-08-29Update xeyes to 1.2.0Matthieu Herrb
2021-08-29Update to fonttosfnt 1.2.2Matthieu Herrb
2021-08-09Update to xrdb 1.2.1Matthieu Herrb
2021-08-01Improve the xenodm(1) manual page: describe the behaviour of te providedMatthieu Herrb
Xsetup, Xstartup, Xsession and Xreset scripts and remove the sample code that don't match the reality. Also, while there mention more files used, including ~/.xsession-errors. Based on a report from Laurence Tratt with corrections from jmc@
2021-06-26Remove a test target that was not intended to be committed.Matthieu Herrb
Noticed by Brad Smith.
2021-06-26Set VT in Xservers for riscv64 too.Matthieu Herrb
2021-04-22Keep pointer within window on maximize/fullscreen togglekn
Spawn a window, maximize it in any way, move the cursor to a window border that is not on the screen's edge and unmaximize again: While the window goes back the cursor stays at the screen's edge, i.e. focus is lost to the underlaying window. Moving, resizing, tiling or snapping windows in any way always moves the cursor along iff needed, e.g. using MS-[hjkl] to move a small window from the center to the edge keeps the cursor within window borders -- no matter what you do with the keyboard, focus stays on that window. Make CM-f, CM-m, CM-equal and CMS-equal (default bindings) for toggling full-screen mode, maximization, vertical maximization and horizontal maximization of the current window drag the cursor along if needed as well. OK okan kmos dv
2021-04-02Update to xterm 367. Tested by abieber@, dv@ and Trondd. Thanks.Matthieu Herrb
2021-03-16Fix confusion in boolean resources parsing.Matthieu Herrb
This caused wrong resources values on big endian machines.
2021-03-16Don't create non-existent atoms. ok kn@Matthieu Herrb
2021-03-14Skip IPv6 Link Local Addresses for TCP listener authorizations.Matthieu Herrb
IPv6 Link Local addresses in $DISPLAY are not working for a number of reasons that are unlikely to get fixed. Matches what is done by startx(1)
2021-03-13Fix mis-indentationMatthieu Herrb
2021-03-13Don't add authorizations for TCP connections by default.Matthieu Herrb
Add a new resource 'listenTcp' (false by default) to explicitely add authorizations for existing IP addresses on startup (and pass -listen tcp to the X server). ok kettenis@
2021-03-13Remove the 30s minimum delay for xlock timeouts. From Alex Raschi.Matthieu Herrb