Commit Graph

43 Commits

Author SHA1 Message Date
Daniel Richard G 1c0c923ad1 Split g_file_open() into _ro() and _rw() variants
Rename g_file_open() to g_file_open_rw(), and add a new g_file_open_ro()
call that wraps the common g_file_open_ex(file, 1, 0, 0, 0) idiom. This
will make the file access mode more explicit in the code.

Change all calls to g_file_open() to the _ro() or _rw() variant as
appropriate, and replace g_file_open_ex(file, 1, 0, 0, 0) with the _ro()
call.

Lastly, add tests for the two new calls to test_os_calls.c (code
courteously provided by matt335672).
2023-05-15 17:38:31 -04:00
matt335672 0a1a8f40e5 Moved a lot of string funcs to string_calls module 2020-12-22 11:57:24 +00:00
Pavel Roskin 6ed4c969f4 Eliminate APP_CC and DEFAULT_CC 2017-03-14 00:21:48 -07:00
Pavel Roskin b2d3dcf169 Include config_ac.h from all source files 2017-03-04 00:52:34 -08:00
Pavel Roskin 35d7a0b34f Constify all input string arguments in keygen.c 2017-02-02 21:39:10 -08:00
Pavel Roskin 250bb61025 Check for openssl binary in configure, don't fail if not found
Prefer openssl binary from the same location as the openssl library.

Make it possible to suppress certificate generation during install by
passing OPENSSL=: to make.
2017-01-21 18:20:24 -08:00
speidy 337b2d4be3 keygen: openssl.conf cleanup 2016-12-26 21:57:30 +02:00
speidy 2c48dd04e1 keygen: add CA extensions to self-signed certificates 2016-12-24 17:38:54 -05:00
Pavel Roskin 401612fd1d Fix "unable to find 'distinguished_name' in config" with older openssl
This also fixes "make distcheck", which expects "make uninstall" to
remove all installed files.
2016-11-18 03:59:37 +00:00
Koichiro IWAO 7196094016 Do not create SHA-1 certificates anymore
as many systems in the world still default to create SHA-1 certs if
hash algorithm is not specified explicitly.
2016-11-16 17:24:26 +09:00
Jay Sorg 4f33a9db1d change xrdp.ini security_layer=negotiate and auto generate tls keys on make install 2016-11-11 22:55:21 -08:00
Jay Sorg e39f567c35 on make install, don't create rsakeys.ini if it already exists 2016-11-11 21:47:19 -08:00
Pavel Roskin aeeb3d2c2e Fix warnings detected by -Wwrite-strings 2016-07-08 04:29:42 +00:00
Pavel Roskin bd0b1acf79 Fix format warnings caused by g_writeln("") 2016-04-21 21:21:15 -07:00
Jay Sorg 5af0d06d1e keygen: default 2048 bit RSA key 2016-02-24 14:10:46 -08:00
Pavel Roskin b63575cebc Create and install rsakeys.ini
Use install-data-hook to ensure restrictive permissions on rsakeys.ini.

Don't create rsakeys.ini in init scripts. This makes xrdp functional upon
"make install" without relying on the init scripts.

Packagers should not package rsakeys.ini, it should be created when the
package is installed.
2016-02-23 22:33:28 -08:00
Pavel Roskin a452d8d36a Merge AM_CFLAGS and INCLUDES info AM_CPPFLAGS
AM_CPPFLAGS is for flags passed to the preprocessor, such as defines and
includes. AM_CFLAGS is for flags affecting the compiler, such as debug
and optimization settings.

INCLUDES is an obsolete name. Users can pass INCLUDES and break
compilation. AM_CPPFLAGS is more explicit that the flags come from
Automake and should not be overridden.
2016-01-29 22:45:00 -08:00
Laxmikant Rashinkar 0915d33d70 coverity: dead code 2014-07-26 15:06:35 -07:00
Laxmikant Rashinkar 3bb31876e7 coverity: fixed resolution leak issues 2014-07-19 11:56:00 -07:00
Jay Sorg bd810c0695 support 2048 bit RSA keys 2014-06-18 22:02:58 -07:00
Jay Sorg 293c404a12 keygen: add 2048 bit key option 2014-06-06 00:33:08 -07:00
Jay Sorg 96e1811808 keygen: started adding bits for bigger rsa key size 2014-03-28 23:55:25 -07:00
Laxmikant Rashinkar 1123323fda o moved from GNU General Public License to Apache License, Version 2.0
o applied new coding standards to all .c files
o moved some files around
2012-09-19 20:51:34 -07:00
Jay Sorg 58f5dcc030 autotools: change top_srcdir to top_builddir for LIBADD 2012-07-13 16:18:02 -07:00
Itamar Reis Peixoto c1d27665df remove execute permission from keygen.c 2010-11-18 01:27:25 -02:00
jsorg71 d70d80a33d update copyright year 2010-07-04 07:20:56 +00:00
jsorg71 23ffdb0c5f autotools fix and file_loc.h simplified 2009-05-19 04:23:49 +00:00
jsorg71 af83cb7cae remove old makefiles 2008-12-16 02:47:45 +00:00
jsorg71 fa30584146 common change 2008-08-12 06:56:19 +00:00
jsorg71 adb5e12044 add autotools 2008-08-10 07:38:07 +00:00
jsorg71 1c3e74606a work on keygen to install and run on install 2008-05-08 01:43:31 +00:00
jsorg71 cc464bbd04 added comments and changed executable name to xrdp-keygen 2008-04-15 05:37:30 +00:00
jsorg71 c4038f3834 changed unsigned char to tui8 changed a print messsage 2008-04-15 02:30:23 +00:00
jsorg71 38b789e81f update copyright year 2008-01-30 07:30:10 +00:00
jsorg71 bc9462fefe moved ssl calls to common 2007-06-16 04:52:19 +00:00
jsorg71 48153b6244 completed sign key and some cleanups 2007-06-09 23:08:16 +00:00
jsorg71 48f09546a7 added test function 2007-06-09 22:21:39 +00:00
jsorg71 5f4dacbaad added ppk 2007-06-09 06:25:34 +00:00
jsorg71 32cee722e1 reverse the big number bytes 2007-06-09 00:26:02 +00:00
jsorg71 a6d3edf2a2 completed save function 2007-06-08 18:20:09 +00:00
jsorg71 a5fd28f4f5 added dumby sign and save function 2007-06-08 07:31:45 +00:00
jsorg71 023a32252d warnings 2007-06-08 06:54:46 +00:00
jsorg71 ddba72271f added keygen utility 2007-06-08 01:11:35 +00:00