Для расшифровки зашифрованных данных SM2 приложение должно вызывать функцию API EVP_PKEY_decrypt(). Обычно приложение вызывает эту функцию дважды. В первый раз при входе параметр «out» может быть NULL, а при выходе параметр «outlen» заполняется размером буфера, необходимым для хранения расшифрованного открытого текста.
Затем приложение может выделить буфер достаточного размера и снова вызвать EVP_PKEY_decrypt(), но на этот раз передать значение, отличное от NULL, для параметра "out". Ошибка в реализации кода расшифровки SM2 означает, что вычисление размера буфера, необходимого для удержания открытого текста, возвращаемого первым вызовом в EVP_PKEY_decrypt(), может быть меньше фактического размера, требуемого вторым вызовом. Это может привести к переполнению буфера, когда приложение вызывает EVP_PKEY_decrypt() во второй раз с буфером, который слишком мал.
Злоумышленник, который может представить содержимое SM2 для расшифровки в приложение, может привести к тому, что выбранные злоумышленником данные превысят буфер максимум на 62 байта, изменяя содержимое других данных, хранящихся после буфера, возможно, изменяя поведение приложения или вызывая сбой приложения. Расположение буфера зависит от приложения, но обычно выделяется куча. Исправлено в OpenSSL 1.1.1l (Affected 1.1.1-1.1.1k).
Показать оригинальное описание (EN)
In order to decrypt SM2 encrypted data an application is expected to call the API function EVP_PKEY_decrypt(). Typically an application will call this function twice. The first time, on entry, the "out" parameter can be NULL and, on exit, the "outlen" parameter is populated with the buffer size required to hold the decrypted plaintext. The application can then allocate a sufficiently sized buffer and call EVP_PKEY_decrypt() again, but this time passing a non-NULL value for the "out" parameter. A bug in the implementation of the SM2 decryption code means that the calculation of the buffer size required to hold the plaintext returned by the first call to EVP_PKEY_decrypt() can be smaller than the actual size required by the second call. This can lead to a buffer overflow when EVP_PKEY_decrypt() is called by the application a second time with a buffer that is too small. A malicious attacker who is able present SM2 content for decryption to an application could cause attacker chosen data to overflow the buffer by up to a maximum of 62 bytes altering the contents of other data held after the buffer, possibly changing application behaviour or causing the application to crash. The location of the buffer is application dependent but is typically heap allocated. Fixed in OpenSSL 1.1.1l (Affected 1.1.1-1.1.1k).
Характеристики атаки
Последствия
Строка CVSS v3.1
Тип уязвимости (CWE)
Уязвимые продукты 42
| Конфигурация | От (включительно) | До (исключительно) |
|---|---|---|
|
Openssl Openssl
cpe:2.3:a:openssl:openssl:*:*:*:*:*:*:*:*
|
1.1.1
|
1.1.1l
|
|
Debian Debian_Linux
cpe:2.3:o:debian:debian_linux:10.0:*:*:*:*:*:*:*
|
— | — |
|
Debian Debian_Linux
cpe:2.3:o:debian:debian_linux:11.0:*:*:*:*:*:*:*
|
— | — |
|
Netapp Active_Iq_Unified_Manager
cpe:2.3:a:netapp:active_iq_unified_manager:-:*:*:*:*:vmware_vsphere:*:*
|
— | — |
|
Netapp Active_Iq_Unified_Manager
cpe:2.3:a:netapp:active_iq_unified_manager:-:*:*:*:*:windows:*:*
|
— | — |
|
Netapp Clustered_Data_Ontap
cpe:2.3:a:netapp:clustered_data_ontap:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp Clustered_Data_Ontap_Antivirus_Connector
cpe:2.3:a:netapp:clustered_data_ontap_antivirus_connector:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp E-Series_Santricity_Os_Controller
cpe:2.3:a:netapp:e-series_santricity_os_controller:*:*:*:*:*:*:*:*
|
11.0
|
<= 11.50.2
|
|
Netapp Hci_Management_Node
cpe:2.3:a:netapp:hci_management_node:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp Manageability_Software_Development_Kit
cpe:2.3:a:netapp:manageability_software_development_kit:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp Oncommand_Insight
cpe:2.3:a:netapp:oncommand_insight:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp Oncommand_Workflow_Automation
cpe:2.3:a:netapp:oncommand_workflow_automation:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp Santricity_Smi-S_Provider
cpe:2.3:a:netapp:santricity_smi-s_provider:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp Snapcenter
cpe:2.3:a:netapp:snapcenter:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp Solidfire
cpe:2.3:a:netapp:solidfire:-:*:*:*:*:*:*:*
|
— | — |
|
Netapp Storage_Encryption
cpe:2.3:a:netapp:storage_encryption:-:*:*:*:*:*:*:*
|
— | — |
|
Oracle Communications_Cloud_Native_Core_Security_Edge_Protection_Proxy
cpe:2.3:a:oracle:communications_cloud_native_core_security_edge_protection_proxy:1.7.0:*:*:*:*:*:*:*
|
— | — |
|
Oracle Communications_Cloud_Native_Core_Unified_Data_Repository
cpe:2.3:a:oracle:communications_cloud_native_core_unified_data_repository:1.15.0:*:*:*:*:*:*:*
|
— | — |
|
Oracle Communications_Session_Border_Controller
cpe:2.3:a:oracle:communications_session_border_controller:8.4:*:*:*:*:*:*:*
|
— | — |
|
Oracle Communications_Session_Border_Controller
cpe:2.3:a:oracle:communications_session_border_controller:9.0:*:*:*:*:*:*:*
|
— | — |
|
Oracle Communications_Unified_Session_Manager
cpe:2.3:a:oracle:communications_unified_session_manager:8.2.5:*:*:*:*:*:*:*
|
— | — |
|
Oracle Communications_Unified_Session_Manager
cpe:2.3:a:oracle:communications_unified_session_manager:8.4.5:*:*:*:*:*:*:*
|
— | — |
|
Oracle Enterprise_Communications_Broker
cpe:2.3:a:oracle:enterprise_communications_broker:3.2.0:*:*:*:*:*:*:*
|
— | — |
|
Oracle Enterprise_Communications_Broker
cpe:2.3:a:oracle:enterprise_communications_broker:3.3.0:*:*:*:*:*:*:*
|
— | — |
|
Oracle Enterprise_Session_Border_Controller
cpe:2.3:a:oracle:enterprise_session_border_controller:8.4:*:*:*:*:*:*:*
|
— | — |
|
Oracle Enterprise_Session_Border_Controller
cpe:2.3:a:oracle:enterprise_session_border_controller:9.0:*:*:*:*:*:*:*
|
— | — |
|
Oracle Essbase
cpe:2.3:a:oracle:essbase:*:*:*:*:*:*:*:*
|
— |
11.1.2.4.47
|
|
Oracle Essbase
cpe:2.3:a:oracle:essbase:*:*:*:*:*:*:*:*
|
21.1
|
21.3
|
|
Oracle Health_Sciences_Inform_Publisher
cpe:2.3:a:oracle:health_sciences_inform_publisher:6.2.1.1:*:*:*:*:*:*:*
|
— | — |
|
Oracle Health_Sciences_Inform_Publisher
cpe:2.3:a:oracle:health_sciences_inform_publisher:6.3.1.1:*:*:*:*:*:*:*
|
— | — |
|
Oracle Jd_Edwards_Enterpriseone_Tools
cpe:2.3:a:oracle:jd_edwards_enterpriseone_tools:*:*:*:*:*:*:*:*
|
— |
9.2.6.3
|
|
Oracle Jd_Edwards_World_Security
cpe:2.3:a:oracle:jd_edwards_world_security:a9.4:*:*:*:*:*:*:*
|
— | — |
|
Oracle Mysql_Connectors
cpe:2.3:a:oracle:mysql_connectors:*:*:*:*:*:*:*:*
|
— |
<= 8.0.27
|
|
Oracle Mysql_Enterprise_Monitor
cpe:2.3:a:oracle:mysql_enterprise_monitor:*:*:*:*:*:*:*:*
|
— |
<= 8.0.25
|
|
Oracle Mysql_Server
cpe:2.3:a:oracle:mysql_server:*:*:*:*:*:*:*:*
|
5.7.0
|
<= 5.7.35
|
|
Oracle Mysql_Server
cpe:2.3:a:oracle:mysql_server:*:*:*:*:*:*:*:*
|
8.0.0
|
<= 8.0.26
|
|
Oracle Peoplesoft_Enterprise_Peopletools
cpe:2.3:a:oracle:peoplesoft_enterprise_peopletools:8.57:*:*:*:*:*:*:*
|
— | — |
|
Oracle Peoplesoft_Enterprise_Peopletools
cpe:2.3:a:oracle:peoplesoft_enterprise_peopletools:8.58:*:*:*:*:*:*:*
|
— | — |
|
Oracle Peoplesoft_Enterprise_Peopletools
cpe:2.3:a:oracle:peoplesoft_enterprise_peopletools:8.59:*:*:*:*:*:*:*
|
— | — |
|
Oracle Zfs_Storage_Appliance_Kit
cpe:2.3:a:oracle:zfs_storage_appliance_kit:8.8:*:*:*:*:*:*:*
|
— | — |
|
Tenable Nessus_Network_Monitor
cpe:2.3:a:tenable:nessus_network_monitor:*:*:*:*:*:*:*:*
|
— |
<= 5.13.1
|
|
Tenable Tenable.Sc
cpe:2.3:a:tenable:tenable.sc:*:*:*:*:*:*:*:*
|
5.16.0
|
<= 5.19.1
|