remove extraneous text from bootstrap message - fix #3644
Implemented safe_open() in order to avoid symlink race conditions.

It makes sure that we do not follow unsafe symlinks, that is a link
that belongs to a user, but has a target owned by a different user.
It does this in a way that avoids race conditions (between testing if
a file is a link, and opening that file, there is a small window of
opportunity).

Also implements safe_chdir(), to also safeguard chdir() operations.

Fixes issue #3693.
(cherry picked from commit 995b9d18d750713cd40ce0203550a45646a53cd0)

Conflicts:

	cf-agent/files_editline.c
	cf-agent/verify_files.c
	cf-agent/verify_packages.c
	cf-execd/cf-execd-runner.c
	cf-key/cf-key-functions.c
	cf-serverd/server_common.c
	configure.ac
	libcfnet/client_code.c
	libpromises/cf3lex.l
	libpromises/env_context.c
	libpromises/parser.c
	libpromises/pipes_unix.c
	libpromises/sysinfo.c
	libpromises/verify_reports.c
	libutils/hashes.c
	tests/unit/Makefile.am
Merge pull request #1116 from kacfengine/safe_open_3.5.x

[3.5.x] Implemented safe_open() in order to avoid symlink race conditions.
Work around fdopendir() missing on some platforms.
(cherry picked from commit 19be8b73b5ee94b890ca09ccf7346ea923b36c1c)
Merge pull request #1118 from kacfengine/safe_open_3.5.x

[3.5.x] Work around fdopendir() missing on some platforms.
Add missing header.
Merge pull request #1122 from kacfengine/safe_open_3.5.x

Add missing header.
Don't use O_DIRECTORY flag, which is Linux specific.

Directories will fail when we try to chdir into them anyway, so all
we lose is the early warning.
(cherry picked from commit fd0488f19bc8325bbb51171dd6fc69b074d2b51c)
Switch back to test folder after each test.

Otherwise the test framework may try to write into the wrong
directory.
(cherry picked from commit 7828a2ad7a4efb1799b8c9208c33e03f3af83aea)
Merge pull request #1124 from kacfengine/safe_open_3.5.x

[3.5.x] Some fixes for the safe_open() function.
Don't use GetErrorStrFromCode(), which is not defined in 3.5.x.
Merge pull request #1126 from kacfengine/safe_open_3.5.x

[3.5.x] Don't use GetErrorStrFromCode(), which is not defined in 3.5.x.
Pre-release version bump
va_arg is not well-defined for shorter-than-int arguments

Use int instead of mode_t, as the latter is either int or short
(cherry picked from commit e471bfd58655521fbb5474b49ec85ece174eeee7)
Add missing platform header for HP-UX.

The code compiles without it, but gets the wrong definition of stat
on HP-UX
(cherry picked from commit 6f2025af92da86c70af6e0d67bf6faa187838233)
Merge pull request #1127 from kacfengine/3.5.x

[3.5.x] Fixes for HP-UX.
Fix broken safe_open() when path contains double slashes.
(cherry picked from commit ed36f31a54950a2778f380a9c3606502120ba647)
Merge pull request #1130 from kacfengine/3.5.x

[3.5.x] Fix broken safe_open() when path contains double slashes.
Fix compilation on Solaris 11.

The DATA_TYPE_STRING enum value is defined in their zone.h file, but
we also use it in evaluation code, so compile these functions in a
separate file that doesn't include cf3.defs.h.

Fixes issue #3472.

Back-port of 5e24267e7d045ab7cf70b17dd3f927667d90476c for 3.5.3.
Conflicts resolved in:
	libpromises/Makefile.am
	libpromises/processes_select.c
Merge pull request #1132 from ediosyncratic/RM3472-solaris-compile-fix

3.5.x (RM #3472): Fix compilation on Solaris 11.