Commit Graph

1199 Commits

Author SHA1 Message Date
Jon Trulson 349802ddd3 dthelpprint: make it build. 2020-04-13 16:21:27 -06:00
Jon Trulson b64d91d5a9 app-defaults, config, types: re-enable parallel builds
With a fixed merge utility, we can run these builds in parallel now
without random corruption of the message files.
2020-03-24 18:44:40 -06:00
Jon Trulson 3d217c6ed1 merge: fix to use per-proc filenames rather than hardcoding them
The localized/utils/merge utility used hardcoded temporary filenames
to do its thing.  This prevented any Makefiles that called merge from
enabling parallel builds in order avoid the file collisions that would
result.

Now we:

- use filenames that embed the PID in them, making them unique
  per-process
- place them in /tmp, rather than the current directory

As a result, we can now re-enable parallel builds for localized
app-defaults, config, and types.
2020-03-24 18:43:11 -06:00
Jon Trulson 255b399760 appmanager action files: create and populate them
The appmanager action files (/usr/dt/appconfig/appmanager/*) are now
created properly for the main 4 languages supported.  As usual, the
en_US.UTF-8 locale is a symlink to C.

These files were previously created via the UDB database files via
imake.  Obviously we aren't going to be using those in autotools.

So, each language now has an appmanager/ dir in
programs/localized/$LANG/ that will create them properly on a make and
make install.  It uses a new appmgr.am template in localized/templates
to do this.

This also means all of these languages now can use the new actions
added by Antonis, even though they are not translated, they are at
least usable in those languages now.
2020-03-24 18:41:55 -06:00
Jon Trulson 137bbf383e dthelp: get parts of it building.
This was a patch from Peter G, though modified a bit regarding the
LDADDs the way we do them now.
2020-03-23 13:51:01 -06:00
Jon Trulson dcda29d67a dthelpdemo: remove old Makefile.SUN, .IBM, and .HP 2020-03-23 13:44:34 -06:00
Jon Trulson 11b9c30ace Build nsgmls
Patch from Peter G.

Note, this is temporary - eventually we will want to use the system
nsgmls/onsgmls to handle this and remove our ancient copy of nsgmls.
2020-03-23 13:31:34 -06:00
Jon Trulson b649ef98b1 configure: enable building of nsgmls and parts of dthelp
Patch by Peter G.
2020-03-23 13:27:06 -06:00
Jon Trulson 5852c4742f Fix erroneous uses of ${prefix} rather than $(CDE_INSTALLATION_TOP)
Some Makefiles use prefix when they should be using
CDE_INSTALLATION_TOP.

Patch by Peter G.
2020-03-23 13:10:07 -06:00
Jon Trulson a6e78364d0 Use bindir in install hooks rather than CDE_INSTALLATION_TOP
Patch supplied by Peter G.
2020-03-23 13:00:54 -06:00
Jon Trulson 11af2add7e Merge branch 'master' into autotools-conversion 2020-03-23 12:55:32 -06:00
Jon Trulson 15a2032626 Convert uses of XKeycodeToKeysym (deprecated) to XkbKeycodeToKeysym
patch supplied from Peter G.
2020-03-23 12:51:18 -06:00
Jon Trulson 8f2fe85639 Merge branch 'master' into autotools-conversion 2020-03-22 19:09:58 -06:00
Jon Trulson 6f1a110e1d dtksh: fix 32b/64b issues with XmTextGetString and XmTextFieldGetString
Some of these functions were returning pointers cast as integers,
which of course is bad on a 64b LP64 systems.

This code should probably just be refactored at some point.  There may
be other hidden issues, and all the casting just sucks.
2020-03-09 15:37:59 -06:00
Jon Trulson 04b2d175aa SrvPalette.c: missed a merge conflict in SrvPalette.c 2020-01-26 12:22:09 -07:00
Jon Trulson 313b4a8e0b Merge branch 'master' into autotools-conversion 2020-01-26 12:17:44 -07:00
Chase b46cfa7876 Remove redundant hourglass functions 2020-01-26 12:09:12 -07:00
Jon Trulson 6b32246d06 dtsession, DtSvc: fix CVE-2020-2696/VU#308289
Marco Ivaldi <marco.ivaldi@mediaservice.net> has identified 3
vulnerabilities in CDE.

Two of them could affect our CDE (open-source version), while the 3rd
(sdtcm_convert) is Solaris specific.

The two vulnerabilities, both of which affect dtsession could allow a
local privilege escalation to root.  A POC exists for Solaris.  The
POC will not function on our CDE for two main reasons:

- the POC is Solaris specific
- The overflowed variables in question are allocated on the heap,
  whereas in Solaris these variables are located on the stack.

The first vulnerability allows an extra long palette name to be used
to cause a crash via insufficient validation in
SrvPalette.c:CheckMonitor().

The second, which has not yet been assigned a CERT CVE resides in
SmCreateDirs.c:_DtCreateDtDirs() in libDtSvc.  Due to insufficient
bounds checking, a crash or corruption can be achieved by using a very
long DISPLAY name.

This one is considered difficult to exploit, and no POC code is
available at this time.  CDE 2.x code-bases are also listed as not
vulnerable, however some work has been done anyway to do some proper
bounds checking in this function.

The following text portions are copied from the relevant advisories,
which have not been released as of this writing.

NOTE: Oracle CDE does NOT use CDE 2.3.0a or earlier as mentioned
below.  They are completely different code-bases):

Regarding CVE-2020-2692:

  A buffer overflow in the CheckMonitor() function in the Common
  Desktop Environment 2.3.0a and earlier, as distributed with Oracle
  Solaris 10 1/13 (Update 11) and earlier, allows local users to gain
  root privileges via a long palette name passed to dtsession in a
  malicious .Xdefaults file.

  Note that Oracle Solaris CDE is based on the original CDE 1.x train,
  which is different from the CDE 2.x codebase that was later open
  sourced. Most notably, the vulnerable buffer in the Oracle Solaris
  CDE is stack-based, while in the open source version it is
  heap-based.

Regarding the DtSvc bug, which does not currently have a CERT CVE:

  A difficult to exploit stack-based buffer overflow in the
  _DtCreateDtDirs() function in the Common Desktop Environment version
  distributed with Oracle Solaris 10 1/13 (Update 11) and earlier may
  allow local users to corrupt memory and potentially execute
  arbitrary code in order to escalate privileges via a long X11
  display name. The vulnerable function is located in the libDtSvc
  library and can be reached by executing the setuid program
  dtsession.

  The open source version of CDE (based on the CDE 2.x codebase) is
  not affected.
2020-01-13 19:13:23 -07:00
Jon Trulson 1aaf63f2a0 dtterm, dtsession, dtappgather, dtmail: set correct perms on make install 2020-01-05 20:53:03 -07:00
Jon Trulson 7f4889f348 freetype: redo the way we detect and use
We (configure) relies on freetype-config existing and telling us what
the proper includes and libs are.
2020-01-05 18:11:52 -07:00
Jon Trulson 00dcd9c63d FreeBSD 12: get CDE to build and run
With this patch, CDE (autotools) builds and runs on fbsd 12 now.
fbsd11 should work too, but not yet tested.

You must use gmake - ie:

./configure MAKE=gmake
gmake

Seems all of the BSD's will need to use gmake for now.
2020-01-04 16:26:46 -07:00
Jon Trulson 005c72b917 Merge branch 'master' into autotools-conversion 2019-12-15 15:18:41 -07:00
Chase 008512c777 extra.h: remove unused prototypes 2019-12-15 14:07:52 -07:00
Chase f28abfe8dd dtksh: remove needless OS defines 2019-12-15 14:07:52 -07:00
Chase cc73d03e49 dtkcmds.c: avoid c99 collision 2019-12-15 14:07:52 -07:00
Chase 3152b0bc4e dtksh: remove unused files and functions 2019-12-15 14:07:52 -07:00
Jon Trulson dd729a7be9 _common.dt.tmsg: remove unportable quote hackery 2019-12-15 12:34:00 -07:00
Jon Trulson e4e8b323c7 localized: use proper mkcatdefs for the Motif catalogs 2019-12-15 11:20:36 -07:00
Jon Trulson 9b2534efab dtsession: do not hardcode -lcrypt on link 2019-12-14 19:14:52 -07:00
Jon Trulson 617865da94 gencat: get rid of -o option, not needed and not supported on some systems 2019-12-14 19:05:35 -07:00
Jon Trulson c1078e464a dtlogin: build on openbsd 2019-12-14 18:22:49 -07:00
Jon Trulson d0ce42db9e dtopen/Makefile.am: fix typo in link for pdf handler 2019-12-14 14:21:41 -07:00
Jon Trulson b19aa1b21f dtopen: install symlinked helpers
With this commit, CDE can install and run now.  There are still some
programs/ that are not yet built:

dthelp dtksh dtappbuilder dtdocbook dtinfo nsgmls ttsnoop

and of course documentation (doc/).  But this is a great start.  For
the first time, things build, install, AND run correctly :)
2019-12-04 18:26:32 -07:00
Jon Trulson 7c81d9d19d programs/Makefile.am: add missing palettes/ dir 2019-12-04 16:36:09 -07:00
Jon Trulson 1b5d18f604 fontaliases: redo the way these are built, and actually install them
Use a common make include file to do most of the work and set the
appropriate LANG from localized/templates/ .  This should simplify it
quite a bit and reduce duplication.

Also we were not even installing them, so now we are.
2019-12-04 15:47:28 -07:00
Jon Trulson 25035724af cpp revisited: look for a cpp binary in various locations for use at runtime
Certain programs like dtlogin and tt_type_comp need access to the
system's cpp command to process certain files at runtime.  tradcpp is
not installed on most systems, and is intended for use as a imake-cpp
replacement which is all we are using it for.  We still need an
honest cpp for the CDE components to use.

Now, we look in various places for a 'cpp' command and set CPP_COMMAND
to it's value.  This way tt_type_comp and other CDE programs can do
required processing at runtime.
2019-12-04 14:28:44 -07:00
Jon Trulson 65ce14c419 dtwm: don't install Dtwm.defs - that is processed/handled by localization 2019-12-04 13:43:18 -07:00
Jon Trulson 7364f62ce8 icons: install in proper C/ subdir 2019-12-04 13:22:11 -07:00
Jon Trulson 21cf53c0d0 Fix palette and backdrops installation in dt/shared with proper symlinks 2019-12-04 13:21:31 -07:00
Jon Trulson 15dfdf231a dtsession/SrvPalette.c: delete trailing whitespace 2019-12-03 17:14:32 -07:00
Jon Trulson eb986d8018 dtsession/SrvPalette.c: fix bogus error handling when selection is lost 2019-12-03 17:10:35 -07:00
Jon Trulson 48dd0a54f3 dtlogin/dtsession: fix up some script perms, add proper OS defines 2019-12-03 14:06:18 -07:00
Jon Trulson 005c328779 dtlogin: set correct OS defines for Xsession, fix linux maildir 2019-12-03 13:07:19 -07:00
Jon Trulson 0d69a14ab3 videoTypes.dt: remove duplicate LABEL in Print action 2019-12-03 13:06:21 -07:00
Jon Trulson 8c19b67032 dtsession: add missing dtsession_res script 2019-12-02 23:02:08 -07:00
Jon Trulson 6f27da77d9 dtwm: fix installation 2019-12-02 23:01:08 -07:00
Jon Trulson 751e85d877 dtlogin: fixup some of the options 2019-12-02 23:00:16 -07:00
Jon Trulson ce02cc49d6 dtlogin: install Xsession properly 2019-12-02 22:13:39 -07:00
Jon Trulson cdc9eae583 Get tttypes installed correctly.
There is a problem with CPP_PROGRAM - using $CPP or $GENCPP (tradcpp)
always fails in tt_type_comp with the error:

"nclude ", line 8: syntax error

If I define it to /lib/cpp (previous hardcoded value) then it seems to
work fine.  Only the dtinfo and dtinfo_start ptypes use #include, and
therefore show this error.  Needs investigation.
2019-12-02 19:59:44 -07:00
Jon Trulson 0cc0766cbd Get the dt types installed properly on make install 2019-12-02 19:31:02 -07:00