INSTALL 56 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289
  1. OPENSSL INSTALLATION
  2. --------------------
  3. This document describes installation on all supported operating
  4. systems (the Unix/Linux family (which includes Mac OS/X), OpenVMS,
  5. and Windows).
  6. To install OpenSSL, you will need:
  7. * A make implementation
  8. * Perl 5 with core modules (please read NOTES.PERL)
  9. * The perl module Text::Template (please read NOTES.PERL)
  10. * an ANSI C compiler
  11. * a development environment in the form of development libraries and C
  12. header files
  13. * a supported operating system
  14. For additional platform specific requirements, solutions to specific
  15. issues and other details, please read one of these:
  16. * NOTES.UNIX (any supported Unix like system)
  17. * NOTES.VMS (OpenVMS)
  18. * NOTES.WIN (any supported Windows)
  19. * NOTES.DJGPP (DOS platform with DJGPP)
  20. * NOTES.ANDROID (obviously Android [NDK])
  21. Notational conventions in this document
  22. ---------------------------------------
  23. Throughout this document, we use the following conventions in command
  24. examples:
  25. $ command Any line starting with a dollar sign
  26. ($) is a command line.
  27. { word1 | word2 | word3 } This denotes a mandatory choice, to be
  28. replaced with one of the given words.
  29. A simple example would be this:
  30. $ echo { FOO | BAR | COOKIE }
  31. which is to be understood as one of
  32. these:
  33. $ echo FOO
  34. - or -
  35. $ echo BAR
  36. - or -
  37. $ echo COOKIE
  38. [ word1 | word2 | word3 ] Similar to { word1 | word2 | word3 }
  39. except it's optional to give any of
  40. those. In addition to the examples
  41. above, this would also be valid:
  42. $ echo
  43. {{ target }} This denotes a mandatory word or
  44. sequence of words of some sort. A
  45. simple example would be this:
  46. $ type {{ filename }}
  47. which is to be understood to use the
  48. command 'type' on some file name
  49. determined by the user.
  50. [[ options ]] Similar to {{ target }}, but is
  51. optional.
  52. Note that the notation assumes spaces around {, }, [, ], {{, }} and
  53. [[, ]]. This is to differentiate from OpenVMS directory
  54. specifications, which also use [ and ], but without spaces.
  55. Quick Start
  56. -----------
  57. If you want to just get on with it, do:
  58. on Unix (again, this includes Mac OS/X):
  59. $ ./config
  60. $ make
  61. $ make test
  62. $ make install
  63. on OpenVMS:
  64. $ @config
  65. $ mms
  66. $ mms test
  67. $ mms install
  68. on Windows (only pick one of the targets for configuration):
  69. $ perl Configure { VC-WIN32 | VC-WIN64A | VC-WIN64I | VC-CE }
  70. $ nmake
  71. $ nmake test
  72. $ nmake install
  73. Note that in order to perform the install step above you need to have
  74. appropriate permissions to write to the installation directory.
  75. If any of these steps fails, see section Installation in Detail below.
  76. This will build and install OpenSSL in the default location, which is:
  77. Unix: normal installation directories under /usr/local
  78. OpenVMS: SYS$COMMON:[OPENSSL]
  79. Windows: C:\Program Files\OpenSSL or C:\Program Files (x86)\OpenSSL
  80. The installation directory should be appropriately protected to ensure
  81. unprivileged users cannot make changes to OpenSSL binaries or files, or install
  82. engines. If you already have a pre-installed version of OpenSSL as part of
  83. your Operating System it is recommended that you do not overwrite the system
  84. version and instead install to somewhere else.
  85. If you want to install it anywhere else, run config like this (the options
  86. --prefix and --openssldir are explained further down, and the values shown
  87. here are mere examples):
  88. On Unix:
  89. $ ./config --prefix=/opt/openssl --openssldir=/usr/local/ssl
  90. On OpenVMS:
  91. $ @config --prefix=PROGRAM:[INSTALLS] --openssldir=SYS$MANAGER:[OPENSSL]
  92. (Note: if you do add options to the configuration command, please make sure
  93. you've read more than just this Quick Start, such as relevant NOTES.* files,
  94. the options outline below, as configuration options may change the outcome
  95. in otherwise unexpected ways)
  96. Configuration Options
  97. ---------------------
  98. There are several options to ./config (or ./Configure) to customize
  99. the build (note that for Windows, the defaults for --prefix and
  100. --openssldir depend in what configuration is used and what Windows
  101. implementation OpenSSL is built on. More notes on this in NOTES.WIN):
  102. --api=x.y.z
  103. Don't build with support for deprecated APIs below the
  104. specified version number. For example "--api=1.1.0" will
  105. remove support for all APIS that were deprecated in OpenSSL
  106. version 1.1.0 or below. This is a rather specialized option
  107. for developers. If you just intend to remove all deprecated
  108. APIs entirely (up to the current version), it is easier
  109. to add the 'no-deprecated' option instead (see below).
  110. --cross-compile-prefix=PREFIX
  111. The PREFIX to include in front of commands for your
  112. toolchain. It's likely to have to end with dash, e.g.
  113. a-b-c- would invoke GNU compiler as a-b-c-gcc, etc.
  114. Unfortunately cross-compiling is too case-specific to
  115. put together one-size-fits-all instructions. You might
  116. have to pass more flags or set up environment variables
  117. to actually make it work. Android and iOS cases are
  118. discussed in corresponding Configurations/15-*.conf
  119. files. But there are cases when this option alone is
  120. sufficient. For example to build the mingw64 target on
  121. Linux "--cross-compile-prefix=x86_64-w64-mingw32-"
  122. works. Naturally provided that mingw packages are
  123. installed. Today Debian and Ubuntu users have option to
  124. install a number of prepackaged cross-compilers along
  125. with corresponding run-time and development packages for
  126. "alien" hardware. To give another example
  127. "--cross-compile-prefix=mipsel-linux-gnu-" suffices
  128. in such case. Needless to mention that you have to
  129. invoke ./Configure, not ./config, and pass your target
  130. name explicitly. Also, note that --openssldir refers
  131. to target's file system, not one you are building on.
  132. --debug
  133. Build OpenSSL with debugging symbols and zero optimization
  134. level.
  135. --libdir=DIR
  136. The name of the directory under the top of the installation
  137. directory tree (see the --prefix option) where libraries will
  138. be installed. By default this is "lib". Note that on Windows
  139. only ".lib" files will be stored in this location. dll files
  140. will always be installed to the "bin" directory.
  141. --openssldir=DIR
  142. Directory for OpenSSL configuration files, and also the
  143. default certificate and key store. Defaults are:
  144. Unix: /usr/local/ssl
  145. Windows: C:\Program Files\Common Files\SSL
  146. or C:\Program Files (x86)\Common Files\SSL
  147. OpenVMS: SYS$COMMON:[OPENSSL-COMMON]
  148. --prefix=DIR
  149. The top of the installation directory tree. Defaults are:
  150. Unix: /usr/local
  151. Windows: C:\Program Files\OpenSSL
  152. or C:\Program Files (x86)\OpenSSL
  153. OpenVMS: SYS$COMMON:[OPENSSL]
  154. --release
  155. Build OpenSSL without debugging symbols. This is the default.
  156. --strict-warnings
  157. This is a developer flag that switches on various compiler
  158. options recommended for OpenSSL development. It only works
  159. when using gcc or clang as the compiler. If you are
  160. developing a patch for OpenSSL then it is recommended that
  161. you use this option where possible.
  162. --with-zlib-include=DIR
  163. The directory for the location of the zlib include file. This
  164. option is only necessary if enable-zlib (see below) is used
  165. and the include file is not already on the system include
  166. path.
  167. --with-zlib-lib=LIB
  168. On Unix: this is the directory containing the zlib library.
  169. If not provided the system library path will be used.
  170. On Windows: this is the filename of the zlib library (with or
  171. without a path). This flag must be provided if the
  172. zlib-dynamic option is not also used. If zlib-dynamic is used
  173. then this flag is optional and a default value ("ZLIB1") is
  174. used if not provided.
  175. On VMS: this is the filename of the zlib library (with or
  176. without a path). This flag is optional and if not provided
  177. then "GNV$LIBZSHR", "GNV$LIBZSHR32" or "GNV$LIBZSHR64" is
  178. used by default depending on the pointer size chosen.
  179. --with-rand-seed=seed1[,seed2,...]
  180. A comma separated list of seeding methods which will be tried
  181. by OpenSSL in order to obtain random input (a.k.a "entropy")
  182. for seeding its cryptographically secure random number
  183. generator (CSPRNG). The current seeding methods are:
  184. os: Use a trusted operating system entropy source.
  185. This is the default method if such an entropy
  186. source exists.
  187. getrandom: Use the L<getrandom(2)> or equivalent system
  188. call.
  189. devrandom: Use the first device from the DEVRANDOM list
  190. which can be opened to read random bytes. The
  191. DEVRANDOM preprocessor constant expands to
  192. "/dev/urandom","/dev/random","/dev/srandom" on
  193. most unix-ish operating systems.
  194. egd: Check for an entropy generating daemon.
  195. rdcpu: Use the RDSEED or RDRAND command if provided by
  196. the CPU.
  197. librandom: Use librandom (not implemented yet).
  198. none: Disable automatic seeding. This is the default
  199. on some operating systems where no suitable
  200. entropy source exists, or no support for it is
  201. implemented yet.
  202. For more information, see the section 'Note on random number
  203. generation' at the end of this document.
  204. no-afalgeng
  205. Don't build the AFALG engine. This option will be forced if
  206. on a platform that does not support AFALG.
  207. enable-asan
  208. Build with the Address sanitiser. This is a developer option
  209. only. It may not work on all platforms and should never be
  210. used in production environments. It will only work when used
  211. with gcc or clang and should be used in conjunction with the
  212. no-shared option.
  213. no-asm
  214. Do not use assembler code. This should be viewed as
  215. debugging/trouble-shooting option rather than production.
  216. On some platforms a small amount of assembler code may
  217. still be used even with this option.
  218. no-async
  219. Do not build support for async operations.
  220. no-autoalginit
  221. Don't automatically load all supported ciphers and digests.
  222. Typically OpenSSL will make available all of its supported
  223. ciphers and digests. For a statically linked application this
  224. may be undesirable if small executable size is an objective.
  225. This only affects libcrypto. Ciphers and digests will have to
  226. be loaded manually using EVP_add_cipher() and
  227. EVP_add_digest() if this option is used. This option will
  228. force a non-shared build.
  229. no-autoerrinit
  230. Don't automatically load all libcrypto/libssl error strings.
  231. Typically OpenSSL will automatically load human readable
  232. error strings. For a statically linked application this may
  233. be undesirable if small executable size is an objective.
  234. no-autoload-config
  235. Don't automatically load the default openssl.cnf file.
  236. Typically OpenSSL will automatically load a system config
  237. file which configures default ssl options.
  238. enable-buildtest-c++
  239. While testing, generate C++ buildtest files that
  240. simply check that the public OpenSSL header files
  241. are usable standalone with C++.
  242. Enabling this option demands extra care. For any
  243. compiler flag given directly as configuration
  244. option, you must ensure that it's valid for both
  245. the C and the C++ compiler. If not, the C++ build
  246. test will most likely break. As an alternative,
  247. you can use the language specific variables, CFLAGS
  248. and CXXFLAGS.
  249. no-capieng
  250. Don't build the CAPI engine. This option will be forced if
  251. on a platform that does not support CAPI.
  252. no-cms
  253. Don't build support for CMS features
  254. no-comp
  255. Don't build support for SSL/TLS compression. If this option
  256. is left enabled (the default), then compression will only
  257. work if the zlib or zlib-dynamic options are also chosen.
  258. enable-crypto-mdebug
  259. Build support for debugging memory allocated via
  260. OPENSSL_malloc() or OPENSSL_zalloc().
  261. enable-crypto-mdebug-backtrace
  262. As for crypto-mdebug, but additionally provide backtrace
  263. information for allocated memory.
  264. TO BE USED WITH CARE: this uses GNU C functionality, and
  265. is therefore not usable for non-GNU config targets. If
  266. your build complains about the use of '-rdynamic' or the
  267. lack of header file execinfo.h, this option is not for you.
  268. ALSO NOTE that even though execinfo.h is available on your
  269. system (through Gnulib), the functions might just be stubs
  270. that do nothing.
  271. no-ct
  272. Don't build support for Certificate Transparency.
  273. no-deprecated
  274. Don't build with support for any deprecated APIs. This is the
  275. same as using "--api" and supplying the latest version
  276. number.
  277. no-dgram
  278. Don't build support for datagram based BIOs. Selecting this
  279. option will also force the disabling of DTLS.
  280. no-dso
  281. Don't build support for loading Dynamic Shared Objects.
  282. enable-devcryptoeng
  283. Build the /dev/crypto engine. It is automatically selected
  284. on BSD implementations, in which case it can be disabled with
  285. no-devcryptoeng.
  286. no-dynamic-engine
  287. Don't build the dynamically loaded engines. This only has an
  288. effect in a "shared" build
  289. no-ec
  290. Don't build support for Elliptic Curves.
  291. no-ec2m
  292. Don't build support for binary Elliptic Curves
  293. enable-ec_nistp_64_gcc_128
  294. Enable support for optimised implementations of some commonly
  295. used NIST elliptic curves.
  296. This is only supported on platforms:
  297. - with little-endian storage of non-byte types
  298. - that tolerate misaligned memory references
  299. - where the compiler:
  300. - supports the non-standard type __uint128_t
  301. - defines the built-in macro __SIZEOF_INT128__
  302. enable-egd
  303. Build support for gathering entropy from EGD (Entropy
  304. Gathering Daemon).
  305. no-engine
  306. Don't build support for loading engines.
  307. no-err
  308. Don't compile in any error strings.
  309. enable-external-tests
  310. Enable building of integration with external test suites.
  311. This is a developer option and may not work on all platforms.
  312. The only supported external test suite at the current time is
  313. the BoringSSL test suite. See the file test/README.external
  314. for further details.
  315. no-filenames
  316. Don't compile in filename and line number information (e.g.
  317. for errors and memory allocation).
  318. enable-fuzz-libfuzzer, enable-fuzz-afl
  319. Build with support for fuzzing using either libfuzzer or AFL.
  320. These are developer options only. They may not work on all
  321. platforms and should never be used in production environments.
  322. See the file fuzz/README.md for further details.
  323. no-gost
  324. Don't build support for GOST based ciphersuites. Note that
  325. if this feature is enabled then GOST ciphersuites are only
  326. available if the GOST algorithms are also available through
  327. loading an externally supplied engine.
  328. no-hw-padlock
  329. Don't build the padlock engine.
  330. no-makedepend
  331. Don't generate dependencies.
  332. no-multiblock
  333. Don't build support for writing multiple records in one
  334. go in libssl (Note: this is a different capability to the
  335. pipelining functionality).
  336. no-nextprotoneg
  337. Don't build support for the NPN TLS extension.
  338. no-ocsp
  339. Don't build support for OCSP.
  340. no-pic
  341. Don't build with support for Position Independent Code.
  342. no-pinshared By default OpenSSL will attempt to stay in memory until the
  343. process exits. This is so that libcrypto and libssl can be
  344. properly cleaned up automatically via an "atexit()" handler.
  345. The handler is registered by libcrypto and cleans up both
  346. libraries. On some platforms the atexit() handler will run on
  347. unload of libcrypto (if it has been dynamically loaded)
  348. rather than at process exit. This option can be used to stop
  349. OpenSSL from attempting to stay in memory until the process
  350. exits. This could lead to crashes if either libcrypto or
  351. libssl have already been unloaded at the point
  352. that the atexit handler is invoked, e.g. on a platform which
  353. calls atexit() on unload of the library, and libssl is
  354. unloaded before libcrypto then a crash is likely to happen.
  355. Applications can suppress running of the atexit() handler at
  356. run time by using the OPENSSL_INIT_NO_ATEXIT option to
  357. OPENSSL_init_crypto(). See the man page for it for further
  358. details.
  359. no-posix-io
  360. Don't use POSIX IO capabilities.
  361. no-psk
  362. Don't build support for Pre-Shared Key based ciphersuites.
  363. no-rdrand
  364. Don't use hardware RDRAND capabilities.
  365. no-rfc3779
  366. Don't build support for RFC3779 ("X.509 Extensions for IP
  367. Addresses and AS Identifiers")
  368. sctp
  369. Build support for SCTP
  370. no-shared
  371. Do not create shared libraries, only static ones. See "Note
  372. on shared libraries" below.
  373. no-sock
  374. Don't build support for socket BIOs
  375. no-srp
  376. Don't build support for SRP or SRP based ciphersuites.
  377. no-srtp
  378. Don't build SRTP support
  379. no-sse2
  380. Exclude SSE2 code paths from 32-bit x86 assembly modules.
  381. Normally SSE2 extension is detected at run-time, but the
  382. decision whether or not the machine code will be executed
  383. is taken solely on CPU capability vector. This means that
  384. if you happen to run OS kernel which does not support SSE2
  385. extension on Intel P4 processor, then your application
  386. might be exposed to "illegal instruction" exception.
  387. There might be a way to enable support in kernel, e.g.
  388. FreeBSD kernel can be compiled with CPU_ENABLE_SSE, and
  389. there is a way to disengage SSE2 code paths upon application
  390. start-up, but if you aim for wider "audience" running
  391. such kernel, consider no-sse2. Both the 386 and
  392. no-asm options imply no-sse2.
  393. enable-ssl-trace
  394. Build with the SSL Trace capabilities (adds the "-trace"
  395. option to s_client and s_server).
  396. no-static-engine
  397. Don't build the statically linked engines. This only
  398. has an impact when not built "shared".
  399. no-stdio
  400. Don't use anything from the C header file "stdio.h" that
  401. makes use of the "FILE" type. Only libcrypto and libssl can
  402. be built in this way. Using this option will suppress
  403. building the command line applications. Additionally since
  404. the OpenSSL tests also use the command line applications the
  405. tests will also be skipped.
  406. no-tests
  407. Don't build test programs or run any test.
  408. no-threads
  409. Don't try to build with support for multi-threaded
  410. applications.
  411. threads
  412. Build with support for multi-threaded applications. Most
  413. platforms will enable this by default. However if on a
  414. platform where this is not the case then this will usually
  415. require additional system-dependent options! See "Note on
  416. multi-threading" below.
  417. no-ts
  418. Don't build Time Stamping Authority support.
  419. enable-ubsan
  420. Build with the Undefined Behaviour sanitiser. This is a
  421. developer option only. It may not work on all platforms and
  422. should never be used in production environments. It will only
  423. work when used with gcc or clang and should be used in
  424. conjunction with the "-DPEDANTIC" option (or the
  425. --strict-warnings option).
  426. no-ui-console
  427. Don't build with the "UI" console method (i.e. the "UI"
  428. method that enables text based console prompts).
  429. enable-unit-test
  430. Enable additional unit test APIs. This should not typically
  431. be used in production deployments.
  432. enable-weak-ssl-ciphers
  433. Build support for SSL/TLS ciphers that are considered "weak"
  434. (e.g. RC4 based ciphersuites).
  435. zlib
  436. Build with support for zlib compression/decompression.
  437. zlib-dynamic
  438. Like "zlib", but has OpenSSL load the zlib library
  439. dynamically when needed. This is only supported on systems
  440. where loading of shared libraries is supported.
  441. 386
  442. In 32-bit x86 builds, when generating assembly modules,
  443. use the 80386 instruction set only (the default x86 code
  444. is more efficient, but requires at least a 486). Note:
  445. This doesn't affect code generated by compiler, you're
  446. likely to complement configuration command line with
  447. suitable compiler-specific option.
  448. no-<prot>
  449. Don't build support for negotiating the specified SSL/TLS
  450. protocol (one of ssl, ssl3, tls, tls1, tls1_1, tls1_2,
  451. tls1_3, dtls, dtls1 or dtls1_2). If "no-tls" is selected then
  452. all of tls1, tls1_1, tls1_2 and tls1_3 are disabled.
  453. Similarly "no-dtls" will disable dtls1 and dtls1_2. The
  454. "no-ssl" option is synonymous with "no-ssl3". Note this only
  455. affects version negotiation. OpenSSL will still provide the
  456. methods for applications to explicitly select the individual
  457. protocol versions.
  458. no-<prot>-method
  459. As for no-<prot> but in addition do not build the methods for
  460. applications to explicitly select individual protocol
  461. versions. Note that there is no "no-tls1_3-method" option
  462. because there is no application method for TLSv1.3. Using
  463. individual protocol methods directly is deprecated.
  464. Applications should use TLS_method() instead.
  465. enable-<alg>
  466. Build with support for the specified algorithm, where <alg>
  467. is one of: md2 or rc5.
  468. no-<alg>
  469. Build without support for the specified algorithm, where
  470. <alg> is one of: aria, bf, blake2, camellia, cast, chacha,
  471. cmac, des, dh, dsa, ecdh, ecdsa, idea, md4, mdc2, ocb,
  472. poly1305, rc2, rc4, rmd160, scrypt, seed, siphash, sm2, sm3,
  473. sm4 or whirlpool. The "ripemd" algorithm is deprecated and
  474. if used is synonymous with rmd160.
  475. -Dxxx, -Ixxx, -Wp, -lxxx, -Lxxx, -Wl, -rpath, -R, -framework, -static
  476. These system specific options will be recognised and
  477. passed through to the compiler to allow you to define
  478. preprocessor symbols, specify additional libraries, library
  479. directories or other compiler options. It might be worth
  480. noting that some compilers generate code specifically for
  481. processor the compiler currently executes on. This is not
  482. necessarily what you might have in mind, since it might be
  483. unsuitable for execution on other, typically older,
  484. processor. Consult your compiler documentation.
  485. Take note of the VAR=value documentation below and how
  486. these flags interact with those variables.
  487. -xxx, +xxx, /xxx
  488. Additional options that are not otherwise recognised are
  489. passed through as they are to the compiler as well.
  490. Unix-style options beginning with a '-' or '+' and
  491. Windows-style options beginning with a '/' are recognized.
  492. Again, consult your compiler documentation.
  493. If the option contains arguments separated by spaces,
  494. then the URL-style notation %20 can be used for the space
  495. character in order to avoid having to quote the option.
  496. For example, -opt%20arg gets expanded to -opt arg.
  497. In fact, any ASCII character can be encoded as %xx using its
  498. hexadecimal encoding.
  499. Take note of the VAR=value documentation below and how
  500. these flags interact with those variables.
  501. VAR=value
  502. Assignment of environment variable for Configure. These
  503. work just like normal environment variable assignments,
  504. but are supported on all platforms and are confined to
  505. the configuration scripts only. These assignments override
  506. the corresponding value in the inherited environment, if
  507. there is one.
  508. The following variables are used as "make variables" and
  509. can be used as an alternative to giving preprocessor,
  510. compiler and linker options directly as configuration.
  511. The following variables are supported:
  512. AR The static library archiver.
  513. ARFLAGS Flags for the static library archiver.
  514. AS The assembler compiler.
  515. ASFLAGS Flags for the assembler compiler.
  516. CC The C compiler.
  517. CFLAGS Flags for the C compiler.
  518. CXX The C++ compiler.
  519. CXXFLAGS Flags for the C++ compiler.
  520. CPP The C/C++ preprocessor.
  521. CPPFLAGS Flags for the C/C++ preprocessor.
  522. CPPDEFINES List of CPP macro definitions, separated
  523. by a platform specific character (':' or
  524. space for Unix, ';' for Windows, ',' for
  525. VMS). This can be used instead of using
  526. -D (or what corresponds to that on your
  527. compiler) in CPPFLAGS.
  528. CPPINCLUDES List of CPP inclusion directories, separated
  529. the same way as for CPPDEFINES. This can
  530. be used instead of -I (or what corresponds
  531. to that on your compiler) in CPPFLAGS.
  532. HASHBANGPERL Perl invocation to be inserted after '#!'
  533. in public perl scripts (only relevant on
  534. Unix).
  535. LD The program linker (not used on Unix, $(CC)
  536. is used there).
  537. LDFLAGS Flags for the shared library, DSO and
  538. program linker.
  539. LDLIBS Extra libraries to use when linking.
  540. Takes the form of a space separated list
  541. of library specifications on Unix and
  542. Windows, and as a comma separated list of
  543. libraries on VMS.
  544. RANLIB The library archive indexer.
  545. RC The Windows resource compiler.
  546. RCFLAGS Flags for the Windows resource compiler.
  547. RM The command to remove files and directories.
  548. These cannot be mixed with compiling / linking flags given
  549. on the command line. In other words, something like this
  550. isn't permitted.
  551. ./config -DFOO CPPFLAGS=-DBAR -DCOOKIE
  552. Backward compatibility note:
  553. To be compatible with older configuration scripts, the
  554. environment variables are ignored if compiling / linking
  555. flags are given on the command line, except for these:
  556. AR, CC, CXX, CROSS_COMPILE, HASHBANGPERL, PERL, RANLIB, RC
  557. and WINDRES
  558. For example, the following command will not see -DBAR:
  559. CPPFLAGS=-DBAR ./config -DCOOKIE
  560. However, the following will see both set variables:
  561. CC=gcc CROSS_COMPILE=x86_64-w64-mingw32- \
  562. ./config -DCOOKIE
  563. If CC is set, it is advisable to also set CXX to ensure
  564. both C and C++ compilers are in the same "family". This
  565. becomes relevant with 'enable-external-tests' and
  566. 'enable-buildtest-c++'.
  567. reconf
  568. reconfigure
  569. Reconfigure from earlier data. This fetches the previous
  570. command line options and environment from data saved in
  571. "configdata.pm", and runs the configuration process again,
  572. using these options and environment.
  573. Note: NO other option is permitted together with "reconf".
  574. This means that you also MUST use "./Configure" (or
  575. what corresponds to that on non-Unix platforms) directly
  576. to invoke this option.
  577. Note: The original configuration saves away values for ALL
  578. environment variables that were used, and if they weren't
  579. defined, they are still saved away with information that
  580. they weren't originally defined. This information takes
  581. precedence over environment variables that are defined
  582. when reconfiguring.
  583. Displaying configuration data
  584. -----------------------------
  585. The configuration script itself will say very little, and finishes by
  586. creating "configdata.pm". This perl module can be loaded by other scripts
  587. to find all the configuration data, and it can also be used as a script to
  588. display all sorts of configuration data in a human readable form.
  589. For more information, please do:
  590. $ ./configdata.pm --help # Unix
  591. or
  592. $ perl configdata.pm --help # Windows and VMS
  593. Installation in Detail
  594. ----------------------
  595. 1a. Configure OpenSSL for your operation system automatically:
  596. NOTE: This is not available on Windows.
  597. $ ./config [[ options ]] # Unix
  598. or
  599. $ @config [[ options ]] ! OpenVMS
  600. For the remainder of this text, the Unix form will be used in all
  601. examples, please use the appropriate form for your platform.
  602. This guesses at your operating system (and compiler, if necessary) and
  603. configures OpenSSL based on this guess. Run ./config -t to see
  604. if it guessed correctly. If you want to use a different compiler, you
  605. are cross-compiling for another platform, or the ./config guess was
  606. wrong for other reasons, go to step 1b. Otherwise go to step 2.
  607. On some systems, you can include debugging information as follows:
  608. $ ./config -d [[ options ]]
  609. 1b. Configure OpenSSL for your operating system manually
  610. OpenSSL knows about a range of different operating system, hardware and
  611. compiler combinations. To see the ones it knows about, run
  612. $ ./Configure # Unix
  613. or
  614. $ perl Configure # All other platforms
  615. For the remainder of this text, the Unix form will be used in all
  616. examples, please use the appropriate form for your platform.
  617. Pick a suitable name from the list that matches your system. For most
  618. operating systems there is a choice between using "cc" or "gcc". When
  619. you have identified your system (and if necessary compiler) use this name
  620. as the argument to Configure. For example, a "linux-elf" user would
  621. run:
  622. $ ./Configure linux-elf [[ options ]]
  623. If your system isn't listed, you will have to create a configuration
  624. file named Configurations/{{ something }}.conf and add the correct
  625. configuration for your system. See the available configs as examples
  626. and read Configurations/README and Configurations/README.design for
  627. more information.
  628. The generic configurations "cc" or "gcc" should usually work on 32 bit
  629. Unix-like systems.
  630. Configure creates a build file ("Makefile" on Unix, "makefile" on Windows
  631. and "descrip.mms" on OpenVMS) from a suitable template in Configurations,
  632. and defines various macros in include/openssl/opensslconf.h (generated from
  633. include/openssl/opensslconf.h.in).
  634. 1c. Configure OpenSSL for building outside of the source tree.
  635. OpenSSL can be configured to build in a build directory separate from
  636. the directory with the source code. It's done by placing yourself in
  637. some other directory and invoking the configuration commands from
  638. there.
  639. Unix example:
  640. $ mkdir /var/tmp/openssl-build
  641. $ cd /var/tmp/openssl-build
  642. $ /PATH/TO/OPENSSL/SOURCE/config [[ options ]]
  643. or
  644. $ /PATH/TO/OPENSSL/SOURCE/Configure {{ target }} [[ options ]]
  645. OpenVMS example:
  646. $ set default sys$login:
  647. $ create/dir [.tmp.openssl-build]
  648. $ set default [.tmp.openssl-build]
  649. $ @[PATH.TO.OPENSSL.SOURCE]config [[ options ]]
  650. or
  651. $ @[PATH.TO.OPENSSL.SOURCE]Configure {{ target }} [[ options ]]
  652. Windows example:
  653. $ C:
  654. $ mkdir \temp-openssl
  655. $ cd \temp-openssl
  656. $ perl d:\PATH\TO\OPENSSL\SOURCE\Configure {{ target }} [[ options ]]
  657. Paths can be relative just as well as absolute. Configure will
  658. do its best to translate them to relative paths whenever possible.
  659. 2. Build OpenSSL by running:
  660. $ make # Unix
  661. $ mms ! (or mmk) OpenVMS
  662. $ nmake # Windows
  663. This will build the OpenSSL libraries (libcrypto.a and libssl.a on
  664. Unix, corresponding on other platforms) and the OpenSSL binary
  665. ("openssl"). The libraries will be built in the top-level directory,
  666. and the binary will be in the "apps" subdirectory.
  667. Troubleshooting:
  668. If the build fails, look at the output. There may be reasons
  669. for the failure that aren't problems in OpenSSL itself (like
  670. missing standard headers).
  671. If the build succeeded previously, but fails after a source or
  672. configuration change, it might be helpful to clean the build tree
  673. before attempting another build. Use this command:
  674. $ make clean # Unix
  675. $ mms clean ! (or mmk) OpenVMS
  676. $ nmake clean # Windows
  677. Assembler error messages can sometimes be sidestepped by using the
  678. "no-asm" configuration option.
  679. Compiling parts of OpenSSL with gcc and others with the system
  680. compiler will result in unresolved symbols on some systems.
  681. If you are still having problems you can get help by sending an email
  682. to the openssl-users email list (see
  683. https://www.openssl.org/community/mailinglists.html for details). If
  684. it is a bug with OpenSSL itself, please open an issue on GitHub, at
  685. https://github.com/openssl/openssl/issues. Please review the existing
  686. ones first; maybe the bug was already reported or has already been
  687. fixed.
  688. 3. After a successful build, the libraries should be tested. Run:
  689. $ make test # Unix
  690. $ mms test ! OpenVMS
  691. $ nmake test # Windows
  692. NOTE: you MUST run the tests from an unprivileged account (or
  693. disable your privileges temporarily if your platform allows it).
  694. If some tests fail, look at the output. There may be reasons for
  695. the failure that isn't a problem in OpenSSL itself (like a
  696. malfunction with Perl). You may want increased verbosity, that
  697. can be accomplished like this:
  698. $ make VERBOSE=1 test # Unix
  699. $ mms /macro=(VERBOSE=1) test ! OpenVMS
  700. $ nmake VERBOSE=1 test # Windows
  701. If you want to run just one or a few specific tests, you can use
  702. the make variable TESTS to specify them, like this:
  703. $ make TESTS='test_rsa test_dsa' test # Unix
  704. $ mms/macro="TESTS=test_rsa test_dsa" test ! OpenVMS
  705. $ nmake TESTS='test_rsa test_dsa' test # Windows
  706. And of course, you can combine (Unix example shown):
  707. $ make VERBOSE=1 TESTS='test_rsa test_dsa' test
  708. You can find the list of available tests like this:
  709. $ make list-tests # Unix
  710. $ mms list-tests ! OpenVMS
  711. $ nmake list-tests # Windows
  712. Have a look at the manual for the perl module Test::Harness to
  713. see what other HARNESS_* variables there are.
  714. If you find a problem with OpenSSL itself, try removing any
  715. compiler optimization flags from the CFLAGS line in Makefile and
  716. run "make clean; make" or corresponding.
  717. To report a bug please open an issue on GitHub, at
  718. https://github.com/openssl/openssl/issues.
  719. For more details on how the make variables TESTS can be used,
  720. see section TESTS in Detail below.
  721. 4. If everything tests ok, install OpenSSL with
  722. $ make install # Unix
  723. $ mms install ! OpenVMS
  724. $ nmake install # Windows
  725. Note that in order to perform the install step above you need to have
  726. appropriate permissions to write to the installation directory.
  727. The above commands will install all the software components in this
  728. directory tree under PREFIX (the directory given with --prefix or its
  729. default):
  730. Unix:
  731. bin/ Contains the openssl binary and a few other
  732. utility scripts.
  733. include/openssl
  734. Contains the header files needed if you want
  735. to build your own programs that use libcrypto
  736. or libssl.
  737. lib Contains the OpenSSL library files.
  738. lib/engines Contains the OpenSSL dynamically loadable engines.
  739. share/man/man1 Contains the OpenSSL command line man-pages.
  740. share/man/man3 Contains the OpenSSL library calls man-pages.
  741. share/man/man5 Contains the OpenSSL configuration format man-pages.
  742. share/man/man7 Contains the OpenSSL other misc man-pages.
  743. share/doc/openssl/html/man1
  744. share/doc/openssl/html/man3
  745. share/doc/openssl/html/man5
  746. share/doc/openssl/html/man7
  747. Contains the HTML rendition of the man-pages.
  748. OpenVMS ('arch' is replaced with the architecture name, "ALPHA"
  749. or "IA64", 'sover' is replaced with the shared library version
  750. (0101 for 1.1.x), and 'pz' is replaced with the pointer size
  751. OpenSSL was built with):
  752. [.EXE.'arch'] Contains the openssl binary.
  753. [.EXE] Contains a few utility scripts.
  754. [.include.openssl]
  755. Contains the header files needed if you want
  756. to build your own programs that use libcrypto
  757. or libssl.
  758. [.LIB.'arch'] Contains the OpenSSL library files.
  759. [.ENGINES'sover''pz'.'arch']
  760. Contains the OpenSSL dynamically loadable engines.
  761. [.SYS$STARTUP] Contains startup, login and shutdown scripts.
  762. These define appropriate logical names and
  763. command symbols.
  764. [.SYSTEST] Contains the installation verification procedure.
  765. [.HTML] Contains the HTML rendition of the manual pages.
  766. Additionally, install will add the following directories under
  767. OPENSSLDIR (the directory given with --openssldir or its default)
  768. for you convenience:
  769. certs Initially empty, this is the default location
  770. for certificate files.
  771. private Initially empty, this is the default location
  772. for private key files.
  773. misc Various scripts.
  774. The installation directory should be appropriately protected to ensure
  775. unprivileged users cannot make changes to OpenSSL binaries or files, or
  776. install engines. If you already have a pre-installed version of OpenSSL as
  777. part of your Operating System it is recommended that you do not overwrite
  778. the system version and instead install to somewhere else.
  779. Package builders who want to configure the library for standard
  780. locations, but have the package installed somewhere else so that
  781. it can easily be packaged, can use
  782. $ make DESTDIR=/tmp/package-root install # Unix
  783. $ mms/macro="DESTDIR=TMP:[PACKAGE-ROOT]" install ! OpenVMS
  784. The specified destination directory will be prepended to all
  785. installation target paths.
  786. Compatibility issues with previous OpenSSL versions:
  787. * COMPILING existing applications
  788. Starting with version 1.1.0, OpenSSL hides a number of structures
  789. that were previously open. This includes all internal libssl
  790. structures and a number of EVP types. Accessor functions have
  791. been added to allow controlled access to the structures' data.
  792. This means that some software needs to be rewritten to adapt to
  793. the new ways of doing things. This often amounts to allocating
  794. an instance of a structure explicitly where you could previously
  795. allocate them on the stack as automatic variables, and using the
  796. provided accessor functions where you would previously access a
  797. structure's field directly.
  798. Some APIs have changed as well. However, older APIs have been
  799. preserved when possible.
  800. Environment Variables
  801. ---------------------
  802. A number of environment variables can be used to provide additional control
  803. over the build process. Typically these should be defined prior to running
  804. config or Configure. Not all environment variables are relevant to all
  805. platforms.
  806. AR
  807. The name of the ar executable to use.
  808. BUILDFILE
  809. Use a different build file name than the platform default
  810. ("Makefile" on Unix-like platforms, "makefile" on native Windows,
  811. "descrip.mms" on OpenVMS). This requires that there is a
  812. corresponding build file template. See Configurations/README
  813. for further information.
  814. CC
  815. The compiler to use. Configure will attempt to pick a default
  816. compiler for your platform but this choice can be overridden
  817. using this variable. Set it to the compiler executable you wish
  818. to use, e.g. "gcc" or "clang".
  819. CROSS_COMPILE
  820. This environment variable has the same meaning as for the
  821. "--cross-compile-prefix" Configure flag described above. If both
  822. are set then the Configure flag takes precedence.
  823. NM
  824. The name of the nm executable to use.
  825. OPENSSL_LOCAL_CONFIG_DIR
  826. OpenSSL comes with a database of information about how it
  827. should be built on different platforms as well as build file
  828. templates for those platforms. The database is comprised of
  829. ".conf" files in the Configurations directory. The build
  830. file templates reside there as well as ".tmpl" files. See the
  831. file Configurations/README for further information about the
  832. format of ".conf" files as well as information on the ".tmpl"
  833. files.
  834. In addition to the standard ".conf" and ".tmpl" files, it is
  835. possible to create your own ".conf" and ".tmpl" files and store
  836. them locally, outside the OpenSSL source tree. This environment
  837. variable can be set to the directory where these files are held
  838. and will be considered by Configure before it looks in the
  839. standard directories.
  840. PERL
  841. The name of the Perl executable to use when building OpenSSL.
  842. This variable is used in config script only. Configure on the
  843. other hand imposes the interpreter by which it itself was
  844. executed on the whole build procedure.
  845. HASHBANGPERL
  846. The command string for the Perl executable to insert in the
  847. #! line of perl scripts that will be publicly installed.
  848. Default: /usr/bin/env perl
  849. Note: the value of this variable is added to the same scripts
  850. on all platforms, but it's only relevant on Unix-like platforms.
  851. RC
  852. The name of the rc executable to use. The default will be as
  853. defined for the target platform in the ".conf" file. If not
  854. defined then "windres" will be used. The WINDRES environment
  855. variable is synonymous to this. If both are defined then RC
  856. takes precedence.
  857. RANLIB
  858. The name of the ranlib executable to use.
  859. WINDRES
  860. See RC.
  861. Makefile targets
  862. ----------------
  863. The Configure script generates a Makefile in a format relevant to the specific
  864. platform. The Makefiles provide a number of targets that can be used. Not all
  865. targets may be available on all platforms. Only the most common targets are
  866. described here. Examine the Makefiles themselves for the full list.
  867. all
  868. The default target to build all the software components.
  869. clean
  870. Remove all build artefacts and return the directory to a "clean"
  871. state.
  872. depend
  873. Rebuild the dependencies in the Makefiles. This is a legacy
  874. option that no longer needs to be used since OpenSSL 1.1.0.
  875. install
  876. Install all OpenSSL components.
  877. install_sw
  878. Only install the OpenSSL software components.
  879. install_docs
  880. Only install the OpenSSL documentation components.
  881. install_man_docs
  882. Only install the OpenSSL man pages (Unix only).
  883. install_html_docs
  884. Only install the OpenSSL html documentation.
  885. list-tests
  886. Prints a list of all the self test names.
  887. test
  888. Build and run the OpenSSL self tests.
  889. uninstall
  890. Uninstall all OpenSSL components.
  891. reconfigure
  892. reconf
  893. Re-run the configuration process, as exactly as the last time
  894. as possible.
  895. update
  896. This is a developer option. If you are developing a patch for
  897. OpenSSL you may need to use this if you want to update
  898. automatically generated files; add new error codes or add new
  899. (or change the visibility of) public API functions. (Unix only).
  900. TESTS in Detail
  901. ---------------
  902. The make variable TESTS supports a versatile set of space separated tokens
  903. with which you can specify a set of tests to be performed. With a "current
  904. set of tests" in mind, initially being empty, here are the possible tokens:
  905. alltests The current set of tests becomes the whole set of available
  906. tests (as listed when you do 'make list-tests' or similar).
  907. xxx Adds the test 'xxx' to the current set of tests.
  908. -xxx Removes 'xxx' from the current set of tests. If this is the
  909. first token in the list, the current set of tests is first
  910. assigned the whole set of available tests, effectively making
  911. this token equivalent to TESTS="alltests -xxx".
  912. nn Adds the test group 'nn' (which is a number) to the current
  913. set of tests.
  914. -nn Removes the test group 'nn' from the current set of tests.
  915. If this is the first token in the list, the current set of
  916. tests is first assigned the whole set of available tests,
  917. effectively making this token equivalent to
  918. TESTS="alltests -xxx".
  919. Also, all tokens except for "alltests" may have wildcards, such as *.
  920. (on Unix and Windows, BSD style wildcards are supported, while on VMS,
  921. it's VMS style wildcards)
  922. Example: All tests except for the fuzz tests:
  923. $ make TESTS=-test_fuzz test
  924. or (if you want to be explicit)
  925. $ make TESTS='alltests -test_fuzz' test
  926. Example: All tests that have a name starting with "test_ssl" but not those
  927. starting with "test_ssl_":
  928. $ make TESTS='test_ssl* -test_ssl_*' test
  929. Example: Only test group 10:
  930. $ make TESTS='10'
  931. Example: All tests except the slow group (group 99):
  932. $ make TESTS='-99'
  933. Example: All tests in test groups 80 to 99 except for tests in group 90:
  934. $ make TESTS='[89]? -90'
  935. Note on multi-threading
  936. -----------------------
  937. For some systems, the OpenSSL Configure script knows what compiler options
  938. are needed to generate a library that is suitable for multi-threaded
  939. applications. On these systems, support for multi-threading is enabled
  940. by default; use the "no-threads" option to disable (this should never be
  941. necessary).
  942. On other systems, to enable support for multi-threading, you will have
  943. to specify at least two options: "threads", and a system-dependent option.
  944. (The latter is "-D_REENTRANT" on various systems.) The default in this
  945. case, obviously, is not to include support for multi-threading (but
  946. you can still use "no-threads" to suppress an annoying warning message
  947. from the Configure script.)
  948. OpenSSL provides built-in support for two threading models: pthreads (found on
  949. most UNIX/Linux systems), and Windows threads. No other threading models are
  950. supported. If your platform does not provide pthreads or Windows threads then
  951. you should Configure with the "no-threads" option.
  952. Notes on shared libraries
  953. -------------------------
  954. For most systems the OpenSSL Configure script knows what is needed to
  955. build shared libraries for libcrypto and libssl. On these systems
  956. the shared libraries will be created by default. This can be suppressed and
  957. only static libraries created by using the "no-shared" option. On systems
  958. where OpenSSL does not know how to build shared libraries the "no-shared"
  959. option will be forced and only static libraries will be created.
  960. Shared libraries are named a little differently on different platforms.
  961. One way or another, they all have the major OpenSSL version number as
  962. part of the file name, i.e. for OpenSSL 1.1.x, 1.1 is somehow part of
  963. the name.
  964. On most POSIX platforms, shared libraries are named libcrypto.so.1.1
  965. and libssl.so.1.1.
  966. on Cygwin, shared libraries are named cygcrypto-1.1.dll and cygssl-1.1.dll
  967. with import libraries libcrypto.dll.a and libssl.dll.a.
  968. On Windows build with MSVC or using MingW, shared libraries are named
  969. libcrypto-1_1.dll and libssl-1_1.dll for 32-bit Windows, libcrypto-1_1-x64.dll
  970. and libssl-1_1-x64.dll for 64-bit x86_64 Windows, and libcrypto-1_1-ia64.dll
  971. and libssl-1_1-ia64.dll for IA64 Windows. With MSVC, the import libraries
  972. are named libcrypto.lib and libssl.lib, while with MingW, they are named
  973. libcrypto.dll.a and libssl.dll.a.
  974. On VMS, shareable images (VMS speak for shared libraries) are named
  975. ossl$libcrypto0101_shr.exe and ossl$libssl0101_shr.exe. However, when
  976. OpenSSL is specifically built for 32-bit pointers, the shareable images
  977. are named ossl$libcrypto0101_shr32.exe and ossl$libssl0101_shr32.exe
  978. instead, and when built for 64-bit pointers, they are named
  979. ossl$libcrypto0101_shr64.exe and ossl$libssl0101_shr64.exe.
  980. Note on random number generation
  981. --------------------------------
  982. Availability of cryptographically secure random numbers is required for
  983. secret key generation. OpenSSL provides several options to seed the
  984. internal CSPRNG. If not properly seeded, the internal CSPRNG will refuse
  985. to deliver random bytes and a "PRNG not seeded error" will occur.
  986. The seeding method can be configured using the --with-rand-seed option,
  987. which can be used to specify a comma separated list of seed methods.
  988. However in most cases OpenSSL will choose a suitable default method,
  989. so it is not necessary to explicitly provide this option. Note also
  990. that not all methods are available on all platforms.
  991. I) On operating systems which provide a suitable randomness source (in
  992. form of a system call or system device), OpenSSL will use the optimal
  993. available method to seed the CSPRNG from the operating system's
  994. randomness sources. This corresponds to the option --with-rand-seed=os.
  995. II) On systems without such a suitable randomness source, automatic seeding
  996. and reseeding is disabled (--with-rand-seed=none) and it may be necessary
  997. to install additional support software to obtain a random seed and reseed
  998. the CSPRNG manually. Please check out the manual pages for RAND_add(),
  999. RAND_bytes(), RAND_egd(), and the FAQ for more information.