ossl-guide-migration.7ossl 103 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186
  1. .\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.42)
  2. .\"
  3. .\" Standard preamble:
  4. .\" ========================================================================
  5. .de Sp \" Vertical space (when we can't use .PP)
  6. .if t .sp .5v
  7. .if n .sp
  8. ..
  9. .de Vb \" Begin verbatim text
  10. .ft CW
  11. .nf
  12. .ne \\$1
  13. ..
  14. .de Ve \" End verbatim text
  15. .ft R
  16. .fi
  17. ..
  18. .\" Set up some character translations and predefined strings. \*(-- will
  19. .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
  20. .\" double quote, and \*(R" will give a right double quote. \*(C+ will
  21. .\" give a nicer C++. Capital omega is used to do unbreakable dashes and
  22. .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff,
  23. .\" nothing in troff, for use with C<>.
  24. .tr \(*W-
  25. .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
  26. .ie n \{\
  27. . ds -- \(*W-
  28. . ds PI pi
  29. . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
  30. . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch
  31. . ds L" ""
  32. . ds R" ""
  33. . ds C` ""
  34. . ds C' ""
  35. 'br\}
  36. .el\{\
  37. . ds -- \|\(em\|
  38. . ds PI \(*p
  39. . ds L" ``
  40. . ds R" ''
  41. . ds C`
  42. . ds C'
  43. 'br\}
  44. .\"
  45. .\" Escape single quotes in literal strings from groff's Unicode transform.
  46. .ie \n(.g .ds Aq \(aq
  47. .el .ds Aq '
  48. .\"
  49. .\" If the F register is >0, we'll generate index entries on stderr for
  50. .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
  51. .\" entries marked with X<> in POD. Of course, you'll have to process the
  52. .\" output yourself in some meaningful fashion.
  53. .\"
  54. .\" Avoid warning from groff about undefined register 'F'.
  55. .de IX
  56. ..
  57. .nr rF 0
  58. .if \n(.g .if rF .nr rF 1
  59. .if (\n(rF:(\n(.g==0)) \{\
  60. . if \nF \{\
  61. . de IX
  62. . tm Index:\\$1\t\\n%\t"\\$2"
  63. ..
  64. . if !\nF==2 \{\
  65. . nr % 0
  66. . nr F 2
  67. . \}
  68. . \}
  69. .\}
  70. .rr rF
  71. .\"
  72. .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
  73. .\" Fear. Run. Save yourself. No user-serviceable parts.
  74. . \" fudge factors for nroff and troff
  75. .if n \{\
  76. . ds #H 0
  77. . ds #V .8m
  78. . ds #F .3m
  79. . ds #[ \f1
  80. . ds #] \fP
  81. .\}
  82. .if t \{\
  83. . ds #H ((1u-(\\\\n(.fu%2u))*.13m)
  84. . ds #V .6m
  85. . ds #F 0
  86. . ds #[ \&
  87. . ds #] \&
  88. .\}
  89. . \" simple accents for nroff and troff
  90. .if n \{\
  91. . ds ' \&
  92. . ds ` \&
  93. . ds ^ \&
  94. . ds , \&
  95. . ds ~ ~
  96. . ds /
  97. .\}
  98. .if t \{\
  99. . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
  100. . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
  101. . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
  102. . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
  103. . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
  104. . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
  105. .\}
  106. . \" troff and (daisy-wheel) nroff accents
  107. .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
  108. .ds 8 \h'\*(#H'\(*b\h'-\*(#H'
  109. .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
  110. .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
  111. .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
  112. .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
  113. .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
  114. .ds ae a\h'-(\w'a'u*4/10)'e
  115. .ds Ae A\h'-(\w'A'u*4/10)'E
  116. . \" corrections for vroff
  117. .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
  118. .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
  119. . \" for low resolution devices (crt and lpr)
  120. .if \n(.H>23 .if \n(.V>19 \
  121. \{\
  122. . ds : e
  123. . ds 8 ss
  124. . ds o a
  125. . ds d- d\h'-1'\(ga
  126. . ds D- D\h'-1'\(hy
  127. . ds th \o'bp'
  128. . ds Th \o'LP'
  129. . ds ae ae
  130. . ds Ae AE
  131. .\}
  132. .rm #[ #] #H #V #F C
  133. .\" ========================================================================
  134. .\"
  135. .IX Title "OSSL-GUIDE-MIGRATION 7ossl"
  136. .TH OSSL-GUIDE-MIGRATION 7ossl "2024-09-03" "3.3.2" "OpenSSL"
  137. .\" For nroff, turn off justification. Always turn off hyphenation; it makes
  138. .\" way too many mistakes in technical documents.
  139. .if n .ad l
  140. .nh
  141. .SH "NAME"
  142. ossl\-guide\-migration, migration_guide
  143. \&\- OpenSSL Guide: Migrating from older OpenSSL versions
  144. .SH "SYNOPSIS"
  145. .IX Header "SYNOPSIS"
  146. See the individual manual pages for details.
  147. .SH "DESCRIPTION"
  148. .IX Header "DESCRIPTION"
  149. This guide details the changes required to migrate to new versions of OpenSSL.
  150. Currently this covers OpenSSL 3.0 & 3.1. For earlier versions refer to
  151. <https://github.com/openssl/openssl/blob/master/CHANGES.md>.
  152. For an overview of some of the key concepts introduced in OpenSSL 3.0 see
  153. \&\fBcrypto\fR\|(7).
  154. .SH "OPENSSL 3.1"
  155. .IX Header "OPENSSL 3.1"
  156. .SS "Main Changes from OpenSSL 3.0"
  157. .IX Subsection "Main Changes from OpenSSL 3.0"
  158. The \s-1FIPS\s0 provider in OpenSSL 3.1 includes some non-FIPS validated algorithms,
  159. consequently the property query \f(CW\*(C`fips=yes\*(C'\fR is mandatory for applications that
  160. want to operate in a \s-1FIPS\s0 approved manner. The algorithms are:
  161. .IP "Triple \s-1DES ECB\s0" 4
  162. .IX Item "Triple DES ECB"
  163. .PD 0
  164. .IP "Triple \s-1DES CBC\s0" 4
  165. .IX Item "Triple DES CBC"
  166. .IP "EdDSA" 4
  167. .IX Item "EdDSA"
  168. .PD
  169. .PP
  170. There are no other changes requiring additional migration measures since OpenSSL 3.0.
  171. .SH "OPENSSL 3.0"
  172. .IX Header "OPENSSL 3.0"
  173. .SS "Main Changes from OpenSSL 1.1.1"
  174. .IX Subsection "Main Changes from OpenSSL 1.1.1"
  175. \fIMajor Release\fR
  176. .IX Subsection "Major Release"
  177. .PP
  178. OpenSSL 3.0 is a major release and consequently any application that currently
  179. uses an older version of OpenSSL will at the very least need to be recompiled in
  180. order to work with the new version. It is the intention that the large majority
  181. of applications will work unchanged with OpenSSL 3.0 if those applications
  182. previously worked with OpenSSL 1.1.1. However this is not guaranteed and some
  183. changes may be required in some cases. Changes may also be required if
  184. applications need to take advantage of some of the new features available in
  185. OpenSSL 3.0 such as the availability of the \s-1FIPS\s0 module.
  186. .PP
  187. \fILicense Change\fR
  188. .IX Subsection "License Change"
  189. .PP
  190. In previous versions, OpenSSL was licensed under the dual OpenSSL and SSLeay
  191. licenses <https://www.openssl.org/source/license-openssl-ssleay.txt>
  192. (both licenses apply). From OpenSSL 3.0 this is replaced by the
  193. Apache License v2 <https://www.openssl.org/source/apache-license-2.0.txt>.
  194. .PP
  195. \fIProviders and \s-1FIPS\s0 support\fR
  196. .IX Subsection "Providers and FIPS support"
  197. .PP
  198. One of the key changes from OpenSSL 1.1.1 is the introduction of the Provider
  199. concept. Providers collect together and make available algorithm implementations.
  200. With OpenSSL 3.0 it is possible to specify, either programmatically or via a
  201. config file, which providers you want to use for any given application.
  202. OpenSSL 3.0 comes with 5 different providers as standard. Over time third
  203. parties may distribute additional providers that can be plugged into OpenSSL.
  204. All algorithm implementations available via providers are accessed through the
  205. \&\*(L"high level\*(R" APIs (for example those functions prefixed with \f(CW\*(C`EVP\*(C'\fR). They cannot
  206. be accessed using the \*(L"Low Level APIs\*(R".
  207. .PP
  208. One of the standard providers available is the \s-1FIPS\s0 provider. This makes
  209. available \s-1FIPS\s0 validated cryptographic algorithms.
  210. The \s-1FIPS\s0 provider is disabled by default and needs to be enabled explicitly
  211. at configuration time using the \f(CW\*(C`enable\-fips\*(C'\fR option. If it is enabled,
  212. the \s-1FIPS\s0 provider gets built and installed in addition to the other standard
  213. providers. No separate installation procedure is necessary.
  214. There is however a dedicated \f(CW\*(C`install_fips\*(C'\fR make target, which serves the
  215. special purpose of installing only the \s-1FIPS\s0 provider into an existing
  216. OpenSSL installation.
  217. .PP
  218. Not all algorithms may be available for the application at a particular moment.
  219. If the application code uses any digest or cipher algorithm via the \s-1EVP\s0 interface,
  220. the application should verify the result of the \fBEVP_EncryptInit\fR\|(3),
  221. \&\fBEVP_EncryptInit_ex\fR\|(3), and \fBEVP_DigestInit\fR\|(3) functions. In case when
  222. the requested algorithm is not available, these functions will fail.
  223. .PP
  224. See also \*(L"Legacy Algorithms\*(R" for information on the legacy provider.
  225. .PP
  226. See also \*(L"Completing the installation of the \s-1FIPS\s0 Module\*(R" and
  227. \&\*(L"Using the \s-1FIPS\s0 Module in applications\*(R".
  228. .PP
  229. \fILow Level APIs\fR
  230. .IX Subsection "Low Level APIs"
  231. .PP
  232. OpenSSL has historically provided two sets of APIs for invoking cryptographic
  233. algorithms: the \*(L"high level\*(R" APIs (such as the \f(CW\*(C`EVP\*(C'\fR APIs) and the \*(L"low level\*(R"
  234. APIs. The high level APIs are typically designed to work across all algorithm
  235. types. The \*(L"low level\*(R" APIs are targeted at a specific algorithm implementation.
  236. For example, the \s-1EVP\s0 APIs provide the functions \fBEVP_EncryptInit_ex\fR\|(3),
  237. \&\fBEVP_EncryptUpdate\fR\|(3) and \fBEVP_EncryptFinal\fR\|(3) to perform symmetric
  238. encryption. Those functions can be used with the algorithms \s-1AES, CHACHA, 3DES\s0 etc.
  239. On the other hand, to do \s-1AES\s0 encryption using the low level APIs you would have
  240. to call \s-1AES\s0 specific functions such as \fBAES_set_encrypt_key\fR\|(3),
  241. \&\fBAES_encrypt\fR\|(3), and so on. The functions for 3DES are different.
  242. Use of the low level APIs has been informally discouraged by the OpenSSL
  243. development team for a long time. However in OpenSSL 3.0 this is made more
  244. formal. All such low level APIs have been deprecated. You may still use them in
  245. your applications, but you may start to see deprecation warnings during
  246. compilation (dependent on compiler support for this). Deprecated APIs may be
  247. removed from future versions of OpenSSL so you are strongly encouraged to update
  248. your code to use the high level APIs instead.
  249. .PP
  250. This is described in more detail in \*(L"Deprecation of Low Level Functions\*(R"
  251. .PP
  252. \fILegacy Algorithms\fR
  253. .IX Subsection "Legacy Algorithms"
  254. .PP
  255. Some cryptographic algorithms such as \fB\s-1MD2\s0\fR and \fB\s-1DES\s0\fR that were available via
  256. the \s-1EVP\s0 APIs are now considered legacy and their use is strongly discouraged.
  257. These legacy \s-1EVP\s0 algorithms are still available in OpenSSL 3.0 but not by
  258. default. If you want to use them then you must load the legacy provider.
  259. This can be as simple as a config file change, or can be done programmatically.
  260. See \fBOSSL_PROVIDER\-legacy\fR\|(7) for a complete list of algorithms.
  261. Applications using the \s-1EVP\s0 APIs to access these algorithms should instead use
  262. more modern algorithms. If that is not possible then these applications
  263. should ensure that the legacy provider has been loaded. This can be achieved
  264. either programmatically or via configuration. See \fBcrypto\fR\|(7) man page for
  265. more information about providers.
  266. .PP
  267. \fIEngines and \*(L"\s-1METHOD\*(R"\s0 APIs\fR
  268. .IX Subsection "Engines and METHOD APIs"
  269. .PP
  270. The refactoring to support Providers conflicts internally with the APIs used to
  271. support engines, including the \s-1ENGINE API\s0 and any function that creates or
  272. modifies custom \*(L"\s-1METHODS\*(R"\s0 (for example \fBEVP_MD_meth_new\fR\|(3),
  273. \&\fBEVP_CIPHER_meth_new\fR\|(3), \fBEVP_PKEY_meth_new\fR\|(3), \fBRSA_meth_new\fR\|(3),
  274. \&\fBEC_KEY_METHOD_new\fR\|(3), etc.). These functions are being deprecated in
  275. OpenSSL 3.0, and users of these APIs should know that their use can likely
  276. bypass provider selection and configuration, with unintended consequences.
  277. This is particularly relevant for applications written to use the OpenSSL 3.0
  278. \&\s-1FIPS\s0 module, as detailed below. Authors and maintainers of external engines are
  279. strongly encouraged to refactor their code transforming engines into providers
  280. using the new Provider \s-1API\s0 and avoiding deprecated methods.
  281. .PP
  282. \fISupport of legacy engines\fR
  283. .IX Subsection "Support of legacy engines"
  284. .PP
  285. If openssl is not built without engine support or deprecated \s-1API\s0 support, engines
  286. will still work. However, their applicability will be limited.
  287. .PP
  288. New algorithms provided via engines will still work.
  289. .PP
  290. Engine-backed keys can be loaded via custom \fB\s-1OSSL_STORE\s0\fR implementation.
  291. In this case the \fB\s-1EVP_PKEY\s0\fR objects created via \fBENGINE_load_private_key\fR\|(3)
  292. will be considered legacy and will continue to work.
  293. .PP
  294. To ensure the future compatibility, the engines should be turned to providers.
  295. To prefer the provider-based hardware offload, you can specify the default
  296. properties to prefer your provider.
  297. .PP
  298. Setting engine-based or application-based default low-level crypto method such
  299. as \fB\s-1RSA_METHOD\s0\fR or \fB\s-1EC_KEY_METHOD\s0\fR is still possible and keys inside the
  300. default provider will use the engine-based implementation for the crypto
  301. operations. However \fB\s-1EVP_PKEY\s0\fRs created by decoding by using \fB\s-1OSSL_DECODER\s0\fR,
  302. \&\fB\s-1PEM_\s0\fR or \fBd2i_\fR APIs will be provider-based. To create a fully legacy
  303. \&\fB\s-1EVP_PKEY\s0\fRs \fBEVP_PKEY_set1_RSA\fR\|(3), \fBEVP_PKEY_set1_EC_KEY\fR\|(3) or similar
  304. functions must be used.
  305. .PP
  306. \fIVersioning Scheme\fR
  307. .IX Subsection "Versioning Scheme"
  308. .PP
  309. The OpenSSL versioning scheme has changed with the OpenSSL 3.0 release. The new
  310. versioning scheme has this format:
  311. .PP
  312. \&\s-1MAJOR.MINOR.PATCH\s0
  313. .PP
  314. For OpenSSL 1.1.1 and below, different patch levels were indicated by a letter
  315. at the end of the release version number. This will no longer be used and
  316. instead the patch level is indicated by the final number in the version. A
  317. change in the second (\s-1MINOR\s0) number indicates that new features may have been
  318. added. OpenSSL versions with the same major number are \s-1API\s0 and \s-1ABI\s0 compatible.
  319. If the major number changes then \s-1API\s0 and \s-1ABI\s0 compatibility is not guaranteed.
  320. .PP
  321. For more information, see \fBOpenSSL_version\fR\|(3).
  322. .PP
  323. \fIOther major new features\fR
  324. .IX Subsection "Other major new features"
  325. .PP
  326. Certificate Management Protocol (\s-1CMP, RFC 4210\s0)
  327. .IX Subsection "Certificate Management Protocol (CMP, RFC 4210)"
  328. .PP
  329. This also covers \s-1CRMF\s0 (\s-1RFC 4211\s0) and \s-1HTTP\s0 transfer (\s-1RFC 6712\s0)
  330. See \fBopenssl\-cmp\fR\|(1) and \fBOSSL_CMP_exec_certreq\fR\|(3) as starting points.
  331. .PP
  332. \s-1HTTP\s0(S) client
  333. .IX Subsection "HTTP(S) client"
  334. .PP
  335. A proper \s-1HTTP\s0(S) client that supports \s-1GET\s0 and \s-1POST,\s0 redirection, plain and
  336. \&\s-1ASN\s0.1\-encoded contents, proxies, and timeouts.
  337. .PP
  338. Key Derivation Function \s-1API\s0 (\s-1EVP_KDF\s0)
  339. .IX Subsection "Key Derivation Function API (EVP_KDF)"
  340. .PP
  341. This simplifies the process of adding new \s-1KDF\s0 and \s-1PRF\s0 implementations.
  342. .PP
  343. Previously \s-1KDF\s0 algorithms had been shoe-horned into using the \s-1EVP_PKEY\s0 object
  344. which was not a logical mapping.
  345. Existing applications that use \s-1KDF\s0 algorithms using \s-1EVP_PKEY\s0
  346. (scrypt, \s-1TLS1 PRF\s0 and \s-1HKDF\s0) may be slower as they use an \s-1EVP_KDF\s0 bridge
  347. internally.
  348. All new applications should use the new \s-1\fBEVP_KDF\s0\fR\|(3) interface.
  349. See also \*(L"Key Derivation Function (\s-1KDF\s0)\*(R" in \fBOSSL_PROVIDER\-default\fR\|(7) and
  350. \&\*(L"Key Derivation Function (\s-1KDF\s0)\*(R" in \s-1\fBOSSL_PROVIDER\-FIPS\s0\fR\|(7).
  351. .PP
  352. Message Authentication Code \s-1API\s0 (\s-1EVP_MAC\s0)
  353. .IX Subsection "Message Authentication Code API (EVP_MAC)"
  354. .PP
  355. This simplifies the process of adding \s-1MAC\s0 implementations.
  356. .PP
  357. This includes a generic \s-1EVP_PKEY\s0 to \s-1EVP_MAC\s0 bridge, to facilitate the continued
  358. use of MACs through raw private keys in functionality such as
  359. \&\fBEVP_DigestSign\fR\|(3) and \fBEVP_DigestVerify\fR\|(3).
  360. .PP
  361. All new applications should use the new \s-1\fBEVP_MAC\s0\fR\|(3) interface.
  362. See also \*(L"Message Authentication Code (\s-1MAC\s0)\*(R" in \fBOSSL_PROVIDER\-default\fR\|(7)
  363. and \*(L"Message Authentication Code (\s-1MAC\s0)\*(R" in \s-1\fBOSSL_PROVIDER\-FIPS\s0\fR\|(7).
  364. .PP
  365. Algorithm Fetching
  366. .IX Subsection "Algorithm Fetching"
  367. .PP
  368. Using calls to convenience functions such as \fBEVP_sha256()\fR and \fBEVP_aes_256_gcm()\fR may
  369. incur a performance penalty when using providers.
  370. Retrieving algorithms from providers involves searching for an algorithm by name.
  371. This is much slower than directly accessing a method table.
  372. It is recommended to prefetch algorithms if an algorithm is used many times.
  373. See \*(L"Performance\*(R" in \fBcrypto\fR\|(7), \*(L"Explicit fetching\*(R" in \fBcrypto\fR\|(7) and \*(L"Implicit fetching\*(R" in \fBcrypto\fR\|(7).
  374. .PP
  375. Support for Linux Kernel \s-1TLS\s0
  376. .IX Subsection "Support for Linux Kernel TLS"
  377. .PP
  378. In order to use \s-1KTLS,\s0 support for it must be compiled in using the
  379. \&\f(CW\*(C`enable\-ktls\*(C'\fR configuration option. It must also be enabled at run time using
  380. the \fB\s-1SSL_OP_ENABLE_KTLS\s0\fR option.
  381. .PP
  382. New Algorithms
  383. .IX Subsection "New Algorithms"
  384. .IP "\(bu" 4
  385. \&\s-1KDF\s0 algorithms \*(L"\s-1SINGLE STEP\*(R"\s0 and \*(L"\s-1SSH\*(R"\s0
  386. .Sp
  387. See \s-1\fBEVP_KDF\-SS\s0\fR\|(7) and \s-1\fBEVP_KDF\-SSHKDF\s0\fR\|(7)
  388. .IP "\(bu" 4
  389. \&\s-1MAC\s0 Algorithms \*(L"\s-1GMAC\*(R"\s0 and \*(L"\s-1KMAC\*(R"\s0
  390. .Sp
  391. See \s-1\fBEVP_MAC\-GMAC\s0\fR\|(7) and \s-1\fBEVP_MAC\-KMAC\s0\fR\|(7).
  392. .IP "\(bu" 4
  393. \&\s-1KEM\s0 Algorithm \*(L"\s-1RSASVE\*(R"\s0
  394. .Sp
  395. See \s-1\fBEVP_KEM\-RSA\s0\fR\|(7).
  396. .IP "\(bu" 4
  397. Cipher Algorithm \*(L"AES-SIV\*(R"
  398. .Sp
  399. See \*(L"\s-1SIV\s0 Mode\*(R" in \fBEVP_EncryptInit\fR\|(3).
  400. .IP "\(bu" 4
  401. \&\s-1AES\s0 Key Wrap inverse ciphers supported by \s-1EVP\s0 layer.
  402. .Sp
  403. The inverse ciphers use \s-1AES\s0 decryption for wrapping, and \s-1AES\s0 encryption for
  404. unwrapping. The algorithms are: \*(L"\s-1AES\-128\-WRAP\-INV\*(R", \*(L"AES\-192\-WRAP\-INV\*(R",
  405. \&\*(L"AES\-256\-WRAP\-INV\*(R", \*(L"AES\-128\-WRAP\-PAD\-INV\*(R", \*(L"AES\-192\-WRAP\-PAD\-INV\*(R"\s0 and
  406. \&\*(L"\s-1AES\-256\-WRAP\-PAD\-INV\*(R".\s0
  407. .IP "\(bu" 4
  408. \&\s-1CTS\s0 ciphers added to \s-1EVP\s0 layer.
  409. .Sp
  410. The algorithms are \*(L"\s-1AES\-128\-CBC\-CTS\*(R", \*(L"AES\-192\-CBC\-CTS\*(R", \*(L"AES\-256\-CBC\-CTS\*(R",
  411. \&\*(L"CAMELLIA\-128\-CBC\-CTS\*(R", \*(L"CAMELLIA\-192\-CBC\-CTS\*(R"\s0 and \*(L"\s-1CAMELLIA\-256\-CBC\-CTS\*(R".
  412. CS1, CS2\s0 and \s-1CS3\s0 variants are supported.
  413. .PP
  414. \s-1CMS\s0 and PKCS#7 updates
  415. .IX Subsection "CMS and PKCS#7 updates"
  416. .IP "\(bu" 4
  417. Added CAdES-BES signature verification support.
  418. .IP "\(bu" 4
  419. Added CAdES-BES signature scheme and attributes support (\s-1RFC 5126\s0) to \s-1CMS API.\s0
  420. .IP "\(bu" 4
  421. Added AuthEnvelopedData content type structure (\s-1RFC 5083\s0) using \s-1AES_GCM\s0
  422. .Sp
  423. This uses the AES-GCM parameter (\s-1RFC 5084\s0) for the Cryptographic Message Syntax.
  424. Its purpose is to support encryption and decryption of a digital envelope that
  425. is both authenticated and encrypted using \s-1AES GCM\s0 mode.
  426. .IP "\(bu" 4
  427. \&\fBPKCS7_get_octet_string\fR\|(3) and \fBPKCS7_type_is_other\fR\|(3) were made public.
  428. .PP
  429. PKCS#12 \s-1API\s0 updates
  430. .IX Subsection "PKCS#12 API updates"
  431. .PP
  432. The default algorithms for pkcs12 creation with the \fBPKCS12_create()\fR function
  433. were changed to more modern \s-1PBKDF2\s0 and \s-1AES\s0 based algorithms. The default
  434. \&\s-1MAC\s0 iteration count was changed to \s-1PKCS12_DEFAULT_ITER\s0 to make it equal
  435. with the password-based encryption iteration count. The default digest
  436. algorithm for the \s-1MAC\s0 computation was changed to \s-1SHA\-256.\s0 The pkcs12
  437. application now supports \-legacy option that restores the previous
  438. default algorithms to support interoperability with legacy systems.
  439. .PP
  440. Added enhanced PKCS#12 APIs which accept a library context \fB\s-1OSSL_LIB_CTX\s0\fR
  441. and (where relevant) a property query. Other APIs which handle PKCS#7 and
  442. PKCS#8 objects have also been enhanced where required. This includes:
  443. .PP
  444. \&\fBPKCS12_add_key_ex\fR\|(3), \fBPKCS12_add_safe_ex\fR\|(3), \fBPKCS12_add_safes_ex\fR\|(3),
  445. \&\fBPKCS12_create_ex\fR\|(3), \fBPKCS12_decrypt_skey_ex\fR\|(3), \fBPKCS12_init_ex\fR\|(3),
  446. \&\fBPKCS12_item_decrypt_d2i_ex\fR\|(3), \fBPKCS12_item_i2d_encrypt_ex\fR\|(3),
  447. \&\fBPKCS12_key_gen_asc_ex\fR\|(3), \fBPKCS12_key_gen_uni_ex\fR\|(3), \fBPKCS12_key_gen_utf8_ex\fR\|(3),
  448. \&\fBPKCS12_pack_p7encdata_ex\fR\|(3), \fBPKCS12_pbe_crypt_ex\fR\|(3), \fBPKCS12_PBE_keyivgen_ex\fR\|(3),
  449. \&\fBPKCS12_SAFEBAG_create_pkcs8_encrypt_ex\fR\|(3), \fBPKCS5_pbe2_set_iv_ex\fR\|(3),
  450. \&\fBPKCS5_pbe_set0_algor_ex\fR\|(3), \fBPKCS5_pbe_set_ex\fR\|(3), \fBPKCS5_pbkdf2_set_ex\fR\|(3),
  451. \&\fBPKCS5_v2_PBE_keyivgen_ex\fR\|(3), \fBPKCS5_v2_scrypt_keyivgen_ex\fR\|(3),
  452. \&\fBPKCS8_decrypt_ex\fR\|(3), \fBPKCS8_encrypt_ex\fR\|(3), \fBPKCS8_set0_pbe_ex\fR\|(3).
  453. .PP
  454. As part of this change the EVP_PBE_xxx APIs can also accept a library
  455. context and property query and will call an extended version of the key/IV
  456. derivation function which supports these parameters. This includes
  457. \&\fBEVP_PBE_CipherInit_ex\fR\|(3), \fBEVP_PBE_find_ex\fR\|(3) and \fBEVP_PBE_scrypt_ex\fR\|(3).
  458. .PP
  459. PKCS#12 \s-1KDF\s0 versus \s-1FIPS\s0
  460. .IX Subsection "PKCS#12 KDF versus FIPS"
  461. .PP
  462. Unlike in 1.x.y, the \s-1PKCS12KDF\s0 algorithm used when a PKCS#12 structure
  463. is created with a \s-1MAC\s0 that does not work with the \s-1FIPS\s0 provider as the \s-1PKCS12KDF\s0
  464. is not a \s-1FIPS\s0 approvable mechanism.
  465. .PP
  466. See \s-1\fBEVP_KDF\-PKCS12KDF\s0\fR\|(7), \fBPKCS12_create\fR\|(3), \fBopenssl\-pkcs12\fR\|(1),
  467. \&\s-1\fBOSSL_PROVIDER\-FIPS\s0\fR\|(7).
  468. .PP
  469. Windows thread synchronization changes
  470. .IX Subsection "Windows thread synchronization changes"
  471. .PP
  472. Windows thread synchronization uses read/write primitives (SRWLock) when
  473. supported by the \s-1OS,\s0 otherwise CriticalSection continues to be used.
  474. .PP
  475. Trace \s-1API\s0
  476. .IX Subsection "Trace API"
  477. .PP
  478. A new generic trace \s-1API\s0 has been added which provides support for enabling
  479. instrumentation through trace output. This feature is mainly intended as an aid
  480. for developers and is disabled by default. To utilize it, OpenSSL needs to be
  481. configured with the \f(CW\*(C`enable\-trace\*(C'\fR option.
  482. .PP
  483. If the tracing \s-1API\s0 is enabled, the application can activate trace output by
  484. registering BIOs as trace channels for a number of tracing and debugging
  485. categories. See \fBOSSL_trace_enabled\fR\|(3).
  486. .PP
  487. Key validation updates
  488. .IX Subsection "Key validation updates"
  489. .PP
  490. \&\fBEVP_PKEY_public_check\fR\|(3) and \fBEVP_PKEY_param_check\fR\|(3) now work for
  491. more key types. This includes \s-1RSA, DSA, ED25519, X25519, ED448\s0 and X448.
  492. Previously (in 1.1.1) they would return \-2. For key types that do not have
  493. parameters then \fBEVP_PKEY_param_check\fR\|(3) will always return 1.
  494. .PP
  495. \fIOther notable deprecations and changes\fR
  496. .IX Subsection "Other notable deprecations and changes"
  497. .PP
  498. The function code part of an OpenSSL error code is no longer relevant
  499. .IX Subsection "The function code part of an OpenSSL error code is no longer relevant"
  500. .PP
  501. This code is now always set to zero. Related functions are deprecated.
  502. .PP
  503. \s-1STACK\s0 and \s-1HASH\s0 macros have been cleaned up
  504. .IX Subsection "STACK and HASH macros have been cleaned up"
  505. .PP
  506. The type-safe wrappers are declared everywhere and implemented once.
  507. See \s-1\fBDEFINE_STACK_OF\s0\fR\|(3) and \s-1\fBDEFINE_LHASH_OF_EX\s0\fR\|(3).
  508. .PP
  509. The \s-1RAND_DRBG\s0 subsystem has been removed
  510. .IX Subsection "The RAND_DRBG subsystem has been removed"
  511. .PP
  512. The new \s-1\fBEVP_RAND\s0\fR\|(3) is a partial replacement: the \s-1DRBG\s0 callback framework is
  513. absent. The \s-1RAND_DRBG API\s0 did not fit well into the new provider concept as
  514. implemented by \s-1EVP_RAND\s0 and \s-1EVP_RAND_CTX.\s0
  515. .PP
  516. Removed \fBFIPS_mode()\fR and \fBFIPS_mode_set()\fR
  517. .IX Subsection "Removed FIPS_mode() and FIPS_mode_set()"
  518. .PP
  519. These functions are legacy APIs that are not applicable to the new provider
  520. model. Applications should instead use
  521. \&\fBEVP_default_properties_is_fips_enabled\fR\|(3) and
  522. \&\fBEVP_default_properties_enable_fips\fR\|(3).
  523. .PP
  524. Key generation is slower
  525. .IX Subsection "Key generation is slower"
  526. .PP
  527. The Miller-Rabin test now uses 64 rounds, which is used for all prime generation,
  528. including \s-1RSA\s0 key generation. This affects the time for larger keys sizes.
  529. .PP
  530. The default key generation method for the regular 2\-prime \s-1RSA\s0 keys was changed
  531. to the \s-1FIPS186\-4 B.3.6\s0 method (Generation of Probable Primes with Conditions
  532. Based on Auxiliary Probable Primes). This method is slower than the original
  533. method.
  534. .PP
  535. Change \s-1PBKDF2\s0 to conform to \s-1SP800\-132\s0 instead of the older \s-1PKCS5 RFC2898\s0
  536. .IX Subsection "Change PBKDF2 to conform to SP800-132 instead of the older PKCS5 RFC2898"
  537. .PP
  538. This checks that the salt length is at least 128 bits, the derived key length is
  539. at least 112 bits, and that the iteration count is at least 1000.
  540. For backwards compatibility these checks are disabled by default in the
  541. default provider, but are enabled by default in the \s-1FIPS\s0 provider.
  542. .PP
  543. To enable or disable the checks see \fB\s-1OSSL_KDF_PARAM_PKCS5\s0\fR in
  544. \&\s-1\fBEVP_KDF\-PBKDF2\s0\fR\|(7). The parameter can be set using \fBEVP_KDF_derive\fR\|(3).
  545. .PP
  546. Enforce a minimum \s-1DH\s0 modulus size of 512 bits
  547. .IX Subsection "Enforce a minimum DH modulus size of 512 bits"
  548. .PP
  549. Smaller sizes now result in an error.
  550. .PP
  551. \s-1SM2\s0 key changes
  552. .IX Subsection "SM2 key changes"
  553. .PP
  554. \&\s-1EC\s0 EVP_PKEYs with the \s-1SM2\s0 curve have been reworked to automatically become
  555. \&\s-1EVP_PKEY_SM2\s0 rather than \s-1EVP_PKEY_EC.\s0
  556. .PP
  557. Unlike in previous OpenSSL versions, this means that applications cannot
  558. call \f(CW\*(C`EVP_PKEY_set_alias_type(pkey, EVP_PKEY_SM2)\*(C'\fR to get \s-1SM2\s0 computations.
  559. .PP
  560. Parameter and key generation is also reworked to make it possible
  561. to generate \s-1EVP_PKEY_SM2\s0 parameters and keys. Applications must now generate
  562. \&\s-1SM2\s0 keys directly and must not create an \s-1EVP_PKEY_EC\s0 key first. It is no longer
  563. possible to import an \s-1SM2\s0 key with domain parameters other than the \s-1SM2\s0 elliptic
  564. curve ones.
  565. .PP
  566. Validation of \s-1SM2\s0 keys has been separated from the validation of regular \s-1EC\s0
  567. keys, allowing to improve the \s-1SM2\s0 validation process to reject loaded private
  568. keys that are not conforming to the \s-1SM2 ISO\s0 standard.
  569. In particular, a private scalar \fIk\fR outside the range \fI1 <= k < n\-1\fR is
  570. now correctly rejected.
  571. .PP
  572. \fBEVP_PKEY_set_alias_type()\fR method has been removed
  573. .IX Subsection "EVP_PKEY_set_alias_type() method has been removed"
  574. .PP
  575. This function made a \fB\s-1EVP_PKEY\s0\fR object mutable after it had been set up. In
  576. OpenSSL 3.0 it was decided that a provided key should not be able to change its
  577. type, so this function has been removed.
  578. .PP
  579. Functions that return an internal key should be treated as read only
  580. .IX Subsection "Functions that return an internal key should be treated as read only"
  581. .PP
  582. Functions such as \fBEVP_PKEY_get0_RSA\fR\|(3) behave slightly differently in
  583. OpenSSL 3.0. Previously they returned a pointer to the low-level key used
  584. internally by libcrypto. From OpenSSL 3.0 this key may now be held in a
  585. provider. Calling these functions will only return a handle on the internal key
  586. where the \s-1EVP_PKEY\s0 was constructed using this key in the first place, for
  587. example using a function or macro such as \fBEVP_PKEY_assign_RSA\fR\|(3),
  588. \&\fBEVP_PKEY_set1_RSA\fR\|(3), etc.
  589. Where the \s-1EVP_PKEY\s0 holds a provider managed key, then these functions now return
  590. a cached copy of the key. Changes to the internal provider key that take place
  591. after the first time the cached key is accessed will not be reflected back in
  592. the cached copy. Similarly any changes made to the cached copy by application
  593. code will not be reflected back in the internal provider key.
  594. .PP
  595. For the above reasons the keys returned from these functions should typically be
  596. treated as read-only. To emphasise this the value returned from
  597. \&\fBEVP_PKEY_get0_RSA\fR\|(3), \fBEVP_PKEY_get0_DSA\fR\|(3), \fBEVP_PKEY_get0_EC_KEY\fR\|(3) and
  598. \&\fBEVP_PKEY_get0_DH\fR\|(3) have been made const. This may break some existing code.
  599. Applications broken by this change should be modified. The preferred solution is
  600. to refactor the code to avoid the use of these deprecated functions. Failing
  601. this the code should be modified to use a const pointer instead.
  602. The \fBEVP_PKEY_get1_RSA\fR\|(3), \fBEVP_PKEY_get1_DSA\fR\|(3), \fBEVP_PKEY_get1_EC_KEY\fR\|(3)
  603. and \fBEVP_PKEY_get1_DH\fR\|(3) functions continue to return a non-const pointer to
  604. enable them to be \*(L"freed\*(R". However they should also be treated as read-only.
  605. .PP
  606. The public key check has moved from \fBEVP_PKEY_derive()\fR to \fBEVP_PKEY_derive_set_peer()\fR
  607. .IX Subsection "The public key check has moved from EVP_PKEY_derive() to EVP_PKEY_derive_set_peer()"
  608. .PP
  609. This may mean result in an error in \fBEVP_PKEY_derive_set_peer\fR\|(3) rather than
  610. during \fBEVP_PKEY_derive\fR\|(3).
  611. To disable this check use EVP_PKEY_derive_set_peer_ex(dh, peer, 0).
  612. .PP
  613. The print format has cosmetic changes for some functions
  614. .IX Subsection "The print format has cosmetic changes for some functions"
  615. .PP
  616. The output from numerous \*(L"printing\*(R" functions such as \fBX509_signature_print\fR\|(3),
  617. \&\fBX509_print_ex\fR\|(3), \fBX509_CRL_print_ex\fR\|(3), and other similar functions has been
  618. amended such that there may be cosmetic differences between the output
  619. observed in 1.1.1 and 3.0. This also applies to the \fB\-text\fR output from the
  620. \&\fBopenssl x509\fR and \fBopenssl crl\fR applications.
  621. .PP
  622. Interactive mode from the \fBopenssl\fR program has been removed
  623. .IX Subsection "Interactive mode from the openssl program has been removed"
  624. .PP
  625. From now on, running it without arguments is equivalent to \fBopenssl help\fR.
  626. .PP
  627. The error return values from some control calls (ctrl) have changed
  628. .IX Subsection "The error return values from some control calls (ctrl) have changed"
  629. .PP
  630. One significant change is that controls which used to return \-2 for
  631. invalid inputs, now return \-1 indicating a generic error condition instead.
  632. .PP
  633. \s-1DH\s0 and \s-1DHX\s0 key types have different settable parameters
  634. .IX Subsection "DH and DHX key types have different settable parameters"
  635. .PP
  636. Previously (in 1.1.1) these conflicting parameters were allowed, but will now
  637. result in errors. See \s-1\fBEVP_PKEY\-DH\s0\fR\|(7) for further details. This affects the
  638. behaviour of \fBopenssl\-genpkey\fR\|(1) for \s-1DH\s0 parameter generation.
  639. .PP
  640. \fBEVP_CIPHER_CTX_set_flags()\fR ordering change
  641. .IX Subsection "EVP_CIPHER_CTX_set_flags() ordering change"
  642. .PP
  643. If using a cipher from a provider the \fB\s-1EVP_CIPH_FLAG_LENGTH_BITS\s0\fR flag can only
  644. be set \fBafter\fR the cipher has been assigned to the cipher context.
  645. See \*(L"\s-1FLAGS\*(R"\s0 in \fBEVP_EncryptInit\fR\|(3) for more information.
  646. .PP
  647. Validation of operation context parameters
  648. .IX Subsection "Validation of operation context parameters"
  649. .PP
  650. Due to move of the implementation of cryptographic operations to the
  651. providers, validation of various operation parameters can be postponed until
  652. the actual operation is executed where previously it happened immediately
  653. when an operation parameter was set.
  654. .PP
  655. For example when setting an unsupported curve with
  656. \&\fBEVP_PKEY_CTX_set_ec_paramgen_curve_nid()\fR this function call will not fail
  657. but later keygen operations with the \s-1EVP_PKEY_CTX\s0 will fail.
  658. .PP
  659. Removal of function code from the error codes
  660. .IX Subsection "Removal of function code from the error codes"
  661. .PP
  662. The function code part of the error code is now always set to 0. For that
  663. reason the \s-1\fBERR_GET_FUNC\s0()\fR macro was removed. Applications must resolve
  664. the error codes only using the library number and the reason code.
  665. .PP
  666. ChaCha20\-Poly1305 cipher does not allow a truncated \s-1IV\s0 length to be used
  667. .IX Subsection "ChaCha20-Poly1305 cipher does not allow a truncated IV length to be used"
  668. .PP
  669. In OpenSSL 3.0 setting the \s-1IV\s0 length to any value other than 12 will result in an
  670. error.
  671. Prior to OpenSSL 3.0 the ivlen could be smaller that the required 12 byte length,
  672. using EVP_CIPHER_CTX_ctrl(ctx, \s-1EVP_CRTL_AEAD_SET_IVLEN,\s0 ivlen, \s-1NULL\s0). This resulted
  673. in an \s-1IV\s0 that had leading zero padding.
  674. .SS "Installation and Compilation"
  675. .IX Subsection "Installation and Compilation"
  676. Please refer to the \s-1INSTALL\s0.md file in the top of the distribution for
  677. instructions on how to build and install OpenSSL 3.0. Please also refer to the
  678. various platform specific \s-1NOTES\s0 files for your specific platform.
  679. .SS "Upgrading from OpenSSL 1.1.1"
  680. .IX Subsection "Upgrading from OpenSSL 1.1.1"
  681. Upgrading to OpenSSL 3.0 from OpenSSL 1.1.1 should be relatively straight
  682. forward in most cases. The most likely area where you will encounter problems
  683. is if you have used low level APIs in your code (as discussed above). In that
  684. case you are likely to start seeing deprecation warnings when compiling your
  685. application. If this happens you have 3 options:
  686. .IP "1." 4
  687. Ignore the warnings. They are just warnings. The deprecated functions are still present and you may still use them. However be aware that they may be removed from a future version of OpenSSL.
  688. .IP "2." 4
  689. Suppress the warnings. Refer to your compiler documentation on how to do this.
  690. .IP "3." 4
  691. Remove your usage of the low level APIs. In this case you will need to rewrite your code to use the high level APIs instead
  692. .PP
  693. \fIError code changes\fR
  694. .IX Subsection "Error code changes"
  695. .PP
  696. As OpenSSL 3.0 provides a brand new Encoder/Decoder mechanism for working with
  697. widely used file formats, application code that checks for particular error
  698. reason codes on key loading failures might need an update.
  699. .PP
  700. Password-protected keys may deserve special attention. If only some errors
  701. are treated as an indicator that the user should be asked about the password again,
  702. it's worth testing these scenarios and processing the newly relevant codes.
  703. .PP
  704. There may be more cases to treat specially, depending on the calling application code.
  705. .SS "Upgrading from OpenSSL 1.0.2"
  706. .IX Subsection "Upgrading from OpenSSL 1.0.2"
  707. Upgrading to OpenSSL 3.0 from OpenSSL 1.0.2 is likely to be significantly more
  708. difficult. In addition to the issues discussed above in the section about
  709. \&\*(L"Upgrading from OpenSSL 1.1.1\*(R", the main things to be aware of are:
  710. .IP "1." 4
  711. The build and installation procedure has changed significantly.
  712. .Sp
  713. Check the file \s-1INSTALL\s0.md in the top of the installation for instructions on how
  714. to build and install OpenSSL for your platform. Also read the various \s-1NOTES\s0
  715. files in the same directory, as applicable for your platform.
  716. .IP "2." 4
  717. Many structures have been made opaque in OpenSSL 3.0.
  718. .Sp
  719. The structure definitions have been removed from the public header files and
  720. moved to internal header files. In practice this means that you can no longer
  721. stack allocate some structures. Instead they must be heap allocated through some
  722. function call (typically those function names have a \f(CW\*(C`_new\*(C'\fR suffix to them).
  723. Additionally you must use \*(L"setter\*(R" or \*(L"getter\*(R" functions to access the fields
  724. within those structures.
  725. .Sp
  726. For example code that previously looked like this:
  727. .Sp
  728. .Vb 1
  729. \& EVP_MD_CTX md_ctx;
  730. \&
  731. \& /* This line will now generate compiler errors */
  732. \& EVP_MD_CTX_init(&md_ctx);
  733. .Ve
  734. .Sp
  735. The code needs to be amended to look like this:
  736. .Sp
  737. .Vb 1
  738. \& EVP_MD_CTX *md_ctx;
  739. \&
  740. \& md_ctx = EVP_MD_CTX_new();
  741. \& ...
  742. \& ...
  743. \& EVP_MD_CTX_free(md_ctx);
  744. .Ve
  745. .IP "3." 4
  746. Support for TLSv1.3 has been added.
  747. .Sp
  748. This has a number of implications for \s-1SSL/TLS\s0 applications. See the
  749. \&\s-1TLS1.3\s0 page <https://wiki.openssl.org/index.php/TLS1.3> for further details.
  750. .PP
  751. More details about the breaking changes between OpenSSL versions 1.0.2 and 1.1.0
  752. can be found on the
  753. OpenSSL 1.1.0 Changes page <https://wiki.openssl.org/index.php/OpenSSL_1.1.0_Changes>.
  754. .PP
  755. \fIUpgrading from the OpenSSL 2.0 \s-1FIPS\s0 Object Module\fR
  756. .IX Subsection "Upgrading from the OpenSSL 2.0 FIPS Object Module"
  757. .PP
  758. The OpenSSL 2.0 \s-1FIPS\s0 Object Module was a separate download that had to be built
  759. separately and then integrated into your main OpenSSL 1.0.2 build.
  760. In OpenSSL 3.0 the \s-1FIPS\s0 support is fully integrated into the mainline version of
  761. OpenSSL and is no longer a separate download. For further information see
  762. \&\*(L"Completing the installation of the \s-1FIPS\s0 Module\*(R".
  763. .PP
  764. The function calls \fBFIPS_mode()\fR and \fBFIPS_mode_set()\fR have been removed
  765. from OpenSSL 3.0. You should rewrite your application to not use them.
  766. See \fBfips_module\fR\|(7) and \s-1\fBOSSL_PROVIDER\-FIPS\s0\fR\|(7) for details.
  767. .SS "Completing the installation of the \s-1FIPS\s0 Module"
  768. .IX Subsection "Completing the installation of the FIPS Module"
  769. The \s-1FIPS\s0 Module will be built and installed automatically if \s-1FIPS\s0 support has
  770. been configured. The current documentation can be found in the
  771. README-FIPS <https://github.com/openssl/openssl/blob/master/README-FIPS.md> file.
  772. .SS "Programming"
  773. .IX Subsection "Programming"
  774. Applications written to work with OpenSSL 1.1.1 will mostly just work with
  775. OpenSSL 3.0. However changes will be required if you want to take advantage of
  776. some of the new features that OpenSSL 3.0 makes available. In order to do that
  777. you need to understand some new concepts introduced in OpenSSL 3.0.
  778. Read \*(L"Library contexts\*(R" in \fBcrypto\fR\|(7) for further information.
  779. .PP
  780. \fILibrary Context\fR
  781. .IX Subsection "Library Context"
  782. .PP
  783. A library context allows different components of a complex application to each
  784. use a different library context and have different providers loaded with
  785. different configuration settings.
  786. See \*(L"Library contexts\*(R" in \fBcrypto\fR\|(7) for further info.
  787. .PP
  788. If the user creates an \fB\s-1OSSL_LIB_CTX\s0\fR via \fBOSSL_LIB_CTX_new\fR\|(3) then many
  789. functions may need to be changed to pass additional parameters to handle the
  790. library context.
  791. .PP
  792. Using a Library Context \- Old functions that should be changed
  793. .IX Subsection "Using a Library Context - Old functions that should be changed"
  794. .PP
  795. If a library context is needed then all EVP_* digest functions that return a
  796. \&\fBconst \s-1EVP_MD\s0 *\fR such as \fBEVP_sha256()\fR should be replaced with a call to
  797. \&\fBEVP_MD_fetch\fR\|(3). See \*(L"\s-1ALGORITHM FETCHING\*(R"\s0 in \fBcrypto\fR\|(7).
  798. .PP
  799. If a library context is needed then all EVP_* cipher functions that return a
  800. \&\fBconst \s-1EVP_CIPHER\s0 *\fR such as \fBEVP_aes_128_cbc()\fR should be replaced vith a call to
  801. \&\fBEVP_CIPHER_fetch\fR\|(3). See \*(L"\s-1ALGORITHM FETCHING\*(R"\s0 in \fBcrypto\fR\|(7).
  802. .PP
  803. Some functions can be passed an object that has already been set up with a library
  804. context such as \fBd2i_X509\fR\|(3), \fBd2i_X509_CRL\fR\|(3), \fBd2i_X509_REQ\fR\|(3) and
  805. \&\fBd2i_X509_PUBKEY\fR\|(3). If \s-1NULL\s0 is passed instead then the created object will be
  806. set up with the default library context. Use \fBX509_new_ex\fR\|(3),
  807. \&\fBX509_CRL_new_ex\fR\|(3), \fBX509_REQ_new_ex\fR\|(3) and \fBX509_PUBKEY_new_ex\fR\|(3) if a
  808. library context is required.
  809. .PP
  810. All functions listed below with a \fI\s-1NAME\s0\fR have a replacement function \fINAME_ex\fR
  811. that takes \fB\s-1OSSL_LIB_CTX\s0\fR as an additional argument. Functions that have other
  812. mappings are listed along with the respective name.
  813. .IP "\(bu" 4
  814. \&\fBASN1_item_new\fR\|(3), \fBASN1_item_d2i\fR\|(3), \fBASN1_item_d2i_fp\fR\|(3),
  815. \&\fBASN1_item_d2i_bio\fR\|(3), \fBASN1_item_sign\fR\|(3) and \fBASN1_item_verify\fR\|(3)
  816. .IP "\(bu" 4
  817. \&\fBBIO_new\fR\|(3)
  818. .IP "\(bu" 4
  819. \&\fBb2i_RSA_PVK_bio()\fR and \fBi2b_PVK_bio()\fR
  820. .IP "\(bu" 4
  821. \&\fBBN_CTX_new\fR\|(3) and \fBBN_CTX_secure_new\fR\|(3)
  822. .IP "\(bu" 4
  823. \&\fBCMS_AuthEnvelopedData_create\fR\|(3), \fBCMS_ContentInfo_new\fR\|(3), \fBCMS_data_create\fR\|(3),
  824. \&\fBCMS_digest_create\fR\|(3), \fBCMS_EncryptedData_encrypt\fR\|(3), \fBCMS_encrypt\fR\|(3),
  825. \&\fBCMS_EnvelopedData_create\fR\|(3), \fBCMS_ReceiptRequest_create0\fR\|(3) and \fBCMS_sign\fR\|(3)
  826. .IP "\(bu" 4
  827. \&\fBCONF_modules_load_file\fR\|(3)
  828. .IP "\(bu" 4
  829. \&\fBCTLOG_new\fR\|(3), \fBCTLOG_new_from_base64\fR\|(3) and \fBCTLOG_STORE_new\fR\|(3)
  830. .IP "\(bu" 4
  831. \&\fBCT_POLICY_EVAL_CTX_new\fR\|(3)
  832. .IP "\(bu" 4
  833. \&\fBd2i_AutoPrivateKey\fR\|(3), \fBd2i_PrivateKey\fR\|(3) and \fBd2i_PUBKEY\fR\|(3)
  834. .IP "\(bu" 4
  835. \&\fBd2i_PrivateKey_bio\fR\|(3) and \fBd2i_PrivateKey_fp\fR\|(3)
  836. .Sp
  837. Use \fBd2i_PrivateKey_ex_bio\fR\|(3) and \fBd2i_PrivateKey_ex_fp\fR\|(3)
  838. .IP "\(bu" 4
  839. \&\fBEC_GROUP_new\fR\|(3)
  840. .Sp
  841. Use \fBEC_GROUP_new_by_curve_name_ex\fR\|(3) or \fBEC_GROUP_new_from_params\fR\|(3).
  842. .IP "\(bu" 4
  843. \&\fBEVP_DigestSignInit\fR\|(3) and \fBEVP_DigestVerifyInit\fR\|(3)
  844. .IP "\(bu" 4
  845. \&\fBEVP_PBE_CipherInit\fR\|(3), \fBEVP_PBE_find\fR\|(3) and \fBEVP_PBE_scrypt\fR\|(3)
  846. .IP "\(bu" 4
  847. \&\fBPKCS5_PBE_keyivgen\fR\|(3)
  848. .IP "\(bu" 4
  849. \&\s-1\fBEVP_PKCS82PKEY\s0\fR\|(3)
  850. .IP "\(bu" 4
  851. \&\fBEVP_PKEY_CTX_new_id\fR\|(3)
  852. .Sp
  853. Use \fBEVP_PKEY_CTX_new_from_name\fR\|(3)
  854. .IP "\(bu" 4
  855. \&\fBEVP_PKEY_derive_set_peer\fR\|(3), \fBEVP_PKEY_new_raw_private_key\fR\|(3)
  856. and \fBEVP_PKEY_new_raw_public_key\fR\|(3)
  857. .IP "\(bu" 4
  858. \&\fBEVP_SignFinal\fR\|(3) and \fBEVP_VerifyFinal\fR\|(3)
  859. .IP "\(bu" 4
  860. \&\fBNCONF_new\fR\|(3)
  861. .IP "\(bu" 4
  862. \&\fBOCSP_RESPID_match\fR\|(3) and \fBOCSP_RESPID_set_by_key\fR\|(3)
  863. .IP "\(bu" 4
  864. \&\fBOPENSSL_thread_stop\fR\|(3)
  865. .IP "\(bu" 4
  866. \&\fBOSSL_STORE_open\fR\|(3)
  867. .IP "\(bu" 4
  868. \&\fBPEM_read_bio_Parameters\fR\|(3), \fBPEM_read_bio_PrivateKey\fR\|(3), \fBPEM_read_bio_PUBKEY\fR\|(3),
  869. \&\fBPEM_read_PrivateKey\fR\|(3) and \fBPEM_read_PUBKEY\fR\|(3)
  870. .IP "\(bu" 4
  871. \&\fBPEM_write_bio_PrivateKey\fR\|(3), \fBPEM_write_bio_PUBKEY\fR\|(3), \fBPEM_write_PrivateKey\fR\|(3)
  872. and \fBPEM_write_PUBKEY\fR\|(3)
  873. .IP "\(bu" 4
  874. \&\fBPEM_X509_INFO_read_bio\fR\|(3) and \fBPEM_X509_INFO_read\fR\|(3)
  875. .IP "\(bu" 4
  876. \&\fBPKCS12_add_key\fR\|(3), \fBPKCS12_add_safe\fR\|(3), \fBPKCS12_add_safes\fR\|(3),
  877. \&\fBPKCS12_create\fR\|(3), \fBPKCS12_decrypt_skey\fR\|(3), \fBPKCS12_init\fR\|(3), \fBPKCS12_item_decrypt_d2i\fR\|(3),
  878. \&\fBPKCS12_item_i2d_encrypt\fR\|(3), \fBPKCS12_key_gen_asc\fR\|(3), \fBPKCS12_key_gen_uni\fR\|(3),
  879. \&\fBPKCS12_key_gen_utf8\fR\|(3), \fBPKCS12_pack_p7encdata\fR\|(3), \fBPKCS12_pbe_crypt\fR\|(3),
  880. \&\fBPKCS12_PBE_keyivgen\fR\|(3), \fBPKCS12_SAFEBAG_create_pkcs8_encrypt\fR\|(3)
  881. .IP "\(bu" 4
  882. \&\fBPKCS5_pbe_set0_algor\fR\|(3), \fBPKCS5_pbe_set\fR\|(3), \fBPKCS5_pbe2_set_iv\fR\|(3),
  883. \&\fBPKCS5_pbkdf2_set\fR\|(3) and \fBPKCS5_v2_scrypt_keyivgen\fR\|(3)
  884. .IP "\(bu" 4
  885. \&\fBPKCS7_encrypt\fR\|(3), \fBPKCS7_new\fR\|(3) and \fBPKCS7_sign\fR\|(3)
  886. .IP "\(bu" 4
  887. \&\fBPKCS8_decrypt\fR\|(3), \fBPKCS8_encrypt\fR\|(3) and \fBPKCS8_set0_pbe\fR\|(3)
  888. .IP "\(bu" 4
  889. \&\fBRAND_bytes\fR\|(3) and \fBRAND_priv_bytes\fR\|(3)
  890. .IP "\(bu" 4
  891. \&\fBSMIME_write_ASN1\fR\|(3)
  892. .IP "\(bu" 4
  893. \&\fBSSL_load_client_CA_file\fR\|(3)
  894. .IP "\(bu" 4
  895. \&\fBSSL_CTX_new\fR\|(3)
  896. .IP "\(bu" 4
  897. \&\fBTS_RESP_CTX_new\fR\|(3)
  898. .IP "\(bu" 4
  899. \&\fBX509_CRL_new\fR\|(3)
  900. .IP "\(bu" 4
  901. \&\fBX509_load_cert_crl_file\fR\|(3) and \fBX509_load_cert_file\fR\|(3)
  902. .IP "\(bu" 4
  903. \&\fBX509_LOOKUP_by_subject\fR\|(3) and \fBX509_LOOKUP_ctrl\fR\|(3)
  904. .IP "\(bu" 4
  905. \&\fBX509_NAME_hash\fR\|(3)
  906. .IP "\(bu" 4
  907. \&\fBX509_new\fR\|(3)
  908. .IP "\(bu" 4
  909. \&\fBX509_REQ_new\fR\|(3) and \fBX509_REQ_verify\fR\|(3)
  910. .IP "\(bu" 4
  911. \&\fBX509_STORE_CTX_new\fR\|(3), \fBX509_STORE_set_default_paths\fR\|(3), \fBX509_STORE_load_file\fR\|(3),
  912. \&\fBX509_STORE_load_locations\fR\|(3) and \fBX509_STORE_load_store\fR\|(3)
  913. .PP
  914. New functions that use a Library context
  915. .IX Subsection "New functions that use a Library context"
  916. .PP
  917. The following functions can be passed a library context if required.
  918. Passing \s-1NULL\s0 will use the default library context.
  919. .IP "\(bu" 4
  920. \&\fBBIO_new_from_core_bio\fR\|(3)
  921. .IP "\(bu" 4
  922. \&\fBEVP_ASYM_CIPHER_fetch\fR\|(3) and \fBEVP_ASYM_CIPHER_do_all_provided\fR\|(3)
  923. .IP "\(bu" 4
  924. \&\fBEVP_CIPHER_fetch\fR\|(3) and \fBEVP_CIPHER_do_all_provided\fR\|(3)
  925. .IP "\(bu" 4
  926. \&\fBEVP_default_properties_enable_fips\fR\|(3) and
  927. \&\fBEVP_default_properties_is_fips_enabled\fR\|(3)
  928. .IP "\(bu" 4
  929. \&\fBEVP_KDF_fetch\fR\|(3) and \fBEVP_KDF_do_all_provided\fR\|(3)
  930. .IP "\(bu" 4
  931. \&\fBEVP_KEM_fetch\fR\|(3) and \fBEVP_KEM_do_all_provided\fR\|(3)
  932. .IP "\(bu" 4
  933. \&\fBEVP_KEYEXCH_fetch\fR\|(3) and \fBEVP_KEYEXCH_do_all_provided\fR\|(3)
  934. .IP "\(bu" 4
  935. \&\fBEVP_KEYMGMT_fetch\fR\|(3) and \fBEVP_KEYMGMT_do_all_provided\fR\|(3)
  936. .IP "\(bu" 4
  937. \&\fBEVP_MAC_fetch\fR\|(3) and \fBEVP_MAC_do_all_provided\fR\|(3)
  938. .IP "\(bu" 4
  939. \&\fBEVP_MD_fetch\fR\|(3) and \fBEVP_MD_do_all_provided\fR\|(3)
  940. .IP "\(bu" 4
  941. \&\fBEVP_PKEY_CTX_new_from_pkey\fR\|(3)
  942. .IP "\(bu" 4
  943. \&\fBEVP_PKEY_Q_keygen\fR\|(3)
  944. .IP "\(bu" 4
  945. \&\fBEVP_Q_mac\fR\|(3) and \fBEVP_Q_digest\fR\|(3)
  946. .IP "\(bu" 4
  947. \&\s-1\fBEVP_RAND\s0\fR\|(3) and \fBEVP_RAND_do_all_provided\fR\|(3)
  948. .IP "\(bu" 4
  949. \&\fBEVP_set_default_properties\fR\|(3)
  950. .IP "\(bu" 4
  951. \&\fBEVP_SIGNATURE_fetch\fR\|(3) and \fBEVP_SIGNATURE_do_all_provided\fR\|(3)
  952. .IP "\(bu" 4
  953. \&\fBOSSL_CMP_CTX_new\fR\|(3) and \fBOSSL_CMP_SRV_CTX_new\fR\|(3)
  954. .IP "\(bu" 4
  955. \&\fBOSSL_CRMF_ENCRYPTEDVALUE_get1_encCert\fR\|(3)
  956. .IP "\(bu" 4
  957. \&\fBOSSL_CRMF_MSG_create_popo\fR\|(3) and \fBOSSL_CRMF_MSGS_verify_popo\fR\|(3)
  958. .IP "\(bu" 4
  959. \&\fBOSSL_CRMF_pbm_new\fR\|(3) and \fBOSSL_CRMF_pbmp_new\fR\|(3)
  960. .IP "\(bu" 4
  961. \&\fBOSSL_DECODER_CTX_add_extra\fR\|(3) and \fBOSSL_DECODER_CTX_new_for_pkey\fR\|(3)
  962. .IP "\(bu" 4
  963. \&\fBOSSL_DECODER_fetch\fR\|(3) and \fBOSSL_DECODER_do_all_provided\fR\|(3)
  964. .IP "\(bu" 4
  965. \&\fBOSSL_ENCODER_CTX_add_extra\fR\|(3)
  966. .IP "\(bu" 4
  967. \&\fBOSSL_ENCODER_fetch\fR\|(3) and \fBOSSL_ENCODER_do_all_provided\fR\|(3)
  968. .IP "\(bu" 4
  969. \&\fBOSSL_LIB_CTX_free\fR\|(3), \fBOSSL_LIB_CTX_load_config\fR\|(3) and \fBOSSL_LIB_CTX_set0_default\fR\|(3)
  970. .IP "\(bu" 4
  971. \&\fBOSSL_PROVIDER_add_builtin\fR\|(3), \fBOSSL_PROVIDER_available\fR\|(3),
  972. \&\fBOSSL_PROVIDER_do_all\fR\|(3), \fBOSSL_PROVIDER_load\fR\|(3),
  973. \&\fBOSSL_PROVIDER_set_default_search_path\fR\|(3) and \fBOSSL_PROVIDER_try_load\fR\|(3)
  974. .IP "\(bu" 4
  975. \&\fBOSSL_SELF_TEST_get_callback\fR\|(3) and \fBOSSL_SELF_TEST_set_callback\fR\|(3)
  976. .IP "\(bu" 4
  977. \&\fBOSSL_STORE_attach\fR\|(3)
  978. .IP "\(bu" 4
  979. \&\fBOSSL_STORE_LOADER_fetch\fR\|(3) and \fBOSSL_STORE_LOADER_do_all_provided\fR\|(3)
  980. .IP "\(bu" 4
  981. \&\fBRAND_get0_primary\fR\|(3), \fBRAND_get0_private\fR\|(3), \fBRAND_get0_public\fR\|(3),
  982. \&\fBRAND_set_DRBG_type\fR\|(3) and \fBRAND_set_seed_source_type\fR\|(3)
  983. .PP
  984. \fIProviders\fR
  985. .IX Subsection "Providers"
  986. .PP
  987. Providers are described in detail here \*(L"Providers\*(R" in \fBcrypto\fR\|(7).
  988. See also \*(L"\s-1OPENSSL PROVIDERS\*(R"\s0 in \fBcrypto\fR\|(7).
  989. .PP
  990. \fIFetching algorithms and property queries\fR
  991. .IX Subsection "Fetching algorithms and property queries"
  992. .PP
  993. Implicit and Explicit Fetching is described in detail here
  994. \&\*(L"\s-1ALGORITHM FETCHING\*(R"\s0 in \fBcrypto\fR\|(7).
  995. .PP
  996. \fIMapping \s-1EVP\s0 controls and flags to provider \s-1\f(BIOSSL_PARAM\s0\fI\|(3) parameters\fR
  997. .IX Subsection "Mapping EVP controls and flags to provider OSSL_PARAM parameters"
  998. .PP
  999. The existing functions for controls (such as \fBEVP_CIPHER_CTX_ctrl\fR\|(3)) and
  1000. manipulating flags (such as \fBEVP_MD_CTX_set_flags\fR\|(3))internally use
  1001. \&\fB\s-1OSSL_PARAMS\s0\fR to pass information to/from provider objects.
  1002. See \s-1\fBOSSL_PARAM\s0\fR\|(3) for additional information related to parameters.
  1003. .PP
  1004. For ciphers see \*(L"\s-1CONTROLS\*(R"\s0 in \fBEVP_EncryptInit\fR\|(3), \*(L"\s-1FLAGS\*(R"\s0 in \fBEVP_EncryptInit\fR\|(3) and
  1005. \&\*(L"\s-1PARAMETERS\*(R"\s0 in \fBEVP_EncryptInit\fR\|(3).
  1006. .PP
  1007. For digests see \*(L"\s-1CONTROLS\*(R"\s0 in \fBEVP_DigestInit\fR\|(3), \*(L"\s-1FLAGS\*(R"\s0 in \fBEVP_DigestInit\fR\|(3) and
  1008. \&\*(L"\s-1PARAMETERS\*(R"\s0 in \fBEVP_DigestInit\fR\|(3).
  1009. .PP
  1010. \fIDeprecation of Low Level Functions\fR
  1011. .IX Subsection "Deprecation of Low Level Functions"
  1012. .PP
  1013. A significant number of APIs have been deprecated in OpenSSL 3.0.
  1014. This section describes some common categories of deprecations.
  1015. See \*(L"Deprecated function mappings\*(R" for the list of deprecated functions
  1016. that refer to these categories.
  1017. .PP
  1018. Providers are a replacement for engines and low-level method overrides
  1019. .IX Subsection "Providers are a replacement for engines and low-level method overrides"
  1020. .PP
  1021. Any accessor that uses an \s-1ENGINE\s0 is deprecated (such as \fBEVP_PKEY_set1_engine()\fR).
  1022. Applications using engines should instead use providers.
  1023. .PP
  1024. Before providers were added algorithms were overridden by changing the methods
  1025. used by algorithms. All these methods such as \fBRSA_new_method()\fR and \fBRSA_meth_new()\fR
  1026. are now deprecated and can be replaced by using providers instead.
  1027. .PP
  1028. Deprecated i2d and d2i functions for low-level key types
  1029. .IX Subsection "Deprecated i2d and d2i functions for low-level key types"
  1030. .PP
  1031. Any i2d and d2i functions such as \fBd2i_DHparams()\fR that take a low-level key type
  1032. have been deprecated. Applications should instead use the \s-1\fBOSSL_DECODER\s0\fR\|(3) and
  1033. \&\s-1\fBOSSL_ENCODER\s0\fR\|(3) APIs to read and write files.
  1034. See \*(L"Migration\*(R" in \fBd2i_RSAPrivateKey\fR\|(3) for further details.
  1035. .PP
  1036. Deprecated low-level key object getters and setters
  1037. .IX Subsection "Deprecated low-level key object getters and setters"
  1038. .PP
  1039. Applications that set or get low-level key objects (such as \fBEVP_PKEY_set1_DH()\fR
  1040. or \fBEVP_PKEY_get0()\fR) should instead use the \s-1OSSL_ENCODER\s0
  1041. (See \fBOSSL_ENCODER_to_bio\fR\|(3)) or \s-1OSSL_DECODER\s0 (See \fBOSSL_DECODER_from_bio\fR\|(3))
  1042. APIs, or alternatively use \fBEVP_PKEY_fromdata\fR\|(3) or \fBEVP_PKEY_todata\fR\|(3).
  1043. .PP
  1044. Deprecated low-level key parameter getters
  1045. .IX Subsection "Deprecated low-level key parameter getters"
  1046. .PP
  1047. Functions that access low-level objects directly such as \fBRSA_get0_n\fR\|(3) are now
  1048. deprecated. Applications should use one of \fBEVP_PKEY_get_bn_param\fR\|(3),
  1049. \&\fBEVP_PKEY_get_int_param\fR\|(3), l<\fBEVP_PKEY_get_size_t_param\fR\|(3)>,
  1050. \&\fBEVP_PKEY_get_utf8_string_param\fR\|(3), \fBEVP_PKEY_get_octet_string_param\fR\|(3) or
  1051. \&\fBEVP_PKEY_get_params\fR\|(3) to access fields from an \s-1EVP_PKEY.\s0
  1052. Gettable parameters are listed in \*(L"Common \s-1RSA\s0 parameters\*(R" in \s-1\fBEVP_PKEY\-RSA\s0\fR\|(7),
  1053. \&\*(L"\s-1DH\s0 parameters\*(R" in \s-1\fBEVP_PKEY\-DH\s0\fR\|(7), \*(L"\s-1DSA\s0 parameters\*(R" in \s-1\fBEVP_PKEY\-DSA\s0\fR\|(7),
  1054. \&\*(L"\s-1FFC\s0 parameters\*(R" in \s-1\fBEVP_PKEY\-FFC\s0\fR\|(7), \*(L"Common \s-1EC\s0 parameters\*(R" in \s-1\fBEVP_PKEY\-EC\s0\fR\|(7) and
  1055. \&\*(L"Common X25519, X448, \s-1ED25519\s0 and \s-1ED448\s0 parameters\*(R" in \s-1\fBEVP_PKEY\-X25519\s0\fR\|(7).
  1056. Applications may also use \fBEVP_PKEY_todata\fR\|(3) to return all fields.
  1057. .PP
  1058. Deprecated low-level key parameter setters
  1059. .IX Subsection "Deprecated low-level key parameter setters"
  1060. .PP
  1061. Functions that access low-level objects directly such as \fBRSA_set0_crt_params\fR\|(3)
  1062. are now deprecated. Applications should use \fBEVP_PKEY_fromdata\fR\|(3) to create
  1063. new keys from user provided key data. Keys should be immutable once they are
  1064. created, so if required the user may use \fBEVP_PKEY_todata\fR\|(3), \fBOSSL_PARAM_merge\fR\|(3),
  1065. and \fBEVP_PKEY_fromdata\fR\|(3) to create a modified key.
  1066. See \*(L"Examples\*(R" in \s-1\fBEVP_PKEY\-DH\s0\fR\|(7) for more information.
  1067. See \*(L"Deprecated low-level key generation functions\*(R" for information on
  1068. generating a key using parameters.
  1069. .PP
  1070. Deprecated low-level object creation
  1071. .IX Subsection "Deprecated low-level object creation"
  1072. .PP
  1073. Low-level objects were created using methods such as \fBRSA_new\fR\|(3),
  1074. \&\fBRSA_up_ref\fR\|(3) and \fBRSA_free\fR\|(3). Applications should instead use the
  1075. high-level \s-1EVP_PKEY\s0 APIs, e.g. \fBEVP_PKEY_new\fR\|(3), \fBEVP_PKEY_up_ref\fR\|(3) and
  1076. \&\fBEVP_PKEY_free\fR\|(3).
  1077. See also \fBEVP_PKEY_CTX_new_from_name\fR\|(3) and \fBEVP_PKEY_CTX_new_from_pkey\fR\|(3).
  1078. .PP
  1079. EVP_PKEYs may be created in a variety of ways:
  1080. See also \*(L"Deprecated low-level key generation functions\*(R",
  1081. \&\*(L"Deprecated low-level key reading and writing functions\*(R" and
  1082. \&\*(L"Deprecated low-level key parameter setters\*(R".
  1083. .PP
  1084. Deprecated low-level encryption functions
  1085. .IX Subsection "Deprecated low-level encryption functions"
  1086. .PP
  1087. Low-level encryption functions such as \fBAES_encrypt\fR\|(3) and \fBAES_decrypt\fR\|(3)
  1088. have been informally discouraged from use for a long time. Applications should
  1089. instead use the high level \s-1EVP\s0 APIs \fBEVP_EncryptInit_ex\fR\|(3),
  1090. \&\fBEVP_EncryptUpdate\fR\|(3), and \fBEVP_EncryptFinal_ex\fR\|(3) or
  1091. \&\fBEVP_DecryptInit_ex\fR\|(3), \fBEVP_DecryptUpdate\fR\|(3) and \fBEVP_DecryptFinal_ex\fR\|(3).
  1092. .PP
  1093. Deprecated low-level digest functions
  1094. .IX Subsection "Deprecated low-level digest functions"
  1095. .PP
  1096. Use of low-level digest functions such as \fBSHA1_Init\fR\|(3) have been
  1097. informally discouraged from use for a long time. Applications should instead
  1098. use the the high level \s-1EVP\s0 APIs \fBEVP_DigestInit_ex\fR\|(3), \fBEVP_DigestUpdate\fR\|(3)
  1099. and \fBEVP_DigestFinal_ex\fR\|(3), or the quick one-shot \fBEVP_Q_digest\fR\|(3).
  1100. .PP
  1101. Note that the functions \s-1\fBSHA1\s0\fR\|(3), \s-1\fBSHA224\s0\fR\|(3), \s-1\fBSHA256\s0\fR\|(3), \s-1\fBSHA384\s0\fR\|(3)
  1102. and \s-1\fBSHA512\s0\fR\|(3) have changed to macros that use \fBEVP_Q_digest\fR\|(3).
  1103. .PP
  1104. Deprecated low-level signing functions
  1105. .IX Subsection "Deprecated low-level signing functions"
  1106. .PP
  1107. Use of low-level signing functions such as \fBDSA_sign\fR\|(3) have been
  1108. informally discouraged for a long time. Instead applications should use
  1109. \&\fBEVP_DigestSign\fR\|(3) and \fBEVP_DigestVerify\fR\|(3).
  1110. See also \s-1\fBEVP_SIGNATURE\-RSA\s0\fR\|(7), \s-1\fBEVP_SIGNATURE\-DSA\s0\fR\|(7),
  1111. \&\s-1\fBEVP_SIGNATURE\-ECDSA\s0\fR\|(7) and \s-1\fBEVP_SIGNATURE\-ED25519\s0\fR\|(7).
  1112. .PP
  1113. Deprecated low-level \s-1MAC\s0 functions
  1114. .IX Subsection "Deprecated low-level MAC functions"
  1115. .PP
  1116. Low-level mac functions such as \fBCMAC_Init\fR\|(3) are deprecated.
  1117. Applications should instead use the new \s-1\fBEVP_MAC\s0\fR\|(3) interface, using
  1118. \&\fBEVP_MAC_CTX_new\fR\|(3), \fBEVP_MAC_CTX_free\fR\|(3), \fBEVP_MAC_init\fR\|(3),
  1119. \&\fBEVP_MAC_update\fR\|(3) and \fBEVP_MAC_final\fR\|(3) or the single-shot \s-1MAC\s0 function
  1120. \&\fBEVP_Q_mac\fR\|(3).
  1121. See \s-1\fBEVP_MAC\s0\fR\|(3), \s-1\fBEVP_MAC\-HMAC\s0\fR\|(7), \s-1\fBEVP_MAC\-CMAC\s0\fR\|(7), \s-1\fBEVP_MAC\-GMAC\s0\fR\|(7),
  1122. \&\s-1\fBEVP_MAC\-KMAC\s0\fR\|(7), \s-1\fBEVP_MAC\-BLAKE2\s0\fR\|(7), \fBEVP_MAC\-Poly1305\fR\|(7) and
  1123. \&\fBEVP_MAC\-Siphash\fR\|(7) for additional information.
  1124. .PP
  1125. Note that the one-shot method \s-1\fBHMAC\s0()\fR is still available for compatibility purposes,
  1126. but this can also be replaced by using \s-1EVP_Q_MAC\s0 if a library context is required.
  1127. .PP
  1128. Deprecated low-level validation functions
  1129. .IX Subsection "Deprecated low-level validation functions"
  1130. .PP
  1131. Low-level validation functions such as \fBDH_check\fR\|(3) have been informally
  1132. discouraged from use for a long time. Applications should instead use the high-level
  1133. \&\s-1EVP_PKEY\s0 APIs such as \fBEVP_PKEY_check\fR\|(3), \fBEVP_PKEY_param_check\fR\|(3),
  1134. \&\fBEVP_PKEY_param_check_quick\fR\|(3), \fBEVP_PKEY_public_check\fR\|(3),
  1135. \&\fBEVP_PKEY_public_check_quick\fR\|(3), \fBEVP_PKEY_private_check\fR\|(3),
  1136. and \fBEVP_PKEY_pairwise_check\fR\|(3).
  1137. .PP
  1138. Deprecated low-level key exchange functions
  1139. .IX Subsection "Deprecated low-level key exchange functions"
  1140. .PP
  1141. Many low-level functions have been informally discouraged from use for a long
  1142. time. Applications should instead use \fBEVP_PKEY_derive\fR\|(3).
  1143. See \s-1\fBEVP_KEYEXCH\-DH\s0\fR\|(7), \s-1\fBEVP_KEYEXCH\-ECDH\s0\fR\|(7) and \s-1\fBEVP_KEYEXCH\-X25519\s0\fR\|(7).
  1144. .PP
  1145. Deprecated low-level key generation functions
  1146. .IX Subsection "Deprecated low-level key generation functions"
  1147. .PP
  1148. Many low-level functions have been informally discouraged from use for a long
  1149. time. Applications should instead use \fBEVP_PKEY_keygen_init\fR\|(3) and
  1150. \&\fBEVP_PKEY_generate\fR\|(3) as described in \s-1\fBEVP_PKEY\-DSA\s0\fR\|(7), \s-1\fBEVP_PKEY\-DH\s0\fR\|(7),
  1151. \&\s-1\fBEVP_PKEY\-RSA\s0\fR\|(7), \s-1\fBEVP_PKEY\-EC\s0\fR\|(7) and \s-1\fBEVP_PKEY\-X25519\s0\fR\|(7).
  1152. The 'quick' one-shot function \fBEVP_PKEY_Q_keygen\fR\|(3) and macros for the most
  1153. common cases: <\fBEVP_RSA_gen\fR\|(3)> and \fBEVP_EC_gen\fR\|(3) may also be used.
  1154. .PP
  1155. Deprecated low-level key reading and writing functions
  1156. .IX Subsection "Deprecated low-level key reading and writing functions"
  1157. .PP
  1158. Use of low-level objects (such as \s-1DSA\s0) has been informally discouraged from use
  1159. for a long time. Functions to read and write these low-level objects (such as
  1160. \&\fBPEM_read_DSA_PUBKEY()\fR) should be replaced. Applications should instead use
  1161. \&\fBOSSL_ENCODER_to_bio\fR\|(3) and \fBOSSL_DECODER_from_bio\fR\|(3).
  1162. .PP
  1163. Deprecated low-level key printing functions
  1164. .IX Subsection "Deprecated low-level key printing functions"
  1165. .PP
  1166. Use of low-level objects (such as \s-1DSA\s0) has been informally discouraged from use
  1167. for a long time. Functions to print these low-level objects such as
  1168. \&\fBDSA_print()\fR should be replaced with the equivalent \s-1EVP_PKEY\s0 functions.
  1169. Application should use one of \fBEVP_PKEY_print_public\fR\|(3),
  1170. \&\fBEVP_PKEY_print_private\fR\|(3), \fBEVP_PKEY_print_params\fR\|(3),
  1171. \&\fBEVP_PKEY_print_public_fp\fR\|(3), \fBEVP_PKEY_print_private_fp\fR\|(3) or
  1172. \&\fBEVP_PKEY_print_params_fp\fR\|(3). Note that internally these use
  1173. \&\fBOSSL_ENCODER_to_bio\fR\|(3) and \fBOSSL_DECODER_from_bio\fR\|(3).
  1174. .PP
  1175. \fIDeprecated function mappings\fR
  1176. .IX Subsection "Deprecated function mappings"
  1177. .PP
  1178. The following functions have been deprecated in 3.0.
  1179. .IP "\(bu" 4
  1180. \&\fBAES_bi_ige_encrypt()\fR and \fBAES_ige_encrypt()\fR
  1181. .Sp
  1182. There is no replacement for the \s-1IGE\s0 functions. New code should not use these modes.
  1183. These undocumented functions were never integrated into the \s-1EVP\s0 layer.
  1184. They implemented the \s-1AES\s0 Infinite Garble Extension (\s-1IGE\s0) mode and \s-1AES\s0
  1185. Bi-directional \s-1IGE\s0 mode. These modes were never formally standardised and
  1186. usage of these functions is believed to be very small. In particular
  1187. \&\fBAES_bi_ige_encrypt()\fR has a known bug. It accepts 2 \s-1AES\s0 keys, but only one
  1188. is ever used. The security implications are believed to be minimal, but
  1189. this issue was never fixed for backwards compatibility reasons.
  1190. .IP "\(bu" 4
  1191. \&\fBAES_encrypt()\fR, \fBAES_decrypt()\fR, \fBAES_set_encrypt_key()\fR, \fBAES_set_decrypt_key()\fR,
  1192. \&\fBAES_cbc_encrypt()\fR, \fBAES_cfb128_encrypt()\fR, \fBAES_cfb1_encrypt()\fR, \fBAES_cfb8_encrypt()\fR,
  1193. \&\fBAES_ecb_encrypt()\fR, \fBAES_ofb128_encrypt()\fR
  1194. .IP "\(bu" 4
  1195. \&\fBAES_unwrap_key()\fR, \fBAES_wrap_key()\fR
  1196. .Sp
  1197. See \*(L"Deprecated low-level encryption functions\*(R"
  1198. .IP "\(bu" 4
  1199. \&\fBAES_options()\fR
  1200. .Sp
  1201. There is no replacement. It returned a string indicating if the \s-1AES\s0 code was unrolled.
  1202. .IP "\(bu" 4
  1203. \&\fBASN1_digest()\fR, \fBASN1_sign()\fR, \fBASN1_verify()\fR
  1204. .Sp
  1205. There are no replacements. These old functions are not used, and could be
  1206. disabled with the macro \s-1NO_ASN1_OLD\s0 since OpenSSL 0.9.7.
  1207. .IP "\(bu" 4
  1208. \&\fBASN1_STRING_length_set()\fR
  1209. .Sp
  1210. Use \fBASN1_STRING_set\fR\|(3) or \fBASN1_STRING_set0\fR\|(3) instead.
  1211. This was a potentially unsafe function that could change the bounds of a
  1212. previously passed in pointer.
  1213. .IP "\(bu" 4
  1214. \&\fBBF_encrypt()\fR, \fBBF_decrypt()\fR, \fBBF_set_key()\fR, \fBBF_cbc_encrypt()\fR, \fBBF_cfb64_encrypt()\fR,
  1215. \&\fBBF_ecb_encrypt()\fR, \fBBF_ofb64_encrypt()\fR
  1216. .Sp
  1217. See \*(L"Deprecated low-level encryption functions\*(R".
  1218. The Blowfish algorithm has been moved to the Legacy Provider.
  1219. .IP "\(bu" 4
  1220. \&\fBBF_options()\fR
  1221. .Sp
  1222. There is no replacement. This option returned a constant string.
  1223. .IP "\(bu" 4
  1224. \&\fBBIO_get_callback()\fR, \fBBIO_set_callback()\fR, \fBBIO_debug_callback()\fR
  1225. .Sp
  1226. Use the respective non-deprecated \fB_ex()\fR functions.
  1227. .IP "\(bu" 4
  1228. \&\fBBN_is_prime_ex()\fR, \fBBN_is_prime_fasttest_ex()\fR
  1229. .Sp
  1230. Use \fBBN_check_prime\fR\|(3) which avoids possible misuse and always uses at least
  1231. 64 rounds of the Miller-Rabin primality test.
  1232. .IP "\(bu" 4
  1233. \&\fBBN_pseudo_rand()\fR, \fBBN_pseudo_rand_range()\fR
  1234. .Sp
  1235. Use \fBBN_rand\fR\|(3) and \fBBN_rand_range\fR\|(3).
  1236. .IP "\(bu" 4
  1237. \&\fBBN_X931_derive_prime_ex()\fR, \fBBN_X931_generate_prime_ex()\fR, \fBBN_X931_generate_Xpq()\fR
  1238. .Sp
  1239. There are no replacements for these low-level functions. They were used internally
  1240. by \fBRSA_X931_derive_ex()\fR and \fBRSA_X931_generate_key_ex()\fR which are also deprecated.
  1241. Use \fBEVP_PKEY_keygen\fR\|(3) instead.
  1242. .IP "\(bu" 4
  1243. \&\fBCamellia_encrypt()\fR, \fBCamellia_decrypt()\fR, \fBCamellia_set_key()\fR,
  1244. \&\fBCamellia_cbc_encrypt()\fR, \fBCamellia_cfb128_encrypt()\fR, \fBCamellia_cfb1_encrypt()\fR,
  1245. \&\fBCamellia_cfb8_encrypt()\fR, \fBCamellia_ctr128_encrypt()\fR, \fBCamellia_ecb_encrypt()\fR,
  1246. \&\fBCamellia_ofb128_encrypt()\fR
  1247. .Sp
  1248. See \*(L"Deprecated low-level encryption functions\*(R".
  1249. .IP "\(bu" 4
  1250. \&\fBCAST_encrypt()\fR, \fBCAST_decrypt()\fR, \fBCAST_set_key()\fR, \fBCAST_cbc_encrypt()\fR,
  1251. \&\fBCAST_cfb64_encrypt()\fR, \fBCAST_ecb_encrypt()\fR, \fBCAST_ofb64_encrypt()\fR
  1252. .Sp
  1253. See \*(L"Deprecated low-level encryption functions\*(R".
  1254. The \s-1CAST\s0 algorithm has been moved to the Legacy Provider.
  1255. .IP "\(bu" 4
  1256. \&\fBCMAC_CTX_new()\fR, \fBCMAC_CTX_cleanup()\fR, \fBCMAC_CTX_copy()\fR, \fBCMAC_CTX_free()\fR,
  1257. \&\fBCMAC_CTX_get0_cipher_ctx()\fR
  1258. .Sp
  1259. See \*(L"Deprecated low-level \s-1MAC\s0 functions\*(R".
  1260. .IP "\(bu" 4
  1261. \&\fBCMAC_Init()\fR, \fBCMAC_Update()\fR, \fBCMAC_Final()\fR, \fBCMAC_resume()\fR
  1262. .Sp
  1263. See \*(L"Deprecated low-level \s-1MAC\s0 functions\*(R".
  1264. .IP "\(bu" 4
  1265. \&\fBCRYPTO_mem_ctrl()\fR, \fBCRYPTO_mem_debug_free()\fR, \fBCRYPTO_mem_debug_malloc()\fR,
  1266. \&\fBCRYPTO_mem_debug_pop()\fR, \fBCRYPTO_mem_debug_push()\fR, \fBCRYPTO_mem_debug_realloc()\fR,
  1267. \&\fBCRYPTO_mem_leaks()\fR, \fBCRYPTO_mem_leaks_cb()\fR, \fBCRYPTO_mem_leaks_fp()\fR,
  1268. \&\fBCRYPTO_set_mem_debug()\fR
  1269. .Sp
  1270. Memory-leak checking has been deprecated in favor of more modern development
  1271. tools, such as compiler memory and leak sanitizers or Valgrind.
  1272. .IP "\(bu" 4
  1273. \&\fBCRYPTO_cts128_encrypt_block()\fR, \fBCRYPTO_cts128_encrypt()\fR,
  1274. \&\fBCRYPTO_cts128_decrypt_block()\fR, \fBCRYPTO_cts128_decrypt()\fR,
  1275. \&\fBCRYPTO_nistcts128_encrypt_block()\fR, \fBCRYPTO_nistcts128_encrypt()\fR,
  1276. \&\fBCRYPTO_nistcts128_decrypt_block()\fR, \fBCRYPTO_nistcts128_decrypt()\fR
  1277. .Sp
  1278. Use the higher level functions \fBEVP_CipherInit_ex2()\fR, \fBEVP_CipherUpdate()\fR and
  1279. \&\fBEVP_CipherFinal_ex()\fR instead.
  1280. See the \*(L"cts_mode\*(R" parameter in
  1281. \&\*(L"Gettable and Settable \s-1EVP_CIPHER_CTX\s0 parameters\*(R" in \fBEVP_EncryptInit\fR\|(3).
  1282. See \*(L"\s-1EXAMPLES\*(R"\s0 in \fBEVP_EncryptInit\fR\|(3) for a \s-1AES\-256\-CBC\-CTS\s0 example.
  1283. .IP "\(bu" 4
  1284. \&\fBd2i_DHparams()\fR, \fBd2i_DHxparams()\fR, \fBd2i_DSAparams()\fR, \fBd2i_DSAPrivateKey()\fR,
  1285. \&\fBd2i_DSAPrivateKey_bio()\fR, \fBd2i_DSAPrivateKey_fp()\fR, \fBd2i_DSA_PUBKEY()\fR,
  1286. \&\fBd2i_DSA_PUBKEY_bio()\fR, \fBd2i_DSA_PUBKEY_fp()\fR, \fBd2i_DSAPublicKey()\fR,
  1287. \&\fBd2i_ECParameters()\fR, \fBd2i_ECPrivateKey()\fR, \fBd2i_ECPrivateKey_bio()\fR,
  1288. \&\fBd2i_ECPrivateKey_fp()\fR, \fBd2i_EC_PUBKEY()\fR, \fBd2i_EC_PUBKEY_bio()\fR,
  1289. \&\fBd2i_EC_PUBKEY_fp()\fR, \fBd2i_RSAPrivateKey()\fR,
  1290. \&\fBd2i_RSAPrivateKey_bio()\fR, \fBd2i_RSAPrivateKey_fp()\fR, \fBd2i_RSA_PUBKEY()\fR,
  1291. \&\fBd2i_RSA_PUBKEY_bio()\fR, \fBd2i_RSA_PUBKEY_fp()\fR, \fBd2i_RSAPublicKey()\fR,
  1292. \&\fBd2i_RSAPublicKey_bio()\fR, \fBd2i_RSAPublicKey_fp()\fR
  1293. .Sp
  1294. See \*(L"Deprecated i2d and d2i functions for low-level key types\*(R"
  1295. .IP "\(bu" 4
  1296. \&\fBo2i_ECPublicKey()\fR
  1297. .Sp
  1298. Use \fBEVP_PKEY_set1_encoded_public_key\fR\|(3).
  1299. See \*(L"Deprecated low-level key parameter setters\*(R"
  1300. .IP "\(bu" 4
  1301. \&\fBDES_crypt()\fR, \fBDES_fcrypt()\fR, \fBDES_encrypt1()\fR, \fBDES_encrypt2()\fR, \fBDES_encrypt3()\fR,
  1302. \&\fBDES_decrypt3()\fR, \fBDES_ede3_cbc_encrypt()\fR, \fBDES_ede3_cfb64_encrypt()\fR,
  1303. \&\fBDES_ede3_cfb_encrypt()\fR,\fBDES_ede3_ofb64_encrypt()\fR,
  1304. \&\fBDES_ecb_encrypt()\fR, \fBDES_ecb3_encrypt()\fR, \fBDES_ofb64_encrypt()\fR, \fBDES_ofb_encrypt()\fR,
  1305. DES_cfb64_encrypt \fBDES_cfb_encrypt()\fR, \fBDES_cbc_encrypt()\fR, \fBDES_ncbc_encrypt()\fR,
  1306. \&\fBDES_pcbc_encrypt()\fR, \fBDES_xcbc_encrypt()\fR, \fBDES_cbc_cksum()\fR, \fBDES_quad_cksum()\fR,
  1307. \&\fBDES_check_key_parity()\fR, \fBDES_is_weak_key()\fR, \fBDES_key_sched()\fR, \fBDES_options()\fR,
  1308. \&\fBDES_random_key()\fR, \fBDES_set_key()\fR, \fBDES_set_key_checked()\fR, \fBDES_set_key_unchecked()\fR,
  1309. \&\fBDES_set_odd_parity()\fR, \fBDES_string_to_2keys()\fR, \fBDES_string_to_key()\fR
  1310. .Sp
  1311. See \*(L"Deprecated low-level encryption functions\*(R".
  1312. Algorithms for \*(L"DESX-CBC\*(R", \*(L"DES-ECB\*(R", \*(L"DES-CBC\*(R", \*(L"DES-OFB\*(R", \*(L"DES-CFB\*(R",
  1313. \&\*(L"\s-1DES\-CFB1\*(R"\s0 and \*(L"\s-1DES\-CFB8\*(R"\s0 have been moved to the Legacy Provider.
  1314. .IP "\(bu" 4
  1315. \&\fBDH_bits()\fR, \fBDH_security_bits()\fR, \fBDH_size()\fR
  1316. .Sp
  1317. Use \fBEVP_PKEY_get_bits\fR\|(3), \fBEVP_PKEY_get_security_bits\fR\|(3) and
  1318. \&\fBEVP_PKEY_get_size\fR\|(3).
  1319. .IP "\(bu" 4
  1320. \&\fBDH_check()\fR, \fBDH_check_ex()\fR, \fBDH_check_params()\fR, \fBDH_check_params_ex()\fR,
  1321. \&\fBDH_check_pub_key()\fR, \fBDH_check_pub_key_ex()\fR
  1322. .Sp
  1323. See \*(L"Deprecated low-level validation functions\*(R"
  1324. .IP "\(bu" 4
  1325. \&\fBDH_clear_flags()\fR, \fBDH_test_flags()\fR, \fBDH_set_flags()\fR
  1326. .Sp
  1327. The \fB\s-1DH_FLAG_CACHE_MONT_P\s0\fR flag has been deprecated without replacement.
  1328. The \fB\s-1DH_FLAG_TYPE_DH\s0\fR and \fB\s-1DH_FLAG_TYPE_DHX\s0\fR have been deprecated.
  1329. Use \fBEVP_PKEY_is_a()\fR to determine the type of a key.
  1330. There is no replacement for setting these flags.
  1331. .IP "\(bu" 4
  1332. \&\fBDH_compute_key()\fR \fBDH_compute_key_padded()\fR
  1333. .Sp
  1334. See \*(L"Deprecated low-level key exchange functions\*(R".
  1335. .IP "\(bu" 4
  1336. \&\fBDH_new()\fR, \fBDH_new_by_nid()\fR, \fBDH_free()\fR, \fBDH_up_ref()\fR
  1337. .Sp
  1338. See \*(L"Deprecated low-level object creation\*(R"
  1339. .IP "\(bu" 4
  1340. \&\fBDH_generate_key()\fR, \fBDH_generate_parameters_ex()\fR
  1341. .Sp
  1342. See \*(L"Deprecated low-level key generation functions\*(R".
  1343. .IP "\(bu" 4
  1344. \&\fBDH_get0_pqg()\fR, \fBDH_get0_p()\fR, \fBDH_get0_q()\fR, \fBDH_get0_g()\fR, \fBDH_get0_key()\fR,
  1345. \&\fBDH_get0_priv_key()\fR, \fBDH_get0_pub_key()\fR, \fBDH_get_length()\fR, \fBDH_get_nid()\fR
  1346. .Sp
  1347. See \*(L"Deprecated low-level key parameter getters\*(R"
  1348. .IP "\(bu" 4
  1349. \&\fBDH_get_1024_160()\fR, \fBDH_get_2048_224()\fR, \fBDH_get_2048_256()\fR
  1350. .Sp
  1351. Applications should instead set the \fB\s-1OSSL_PKEY_PARAM_GROUP_NAME\s0\fR as specified in
  1352. \&\*(L"\s-1DH\s0 parameters\*(R" in \s-1\fBEVP_PKEY\-DH\s0\fR\|(7)) to one of \*(L"dh_1024_160\*(R", \*(L"dh_2048_224\*(R" or
  1353. \&\*(L"dh_2048_256\*(R" when generating a \s-1DH\s0 key.
  1354. .IP "\(bu" 4
  1355. \&\s-1\fBDH_KDF_X9_42\s0()\fR
  1356. .Sp
  1357. Applications should use \fBEVP_PKEY_CTX_set_dh_kdf_type\fR\|(3) instead.
  1358. .IP "\(bu" 4
  1359. \&\fBDH_get_default_method()\fR, \fBDH_get0_engine()\fR, DH_meth_*(), \fBDH_new_method()\fR,
  1360. \&\fBDH_OpenSSL()\fR, \fBDH_get_ex_data()\fR, \fBDH_set_default_method()\fR, \fBDH_set_method()\fR,
  1361. \&\fBDH_set_ex_data()\fR
  1362. .Sp
  1363. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R"
  1364. .IP "\(bu" 4
  1365. \&\fBDHparams_print()\fR, \fBDHparams_print_fp()\fR
  1366. .Sp
  1367. See \*(L"Deprecated low-level key printing functions\*(R"
  1368. .IP "\(bu" 4
  1369. \&\fBDH_set0_key()\fR, \fBDH_set0_pqg()\fR, \fBDH_set_length()\fR
  1370. .Sp
  1371. See \*(L"Deprecated low-level key parameter setters\*(R"
  1372. .IP "\(bu" 4
  1373. \&\fBDSA_bits()\fR, \fBDSA_security_bits()\fR, \fBDSA_size()\fR
  1374. .Sp
  1375. Use \fBEVP_PKEY_get_bits\fR\|(3), \fBEVP_PKEY_get_security_bits\fR\|(3) and
  1376. \&\fBEVP_PKEY_get_size\fR\|(3).
  1377. .IP "\(bu" 4
  1378. \&\fBDHparams_dup()\fR, \fBDSA_dup_DH()\fR
  1379. .Sp
  1380. There is no direct replacement. Applications may use \fBEVP_PKEY_copy_parameters\fR\|(3)
  1381. and \fBEVP_PKEY_dup\fR\|(3) instead.
  1382. .IP "\(bu" 4
  1383. \&\fBDSA_generate_key()\fR, \fBDSA_generate_parameters_ex()\fR
  1384. .Sp
  1385. See \*(L"Deprecated low-level key generation functions\*(R".
  1386. .IP "\(bu" 4
  1387. \&\fBDSA_get0_engine()\fR, \fBDSA_get_default_method()\fR, \fBDSA_get_ex_data()\fR,
  1388. \&\fBDSA_get_method()\fR, DSA_meth_*(), \fBDSA_new_method()\fR, \fBDSA_OpenSSL()\fR,
  1389. \&\fBDSA_set_default_method()\fR, \fBDSA_set_ex_data()\fR, \fBDSA_set_method()\fR
  1390. .Sp
  1391. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R".
  1392. .IP "\(bu" 4
  1393. \&\fBDSA_get0_p()\fR, \fBDSA_get0_q()\fR, \fBDSA_get0_g()\fR, \fBDSA_get0_pqg()\fR, \fBDSA_get0_key()\fR,
  1394. \&\fBDSA_get0_priv_key()\fR, \fBDSA_get0_pub_key()\fR
  1395. .Sp
  1396. See \*(L"Deprecated low-level key parameter getters\*(R".
  1397. .IP "\(bu" 4
  1398. \&\fBDSA_new()\fR, \fBDSA_free()\fR, \fBDSA_up_ref()\fR
  1399. .Sp
  1400. See \*(L"Deprecated low-level object creation\*(R"
  1401. .IP "\(bu" 4
  1402. \&\fBDSAparams_dup()\fR
  1403. .Sp
  1404. There is no direct replacement. Applications may use \fBEVP_PKEY_copy_parameters\fR\|(3)
  1405. and \fBEVP_PKEY_dup\fR\|(3) instead.
  1406. .IP "\(bu" 4
  1407. \&\fBDSAparams_print()\fR, \fBDSAparams_print_fp()\fR, \fBDSA_print()\fR, \fBDSA_print_fp()\fR
  1408. .Sp
  1409. See \*(L"Deprecated low-level key printing functions\*(R"
  1410. .IP "\(bu" 4
  1411. \&\fBDSA_set0_key()\fR, \fBDSA_set0_pqg()\fR
  1412. .Sp
  1413. See \*(L"Deprecated low-level key parameter setters\*(R"
  1414. .IP "\(bu" 4
  1415. \&\fBDSA_set_flags()\fR, \fBDSA_clear_flags()\fR, \fBDSA_test_flags()\fR
  1416. .Sp
  1417. The \fB\s-1DSA_FLAG_CACHE_MONT_P\s0\fR flag has been deprecated without replacement.
  1418. .IP "\(bu" 4
  1419. \&\fBDSA_sign()\fR, \fBDSA_do_sign()\fR, \fBDSA_sign_setup()\fR, \fBDSA_verify()\fR, \fBDSA_do_verify()\fR
  1420. .Sp
  1421. See \*(L"Deprecated low-level signing functions\*(R".
  1422. .IP "\(bu" 4
  1423. \&\fBECDH_compute_key()\fR
  1424. .Sp
  1425. See \*(L"Deprecated low-level key exchange functions\*(R".
  1426. .IP "\(bu" 4
  1427. \&\s-1\fBECDH_KDF_X9_62\s0()\fR
  1428. .Sp
  1429. Applications may either set this using the helper function
  1430. \&\fBEVP_PKEY_CTX_set_ecdh_kdf_type\fR\|(3) or by setting an \s-1\fBOSSL_PARAM\s0\fR\|(3) using the
  1431. \&\*(L"kdf-type\*(R" as shown in \*(L"\s-1EXAMPLES\*(R"\s0 in \s-1\fBEVP_KEYEXCH\-ECDH\s0\fR\|(7)
  1432. .IP "\(bu" 4
  1433. \&\fBECDSA_sign()\fR, \fBECDSA_sign_ex()\fR, \fBECDSA_sign_setup()\fR, \fBECDSA_do_sign()\fR,
  1434. \&\fBECDSA_do_sign_ex()\fR, \fBECDSA_verify()\fR, \fBECDSA_do_verify()\fR
  1435. .Sp
  1436. See \*(L"Deprecated low-level signing functions\*(R".
  1437. .IP "\(bu" 4
  1438. \&\fBECDSA_size()\fR
  1439. .Sp
  1440. Applications should use \fBEVP_PKEY_get_size\fR\|(3).
  1441. .IP "\(bu" 4
  1442. \&\fBEC_GF2m_simple_method()\fR, \fBEC_GFp_mont_method()\fR, \fBEC_GFp_nist_method()\fR,
  1443. \&\fBEC_GFp_nistp224_method()\fR, \fBEC_GFp_nistp256_method()\fR, \fBEC_GFp_nistp521_method()\fR,
  1444. \&\fBEC_GFp_simple_method()\fR
  1445. .Sp
  1446. There are no replacements for these functions. Applications should rely on the
  1447. library automatically assigning a suitable method internally when an \s-1EC_GROUP\s0
  1448. is constructed.
  1449. .IP "\(bu" 4
  1450. \&\fBEC_GROUP_clear_free()\fR
  1451. .Sp
  1452. Use \fBEC_GROUP_free\fR\|(3) instead.
  1453. .IP "\(bu" 4
  1454. \&\fBEC_GROUP_get_curve_GF2m()\fR, \fBEC_GROUP_get_curve_GFp()\fR, \fBEC_GROUP_set_curve_GF2m()\fR,
  1455. \&\fBEC_GROUP_set_curve_GFp()\fR
  1456. .Sp
  1457. Applications should use \fBEC_GROUP_get_curve\fR\|(3) and \fBEC_GROUP_set_curve\fR\|(3).
  1458. .IP "\(bu" 4
  1459. \&\fBEC_GROUP_have_precompute_mult()\fR, \fBEC_GROUP_precompute_mult()\fR,
  1460. \&\fBEC_KEY_precompute_mult()\fR
  1461. .Sp
  1462. These functions are not widely used. Applications should instead switch to
  1463. named curves which OpenSSL has hardcoded lookup tables for.
  1464. .IP "\(bu" 4
  1465. \&\fBEC_GROUP_new()\fR, \fBEC_GROUP_method_of()\fR, \fBEC_POINT_method_of()\fR
  1466. .Sp
  1467. \&\s-1EC_METHOD\s0 is now an internal-only concept and a suitable \s-1EC_METHOD\s0 is assigned
  1468. internally without application intervention.
  1469. Users of \fBEC_GROUP_new()\fR should switch to a different suitable constructor.
  1470. .IP "\(bu" 4
  1471. \&\fBEC_KEY_can_sign()\fR
  1472. .Sp
  1473. Applications should use \fBEVP_PKEY_can_sign\fR\|(3) instead.
  1474. .IP "\(bu" 4
  1475. \&\fBEC_KEY_check_key()\fR
  1476. .Sp
  1477. See \*(L"Deprecated low-level validation functions\*(R"
  1478. .IP "\(bu" 4
  1479. \&\fBEC_KEY_set_flags()\fR, \fBEC_KEY_get_flags()\fR, \fBEC_KEY_clear_flags()\fR
  1480. .Sp
  1481. See \*(L"Common \s-1EC\s0 parameters\*(R" in \s-1\fBEVP_PKEY\-EC\s0\fR\|(7) which handles flags as separate
  1482. parameters for \fB\s-1OSSL_PKEY_PARAM_EC_POINT_CONVERSION_FORMAT\s0\fR,
  1483. \&\fB\s-1OSSL_PKEY_PARAM_EC_GROUP_CHECK_TYPE\s0\fR, \fB\s-1OSSL_PKEY_PARAM_EC_ENCODING\s0\fR,
  1484. \&\fB\s-1OSSL_PKEY_PARAM_USE_COFACTOR_ECDH\s0\fR and
  1485. \&\fB\s-1OSSL_PKEY_PARAM_EC_INCLUDE_PUBLIC\s0\fR.
  1486. See also \*(L"\s-1EXAMPLES\*(R"\s0 in \s-1\fBEVP_PKEY\-EC\s0\fR\|(7)
  1487. .IP "\(bu" 4
  1488. \&\fBEC_KEY_dup()\fR, \fBEC_KEY_copy()\fR
  1489. .Sp
  1490. There is no direct replacement. Applications may use \fBEVP_PKEY_copy_parameters\fR\|(3)
  1491. and \fBEVP_PKEY_dup\fR\|(3) instead.
  1492. .IP "\(bu" 4
  1493. \&\fBEC_KEY_decoded_from_explicit_params()\fR
  1494. .Sp
  1495. There is no replacement.
  1496. .IP "\(bu" 4
  1497. \&\fBEC_KEY_generate_key()\fR
  1498. .Sp
  1499. See \*(L"Deprecated low-level key generation functions\*(R".
  1500. .IP "\(bu" 4
  1501. \&\fBEC_KEY_get0_group()\fR, \fBEC_KEY_get0_private_key()\fR, \fBEC_KEY_get0_public_key()\fR,
  1502. \&\fBEC_KEY_get_conv_form()\fR, \fBEC_KEY_get_enc_flags()\fR
  1503. .Sp
  1504. See \*(L"Deprecated low-level key parameter getters\*(R".
  1505. .IP "\(bu" 4
  1506. \&\fBEC_KEY_get0_engine()\fR, \fBEC_KEY_get_default_method()\fR, \fBEC_KEY_get_method()\fR,
  1507. \&\fBEC_KEY_new_method()\fR, \fBEC_KEY_get_ex_data()\fR, \fBEC_KEY_OpenSSL()\fR,
  1508. \&\fBEC_KEY_set_ex_data()\fR, \fBEC_KEY_set_default_method()\fR, EC_KEY_METHOD_*(),
  1509. \&\fBEC_KEY_set_method()\fR
  1510. .Sp
  1511. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R"
  1512. .IP "\(bu" 4
  1513. \&\fBEC_METHOD_get_field_type()\fR
  1514. .Sp
  1515. Use \fBEC_GROUP_get_field_type\fR\|(3) instead.
  1516. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R"
  1517. .IP "\(bu" 4
  1518. \&\fBEC_KEY_key2buf()\fR, \fBEC_KEY_oct2key()\fR, \fBEC_KEY_oct2priv()\fR, \fBEC_KEY_priv2buf()\fR,
  1519. \&\fBEC_KEY_priv2oct()\fR
  1520. .Sp
  1521. There are no replacements for these.
  1522. .IP "\(bu" 4
  1523. \&\fBEC_KEY_new()\fR, \fBEC_KEY_new_by_curve_name()\fR, \fBEC_KEY_free()\fR, \fBEC_KEY_up_ref()\fR
  1524. .Sp
  1525. See \*(L"Deprecated low-level object creation\*(R"
  1526. .IP "\(bu" 4
  1527. \&\fBEC_KEY_print()\fR, \fBEC_KEY_print_fp()\fR
  1528. .Sp
  1529. See \*(L"Deprecated low-level key printing functions\*(R"
  1530. .IP "\(bu" 4
  1531. \&\fBEC_KEY_set_asn1_flag()\fR, \fBEC_KEY_set_conv_form()\fR, \fBEC_KEY_set_enc_flags()\fR
  1532. .Sp
  1533. See \*(L"Deprecated low-level key parameter setters\*(R".
  1534. .IP "\(bu" 4
  1535. \&\fBEC_KEY_set_group()\fR, \fBEC_KEY_set_private_key()\fR, \fBEC_KEY_set_public_key()\fR,
  1536. \&\fBEC_KEY_set_public_key_affine_coordinates()\fR
  1537. .Sp
  1538. See \*(L"Deprecated low-level key parameter setters\*(R".
  1539. .IP "\(bu" 4
  1540. \&\fBECParameters_print()\fR, \fBECParameters_print_fp()\fR, \fBECPKParameters_print()\fR,
  1541. \&\fBECPKParameters_print_fp()\fR
  1542. .Sp
  1543. See \*(L"Deprecated low-level key printing functions\*(R"
  1544. .IP "\(bu" 4
  1545. \&\fBEC_POINT_bn2point()\fR, \fBEC_POINT_point2bn()\fR
  1546. .Sp
  1547. These functions were not particularly useful, since \s-1EC\s0 point serialization
  1548. formats are not individual big-endian integers.
  1549. .IP "\(bu" 4
  1550. \&\fBEC_POINT_get_affine_coordinates_GF2m()\fR, \fBEC_POINT_get_affine_coordinates_GFp()\fR,
  1551. \&\fBEC_POINT_set_affine_coordinates_GF2m()\fR, \fBEC_POINT_set_affine_coordinates_GFp()\fR
  1552. .Sp
  1553. Applications should use \fBEC_POINT_get_affine_coordinates\fR\|(3) and
  1554. \&\fBEC_POINT_set_affine_coordinates\fR\|(3) instead.
  1555. .IP "\(bu" 4
  1556. \&\fBEC_POINT_get_Jprojective_coordinates_GFp()\fR, \fBEC_POINT_set_Jprojective_coordinates_GFp()\fR
  1557. .Sp
  1558. These functions are not widely used. Applications should instead use the
  1559. \&\fBEC_POINT_set_affine_coordinates\fR\|(3) and \fBEC_POINT_get_affine_coordinates\fR\|(3)
  1560. functions.
  1561. .IP "\(bu" 4
  1562. \&\fBEC_POINT_make_affine()\fR, \fBEC_POINTs_make_affine()\fR
  1563. .Sp
  1564. There is no replacement. These functions were not widely used, and OpenSSL
  1565. automatically performs this conversion when needed.
  1566. .IP "\(bu" 4
  1567. \&\fBEC_POINT_set_compressed_coordinates_GF2m()\fR, \fBEC_POINT_set_compressed_coordinates_GFp()\fR
  1568. .Sp
  1569. Applications should use \fBEC_POINT_set_compressed_coordinates\fR\|(3) instead.
  1570. .IP "\(bu" 4
  1571. \&\fBEC_POINTs_mul()\fR
  1572. .Sp
  1573. This function is not widely used. Applications should instead use the
  1574. \&\fBEC_POINT_mul\fR\|(3) function.
  1575. .IP "\(bu" 4
  1576. \&\fBENGINE_*()\fR
  1577. .Sp
  1578. All engine functions are deprecated. An engine should be rewritten as a provider.
  1579. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R".
  1580. .IP "\(bu" 4
  1581. \&\fBERR_load_*()\fR, \fBERR_func_error_string()\fR, \fBERR_get_error_line()\fR,
  1582. \&\fBERR_get_error_line_data()\fR, \fBERR_get_state()\fR
  1583. .Sp
  1584. OpenSSL now loads error strings automatically so these functions are not needed.
  1585. .IP "\(bu" 4
  1586. \&\fBERR_peek_error_line_data()\fR, \fBERR_peek_last_error_line_data()\fR
  1587. .Sp
  1588. The new functions are \fBERR_peek_error_func\fR\|(3), \fBERR_peek_last_error_func\fR\|(3),
  1589. \&\fBERR_peek_error_data\fR\|(3), \fBERR_peek_last_error_data\fR\|(3), \fBERR_get_error_all\fR\|(3),
  1590. \&\fBERR_peek_error_all\fR\|(3) and \fBERR_peek_last_error_all\fR\|(3).
  1591. Applications should use \fBERR_get_error_all\fR\|(3), or pick information
  1592. with ERR_peek functions and finish off with getting the error code by using
  1593. \&\fBERR_get_error\fR\|(3).
  1594. .IP "\(bu" 4
  1595. \&\fBEVP_CIPHER_CTX_iv()\fR, \fBEVP_CIPHER_CTX_iv_noconst()\fR, \fBEVP_CIPHER_CTX_original_iv()\fR
  1596. .Sp
  1597. Applications should instead use \fBEVP_CIPHER_CTX_get_updated_iv\fR\|(3),
  1598. \&\fBEVP_CIPHER_CTX_get_updated_iv\fR\|(3) and \fBEVP_CIPHER_CTX_get_original_iv\fR\|(3)
  1599. respectively.
  1600. See \fBEVP_CIPHER_CTX_get_original_iv\fR\|(3) for further information.
  1601. .IP "\(bu" 4
  1602. \&\fBEVP_CIPHER_meth_*()\fR, \fBEVP_MD_CTX_set_update_fn()\fR, \fBEVP_MD_CTX_update_fn()\fR,
  1603. \&\fBEVP_MD_meth_*()\fR
  1604. .Sp
  1605. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R".
  1606. .IP "\(bu" 4
  1607. \&\s-1\fBEVP_PKEY_CTRL_PKCS7_ENCRYPT\s0()\fR, \s-1\fBEVP_PKEY_CTRL_PKCS7_DECRYPT\s0()\fR,
  1608. \&\s-1\fBEVP_PKEY_CTRL_PKCS7_SIGN\s0()\fR, \s-1\fBEVP_PKEY_CTRL_CMS_ENCRYPT\s0()\fR,
  1609. \&\s-1\fBEVP_PKEY_CTRL_CMS_DECRYPT\s0()\fR, and \s-1\fBEVP_PKEY_CTRL_CMS_SIGN\s0()\fR
  1610. .Sp
  1611. These control operations are not invoked by the OpenSSL library anymore and
  1612. are replaced by direct checks of the key operation against the key type
  1613. when the operation is initialized.
  1614. .IP "\(bu" 4
  1615. \&\fBEVP_PKEY_CTX_get0_dh_kdf_ukm()\fR, \fBEVP_PKEY_CTX_get0_ecdh_kdf_ukm()\fR
  1616. .Sp
  1617. See the \*(L"kdf-ukm\*(R" item in \*(L"\s-1DH\s0 key exchange parameters\*(R" in \s-1\fBEVP_KEYEXCH\-DH\s0\fR\|(7) and
  1618. \&\*(L"\s-1ECDH\s0 Key Exchange parameters\*(R" in \s-1\fBEVP_KEYEXCH\-ECDH\s0\fR\|(7).
  1619. These functions are obsolete and should not be required.
  1620. .IP "\(bu" 4
  1621. \&\fBEVP_PKEY_CTX_set_rsa_keygen_pubexp()\fR
  1622. .Sp
  1623. Applications should use \fBEVP_PKEY_CTX_set1_rsa_keygen_pubexp\fR\|(3) instead.
  1624. .IP "\(bu" 4
  1625. \&\fBEVP_PKEY_cmp()\fR, \fBEVP_PKEY_cmp_parameters()\fR
  1626. .Sp
  1627. Applications should use \fBEVP_PKEY_eq\fR\|(3) and \fBEVP_PKEY_parameters_eq\fR\|(3) instead.
  1628. See \fBEVP_PKEY_copy_parameters\fR\|(3) for further details.
  1629. .IP "\(bu" 4
  1630. \&\fBEVP_PKEY_encrypt_old()\fR, \fBEVP_PKEY_decrypt_old()\fR,
  1631. .Sp
  1632. Applications should use \fBEVP_PKEY_encrypt_init\fR\|(3) and \fBEVP_PKEY_encrypt\fR\|(3) or
  1633. \&\fBEVP_PKEY_decrypt_init\fR\|(3) and \fBEVP_PKEY_decrypt\fR\|(3) instead.
  1634. .IP "\(bu" 4
  1635. \&\fBEVP_PKEY_get0()\fR
  1636. .Sp
  1637. This function returns \s-1NULL\s0 if the key comes from a provider.
  1638. .IP "\(bu" 4
  1639. \&\fBEVP_PKEY_get0_DH()\fR, \fBEVP_PKEY_get0_DSA()\fR, \fBEVP_PKEY_get0_EC_KEY()\fR, \fBEVP_PKEY_get0_RSA()\fR,
  1640. \&\fBEVP_PKEY_get1_DH()\fR, \fBEVP_PKEY_get1_DSA()\fR, EVP_PKEY_get1_EC_KEY and \fBEVP_PKEY_get1_RSA()\fR,
  1641. \&\fBEVP_PKEY_get0_hmac()\fR, \fBEVP_PKEY_get0_poly1305()\fR, \fBEVP_PKEY_get0_siphash()\fR
  1642. .Sp
  1643. See \*(L"Functions that return an internal key should be treated as read only\*(R".
  1644. .IP "\(bu" 4
  1645. \&\fBEVP_PKEY_meth_*()\fR
  1646. .Sp
  1647. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R".
  1648. .IP "\(bu" 4
  1649. \&\fBEVP_PKEY_new_CMAC_key()\fR
  1650. .Sp
  1651. See \*(L"Deprecated low-level \s-1MAC\s0 functions\*(R".
  1652. .IP "\(bu" 4
  1653. \&\fBEVP_PKEY_assign()\fR, \fBEVP_PKEY_set1_DH()\fR, \fBEVP_PKEY_set1_DSA()\fR,
  1654. \&\fBEVP_PKEY_set1_EC_KEY()\fR, \fBEVP_PKEY_set1_RSA()\fR
  1655. .Sp
  1656. See \*(L"Deprecated low-level key object getters and setters\*(R"
  1657. .IP "\(bu" 4
  1658. \&\fBEVP_PKEY_set1_tls_encodedpoint()\fR \fBEVP_PKEY_get1_tls_encodedpoint()\fR
  1659. .Sp
  1660. These functions were previously used by libssl to set or get an encoded public
  1661. key into/from an \s-1EVP_PKEY\s0 object. With OpenSSL 3.0 these are replaced by the more
  1662. generic functions \fBEVP_PKEY_set1_encoded_public_key\fR\|(3) and
  1663. \&\fBEVP_PKEY_get1_encoded_public_key\fR\|(3).
  1664. The old versions have been converted to deprecated macros that just call the
  1665. new functions.
  1666. .IP "\(bu" 4
  1667. \&\fBEVP_PKEY_set1_engine()\fR, \fBEVP_PKEY_get0_engine()\fR
  1668. .Sp
  1669. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R".
  1670. .IP "\(bu" 4
  1671. \&\fBEVP_PKEY_set_alias_type()\fR
  1672. .Sp
  1673. This function has been removed. There is no replacement.
  1674. See \*(L"\fBEVP_PKEY_set_alias_type()\fR method has been removed\*(R"
  1675. .IP "\(bu" 4
  1676. \&\fBHMAC_Init_ex()\fR, \fBHMAC_Update()\fR, \fBHMAC_Final()\fR, \fBHMAC_size()\fR
  1677. .Sp
  1678. See \*(L"Deprecated low-level \s-1MAC\s0 functions\*(R".
  1679. .IP "\(bu" 4
  1680. \&\fBHMAC_CTX_new()\fR, \fBHMAC_CTX_free()\fR, \fBHMAC_CTX_copy()\fR, \fBHMAC_CTX_reset()\fR,
  1681. \&\fBHMAC_CTX_set_flags()\fR, \fBHMAC_CTX_get_md()\fR
  1682. .Sp
  1683. See \*(L"Deprecated low-level \s-1MAC\s0 functions\*(R".
  1684. .IP "\(bu" 4
  1685. \&\fBi2d_DHparams()\fR, \fBi2d_DHxparams()\fR
  1686. .Sp
  1687. See \*(L"Deprecated low-level key reading and writing functions\*(R"
  1688. and \*(L"Migration\*(R" in \fBd2i_RSAPrivateKey\fR\|(3)
  1689. .IP "\(bu" 4
  1690. \&\fBi2d_DSAparams()\fR, \fBi2d_DSAPrivateKey()\fR, \fBi2d_DSAPrivateKey_bio()\fR,
  1691. \&\fBi2d_DSAPrivateKey_fp()\fR, \fBi2d_DSA_PUBKEY()\fR, \fBi2d_DSA_PUBKEY_bio()\fR,
  1692. \&\fBi2d_DSA_PUBKEY_fp()\fR, \fBi2d_DSAPublicKey()\fR
  1693. .Sp
  1694. See \*(L"Deprecated low-level key reading and writing functions\*(R"
  1695. and \*(L"Migration\*(R" in \fBd2i_RSAPrivateKey\fR\|(3)
  1696. .IP "\(bu" 4
  1697. \&\fBi2d_ECParameters()\fR, \fBi2d_ECPrivateKey()\fR, \fBi2d_ECPrivateKey_bio()\fR,
  1698. \&\fBi2d_ECPrivateKey_fp()\fR, \fBi2d_EC_PUBKEY()\fR, \fBi2d_EC_PUBKEY_bio()\fR,
  1699. \&\fBi2d_EC_PUBKEY_fp()\fR
  1700. .Sp
  1701. See \*(L"Deprecated low-level key reading and writing functions\*(R"
  1702. and \*(L"Migration\*(R" in \fBd2i_RSAPrivateKey\fR\|(3)
  1703. .IP "\(bu" 4
  1704. \&\fBi2o_ECPublicKey()\fR
  1705. .Sp
  1706. Use \fBEVP_PKEY_get1_encoded_public_key\fR\|(3).
  1707. See \*(L"Deprecated low-level key parameter getters\*(R"
  1708. .IP "\(bu" 4
  1709. \&\fBi2d_RSAPrivateKey()\fR, \fBi2d_RSAPrivateKey_bio()\fR, \fBi2d_RSAPrivateKey_fp()\fR,
  1710. \&\fBi2d_RSA_PUBKEY()\fR, \fBi2d_RSA_PUBKEY_bio()\fR, \fBi2d_RSA_PUBKEY_fp()\fR,
  1711. \&\fBi2d_RSAPublicKey()\fR, \fBi2d_RSAPublicKey_bio()\fR, \fBi2d_RSAPublicKey_fp()\fR
  1712. .Sp
  1713. See \*(L"Deprecated low-level key reading and writing functions\*(R"
  1714. and \*(L"Migration\*(R" in \fBd2i_RSAPrivateKey\fR\|(3)
  1715. .IP "\(bu" 4
  1716. \&\fBIDEA_encrypt()\fR, \fBIDEA_set_decrypt_key()\fR, \fBIDEA_set_encrypt_key()\fR,
  1717. \&\fBIDEA_cbc_encrypt()\fR, \fBIDEA_cfb64_encrypt()\fR, \fBIDEA_ecb_encrypt()\fR,
  1718. \&\fBIDEA_ofb64_encrypt()\fR
  1719. .Sp
  1720. See \*(L"Deprecated low-level encryption functions\*(R".
  1721. \&\s-1IDEA\s0 has been moved to the Legacy Provider.
  1722. .IP "\(bu" 4
  1723. \&\fBIDEA_options()\fR
  1724. .Sp
  1725. There is no replacement. This function returned a constant string.
  1726. .IP "\(bu" 4
  1727. \&\s-1\fBMD2\s0()\fR, \fBMD2_Init()\fR, \fBMD2_Update()\fR, \fBMD2_Final()\fR
  1728. .Sp
  1729. See \*(L"Deprecated low-level encryption functions\*(R".
  1730. \&\s-1MD2\s0 has been moved to the Legacy Provider.
  1731. .IP "\(bu" 4
  1732. \&\fBMD2_options()\fR
  1733. .Sp
  1734. There is no replacement. This function returned a constant string.
  1735. .IP "\(bu" 4
  1736. \&\s-1\fBMD4\s0()\fR, \fBMD4_Init()\fR, \fBMD4_Update()\fR, \fBMD4_Final()\fR, \fBMD4_Transform()\fR
  1737. .Sp
  1738. See \*(L"Deprecated low-level encryption functions\*(R".
  1739. \&\s-1MD4\s0 has been moved to the Legacy Provider.
  1740. .IP "\(bu" 4
  1741. \&\s-1\fBMDC2\s0()\fR, \fBMDC2_Init()\fR, \fBMDC2_Update()\fR, \fBMDC2_Final()\fR
  1742. .Sp
  1743. See \*(L"Deprecated low-level encryption functions\*(R".
  1744. \&\s-1MDC2\s0 has been moved to the Legacy Provider.
  1745. .IP "\(bu" 4
  1746. \&\s-1\fBMD5\s0()\fR, \fBMD5_Init()\fR, \fBMD5_Update()\fR, \fBMD5_Final()\fR, \fBMD5_Transform()\fR
  1747. .Sp
  1748. See \*(L"Deprecated low-level encryption functions\*(R".
  1749. .IP "\(bu" 4
  1750. \&\s-1\fBNCONF_WIN32\s0()\fR
  1751. .Sp
  1752. This undocumented function has no replacement.
  1753. See \*(L"\s-1HISTORY\*(R"\s0 in \fBconfig\fR\|(5) for more details.
  1754. .IP "\(bu" 4
  1755. \&\fBOCSP_parse_url()\fR
  1756. .Sp
  1757. Use \fBOSSL_HTTP_parse_url\fR\|(3) instead.
  1758. .IP "\(bu" 4
  1759. \&\fB\s-1OCSP_REQ_CTX\s0\fR type and \fBOCSP_REQ_CTX_*()\fR functions
  1760. .Sp
  1761. These methods were used to collect all necessary data to form a \s-1HTTP\s0 request,
  1762. and to perform the \s-1HTTP\s0 transfer with that request. With OpenSSL 3.0, the
  1763. type is \fB\s-1OSSL_HTTP_REQ_CTX\s0\fR, and the deprecated functions are replaced
  1764. with \fBOSSL_HTTP_REQ_CTX_*()\fR. See \s-1\fBOSSL_HTTP_REQ_CTX\s0\fR\|(3) for additional
  1765. details.
  1766. .IP "\(bu" 4
  1767. \&\fBOPENSSL_fork_child()\fR, \fBOPENSSL_fork_parent()\fR, \fBOPENSSL_fork_prepare()\fR
  1768. .Sp
  1769. There is no replacement for these functions. These pthread fork support methods
  1770. were unused by OpenSSL.
  1771. .IP "\(bu" 4
  1772. \&\fBOSSL_STORE_ctrl()\fR, \fBOSSL_STORE_do_all_loaders()\fR, \fBOSSL_STORE_LOADER_get0_engine()\fR,
  1773. \&\fBOSSL_STORE_LOADER_get0_scheme()\fR, \fBOSSL_STORE_LOADER_new()\fR,
  1774. \&\fBOSSL_STORE_LOADER_set_attach()\fR, \fBOSSL_STORE_LOADER_set_close()\fR,
  1775. \&\fBOSSL_STORE_LOADER_set_ctrl()\fR, \fBOSSL_STORE_LOADER_set_eof()\fR,
  1776. \&\fBOSSL_STORE_LOADER_set_error()\fR, \fBOSSL_STORE_LOADER_set_expect()\fR,
  1777. \&\fBOSSL_STORE_LOADER_set_find()\fR, \fBOSSL_STORE_LOADER_set_load()\fR,
  1778. \&\fBOSSL_STORE_LOADER_set_open()\fR, \fBOSSL_STORE_LOADER_set_open_ex()\fR,
  1779. \&\fBOSSL_STORE_register_loader()\fR, \fBOSSL_STORE_unregister_loader()\fR,
  1780. \&\fBOSSL_STORE_vctrl()\fR
  1781. .Sp
  1782. These functions helped applications and engines create loaders for
  1783. schemes they supported. These are all deprecated and discouraged in favour of
  1784. provider implementations, see \fBprovider\-storemgmt\fR\|(7).
  1785. .IP "\(bu" 4
  1786. \&\fBPEM_read_DHparams()\fR, \fBPEM_read_bio_DHparams()\fR,
  1787. \&\fBPEM_read_DSAparams()\fR, \fBPEM_read_bio_DSAparams()\fR,
  1788. \&\fBPEM_read_DSAPrivateKey()\fR, \fBPEM_read_DSA_PUBKEY()\fR,
  1789. PEM_read_bio_DSAPrivateKey and \fBPEM_read_bio_DSA_PUBKEY()\fR,
  1790. \&\fBPEM_read_ECPKParameters()\fR, \fBPEM_read_ECPrivateKey()\fR, \fBPEM_read_EC_PUBKEY()\fR,
  1791. \&\fBPEM_read_bio_ECPKParameters()\fR, \fBPEM_read_bio_ECPrivateKey()\fR, \fBPEM_read_bio_EC_PUBKEY()\fR,
  1792. \&\fBPEM_read_RSAPrivateKey()\fR, \fBPEM_read_RSA_PUBKEY()\fR, \fBPEM_read_RSAPublicKey()\fR,
  1793. \&\fBPEM_read_bio_RSAPrivateKey()\fR, \fBPEM_read_bio_RSA_PUBKEY()\fR, \fBPEM_read_bio_RSAPublicKey()\fR,
  1794. \&\fBPEM_write_bio_DHparams()\fR, \fBPEM_write_bio_DHxparams()\fR, \fBPEM_write_DHparams()\fR, \fBPEM_write_DHxparams()\fR,
  1795. \&\fBPEM_write_DSAparams()\fR, \fBPEM_write_DSAPrivateKey()\fR, \fBPEM_write_DSA_PUBKEY()\fR,
  1796. \&\fBPEM_write_bio_DSAparams()\fR, \fBPEM_write_bio_DSAPrivateKey()\fR, \fBPEM_write_bio_DSA_PUBKEY()\fR,
  1797. \&\fBPEM_write_ECPKParameters()\fR, \fBPEM_write_ECPrivateKey()\fR, \fBPEM_write_EC_PUBKEY()\fR,
  1798. \&\fBPEM_write_bio_ECPKParameters()\fR, \fBPEM_write_bio_ECPrivateKey()\fR, \fBPEM_write_bio_EC_PUBKEY()\fR,
  1799. \&\fBPEM_write_RSAPrivateKey()\fR, \fBPEM_write_RSA_PUBKEY()\fR, \fBPEM_write_RSAPublicKey()\fR,
  1800. \&\fBPEM_write_bio_RSAPrivateKey()\fR, \fBPEM_write_bio_RSA_PUBKEY()\fR,
  1801. \&\fBPEM_write_bio_RSAPublicKey()\fR,
  1802. .Sp
  1803. See \*(L"Deprecated low-level key reading and writing functions\*(R"
  1804. .IP "\(bu" 4
  1805. \&\s-1\fBPKCS1_MGF1\s0()\fR
  1806. .Sp
  1807. See \*(L"Deprecated low-level encryption functions\*(R".
  1808. .IP "\(bu" 4
  1809. \&\fBRAND_get_rand_method()\fR, \fBRAND_set_rand_method()\fR, \fBRAND_OpenSSL()\fR,
  1810. \&\fBRAND_set_rand_engine()\fR
  1811. .Sp
  1812. Applications should instead use \fBRAND_set_DRBG_type\fR\|(3),
  1813. \&\s-1\fBEVP_RAND\s0\fR\|(3) and \s-1\fBEVP_RAND\s0\fR\|(7).
  1814. See \fBRAND_set_rand_method\fR\|(3) for more details.
  1815. .IP "\(bu" 4
  1816. \&\fBRC2_encrypt()\fR, \fBRC2_decrypt()\fR, \fBRC2_set_key()\fR, \fBRC2_cbc_encrypt()\fR, \fBRC2_cfb64_encrypt()\fR,
  1817. \&\fBRC2_ecb_encrypt()\fR, \fBRC2_ofb64_encrypt()\fR,
  1818. \&\s-1\fBRC4\s0()\fR, \fBRC4_set_key()\fR, \fBRC4_options()\fR,
  1819. \&\fBRC5_32_encrypt()\fR, \fBRC5_32_set_key()\fR, \fBRC5_32_decrypt()\fR, \fBRC5_32_cbc_encrypt()\fR,
  1820. \&\fBRC5_32_cfb64_encrypt()\fR, \fBRC5_32_ecb_encrypt()\fR, \fBRC5_32_ofb64_encrypt()\fR
  1821. .Sp
  1822. See \*(L"Deprecated low-level encryption functions\*(R".
  1823. The Algorithms \*(L"\s-1RC2\*(R", \*(L"RC4\*(R"\s0 and \*(L"\s-1RC5\*(R"\s0 have been moved to the Legacy Provider.
  1824. .IP "\(bu" 4
  1825. \&\s-1\fBRIPEMD160\s0()\fR, \fBRIPEMD160_Init()\fR, \fBRIPEMD160_Update()\fR, \fBRIPEMD160_Final()\fR,
  1826. \&\fBRIPEMD160_Transform()\fR
  1827. .Sp
  1828. See \*(L"Deprecated low-level digest functions\*(R".
  1829. The \s-1RIPE\s0 algorithm has been moved to the Legacy Provider.
  1830. .IP "\(bu" 4
  1831. \&\fBRSA_bits()\fR, \fBRSA_security_bits()\fR, \fBRSA_size()\fR
  1832. .Sp
  1833. Use \fBEVP_PKEY_get_bits\fR\|(3), \fBEVP_PKEY_get_security_bits\fR\|(3) and
  1834. \&\fBEVP_PKEY_get_size\fR\|(3).
  1835. .IP "\(bu" 4
  1836. \&\fBRSA_check_key()\fR, \fBRSA_check_key_ex()\fR
  1837. .Sp
  1838. See \*(L"Deprecated low-level validation functions\*(R"
  1839. .IP "\(bu" 4
  1840. \&\fBRSA_clear_flags()\fR, \fBRSA_flags()\fR, \fBRSA_set_flags()\fR, \fBRSA_test_flags()\fR,
  1841. \&\fBRSA_setup_blinding()\fR, \fBRSA_blinding_off()\fR, \fBRSA_blinding_on()\fR
  1842. .Sp
  1843. All of these \s-1RSA\s0 flags have been deprecated without replacement:
  1844. .Sp
  1845. \&\fB\s-1RSA_FLAG_BLINDING\s0\fR, \fB\s-1RSA_FLAG_CACHE_PRIVATE\s0\fR, \fB\s-1RSA_FLAG_CACHE_PUBLIC\s0\fR,
  1846. \&\fB\s-1RSA_FLAG_EXT_PKEY\s0\fR, \fB\s-1RSA_FLAG_NO_BLINDING\s0\fR, \fB\s-1RSA_FLAG_THREAD_SAFE\s0\fR
  1847. \&\fB\s-1RSA_METHOD_FLAG_NO_CHECK\s0\fR
  1848. .IP "\(bu" 4
  1849. \&\fBRSA_generate_key_ex()\fR, \fBRSA_generate_multi_prime_key()\fR
  1850. .Sp
  1851. See \*(L"Deprecated low-level key generation functions\*(R".
  1852. .IP "\(bu" 4
  1853. \&\fBRSA_get0_engine()\fR
  1854. .Sp
  1855. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R"
  1856. .IP "\(bu" 4
  1857. \&\fBRSA_get0_crt_params()\fR, \fBRSA_get0_d()\fR, \fBRSA_get0_dmp1()\fR, \fBRSA_get0_dmq1()\fR,
  1858. \&\fBRSA_get0_e()\fR, \fBRSA_get0_factors()\fR, \fBRSA_get0_iqmp()\fR, \fBRSA_get0_key()\fR,
  1859. \&\fBRSA_get0_multi_prime_crt_params()\fR, \fBRSA_get0_multi_prime_factors()\fR, \fBRSA_get0_n()\fR,
  1860. \&\fBRSA_get0_p()\fR, \fBRSA_get0_pss_params()\fR, \fBRSA_get0_q()\fR,
  1861. \&\fBRSA_get_multi_prime_extra_count()\fR
  1862. .Sp
  1863. See \*(L"Deprecated low-level key parameter getters\*(R"
  1864. .IP "\(bu" 4
  1865. \&\fBRSA_new()\fR, \fBRSA_free()\fR, \fBRSA_up_ref()\fR
  1866. .Sp
  1867. See \*(L"Deprecated low-level object creation\*(R".
  1868. .IP "\(bu" 4
  1869. \&\fBRSA_get_default_method()\fR, RSA_get_ex_data and \fBRSA_get_method()\fR
  1870. .Sp
  1871. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R".
  1872. .IP "\(bu" 4
  1873. \&\fBRSA_get_version()\fR
  1874. .Sp
  1875. There is no replacement.
  1876. .IP "\(bu" 4
  1877. \&\fBRSA_meth_*()\fR, \fBRSA_new_method()\fR, RSA_null_method and \fBRSA_PKCS1_OpenSSL()\fR
  1878. .Sp
  1879. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R".
  1880. .IP "\(bu" 4
  1881. \&\fBRSA_padding_add_*()\fR, \fBRSA_padding_check_*()\fR
  1882. .Sp
  1883. See \*(L"Deprecated low-level signing functions\*(R" and
  1884. \&\*(L"Deprecated low-level encryption functions\*(R".
  1885. .IP "\(bu" 4
  1886. \&\fBRSA_print()\fR, \fBRSA_print_fp()\fR
  1887. .Sp
  1888. See \*(L"Deprecated low-level key printing functions\*(R"
  1889. .IP "\(bu" 4
  1890. \&\fBRSA_public_encrypt()\fR, \fBRSA_private_decrypt()\fR
  1891. .Sp
  1892. See \*(L"Deprecated low-level encryption functions\*(R"
  1893. .IP "\(bu" 4
  1894. \&\fBRSA_private_encrypt()\fR, \fBRSA_public_decrypt()\fR
  1895. .Sp
  1896. This is equivalent to doing sign and verify recover operations (with a padding
  1897. mode of none). See \*(L"Deprecated low-level signing functions\*(R".
  1898. .IP "\(bu" 4
  1899. \&\fBRSAPrivateKey_dup()\fR, \fBRSAPublicKey_dup()\fR
  1900. .Sp
  1901. There is no direct replacement. Applications may use \fBEVP_PKEY_dup\fR\|(3).
  1902. .IP "\(bu" 4
  1903. \&\fBRSAPublicKey_it()\fR, \fBRSAPrivateKey_it()\fR
  1904. .Sp
  1905. See \*(L"Deprecated low-level key reading and writing functions\*(R"
  1906. .IP "\(bu" 4
  1907. \&\fBRSA_set0_crt_params()\fR, \fBRSA_set0_factors()\fR, \fBRSA_set0_key()\fR,
  1908. \&\fBRSA_set0_multi_prime_params()\fR
  1909. .Sp
  1910. See \*(L"Deprecated low-level key parameter setters\*(R".
  1911. .IP "\(bu" 4
  1912. \&\fBRSA_set_default_method()\fR, \fBRSA_set_method()\fR, \fBRSA_set_ex_data()\fR
  1913. .Sp
  1914. See \*(L"Providers are a replacement for engines and low-level method overrides\*(R"
  1915. .IP "\(bu" 4
  1916. \&\fBRSA_sign()\fR, \fBRSA_sign_ASN1_OCTET_STRING()\fR, \fBRSA_verify()\fR,
  1917. \&\fBRSA_verify_ASN1_OCTET_STRING()\fR, \fBRSA_verify_PKCS1_PSS()\fR,
  1918. \&\fBRSA_verify_PKCS1_PSS_mgf1()\fR
  1919. .Sp
  1920. See \*(L"Deprecated low-level signing functions\*(R".
  1921. .IP "\(bu" 4
  1922. \&\fBRSA_X931_derive_ex()\fR, \fBRSA_X931_generate_key_ex()\fR, \fBRSA_X931_hash_id()\fR
  1923. .Sp
  1924. There are no replacements for these functions.
  1925. X931 padding can be set using \*(L"Signature Parameters\*(R" in \s-1\fBEVP_SIGNATURE\-RSA\s0\fR\|(7).
  1926. See \fB\s-1OSSL_SIGNATURE_PARAM_PAD_MODE\s0\fR.
  1927. .IP "\(bu" 4
  1928. \&\fBSEED_encrypt()\fR, \fBSEED_decrypt()\fR, \fBSEED_set_key()\fR, \fBSEED_cbc_encrypt()\fR,
  1929. \&\fBSEED_cfb128_encrypt()\fR, \fBSEED_ecb_encrypt()\fR, \fBSEED_ofb128_encrypt()\fR
  1930. .Sp
  1931. See \*(L"Deprecated low-level encryption functions\*(R".
  1932. The \s-1SEED\s0 algorithm has been moved to the Legacy Provider.
  1933. .IP "\(bu" 4
  1934. \&\fBSHA1_Init()\fR, \fBSHA1_Update()\fR, \fBSHA1_Final()\fR, \fBSHA1_Transform()\fR,
  1935. \&\fBSHA224_Init()\fR, \fBSHA224_Update()\fR, \fBSHA224_Final()\fR,
  1936. \&\fBSHA256_Init()\fR, \fBSHA256_Update()\fR, \fBSHA256_Final()\fR, \fBSHA256_Transform()\fR,
  1937. \&\fBSHA384_Init()\fR, \fBSHA384_Update()\fR, \fBSHA384_Final()\fR,
  1938. \&\fBSHA512_Init()\fR, \fBSHA512_Update()\fR, \fBSHA512_Final()\fR, \fBSHA512_Transform()\fR
  1939. .Sp
  1940. See \*(L"Deprecated low-level digest functions\*(R".
  1941. .IP "\(bu" 4
  1942. \&\fBSRP_Calc_A()\fR, \fBSRP_Calc_B()\fR, \fBSRP_Calc_client_key()\fR, \fBSRP_Calc_server_key()\fR,
  1943. \&\fBSRP_Calc_u()\fR, \fBSRP_Calc_x()\fR, \fBSRP_check_known_gN_param()\fR, \fBSRP_create_verifier()\fR,
  1944. \&\fBSRP_create_verifier_BN()\fR, \fBSRP_get_default_gN()\fR, \fBSRP_user_pwd_free()\fR, \fBSRP_user_pwd_new()\fR,
  1945. \&\fBSRP_user_pwd_set0_sv()\fR, \fBSRP_user_pwd_set1_ids()\fR, \fBSRP_user_pwd_set_gN()\fR,
  1946. \&\fBSRP_VBASE_add0_user()\fR, \fBSRP_VBASE_free()\fR, \fBSRP_VBASE_get1_by_user()\fR, \fBSRP_VBASE_init()\fR,
  1947. \&\fBSRP_VBASE_new()\fR, \fBSRP_Verify_A_mod_N()\fR, \fBSRP_Verify_B_mod_N()\fR
  1948. .Sp
  1949. There are no replacements for the \s-1SRP\s0 functions.
  1950. .IP "\(bu" 4
  1951. \&\fBSSL_CTX_set_tmp_dh_callback()\fR, \fBSSL_set_tmp_dh_callback()\fR,
  1952. \&\fBSSL_CTX_set_tmp_dh()\fR, \fBSSL_set_tmp_dh()\fR
  1953. .Sp
  1954. These are used to set the Diffie-Hellman (\s-1DH\s0) parameters that are to be used by
  1955. servers requiring ephemeral \s-1DH\s0 keys. Instead applications should consider using
  1956. the built-in \s-1DH\s0 parameters that are available by calling \fBSSL_CTX_set_dh_auto\fR\|(3)
  1957. or \fBSSL_set_dh_auto\fR\|(3). If custom parameters are necessary then applications can
  1958. use the alternative functions \fBSSL_CTX_set0_tmp_dh_pkey\fR\|(3) and
  1959. \&\fBSSL_set0_tmp_dh_pkey\fR\|(3). There is no direct replacement for the \*(L"callback\*(R"
  1960. functions. The callback was originally useful in order to have different
  1961. parameters for export and non-export ciphersuites. Export ciphersuites are no
  1962. longer supported by OpenSSL. Use of the callback functions should be replaced
  1963. by one of the other methods described above.
  1964. .IP "\(bu" 4
  1965. \&\fBSSL_CTX_set_tlsext_ticket_key_cb()\fR
  1966. .Sp
  1967. Use the new \fBSSL_CTX_set_tlsext_ticket_key_evp_cb\fR\|(3) function instead.
  1968. .IP "\(bu" 4
  1969. \&\s-1\fBWHIRLPOOL\s0()\fR, \fBWHIRLPOOL_Init()\fR, \fBWHIRLPOOL_Update()\fR, \fBWHIRLPOOL_Final()\fR,
  1970. \&\fBWHIRLPOOL_BitUpdate()\fR
  1971. .Sp
  1972. See \*(L"Deprecated low-level digest functions\*(R".
  1973. The Whirlpool algorithm has been moved to the Legacy Provider.
  1974. .IP "\(bu" 4
  1975. \&\fBX509_certificate_type()\fR
  1976. .Sp
  1977. This was an undocumented function. Applications can use \fBX509_get0_pubkey\fR\|(3)
  1978. and \fBX509_get0_signature\fR\|(3) instead.
  1979. .IP "\(bu" 4
  1980. \&\fBX509_http_nbio()\fR, \fBX509_CRL_http_nbio()\fR
  1981. .Sp
  1982. Use \fBX509_load_http\fR\|(3) and \fBX509_CRL_load_http\fR\|(3) instead.
  1983. .PP
  1984. \fI\s-1NID\s0 handling for provided keys and algorithms\fR
  1985. .IX Subsection "NID handling for provided keys and algorithms"
  1986. .PP
  1987. The following functions for \s-1NID\s0 (numeric id) handling have changed semantics.
  1988. .IP "\(bu" 4
  1989. \&\fBEVP_PKEY_id()\fR, \fBEVP_PKEY_get_id()\fR
  1990. .Sp
  1991. This function was previously used to reliably return the \s-1NID\s0 of
  1992. an \s-1EVP_PKEY\s0 object, e.g., to look up the name of the algorithm of
  1993. such \s-1EVP_PKEY\s0 by calling \fBOBJ_nid2sn\fR\|(3). With the introduction
  1994. of \fBprovider\fR\|(7)s \fBEVP_PKEY_id()\fR or its new equivalent
  1995. \&\fBEVP_PKEY_get_id\fR\|(3) might now also return the value \-1
  1996. (\fB\s-1EVP_PKEY_KEYMGMT\s0\fR) indicating the use of a provider to
  1997. implement the \s-1EVP_PKEY\s0 object. Therefore, the use of
  1998. \&\fBEVP_PKEY_get0_type_name\fR\|(3) is recommended for retrieving
  1999. the name of the \s-1EVP_PKEY\s0 algorithm.
  2000. .SS "Using the \s-1FIPS\s0 Module in applications"
  2001. .IX Subsection "Using the FIPS Module in applications"
  2002. See \fBfips_module\fR\|(7) and \s-1\fBOSSL_PROVIDER\-FIPS\s0\fR\|(7) for details.
  2003. .SS "OpenSSL command line application changes"
  2004. .IX Subsection "OpenSSL command line application changes"
  2005. \fINew applications\fR
  2006. .IX Subsection "New applications"
  2007. .PP
  2008. \&\fBopenssl kdf\fR uses the new \s-1\fBEVP_KDF\s0\fR\|(3) \s-1API.\s0
  2009. \&\fBopenssl kdf\fR uses the new \s-1\fBEVP_MAC\s0\fR\|(3) \s-1API.\s0
  2010. .PP
  2011. \fIAdded options\fR
  2012. .IX Subsection "Added options"
  2013. .PP
  2014. \&\fB\-provider_path\fR and \fB\-provider\fR are available to all apps and can be used
  2015. multiple times to load any providers, such as the 'legacy' provider or third
  2016. party providers. If used then the 'default' provider would also need to be
  2017. specified if required. The \fB\-provider_path\fR must be specified before the
  2018. \&\fB\-provider\fR option.
  2019. .PP
  2020. The \fBlist\fR app has many new options. See \fBopenssl\-list\fR\|(1) for more
  2021. information.
  2022. .PP
  2023. \&\fB\-crl_lastupdate\fR and \fB\-crl_nextupdate\fR used by \fBopenssl ca\fR allows
  2024. explicit setting of fields in the generated \s-1CRL.\s0
  2025. .PP
  2026. \fIRemoved options\fR
  2027. .IX Subsection "Removed options"
  2028. .PP
  2029. Interactive mode is not longer available.
  2030. .PP
  2031. The \fB\-crypt\fR option used by \fBopenssl passwd\fR.
  2032. The \fB\-c\fR option used by \fBopenssl x509\fR, \fBopenssl dhparam\fR,
  2033. \&\fBopenssl dsaparam\fR, and \fBopenssl ecparam\fR.
  2034. .PP
  2035. \fIOther Changes\fR
  2036. .IX Subsection "Other Changes"
  2037. .PP
  2038. The output of Command line applications may have minor changes.
  2039. These are primarily changes in capitalisation and white space. However, in some
  2040. cases, there are additional differences.
  2041. For example, the \s-1DH\s0 parameters output from \fBopenssl dhparam\fR now lists 'P',
  2042. \&'Q', 'G' and 'pcounter' instead of 'prime', 'generator', 'subgroup order' and
  2043. \&'counter' respectively.
  2044. .PP
  2045. The \fBopenssl\fR commands that read keys, certificates, and CRLs now
  2046. automatically detect the \s-1PEM\s0 or \s-1DER\s0 format of the input files so it is not
  2047. necessary to explicitly specify the input format anymore. However if the
  2048. input format option is used the specified format will be required.
  2049. .PP
  2050. \&\fBopenssl speed\fR no longer uses low-level \s-1API\s0 calls.
  2051. This implies some of the performance numbers might not be comparable with the
  2052. previous releases due to higher overhead. This applies particularly to
  2053. measuring performance on smaller data chunks.
  2054. .PP
  2055. b<openssl dhparam>, \fBopenssl dsa\fR, \fBopenssl gendsa\fR, \fBopenssl dsaparam\fR,
  2056. \&\fBopenssl genrsa\fR and \fBopenssl rsa\fR have been modified to use \s-1PKEY\s0 APIs.
  2057. \&\fBopenssl genrsa\fR and \fBopenssl rsa\fR now write \s-1PKCS\s0 #8 keys by default.
  2058. .PP
  2059. \fIDefault settings\fR
  2060. .IX Subsection "Default settings"
  2061. .PP
  2062. \&\*(L"\s-1SHA256\*(R"\s0 is now the default digest for \s-1TS\s0 query used by \fBopenssl ts\fR.
  2063. .PP
  2064. \fIDeprecated apps\fR
  2065. .IX Subsection "Deprecated apps"
  2066. .PP
  2067. \&\fBopenssl rsautl\fR is deprecated, use \fBopenssl pkeyutl\fR instead.
  2068. \&\fBopenssl dhparam\fR, \fBopenssl dsa\fR, \fBopenssl gendsa\fR, \fBopenssl dsaparam\fR,
  2069. \&\fBopenssl genrsa\fR, \fBopenssl rsa\fR, \fBopenssl genrsa\fR and \fBopenssl rsa\fR are
  2070. now in maintenance mode and no new features will be added to them.
  2071. .SS "\s-1TLS\s0 Changes"
  2072. .IX Subsection "TLS Changes"
  2073. .IP "\(bu" 4
  2074. \&\s-1TLS 1.3 FFDHE\s0 key exchange support added
  2075. .Sp
  2076. This uses \s-1DH\s0 safe prime named groups.
  2077. .IP "\(bu" 4
  2078. Support for fully \*(L"pluggable\*(R" TLSv1.3 groups.
  2079. .Sp
  2080. This means that providers may supply their own group implementations (using
  2081. either the \*(L"key exchange\*(R" or the \*(L"key encapsulation\*(R" methods) which will
  2082. automatically be detected and used by libssl.
  2083. .IP "\(bu" 4
  2084. \&\s-1SSL\s0 and \s-1SSL_CTX\s0 options are now 64 bit instead of 32 bit.
  2085. .Sp
  2086. The signatures of the functions to get and set options on \s-1SSL\s0 and
  2087. \&\s-1SSL_CTX\s0 objects changed from \*(L"unsigned long\*(R" to \*(L"uint64_t\*(R" type.
  2088. .Sp
  2089. This may require source code changes. For example it is no longer possible
  2090. to use the \fB\s-1SSL_OP_\s0\fR macro values in preprocessor \f(CW\*(C`#if\*(C'\fR conditions.
  2091. However it is still possible to test whether these macros are defined or not.
  2092. .Sp
  2093. See \fBSSL_CTX_get_options\fR\|(3), \fBSSL_CTX_set_options\fR\|(3),
  2094. \&\fBSSL_get_options\fR\|(3) and \fBSSL_set_options\fR\|(3).
  2095. .IP "\(bu" 4
  2096. \&\fBSSL_set1_host()\fR and \fBSSL_add1_host()\fR Changes
  2097. .Sp
  2098. These functions now take \s-1IP\s0 literal addresses as well as actual hostnames.
  2099. .IP "\(bu" 4
  2100. Added \s-1SSL\s0 option \s-1SSL_OP_CLEANSE_PLAINTEXT\s0
  2101. .Sp
  2102. If the option is set, openssl cleanses (zeroizes) plaintext bytes from
  2103. internal buffers after delivering them to the application. Note,
  2104. the application is still responsible for cleansing other copies
  2105. (e.g.: data received by \fBSSL_read\fR\|(3)).
  2106. .IP "\(bu" 4
  2107. Client-initiated renegotiation is disabled by default.
  2108. .Sp
  2109. To allow it, use the \fB\-client_renegotiation\fR option,
  2110. the \fB\s-1SSL_OP_ALLOW_CLIENT_RENEGOTIATION\s0\fR flag, or the \f(CW\*(C`ClientRenegotiation\*(C'\fR
  2111. config parameter as appropriate.
  2112. .IP "\(bu" 4
  2113. Secure renegotiation is now required by default for \s-1TLS\s0 connections
  2114. .Sp
  2115. Support for \s-1RFC 5746\s0 secure renegotiation is now required by default for
  2116. \&\s-1SSL\s0 or \s-1TLS\s0 connections to succeed. Applications that require the ability
  2117. to connect to legacy peers will need to explicitly set
  2118. \&\s-1SSL_OP_LEGACY_SERVER_CONNECT.\s0 Accordingly, \s-1SSL_OP_LEGACY_SERVER_CONNECT\s0
  2119. is no longer set as part of \s-1SSL_OP_ALL.\s0
  2120. .IP "\(bu" 4
  2121. Combining the Configure options no-ec and no-dh no longer disables TLSv1.3
  2122. .Sp
  2123. Typically if OpenSSL has no \s-1EC\s0 or \s-1DH\s0 algorithms then it cannot support
  2124. connections with TLSv1.3. However OpenSSL now supports \*(L"pluggable\*(R" groups
  2125. through providers. Therefore third party providers may supply group
  2126. implementations even where there are no built-in ones. Attempting to create
  2127. \&\s-1TLS\s0 connections in such a build without also disabling TLSv1.3 at run time or
  2128. using third party provider groups may result in handshake failures. TLSv1.3
  2129. can be disabled at compile time using the \*(L"no\-tls1_3\*(R" Configure option.
  2130. .IP "\(bu" 4
  2131. \&\fBSSL_CTX_set_ciphersuites()\fR and \fBSSL_set_ciphersuites()\fR changes.
  2132. .Sp
  2133. The methods now ignore unknown ciphers.
  2134. .IP "\(bu" 4
  2135. Security callback change.
  2136. .Sp
  2137. The security callback, which can be customised by application code, supports
  2138. the security operation \s-1SSL_SECOP_TMP_DH.\s0 This is defined to take an \s-1EVP_PKEY\s0
  2139. in the \*(L"other\*(R" parameter. In most places this is what is passed. All these
  2140. places occur server side. However there was one client side call of this
  2141. security operation and it passed a \s-1DH\s0 object instead. This is incorrect
  2142. according to the definition of \s-1SSL_SECOP_TMP_DH,\s0 and is inconsistent with all
  2143. of the other locations. Therefore this client side call has been changed to
  2144. pass an \s-1EVP_PKEY\s0 instead.
  2145. .IP "\(bu" 4
  2146. New \s-1SSL\s0 option \s-1SSL_OP_IGNORE_UNEXPECTED_EOF\s0
  2147. .Sp
  2148. The \s-1SSL\s0 option \s-1SSL_OP_IGNORE_UNEXPECTED_EOF\s0 is introduced. If that option
  2149. is set, an unexpected \s-1EOF\s0 is ignored, it pretends a close notify was received
  2150. instead and so the returned error becomes \s-1SSL_ERROR_ZERO_RETURN.\s0
  2151. .IP "\(bu" 4
  2152. The security strength of \s-1SHA1\s0 and \s-1MD5\s0 based signatures in \s-1TLS\s0 has been reduced.
  2153. .Sp
  2154. This results in \s-1SSL 3, TLS 1.0, TLS 1.1\s0 and \s-1DTLS 1.0\s0 no longer
  2155. working at the default security level of 1 and instead requires security
  2156. level 0. The security level can be changed either using the cipher string
  2157. with \f(CW@SECLEVEL\fR, or calling \fBSSL_CTX_set_security_level\fR\|(3). This also means
  2158. that where the signature algorithms extension is missing from a ClientHello
  2159. then the handshake will fail in \s-1TLS 1.2\s0 at security level 1. This is because,
  2160. although this extension is optional, failing to provide one means that
  2161. OpenSSL will fallback to a default set of signature algorithms. This default
  2162. set requires the availability of \s-1SHA1.\s0
  2163. .IP "\(bu" 4
  2164. X509 certificates signed using \s-1SHA1\s0 are no longer allowed at security level 1 and above.
  2165. .Sp
  2166. In \s-1TLS/SSL\s0 the default security level is 1. It can be set either using the cipher
  2167. string with \f(CW@SECLEVEL\fR, or calling \fBSSL_CTX_set_security_level\fR\|(3). If the
  2168. leaf certificate is signed with \s-1SHA\-1,\s0 a call to \fBSSL_CTX_use_certificate\fR\|(3)
  2169. will fail if the security level is not lowered first.
  2170. Outside \s-1TLS/SSL,\s0 the default security level is \-1 (effectively 0). It can
  2171. be set using \fBX509_VERIFY_PARAM_set_auth_level\fR\|(3) or using the \fB\-auth_level\fR
  2172. options of the commands.
  2173. .SH "SEE ALSO"
  2174. .IX Header "SEE ALSO"
  2175. \&\fBfips_module\fR\|(7)
  2176. .SH "HISTORY"
  2177. .IX Header "HISTORY"
  2178. The migration guide was created for OpenSSL 3.0.
  2179. .SH "COPYRIGHT"
  2180. .IX Header "COPYRIGHT"
  2181. Copyright 2021\-2024 The OpenSSL Project Authors. All Rights Reserved.
  2182. .PP
  2183. Licensed under the Apache License 2.0 (the \*(L"License\*(R"). You may not use
  2184. this file except in compliance with the License. You can obtain a copy
  2185. in the file \s-1LICENSE\s0 in the source distribution or at
  2186. <https://www.openssl.org/source/license.html>.