cve_id
stringlengths 13
16
| obtain_all_privilege
stringclasses 3
values | obtain_user_privilege
stringclasses 2
values | obtain_other_privilege
stringclasses 2
values | user_interaction_required
stringclasses 3
values | cvss2_vector_string
stringclasses 106
values | cvss2_access_vector
stringclasses 4
values | cvss2_access_complexity
stringclasses 4
values | cvss2_authentication
stringclasses 3
values | cvss2_confidentiality_impact
stringclasses 4
values | cvss2_integrity_impact
stringclasses 4
values | cvss2_availability_impact
stringclasses 4
values | cvss2_base_score
stringclasses 50
values | cvss3_vector_string
stringclasses 226
values | cvss3_attack_vector
stringclasses 5
values | cvss3_attack_complexity
stringclasses 3
values | cvss3_privileges_required
stringclasses 4
values | cvss3_user_interaction
stringclasses 3
values | cvss3_scope
stringclasses 3
values | cvss3_confidentiality_impact
stringclasses 4
values | cvss3_integrity_impact
stringclasses 4
values | cvss3_availability_impact
stringclasses 4
values | cvss3_base_score
stringclasses 55
values | cvss3_base_severity
stringclasses 5
values | exploitability_score
stringclasses 22
values | impact_score
stringclasses 15
values | ac_insuf_info
stringclasses 3
values | reference_json
stringlengths 221
23.3k
| problemtype_json
stringclasses 200
values | severity
stringclasses 4
values | cve_nodes
stringlengths 2
33.1k
| cve_description
stringlengths 64
1.99k
| cve_last_modified_date
stringlengths 17
17
| cve_published_date
stringlengths 17
17
| cwe_name
stringclasses 125
values | cwe_description
stringclasses 124
values | cwe_extended_description
stringclasses 95
values | cwe_url
stringclasses 124
values | cwe_is_category
int64 0
1
| commit_author
stringlengths 0
34
| commit_author_date
stringlengths 25
25
| commit_msg
stringlengths 0
13.3k
| commit_hash
stringlengths 40
40
| commit_is_merge
stringclasses 1
value | repo_name
stringclasses 467
values | repo_description
stringclasses 459
values | repo_date_created
stringclasses 467
values | repo_date_last_push
stringclasses 467
values | repo_homepage
stringclasses 294
values | repo_owner
stringclasses 470
values | repo_stars
stringclasses 406
values | repo_forks
stringclasses 352
values | function_name
stringlengths 3
120
| function_signature
stringlengths 6
640
| function_parameters
stringlengths 2
302
| function
stringlengths 12
114k
| function_token_count
stringlengths 1
5
| function_before_change
stringclasses 1
value | labels
int64 1
1
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
CVE-2016-7411 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | nan | [{'url': 'https://bugs.php.net/bug.php?id=73052', 'name': 'https://bugs.php.net/bug.php?id=73052', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Issue Tracking']}, {'url': 'https://github.com/php/php-src/commit/6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43?w=1', 'name': 'https://github.com/php/php-src/commit/6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43?w=1', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/09/15/10', 'name': '[oss-security] 20160915 Re: CVE assignment for PHP 5.6.26 and 7.0.11', 'refsource': 'MLIST', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/93009', 'name': '93009', 'refsource': 'BID', 'tags': []}, {'url': 'https://security.gentoo.org/glsa/201611-22', 'name': 'GLSA-201611-22', 'refsource': 'GENTOO', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1036836', 'name': '1036836', 'refsource': 'SECTRACK', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.25', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'ext/standard/var_unserializer.re in PHP before 5.6.26 mishandles object-deserialization failures, which allows remote attackers to cause a denial of service (memory corruption) or possibly have unspecified other impact via an unserialize call that references a partially constructed object.'}] | 2017-07-30T01:29Z | 2016-09-17T21:59Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Stanislav Malyshev | 2016-09-11 21:19:29-07:00 | Fix bug #73052 - Memory Corruption in During Deserialized-object Destruction | 6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | zend_object_store_ctor_failed | zend_object_store_ctor_failed( zval * zobject TSRMLS_DC) | ['TSRMLS_DC'] | ZEND_API void zend_object_store_ctor_failed(zval *zobject TSRMLS_DC)
{
zend_object_handle handle = Z_OBJ_HANDLE_P(zobject);
zend_object_store_bucket *obj_bucket = &EG(objects_store).object_buckets[handle];
obj_bucket->bucket.obj.handlers = Z_OBJ_HT_P(zobject);;
obj_bucket->destructor_called = 1;
} | 52 | True | 1 |
CVE-2016-7411 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | nan | [{'url': 'https://bugs.php.net/bug.php?id=73052', 'name': 'https://bugs.php.net/bug.php?id=73052', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Issue Tracking']}, {'url': 'https://github.com/php/php-src/commit/6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43?w=1', 'name': 'https://github.com/php/php-src/commit/6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43?w=1', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/09/15/10', 'name': '[oss-security] 20160915 Re: CVE assignment for PHP 5.6.26 and 7.0.11', 'refsource': 'MLIST', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/93009', 'name': '93009', 'refsource': 'BID', 'tags': []}, {'url': 'https://security.gentoo.org/glsa/201611-22', 'name': 'GLSA-201611-22', 'refsource': 'GENTOO', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1036836', 'name': '1036836', 'refsource': 'SECTRACK', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.25', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'ext/standard/var_unserializer.re in PHP before 5.6.26 mishandles object-deserialization failures, which allows remote attackers to cause a denial of service (memory corruption) or possibly have unspecified other impact via an unserialize call that references a partially constructed object.'}] | 2017-07-30T01:29Z | 2016-09-17T21:59Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Stanislav Malyshev | 2016-09-11 21:19:29-07:00 | Fix bug #73052 - Memory Corruption in During Deserialized-object Destruction | 6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | zend_objects_store_del_ref_by_handle_ex | zend_objects_store_del_ref_by_handle_ex( zend_object_handle handle , const zend_object_handlers * handlers TSRMLS_DC) | ['handle', 'TSRMLS_DC'] | ZEND_API void zend_objects_store_del_ref_by_handle_ex(zend_object_handle handle, const zend_object_handlers *handlers TSRMLS_DC) /* {{{ */
{
struct _store_object *obj;
int failure = 0;
if (!EG(objects_store).object_buckets) {
return;
}
obj = &EG(objects_store).object_buckets[handle].bucket.obj;
/* Make sure we hold a reference count during the destructor call
otherwise, when the destructor ends the storage might be freed
when the refcount reaches 0 a second time
*/
if (EG(objects_store).object_buckets[handle].valid) {
if (obj->refcount == 1) {
if (!EG(objects_store).object_buckets[handle].destructor_called) {
EG(objects_store).object_buckets[handle].destructor_called = 1;
if (obj->dtor) {
if (handlers && !obj->handlers) {
obj->handlers = handlers;
}
zend_try {
obj->dtor(obj->object, handle TSRMLS_CC);
} zend_catch {
failure = 1;
} zend_end_try();
}
}
/* re-read the object from the object store as the store might have been reallocated in the dtor */
obj = &EG(objects_store).object_buckets[handle].bucket.obj;
if (obj->refcount == 1) {
GC_REMOVE_ZOBJ_FROM_BUFFER(obj);
if (obj->free_storage) {
zend_try {
obj->free_storage(obj->object TSRMLS_CC);
} zend_catch {
failure = 1;
} zend_end_try();
}
ZEND_OBJECTS_STORE_ADD_TO_FREE_LIST();
}
}
}
obj->refcount--;
#if ZEND_DEBUG_OBJECTS
if (obj->refcount == 0) {
fprintf(stderr, "Deallocated object id #%d\n", handle);
} else {
fprintf(stderr, "Decreased refcount of object id #%d\n", handle);
}
#endif
if (failure) {
zend_bailout();
}
} | 276 | True | 1 |
CVE-2016-7411 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | nan | [{'url': 'https://bugs.php.net/bug.php?id=73052', 'name': 'https://bugs.php.net/bug.php?id=73052', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Issue Tracking']}, {'url': 'https://github.com/php/php-src/commit/6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43?w=1', 'name': 'https://github.com/php/php-src/commit/6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43?w=1', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/09/15/10', 'name': '[oss-security] 20160915 Re: CVE assignment for PHP 5.6.26 and 7.0.11', 'refsource': 'MLIST', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/93009', 'name': '93009', 'refsource': 'BID', 'tags': []}, {'url': 'https://security.gentoo.org/glsa/201611-22', 'name': 'GLSA-201611-22', 'refsource': 'GENTOO', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1036836', 'name': '1036836', 'refsource': 'SECTRACK', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.25', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'ext/standard/var_unserializer.re in PHP before 5.6.26 mishandles object-deserialization failures, which allows remote attackers to cause a denial of service (memory corruption) or possibly have unspecified other impact via an unserialize call that references a partially constructed object.'}] | 2017-07-30T01:29Z | 2016-09-17T21:59Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Stanislav Malyshev | 2016-09-11 21:19:29-07:00 | Fix bug #73052 - Memory Corruption in During Deserialized-object Destruction | 6a7cc8ff85827fa9ac715b3a83c2d9147f33cd43 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_var_unserialize | php_var_unserialize( UNSERIALIZE_PARAMETER) | ['UNSERIALIZE_PARAMETER'] | PHPAPI int php_var_unserialize(UNSERIALIZE_PARAMETER)
{
const unsigned char *cursor, *limit, *marker, *start;
zval **rval_ref;
limit = max;
cursor = *p;
if (YYCURSOR >= YYLIMIT) {
return 0;
}
if (var_hash && cursor[0] != 'R') {
var_push(var_hash, rval);
}
start = cursor;
#line 495 "ext/standard/var_unserializer.c"
{
YYCTYPE yych;
static const unsigned char yybm[] = {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
128, 128, 128, 128, 128, 128, 128, 128,
128, 128, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
};
if ((YYLIMIT - YYCURSOR) < 7) YYFILL(7);
yych = *YYCURSOR;
switch (yych) {
case 'C':
case 'O': goto yy13;
case 'N': goto yy5;
case 'R': goto yy2;
case 'S': goto yy10;
case 'a': goto yy11;
case 'b': goto yy6;
case 'd': goto yy8;
case 'i': goto yy7;
case 'o': goto yy12;
case 'r': goto yy4;
case 's': goto yy9;
case '}': goto yy14;
default: goto yy16;
}
yy2:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy95;
yy3:
#line 860 "ext/standard/var_unserializer.re"
{ return 0; }
#line 557 "ext/standard/var_unserializer.c"
yy4:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy89;
goto yy3;
yy5:
yych = *++YYCURSOR;
if (yych == ';') goto yy87;
goto yy3;
yy6:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy83;
goto yy3;
yy7:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy77;
goto yy3;
yy8:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy53;
goto yy3;
yy9:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy46;
goto yy3;
yy10:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy39;
goto yy3;
yy11:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy32;
goto yy3;
yy12:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy25;
goto yy3;
yy13:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy17;
goto yy3;
yy14:
++YYCURSOR;
#line 854 "ext/standard/var_unserializer.re"
{
/* this is the case where we have less data than planned */
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Unexpected end of serialized data");
return 0; /* not sure if it should be 0 or 1 here? */
}
#line 606 "ext/standard/var_unserializer.c"
yy16:
yych = *++YYCURSOR;
goto yy3;
yy17:
yych = *++YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
if (yych == '+') goto yy19;
yy18:
YYCURSOR = YYMARKER;
goto yy3;
yy19:
yych = *++YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
goto yy18;
yy20:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
if (yych <= '/') goto yy18;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 707 "ext/standard/var_unserializer.re"
{
size_t len, len2, len3, maxlen;
long elements;
char *class_name;
zend_class_entry *ce;
zend_class_entry **pce;
int incomplete_class = 0;
int custom_object = 0;
zval *user_func;
zval *retval_ptr;
zval **args[1];
zval *arg_func_name;
if (!var_hash) return 0;
if (*start == 'C') {
custom_object = 1;
}
INIT_PZVAL(*rval);
len2 = len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len || len == 0) {
*p = start + 2;
return 0;
}
class_name = (char*)YYCURSOR;
YYCURSOR += len;
if (*(YYCURSOR) != '"') {
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR+1) != ':') {
*p = YYCURSOR+1;
return 0;
}
len3 = strspn(class_name, "0123456789_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\177\200\201\202\203\204\205\206\207\210\211\212\213\214\215\216\217\220\221\222\223\224\225\226\227\230\231\232\233\234\235\236\237\240\241\242\243\244\245\246\247\250\251\252\253\254\255\256\257\260\261\262\263\264\265\266\267\270\271\272\273\274\275\276\277\300\301\302\303\304\305\306\307\310\311\312\313\314\315\316\317\320\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343\344\345\346\347\350\351\352\353\354\355\356\357\360\361\362\363\364\365\366\367\370\371\372\373\374\375\376\377\\");
if (len3 != len)
{
*p = YYCURSOR + len3 - len;
return 0;
}
class_name = estrndup(class_name, len);
do {
/* Try to find class directly */
BG(serialize_lock)++;
if (zend_lookup_class(class_name, len2, &pce TSRMLS_CC) == SUCCESS) {
BG(serialize_lock)--;
if (EG(exception)) {
efree(class_name);
return 0;
}
ce = *pce;
break;
}
BG(serialize_lock)--;
if (EG(exception)) {
efree(class_name);
return 0;
}
/* Check for unserialize callback */
if ((PG(unserialize_callback_func) == NULL) || (PG(unserialize_callback_func)[0] == '\0')) {
incomplete_class = 1;
ce = PHP_IC_ENTRY;
break;
}
/* Call unserialize callback */
MAKE_STD_ZVAL(user_func);
ZVAL_STRING(user_func, PG(unserialize_callback_func), 1);
args[0] = &arg_func_name;
MAKE_STD_ZVAL(arg_func_name);
ZVAL_STRING(arg_func_name, class_name, 1);
BG(serialize_lock)++;
if (call_user_function_ex(CG(function_table), NULL, user_func, &retval_ptr, 1, args, 0, NULL TSRMLS_CC) != SUCCESS) {
BG(serialize_lock)--;
if (EG(exception)) {
efree(class_name);
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&arg_func_name);
return 0;
}
php_error_docref(NULL TSRMLS_CC, E_WARNING, "defined (%s) but not found", user_func->value.str.val);
incomplete_class = 1;
ce = PHP_IC_ENTRY;
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&arg_func_name);
break;
}
BG(serialize_lock)--;
if (retval_ptr) {
zval_ptr_dtor(&retval_ptr);
}
if (EG(exception)) {
efree(class_name);
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&arg_func_name);
return 0;
}
/* The callback function may have defined the class */
if (zend_lookup_class(class_name, len2, &pce TSRMLS_CC) == SUCCESS) {
ce = *pce;
} else {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Function %s() hasn't defined the class it was called for", user_func->value.str.val);
incomplete_class = 1;
ce = PHP_IC_ENTRY;
}
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&arg_func_name);
break;
} while (1);
*p = YYCURSOR;
if (custom_object) {
int ret;
ret = object_custom(UNSERIALIZE_PASSTHRU, ce);
if (ret && incomplete_class) {
php_store_class_name(*rval, class_name, len2);
}
efree(class_name);
return ret;
}
elements = object_common1(UNSERIALIZE_PASSTHRU, ce);
if (incomplete_class) {
php_store_class_name(*rval, class_name, len2);
}
efree(class_name);
return object_common2(UNSERIALIZE_PASSTHRU, elements);
}
#line 784 "ext/standard/var_unserializer.c"
yy25:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy26;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy27;
goto yy18;
}
yy26:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy27:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy27;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 698 "ext/standard/var_unserializer.re"
{
if (!var_hash) return 0;
INIT_PZVAL(*rval);
return object_common2(UNSERIALIZE_PASSTHRU,
object_common1(UNSERIALIZE_PASSTHRU, ZEND_STANDARD_CLASS_DEF_PTR));
}
#line 818 "ext/standard/var_unserializer.c"
yy32:
yych = *++YYCURSOR;
if (yych == '+') goto yy33;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy34;
goto yy18;
yy33:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy34:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy34;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '{') goto yy18;
++YYCURSOR;
#line 677 "ext/standard/var_unserializer.re"
{
long elements = parse_iv(start + 2);
/* use iv() not uiv() in order to check data range */
*p = YYCURSOR;
if (!var_hash) return 0;
if (elements < 0) {
return 0;
}
INIT_PZVAL(*rval);
array_init_size(*rval, elements);
if (!process_nested_data(UNSERIALIZE_PASSTHRU, Z_ARRVAL_PP(rval), elements, 0)) {
return 0;
}
return finish_nested_data(UNSERIALIZE_PASSTHRU);
}
#line 860 "ext/standard/var_unserializer.c"
yy39:
yych = *++YYCURSOR;
if (yych == '+') goto yy40;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy41;
goto yy18;
yy40:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy41:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy41;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 642 "ext/standard/var_unserializer.re"
{
size_t len, maxlen;
char *str;
len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len) {
*p = start + 2;
return 0;
}
if ((str = unserialize_str(&YYCURSOR, &len, maxlen)) == NULL) {
return 0;
}
if (*(YYCURSOR) != '"') {
efree(str);
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR + 1) != ';') {
efree(str);
*p = YYCURSOR + 1;
return 0;
}
YYCURSOR += 2;
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_STRINGL(*rval, str, len, 0);
return 1;
}
#line 916 "ext/standard/var_unserializer.c"
yy46:
yych = *++YYCURSOR;
if (yych == '+') goto yy47;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy48;
goto yy18;
yy47:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy48:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy48;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 609 "ext/standard/var_unserializer.re"
{
size_t len, maxlen;
char *str;
len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len) {
*p = start + 2;
return 0;
}
str = (char*)YYCURSOR;
YYCURSOR += len;
if (*(YYCURSOR) != '"') {
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR + 1) != ';') {
*p = YYCURSOR + 1;
return 0;
}
YYCURSOR += 2;
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_STRINGL(*rval, str, len, 1);
return 1;
}
#line 970 "ext/standard/var_unserializer.c"
yy53:
yych = *++YYCURSOR;
if (yych <= '/') {
if (yych <= ',') {
if (yych == '+') goto yy57;
goto yy18;
} else {
if (yych <= '-') goto yy55;
if (yych <= '.') goto yy60;
goto yy18;
}
} else {
if (yych <= 'I') {
if (yych <= '9') goto yy58;
if (yych <= 'H') goto yy18;
goto yy56;
} else {
if (yych != 'N') goto yy18;
}
}
yych = *++YYCURSOR;
if (yych == 'A') goto yy76;
goto yy18;
yy55:
yych = *++YYCURSOR;
if (yych <= '/') {
if (yych == '.') goto yy60;
goto yy18;
} else {
if (yych <= '9') goto yy58;
if (yych != 'I') goto yy18;
}
yy56:
yych = *++YYCURSOR;
if (yych == 'N') goto yy72;
goto yy18;
yy57:
yych = *++YYCURSOR;
if (yych == '.') goto yy60;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy58:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ':') {
if (yych <= '.') {
if (yych <= '-') goto yy18;
goto yy70;
} else {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy58;
goto yy18;
}
} else {
if (yych <= 'E') {
if (yych <= ';') goto yy63;
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy60:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy61:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ';') {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy61;
if (yych <= ':') goto yy18;
} else {
if (yych <= 'E') {
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy63:
++YYCURSOR;
#line 599 "ext/standard/var_unserializer.re"
{
#if SIZEOF_LONG == 4
use_double:
#endif
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_DOUBLE(*rval, zend_strtod((const char *)start + 2, NULL));
return 1;
}
#line 1068 "ext/standard/var_unserializer.c"
yy65:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy66;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
goto yy18;
}
yy66:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych == '+') goto yy69;
goto yy18;
} else {
if (yych <= '-') goto yy69;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
}
yy67:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
if (yych == ';') goto yy63;
goto yy18;
yy69:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
goto yy18;
yy70:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ';') {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy70;
if (yych <= ':') goto yy18;
goto yy63;
} else {
if (yych <= 'E') {
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy72:
yych = *++YYCURSOR;
if (yych != 'F') goto yy18;
yy73:
yych = *++YYCURSOR;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 584 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
INIT_PZVAL(*rval);
if (!strncmp(start + 2, "NAN", 3)) {
ZVAL_DOUBLE(*rval, php_get_nan());
} else if (!strncmp(start + 2, "INF", 3)) {
ZVAL_DOUBLE(*rval, php_get_inf());
} else if (!strncmp(start + 2, "-INF", 4)) {
ZVAL_DOUBLE(*rval, -php_get_inf());
}
return 1;
}
#line 1142 "ext/standard/var_unserializer.c"
yy76:
yych = *++YYCURSOR;
if (yych == 'N') goto yy73;
goto yy18;
yy77:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy78;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy79;
goto yy18;
}
yy78:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy79:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy79;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 557 "ext/standard/var_unserializer.re"
{
#if SIZEOF_LONG == 4
int digits = YYCURSOR - start - 3;
if (start[2] == '-' || start[2] == '+') {
digits--;
}
/* Use double for large long values that were serialized on a 64-bit system */
if (digits >= MAX_LENGTH_OF_LONG - 1) {
if (digits == MAX_LENGTH_OF_LONG - 1) {
int cmp = strncmp(YYCURSOR - MAX_LENGTH_OF_LONG, long_min_digits, MAX_LENGTH_OF_LONG - 1);
if (!(cmp < 0 || (cmp == 0 && start[2] == '-'))) {
goto use_double;
}
} else {
goto use_double;
}
}
#endif
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_LONG(*rval, parse_iv(start + 2));
return 1;
}
#line 1196 "ext/standard/var_unserializer.c"
yy83:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= '2') goto yy18;
yych = *++YYCURSOR;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 550 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_BOOL(*rval, parse_iv(start + 2));
return 1;
}
#line 1211 "ext/standard/var_unserializer.c"
yy87:
++YYCURSOR;
#line 543 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_NULL(*rval);
return 1;
}
#line 1221 "ext/standard/var_unserializer.c"
yy89:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy90;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy91;
goto yy18;
}
yy90:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy91:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy91;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 520 "ext/standard/var_unserializer.re"
{
long id;
*p = YYCURSOR;
if (!var_hash) return 0;
id = parse_iv(start + 2) - 1;
if (id == -1 || var_access(var_hash, id, &rval_ref) != SUCCESS) {
return 0;
}
if (*rval == *rval_ref) return 0;
if (*rval != NULL) {
var_push_dtor_no_addref(var_hash, rval);
}
*rval = *rval_ref;
Z_ADDREF_PP(rval);
Z_UNSET_ISREF_PP(rval);
return 1;
}
#line 1267 "ext/standard/var_unserializer.c"
yy95:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy96;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy97;
goto yy18;
}
yy96:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy97:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy97;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 499 "ext/standard/var_unserializer.re"
{
long id;
*p = YYCURSOR;
if (!var_hash) return 0;
id = parse_iv(start + 2) - 1;
if (id == -1 || var_access(var_hash, id, &rval_ref) != SUCCESS) {
return 0;
}
if (*rval != NULL) {
var_push_dtor_no_addref(var_hash, rval);
}
*rval = *rval_ref;
Z_ADDREF_PP(rval);
Z_SET_ISREF_PP(rval);
return 1;
}
#line 1311 "ext/standard/var_unserializer.c"
}
#line 862 "ext/standard/var_unserializer.re"
return 0;
} | 4557 | True | 1 |
CVE-2016-7418 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | True | [{'url': 'http://www.php.net/ChangeLog-7.php', 'name': 'http://www.php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes']}, {'url': 'https://github.com/php/php-src/commit/c4cca4c20e75359c9a13a1f9a36cb7b4e9601d29?w=1', 'name': 'https://github.com/php/php-src/commit/c4cca4c20e75359c9a13a1f9a36cb7b4e9601d29?w=1', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch']}, {'url': 'https://bugs.php.net/bug.php?id=73065', 'name': 'https://bugs.php.net/bug.php?id=73065', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Issue Tracking']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/09/15/10', 'name': '[oss-security] 20160915 Re: CVE assignment for PHP 5.6.26 and 7.0.11', 'refsource': 'MLIST', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/93011', 'name': '93011', 'refsource': 'BID', 'tags': []}, {'url': 'https://security.gentoo.org/glsa/201611-22', 'name': 'GLSA-201611-22', 'refsource': 'GENTOO', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1036836', 'name': '1036836', 'refsource': 'SECTRACK', 'tags': []}, {'url': 'https://www.tenable.com/security/tns-2016-19', 'name': 'https://www.tenable.com/security/tns-2016-19', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.25', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The php_wddx_push_element function in ext/wddx/wddx.c in PHP before 5.6.26 and 7.x before 7.0.11 allows remote attackers to cause a denial of service (invalid pointer access and out-of-bounds read) or possibly have unspecified other impact via an incorrect boolean element in a wddxPacket XML document, leading to mishandling in a wddx_deserialize call.'}] | 2018-05-04T01:29Z | 2016-09-17T21:59Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Stanislav Malyshev | 2016-09-12 00:35:01-07:00 | Fix bug #73065: Out-Of-Bounds Read in php_wddx_push_element of wddx.c | c4cca4c20e75359c9a13a1f9a36cb7b4e9601d29 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_wddx_push_element | php_wddx_push_element( void * user_data , const XML_Char * name , const XML_Char ** atts) | ['user_data', 'name', 'atts'] | */
static void php_wddx_push_element(void *user_data, const XML_Char *name, const XML_Char **atts)
{
st_entry ent;
wddx_stack *stack = (wddx_stack *)user_data;
if (!strcmp(name, EL_PACKET)) {
int i;
if (atts) for (i=0; atts[i]; i++) {
if (!strcmp(atts[i], EL_VERSION)) {
/* nothing for now */
}
}
} else if (!strcmp(name, EL_STRING)) {
ent.type = ST_STRING;
SET_STACK_VARNAME;
ALLOC_ZVAL(ent.data);
INIT_PZVAL(ent.data);
Z_TYPE_P(ent.data) = IS_STRING;
Z_STRVAL_P(ent.data) = STR_EMPTY_ALLOC();
Z_STRLEN_P(ent.data) = 0;
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} else if (!strcmp(name, EL_BINARY)) {
ent.type = ST_BINARY;
SET_STACK_VARNAME;
ALLOC_ZVAL(ent.data);
INIT_PZVAL(ent.data);
Z_TYPE_P(ent.data) = IS_STRING;
Z_STRVAL_P(ent.data) = STR_EMPTY_ALLOC();
Z_STRLEN_P(ent.data) = 0;
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} else if (!strcmp(name, EL_CHAR)) {
int i;
if (atts) for (i = 0; atts[i]; i++) {
if (!strcmp(atts[i], EL_CHAR_CODE) && atts[++i] && atts[i][0]) {
char tmp_buf[2];
snprintf(tmp_buf, sizeof(tmp_buf), "%c", (char)strtol(atts[i], NULL, 16));
php_wddx_process_data(user_data, tmp_buf, strlen(tmp_buf));
break;
}
}
} else if (!strcmp(name, EL_NUMBER)) {
ent.type = ST_NUMBER;
SET_STACK_VARNAME;
ALLOC_ZVAL(ent.data);
INIT_PZVAL(ent.data);
Z_TYPE_P(ent.data) = IS_LONG;
Z_LVAL_P(ent.data) = 0;
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} else if (!strcmp(name, EL_BOOLEAN)) {
int i;
if (atts) for (i = 0; atts[i]; i++) {
if (!strcmp(atts[i], EL_VALUE) && atts[++i] && atts[i][0]) {
ent.type = ST_BOOLEAN;
SET_STACK_VARNAME;
ALLOC_ZVAL(ent.data);
INIT_PZVAL(ent.data);
Z_TYPE_P(ent.data) = IS_BOOL;
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
php_wddx_process_data(user_data, atts[i], strlen(atts[i]));
break;
}
}
} else if (!strcmp(name, EL_NULL)) {
ent.type = ST_NULL;
SET_STACK_VARNAME;
ALLOC_ZVAL(ent.data);
INIT_PZVAL(ent.data);
ZVAL_NULL(ent.data);
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} else if (!strcmp(name, EL_ARRAY)) {
ent.type = ST_ARRAY;
SET_STACK_VARNAME;
ALLOC_ZVAL(ent.data);
array_init(ent.data);
INIT_PZVAL(ent.data);
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} else if (!strcmp(name, EL_STRUCT)) {
ent.type = ST_STRUCT;
SET_STACK_VARNAME;
ALLOC_ZVAL(ent.data);
array_init(ent.data);
INIT_PZVAL(ent.data);
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} else if (!strcmp(name, EL_VAR)) {
int i;
if (atts) for (i = 0; atts[i]; i++) {
if (!strcmp(atts[i], EL_NAME) && atts[++i] && atts[i][0]) {
if (stack->varname) efree(stack->varname);
stack->varname = estrdup(atts[i]);
break;
}
}
} else if (!strcmp(name, EL_RECORDSET)) {
int i;
ent.type = ST_RECORDSET;
SET_STACK_VARNAME;
MAKE_STD_ZVAL(ent.data);
array_init(ent.data);
if (atts) for (i = 0; atts[i]; i++) {
if (!strcmp(atts[i], "fieldNames") && atts[++i] && atts[i][0]) {
zval *tmp;
char *key;
char *p1, *p2, *endp;
endp = (char *)atts[i] + strlen(atts[i]);
p1 = (char *)atts[i];
while ((p2 = php_memnstr(p1, ",", sizeof(",")-1, endp)) != NULL) {
key = estrndup(p1, p2 - p1);
MAKE_STD_ZVAL(tmp);
array_init(tmp);
add_assoc_zval_ex(ent.data, key, p2 - p1 + 1, tmp);
p1 = p2 + sizeof(",")-1;
efree(key);
}
if (p1 <= endp) {
MAKE_STD_ZVAL(tmp);
array_init(tmp);
add_assoc_zval_ex(ent.data, p1, endp - p1 + 1, tmp);
}
break;
}
}
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} else if (!strcmp(name, EL_FIELD)) {
int i;
st_entry ent;
ent.type = ST_FIELD;
ent.varname = NULL;
ent.data = NULL;
if (atts) for (i = 0; atts[i]; i++) {
if (!strcmp(atts[i], EL_NAME) && atts[++i] && atts[i][0]) {
st_entry *recordset;
zval **field;
if (wddx_stack_top(stack, (void**)&recordset) == SUCCESS &&
recordset->type == ST_RECORDSET &&
zend_hash_find(Z_ARRVAL_P(recordset->data), (char*)atts[i], strlen(atts[i])+1, (void**)&field) == SUCCESS) {
ent.data = *field;
}
break;
}
}
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} else if (!strcmp(name, EL_DATETIME)) {
ent.type = ST_DATETIME;
SET_STACK_VARNAME;
ALLOC_ZVAL(ent.data);
INIT_PZVAL(ent.data);
Z_TYPE_P(ent.data) = IS_LONG;
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
} | 1339 | True | 1 |
CVE-2016-7412 | False | False | False | False | AV:N/AC:M/Au:N/C:P/I:P/A:P | NETWORK | MEDIUM | NONE | PARTIAL | PARTIAL | PARTIAL | 6.8 | CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | HIGH | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 8.1 | HIGH | 2.2 | 5.9 | nan | [{'url': 'http://www.php.net/ChangeLog-7.php', 'name': 'http://www.php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes']}, {'url': 'https://bugs.php.net/bug.php?id=72293', 'name': 'https://bugs.php.net/bug.php?id=72293', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Issue Tracking']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes']}, {'url': 'https://github.com/php/php-src/commit/28f80baf3c53e267c9ce46a2a0fadbb981585132?w=1', 'name': 'https://github.com/php/php-src/commit/28f80baf3c53e267c9ce46a2a0fadbb981585132?w=1', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/09/15/10', 'name': '[oss-security] 20160915 Re: CVE assignment for PHP 5.6.26 and 7.0.11', 'refsource': 'MLIST', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/93005', 'name': '93005', 'refsource': 'BID', 'tags': []}, {'url': 'https://security.gentoo.org/glsa/201611-22', 'name': 'GLSA-201611-22', 'refsource': 'GENTOO', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1036836', 'name': '1036836', 'refsource': 'SECTRACK', 'tags': []}, {'url': 'https://www.tenable.com/security/tns-2016-19', 'name': 'https://www.tenable.com/security/tns-2016-19', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.25', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'ext/mysqlnd/mysqlnd_wireprotocol.c in PHP before 5.6.26 and 7.x before 7.0.11 does not verify that a BIT field has the UNSIGNED_FLAG flag, which allows remote MySQL servers to cause a denial of service (heap-based buffer overflow) or possibly have unspecified other impact via crafted field metadata.'}] | 2018-05-04T01:29Z | 2016-09-17T21:59Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Stanislav Malyshev | 2016-09-12 20:25:08-07:00 | Fix bug #72293 - Heap overflow in mysqlnd related to BIT fields | 28f80baf3c53e267c9ce46a2a0fadbb981585132 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_mysqlnd_rowp_read_text_protocol_aux | php_mysqlnd_rowp_read_text_protocol_aux( MYSQLND_MEMORY_POOL_CHUNK * row_buffer , zval ** fields , unsigned int field_count , const MYSQLND_FIELD * fields_metadata , zend_bool as_int_or_float , zend_bool copy_data , MYSQLND_STATS * stats TSRMLS_DC) | ['row_buffer', 'fields', 'field_count', 'fields_metadata', 'as_int_or_float', 'copy_data', 'TSRMLS_DC'] | enum_func_status
php_mysqlnd_rowp_read_text_protocol_aux(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval ** fields,
unsigned int field_count, const MYSQLND_FIELD * fields_metadata,
zend_bool as_int_or_float, zend_bool copy_data, MYSQLND_STATS * stats TSRMLS_DC)
{
unsigned int i;
zend_bool last_field_was_string = FALSE;
zval **current_field, **end_field, **start_field;
zend_uchar * p = row_buffer->ptr;
size_t data_size = row_buffer->app;
zend_uchar * bit_area = (zend_uchar*) row_buffer->ptr + data_size + 1; /* we allocate from here */
DBG_ENTER("php_mysqlnd_rowp_read_text_protocol_aux");
if (!fields) {
DBG_RETURN(FAIL);
}
end_field = (start_field = fields) + field_count;
for (i = 0, current_field = start_field; current_field < end_field; current_field++, i++) {
DBG_INF("Directly creating zval");
MAKE_STD_ZVAL(*current_field);
if (!*current_field) {
DBG_RETURN(FAIL);
}
}
for (i = 0, current_field = start_field; current_field < end_field; current_field++, i++) {
/* Don't reverse the order. It is significant!*/
zend_uchar *this_field_len_pos = p;
/* php_mysqlnd_net_field_length() call should be after *this_field_len_pos = p; */
unsigned long len = php_mysqlnd_net_field_length(&p);
if (copy_data == FALSE && current_field > start_field && last_field_was_string) {
/*
Normal queries:
We have to put \0 now to the end of the previous field, if it was
a string. IS_NULL doesn't matter. Because we have already read our
length, then we can overwrite it in the row buffer.
This statement terminates the previous field, not the current one.
NULL_LENGTH is encoded in one byte, so we can stick a \0 there.
Any string's length is encoded in at least one byte, so we can stick
a \0 there.
*/
*this_field_len_pos = '\0';
}
/* NULL or NOT NULL, this is the question! */
if (len == MYSQLND_NULL_LENGTH) {
ZVAL_NULL(*current_field);
last_field_was_string = FALSE;
} else {
#if defined(MYSQLND_STRING_TO_INT_CONVERSION)
struct st_mysqlnd_perm_bind perm_bind =
mysqlnd_ps_fetch_functions[fields_metadata[i].type];
#endif
if (MYSQLND_G(collect_statistics)) {
enum_mysqlnd_collected_stats statistic;
switch (fields_metadata[i].type) {
case MYSQL_TYPE_DECIMAL: statistic = STAT_TEXT_TYPE_FETCHED_DECIMAL; break;
case MYSQL_TYPE_TINY: statistic = STAT_TEXT_TYPE_FETCHED_INT8; break;
case MYSQL_TYPE_SHORT: statistic = STAT_TEXT_TYPE_FETCHED_INT16; break;
case MYSQL_TYPE_LONG: statistic = STAT_TEXT_TYPE_FETCHED_INT32; break;
case MYSQL_TYPE_FLOAT: statistic = STAT_TEXT_TYPE_FETCHED_FLOAT; break;
case MYSQL_TYPE_DOUBLE: statistic = STAT_TEXT_TYPE_FETCHED_DOUBLE; break;
case MYSQL_TYPE_NULL: statistic = STAT_TEXT_TYPE_FETCHED_NULL; break;
case MYSQL_TYPE_TIMESTAMP: statistic = STAT_TEXT_TYPE_FETCHED_TIMESTAMP; break;
case MYSQL_TYPE_LONGLONG: statistic = STAT_TEXT_TYPE_FETCHED_INT64; break;
case MYSQL_TYPE_INT24: statistic = STAT_TEXT_TYPE_FETCHED_INT24; break;
case MYSQL_TYPE_DATE: statistic = STAT_TEXT_TYPE_FETCHED_DATE; break;
case MYSQL_TYPE_TIME: statistic = STAT_TEXT_TYPE_FETCHED_TIME; break;
case MYSQL_TYPE_DATETIME: statistic = STAT_TEXT_TYPE_FETCHED_DATETIME; break;
case MYSQL_TYPE_YEAR: statistic = STAT_TEXT_TYPE_FETCHED_YEAR; break;
case MYSQL_TYPE_NEWDATE: statistic = STAT_TEXT_TYPE_FETCHED_DATE; break;
case MYSQL_TYPE_VARCHAR: statistic = STAT_TEXT_TYPE_FETCHED_STRING; break;
case MYSQL_TYPE_BIT: statistic = STAT_TEXT_TYPE_FETCHED_BIT; break;
case MYSQL_TYPE_NEWDECIMAL: statistic = STAT_TEXT_TYPE_FETCHED_DECIMAL; break;
case MYSQL_TYPE_ENUM: statistic = STAT_TEXT_TYPE_FETCHED_ENUM; break;
case MYSQL_TYPE_SET: statistic = STAT_TEXT_TYPE_FETCHED_SET; break;
case MYSQL_TYPE_JSON: statistic = STAT_TEXT_TYPE_FETCHED_JSON; break;
case MYSQL_TYPE_TINY_BLOB: statistic = STAT_TEXT_TYPE_FETCHED_BLOB; break;
case MYSQL_TYPE_MEDIUM_BLOB:statistic = STAT_TEXT_TYPE_FETCHED_BLOB; break;
case MYSQL_TYPE_LONG_BLOB: statistic = STAT_TEXT_TYPE_FETCHED_BLOB; break;
case MYSQL_TYPE_BLOB: statistic = STAT_TEXT_TYPE_FETCHED_BLOB; break;
case MYSQL_TYPE_VAR_STRING: statistic = STAT_TEXT_TYPE_FETCHED_STRING; break;
case MYSQL_TYPE_STRING: statistic = STAT_TEXT_TYPE_FETCHED_STRING; break;
case MYSQL_TYPE_GEOMETRY: statistic = STAT_TEXT_TYPE_FETCHED_GEOMETRY; break;
default: statistic = STAT_TEXT_TYPE_FETCHED_OTHER; break;
}
MYSQLND_INC_CONN_STATISTIC_W_VALUE2(stats, statistic, 1, STAT_BYTES_RECEIVED_PURE_DATA_TEXT, len);
}
#ifdef MYSQLND_STRING_TO_INT_CONVERSION
if (as_int_or_float && perm_bind.php_type == IS_LONG) {
zend_uchar save = *(p + len);
/* We have to make it ASCIIZ temporarily */
*(p + len) = '\0';
if (perm_bind.pack_len < SIZEOF_LONG) {
/* direct conversion */
int64_t v =
#ifndef PHP_WIN32
atoll((char *) p);
#else
_atoi64((char *) p);
#endif
ZVAL_LONG(*current_field, (long) v); /* the cast is safe */
} else {
uint64_t v =
#ifndef PHP_WIN32
(uint64_t) atoll((char *) p);
#else
(uint64_t) _atoi64((char *) p);
#endif
zend_bool uns = fields_metadata[i].flags & UNSIGNED_FLAG? TRUE:FALSE;
/* We have to make it ASCIIZ temporarily */
#if SIZEOF_LONG==8
if (uns == TRUE && v > 9223372036854775807L)
#elif SIZEOF_LONG==4
if ((uns == TRUE && v > L64(2147483647)) ||
(uns == FALSE && (( L64(2147483647) < (int64_t) v) ||
(L64(-2147483648) > (int64_t) v))))
#else
#error Need fix for this architecture
#endif /* SIZEOF */
{
ZVAL_STRINGL(*current_field, (char *)p, len, 0);
} else {
ZVAL_LONG(*current_field, (long) v); /* the cast is safe */
}
}
*(p + len) = save;
} else if (as_int_or_float && perm_bind.php_type == IS_DOUBLE) {
zend_uchar save = *(p + len);
/* We have to make it ASCIIZ temporarily */
*(p + len) = '\0';
ZVAL_DOUBLE(*current_field, atof((char *) p));
*(p + len) = save;
} else
#endif /* MYSQLND_STRING_TO_INT_CONVERSION */
if (fields_metadata[i].type == MYSQL_TYPE_BIT) {
/*
BIT fields are specially handled. As they come as bit mask, we have
to convert it to human-readable representation. As the bits take
less space in the protocol than the numbers they represent, we don't
have enough space in the packet buffer to overwrite inside.
Thus, a bit more space is pre-allocated at the end of the buffer,
see php_mysqlnd_rowp_read(). And we add the strings at the end.
Definitely not nice, _hackish_ :(, but works.
*/
zend_uchar *start = bit_area;
ps_fetch_from_1_to_8_bytes(*current_field, &(fields_metadata[i]), 0, &p, len TSRMLS_CC);
/*
We have advanced in ps_fetch_from_1_to_8_bytes. We should go back because
later in this function there will be an advancement.
*/
p -= len;
if (Z_TYPE_PP(current_field) == IS_LONG) {
bit_area += 1 + sprintf((char *)start, "%ld", Z_LVAL_PP(current_field));
ZVAL_STRINGL(*current_field, (char *) start, bit_area - start - 1, copy_data);
} else if (Z_TYPE_PP(current_field) == IS_STRING){
memcpy(bit_area, Z_STRVAL_PP(current_field), Z_STRLEN_PP(current_field));
bit_area += Z_STRLEN_PP(current_field);
*bit_area++ = '\0';
zval_dtor(*current_field);
ZVAL_STRINGL(*current_field, (char *) start, bit_area - start - 1, copy_data);
}
} else {
ZVAL_STRINGL(*current_field, (char *)p, len, copy_data);
}
p += len;
last_field_was_string = TRUE;
}
}
if (copy_data == FALSE && last_field_was_string) {
/* Normal queries: The buffer has one more byte at the end, because we need it */
row_buffer->ptr[data_size] = '\0';
}
DBG_RETURN(PASS); | 1031 | True | 1 |
CVE-2016-7480 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | True | [{'url': 'https://www.youtube.com/watch?v=LDcaPstAuPk', 'name': 'https://www.youtube.com/watch?v=LDcaPstAuPk', 'refsource': 'MISC', 'tags': ['Broken Link', 'Third Party Advisory']}, {'url': 'https://github.com/php/php-src/commit/61cdd1255d5b9c8453be71aacbbf682796ac77d4', 'name': 'https://github.com/php/php-src/commit/61cdd1255d5b9c8453be71aacbbf682796ac77d4', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73257', 'name': 'https://bugs.php.net/bug.php?id=73257', 'refsource': 'MISC', 'tags': ['Issue Tracking', 'Patch', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://blog.checkpoint.com/wp-content/uploads/2016/12/PHP_Technical_Report.pdf', 'name': 'http://blog.checkpoint.com/wp-content/uploads/2016/12/PHP_Technical_Report.pdf', 'refsource': 'MISC', 'tags': ['Exploit', 'Technical Description', 'Third Party Advisory']}, {'url': 'http://blog.checkpoint.com/2016/12/27/check-point-discovers-three-zero-day-vulnerabilities-web-programming-language-php-7', 'name': 'http://blog.checkpoint.com/2016/12/27/check-point-discovers-three-zero-day-vulnerabilities-web-programming-language-php-7', 'refsource': 'MISC', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'http://www.securityfocus.com/bid/95152', 'name': '95152', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '7.0.0', 'versionEndExcluding': '7.0.11', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:netapp:clustered_data_ontap:-:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The SplObjectStorage unserialize implementation in ext/spl/spl_observer.c in PHP before 7.0.12 does not verify that a key is an object, which allows remote attackers to execute arbitrary code or cause a denial of service (uninitialized memory access) via crafted serialized data.'}] | 2022-07-20T16:47Z | 2017-01-11T07:59Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Stanislav Malyshev | 2016-10-10 22:54:29-07:00 | Fix bug #73257 and bug #73258 - SplObjectStorage unserialize allows use of non-object as key | 61cdd1255d5b9c8453be71aacbbf682796ac77d4 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | SPL_METHOD | SPL_METHOD( SplObjectStorage , unserialize) | ['SplObjectStorage', 'unserialize'] | SPL_METHOD(SplObjectStorage, unserialize)
{
spl_SplObjectStorage *intern = Z_SPLOBJSTORAGE_P(getThis());
char *buf;
size_t buf_len;
const unsigned char *p, *s;
php_unserialize_data_t var_hash;
zval entry, inf;
zval *pcount, *pmembers;
spl_SplObjectStorageElement *element;
zend_long count;
if (zend_parse_parameters(ZEND_NUM_ARGS(), "s", &buf, &buf_len) == FAILURE) {
return;
}
if (buf_len == 0) {
return;
}
/* storage */
s = p = (const unsigned char*)buf;
PHP_VAR_UNSERIALIZE_INIT(var_hash);
if (*p!= 'x' || *++p != ':') {
goto outexcept;
}
++p;
pcount = var_tmp_var(&var_hash);
if (!php_var_unserialize(pcount, &p, s + buf_len, &var_hash) || Z_TYPE_P(pcount) != IS_LONG) {
goto outexcept;
}
--p; /* for ';' */
count = Z_LVAL_P(pcount);
while (count-- > 0) {
spl_SplObjectStorageElement *pelement;
zend_string *hash;
if (*p != ';') {
goto outexcept;
}
++p;
if(*p != 'O' && *p != 'C' && *p != 'r') {
goto outexcept;
}
/* store reference to allow cross-references between different elements */
if (!php_var_unserialize(&entry, &p, s + buf_len, &var_hash)) {
goto outexcept;
}
if (Z_TYPE(entry) != IS_OBJECT) {
zval_ptr_dtor(&entry);
goto outexcept;
}
if (*p == ',') { /* new version has inf */
++p;
if (!php_var_unserialize(&inf, &p, s + buf_len, &var_hash)) {
zval_ptr_dtor(&entry);
goto outexcept;
}
} else {
ZVAL_UNDEF(&inf);
}
hash = spl_object_storage_get_hash(intern, getThis(), &entry);
if (!hash) {
zval_ptr_dtor(&entry);
zval_ptr_dtor(&inf);
goto outexcept;
}
pelement = spl_object_storage_get(intern, hash);
spl_object_storage_free_hash(intern, hash);
if (pelement) {
if (!Z_ISUNDEF(pelement->inf)) {
var_push_dtor(&var_hash, &pelement->inf);
}
if (!Z_ISUNDEF(pelement->obj)) {
var_push_dtor(&var_hash, &pelement->obj);
}
}
element = spl_object_storage_attach(intern, getThis(), &entry, Z_ISUNDEF(inf)?NULL:&inf);
var_replace(&var_hash, &entry, &element->obj);
var_replace(&var_hash, &inf, &element->inf);
zval_ptr_dtor(&entry);
ZVAL_UNDEF(&entry);
zval_ptr_dtor(&inf);
ZVAL_UNDEF(&inf);
}
if (*p != ';') {
goto outexcept;
}
++p;
/* members */
if (*p!= 'm' || *++p != ':') {
goto outexcept;
}
++p;
pmembers = var_tmp_var(&var_hash);
if (!php_var_unserialize(pmembers, &p, s + buf_len, &var_hash) || Z_TYPE_P(pmembers) != IS_ARRAY) {
goto outexcept;
}
/* copy members */
object_properties_load(&intern->std, Z_ARRVAL_P(pmembers));
PHP_VAR_UNSERIALIZE_DESTROY(var_hash);
return;
outexcept:
PHP_VAR_UNSERIALIZE_DESTROY(var_hash);
zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0, "Error at offset %pd of %d bytes", (zend_long)((char*)p - buf), buf_len);
return;
} /* }}} */ | 632 | True | 1 |
CVE-2016-9934 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | True | [{'url': 'https://github.com/php/php-src/commit/6045de69c7dedcba3eadf7c4bba424b19c81d00d', 'name': 'https://github.com/php/php-src/commit/6045de69c7dedcba3eadf7c4bba424b19c81d00d', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73331', 'name': 'https://bugs.php.net/bug.php?id=73331', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'http://www.php.net/ChangeLog-7.php', 'name': 'http://www.php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/12/12/2', 'name': '[oss-security] 20161212 CVE assignment for PHP 5.6.28, 5.6.29, 7.0.13, 7.0.14 and 7.1.0', 'refsource': 'MLIST', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/94845', 'name': '94845', 'refsource': 'BID', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2016-12/msg00142.html', 'name': 'openSUSE-SU-2016:3239', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2017-01/msg00054.html', 'name': 'openSUSE-SU-2017:0081', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2017-01/msg00034.html', 'name': 'openSUSE-SU-2017:0061', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-476'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.27', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'ext/wddx/wddx.c in PHP before 5.6.28 and 7.x before 7.0.13 allows remote attackers to cause a denial of service (NULL pointer dereference) via crafted serialized data in a wddxPacket XML document, as demonstrated by a PDORow string.'}] | 2018-05-04T01:29Z | 2017-01-04T20:59Z | NULL Pointer Dereference | A NULL pointer dereference occurs when the application dereferences a pointer that it expects to be valid, but is NULL, typically causing a crash or exit. | NULL pointer dereference issues can occur through a number of flaws, including race conditions, and simple programming omissions.
| https://cwe.mitre.org/data/definitions/476.html | 0 | Stanislav Malyshev | 2016-10-23 20:07:47-07:00 | Fix bug #73331 - do not try to serialize/unserialize objects wddx can not handle
Proper soltion would be to call serialize/unserialize and deal with the result,
but this requires more work that should be done by wddx maintainer (not me). | 6045de69c7dedcba3eadf7c4bba424b19c81d00d | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_wddx_pop_element | php_wddx_pop_element( void * user_data , const XML_Char * name) | ['user_data', 'name'] | */
static void php_wddx_pop_element(void *user_data, const XML_Char *name)
{
st_entry *ent1, *ent2;
wddx_stack *stack = (wddx_stack *)user_data;
HashTable *target_hash;
zend_class_entry **pce;
zval *obj;
zval *tmp;
TSRMLS_FETCH();
/* OBJECTS_FIXME */
if (stack->top == 0) {
return;
}
if (!strcmp(name, EL_STRING) || !strcmp(name, EL_NUMBER) ||
!strcmp(name, EL_BOOLEAN) || !strcmp(name, EL_NULL) ||
!strcmp(name, EL_ARRAY) || !strcmp(name, EL_STRUCT) ||
!strcmp(name, EL_RECORDSET) || !strcmp(name, EL_BINARY) ||
!strcmp(name, EL_DATETIME)) {
wddx_stack_top(stack, (void**)&ent1);
if (!ent1->data) {
if (stack->top > 1) {
stack->top--;
efree(ent1);
} else {
stack->done = 1;
}
return;
}
if (!strcmp(name, EL_BINARY)) {
int new_len=0;
unsigned char *new_str;
new_str = php_base64_decode(Z_STRVAL_P(ent1->data), Z_STRLEN_P(ent1->data), &new_len);
STR_FREE(Z_STRVAL_P(ent1->data));
if (new_str) {
Z_STRVAL_P(ent1->data) = new_str;
Z_STRLEN_P(ent1->data) = new_len;
} else {
ZVAL_EMPTY_STRING(ent1->data);
}
}
/* Call __wakeup() method on the object. */
if (Z_TYPE_P(ent1->data) == IS_OBJECT) {
zval *fname, *retval = NULL;
MAKE_STD_ZVAL(fname);
ZVAL_STRING(fname, "__wakeup", 1);
call_user_function_ex(NULL, &ent1->data, fname, &retval, 0, 0, 0, NULL TSRMLS_CC);
zval_dtor(fname);
FREE_ZVAL(fname);
if (retval) {
zval_ptr_dtor(&retval);
}
}
if (stack->top > 1) {
stack->top--;
wddx_stack_top(stack, (void**)&ent2);
/* if non-existent field */
if (ent2->data == NULL) {
zval_ptr_dtor(&ent1->data);
efree(ent1);
return;
}
if (Z_TYPE_P(ent2->data) == IS_ARRAY || Z_TYPE_P(ent2->data) == IS_OBJECT) {
target_hash = HASH_OF(ent2->data);
if (ent1->varname) {
if (!strcmp(ent1->varname, PHP_CLASS_NAME_VAR) &&
Z_TYPE_P(ent1->data) == IS_STRING && Z_STRLEN_P(ent1->data) &&
ent2->type == ST_STRUCT && Z_TYPE_P(ent2->data) == IS_ARRAY) {
zend_bool incomplete_class = 0;
zend_str_tolower(Z_STRVAL_P(ent1->data), Z_STRLEN_P(ent1->data));
if (zend_hash_find(EG(class_table), Z_STRVAL_P(ent1->data),
Z_STRLEN_P(ent1->data)+1, (void **) &pce)==FAILURE) {
incomplete_class = 1;
pce = &PHP_IC_ENTRY;
}
/* Initialize target object */
MAKE_STD_ZVAL(obj);
object_init_ex(obj, *pce);
/* Merge current hashtable with object's default properties */
zend_hash_merge(Z_OBJPROP_P(obj),
Z_ARRVAL_P(ent2->data),
(void (*)(void *)) zval_add_ref,
(void *) &tmp, sizeof(zval *), 0);
if (incomplete_class) {
php_store_class_name(obj, Z_STRVAL_P(ent1->data), Z_STRLEN_P(ent1->data));
}
/* Clean up old array entry */
zval_ptr_dtor(&ent2->data);
/* Set stack entry to point to the newly created object */
ent2->data = obj;
/* Clean up class name var entry */
zval_ptr_dtor(&ent1->data);
} else if (Z_TYPE_P(ent2->data) == IS_OBJECT) {
zend_class_entry *old_scope = EG(scope);
EG(scope) = Z_OBJCE_P(ent2->data);
Z_DELREF_P(ent1->data);
add_property_zval(ent2->data, ent1->varname, ent1->data);
EG(scope) = old_scope;
} else {
zend_symtable_update(target_hash, ent1->varname, strlen(ent1->varname)+1, &ent1->data, sizeof(zval *), NULL);
}
efree(ent1->varname);
} else {
zend_hash_next_index_insert(target_hash, &ent1->data, sizeof(zval *), NULL);
}
}
efree(ent1);
} else {
stack->done = 1;
}
} else if (!strcmp(name, EL_VAR) && stack->varname) {
efree(stack->varname);
stack->varname = NULL;
} else if (!strcmp(name, EL_FIELD)) {
st_entry *ent;
wddx_stack_top(stack, (void **)&ent);
efree(ent);
stack->top--;
} | 875 | True | 1 |
CVE-2016-9934 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | True | [{'url': 'https://github.com/php/php-src/commit/6045de69c7dedcba3eadf7c4bba424b19c81d00d', 'name': 'https://github.com/php/php-src/commit/6045de69c7dedcba3eadf7c4bba424b19c81d00d', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73331', 'name': 'https://bugs.php.net/bug.php?id=73331', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'http://www.php.net/ChangeLog-7.php', 'name': 'http://www.php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/12/12/2', 'name': '[oss-security] 20161212 CVE assignment for PHP 5.6.28, 5.6.29, 7.0.13, 7.0.14 and 7.1.0', 'refsource': 'MLIST', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/94845', 'name': '94845', 'refsource': 'BID', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2016-12/msg00142.html', 'name': 'openSUSE-SU-2016:3239', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2017-01/msg00054.html', 'name': 'openSUSE-SU-2017:0081', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2017-01/msg00034.html', 'name': 'openSUSE-SU-2017:0061', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-476'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.27', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'ext/wddx/wddx.c in PHP before 5.6.28 and 7.x before 7.0.13 allows remote attackers to cause a denial of service (NULL pointer dereference) via crafted serialized data in a wddxPacket XML document, as demonstrated by a PDORow string.'}] | 2018-05-04T01:29Z | 2017-01-04T20:59Z | NULL Pointer Dereference | A NULL pointer dereference occurs when the application dereferences a pointer that it expects to be valid, but is NULL, typically causing a crash or exit. | NULL pointer dereference issues can occur through a number of flaws, including race conditions, and simple programming omissions.
| https://cwe.mitre.org/data/definitions/476.html | 0 | Stanislav Malyshev | 2016-10-23 20:07:47-07:00 | Fix bug #73331 - do not try to serialize/unserialize objects wddx can not handle
Proper soltion would be to call serialize/unserialize and deal with the result,
but this requires more work that should be done by wddx maintainer (not me). | 6045de69c7dedcba3eadf7c4bba424b19c81d00d | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_wddx_serialize_object | php_wddx_serialize_object( wddx_packet * packet , zval * obj) | ['packet', 'obj'] | */
static void php_wddx_serialize_object(wddx_packet *packet, zval *obj)
{
/* OBJECTS_FIXME */
zval **ent, *fname, **varname;
zval *retval = NULL;
const char *key;
ulong idx;
char tmp_buf[WDDX_BUF_LEN];
HashTable *objhash, *sleephash;
TSRMLS_FETCH();
MAKE_STD_ZVAL(fname);
ZVAL_STRING(fname, "__sleep", 1);
/*
* We try to call __sleep() method on object. It's supposed to return an
* array of property names to be serialized.
*/
if (call_user_function_ex(CG(function_table), &obj, fname, &retval, 0, 0, 1, NULL TSRMLS_CC) == SUCCESS) {
if (retval && (sleephash = HASH_OF(retval))) {
PHP_CLASS_ATTRIBUTES;
PHP_SET_CLASS_ATTRIBUTES(obj);
php_wddx_add_chunk_static(packet, WDDX_STRUCT_S);
snprintf(tmp_buf, WDDX_BUF_LEN, WDDX_VAR_S, PHP_CLASS_NAME_VAR);
php_wddx_add_chunk(packet, tmp_buf);
php_wddx_add_chunk_static(packet, WDDX_STRING_S);
php_wddx_add_chunk_ex(packet, class_name, name_len);
php_wddx_add_chunk_static(packet, WDDX_STRING_E);
php_wddx_add_chunk_static(packet, WDDX_VAR_E);
PHP_CLEANUP_CLASS_ATTRIBUTES();
objhash = HASH_OF(obj);
for (zend_hash_internal_pointer_reset(sleephash);
zend_hash_get_current_data(sleephash, (void **)&varname) == SUCCESS;
zend_hash_move_forward(sleephash)) {
if (Z_TYPE_PP(varname) != IS_STRING) {
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "__sleep should return an array only containing the names of instance-variables to serialize.");
continue;
}
if (zend_hash_find(objhash, Z_STRVAL_PP(varname), Z_STRLEN_PP(varname)+1, (void **)&ent) == SUCCESS) {
php_wddx_serialize_var(packet, *ent, Z_STRVAL_PP(varname), Z_STRLEN_PP(varname) TSRMLS_CC);
}
}
php_wddx_add_chunk_static(packet, WDDX_STRUCT_E);
}
} else {
uint key_len;
PHP_CLASS_ATTRIBUTES;
PHP_SET_CLASS_ATTRIBUTES(obj);
php_wddx_add_chunk_static(packet, WDDX_STRUCT_S);
snprintf(tmp_buf, WDDX_BUF_LEN, WDDX_VAR_S, PHP_CLASS_NAME_VAR);
php_wddx_add_chunk(packet, tmp_buf);
php_wddx_add_chunk_static(packet, WDDX_STRING_S);
php_wddx_add_chunk_ex(packet, class_name, name_len);
php_wddx_add_chunk_static(packet, WDDX_STRING_E);
php_wddx_add_chunk_static(packet, WDDX_VAR_E);
PHP_CLEANUP_CLASS_ATTRIBUTES();
objhash = HASH_OF(obj);
for (zend_hash_internal_pointer_reset(objhash);
zend_hash_get_current_data(objhash, (void**)&ent) == SUCCESS;
zend_hash_move_forward(objhash)) {
if (*ent == obj) {
continue;
}
if (zend_hash_get_current_key_ex(objhash, &key, &key_len, &idx, 0, NULL) == HASH_KEY_IS_STRING) {
const char *class_name, *prop_name;
zend_unmangle_property_name(key, key_len-1, &class_name, &prop_name);
php_wddx_serialize_var(packet, *ent, prop_name, strlen(prop_name)+1 TSRMLS_CC);
} else {
key_len = slprintf(tmp_buf, sizeof(tmp_buf), "%ld", idx);
php_wddx_serialize_var(packet, *ent, tmp_buf, key_len TSRMLS_CC);
}
}
php_wddx_add_chunk_static(packet, WDDX_STRUCT_E);
}
zval_dtor(fname);
FREE_ZVAL(fname);
if (retval) {
zval_ptr_dtor(&retval);
} | 537 | True | 1 |
CVE-2016-9933 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | True | [{'url': 'https://github.com/php/php-src/commit/863d37ea66d5c960db08d6f4a2cbd2518f0f80d1', 'name': 'https://github.com/php/php-src/commit/863d37ea66d5c960db08d6f4a2cbd2518f0f80d1', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'https://github.com/libgd/libgd/issues/215', 'name': 'https://github.com/libgd/libgd/issues/215', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'https://github.com/libgd/libgd/commit/77f619d48259383628c3ec4654b1ad578e9eb40e', 'name': 'https://github.com/libgd/libgd/commit/77f619d48259383628c3ec4654b1ad578e9eb40e', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=72696', 'name': 'https://bugs.php.net/bug.php?id=72696', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'http://www.php.net/ChangeLog-7.php', 'name': 'http://www.php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/12/12/2', 'name': '[oss-security] 20161212 CVE assignment for PHP 5.6.28, 5.6.29, 7.0.13, 7.0.14 and 7.1.0', 'refsource': 'MLIST', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/94865', 'name': '94865', 'refsource': 'BID', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2017-01/msg00002.html', 'name': 'openSUSE-SU-2017:0006', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2016-12/msg00142.html', 'name': 'openSUSE-SU-2016:3239', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2016-12/msg00133.html', 'name': 'openSUSE-SU-2016:3228', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://www.debian.org/security/2017/dsa-3751', 'name': 'DSA-3751', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2017-01/msg00054.html', 'name': 'openSUSE-SU-2017:0081', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2017-01/msg00034.html', 'name': 'openSUSE-SU-2017:0061', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | MEDIUM | [{'operator': 'AND', 'children': [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:libgd:libgd:2.2.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.27', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': False, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}]}], 'cpe_match': []}] | [{'lang': 'en', 'value': 'Stack consumption vulnerability in the gdImageFillToBorder function in gd.c in the GD Graphics Library (aka libgd) before 2.2.2, as used in PHP before 5.6.28 and 7.x before 7.0.13, allows remote attackers to cause a denial of service (segmentation violation) via a crafted imagefilltoborder call that triggers use of a negative color value.'}] | 2018-05-04T01:29Z | 2017-01-04T20:59Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Christoph M. Becker | 2016-10-25 13:23:16+02:00 | Fix #72696: imagefilltoborder stackoverflow on truecolor images
We must not allow negative color values be passed to
gdImageFillToBorder(), because that can lead to infinite recursion
since the recursion termination condition will not necessarily be met. | 863d37ea66d5c960db08d6f4a2cbd2518f0f80d1 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | gdImageFillToBorder | gdImageFillToBorder( gdImagePtr im , int x , int y , int border , int color) | ['im', 'x', 'y', 'border', 'color'] | void gdImageFillToBorder (gdImagePtr im, int x, int y, int border, int color)
{
int lastBorder;
/* Seek left */
int leftLimit = -1, rightLimit;
int i, restoreAlphaBlending = 0;
if (border < 0) {
/* Refuse to fill to a non-solid border */
return;
}
if (!im->trueColor) {
if ((color > (im->colorsTotal - 1)) || (border > (im->colorsTotal - 1)) || (color < 0)) {
return;
}
}
restoreAlphaBlending = im->alphaBlendingFlag;
im->alphaBlendingFlag = 0;
if (x >= im->sx) {
x = im->sx - 1;
} else if (x < 0) {
x = 0;
}
if (y >= im->sy) {
y = im->sy - 1;
} else if (y < 0) {
y = 0;
}
for (i = x; i >= 0; i--) {
if (gdImageGetPixel(im, i, y) == border) {
break;
}
gdImageSetPixel(im, i, y, color);
leftLimit = i;
}
if (leftLimit == -1) {
im->alphaBlendingFlag = restoreAlphaBlending;
return;
}
/* Seek right */
rightLimit = x;
for (i = (x + 1); i < im->sx; i++) {
if (gdImageGetPixel(im, i, y) == border) {
break;
}
gdImageSetPixel(im, i, y, color);
rightLimit = i;
}
/* Look at lines above and below and start paints */
/* Above */
if (y > 0) {
lastBorder = 1;
for (i = leftLimit; i <= rightLimit; i++) {
int c = gdImageGetPixel(im, i, y - 1);
if (lastBorder) {
if ((c != border) && (c != color)) {
gdImageFillToBorder(im, i, y - 1, border, color);
lastBorder = 0;
}
} else if ((c == border) || (c == color)) {
lastBorder = 1;
}
}
}
/* Below */
if (y < ((im->sy) - 1)) {
lastBorder = 1;
for (i = leftLimit; i <= rightLimit; i++) {
int c = gdImageGetPixel(im, i, y + 1);
if (lastBorder) {
if ((c != border) && (c != color)) {
gdImageFillToBorder(im, i, y + 1, border, color);
lastBorder = 0;
}
} else if ((c == border) || (c == color)) {
lastBorder = 1;
}
}
}
im->alphaBlendingFlag = restoreAlphaBlending;
} | 507 | True | 1 |
CVE-2016-9936 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | nan | [{'url': 'https://github.com/php/php-src/commit/b2af4e8868726a040234de113436c6e4f6372d17', 'name': 'https://github.com/php/php-src/commit/b2af4e8868726a040234de113436c6e4f6372d17', 'refsource': 'CONFIRM', 'tags': ['Patch']}, {'url': 'https://bugs.php.net/bug.php?id=72978', 'name': 'https://bugs.php.net/bug.php?id=72978', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Issue Tracking']}, {'url': 'http://www.php.net/ChangeLog-7.php', 'name': 'http://www.php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Release Notes']}, {'url': 'http://www.openwall.com/lists/oss-security/2016/12/12/2', 'name': '[oss-security] 20161212 CVE assignment for PHP 5.6.28, 5.6.29, 7.0.13, 7.0.14 and 7.1.0', 'refsource': 'MLIST', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/94849', 'name': '94849', 'refsource': 'BID', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2017-01/msg00034.html', 'name': 'openSUSE-SU-2017:0061', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-416'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The unserialize implementation in ext/standard/var.c in PHP 7.x before 7.0.14 allows remote attackers to cause a denial of service (use-after-free) or possibly have unspecified other impact via crafted serialized data. NOTE: this vulnerability exists because of an incomplete fix for CVE-2015-6834.'}] | 2018-05-04T01:29Z | 2017-01-04T20:59Z | Use After Free | Referencing memory after it has been freed can cause a program to crash, use unexpected values, or execute code. |
The use of previously-freed memory can have any number of adverse consequences, ranging from the corruption of valid data to the execution of arbitrary code, depending on the instantiation and timing of the flaw. The simplest way data corruption may occur involves the system's reuse of the freed memory. Use-after-free errors have two common and sometimes overlapping causes:
Error conditions and other exceptional circumstances.
Confusion over which part of the program is responsible for freeing the memory.
In this scenario, the memory in question is allocated to another pointer validly at some point after it has been freed. The original pointer to the freed memory is used again and points to somewhere within the new allocation. As the data is changed, it corrupts the validly used memory; this induces undefined behavior in the process.
If the newly allocated data chances to hold a class, in C++ for example, various function pointers may be scattered within the heap data. If one of these function pointers is overwritten with an address to valid shellcode, execution of arbitrary code can be achieved.
| https://cwe.mitre.org/data/definitions/416.html | 0 | Nikita Popov | 2016-10-23 21:37:36+02:00 | Complete the fix of bug #70172 for PHP 7 | b2af4e8868726a040234de113436c6e4f6372d17 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | PHP_FUNCTION | PHP_FUNCTION( unserialize) | ['unserialize'] | PHP_FUNCTION(unserialize)
{
char *buf = NULL;
size_t buf_len;
const unsigned char *p;
php_unserialize_data_t var_hash;
zval *options = NULL, *classes = NULL;
HashTable *class_hash = NULL;
if (zend_parse_parameters(ZEND_NUM_ARGS(), "s|a", &buf, &buf_len, &options) == FAILURE) {
RETURN_FALSE;
}
if (buf_len == 0) {
RETURN_FALSE;
}
p = (const unsigned char*) buf;
PHP_VAR_UNSERIALIZE_INIT(var_hash);
if(options != NULL) {
classes = zend_hash_str_find(Z_ARRVAL_P(options), "allowed_classes", sizeof("allowed_classes")-1);
if(classes && (Z_TYPE_P(classes) == IS_ARRAY || !zend_is_true(classes))) {
ALLOC_HASHTABLE(class_hash);
zend_hash_init(class_hash, (Z_TYPE_P(classes) == IS_ARRAY)?zend_hash_num_elements(Z_ARRVAL_P(classes)):0, NULL, NULL, 0);
}
if(class_hash && Z_TYPE_P(classes) == IS_ARRAY) {
zval *entry;
zend_string *lcname;
ZEND_HASH_FOREACH_VAL(Z_ARRVAL_P(classes), entry) {
convert_to_string_ex(entry);
lcname = zend_string_tolower(Z_STR_P(entry));
zend_hash_add_empty_element(class_hash, lcname);
zend_string_release(lcname);
} ZEND_HASH_FOREACH_END();
}
}
if (!php_var_unserialize_ex(return_value, &p, p + buf_len, &var_hash, class_hash)) {
PHP_VAR_UNSERIALIZE_DESTROY(var_hash);
if (class_hash) {
zend_hash_destroy(class_hash);
FREE_HASHTABLE(class_hash);
}
zval_ptr_dtor(return_value);
if (!EG(exception)) {
php_error_docref(NULL, E_NOTICE, "Error at offset " ZEND_LONG_FMT " of %zd bytes",
(zend_long)((char*)p - buf), buf_len);
}
RETURN_FALSE;
}
/* We should keep an reference to return_value to prevent it from being dtor
in case nesting calls to unserialize */
var_push_dtor(&var_hash, return_value);
PHP_VAR_UNSERIALIZE_DESTROY(var_hash);
if (class_hash) {
zend_hash_destroy(class_hash);
FREE_HASHTABLE(class_hash);
}
} | 353 | True | 1 |
CVE-2016-10161 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | nan | [{'url': 'https://github.com/php/php-src/commit/16b3003ffc6393e250f069aa28a78dc5a2c064b2', 'name': 'https://github.com/php/php-src/commit/16b3003ffc6393e250f069aa28a78dc5a2c064b2', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73825', 'name': 'https://bugs.php.net/bug.php?id=73825', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.securityfocus.com/bid/95768', 'name': '95768', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://security.gentoo.org/glsa/201702-29', 'name': 'GLSA-201702-29', 'refsource': 'GENTOO', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1037659', 'name': '1037659', 'refsource': 'SECTRACK', 'tags': []}, {'url': 'https://www.tenable.com/security/tns-2017-04', 'name': 'https://www.tenable.com/security/tns-2017-04', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.debian.org/security/2017/dsa-3783', 'name': 'DSA-3783', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.29', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The object_common1 function in ext/standard/var_unserializer.c in PHP before 5.6.30, 7.0.x before 7.0.15, and 7.1.x before 7.1.1 allows remote attackers to cause a denial of service (buffer over-read and application crash) via crafted serialized data that is mishandled in a finish_nested_data call.'}] | 2018-05-04T01:29Z | 2017-01-24T21:59Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Stanislav Malyshev | 2016-12-30 16:59:46-08:00 | Fix bug #73825 - Heap out of bounds read on unserialize in finish_nested_data() | 16b3003ffc6393e250f069aa28a78dc5a2c064b2 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | object_common1 | object_common1( UNSERIALIZE_PARAMETER , zend_class_entry * ce) | ['UNSERIALIZE_PARAMETER', 'ce'] | static inline long object_common1(UNSERIALIZE_PARAMETER, zend_class_entry *ce)
{
long elements;
elements = parse_iv2((*p) + 2, p);
(*p) += 2;
if (ce->serialize == NULL) {
object_init_ex(*rval, ce);
} else {
/* If this class implements Serializable, it should not land here but in object_custom(). The passed string
obviously doesn't descend from the regular serializer. */
zend_error(E_WARNING, "Erroneous data format for unserializing '%s'", ce->name);
return 0;
}
return elements;
} | 72 | True | 1 |
CVE-2016-10161 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | nan | [{'url': 'https://github.com/php/php-src/commit/16b3003ffc6393e250f069aa28a78dc5a2c064b2', 'name': 'https://github.com/php/php-src/commit/16b3003ffc6393e250f069aa28a78dc5a2c064b2', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73825', 'name': 'https://bugs.php.net/bug.php?id=73825', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.securityfocus.com/bid/95768', 'name': '95768', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://security.gentoo.org/glsa/201702-29', 'name': 'GLSA-201702-29', 'refsource': 'GENTOO', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1037659', 'name': '1037659', 'refsource': 'SECTRACK', 'tags': []}, {'url': 'https://www.tenable.com/security/tns-2017-04', 'name': 'https://www.tenable.com/security/tns-2017-04', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.debian.org/security/2017/dsa-3783', 'name': 'DSA-3783', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.29', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The object_common1 function in ext/standard/var_unserializer.c in PHP before 5.6.30, 7.0.x before 7.0.15, and 7.1.x before 7.1.1 allows remote attackers to cause a denial of service (buffer over-read and application crash) via crafted serialized data that is mishandled in a finish_nested_data call.'}] | 2018-05-04T01:29Z | 2017-01-24T21:59Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Stanislav Malyshev | 2016-12-30 16:59:46-08:00 | Fix bug #73825 - Heap out of bounds read on unserialize in finish_nested_data() | 16b3003ffc6393e250f069aa28a78dc5a2c064b2 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_var_unserialize | php_var_unserialize( UNSERIALIZE_PARAMETER) | ['UNSERIALIZE_PARAMETER'] | PHPAPI int php_var_unserialize(UNSERIALIZE_PARAMETER)
{
const unsigned char *cursor, *limit, *marker, *start;
zval **rval_ref;
limit = max;
cursor = *p;
if (YYCURSOR >= YYLIMIT) {
return 0;
}
if (var_hash && cursor[0] != 'R') {
var_push(var_hash, rval);
}
start = cursor;
#line 496 "ext/standard/var_unserializer.c"
{
YYCTYPE yych;
static const unsigned char yybm[] = {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
128, 128, 128, 128, 128, 128, 128, 128,
128, 128, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
};
if ((YYLIMIT - YYCURSOR) < 7) YYFILL(7);
yych = *YYCURSOR;
switch (yych) {
case 'C':
case 'O': goto yy13;
case 'N': goto yy5;
case 'R': goto yy2;
case 'S': goto yy10;
case 'a': goto yy11;
case 'b': goto yy6;
case 'd': goto yy8;
case 'i': goto yy7;
case 'o': goto yy12;
case 'r': goto yy4;
case 's': goto yy9;
case '}': goto yy14;
default: goto yy16;
}
yy2:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy95;
yy3:
#line 861 "ext/standard/var_unserializer.re"
{ return 0; }
#line 558 "ext/standard/var_unserializer.c"
yy4:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy89;
goto yy3;
yy5:
yych = *++YYCURSOR;
if (yych == ';') goto yy87;
goto yy3;
yy6:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy83;
goto yy3;
yy7:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy77;
goto yy3;
yy8:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy53;
goto yy3;
yy9:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy46;
goto yy3;
yy10:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy39;
goto yy3;
yy11:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy32;
goto yy3;
yy12:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy25;
goto yy3;
yy13:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy17;
goto yy3;
yy14:
++YYCURSOR;
#line 855 "ext/standard/var_unserializer.re"
{
/* this is the case where we have less data than planned */
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Unexpected end of serialized data");
return 0; /* not sure if it should be 0 or 1 here? */
}
#line 607 "ext/standard/var_unserializer.c"
yy16:
yych = *++YYCURSOR;
goto yy3;
yy17:
yych = *++YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
if (yych == '+') goto yy19;
yy18:
YYCURSOR = YYMARKER;
goto yy3;
yy19:
yych = *++YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
goto yy18;
yy20:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
if (yych <= '/') goto yy18;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 708 "ext/standard/var_unserializer.re"
{
size_t len, len2, len3, maxlen;
long elements;
char *class_name;
zend_class_entry *ce;
zend_class_entry **pce;
int incomplete_class = 0;
int custom_object = 0;
zval *user_func;
zval *retval_ptr;
zval **args[1];
zval *arg_func_name;
if (!var_hash) return 0;
if (*start == 'C') {
custom_object = 1;
}
INIT_PZVAL(*rval);
len2 = len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len || len == 0) {
*p = start + 2;
return 0;
}
class_name = (char*)YYCURSOR;
YYCURSOR += len;
if (*(YYCURSOR) != '"') {
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR+1) != ':') {
*p = YYCURSOR+1;
return 0;
}
len3 = strspn(class_name, "0123456789_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\177\200\201\202\203\204\205\206\207\210\211\212\213\214\215\216\217\220\221\222\223\224\225\226\227\230\231\232\233\234\235\236\237\240\241\242\243\244\245\246\247\250\251\252\253\254\255\256\257\260\261\262\263\264\265\266\267\270\271\272\273\274\275\276\277\300\301\302\303\304\305\306\307\310\311\312\313\314\315\316\317\320\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343\344\345\346\347\350\351\352\353\354\355\356\357\360\361\362\363\364\365\366\367\370\371\372\373\374\375\376\377\\");
if (len3 != len)
{
*p = YYCURSOR + len3 - len;
return 0;
}
class_name = estrndup(class_name, len);
do {
/* Try to find class directly */
BG(serialize_lock)++;
if (zend_lookup_class(class_name, len2, &pce TSRMLS_CC) == SUCCESS) {
BG(serialize_lock)--;
if (EG(exception)) {
efree(class_name);
return 0;
}
ce = *pce;
break;
}
BG(serialize_lock)--;
if (EG(exception)) {
efree(class_name);
return 0;
}
/* Check for unserialize callback */
if ((PG(unserialize_callback_func) == NULL) || (PG(unserialize_callback_func)[0] == '\0')) {
incomplete_class = 1;
ce = PHP_IC_ENTRY;
break;
}
/* Call unserialize callback */
MAKE_STD_ZVAL(user_func);
ZVAL_STRING(user_func, PG(unserialize_callback_func), 1);
args[0] = &arg_func_name;
MAKE_STD_ZVAL(arg_func_name);
ZVAL_STRING(arg_func_name, class_name, 1);
BG(serialize_lock)++;
if (call_user_function_ex(CG(function_table), NULL, user_func, &retval_ptr, 1, args, 0, NULL TSRMLS_CC) != SUCCESS) {
BG(serialize_lock)--;
if (EG(exception)) {
efree(class_name);
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&arg_func_name);
return 0;
}
php_error_docref(NULL TSRMLS_CC, E_WARNING, "defined (%s) but not found", user_func->value.str.val);
incomplete_class = 1;
ce = PHP_IC_ENTRY;
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&arg_func_name);
break;
}
BG(serialize_lock)--;
if (retval_ptr) {
zval_ptr_dtor(&retval_ptr);
}
if (EG(exception)) {
efree(class_name);
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&arg_func_name);
return 0;
}
/* The callback function may have defined the class */
if (zend_lookup_class(class_name, len2, &pce TSRMLS_CC) == SUCCESS) {
ce = *pce;
} else {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Function %s() hasn't defined the class it was called for", user_func->value.str.val);
incomplete_class = 1;
ce = PHP_IC_ENTRY;
}
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&arg_func_name);
break;
} while (1);
*p = YYCURSOR;
if (custom_object) {
int ret;
ret = object_custom(UNSERIALIZE_PASSTHRU, ce);
if (ret && incomplete_class) {
php_store_class_name(*rval, class_name, len2);
}
efree(class_name);
return ret;
}
elements = object_common1(UNSERIALIZE_PASSTHRU, ce);
if (incomplete_class) {
php_store_class_name(*rval, class_name, len2);
}
efree(class_name);
return object_common2(UNSERIALIZE_PASSTHRU, elements);
}
#line 785 "ext/standard/var_unserializer.c"
yy25:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy26;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy27;
goto yy18;
}
yy26:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy27:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy27;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 699 "ext/standard/var_unserializer.re"
{
if (!var_hash) return 0;
INIT_PZVAL(*rval);
return object_common2(UNSERIALIZE_PASSTHRU,
object_common1(UNSERIALIZE_PASSTHRU, ZEND_STANDARD_CLASS_DEF_PTR));
}
#line 819 "ext/standard/var_unserializer.c"
yy32:
yych = *++YYCURSOR;
if (yych == '+') goto yy33;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy34;
goto yy18;
yy33:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy34:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy34;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '{') goto yy18;
++YYCURSOR;
#line 678 "ext/standard/var_unserializer.re"
{
long elements = parse_iv(start + 2);
/* use iv() not uiv() in order to check data range */
*p = YYCURSOR;
if (!var_hash) return 0;
if (elements < 0) {
return 0;
}
INIT_PZVAL(*rval);
array_init_size(*rval, elements);
if (!process_nested_data(UNSERIALIZE_PASSTHRU, Z_ARRVAL_PP(rval), elements, 0)) {
return 0;
}
return finish_nested_data(UNSERIALIZE_PASSTHRU);
}
#line 861 "ext/standard/var_unserializer.c"
yy39:
yych = *++YYCURSOR;
if (yych == '+') goto yy40;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy41;
goto yy18;
yy40:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy41:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy41;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 643 "ext/standard/var_unserializer.re"
{
size_t len, maxlen;
char *str;
len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len) {
*p = start + 2;
return 0;
}
if ((str = unserialize_str(&YYCURSOR, &len, maxlen)) == NULL) {
return 0;
}
if (*(YYCURSOR) != '"') {
efree(str);
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR + 1) != ';') {
efree(str);
*p = YYCURSOR + 1;
return 0;
}
YYCURSOR += 2;
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_STRINGL(*rval, str, len, 0);
return 1;
}
#line 917 "ext/standard/var_unserializer.c"
yy46:
yych = *++YYCURSOR;
if (yych == '+') goto yy47;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy48;
goto yy18;
yy47:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy48:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy48;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 610 "ext/standard/var_unserializer.re"
{
size_t len, maxlen;
char *str;
len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len) {
*p = start + 2;
return 0;
}
str = (char*)YYCURSOR;
YYCURSOR += len;
if (*(YYCURSOR) != '"') {
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR + 1) != ';') {
*p = YYCURSOR + 1;
return 0;
}
YYCURSOR += 2;
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_STRINGL(*rval, str, len, 1);
return 1;
}
#line 971 "ext/standard/var_unserializer.c"
yy53:
yych = *++YYCURSOR;
if (yych <= '/') {
if (yych <= ',') {
if (yych == '+') goto yy57;
goto yy18;
} else {
if (yych <= '-') goto yy55;
if (yych <= '.') goto yy60;
goto yy18;
}
} else {
if (yych <= 'I') {
if (yych <= '9') goto yy58;
if (yych <= 'H') goto yy18;
goto yy56;
} else {
if (yych != 'N') goto yy18;
}
}
yych = *++YYCURSOR;
if (yych == 'A') goto yy76;
goto yy18;
yy55:
yych = *++YYCURSOR;
if (yych <= '/') {
if (yych == '.') goto yy60;
goto yy18;
} else {
if (yych <= '9') goto yy58;
if (yych != 'I') goto yy18;
}
yy56:
yych = *++YYCURSOR;
if (yych == 'N') goto yy72;
goto yy18;
yy57:
yych = *++YYCURSOR;
if (yych == '.') goto yy60;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy58:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ':') {
if (yych <= '.') {
if (yych <= '-') goto yy18;
goto yy70;
} else {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy58;
goto yy18;
}
} else {
if (yych <= 'E') {
if (yych <= ';') goto yy63;
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy60:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy61:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ';') {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy61;
if (yych <= ':') goto yy18;
} else {
if (yych <= 'E') {
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy63:
++YYCURSOR;
#line 600 "ext/standard/var_unserializer.re"
{
#if SIZEOF_LONG == 4
use_double:
#endif
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_DOUBLE(*rval, zend_strtod((const char *)start + 2, NULL));
return 1;
}
#line 1069 "ext/standard/var_unserializer.c"
yy65:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy66;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
goto yy18;
}
yy66:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych == '+') goto yy69;
goto yy18;
} else {
if (yych <= '-') goto yy69;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
}
yy67:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
if (yych == ';') goto yy63;
goto yy18;
yy69:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
goto yy18;
yy70:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ';') {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy70;
if (yych <= ':') goto yy18;
goto yy63;
} else {
if (yych <= 'E') {
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy72:
yych = *++YYCURSOR;
if (yych != 'F') goto yy18;
yy73:
yych = *++YYCURSOR;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 585 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
INIT_PZVAL(*rval);
if (!strncmp(start + 2, "NAN", 3)) {
ZVAL_DOUBLE(*rval, php_get_nan());
} else if (!strncmp(start + 2, "INF", 3)) {
ZVAL_DOUBLE(*rval, php_get_inf());
} else if (!strncmp(start + 2, "-INF", 4)) {
ZVAL_DOUBLE(*rval, -php_get_inf());
}
return 1;
}
#line 1143 "ext/standard/var_unserializer.c"
yy76:
yych = *++YYCURSOR;
if (yych == 'N') goto yy73;
goto yy18;
yy77:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy78;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy79;
goto yy18;
}
yy78:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy79:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy79;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 558 "ext/standard/var_unserializer.re"
{
#if SIZEOF_LONG == 4
int digits = YYCURSOR - start - 3;
if (start[2] == '-' || start[2] == '+') {
digits--;
}
/* Use double for large long values that were serialized on a 64-bit system */
if (digits >= MAX_LENGTH_OF_LONG - 1) {
if (digits == MAX_LENGTH_OF_LONG - 1) {
int cmp = strncmp(YYCURSOR - MAX_LENGTH_OF_LONG, long_min_digits, MAX_LENGTH_OF_LONG - 1);
if (!(cmp < 0 || (cmp == 0 && start[2] == '-'))) {
goto use_double;
}
} else {
goto use_double;
}
}
#endif
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_LONG(*rval, parse_iv(start + 2));
return 1;
}
#line 1197 "ext/standard/var_unserializer.c"
yy83:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= '2') goto yy18;
yych = *++YYCURSOR;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 551 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_BOOL(*rval, parse_iv(start + 2));
return 1;
}
#line 1212 "ext/standard/var_unserializer.c"
yy87:
++YYCURSOR;
#line 544 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
INIT_PZVAL(*rval);
ZVAL_NULL(*rval);
return 1;
}
#line 1222 "ext/standard/var_unserializer.c"
yy89:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy90;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy91;
goto yy18;
}
yy90:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy91:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy91;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 521 "ext/standard/var_unserializer.re"
{
long id;
*p = YYCURSOR;
if (!var_hash) return 0;
id = parse_iv(start + 2) - 1;
if (id == -1 || var_access(var_hash, id, &rval_ref) != SUCCESS) {
return 0;
}
if (*rval == *rval_ref) return 0;
if (*rval != NULL) {
var_push_dtor_no_addref(var_hash, rval);
}
*rval = *rval_ref;
Z_ADDREF_PP(rval);
Z_UNSET_ISREF_PP(rval);
return 1;
}
#line 1268 "ext/standard/var_unserializer.c"
yy95:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy96;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy97;
goto yy18;
}
yy96:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy97:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy97;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 500 "ext/standard/var_unserializer.re"
{
long id;
*p = YYCURSOR;
if (!var_hash) return 0;
id = parse_iv(start + 2) - 1;
if (id == -1 || var_access(var_hash, id, &rval_ref) != SUCCESS) {
return 0;
}
if (*rval != NULL) {
var_push_dtor_no_addref(var_hash, rval);
}
*rval = *rval_ref;
Z_ADDREF_PP(rval);
Z_SET_ISREF_PP(rval);
return 1;
}
#line 1312 "ext/standard/var_unserializer.c"
}
#line 863 "ext/standard/var_unserializer.re"
return 0;
} | 4557 | True | 1 |
CVE-2016-10158 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | nan | [{'url': 'https://github.com/php/php-src/commit/1cda0d7c2ffb62d8331c64e703131d9cabdc03ea', 'name': 'https://github.com/php/php-src/commit/1cda0d7c2ffb62d8331c64e703131d9cabdc03ea', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73737', 'name': 'https://bugs.php.net/bug.php?id=73737', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.securityfocus.com/bid/95764', 'name': '95764', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://security.gentoo.org/glsa/201702-29', 'name': 'GLSA-201702-29', 'refsource': 'GENTOO', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1037659', 'name': '1037659', 'refsource': 'SECTRACK', 'tags': []}, {'url': 'https://www.tenable.com/security/tns-2017-04', 'name': 'https://www.tenable.com/security/tns-2017-04', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.debian.org/security/2017/dsa-3783', 'name': 'DSA-3783', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-189'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.29', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The exif_convert_any_to_int function in ext/exif/exif.c in PHP before 5.6.30, 7.0.x before 7.0.15, and 7.1.x before 7.1.1 allows remote attackers to cause a denial of service (application crash) via crafted EXIF data that triggers an attempt to divide the minimum representable negative integer by -1.'}] | 2018-05-04T01:29Z | 2017-01-24T21:59Z | Numeric Errors | Weaknesses in this category are related to improper calculation or conversion of numbers. | https://cwe.mitre.org/data/definitions/189.html | 1 | Stanislav Malyshev | 2016-12-31 19:31:49-08:00 | Fix bug #73737 FPE when parsing a tag format | 1cda0d7c2ffb62d8331c64e703131d9cabdc03ea | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | exif_convert_any_to_int | exif_convert_any_to_int( void * value , int format , int motorola_intel TSRMLS_DC) | ['value', 'format', 'TSRMLS_DC'] | static size_t exif_convert_any_to_int(void *value, int format, int motorola_intel TSRMLS_DC)
{
int s_den;
unsigned u_den;
switch(format) {
case TAG_FMT_SBYTE: return *(signed char *)value;
case TAG_FMT_BYTE: return *(uchar *)value;
case TAG_FMT_USHORT: return php_ifd_get16u(value, motorola_intel);
case TAG_FMT_ULONG: return php_ifd_get32u(value, motorola_intel);
case TAG_FMT_URATIONAL:
u_den = php_ifd_get32u(4+(char *)value, motorola_intel);
if (u_den == 0) {
return 0;
} else {
return php_ifd_get32u(value, motorola_intel) / u_den;
}
case TAG_FMT_SRATIONAL:
s_den = php_ifd_get32s(4+(char *)value, motorola_intel);
if (s_den == 0) {
return 0;
} else {
return php_ifd_get32s(value, motorola_intel) / s_den;
}
case TAG_FMT_SSHORT: return php_ifd_get16u(value, motorola_intel);
case TAG_FMT_SLONG: return php_ifd_get32s(value, motorola_intel);
/* Not sure if this is correct (never seen float used in Exif format) */
case TAG_FMT_SINGLE:
#ifdef EXIF_DEBUG
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Found value of type single");
#endif
return (size_t)*(float *)value;
case TAG_FMT_DOUBLE:
#ifdef EXIF_DEBUG
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Found value of type double");
#endif
return (size_t)*(double *)value;
}
return 0;
} | 229 | True | 1 |
|
CVE-2016-10162 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | nan | [{'url': 'https://github.com/php/php-src/commit/8d2539fa0faf3f63e1d1e7635347c5b9e777d47b', 'name': 'https://github.com/php/php-src/commit/8d2539fa0faf3f63e1d1e7635347c5b9e777d47b', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73831', 'name': 'https://bugs.php.net/bug.php?id=73831', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.securityfocus.com/bid/95668', 'name': '95668', 'refsource': 'BID', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1037659', 'name': '1037659', 'refsource': 'SECTRACK', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-476'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The php_wddx_pop_element function in ext/wddx/wddx.c in PHP 7.0.x before 7.0.15 and 7.1.x before 7.1.1 allows remote attackers to cause a denial of service (NULL pointer dereference and application crash) via an inapplicable class name in a wddxPacket XML document, leading to mishandling in a wddx_deserialize call.'}] | 2018-05-04T01:29Z | 2017-01-24T21:59Z | NULL Pointer Dereference | A NULL pointer dereference occurs when the application dereferences a pointer that it expects to be valid, but is NULL, typically causing a crash or exit. | NULL pointer dereference issues can occur through a number of flaws, including race conditions, and simple programming omissions.
| https://cwe.mitre.org/data/definitions/476.html | 0 | Stanislav Malyshev | 2016-12-31 20:14:20-08:00 | Fix bug #73831 - NULL Pointer Dereference while unserialize php object | 8d2539fa0faf3f63e1d1e7635347c5b9e777d47b | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_wddx_pop_element | php_wddx_pop_element( void * user_data , const XML_Char * name) | ['user_data', 'name'] | */
static void php_wddx_pop_element(void *user_data, const XML_Char *name)
{
st_entry *ent1, *ent2;
wddx_stack *stack = (wddx_stack *)user_data;
HashTable *target_hash;
zend_class_entry *pce;
zval obj;
/* OBJECTS_FIXME */
if (stack->top == 0) {
return;
}
if (!strcmp((char *)name, EL_STRING) || !strcmp((char *)name, EL_NUMBER) ||
!strcmp((char *)name, EL_BOOLEAN) || !strcmp((char *)name, EL_NULL) ||
!strcmp((char *)name, EL_ARRAY) || !strcmp((char *)name, EL_STRUCT) ||
!strcmp((char *)name, EL_RECORDSET) || !strcmp((char *)name, EL_BINARY) ||
!strcmp((char *)name, EL_DATETIME)) {
wddx_stack_top(stack, (void**)&ent1);
if (Z_TYPE(ent1->data) == IS_UNDEF) {
if (stack->top > 1) {
stack->top--;
efree(ent1);
} else {
stack->done = 1;
}
return;
}
if (!strcmp((char *)name, EL_BINARY)) {
zend_string *new_str = NULL;
if (ZSTR_EMPTY_ALLOC() != Z_STR(ent1->data)) {
new_str = php_base64_decode(
(unsigned char *)Z_STRVAL(ent1->data), Z_STRLEN(ent1->data));
}
zval_ptr_dtor(&ent1->data);
if (new_str) {
ZVAL_STR(&ent1->data, new_str);
} else {
ZVAL_EMPTY_STRING(&ent1->data);
}
}
/* Call __wakeup() method on the object. */
if (Z_TYPE(ent1->data) == IS_OBJECT) {
zval fname, retval;
ZVAL_STRING(&fname, "__wakeup");
call_user_function_ex(NULL, &ent1->data, &fname, &retval, 0, 0, 0, NULL);
zval_ptr_dtor(&fname);
zval_ptr_dtor(&retval);
}
if (stack->top > 1) {
stack->top--;
wddx_stack_top(stack, (void**)&ent2);
/* if non-existent field */
if (Z_ISUNDEF(ent2->data)) {
zval_ptr_dtor(&ent1->data);
efree(ent1);
return;
}
if (Z_TYPE(ent2->data) == IS_ARRAY || Z_TYPE(ent2->data) == IS_OBJECT) {
target_hash = HASH_OF(&ent2->data);
if (ent1->varname) {
if (!strcmp(ent1->varname, PHP_CLASS_NAME_VAR) &&
Z_TYPE(ent1->data) == IS_STRING && Z_STRLEN(ent1->data) &&
ent2->type == ST_STRUCT && Z_TYPE(ent2->data) == IS_ARRAY) {
zend_bool incomplete_class = 0;
zend_str_tolower(Z_STRVAL(ent1->data), Z_STRLEN(ent1->data));
zend_string_forget_hash_val(Z_STR(ent1->data));
if ((pce = zend_hash_find_ptr(EG(class_table), Z_STR(ent1->data))) == NULL) {
incomplete_class = 1;
pce = PHP_IC_ENTRY;
}
if (pce != PHP_IC_ENTRY && (pce->serialize || pce->unserialize)) {
zval_ptr_dtor(&ent2->data);
ZVAL_UNDEF(&ent2->data);
php_error_docref(NULL, E_WARNING, "Class %s can not be unserialized", Z_STRVAL(ent1->data));
} else {
/* Initialize target object */
object_init_ex(&obj, pce);
/* Merge current hashtable with object's default properties */
zend_hash_merge(Z_OBJPROP(obj),
Z_ARRVAL(ent2->data),
zval_add_ref, 0);
if (incomplete_class) {
php_store_class_name(&obj, Z_STRVAL(ent1->data), Z_STRLEN(ent1->data));
}
/* Clean up old array entry */
zval_ptr_dtor(&ent2->data);
/* Set stack entry to point to the newly created object */
ZVAL_COPY_VALUE(&ent2->data, &obj);
}
/* Clean up class name var entry */
zval_ptr_dtor(&ent1->data);
} else if (Z_TYPE(ent2->data) == IS_OBJECT) {
zend_class_entry *old_scope = EG(scope);
EG(scope) = Z_OBJCE(ent2->data);
add_property_zval(&ent2->data, ent1->varname, &ent1->data);
if Z_REFCOUNTED(ent1->data) Z_DELREF(ent1->data);
EG(scope) = old_scope;
} else {
zend_symtable_str_update(target_hash, ent1->varname, strlen(ent1->varname), &ent1->data);
}
efree(ent1->varname);
} else {
zend_hash_next_index_insert(target_hash, &ent1->data);
}
}
efree(ent1);
} else {
stack->done = 1;
}
} else if (!strcmp((char *)name, EL_VAR) && stack->varname) {
efree(stack->varname);
stack->varname = NULL;
} else if (!strcmp((char *)name, EL_FIELD)) {
st_entry *ent;
wddx_stack_top(stack, (void **)&ent);
efree(ent);
stack->top--;
} | 923 | True | 1 |
CVE-2017-5340 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | True | [{'url': 'https://github.com/php/php-src/commit/4cc0286f2f3780abc6084bcdae5dce595daa3c12', 'name': 'https://github.com/php/php-src/commit/4cc0286f2f3780abc6084bcdae5dce595daa3c12', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73832', 'name': 'https://bugs.php.net/bug.php?id=73832', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Issue Tracking', 'VDB Entry', 'Vendor Advisory']}, {'url': 'http://www.securityfocus.com/bid/95371', 'name': '95371', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'http://www.securitytracker.com/id/1037659', 'name': '1037659', 'refsource': 'SECTRACK', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-190'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '7.1.0', 'versionEndExcluding': '7.1.1', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '7.0.0', 'versionEndExcluding': '7.0.15', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:netapp:clustered_data_ontap:-:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'Zend/zend_hash.c in PHP before 7.0.15 and 7.1.x before 7.1.1 mishandles certain cases that require large array allocations, which allows remote attackers to execute arbitrary code or cause a denial of service (integer overflow, uninitialized memory access, and use of arbitrary destructor function pointers) via crafted serialized data.'}] | 2022-07-20T16:46Z | 2017-01-11T06:59Z | Integer Overflow or Wraparound | The software performs a calculation that can produce an integer overflow or wraparound, when the logic assumes that the resulting value will always be larger than the original value. This can introduce other weaknesses when the calculation is used for resource management or execution control. | An integer overflow or wraparound occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, the value may wrap to become a very small or negative number. While this may be intended behavior in circumstances that rely on wrapping, it can have security consequences if the wrap is unexpected. This is especially the case if the integer overflow can be triggered using user-supplied inputs. This becomes security-critical when the result is used to control looping, make a security decision, or determine the offset or size in behaviors such as memory allocation, copying, concatenation, etc.
| https://cwe.mitre.org/data/definitions/190.html | 0 | Stanislav Malyshev | 2017-01-02 20:14:05-08:00 | Fix #73832 - leave the table in a safe state if the size is too big. | 4cc0286f2f3780abc6084bcdae5dce595daa3c12 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | _zend_hash_init | _zend_hash_init( HashTable * ht , uint32_t nSize , dtor_func_t pDestructor , zend_bool persistent ZEND_FILE_LINE_DC) | ['ht', 'nSize', 'pDestructor', 'ZEND_FILE_LINE_DC'] | ZEND_API void ZEND_FASTCALL _zend_hash_init(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent ZEND_FILE_LINE_DC)
{
GC_REFCOUNT(ht) = 1;
GC_TYPE_INFO(ht) = IS_ARRAY;
ht->u.flags = (persistent ? HASH_FLAG_PERSISTENT : 0) | HASH_FLAG_APPLY_PROTECTION | HASH_FLAG_STATIC_KEYS;
ht->nTableSize = zend_hash_check_size(nSize);
ht->nTableMask = HT_MIN_MASK;
HT_SET_DATA_ADDR(ht, &uninitialized_bucket);
ht->nNumUsed = 0;
ht->nNumOfElements = 0;
ht->nInternalPointer = HT_INVALID_IDX;
ht->nNextFreeElement = 0;
ht->pDestructor = pDestructor;
} | 103 | True | 1 |
CVE-2017-11142 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:C | NETWORK | LOW | NONE | NONE | NONE | COMPLETE | 7.8 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | nan | [{'url': 'https://github.com/php/php-src/commit/a15bffd105ac28fd0dd9b596632dbf035238fda3', 'name': 'https://github.com/php/php-src/commit/a15bffd105ac28fd0dd9b596632dbf035238fda3', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/php/php-src/commit/0f8cf3b8497dc45c010c44ed9e96518e11e19fc3', 'name': 'https://github.com/php/php-src/commit/0f8cf3b8497dc45c010c44ed9e96518e11e19fc3', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73807', 'name': 'https://bugs.php.net/bug.php?id=73807', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://openwall.com/lists/oss-security/2017/07/10/6', 'name': 'http://openwall.com/lists/oss-security/2017/07/10/6', 'refsource': 'CONFIRM', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/99601', 'name': '99601', 'refsource': 'BID', 'tags': []}, {'url': 'https://www.tenable.com/security/tns-2017-12', 'name': 'https://www.tenable.com/security/tns-2017-12', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://www.debian.org/security/2018/dsa-4081', 'name': 'DSA-4081', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-400'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.16:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.30', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In PHP before 5.6.31, 7.x before 7.0.17, and 7.1.x before 7.1.3, remote attackers could cause a CPU consumption denial of service attack by injecting long form variables, related to main/php_variables.c.'}] | 2018-01-14T02:29Z | 2017-07-10T14:29Z | Uncontrolled Resource Consumption | The software does not properly control the allocation and maintenance of a limited resource, thereby enabling an actor to influence the amount of resources consumed, eventually leading to the exhaustion of available resources. |
Limited resources include memory, file system storage, database connection pool entries, and CPU. If an attacker can trigger the allocation of these limited resources, but the number or size of the resources is not controlled, then the attacker could cause a denial of service that consumes all available resources. This would prevent valid users from accessing the software, and it could potentially have an impact on the surrounding environment. For example, a memory exhaustion attack against an application could slow down the application as well as its host operating system.
There are at least three distinct scenarios which can commonly lead to resource exhaustion:
Lack of throttling for the number of allocated resources
Losing all references to a resource before reaching the shutdown stage
Not closing/returning a resource after processing
Resource exhaustion problems are often result due to an incorrect implementation of the following situations:
Error conditions and other exceptional circumstances.
Confusion over which part of the program is responsible for releasing the resource.
| https://cwe.mitre.org/data/definitions/400.html | 0 | Nikita Popov | 2017-02-02 16:04:02+01:00 | Fix bug #73807 | a15bffd105ac28fd0dd9b596632dbf035238fda3 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | add_post_var | add_post_var( zval * arr , post_var_data_t * var , zend_bool eof) | ['arr', 'var', 'eof'] | static zend_bool add_post_var(zval *arr, post_var_data_t *var, zend_bool eof)
{
char *ksep, *vsep, *val;
size_t klen, vlen;
size_t new_vlen;
if (var->ptr >= var->end) {
return 0;
}
vsep = memchr(var->ptr, '&', var->end - var->ptr);
if (!vsep) {
if (!eof) {
return 0;
} else {
vsep = var->end;
}
}
ksep = memchr(var->ptr, '=', vsep - var->ptr);
if (ksep) {
*ksep = '\0';
/* "foo=bar&" or "foo=&" */
klen = ksep - var->ptr;
vlen = vsep - ++ksep;
} else {
ksep = "";
/* "foo&" */
klen = vsep - var->ptr;
vlen = 0;
}
php_url_decode(var->ptr, klen);
val = estrndup(ksep, vlen);
if (vlen) {
vlen = php_url_decode(val, vlen);
}
if (sapi_module.input_filter(PARSE_POST, var->ptr, &val, vlen, &new_vlen)) {
php_register_variable_safe(var->ptr, val, new_vlen, arr);
}
efree(val);
var->ptr = vsep + (vsep != var->end);
return 1;
} | 246 | True | 1 |
CVE-2017-7189 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:N | NETWORK | LOW | NONE | PARTIAL | NONE | NONE | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | NONE | NONE | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/php/php-src/commit/bab0b99f376dac9170ac81382a5ed526938d595a', 'name': 'https://github.com/php/php-src/commit/bab0b99f376dac9170ac81382a5ed526938d595a', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=74192', 'name': 'https://bugs.php.net/bug.php?id=74192', 'refsource': 'MISC', 'tags': ['Permissions Required', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-20'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '7.0.0', 'versionEndExcluding': '7.0.16', 'cpe_name': []}]}] | [{'lang': 'en', 'value': "main/streams/xp_socket.c in PHP 7.x before 2017-03-07 misparses fsockopen calls, such as by interpreting fsockopen('127.0.0.1:80', 443) as if the address/port were 127.0.0.1:80:443, which is later truncated to 127.0.0.1:80. This behavior has a security risk if the explicitly provided port number (i.e., 443 in this example) is hardcoded into an application as a security policy, but the hostname argument (i.e., 127.0.0.1:80 in this example) is obtained from untrusted input."}] | 2019-07-17T16:39Z | 2019-07-10T15:15Z | Improper Input Validation | The product receives input or data, but it does
not validate or incorrectly validates that the input has the
properties that are required to process the data safely and
correctly. |
Input validation is a frequently-used technique
for checking potentially dangerous inputs in order to
ensure that the inputs are safe for processing within the
code, or when communicating with other components. When
software does not validate input properly, an attacker is
able to craft the input in a form that is not expected by
the rest of the application. This will lead to parts of the
system receiving unintended input, which may result in
altered control flow, arbitrary control of a resource, or
arbitrary code execution.
Input validation is not the only technique for
processing input, however. Other techniques attempt to
transform potentially-dangerous input into something safe, such
as filtering (CWE-790) - which attempts to remove dangerous
inputs - or encoding/escaping (CWE-116), which attempts to
ensure that the input is not misinterpreted when it is included
in output to another component. Other techniques exist as well
(see CWE-138 for more examples.)
Input validation can be applied to:
raw data - strings, numbers, parameters, file contents, etc.
metadata - information about the raw data, such as headers or size
Data can be simple or structured. Structured data
can be composed of many nested layers, composed of
combinations of metadata and raw data, with other simple or
structured data.
Many properties of raw data or metadata may need
to be validated upon entry into the code, such
as:
specified quantities such as size, length, frequency, price, rate, number of operations, time, etc.
implied or derived quantities, such as the actual size of a file instead of a specified size
indexes, offsets, or positions into more complex data structures
symbolic keys or other elements into hash tables, associative arrays, etc.
well-formedness, i.e. syntactic correctness - compliance with expected syntax
lexical token correctness - compliance with rules for what is treated as a token
specified or derived type - the actual type of the input (or what the input appears to be)
consistency - between individual data elements, between raw data and metadata, between references, etc.
conformance to domain-specific rules, e.g. business logic
equivalence - ensuring that equivalent inputs are treated the same
authenticity, ownership, or other attestations about the input, e.g. a cryptographic signature to prove the source of the data
Implied or derived properties of data must often
be calculated or inferred by the code itself. Errors in
deriving properties may be considered a contributing factor
to improper input validation.
Note that "input validation" has very different
meanings to different people, or within different
classification schemes. Caution must be used when
referencing this CWE entry or mapping to it. For example,
some weaknesses might involve inadvertently giving control
to an attacker over an input when they should not be able
to provide an input at all, but sometimes this is referred
to as input validation.
Finally, it is important to emphasize that the
distinctions between input validation and output escaping
are often blurred, and developers must be careful to
understand the difference, including how input validation
is not always sufficient to prevent vulnerabilities,
especially when less stringent data types must be
supported, such as free-form text. Consider a SQL injection
scenario in which a person's last name is inserted into a
query. The name "O'Reilly" would likely pass the validation
step since it is a common last name in the English
language. However, this valid name cannot be directly
inserted into the database because it contains the "'"
apostrophe character, which would need to be escaped or
otherwise transformed. In this case, removing the
apostrophe might reduce the risk of SQL injection, but it
would produce incorrect behavior because the wrong name
would be recorded.
| https://cwe.mitre.org/data/definitions/20.html | 0 | Sara Golemon | 2017-03-07 11:27:46-08:00 | Detect invalid port in xp_socket parse ip address
For historical reasons, fsockopen() accepts the port and hostname
separately: fsockopen('127.0.0.1', 80)
However, with the introdcution of stream transports in PHP 4.3,
it became possible to include the port in the hostname specifier:
fsockopen('127.0.0.1:80')
Or more formally: fsockopen('tcp://127.0.0.1:80')
Confusing results when these two forms are combined, however.
fsockopen('127.0.0.1:80', 443) results in fsockopen() attempting
to connect to '127.0.0.1:80:443' which any reasonable stack would
consider invalid.
Unfortunately, PHP parses the address looking for the first colon
(with special handling for IPv6, don't worry) and calls atoi()
from there. atoi() in turn, simply stops parsing at the first
non-numeric character and returns the value so far.
The end result is that the explicitly supplied port is treated
as ignored garbage, rather than producing an error.
This diff replaces atoi() with strtol() and inspects the
stop character. If additional "garbage" of any kind is found,
it fails and returns an error. | bab0b99f376dac9170ac81382a5ed526938d595a | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | parse_ip_address_ex | parse_ip_address_ex( const char * str , size_t str_len , int * portno , int get_err , zend_string ** err) | ['str', 'str_len', 'portno', 'get_err', 'err'] | static inline char *parse_ip_address_ex(const char *str, size_t str_len, int *portno, int get_err, zend_string **err)
{
char *colon;
char *host = NULL;
#ifdef HAVE_IPV6
char *p;
if (*(str) == '[' && str_len > 1) {
/* IPV6 notation to specify raw address with port (i.e. [fe80::1]:80) */
p = memchr(str + 1, ']', str_len - 2);
if (!p || *(p + 1) != ':') {
if (get_err) {
*err = strpprintf(0, "Failed to parse IPv6 address \"%s\"", str);
}
return NULL;
}
*portno = atoi(p + 2);
return estrndup(str + 1, p - str - 1);
}
#endif
if (str_len) {
colon = memchr(str, ':', str_len - 1);
} else {
colon = NULL;
}
if (colon) {
*portno = atoi(colon + 1);
host = estrndup(str, colon - str);
} else {
if (get_err) {
*err = strpprintf(0, "Failed to parse address \"%s\"", str);
}
return NULL;
}
return host;
} | 208 | True | 1 |
CVE-2017-7272 | False | False | False | True | AV:N/AC:M/Au:N/C:P/I:P/A:N | NETWORK | MEDIUM | NONE | PARTIAL | PARTIAL | NONE | 5.8 | CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N | NETWORK | LOW | NONE | REQUIRED | CHANGED | NONE | HIGH | NONE | 7.4 | HIGH | 2.8 | 4.0 | nan | [{'url': 'https://github.com/php/php-src/commit/bab0b99f376dac9170ac81382a5ed526938d595a', 'name': 'https://github.com/php/php-src/commit/bab0b99f376dac9170ac81382a5ed526938d595a', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=74216', 'name': 'https://bugs.php.net/bug.php?id=74216', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Vendor Advisory']}, {'url': 'http://www.securityfocus.com/bid/97178', 'name': '97178', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://www.sec-consult.com/fxdata/seccons/prod/temedia/advisories_txt/20170403-0_PHP_Misbehavior_of_fsockopen_function_v10.txt', 'name': 'https://www.sec-consult.com/fxdata/seccons/prod/temedia/advisories_txt/20170403-0_PHP_Misbehavior_of_fsockopen_function_v10.txt', 'refsource': 'MISC', 'tags': []}, {'url': 'http://www.securitytracker.com/id/1038158', 'name': '1038158', 'refsource': 'SECTRACK', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://bugs.php.net/bug.php?id=75505', 'name': 'https://bugs.php.net/bug.php?id=75505', 'refsource': 'CONFIRM', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-918'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '7.1.3', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'PHP through 7.1.11 enables potential SSRF in applications that accept an fsockopen or pfsockopen hostname argument with an expectation that the port number is constrained. Because a :port syntax is recognized, fsockopen will use the port number that is specified in the hostname argument, instead of the port number in the second argument of the function.'}] | 2018-02-26T02:29Z | 2017-03-27T17:59Z | Server-Side Request Forgery (SSRF) | The web server receives a URL or similar request from an upstream component and retrieves the contents of this URL, but it does not sufficiently ensure that the request is being sent to the expected destination. | By providing URLs to unexpected hosts or ports, attackers can make it appear that the server is sending the request, possibly bypassing access controls such as firewalls that prevent the attackers from accessing the URLs directly. The server can be used as a proxy to conduct port scanning of hosts in internal networks, use other URLs such as that can access documents on the system (using file://), or use other protocols such as gopher:// or tftp://, which may provide greater control over the contents of requests.
| https://cwe.mitre.org/data/definitions/918.html | 0 | Sara Golemon | 2017-03-07 11:27:46-08:00 | Detect invalid port in xp_socket parse ip address
For historical reasons, fsockopen() accepts the port and hostname
separately: fsockopen('127.0.0.1', 80)
However, with the introdcution of stream transports in PHP 4.3,
it became possible to include the port in the hostname specifier:
fsockopen('127.0.0.1:80')
Or more formally: fsockopen('tcp://127.0.0.1:80')
Confusing results when these two forms are combined, however.
fsockopen('127.0.0.1:80', 443) results in fsockopen() attempting
to connect to '127.0.0.1:80:443' which any reasonable stack would
consider invalid.
Unfortunately, PHP parses the address looking for the first colon
(with special handling for IPv6, don't worry) and calls atoi()
from there. atoi() in turn, simply stops parsing at the first
non-numeric character and returns the value so far.
The end result is that the explicitly supplied port is treated
as ignored garbage, rather than producing an error.
This diff replaces atoi() with strtol() and inspects the
stop character. If additional "garbage" of any kind is found,
it fails and returns an error. | bab0b99f376dac9170ac81382a5ed526938d595a | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | parse_ip_address_ex | parse_ip_address_ex( const char * str , size_t str_len , int * portno , int get_err , zend_string ** err) | ['str', 'str_len', 'portno', 'get_err', 'err'] | static inline char *parse_ip_address_ex(const char *str, size_t str_len, int *portno, int get_err, zend_string **err)
{
char *colon;
char *host = NULL;
#ifdef HAVE_IPV6
char *p;
if (*(str) == '[' && str_len > 1) {
/* IPV6 notation to specify raw address with port (i.e. [fe80::1]:80) */
p = memchr(str + 1, ']', str_len - 2);
if (!p || *(p + 1) != ':') {
if (get_err) {
*err = strpprintf(0, "Failed to parse IPv6 address \"%s\"", str);
}
return NULL;
}
*portno = atoi(p + 2);
return estrndup(str + 1, p - str - 1);
}
#endif
if (str_len) {
colon = memchr(str, ':', str_len - 1);
} else {
colon = NULL;
}
if (colon) {
*portno = atoi(colon + 1);
host = estrndup(str, colon - str);
} else {
if (get_err) {
*err = strpprintf(0, "Failed to parse address \"%s\"", str);
}
return NULL;
}
return host;
} | 208 | True | 1 |
CVE-2017-11142 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:C | NETWORK | LOW | NONE | NONE | NONE | COMPLETE | 7.8 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | nan | [{'url': 'https://github.com/php/php-src/commit/a15bffd105ac28fd0dd9b596632dbf035238fda3', 'name': 'https://github.com/php/php-src/commit/a15bffd105ac28fd0dd9b596632dbf035238fda3', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/php/php-src/commit/0f8cf3b8497dc45c010c44ed9e96518e11e19fc3', 'name': 'https://github.com/php/php-src/commit/0f8cf3b8497dc45c010c44ed9e96518e11e19fc3', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73807', 'name': 'https://bugs.php.net/bug.php?id=73807', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://openwall.com/lists/oss-security/2017/07/10/6', 'name': 'http://openwall.com/lists/oss-security/2017/07/10/6', 'refsource': 'CONFIRM', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/99601', 'name': '99601', 'refsource': 'BID', 'tags': []}, {'url': 'https://www.tenable.com/security/tns-2017-12', 'name': 'https://www.tenable.com/security/tns-2017-12', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://www.debian.org/security/2018/dsa-4081', 'name': 'DSA-4081', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-400'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.16:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.30', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In PHP before 5.6.31, 7.x before 7.0.17, and 7.1.x before 7.1.3, remote attackers could cause a CPU consumption denial of service attack by injecting long form variables, related to main/php_variables.c.'}] | 2018-01-14T02:29Z | 2017-07-10T14:29Z | Uncontrolled Resource Consumption | The software does not properly control the allocation and maintenance of a limited resource, thereby enabling an actor to influence the amount of resources consumed, eventually leading to the exhaustion of available resources. |
Limited resources include memory, file system storage, database connection pool entries, and CPU. If an attacker can trigger the allocation of these limited resources, but the number or size of the resources is not controlled, then the attacker could cause a denial of service that consumes all available resources. This would prevent valid users from accessing the software, and it could potentially have an impact on the surrounding environment. For example, a memory exhaustion attack against an application could slow down the application as well as its host operating system.
There are at least three distinct scenarios which can commonly lead to resource exhaustion:
Lack of throttling for the number of allocated resources
Losing all references to a resource before reaching the shutdown stage
Not closing/returning a resource after processing
Resource exhaustion problems are often result due to an incorrect implementation of the following situations:
Error conditions and other exceptional circumstances.
Confusion over which part of the program is responsible for releasing the resource.
| https://cwe.mitre.org/data/definitions/400.html | 0 | Nikita Popov | 2017-02-02 16:04:02+01:00 | Fix bug #73807 | 0f8cf3b8497dc45c010c44ed9e96518e11e19fc3 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | add_post_var | add_post_var( zval * arr , post_var_data_t * var , zend_bool eof TSRMLS_DC) | ['arr', 'var', 'TSRMLS_DC'] | static zend_bool add_post_var(zval *arr, post_var_data_t *var, zend_bool eof TSRMLS_DC)
{
char *ksep, *vsep, *val;
size_t klen, vlen;
/* FIXME: string-size_t */
unsigned int new_vlen;
if (var->ptr >= var->end) {
return 0;
}
vsep = memchr(var->ptr, '&', var->end - var->ptr);
if (!vsep) {
if (!eof) {
return 0;
} else {
vsep = var->end;
}
}
ksep = memchr(var->ptr, '=', vsep - var->ptr);
if (ksep) {
*ksep = '\0';
/* "foo=bar&" or "foo=&" */
klen = ksep - var->ptr;
vlen = vsep - ++ksep;
} else {
ksep = "";
/* "foo&" */
klen = vsep - var->ptr;
vlen = 0;
}
php_url_decode(var->ptr, klen);
val = estrndup(ksep, vlen);
if (vlen) {
vlen = php_url_decode(val, vlen);
}
if (sapi_module.input_filter(PARSE_POST, var->ptr, &val, vlen, &new_vlen TSRMLS_CC)) {
php_register_variable_safe(var->ptr, val, new_vlen, arr TSRMLS_CC);
}
efree(val);
var->ptr = vsep + (vsep != var->end);
return 1;
} | 250 | True | 1 |
CVE-2017-11142 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:C | NETWORK | LOW | NONE | NONE | NONE | COMPLETE | 7.8 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | nan | [{'url': 'https://github.com/php/php-src/commit/a15bffd105ac28fd0dd9b596632dbf035238fda3', 'name': 'https://github.com/php/php-src/commit/a15bffd105ac28fd0dd9b596632dbf035238fda3', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/php/php-src/commit/0f8cf3b8497dc45c010c44ed9e96518e11e19fc3', 'name': 'https://github.com/php/php-src/commit/0f8cf3b8497dc45c010c44ed9e96518e11e19fc3', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=73807', 'name': 'https://bugs.php.net/bug.php?id=73807', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://openwall.com/lists/oss-security/2017/07/10/6', 'name': 'http://openwall.com/lists/oss-security/2017/07/10/6', 'refsource': 'CONFIRM', 'tags': ['Mailing List']}, {'url': 'http://www.securityfocus.com/bid/99601', 'name': '99601', 'refsource': 'BID', 'tags': []}, {'url': 'https://www.tenable.com/security/tns-2017-12', 'name': 'https://www.tenable.com/security/tns-2017-12', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://www.debian.org/security/2018/dsa-4081', 'name': 'DSA-4081', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-400'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.16:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.30', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In PHP before 5.6.31, 7.x before 7.0.17, and 7.1.x before 7.1.3, remote attackers could cause a CPU consumption denial of service attack by injecting long form variables, related to main/php_variables.c.'}] | 2018-01-14T02:29Z | 2017-07-10T14:29Z | Uncontrolled Resource Consumption | The software does not properly control the allocation and maintenance of a limited resource, thereby enabling an actor to influence the amount of resources consumed, eventually leading to the exhaustion of available resources. |
Limited resources include memory, file system storage, database connection pool entries, and CPU. If an attacker can trigger the allocation of these limited resources, but the number or size of the resources is not controlled, then the attacker could cause a denial of service that consumes all available resources. This would prevent valid users from accessing the software, and it could potentially have an impact on the surrounding environment. For example, a memory exhaustion attack against an application could slow down the application as well as its host operating system.
There are at least three distinct scenarios which can commonly lead to resource exhaustion:
Lack of throttling for the number of allocated resources
Losing all references to a resource before reaching the shutdown stage
Not closing/returning a resource after processing
Resource exhaustion problems are often result due to an incorrect implementation of the following situations:
Error conditions and other exceptional circumstances.
Confusion over which part of the program is responsible for releasing the resource.
| https://cwe.mitre.org/data/definitions/400.html | 0 | Nikita Popov | 2017-02-02 16:04:02+01:00 | Fix bug #73807 | 0f8cf3b8497dc45c010c44ed9e96518e11e19fc3 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | add_post_vars | add_post_vars( zval * arr , post_var_data_t * vars , zend_bool eof TSRMLS_DC) | ['arr', 'vars', 'TSRMLS_DC'] | static inline int add_post_vars(zval *arr, post_var_data_t *vars, zend_bool eof TSRMLS_DC)
{
uint64_t max_vars = PG(max_input_vars);
vars->ptr = vars->str.c;
vars->end = vars->str.c + vars->str.len;
while (add_post_var(arr, vars, eof TSRMLS_CC)) {
if (++vars->cnt > max_vars) {
php_error_docref(NULL TSRMLS_CC, E_WARNING,
"Input variables exceeded %" PRIu64 ". "
"To increase the limit change max_input_vars in php.ini.",
max_vars);
return FAILURE;
}
}
if (!eof) {
memmove(vars->str.c, vars->ptr, vars->str.len = vars->end - vars->ptr);
}
return SUCCESS;
} | 130 | True | 1 |
CVE-2017-12932 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | True | [{'url': 'https://github.com/php/php-src/commit/1a23ebc1fff59bf480ca92963b36eba5c1b904c4', 'name': 'https://github.com/php/php-src/commit/1a23ebc1fff59bf480ca92963b36eba5c1b904c4', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=74103', 'name': 'https://bugs.php.net/bug.php?id=74103', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.securityfocus.com/bid/100427', 'name': '100427', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://security.gentoo.org/glsa/201709-21', 'name': 'GLSA-201709-21', 'refsource': 'GENTOO', 'tags': []}, {'url': 'https://www.debian.org/security/2018/dsa-4080', 'name': 'DSA-4080', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2519', 'name': 'RHSA-2019:2519', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-416'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.19:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.20:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.17:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.18:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.22:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.16:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.21:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'ext/standard/var_unserializer.re in PHP 7.0.x through 7.0.22 and 7.1.x through 7.1.8 is prone to a heap use after free while unserializing untrusted data, related to improper use of the hash API for key deletion in a situation with an invalid array size. Exploitation of this issue can have an unspecified impact on the integrity of PHP.'}] | 2018-05-04T01:29Z | 2017-08-18T03:29Z | Use After Free | Referencing memory after it has been freed can cause a program to crash, use unexpected values, or execute code. |
The use of previously-freed memory can have any number of adverse consequences, ranging from the corruption of valid data to the execution of arbitrary code, depending on the instantiation and timing of the flaw. The simplest way data corruption may occur involves the system's reuse of the freed memory. Use-after-free errors have two common and sometimes overlapping causes:
Error conditions and other exceptional circumstances.
Confusion over which part of the program is responsible for freeing the memory.
In this scenario, the memory in question is allocated to another pointer validly at some point after it has been freed. The original pointer to the freed memory is used again and points to somewhere within the new allocation. As the data is changed, it corrupts the validly used memory; this induces undefined behavior in the process.
If the newly allocated data chances to hold a class, in C++ for example, various function pointers may be scattered within the heap data. If one of these function pointers is overwritten with an address to valid shellcode, execution of arbitrary code can be achieved.
| https://cwe.mitre.org/data/definitions/416.html | 0 | Nikita Popov | 2017-08-12 13:00:39+02:00 | Fixed bug #74103 and bug #75054
Directly fail unserialization when trying to acquire an r/R
reference to an UNDEF HT slot. Previously this left an UNDEF and
later deleted the index/key from the HT.
What actually caused the issue here is a combination of two
factors: First, the key deletion was performed using the hash API,
rather than the symtable API, such that the element was not actually
removed if it used an integral string key. Second, a subsequent
deletion operation, while collecting trailing UNDEF ranges, would
mark the element as available for reuse (leaving a corrupted HT
state with nNumOfElemnts > nNumUsed).
Fix this by failing early and dropping the deletion code. | 1a23ebc1fff59bf480ca92963b36eba5c1b904c4 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_var_unserialize_internal | php_var_unserialize_internal( UNSERIALIZE_PARAMETER) | ['UNSERIALIZE_PARAMETER'] | static int php_var_unserialize_internal(UNSERIALIZE_PARAMETER)
{
const unsigned char *cursor, *limit, *marker, *start;
zval *rval_ref;
limit = max;
cursor = *p;
if (YYCURSOR >= YYLIMIT) {
return 0;
}
if (var_hash && (*p)[0] != 'R') {
var_push(var_hash, rval);
}
start = cursor;
#line 585 "ext/standard/var_unserializer.c"
{
YYCTYPE yych;
static const unsigned char yybm[] = {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
128, 128, 128, 128, 128, 128, 128, 128,
128, 128, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
};
if ((YYLIMIT - YYCURSOR) < 7) YYFILL(7);
yych = *YYCURSOR;
switch (yych) {
case 'C':
case 'O': goto yy13;
case 'N': goto yy5;
case 'R': goto yy2;
case 'S': goto yy10;
case 'a': goto yy11;
case 'b': goto yy6;
case 'd': goto yy8;
case 'i': goto yy7;
case 'o': goto yy12;
case 'r': goto yy4;
case 's': goto yy9;
case '}': goto yy14;
default: goto yy16;
}
yy2:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy95;
yy3:
#line 962 "ext/standard/var_unserializer.re"
{ return 0; }
#line 646 "ext/standard/var_unserializer.c"
yy4:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy89;
goto yy3;
yy5:
yych = *++YYCURSOR;
if (yych == ';') goto yy87;
goto yy3;
yy6:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy83;
goto yy3;
yy7:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy77;
goto yy3;
yy8:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy53;
goto yy3;
yy9:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy46;
goto yy3;
yy10:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy39;
goto yy3;
yy11:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy32;
goto yy3;
yy12:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy25;
goto yy3;
yy13:
yych = *(YYMARKER = ++YYCURSOR);
if (yych == ':') goto yy17;
goto yy3;
yy14:
++YYCURSOR;
#line 956 "ext/standard/var_unserializer.re"
{
/* this is the case where we have less data than planned */
php_error_docref(NULL, E_NOTICE, "Unexpected end of serialized data");
return 0; /* not sure if it should be 0 or 1 here? */
}
#line 695 "ext/standard/var_unserializer.c"
yy16:
yych = *++YYCURSOR;
goto yy3;
yy17:
yych = *++YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
if (yych == '+') goto yy19;
yy18:
YYCURSOR = YYMARKER;
goto yy3;
yy19:
yych = *++YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
goto yy18;
yy20:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yybm[0+yych] & 128) {
goto yy20;
}
if (yych <= '/') goto yy18;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 804 "ext/standard/var_unserializer.re"
{
size_t len, len2, len3, maxlen;
zend_long elements;
char *str;
zend_string *class_name;
zend_class_entry *ce;
int incomplete_class = 0;
int custom_object = 0;
zval user_func;
zval retval;
zval args[1];
if (!var_hash) return 0;
if (*start == 'C') {
custom_object = 1;
}
len2 = len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len || len == 0) {
*p = start + 2;
return 0;
}
str = (char*)YYCURSOR;
YYCURSOR += len;
if (*(YYCURSOR) != '"') {
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR+1) != ':') {
*p = YYCURSOR+1;
return 0;
}
len3 = strspn(str, "0123456789_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\177\200\201\202\203\204\205\206\207\210\211\212\213\214\215\216\217\220\221\222\223\224\225\226\227\230\231\232\233\234\235\236\237\240\241\242\243\244\245\246\247\250\251\252\253\254\255\256\257\260\261\262\263\264\265\266\267\270\271\272\273\274\275\276\277\300\301\302\303\304\305\306\307\310\311\312\313\314\315\316\317\320\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343\344\345\346\347\350\351\352\353\354\355\356\357\360\361\362\363\364\365\366\367\370\371\372\373\374\375\376\377\\");
if (len3 != len)
{
*p = YYCURSOR + len3 - len;
return 0;
}
class_name = zend_string_init(str, len, 0);
do {
if(!unserialize_allowed_class(class_name, classes)) {
incomplete_class = 1;
ce = PHP_IC_ENTRY;
break;
}
/* Try to find class directly */
BG(serialize_lock)++;
ce = zend_lookup_class(class_name);
if (ce) {
BG(serialize_lock)--;
if (EG(exception)) {
zend_string_release(class_name);
return 0;
}
break;
}
BG(serialize_lock)--;
if (EG(exception)) {
zend_string_release(class_name);
return 0;
}
/* Check for unserialize callback */
if ((PG(unserialize_callback_func) == NULL) || (PG(unserialize_callback_func)[0] == '\0')) {
incomplete_class = 1;
ce = PHP_IC_ENTRY;
break;
}
/* Call unserialize callback */
ZVAL_STRING(&user_func, PG(unserialize_callback_func));
ZVAL_STR_COPY(&args[0], class_name);
BG(serialize_lock)++;
if (call_user_function_ex(CG(function_table), NULL, &user_func, &retval, 1, args, 0, NULL) != SUCCESS) {
BG(serialize_lock)--;
if (EG(exception)) {
zend_string_release(class_name);
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&args[0]);
return 0;
}
php_error_docref(NULL, E_WARNING, "defined (%s) but not found", Z_STRVAL(user_func));
incomplete_class = 1;
ce = PHP_IC_ENTRY;
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&args[0]);
break;
}
BG(serialize_lock)--;
zval_ptr_dtor(&retval);
if (EG(exception)) {
zend_string_release(class_name);
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&args[0]);
return 0;
}
/* The callback function may have defined the class */
BG(serialize_lock)++;
if ((ce = zend_lookup_class(class_name)) == NULL) {
php_error_docref(NULL, E_WARNING, "Function %s() hasn't defined the class it was called for", Z_STRVAL(user_func));
incomplete_class = 1;
ce = PHP_IC_ENTRY;
}
BG(serialize_lock)--;
zval_ptr_dtor(&user_func);
zval_ptr_dtor(&args[0]);
break;
} while (1);
*p = YYCURSOR;
if (custom_object) {
int ret;
ret = object_custom(UNSERIALIZE_PASSTHRU, ce);
if (ret && incomplete_class) {
php_store_class_name(rval, ZSTR_VAL(class_name), len2);
}
zend_string_release(class_name);
return ret;
}
elements = object_common1(UNSERIALIZE_PASSTHRU, ce);
if (elements < 0) {
zend_string_release(class_name);
return 0;
}
if (incomplete_class) {
php_store_class_name(rval, ZSTR_VAL(class_name), len2);
}
zend_string_release(class_name);
return object_common2(UNSERIALIZE_PASSTHRU, elements);
}
#line 878 "ext/standard/var_unserializer.c"
yy25:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy26;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy27;
goto yy18;
}
yy26:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy27:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy27;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 793 "ext/standard/var_unserializer.re"
{
zend_long elements;
if (!var_hash) return 0;
elements = object_common1(UNSERIALIZE_PASSTHRU, ZEND_STANDARD_CLASS_DEF_PTR);
if (elements < 0 || elements >= HT_MAX_SIZE) {
return 0;
}
return object_common2(UNSERIALIZE_PASSTHRU, elements);
}
#line 914 "ext/standard/var_unserializer.c"
yy32:
yych = *++YYCURSOR;
if (yych == '+') goto yy33;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy34;
goto yy18;
yy33:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy34:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy34;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '{') goto yy18;
++YYCURSOR;
#line 769 "ext/standard/var_unserializer.re"
{
zend_long elements = parse_iv(start + 2);
/* use iv() not uiv() in order to check data range */
*p = YYCURSOR;
if (!var_hash) return 0;
if (elements < 0 || elements >= HT_MAX_SIZE) {
return 0;
}
array_init_size(rval, elements);
if (elements) {
/* we can't convert from packed to hash during unserialization, because
reference to some zvals might be keept in var_hash (to support references) */
zend_hash_real_init(Z_ARRVAL_P(rval), 0);
}
if (!process_nested_data(UNSERIALIZE_PASSTHRU, Z_ARRVAL_P(rval), elements, 0)) {
return 0;
}
return finish_nested_data(UNSERIALIZE_PASSTHRU);
}
#line 959 "ext/standard/var_unserializer.c"
yy39:
yych = *++YYCURSOR;
if (yych == '+') goto yy40;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy41;
goto yy18;
yy40:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy41:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy41;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 735 "ext/standard/var_unserializer.re"
{
size_t len, maxlen;
zend_string *str;
len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len) {
*p = start + 2;
return 0;
}
if ((str = unserialize_str(&YYCURSOR, len, maxlen)) == NULL) {
return 0;
}
if (*(YYCURSOR) != '"') {
zend_string_free(str);
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR + 1) != ';') {
efree(str);
*p = YYCURSOR + 1;
return 0;
}
YYCURSOR += 2;
*p = YYCURSOR;
ZVAL_STR(rval, str);
return 1;
}
#line 1014 "ext/standard/var_unserializer.c"
yy46:
yych = *++YYCURSOR;
if (yych == '+') goto yy47;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy48;
goto yy18;
yy47:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy48:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy48;
if (yych >= ';') goto yy18;
yych = *++YYCURSOR;
if (yych != '"') goto yy18;
++YYCURSOR;
#line 703 "ext/standard/var_unserializer.re"
{
size_t len, maxlen;
char *str;
len = parse_uiv(start + 2);
maxlen = max - YYCURSOR;
if (maxlen < len) {
*p = start + 2;
return 0;
}
str = (char*)YYCURSOR;
YYCURSOR += len;
if (*(YYCURSOR) != '"') {
*p = YYCURSOR;
return 0;
}
if (*(YYCURSOR + 1) != ';') {
*p = YYCURSOR + 1;
return 0;
}
YYCURSOR += 2;
*p = YYCURSOR;
ZVAL_STRINGL(rval, str, len);
return 1;
}
#line 1067 "ext/standard/var_unserializer.c"
yy53:
yych = *++YYCURSOR;
if (yych <= '/') {
if (yych <= ',') {
if (yych == '+') goto yy57;
goto yy18;
} else {
if (yych <= '-') goto yy55;
if (yych <= '.') goto yy60;
goto yy18;
}
} else {
if (yych <= 'I') {
if (yych <= '9') goto yy58;
if (yych <= 'H') goto yy18;
goto yy56;
} else {
if (yych != 'N') goto yy18;
}
}
yych = *++YYCURSOR;
if (yych == 'A') goto yy76;
goto yy18;
yy55:
yych = *++YYCURSOR;
if (yych <= '/') {
if (yych == '.') goto yy60;
goto yy18;
} else {
if (yych <= '9') goto yy58;
if (yych != 'I') goto yy18;
}
yy56:
yych = *++YYCURSOR;
if (yych == 'N') goto yy72;
goto yy18;
yy57:
yych = *++YYCURSOR;
if (yych == '.') goto yy60;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy58:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ':') {
if (yych <= '.') {
if (yych <= '-') goto yy18;
goto yy70;
} else {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy58;
goto yy18;
}
} else {
if (yych <= 'E') {
if (yych <= ';') goto yy63;
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy60:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy61:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ';') {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy61;
if (yych <= ':') goto yy18;
} else {
if (yych <= 'E') {
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy63:
++YYCURSOR;
#line 694 "ext/standard/var_unserializer.re"
{
#if SIZEOF_ZEND_LONG == 4
use_double:
#endif
*p = YYCURSOR;
ZVAL_DOUBLE(rval, zend_strtod((const char *)start + 2, NULL));
return 1;
}
#line 1164 "ext/standard/var_unserializer.c"
yy65:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy66;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
goto yy18;
}
yy66:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych == '+') goto yy69;
goto yy18;
} else {
if (yych <= '-') goto yy69;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
}
yy67:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
if (yych == ';') goto yy63;
goto yy18;
yy69:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy67;
goto yy18;
yy70:
++YYCURSOR;
if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if (yych <= ';') {
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy70;
if (yych <= ':') goto yy18;
goto yy63;
} else {
if (yych <= 'E') {
if (yych <= 'D') goto yy18;
goto yy65;
} else {
if (yych == 'e') goto yy65;
goto yy18;
}
}
yy72:
yych = *++YYCURSOR;
if (yych != 'F') goto yy18;
yy73:
yych = *++YYCURSOR;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 678 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
if (!strncmp((char*)start + 2, "NAN", 3)) {
ZVAL_DOUBLE(rval, php_get_nan());
} else if (!strncmp((char*)start + 2, "INF", 3)) {
ZVAL_DOUBLE(rval, php_get_inf());
} else if (!strncmp((char*)start + 2, "-INF", 4)) {
ZVAL_DOUBLE(rval, -php_get_inf());
} else {
ZVAL_NULL(rval);
}
return 1;
}
#line 1239 "ext/standard/var_unserializer.c"
yy76:
yych = *++YYCURSOR;
if (yych == 'N') goto yy73;
goto yy18;
yy77:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy78;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy79;
goto yy18;
}
yy78:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy79:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy79;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 652 "ext/standard/var_unserializer.re"
{
#if SIZEOF_ZEND_LONG == 4
int digits = YYCURSOR - start - 3;
if (start[2] == '-' || start[2] == '+') {
digits--;
}
/* Use double for large zend_long values that were serialized on a 64-bit system */
if (digits >= MAX_LENGTH_OF_LONG - 1) {
if (digits == MAX_LENGTH_OF_LONG - 1) {
int cmp = strncmp((char*)YYCURSOR - MAX_LENGTH_OF_LONG, long_min_digits, MAX_LENGTH_OF_LONG - 1);
if (!(cmp < 0 || (cmp == 0 && start[2] == '-'))) {
goto use_double;
}
} else {
goto use_double;
}
}
#endif
*p = YYCURSOR;
ZVAL_LONG(rval, parse_iv(start + 2));
return 1;
}
#line 1292 "ext/standard/var_unserializer.c"
yy83:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= '2') goto yy18;
yych = *++YYCURSOR;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 646 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
ZVAL_BOOL(rval, parse_iv(start + 2));
return 1;
}
#line 1306 "ext/standard/var_unserializer.c"
yy87:
++YYCURSOR;
#line 640 "ext/standard/var_unserializer.re"
{
*p = YYCURSOR;
ZVAL_NULL(rval);
return 1;
}
#line 1315 "ext/standard/var_unserializer.c"
yy89:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy90;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy91;
goto yy18;
}
yy90:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy91:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy91;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 615 "ext/standard/var_unserializer.re"
{
zend_long id;
*p = YYCURSOR;
if (!var_hash) return 0;
id = parse_iv(start + 2) - 1;
if (id == -1 || (rval_ref = var_access(var_hash, id)) == NULL) {
return 0;
}
if (rval_ref == rval) {
return 0;
}
if (Z_ISUNDEF_P(rval_ref) || (Z_ISREF_P(rval_ref) && Z_ISUNDEF_P(Z_REFVAL_P(rval_ref)))) {
ZVAL_UNDEF(rval);
return 1;
}
ZVAL_COPY(rval, rval_ref);
return 1;
}
#line 1363 "ext/standard/var_unserializer.c"
yy95:
yych = *++YYCURSOR;
if (yych <= ',') {
if (yych != '+') goto yy18;
} else {
if (yych <= '-') goto yy96;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy97;
goto yy18;
}
yy96:
yych = *++YYCURSOR;
if (yych <= '/') goto yy18;
if (yych >= ':') goto yy18;
yy97:
++YYCURSOR;
if (YYLIMIT <= YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if (yych <= '/') goto yy18;
if (yych <= '9') goto yy97;
if (yych != ';') goto yy18;
++YYCURSOR;
#line 589 "ext/standard/var_unserializer.re"
{
zend_long id;
*p = YYCURSOR;
if (!var_hash) return 0;
id = parse_iv(start + 2) - 1;
if (id == -1 || (rval_ref = var_access(var_hash, id)) == NULL) {
return 0;
}
zval_ptr_dtor(rval);
if (Z_ISUNDEF_P(rval_ref) || (Z_ISREF_P(rval_ref) && Z_ISUNDEF_P(Z_REFVAL_P(rval_ref)))) {
ZVAL_UNDEF(rval);
return 1;
}
if (Z_ISREF_P(rval_ref)) {
ZVAL_COPY(rval, rval_ref);
} else {
ZVAL_NEW_REF(rval_ref, rval_ref);
ZVAL_COPY(rval, rval_ref);
}
return 1;
}
#line 1412 "ext/standard/var_unserializer.c"
}
#line 964 "ext/standard/var_unserializer.re"
return 0;
} | 4606 | True | 1 |
CVE-2017-12932 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | True | [{'url': 'https://github.com/php/php-src/commit/1a23ebc1fff59bf480ca92963b36eba5c1b904c4', 'name': 'https://github.com/php/php-src/commit/1a23ebc1fff59bf480ca92963b36eba5c1b904c4', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=74103', 'name': 'https://bugs.php.net/bug.php?id=74103', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Vendor Advisory']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://www.securityfocus.com/bid/100427', 'name': '100427', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://security.gentoo.org/glsa/201709-21', 'name': 'GLSA-201709-21', 'refsource': 'GENTOO', 'tags': []}, {'url': 'https://www.debian.org/security/2018/dsa-4080', 'name': 'DSA-4080', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'name': 'https://security.netapp.com/advisory/ntap-20180112-0001/', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2018:1296', 'name': 'RHSA-2018:1296', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2519', 'name': 'RHSA-2019:2519', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-416'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.19:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.20:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.17:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.18:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.22:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.16:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.1.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:7.0.21:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'ext/standard/var_unserializer.re in PHP 7.0.x through 7.0.22 and 7.1.x through 7.1.8 is prone to a heap use after free while unserializing untrusted data, related to improper use of the hash API for key deletion in a situation with an invalid array size. Exploitation of this issue can have an unspecified impact on the integrity of PHP.'}] | 2018-05-04T01:29Z | 2017-08-18T03:29Z | Use After Free | Referencing memory after it has been freed can cause a program to crash, use unexpected values, or execute code. |
The use of previously-freed memory can have any number of adverse consequences, ranging from the corruption of valid data to the execution of arbitrary code, depending on the instantiation and timing of the flaw. The simplest way data corruption may occur involves the system's reuse of the freed memory. Use-after-free errors have two common and sometimes overlapping causes:
Error conditions and other exceptional circumstances.
Confusion over which part of the program is responsible for freeing the memory.
In this scenario, the memory in question is allocated to another pointer validly at some point after it has been freed. The original pointer to the freed memory is used again and points to somewhere within the new allocation. As the data is changed, it corrupts the validly used memory; this induces undefined behavior in the process.
If the newly allocated data chances to hold a class, in C++ for example, various function pointers may be scattered within the heap data. If one of these function pointers is overwritten with an address to valid shellcode, execution of arbitrary code can be achieved.
| https://cwe.mitre.org/data/definitions/416.html | 0 | Nikita Popov | 2017-08-12 13:00:39+02:00 | Fixed bug #74103 and bug #75054
Directly fail unserialization when trying to acquire an r/R
reference to an UNDEF HT slot. Previously this left an UNDEF and
later deleted the index/key from the HT.
What actually caused the issue here is a combination of two
factors: First, the key deletion was performed using the hash API,
rather than the symtable API, such that the element was not actually
removed if it used an integral string key. Second, a subsequent
deletion operation, while collecting trailing UNDEF ranges, would
mark the element as available for reuse (leaving a corrupted HT
state with nNumOfElemnts > nNumUsed).
Fix this by failing early and dropping the deletion code. | 1a23ebc1fff59bf480ca92963b36eba5c1b904c4 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | process_nested_data | process_nested_data( UNSERIALIZE_PARAMETER , HashTable * ht , zend_long elements , int objprops) | ['UNSERIALIZE_PARAMETER', 'ht', 'elements', 'objprops'] | static zend_always_inline int process_nested_data(UNSERIALIZE_PARAMETER, HashTable *ht, zend_long elements, int objprops)
{
while (elements-- > 0) {
zval key, *data, d, *old_data;
zend_ulong idx;
ZVAL_UNDEF(&key);
if (!php_var_unserialize_internal(&key, p, max, NULL, classes)) {
zval_dtor(&key);
return 0;
}
data = NULL;
ZVAL_UNDEF(&d);
if (!objprops) {
if (Z_TYPE(key) == IS_LONG) {
idx = Z_LVAL(key);
numeric_key:
if (UNEXPECTED((old_data = zend_hash_index_find(ht, idx)) != NULL)) {
//??? update hash
var_push_dtor(var_hash, old_data);
data = zend_hash_index_update(ht, idx, &d);
} else {
data = zend_hash_index_add_new(ht, idx, &d);
}
} else if (Z_TYPE(key) == IS_STRING) {
if (UNEXPECTED(ZEND_HANDLE_NUMERIC(Z_STR(key), idx))) {
goto numeric_key;
}
if (UNEXPECTED((old_data = zend_hash_find(ht, Z_STR(key))) != NULL)) {
//??? update hash
var_push_dtor(var_hash, old_data);
data = zend_hash_update(ht, Z_STR(key), &d);
} else {
data = zend_hash_add_new(ht, Z_STR(key), &d);
}
} else {
zval_dtor(&key);
return 0;
}
} else {
if (EXPECTED(Z_TYPE(key) == IS_STRING)) {
string_key:
if ((old_data = zend_hash_find(ht, Z_STR(key))) != NULL) {
if (Z_TYPE_P(old_data) == IS_INDIRECT) {
old_data = Z_INDIRECT_P(old_data);
}
var_push_dtor(var_hash, old_data);
data = zend_hash_update_ind(ht, Z_STR(key), &d);
} else {
data = zend_hash_add_new(ht, Z_STR(key), &d);
}
} else if (Z_TYPE(key) == IS_LONG) {
/* object properties should include no integers */
convert_to_string(&key);
goto string_key;
} else {
zval_dtor(&key);
return 0;
}
}
if (!php_var_unserialize_internal(data, p, max, var_hash, classes)) {
zval_dtor(&key);
return 0;
}
if (UNEXPECTED(Z_ISUNDEF_P(data))) {
if (Z_TYPE(key) == IS_LONG) {
zend_hash_index_del(ht, Z_LVAL(key));
} else {
zend_hash_del_ind(ht, Z_STR(key));
}
} else {
var_push_dtor(var_hash, data);
}
zval_dtor(&key);
if (elements && *(*p-1) != ';' && *(*p-1) != '}') {
(*p)--;
return 0;
}
}
return 1;
} | 528 | True | 1 |
CVE-2018-7584 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | False | [{'url': 'https://github.com/php/php-src/commit/523f230c831d7b33353203fa34aee4e92ac12bba', 'name': 'https://github.com/php/php-src/commit/523f230c831d7b33353203fa34aee4e92ac12bba', 'refsource': 'CONFIRM', 'tags': ['Patch']}, {'url': 'https://bugs.php.net/bug.php?id=75981', 'name': 'https://bugs.php.net/bug.php?id=75981', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking']}, {'url': 'http://php.net/ChangeLog-7.php', 'name': 'http://php.net/ChangeLog-7.php', 'refsource': 'CONFIRM', 'tags': ['Release Notes']}, {'url': 'http://www.securityfocus.com/bid/103204', 'name': '103204', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://usn.ubuntu.com/3600-1/', 'name': 'USN-3600-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2018/03/msg00030.html', 'name': '[debian-lts-announce] 20180329 [SECURITY] [DLA 1326-1] php5 security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://www.tenable.com/security/tns-2018-03', 'name': 'https://www.tenable.com/security/tns-2018-03', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3600-2/', 'name': 'USN-3600-2', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://www.exploit-db.com/exploits/44846/', 'name': '44846', 'refsource': 'EXPLOIT-DB', 'tags': ['Exploit', 'Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2018/06/msg00005.html', 'name': '[debian-lts-announce] 20180626 [SECURITY] [DLA 1397-1] php5 security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://www.debian.org/security/2018/dsa-4240', 'name': 'DSA-4240', 'refsource': 'DEBIAN', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securitytracker.com/id/1041607', 'name': '1041607', 'refsource': 'SECTRACK', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://www.tenable.com/security/tns-2018-12', 'name': 'https://www.tenable.com/security/tns-2018-12', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2519', 'name': 'RHSA-2019:2519', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.6.33', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '7.0.0', 'versionEndExcluding': '7.0.28', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '7.1.0', 'versionEndIncluding': '7.1.14', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '7.2.0', 'versionEndIncluding': '7.2.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:12.04:*:*:*:esm:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:17.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:7.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In PHP through 5.6.33, 7.0.x before 7.0.28, 7.1.x through 7.1.14, and 7.2.x through 7.2.2, there is a stack-based buffer under-read while parsing an HTTP response in the php_stream_url_wrap_http_ex function in ext/standard/http_fopen_wrapper.c. This subsequently results in copying a large string.'}] | 2019-08-19T11:15Z | 2018-03-01T19:29Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Stanislav Malyshev | 2018-02-20 15:34:43-08:00 | Fix bug #75981: prevent reading beyond buffer start | 523f230c831d7b33353203fa34aee4e92ac12bba | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_stream_url_wrap_http_ex | php_stream_url_wrap_http_ex( php_stream_wrapper * wrapper , const char * path , const char * mode , int options , char ** opened_path , php_stream_context * context , int redirect_max , int flags STREAMS_DC TSRMLS_DC) | ['wrapper', 'path', 'mode', 'options', 'opened_path', 'context', 'redirect_max', 'TSRMLS_DC'] | php_stream *php_stream_url_wrap_http_ex(php_stream_wrapper *wrapper,
const char *path, const char *mode, int options, char **opened_path,
php_stream_context *context, int redirect_max, int flags STREAMS_DC TSRMLS_DC) /* {{{ */
{
php_stream *stream = NULL;
php_url *resource = NULL;
int use_ssl;
int use_proxy = 0;
char *scratch = NULL;
char *tmp = NULL;
char *ua_str = NULL;
zval **ua_zval = NULL, **tmpzval = NULL, *ssl_proxy_peer_name = NULL;
int scratch_len = 0;
int body = 0;
char location[HTTP_HEADER_BLOCK_SIZE];
zval *response_header = NULL;
int reqok = 0;
char *http_header_line = NULL;
char tmp_line[128];
size_t chunk_size = 0, file_size = 0;
int eol_detect = 0;
char *transport_string, *errstr = NULL;
int transport_len, have_header = 0, request_fulluri = 0, ignore_errors = 0;
char *protocol_version = NULL;
int protocol_version_len = 3; /* Default: "1.0" */
struct timeval timeout;
char *user_headers = NULL;
int header_init = ((flags & HTTP_WRAPPER_HEADER_INIT) != 0);
int redirected = ((flags & HTTP_WRAPPER_REDIRECTED) != 0);
int follow_location = 1;
php_stream_filter *transfer_encoding = NULL;
int response_code;
tmp_line[0] = '\0';
if (redirect_max < 1) {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "Redirection limit reached, aborting");
return NULL;
}
resource = php_url_parse(path);
if (resource == NULL) {
return NULL;
}
if (strncasecmp(resource->scheme, "http", sizeof("http")) && strncasecmp(resource->scheme, "https", sizeof("https"))) {
if (!context ||
php_stream_context_get_option(context, wrapper->wops->label, "proxy", &tmpzval) == FAILURE ||
Z_TYPE_PP(tmpzval) != IS_STRING ||
Z_STRLEN_PP(tmpzval) <= 0) {
php_url_free(resource);
return php_stream_open_wrapper_ex(path, mode, REPORT_ERRORS, NULL, context);
}
/* Called from a non-http wrapper with http proxying requested (i.e. ftp) */
request_fulluri = 1;
use_ssl = 0;
use_proxy = 1;
transport_len = Z_STRLEN_PP(tmpzval);
transport_string = estrndup(Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval));
} else {
/* Normal http request (possibly with proxy) */
if (strpbrk(mode, "awx+")) {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "HTTP wrapper does not support writeable connections");
php_url_free(resource);
return NULL;
}
use_ssl = resource->scheme && (strlen(resource->scheme) > 4) && resource->scheme[4] == 's';
/* choose default ports */
if (use_ssl && resource->port == 0)
resource->port = 443;
else if (resource->port == 0)
resource->port = 80;
if (context &&
php_stream_context_get_option(context, wrapper->wops->label, "proxy", &tmpzval) == SUCCESS &&
Z_TYPE_PP(tmpzval) == IS_STRING &&
Z_STRLEN_PP(tmpzval) > 0) {
use_proxy = 1;
transport_len = Z_STRLEN_PP(tmpzval);
transport_string = estrndup(Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval));
} else {
transport_len = spprintf(&transport_string, 0, "%s://%s:%d", use_ssl ? "ssl" : "tcp", resource->host, resource->port);
}
}
if (context && php_stream_context_get_option(context, wrapper->wops->label, "timeout", &tmpzval) == SUCCESS) {
SEPARATE_ZVAL(tmpzval);
convert_to_double_ex(tmpzval);
timeout.tv_sec = (time_t) Z_DVAL_PP(tmpzval);
timeout.tv_usec = (size_t) ((Z_DVAL_PP(tmpzval) - timeout.tv_sec) * 1000000);
} else {
timeout.tv_sec = FG(default_socket_timeout);
timeout.tv_usec = 0;
}
stream = php_stream_xport_create(transport_string, transport_len, options,
STREAM_XPORT_CLIENT | STREAM_XPORT_CONNECT,
NULL, &timeout, context, &errstr, NULL);
if (stream) {
php_stream_set_option(stream, PHP_STREAM_OPTION_READ_TIMEOUT, 0, &timeout);
}
if (errstr) {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "%s", errstr);
efree(errstr);
errstr = NULL;
}
efree(transport_string);
if (stream && use_proxy && use_ssl) {
smart_str header = {0};
/* Set peer_name or name verification will try to use the proxy server name */
if (!context || php_stream_context_get_option(context, "ssl", "peer_name", &tmpzval) == FAILURE) {
MAKE_STD_ZVAL(ssl_proxy_peer_name);
ZVAL_STRING(ssl_proxy_peer_name, resource->host, 1);
php_stream_context_set_option(stream->context, "ssl", "peer_name", ssl_proxy_peer_name);
}
smart_str_appendl(&header, "CONNECT ", sizeof("CONNECT ")-1);
smart_str_appends(&header, resource->host);
smart_str_appendc(&header, ':');
smart_str_append_unsigned(&header, resource->port);
smart_str_appendl(&header, " HTTP/1.0\r\n", sizeof(" HTTP/1.0\r\n")-1);
/* check if we have Proxy-Authorization header */
if (context && php_stream_context_get_option(context, "http", "header", &tmpzval) == SUCCESS) {
char *s, *p;
if (Z_TYPE_PP(tmpzval) == IS_ARRAY) {
HashPosition pos;
zval **tmpheader = NULL;
for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_PP(tmpzval), &pos);
SUCCESS == zend_hash_get_current_data_ex(Z_ARRVAL_PP(tmpzval), (void *)&tmpheader, &pos);
zend_hash_move_forward_ex(Z_ARRVAL_PP(tmpzval), &pos)) {
if (Z_TYPE_PP(tmpheader) == IS_STRING) {
s = Z_STRVAL_PP(tmpheader);
do {
while (*s == ' ' || *s == '\t') s++;
p = s;
while (*p != 0 && *p != ':' && *p != '\r' && *p !='\n') p++;
if (*p == ':') {
p++;
if (p - s == sizeof("Proxy-Authorization:") - 1 &&
zend_binary_strcasecmp(s, sizeof("Proxy-Authorization:") - 1,
"Proxy-Authorization:", sizeof("Proxy-Authorization:") - 1) == 0) {
while (*p != 0 && *p != '\r' && *p !='\n') p++;
smart_str_appendl(&header, s, p - s);
smart_str_appendl(&header, "\r\n", sizeof("\r\n")-1);
goto finish;
} else {
while (*p != 0 && *p != '\r' && *p !='\n') p++;
}
}
s = p;
while (*s == '\r' || *s == '\n') s++;
} while (*s != 0);
}
}
} else if (Z_TYPE_PP(tmpzval) == IS_STRING && Z_STRLEN_PP(tmpzval)) {
s = Z_STRVAL_PP(tmpzval);
do {
while (*s == ' ' || *s == '\t') s++;
p = s;
while (*p != 0 && *p != ':' && *p != '\r' && *p !='\n') p++;
if (*p == ':') {
p++;
if (p - s == sizeof("Proxy-Authorization:") - 1 &&
zend_binary_strcasecmp(s, sizeof("Proxy-Authorization:") - 1,
"Proxy-Authorization:", sizeof("Proxy-Authorization:") - 1) == 0) {
while (*p != 0 && *p != '\r' && *p !='\n') p++;
smart_str_appendl(&header, s, p - s);
smart_str_appendl(&header, "\r\n", sizeof("\r\n")-1);
goto finish;
} else {
while (*p != 0 && *p != '\r' && *p !='\n') p++;
}
}
s = p;
while (*s == '\r' || *s == '\n') s++;
} while (*s != 0);
}
}
finish:
smart_str_appendl(&header, "\r\n", sizeof("\r\n")-1);
if (php_stream_write(stream, header.c, header.len) != header.len) {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "Cannot connect to HTTPS server through proxy");
php_stream_close(stream);
stream = NULL;
}
smart_str_free(&header);
if (stream) {
char header_line[HTTP_HEADER_BLOCK_SIZE];
/* get response header */
while (php_stream_gets(stream, header_line, HTTP_HEADER_BLOCK_SIZE-1) != NULL) {
if (header_line[0] == '\n' ||
header_line[0] == '\r' ||
header_line[0] == '\0') {
break;
}
}
}
/* enable SSL transport layer */
if (stream) {
if (php_stream_xport_crypto_setup(stream, STREAM_CRYPTO_METHOD_SSLv23_CLIENT, NULL TSRMLS_CC) < 0 ||
php_stream_xport_crypto_enable(stream, 1 TSRMLS_CC) < 0) {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "Cannot connect to HTTPS server through proxy");
php_stream_close(stream);
stream = NULL;
}
}
}
if (stream == NULL)
goto out;
/* avoid buffering issues while reading header */
if (options & STREAM_WILL_CAST)
chunk_size = php_stream_set_chunk_size(stream, 1);
/* avoid problems with auto-detecting when reading the headers -> the headers
* are always in canonical \r\n format */
eol_detect = stream->flags & (PHP_STREAM_FLAG_DETECT_EOL | PHP_STREAM_FLAG_EOL_MAC);
stream->flags &= ~(PHP_STREAM_FLAG_DETECT_EOL | PHP_STREAM_FLAG_EOL_MAC);
php_stream_context_set(stream, context);
php_stream_notify_info(context, PHP_STREAM_NOTIFY_CONNECT, NULL, 0);
if (header_init && context && php_stream_context_get_option(context, "http", "max_redirects", &tmpzval) == SUCCESS) {
SEPARATE_ZVAL(tmpzval);
convert_to_long_ex(tmpzval);
redirect_max = Z_LVAL_PP(tmpzval);
}
if (context && php_stream_context_get_option(context, "http", "method", &tmpzval) == SUCCESS) {
if (Z_TYPE_PP(tmpzval) == IS_STRING && Z_STRLEN_PP(tmpzval) > 0) {
/* As per the RFC, automatically redirected requests MUST NOT use other methods than
* GET and HEAD unless it can be confirmed by the user */
if (!redirected
|| (Z_STRLEN_PP(tmpzval) == 3 && memcmp("GET", Z_STRVAL_PP(tmpzval), 3) == 0)
|| (Z_STRLEN_PP(tmpzval) == 4 && memcmp("HEAD",Z_STRVAL_PP(tmpzval), 4) == 0)
) {
scratch_len = strlen(path) + 29 + Z_STRLEN_PP(tmpzval);
scratch = emalloc(scratch_len);
strlcpy(scratch, Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval) + 1);
strncat(scratch, " ", 1);
}
}
}
if (context && php_stream_context_get_option(context, "http", "protocol_version", &tmpzval) == SUCCESS) {
SEPARATE_ZVAL(tmpzval);
convert_to_double_ex(tmpzval);
protocol_version_len = spprintf(&protocol_version, 0, "%.1F", Z_DVAL_PP(tmpzval));
}
if (!scratch) {
scratch_len = strlen(path) + 29 + protocol_version_len;
scratch = emalloc(scratch_len);
strncpy(scratch, "GET ", scratch_len);
}
/* Should we send the entire path in the request line, default to no. */
if (!request_fulluri &&
context &&
php_stream_context_get_option(context, "http", "request_fulluri", &tmpzval) == SUCCESS) {
zval ztmp = **tmpzval;
zval_copy_ctor(&ztmp);
convert_to_boolean(&ztmp);
request_fulluri = Z_BVAL(ztmp) ? 1 : 0;
zval_dtor(&ztmp);
}
if (request_fulluri) {
/* Ask for everything */
strcat(scratch, path);
} else {
/* Send the traditional /path/to/file?query_string */
/* file */
if (resource->path && *resource->path) {
strlcat(scratch, resource->path, scratch_len);
} else {
strlcat(scratch, "/", scratch_len);
}
/* query string */
if (resource->query) {
strlcat(scratch, "?", scratch_len);
strlcat(scratch, resource->query, scratch_len);
}
}
/* protocol version we are speaking */
if (protocol_version) {
strlcat(scratch, " HTTP/", scratch_len);
strlcat(scratch, protocol_version, scratch_len);
strlcat(scratch, "\r\n", scratch_len);
} else {
strlcat(scratch, " HTTP/1.0\r\n", scratch_len);
}
/* send it */
php_stream_write(stream, scratch, strlen(scratch));
if (context && php_stream_context_get_option(context, "http", "header", &tmpzval) == SUCCESS) {
tmp = NULL;
if (Z_TYPE_PP(tmpzval) == IS_ARRAY) {
HashPosition pos;
zval **tmpheader = NULL;
smart_str tmpstr = {0};
for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_PP(tmpzval), &pos);
SUCCESS == zend_hash_get_current_data_ex(Z_ARRVAL_PP(tmpzval), (void *)&tmpheader, &pos);
zend_hash_move_forward_ex(Z_ARRVAL_PP(tmpzval), &pos)
) {
if (Z_TYPE_PP(tmpheader) == IS_STRING) {
smart_str_appendl(&tmpstr, Z_STRVAL_PP(tmpheader), Z_STRLEN_PP(tmpheader));
smart_str_appendl(&tmpstr, "\r\n", sizeof("\r\n") - 1);
}
}
smart_str_0(&tmpstr);
/* Remove newlines and spaces from start and end. there's at least one extra \r\n at the end that needs to go. */
if (tmpstr.c) {
tmp = php_trim(tmpstr.c, strlen(tmpstr.c), NULL, 0, NULL, 3 TSRMLS_CC);
smart_str_free(&tmpstr);
}
}
if (Z_TYPE_PP(tmpzval) == IS_STRING && Z_STRLEN_PP(tmpzval)) {
/* Remove newlines and spaces from start and end php_trim will estrndup() */
tmp = php_trim(Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval), NULL, 0, NULL, 3 TSRMLS_CC);
}
if (tmp && strlen(tmp) > 0) {
char *s;
user_headers = estrdup(tmp);
/* Make lowercase for easy comparison against 'standard' headers */
php_strtolower(tmp, strlen(tmp));
if (!header_init) {
/* strip POST headers on redirect */
strip_header(user_headers, tmp, "content-length:");
strip_header(user_headers, tmp, "content-type:");
}
if ((s = strstr(tmp, "user-agent:")) &&
(s == tmp || *(s-1) == '\r' || *(s-1) == '\n' ||
*(s-1) == '\t' || *(s-1) == ' ')) {
have_header |= HTTP_HEADER_USER_AGENT;
}
if ((s = strstr(tmp, "host:")) &&
(s == tmp || *(s-1) == '\r' || *(s-1) == '\n' ||
*(s-1) == '\t' || *(s-1) == ' ')) {
have_header |= HTTP_HEADER_HOST;
}
if ((s = strstr(tmp, "from:")) &&
(s == tmp || *(s-1) == '\r' || *(s-1) == '\n' ||
*(s-1) == '\t' || *(s-1) == ' ')) {
have_header |= HTTP_HEADER_FROM;
}
if ((s = strstr(tmp, "authorization:")) &&
(s == tmp || *(s-1) == '\r' || *(s-1) == '\n' ||
*(s-1) == '\t' || *(s-1) == ' ')) {
have_header |= HTTP_HEADER_AUTH;
}
if ((s = strstr(tmp, "content-length:")) &&
(s == tmp || *(s-1) == '\r' || *(s-1) == '\n' ||
*(s-1) == '\t' || *(s-1) == ' ')) {
have_header |= HTTP_HEADER_CONTENT_LENGTH;
}
if ((s = strstr(tmp, "content-type:")) &&
(s == tmp || *(s-1) == '\r' || *(s-1) == '\n' ||
*(s-1) == '\t' || *(s-1) == ' ')) {
have_header |= HTTP_HEADER_TYPE;
}
if ((s = strstr(tmp, "connection:")) &&
(s == tmp || *(s-1) == '\r' || *(s-1) == '\n' ||
*(s-1) == '\t' || *(s-1) == ' ')) {
have_header |= HTTP_HEADER_CONNECTION;
}
/* remove Proxy-Authorization header */
if (use_proxy && use_ssl && (s = strstr(tmp, "proxy-authorization:")) &&
(s == tmp || *(s-1) == '\r' || *(s-1) == '\n' ||
*(s-1) == '\t' || *(s-1) == ' ')) {
char *p = s + sizeof("proxy-authorization:") - 1;
while (s > tmp && (*(s-1) == ' ' || *(s-1) == '\t')) s--;
while (*p != 0 && *p != '\r' && *p != '\n') p++;
while (*p == '\r' || *p == '\n') p++;
if (*p == 0) {
if (s == tmp) {
efree(user_headers);
user_headers = NULL;
} else {
while (s > tmp && (*(s-1) == '\r' || *(s-1) == '\n')) s--;
user_headers[s - tmp] = 0;
}
} else {
memmove(user_headers + (s - tmp), user_headers + (p - tmp), strlen(p) + 1);
}
}
}
if (tmp) {
efree(tmp);
}
}
/* auth header if it was specified */
if (((have_header & HTTP_HEADER_AUTH) == 0) && resource->user) {
/* decode the strings first */
php_url_decode(resource->user, strlen(resource->user));
/* scratch is large enough, since it was made large enough for the whole URL */
strcpy(scratch, resource->user);
strcat(scratch, ":");
/* Note: password is optional! */
if (resource->pass) {
php_url_decode(resource->pass, strlen(resource->pass));
strcat(scratch, resource->pass);
}
tmp = (char*)php_base64_encode((unsigned char*)scratch, strlen(scratch), NULL);
if (snprintf(scratch, scratch_len, "Authorization: Basic %s\r\n", tmp) > 0) {
php_stream_write(stream, scratch, strlen(scratch));
php_stream_notify_info(context, PHP_STREAM_NOTIFY_AUTH_REQUIRED, NULL, 0);
}
efree(tmp);
tmp = NULL;
}
/* if the user has configured who they are, send a From: line */
if (((have_header & HTTP_HEADER_FROM) == 0) && FG(from_address)) {
if (snprintf(scratch, scratch_len, "From: %s\r\n", FG(from_address)) > 0)
php_stream_write(stream, scratch, strlen(scratch));
}
/* Send Host: header so name-based virtual hosts work */
if ((have_header & HTTP_HEADER_HOST) == 0) {
if ((use_ssl && resource->port != 443 && resource->port != 0) ||
(!use_ssl && resource->port != 80 && resource->port != 0)) {
if (snprintf(scratch, scratch_len, "Host: %s:%i\r\n", resource->host, resource->port) > 0)
php_stream_write(stream, scratch, strlen(scratch));
} else {
if (snprintf(scratch, scratch_len, "Host: %s\r\n", resource->host) > 0) {
php_stream_write(stream, scratch, strlen(scratch));
}
}
}
/* Send a Connection: close header to avoid hanging when the server
* interprets the RFC literally and establishes a keep-alive connection,
* unless the user specifically requests something else by specifying a
* Connection header in the context options. Send that header even for
* HTTP/1.0 to avoid issues when the server respond with a HTTP/1.1
* keep-alive response, which is the preferred response type. */
if ((have_header & HTTP_HEADER_CONNECTION) == 0) {
php_stream_write_string(stream, "Connection: close\r\n");
}
if (context &&
php_stream_context_get_option(context, "http", "user_agent", &ua_zval) == SUCCESS &&
Z_TYPE_PP(ua_zval) == IS_STRING) {
ua_str = Z_STRVAL_PP(ua_zval);
} else if (FG(user_agent)) {
ua_str = FG(user_agent);
}
if (((have_header & HTTP_HEADER_USER_AGENT) == 0) && ua_str) {
#define _UA_HEADER "User-Agent: %s\r\n"
char *ua;
size_t ua_len;
ua_len = sizeof(_UA_HEADER) + strlen(ua_str);
/* ensure the header is only sent if user_agent is not blank */
if (ua_len > sizeof(_UA_HEADER)) {
ua = emalloc(ua_len + 1);
if ((ua_len = slprintf(ua, ua_len, _UA_HEADER, ua_str)) > 0) {
ua[ua_len] = 0;
php_stream_write(stream, ua, ua_len);
} else {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot construct User-agent header");
}
if (ua) {
efree(ua);
}
}
}
if (user_headers) {
/* A bit weird, but some servers require that Content-Length be sent prior to Content-Type for POST
* see bug #44603 for details. Since Content-Type maybe part of user's headers we need to do this check first.
*/
if (
header_init &&
context &&
!(have_header & HTTP_HEADER_CONTENT_LENGTH) &&
php_stream_context_get_option(context, "http", "content", &tmpzval) == SUCCESS &&
Z_TYPE_PP(tmpzval) == IS_STRING && Z_STRLEN_PP(tmpzval) > 0
) {
scratch_len = slprintf(scratch, scratch_len, "Content-Length: %d\r\n", Z_STRLEN_PP(tmpzval));
php_stream_write(stream, scratch, scratch_len);
have_header |= HTTP_HEADER_CONTENT_LENGTH;
}
php_stream_write(stream, user_headers, strlen(user_headers));
php_stream_write(stream, "\r\n", sizeof("\r\n")-1);
efree(user_headers);
}
/* Request content, such as for POST requests */
if (header_init && context &&
php_stream_context_get_option(context, "http", "content", &tmpzval) == SUCCESS &&
Z_TYPE_PP(tmpzval) == IS_STRING && Z_STRLEN_PP(tmpzval) > 0) {
if (!(have_header & HTTP_HEADER_CONTENT_LENGTH)) {
scratch_len = slprintf(scratch, scratch_len, "Content-Length: %d\r\n", Z_STRLEN_PP(tmpzval));
php_stream_write(stream, scratch, scratch_len);
}
if (!(have_header & HTTP_HEADER_TYPE)) {
php_stream_write(stream, "Content-Type: application/x-www-form-urlencoded\r\n",
sizeof("Content-Type: application/x-www-form-urlencoded\r\n") - 1);
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Content-type not specified assuming application/x-www-form-urlencoded");
}
php_stream_write(stream, "\r\n", sizeof("\r\n")-1);
php_stream_write(stream, Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval));
} else {
php_stream_write(stream, "\r\n", sizeof("\r\n")-1);
}
location[0] = '\0';
if (!EG(active_symbol_table)) {
zend_rebuild_symbol_table(TSRMLS_C);
}
if (header_init) {
zval *ztmp;
MAKE_STD_ZVAL(ztmp);
array_init(ztmp);
ZEND_SET_SYMBOL(EG(active_symbol_table), "http_response_header", ztmp);
}
{
zval **rh;
if(zend_hash_find(EG(active_symbol_table), "http_response_header", sizeof("http_response_header"), (void **) &rh) != SUCCESS || Z_TYPE_PP(rh) != IS_ARRAY) {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "HTTP request failed, http_response_header overwritten");
goto out;
}
response_header = *rh;
Z_ADDREF_P(response_header);
}
if (!php_stream_eof(stream)) {
size_t tmp_line_len;
/* get response header */
if (php_stream_get_line(stream, tmp_line, sizeof(tmp_line) - 1, &tmp_line_len) != NULL) {
zval *http_response;
if (tmp_line_len > 9) {
response_code = atoi(tmp_line + 9);
} else {
response_code = 0;
}
if (context && SUCCESS==php_stream_context_get_option(context, "http", "ignore_errors", &tmpzval)) {
ignore_errors = zend_is_true(*tmpzval);
}
/* when we request only the header, don't fail even on error codes */
if ((options & STREAM_ONLY_GET_HEADERS) || ignore_errors) {
reqok = 1;
}
/* status codes of 1xx are "informational", and will be followed by a real response
* e.g "100 Continue". RFC 7231 states that unexpected 1xx status MUST be parsed,
* and MAY be ignored. As such, we need to skip ahead to the "real" status*/
if (response_code >= 100 && response_code < 200) {
/* consume lines until we find a line starting 'HTTP/1' */
while (
!php_stream_eof(stream)
&& php_stream_get_line(stream, tmp_line, sizeof(tmp_line) - 1, &tmp_line_len) != NULL
&& ( tmp_line_len < sizeof("HTTP/1") - 1 || strncasecmp(tmp_line, "HTTP/1", sizeof("HTTP/1") - 1) )
);
if (tmp_line_len > 9) {
response_code = atoi(tmp_line + 9);
} else {
response_code = 0;
}
}
/* all status codes in the 2xx range are defined by the specification as successful;
* all status codes in the 3xx range are for redirection, and so also should never
* fail */
if (response_code >= 200 && response_code < 400) {
reqok = 1;
} else {
switch(response_code) {
case 403:
php_stream_notify_error(context, PHP_STREAM_NOTIFY_AUTH_RESULT,
tmp_line, response_code);
break;
default:
/* safety net in the event tmp_line == NULL */
if (!tmp_line_len) {
tmp_line[0] = '\0';
}
php_stream_notify_error(context, PHP_STREAM_NOTIFY_FAILURE,
tmp_line, response_code);
}
}
if (tmp_line[tmp_line_len - 1] == '\n') {
--tmp_line_len;
if (tmp_line[tmp_line_len - 1] == '\r') {
--tmp_line_len;
}
}
MAKE_STD_ZVAL(http_response);
ZVAL_STRINGL(http_response, tmp_line, tmp_line_len, 1);
zend_hash_next_index_insert(Z_ARRVAL_P(response_header), &http_response, sizeof(zval *), NULL);
}
} else {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "HTTP request failed, unexpected end of socket!");
goto out;
}
/* read past HTTP headers */
http_header_line = emalloc(HTTP_HEADER_BLOCK_SIZE);
while (!body && !php_stream_eof(stream)) {
size_t http_header_line_length;
if (php_stream_get_line(stream, http_header_line, HTTP_HEADER_BLOCK_SIZE, &http_header_line_length) && *http_header_line != '\n' && *http_header_line != '\r') {
char *e = http_header_line + http_header_line_length - 1;
if (*e != '\n') {
do { /* partial header */
if (php_stream_get_line(stream, http_header_line, HTTP_HEADER_BLOCK_SIZE, &http_header_line_length) == NULL) {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "Failed to read HTTP headers");
goto out;
}
e = http_header_line + http_header_line_length - 1;
} while (*e != '\n');
continue;
}
while (*e == '\n' || *e == '\r') {
e--;
}
http_header_line_length = e - http_header_line + 1;
http_header_line[http_header_line_length] = '\0';
if (!strncasecmp(http_header_line, "Location: ", 10)) {
if (context && php_stream_context_get_option(context, "http", "follow_location", &tmpzval) == SUCCESS) {
SEPARATE_ZVAL(tmpzval);
convert_to_long_ex(tmpzval);
follow_location = Z_LVAL_PP(tmpzval);
} else if (!(response_code >= 300 && response_code < 304 || 307 == response_code || 308 == response_code)) {
/* we shouldn't redirect automatically
if follow_location isn't set and response_code not in (300, 301, 302, 303 and 307)
see http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.3.1
RFC 7238 defines 308: http://tools.ietf.org/html/rfc7238 */
follow_location = 0;
}
strlcpy(location, http_header_line + 10, sizeof(location));
} else if (!strncasecmp(http_header_line, "Content-Type: ", 14)) {
php_stream_notify_info(context, PHP_STREAM_NOTIFY_MIME_TYPE_IS, http_header_line + 14, 0);
} else if (!strncasecmp(http_header_line, "Content-Length: ", 16)) {
file_size = atoi(http_header_line + 16);
php_stream_notify_file_size(context, file_size, http_header_line, 0);
} else if (!strncasecmp(http_header_line, "Transfer-Encoding: chunked", sizeof("Transfer-Encoding: chunked"))) {
/* create filter to decode response body */
if (!(options & STREAM_ONLY_GET_HEADERS)) {
long decode = 1;
if (context && php_stream_context_get_option(context, "http", "auto_decode", &tmpzval) == SUCCESS) {
SEPARATE_ZVAL(tmpzval);
convert_to_boolean(*tmpzval);
decode = Z_LVAL_PP(tmpzval);
}
if (decode) {
transfer_encoding = php_stream_filter_create("dechunk", NULL, php_stream_is_persistent(stream) TSRMLS_CC);
if (transfer_encoding) {
/* don't store transfer-encodeing header */
continue;
}
}
}
}
if (http_header_line[0] == '\0') {
body = 1;
} else {
zval *http_header;
MAKE_STD_ZVAL(http_header);
ZVAL_STRINGL(http_header, http_header_line, http_header_line_length, 1);
zend_hash_next_index_insert(Z_ARRVAL_P(response_header), &http_header, sizeof(zval *), NULL);
}
} else {
break;
}
}
if (!reqok || (location[0] != '\0' && follow_location)) {
if (!follow_location || (((options & STREAM_ONLY_GET_HEADERS) || ignore_errors) && redirect_max <= 1)) {
goto out;
}
if (location[0] != '\0')
php_stream_notify_info(context, PHP_STREAM_NOTIFY_REDIRECTED, location, 0);
php_stream_close(stream);
stream = NULL;
if (location[0] != '\0') {
char new_path[HTTP_HEADER_BLOCK_SIZE];
char loc_path[HTTP_HEADER_BLOCK_SIZE];
*new_path='\0';
if (strlen(location)<8 || (strncasecmp(location, "http://", sizeof("http://")-1) &&
strncasecmp(location, "https://", sizeof("https://")-1) &&
strncasecmp(location, "ftp://", sizeof("ftp://")-1) &&
strncasecmp(location, "ftps://", sizeof("ftps://")-1)))
{
if (*location != '/') {
if (*(location+1) != '\0' && resource->path) {
char *s = strrchr(resource->path, '/');
if (!s) {
s = resource->path;
if (!s[0]) {
efree(s);
s = resource->path = estrdup("/");
} else {
*s = '/';
}
}
s[1] = '\0';
if (resource->path && *(resource->path) == '/' && *(resource->path + 1) == '\0') {
snprintf(loc_path, sizeof(loc_path) - 1, "%s%s", resource->path, location);
} else {
snprintf(loc_path, sizeof(loc_path) - 1, "%s/%s", resource->path, location);
}
} else {
snprintf(loc_path, sizeof(loc_path) - 1, "/%s", location);
}
} else {
strlcpy(loc_path, location, sizeof(loc_path));
}
if ((use_ssl && resource->port != 443) || (!use_ssl && resource->port != 80)) {
snprintf(new_path, sizeof(new_path) - 1, "%s://%s:%d%s", resource->scheme, resource->host, resource->port, loc_path);
} else {
snprintf(new_path, sizeof(new_path) - 1, "%s://%s%s", resource->scheme, resource->host, loc_path);
}
} else {
strlcpy(new_path, location, sizeof(new_path));
}
php_url_free(resource);
/* check for invalid redirection URLs */
if ((resource = php_url_parse(new_path)) == NULL) {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "Invalid redirect URL! %s", new_path);
goto out;
}
#define CHECK_FOR_CNTRL_CHARS(val) { \
if (val) { \
unsigned char *s, *e; \
int l; \
l = php_url_decode(val, strlen(val)); \
s = (unsigned char*)val; e = s + l; \
while (s < e) { \
if (iscntrl(*s)) { \
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "Invalid redirect URL! %s", new_path); \
goto out; \
} \
s++; \
} \
} \
}
/* check for control characters in login, password & path */
if (strncasecmp(new_path, "http://", sizeof("http://") - 1) || strncasecmp(new_path, "https://", sizeof("https://") - 1)) {
CHECK_FOR_CNTRL_CHARS(resource->user)
CHECK_FOR_CNTRL_CHARS(resource->pass)
CHECK_FOR_CNTRL_CHARS(resource->path)
}
stream = php_stream_url_wrap_http_ex(wrapper, new_path, mode, options, opened_path, context, --redirect_max, HTTP_WRAPPER_REDIRECTED STREAMS_CC TSRMLS_CC);
} else {
php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "HTTP request failed! %s", tmp_line);
}
}
out:
if (protocol_version) {
efree(protocol_version);
}
if (http_header_line) {
efree(http_header_line);
}
if (scratch) {
efree(scratch);
}
if (resource) {
php_url_free(resource);
}
if (stream) {
if (header_init) {
stream->wrapperdata = response_header;
} else {
if(response_header) {
Z_DELREF_P(response_header);
}
}
php_stream_notify_progress_init(context, 0, file_size);
/* Restore original chunk size now that we're done with headers */
if (options & STREAM_WILL_CAST)
php_stream_set_chunk_size(stream, chunk_size);
/* restore the users auto-detect-line-endings setting */
stream->flags |= eol_detect;
/* as far as streams are concerned, we are now at the start of
* the stream */
stream->position = 0;
/* restore mode */
strlcpy(stream->mode, mode, sizeof(stream->mode));
if (transfer_encoding) {
php_stream_filter_append(&stream->readfilters, transfer_encoding);
}
} else {
if(response_header) {
Z_DELREF_P(response_header);
}
if (transfer_encoding) {
php_stream_filter_free(transfer_encoding TSRMLS_CC);
}
}
return stream;
} | 5501 | True | 1 |
CVE-2013-3735 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | [{'url': 'https://github.com/php/php-src/blob/php-5.4.16RC1/NEWS', 'name': 'https://github.com/php/php-src/blob/php-5.4.16RC1/NEWS', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://github.com/php/php-src/commit/fb58e69a84f4fde603a630d2c9df2fa3be16d846', 'name': 'https://github.com/php/php-src/commit/fb58e69a84f4fde603a630d2c9df2fa3be16d846', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Patch']}, {'url': 'https://github.com/php/php-src/blob/php-5.5.0RC2/NEWS', 'name': 'https://github.com/php/php-src/blob/php-5.5.0RC2/NEWS', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://bugs.php.net/bug.php?id=64660', 'name': 'https://bugs.php.net/bug.php?id=64660', 'refsource': 'MISC', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-20'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:rc1:*:*:*:*:*:*', 'versionEndIncluding': '5.4.15', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:rc1:*:*:*:*:*:*', 'versionEndIncluding': '5.5.0', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha6:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha5:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha2:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': '** DISPUTED ** The Zend Engine in PHP before 5.4.16 RC1, and 5.5.0 before RC2, does not properly determine whether a parser error occurred, which allows context-dependent attackers to cause a denial of service (memory consumption and application crash) via a crafted function definition, as demonstrated by an attack within a shared web-hosting environment. NOTE: the vendor\'s http://php.net/security-note.php page says "for critical security situations you should be using OS-level security by running multiple web servers each as their own user id."'}] | 2013-06-03T04:00Z | 2013-05-31T21:55Z | Improper Input Validation | The product receives input or data, but it does
not validate or incorrectly validates that the input has the
properties that are required to process the data safely and
correctly. |
Input validation is a frequently-used technique
for checking potentially dangerous inputs in order to
ensure that the inputs are safe for processing within the
code, or when communicating with other components. When
software does not validate input properly, an attacker is
able to craft the input in a form that is not expected by
the rest of the application. This will lead to parts of the
system receiving unintended input, which may result in
altered control flow, arbitrary control of a resource, or
arbitrary code execution.
Input validation is not the only technique for
processing input, however. Other techniques attempt to
transform potentially-dangerous input into something safe, such
as filtering (CWE-790) - which attempts to remove dangerous
inputs - or encoding/escaping (CWE-116), which attempts to
ensure that the input is not misinterpreted when it is included
in output to another component. Other techniques exist as well
(see CWE-138 for more examples.)
Input validation can be applied to:
raw data - strings, numbers, parameters, file contents, etc.
metadata - information about the raw data, such as headers or size
Data can be simple or structured. Structured data
can be composed of many nested layers, composed of
combinations of metadata and raw data, with other simple or
structured data.
Many properties of raw data or metadata may need
to be validated upon entry into the code, such
as:
specified quantities such as size, length, frequency, price, rate, number of operations, time, etc.
implied or derived quantities, such as the actual size of a file instead of a specified size
indexes, offsets, or positions into more complex data structures
symbolic keys or other elements into hash tables, associative arrays, etc.
well-formedness, i.e. syntactic correctness - compliance with expected syntax
lexical token correctness - compliance with rules for what is treated as a token
specified or derived type - the actual type of the input (or what the input appears to be)
consistency - between individual data elements, between raw data and metadata, between references, etc.
conformance to domain-specific rules, e.g. business logic
equivalence - ensuring that equivalent inputs are treated the same
authenticity, ownership, or other attestations about the input, e.g. a cryptographic signature to prove the source of the data
Implied or derived properties of data must often
be calculated or inferred by the code itself. Errors in
deriving properties may be considered a contributing factor
to improper input validation.
Note that "input validation" has very different
meanings to different people, or within different
classification schemes. Caution must be used when
referencing this CWE entry or mapping to it. For example,
some weaknesses might involve inadvertently giving control
to an attacker over an input when they should not be able
to provide an input at all, but sometimes this is referred
to as input validation.
Finally, it is important to emphasize that the
distinctions between input validation and output escaping
are often blurred, and developers must be careful to
understand the difference, including how input validation
is not always sufficient to prevent vulnerabilities,
especially when less stringent data types must be
supported, such as free-form text. Consider a SQL injection
scenario in which a person's last name is inserted into a
query. The name "O'Reilly" would likely pass the validation
step since it is a common last name in the English
language. However, this valid name cannot be directly
inserted into the database because it contains the "'"
apostrophe character, which would need to be escaped or
otherwise transformed. In this case, removing the
apostrophe might reduce the risk of SQL injection, but it
would produce incorrect behavior because the wrong name
would be recorded.
| https://cwe.mitre.org/data/definitions/20.html | 0 | Stanislav Malyshev | 2013-05-20 00:52:38-07:00 | fix bug #64660 - yyparse can return 2, not only 1 | fb58e69a84f4fde603a630d2c9df2fa3be16d846 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | compile_file | compile_file( zend_file_handle * file_handle , int type TSRMLS_DC) | ['file_handle', 'TSRMLS_DC'] | ZEND_API zend_op_array *compile_file(zend_file_handle *file_handle, int type TSRMLS_DC)
{
zend_lex_state original_lex_state;
zend_op_array *op_array = (zend_op_array *) emalloc(sizeof(zend_op_array));
zend_op_array *original_active_op_array = CG(active_op_array);
zend_op_array *retval=NULL;
int compiler_result;
zend_bool compilation_successful=0;
znode retval_znode;
zend_bool original_in_compilation = CG(in_compilation);
retval_znode.op_type = IS_CONST;
retval_znode.u.constant.type = IS_LONG;
retval_znode.u.constant.value.lval = 1;
Z_UNSET_ISREF(retval_znode.u.constant);
Z_SET_REFCOUNT(retval_znode.u.constant, 1);
zend_save_lexical_state(&original_lex_state TSRMLS_CC);
retval = op_array; /* success oriented */
if (open_file_for_scanning(file_handle TSRMLS_CC)==FAILURE) {
if (type==ZEND_REQUIRE) {
zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, file_handle->filename TSRMLS_CC);
zend_bailout();
} else {
zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, file_handle->filename TSRMLS_CC);
}
compilation_successful=0;
} else {
init_op_array(op_array, ZEND_USER_FUNCTION, INITIAL_OP_ARRAY_SIZE TSRMLS_CC);
CG(in_compilation) = 1;
CG(active_op_array) = op_array;
zend_stack_push(&CG(context_stack), (void *) &CG(context), sizeof(CG(context)));
zend_init_compiler_context(TSRMLS_C);
compiler_result = zendparse(TSRMLS_C);
zend_do_return(&retval_znode, 0 TSRMLS_CC);
CG(in_compilation) = original_in_compilation;
if (compiler_result==1) { /* parser error */
zend_bailout();
}
compilation_successful=1;
}
if (retval) {
CG(active_op_array) = original_active_op_array;
if (compilation_successful) {
pass_two(op_array TSRMLS_CC);
zend_release_labels(0 TSRMLS_CC);
} else {
efree(op_array);
retval = NULL;
}
}
zend_restore_lexical_state(&original_lex_state TSRMLS_CC);
return retval;
} | 325 | True | 1 |
CVE-2013-3735 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | [{'url': 'https://github.com/php/php-src/blob/php-5.4.16RC1/NEWS', 'name': 'https://github.com/php/php-src/blob/php-5.4.16RC1/NEWS', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://github.com/php/php-src/commit/fb58e69a84f4fde603a630d2c9df2fa3be16d846', 'name': 'https://github.com/php/php-src/commit/fb58e69a84f4fde603a630d2c9df2fa3be16d846', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Patch']}, {'url': 'https://github.com/php/php-src/blob/php-5.5.0RC2/NEWS', 'name': 'https://github.com/php/php-src/blob/php-5.5.0RC2/NEWS', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://bugs.php.net/bug.php?id=64660', 'name': 'https://bugs.php.net/bug.php?id=64660', 'refsource': 'MISC', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-20'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:rc1:*:*:*:*:*:*', 'versionEndIncluding': '5.4.15', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:rc1:*:*:*:*:*:*', 'versionEndIncluding': '5.5.0', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha6:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha5:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha2:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': '** DISPUTED ** The Zend Engine in PHP before 5.4.16 RC1, and 5.5.0 before RC2, does not properly determine whether a parser error occurred, which allows context-dependent attackers to cause a denial of service (memory consumption and application crash) via a crafted function definition, as demonstrated by an attack within a shared web-hosting environment. NOTE: the vendor\'s http://php.net/security-note.php page says "for critical security situations you should be using OS-level security by running multiple web servers each as their own user id."'}] | 2013-06-03T04:00Z | 2013-05-31T21:55Z | Improper Input Validation | The product receives input or data, but it does
not validate or incorrectly validates that the input has the
properties that are required to process the data safely and
correctly. |
Input validation is a frequently-used technique
for checking potentially dangerous inputs in order to
ensure that the inputs are safe for processing within the
code, or when communicating with other components. When
software does not validate input properly, an attacker is
able to craft the input in a form that is not expected by
the rest of the application. This will lead to parts of the
system receiving unintended input, which may result in
altered control flow, arbitrary control of a resource, or
arbitrary code execution.
Input validation is not the only technique for
processing input, however. Other techniques attempt to
transform potentially-dangerous input into something safe, such
as filtering (CWE-790) - which attempts to remove dangerous
inputs - or encoding/escaping (CWE-116), which attempts to
ensure that the input is not misinterpreted when it is included
in output to another component. Other techniques exist as well
(see CWE-138 for more examples.)
Input validation can be applied to:
raw data - strings, numbers, parameters, file contents, etc.
metadata - information about the raw data, such as headers or size
Data can be simple or structured. Structured data
can be composed of many nested layers, composed of
combinations of metadata and raw data, with other simple or
structured data.
Many properties of raw data or metadata may need
to be validated upon entry into the code, such
as:
specified quantities such as size, length, frequency, price, rate, number of operations, time, etc.
implied or derived quantities, such as the actual size of a file instead of a specified size
indexes, offsets, or positions into more complex data structures
symbolic keys or other elements into hash tables, associative arrays, etc.
well-formedness, i.e. syntactic correctness - compliance with expected syntax
lexical token correctness - compliance with rules for what is treated as a token
specified or derived type - the actual type of the input (or what the input appears to be)
consistency - between individual data elements, between raw data and metadata, between references, etc.
conformance to domain-specific rules, e.g. business logic
equivalence - ensuring that equivalent inputs are treated the same
authenticity, ownership, or other attestations about the input, e.g. a cryptographic signature to prove the source of the data
Implied or derived properties of data must often
be calculated or inferred by the code itself. Errors in
deriving properties may be considered a contributing factor
to improper input validation.
Note that "input validation" has very different
meanings to different people, or within different
classification schemes. Caution must be used when
referencing this CWE entry or mapping to it. For example,
some weaknesses might involve inadvertently giving control
to an attacker over an input when they should not be able
to provide an input at all, but sometimes this is referred
to as input validation.
Finally, it is important to emphasize that the
distinctions between input validation and output escaping
are often blurred, and developers must be careful to
understand the difference, including how input validation
is not always sufficient to prevent vulnerabilities,
especially when less stringent data types must be
supported, such as free-form text. Consider a SQL injection
scenario in which a person's last name is inserted into a
query. The name "O'Reilly" would likely pass the validation
step since it is a common last name in the English
language. However, this valid name cannot be directly
inserted into the database because it contains the "'"
apostrophe character, which would need to be escaped or
otherwise transformed. In this case, removing the
apostrophe might reduce the risk of SQL injection, but it
would produce incorrect behavior because the wrong name
would be recorded.
| https://cwe.mitre.org/data/definitions/20.html | 0 | Stanislav Malyshev | 2013-05-20 00:52:38-07:00 | fix bug #64660 - yyparse can return 2, not only 1 | fb58e69a84f4fde603a630d2c9df2fa3be16d846 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | compile_string | compile_string( zval * source_string , char * filename TSRMLS_DC) | ['source_string', 'TSRMLS_DC'] | zend_op_array *compile_string(zval *source_string, char *filename TSRMLS_DC)
{
zend_lex_state original_lex_state;
zend_op_array *op_array = (zend_op_array *) emalloc(sizeof(zend_op_array));
zend_op_array *original_active_op_array = CG(active_op_array);
zend_op_array *retval;
zval tmp;
int compiler_result;
zend_bool original_in_compilation = CG(in_compilation);
if (source_string->value.str.len==0) {
efree(op_array);
return NULL;
}
CG(in_compilation) = 1;
tmp = *source_string;
zval_copy_ctor(&tmp);
convert_to_string(&tmp);
source_string = &tmp;
zend_save_lexical_state(&original_lex_state TSRMLS_CC);
if (zend_prepare_string_for_scanning(source_string, filename TSRMLS_CC)==FAILURE) {
efree(op_array);
retval = NULL;
} else {
zend_bool orig_interactive = CG(interactive);
CG(interactive) = 0;
init_op_array(op_array, ZEND_EVAL_CODE, INITIAL_OP_ARRAY_SIZE TSRMLS_CC);
CG(interactive) = orig_interactive;
CG(active_op_array) = op_array;
zend_stack_push(&CG(context_stack), (void *) &CG(context), sizeof(CG(context)));
zend_init_compiler_context(TSRMLS_C);
BEGIN(ST_IN_SCRIPTING);
compiler_result = zendparse(TSRMLS_C);
if (SCNG(script_filtered)) {
efree(SCNG(script_filtered));
SCNG(script_filtered) = NULL;
}
if (compiler_result==1) {
CG(active_op_array) = original_active_op_array;
CG(unclean_shutdown)=1;
destroy_op_array(op_array TSRMLS_CC);
efree(op_array);
retval = NULL;
} else {
zend_do_return(NULL, 0 TSRMLS_CC);
CG(active_op_array) = original_active_op_array;
pass_two(op_array TSRMLS_CC);
zend_release_labels(0 TSRMLS_CC);
retval = op_array;
}
}
zend_restore_lexical_state(&original_lex_state TSRMLS_CC);
zval_dtor(&tmp);
CG(in_compilation) = original_in_compilation;
return retval;
} | 344 | True | 1 |
CVE-2014-0185 | False | False | False | False | AV:L/AC:L/Au:N/C:C/I:C/A:C | LOCAL | LOW | NONE | COMPLETE | COMPLETE | COMPLETE | 7.2 | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | [{'url': 'http://www.openwall.com/lists/oss-security/2014/04/29/5', 'name': '[oss-security] 20140429 Fwd: [vs] php-fpm: privilege escalation due to insecure default config (CVE-2014-0185)', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://bugzilla.redhat.com/show_bug.cgi?id=1092815', 'name': 'https://bugzilla.redhat.com/show_bug.cgi?id=1092815', 'refsource': 'CONFIRM', 'tags': ['Issue Tracking', 'Third Party Advisory']}, {'url': 'http://www.php.net/ChangeLog-5.php', 'name': 'http://www.php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'https://hoffmann-christian.info/files/php-fpm/0001-Fix-bug-67060-use-default-mode-of-660.patch', 'name': 'https://hoffmann-christian.info/files/php-fpm/0001-Fix-bug-67060-use-default-mode-of-660.patch', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://www.php.net/archive/2014.php#id2014-05-01-1', 'name': 'http://www.php.net/archive/2014.php#id2014-05-01-1', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'https://bugs.launchpad.net/ubuntu/+source/php5/+bug/1307027', 'name': 'https://bugs.launchpad.net/ubuntu/+source/php5/+bug/1307027', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/php/php-src/commit/35ceea928b12373a3b1e3eecdc32ed323223a40d', 'name': 'https://github.com/php/php-src/commit/35ceea928b12373a3b1e3eecdc32ed323223a40d', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Patch', 'Third Party Advisory']}, {'url': 'https://bugs.php.net/bug.php?id=67060', 'name': 'https://bugs.php.net/bug.php?id=67060', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'http://support.apple.com/kb/HT6443', 'name': 'http://support.apple.com/kb/HT6443', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-updates/2015-10/msg00012.html', 'name': 'openSUSE-SU-2015:1685', 'refsource': 'SUSE', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'http://secunia.com/advisories/59329', 'name': '59329', 'refsource': 'SECUNIA', 'tags': ['Third Party Advisory']}, {'url': 'http://secunia.com/advisories/59061', 'name': '59061', 'refsource': 'SECUNIA', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-269'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '5.5.0', 'versionEndExcluding': '5.5.12', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '5.4.0', 'versionEndExcluding': '5.4.28', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionStartIncluding': '5.3.0', 'versionEndExcluding': '5.3.28', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'sapi/fpm/fpm/fpm_unix.c in the FastCGI Process Manager (FPM) in PHP before 5.4.28 and 5.5.x before 5.5.12 uses 0666 permissions for the UNIX socket, which allows local users to gain privileges via a crafted FastCGI client.'}] | 2022-08-16T13:32Z | 2014-05-06T10:44Z | Improper Privilege Management | The software does not properly assign, modify, track, or check privileges for an actor, creating an unintended sphere of control for that actor. | https://cwe.mitre.org/data/definitions/269.html | 0 | Stanislav Malyshev | 2014-04-15 10:43:24-07:00 | Fix bug #67060: use default mode of 660 | 35ceea928b12373a3b1e3eecdc32ed323223a40d | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | fpm_unix_resolve_socket_premissions | fpm_unix_resolve_socket_premissions( struct fpm_worker_pool_s * wp) | ['wp'] | int fpm_unix_resolve_socket_premissions(struct fpm_worker_pool_s *wp) /* {{{ */
{
struct fpm_worker_pool_config_s *c = wp->config;
/* uninitialized */
wp->socket_uid = -1;
wp->socket_gid = -1;
wp->socket_mode = 0666;
if (!c) {
return 0;
}
if (c->listen_owner && *c->listen_owner) {
struct passwd *pwd;
pwd = getpwnam(c->listen_owner);
if (!pwd) {
zlog(ZLOG_SYSERROR, "[pool %s] cannot get uid for user '%s'", wp->config->name, c->listen_owner);
return -1;
}
wp->socket_uid = pwd->pw_uid;
wp->socket_gid = pwd->pw_gid;
}
if (c->listen_group && *c->listen_group) {
struct group *grp;
grp = getgrnam(c->listen_group);
if (!grp) {
zlog(ZLOG_SYSERROR, "[pool %s] cannot get gid for group '%s'", wp->config->name, c->listen_group);
return -1;
}
wp->socket_gid = grp->gr_gid;
}
if (c->listen_mode && *c->listen_mode) {
wp->socket_mode = strtoul(c->listen_mode, 0, 8);
}
return 0;
} | 213 | True | 1 |
|
CVE-2014-3587 | False | False | False | False | AV:N/AC:M/Au:N/C:N/I:N/A:P | NETWORK | MEDIUM | NONE | NONE | NONE | PARTIAL | 4.3 | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | [{'url': 'http://www.debian.org/security/2014/dsa-3008', 'name': 'DSA-3008', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'https://bugs.php.net/bug.php?id=67716', 'name': 'https://bugs.php.net/bug.php?id=67716', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://security-tracker.debian.org/tracker/CVE-2014-3587', 'name': 'https://security-tracker.debian.org/tracker/CVE-2014-3587', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://github.com/file/file/commit/0641e56be1af003aa02c7c6b0184466540637233', 'name': 'https://github.com/file/file/commit/0641e56be1af003aa02c7c6b0184466540637233', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Patch']}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://github.com/php/php-src/commit/7ba1409a1aee5925180de546057ddd84ff267947', 'name': 'https://github.com/php/php-src/commit/7ba1409a1aee5925180de546057ddd84ff267947', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Patch']}, {'url': 'http://www.ubuntu.com/usn/USN-2369-1', 'name': 'USN-2369-1', 'refsource': 'UBUNTU', 'tags': []}, {'url': 'http://www.ubuntu.com/usn/USN-2344-1', 'name': 'USN-2344-1', 'refsource': 'UBUNTU', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1327.html', 'name': 'RHSA-2014:1327', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1326.html', 'name': 'RHSA-2014:1326', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://www.debian.org/security/2014/dsa-3021', 'name': 'DSA-3021', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1766.html', 'name': 'RHSA-2014:1766', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1765.html', 'name': 'RHSA-2014:1765', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://lists.apple.com/archives/security-announce/2015/Apr/msg00001.html', 'name': 'APPLE-SA-2015-04-08-2', 'refsource': 'APPLE', 'tags': []}, {'url': 'https://support.apple.com/HT204659', 'name': 'https://support.apple.com/HT204659', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.oracle.com/technetwork/topics/security/linuxbulletinapr2016-2952096.html', 'name': 'http://www.oracle.com/technetwork/topics/security/linuxbulletinapr2016-2952096.html', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.oracle.com/technetwork/topics/security/linuxbulletinoct2015-2719645.html', 'name': 'http://www.oracle.com/technetwork/topics/security/linuxbulletinoct2015-2719645.html', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.oracle.com/technetwork/topics/security/bulletinjan2015-2370101.html', 'name': 'http://www.oracle.com/technetwork/topics/security/bulletinjan2015-2370101.html', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.securityfocus.com/bid/69325', 'name': '69325', 'refsource': 'BID', 'tags': []}, {'url': 'http://secunia.com/advisories/60696', 'name': '60696', 'refsource': 'SECUNIA', 'tags': []}, {'url': 'http://secunia.com/advisories/60609', 'name': '60609', 'refsource': 'SECUNIA', 'tags': []}, {'url': 'http://www.oracle.com/technetwork/security-advisory/cpuoct2017-3236626.html', 'name': 'http://www.oracle.com/technetwork/security-advisory/cpuoct2017-3236626.html', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2016-0760.html', 'name': 'RHSA-2016:0760', 'refsource': 'REDHAT', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-189'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.00:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.04:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.15:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.02:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.03:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.4.31', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.16:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.07:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.19:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.17:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.18:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.16:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.23:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.24:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.30:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.01:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.08:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.17:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.21:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.22:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.27:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.28:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha6:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.05:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.26:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.19', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.09:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.20:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.29:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.06:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:christos_zoulas:file:5.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha5:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:beta2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:beta2:32-bit:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.18:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.25:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.4:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'Integer overflow in the cdf_read_property_info function in cdf.c in file through 5.19, as used in the Fileinfo component in PHP before 5.4.32 and 5.5.x before 5.5.16, allows remote attackers to cause a denial of service (application crash) via a crafted CDF file. NOTE: this vulnerability exists because of an incomplete fix for CVE-2012-1571.'}] | 2018-01-05T02:29Z | 2014-08-23T01:55Z | Numeric Errors | Weaknesses in this category are related to improper calculation or conversion of numbers. | https://cwe.mitre.org/data/definitions/189.html | 1 | Remi Collet | 2014-08-14 17:19:03-07:00 | Fix bug #67716 - Segfault in cdf.c | 7ba1409a1aee5925180de546057ddd84ff267947 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | cdf_read_property_info | cdf_read_property_info( const cdf_stream_t * sst , const cdf_header_t * h , uint32_t offs , cdf_property_info_t ** info , size_t * count , size_t * maxcount) | ['sst', 'h', 'offs', 'info', 'count', 'maxcount'] | cdf_read_property_info(const cdf_stream_t *sst, const cdf_header_t *h,
uint32_t offs, cdf_property_info_t **info, size_t *count, size_t *maxcount)
{
const cdf_section_header_t *shp;
cdf_section_header_t sh;
const uint8_t *p, *q, *e;
int16_t s16;
int32_t s32;
uint32_t u32;
int64_t s64;
uint64_t u64;
cdf_timestamp_t tp;
size_t i, o, o4, nelements, j;
cdf_property_info_t *inp;
if (offs > UINT32_MAX / 4) {
errno = EFTYPE;
goto out;
}
shp = CAST(const cdf_section_header_t *, (const void *)
((const char *)sst->sst_tab + offs));
if (cdf_check_stream_offset(sst, h, shp, sizeof(*shp), __LINE__) == -1)
goto out;
sh.sh_len = CDF_TOLE4(shp->sh_len);
#define CDF_SHLEN_LIMIT (UINT32_MAX / 8)
if (sh.sh_len > CDF_SHLEN_LIMIT) {
errno = EFTYPE;
goto out;
}
sh.sh_properties = CDF_TOLE4(shp->sh_properties);
#define CDF_PROP_LIMIT (UINT32_MAX / (4 * sizeof(*inp)))
if (sh.sh_properties > CDF_PROP_LIMIT)
goto out;
DPRINTF(("section len: %u properties %u\n", sh.sh_len,
sh.sh_properties));
if (*maxcount) {
if (*maxcount > CDF_PROP_LIMIT)
goto out;
*maxcount += sh.sh_properties;
inp = CAST(cdf_property_info_t *,
realloc(*info, *maxcount * sizeof(*inp)));
} else {
*maxcount = sh.sh_properties;
inp = CAST(cdf_property_info_t *,
malloc(*maxcount * sizeof(*inp)));
}
if (inp == NULL)
goto out;
*info = inp;
inp += *count;
*count += sh.sh_properties;
p = CAST(const uint8_t *, (const void *)
((const char *)(const void *)sst->sst_tab +
offs + sizeof(sh)));
e = CAST(const uint8_t *, (const void *)
(((const char *)(const void *)shp) + sh.sh_len));
if (cdf_check_stream_offset(sst, h, e, 0, __LINE__) == -1)
goto out;
for (i = 0; i < sh.sh_properties; i++) {
size_t ofs, tail = (i << 1) + 1;
if (cdf_check_stream_offset(sst, h, p, tail * sizeof(uint32_t),
__LINE__) == -1)
goto out;
ofs = CDF_GETUINT32(p, tail);
q = (const uint8_t *)(const void *)
((const char *)(const void *)p + ofs
- 2 * sizeof(uint32_t));
if (q > e) {
DPRINTF(("Ran of the end %p > %p\n", q, e));
goto out;
}
inp[i].pi_id = CDF_GETUINT32(p, i << 1);
inp[i].pi_type = CDF_GETUINT32(q, 0);
DPRINTF(("%" SIZE_T_FORMAT "u) id=%x type=%x offs=0x%tx,0x%x\n",
i, inp[i].pi_id, inp[i].pi_type, q - p, offs));
if (inp[i].pi_type & CDF_VECTOR) {
nelements = CDF_GETUINT32(q, 1);
if (nelements == 0) {
DPRINTF(("CDF_VECTOR with nelements == 0\n"));
goto out;
}
o = 2;
} else {
nelements = 1;
o = 1;
}
o4 = o * sizeof(uint32_t);
if (inp[i].pi_type & (CDF_ARRAY|CDF_BYREF|CDF_RESERVED))
goto unknown;
switch (inp[i].pi_type & CDF_TYPEMASK) {
case CDF_NULL:
case CDF_EMPTY:
break;
case CDF_SIGNED16:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
(void)memcpy(&s16, &q[o4], sizeof(s16));
inp[i].pi_s16 = CDF_TOLE2(s16);
break;
case CDF_SIGNED32:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
(void)memcpy(&s32, &q[o4], sizeof(s32));
inp[i].pi_s32 = CDF_TOLE4((uint32_t)s32);
break;
case CDF_BOOL:
case CDF_UNSIGNED32:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
(void)memcpy(&u32, &q[o4], sizeof(u32));
inp[i].pi_u32 = CDF_TOLE4(u32);
break;
case CDF_SIGNED64:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
(void)memcpy(&s64, &q[o4], sizeof(s64));
inp[i].pi_s64 = CDF_TOLE8((uint64_t)s64);
break;
case CDF_UNSIGNED64:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
(void)memcpy(&u64, &q[o4], sizeof(u64));
inp[i].pi_u64 = CDF_TOLE8((uint64_t)u64);
break;
case CDF_FLOAT:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
(void)memcpy(&u32, &q[o4], sizeof(u32));
u32 = CDF_TOLE4(u32);
memcpy(&inp[i].pi_f, &u32, sizeof(inp[i].pi_f));
break;
case CDF_DOUBLE:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
(void)memcpy(&u64, &q[o4], sizeof(u64));
u64 = CDF_TOLE8((uint64_t)u64);
memcpy(&inp[i].pi_d, &u64, sizeof(inp[i].pi_d));
break;
case CDF_LENGTH32_STRING:
case CDF_LENGTH32_WSTRING:
if (nelements > 1) {
size_t nelem = inp - *info;
if (*maxcount > CDF_PROP_LIMIT
|| nelements > CDF_PROP_LIMIT)
goto out;
*maxcount += nelements;
inp = CAST(cdf_property_info_t *,
realloc(*info, *maxcount * sizeof(*inp)));
if (inp == NULL)
goto out;
*info = inp;
inp = *info + nelem;
}
DPRINTF(("nelements = %" SIZE_T_FORMAT "u\n",
nelements));
for (j = 0; j < nelements && i < sh.sh_properties;
j++, i++)
{
uint32_t l = CDF_GETUINT32(q, o);
inp[i].pi_str.s_len = l;
inp[i].pi_str.s_buf = (const char *)
(const void *)(&q[o4 + sizeof(l)]);
DPRINTF(("l = %d, r = %" SIZE_T_FORMAT
"u, s = %s\n", l,
CDF_ROUND(l, sizeof(l)),
inp[i].pi_str.s_buf));
if (l & 1)
l++;
o += l >> 1;
if (q + o >= e)
goto out;
o4 = o * sizeof(uint32_t);
}
i--;
break;
case CDF_FILETIME:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
(void)memcpy(&tp, &q[o4], sizeof(tp));
inp[i].pi_tp = CDF_TOLE8((uint64_t)tp);
break;
case CDF_CLIPBOARD:
if (inp[i].pi_type & CDF_VECTOR)
goto unknown;
break;
default:
unknown:
DPRINTF(("Don't know how to deal with %x\n",
inp[i].pi_type));
break;
}
}
return 0;
out:
free(*info);
return -1;
} | 1462 | True | 1 |
|
CVE-2014-3597 | False | False | False | False | AV:N/AC:M/Au:N/C:P/I:P/A:P | NETWORK | MEDIUM | NONE | PARTIAL | PARTIAL | PARTIAL | 6.8 | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | [{'url': 'https://bugs.php.net/bug.php?id=67717', 'name': 'https://bugs.php.net/bug.php?id=67717', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'https://github.com/php/php-src/commit/2fefae47716d501aec41c1102f3fd4531f070b05', 'name': 'https://github.com/php/php-src/commit/2fefae47716d501aec41c1102f3fd4531f070b05', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://security-tracker.debian.org/tracker/CVE-2014-3597', 'name': 'https://security-tracker.debian.org/tracker/CVE-2014-3597', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.debian.org/security/2014/dsa-3008', 'name': 'DSA-3008', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2014-09/msg00024.html', 'name': 'openSUSE-SU-2014:1133', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://www.ubuntu.com/usn/USN-2344-1', 'name': 'USN-2344-1', 'refsource': 'UBUNTU', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2014-09/msg00055.html', 'name': 'openSUSE-SU-2014:1245', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1327.html', 'name': 'RHSA-2014:1327', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1326.html', 'name': 'RHSA-2014:1326', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1766.html', 'name': 'RHSA-2014:1766', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1765.html', 'name': 'RHSA-2014:1765', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://support.apple.com/HT204659', 'name': 'https://support.apple.com/HT204659', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://lists.apple.com/archives/security-announce/2015/Apr/msg00001.html', 'name': 'APPLE-SA-2015-04-08-2', 'refsource': 'APPLE', 'tags': []}, {'url': 'http://www.securityfocus.com/bid/69322', 'name': '69322', 'refsource': 'BID', 'tags': []}, {'url': 'http://www.oracle.com/technetwork/topics/security/bulletinjan2015-2370101.html', 'name': 'http://www.oracle.com/technetwork/topics/security/bulletinjan2015-2370101.html', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://secunia.com/advisories/60696', 'name': '60696', 'refsource': 'SECUNIA', 'tags': []}, {'url': 'http://secunia.com/advisories/60609', 'name': '60609', 'refsource': 'SECUNIA', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.15:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.4.31', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.19:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.17:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.22:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.20:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.21:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.29:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:beta2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.18:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.25:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.26:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.27:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.28:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha6:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha5:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.16:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.23:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.24:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.30:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:beta2:32-bit:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.9:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'Multiple buffer overflows in the php_parserr function in ext/standard/dns.c in PHP before 5.4.32 and 5.5.x before 5.5.16 allow remote DNS servers to cause a denial of service (application crash) or possibly execute arbitrary code via a crafted DNS record, related to the dns_get_record function and the dn_expand function. NOTE: this issue exists because of an incomplete fix for CVE-2014-4049.'}] | 2017-01-07T03:00Z | 2014-08-23T01:55Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Remi Collet | 2014-08-19 08:33:49+02:00 | Fixed Sec Bug #67717 segfault in dns_get_record CVE-2014-3597
Incomplete fix for CVE-2014-4049
Check possible buffer overflow
- pass real buffer end to dn_expand calls
- check buffer len before each read | 2fefae47716d501aec41c1102f3fd4531f070b05 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | PHP_FUNCTION | PHP_FUNCTION( dns_get_record) | ['dns_get_record'] | PHP_FUNCTION(dns_get_record)
{
char *hostname;
int hostname_len;
long type_param = PHP_DNS_ANY;
zval *authns = NULL, *addtl = NULL;
int type_to_fetch;
#if defined(HAVE_DNS_SEARCH)
struct sockaddr_storage from;
uint32_t fromsize = sizeof(from);
dns_handle_t handle;
#elif defined(HAVE_RES_NSEARCH)
struct __res_state state;
struct __res_state *handle = &state;
#endif
HEADER *hp;
querybuf answer;
u_char *cp = NULL, *end = NULL;
int n, qd, an, ns = 0, ar = 0;
int type, first_query = 1, store_results = 1;
zend_bool raw = 0;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|lz!z!b",
&hostname, &hostname_len, &type_param, &authns, &addtl, &raw) == FAILURE) {
return;
}
if (authns) {
zval_dtor(authns);
array_init(authns);
}
if (addtl) {
zval_dtor(addtl);
array_init(addtl);
}
if (!raw) {
if ((type_param & ~PHP_DNS_ALL) && (type_param != PHP_DNS_ANY)) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Type '%ld' not supported", type_param);
RETURN_FALSE;
}
} else {
if ((type_param < 1) || (type_param > 0xFFFF)) {
php_error_docref(NULL TSRMLS_CC, E_WARNING,
"Numeric DNS record type must be between 1 and 65535, '%ld' given", type_param);
RETURN_FALSE;
}
}
/* Initialize the return array */
array_init(return_value);
/* - We emulate an or'ed type mask by querying type by type. (Steps 0 - NUMTYPES-1 )
* If additional info is wanted we check again with DNS_T_ANY (step NUMTYPES / NUMTYPES+1 )
* store_results is used to skip storing the results retrieved in step
* NUMTYPES+1 when results were already fetched.
* - In case of PHP_DNS_ANY we use the directly fetch DNS_T_ANY. (step NUMTYPES+1 )
* - In case of raw mode, we query only the requestd type instead of looping type by type
* before going with the additional info stuff.
*/
if (raw) {
type = -1;
} else if (type_param == PHP_DNS_ANY) {
type = PHP_DNS_NUM_TYPES + 1;
} else {
type = 0;
}
for ( ;
type < (addtl ? (PHP_DNS_NUM_TYPES + 2) : PHP_DNS_NUM_TYPES) || first_query;
type++
) {
first_query = 0;
switch (type) {
case -1: /* raw */
type_to_fetch = type_param;
/* skip over the rest and go directly to additional records */
type = PHP_DNS_NUM_TYPES - 1;
break;
case 0:
type_to_fetch = type_param&PHP_DNS_A ? DNS_T_A : 0;
break;
case 1:
type_to_fetch = type_param&PHP_DNS_NS ? DNS_T_NS : 0;
break;
case 2:
type_to_fetch = type_param&PHP_DNS_CNAME ? DNS_T_CNAME : 0;
break;
case 3:
type_to_fetch = type_param&PHP_DNS_SOA ? DNS_T_SOA : 0;
break;
case 4:
type_to_fetch = type_param&PHP_DNS_PTR ? DNS_T_PTR : 0;
break;
case 5:
type_to_fetch = type_param&PHP_DNS_HINFO ? DNS_T_HINFO : 0;
break;
case 6:
type_to_fetch = type_param&PHP_DNS_MX ? DNS_T_MX : 0;
break;
case 7:
type_to_fetch = type_param&PHP_DNS_TXT ? DNS_T_TXT : 0;
break;
case 8:
type_to_fetch = type_param&PHP_DNS_AAAA ? DNS_T_AAAA : 0;
break;
case 9:
type_to_fetch = type_param&PHP_DNS_SRV ? DNS_T_SRV : 0;
break;
case 10:
type_to_fetch = type_param&PHP_DNS_NAPTR ? DNS_T_NAPTR : 0;
break;
case 11:
type_to_fetch = type_param&PHP_DNS_A6 ? DNS_T_A6 : 0;
break;
case PHP_DNS_NUM_TYPES:
store_results = 0;
continue;
default:
case (PHP_DNS_NUM_TYPES + 1):
type_to_fetch = DNS_T_ANY;
break;
}
if (type_to_fetch) {
#if defined(HAVE_DNS_SEARCH)
handle = dns_open(NULL);
if (handle == NULL) {
zval_dtor(return_value);
RETURN_FALSE;
}
#elif defined(HAVE_RES_NSEARCH)
memset(&state, 0, sizeof(state));
if (res_ninit(handle)) {
zval_dtor(return_value);
RETURN_FALSE;
}
#else
res_init();
#endif
n = php_dns_search(handle, hostname, C_IN, type_to_fetch, answer.qb2, sizeof answer);
if (n < 0) {
php_dns_free_handle(handle);
continue;
}
cp = answer.qb2 + HFIXEDSZ;
end = answer.qb2 + n;
hp = (HEADER *)&answer;
qd = ntohs(hp->qdcount);
an = ntohs(hp->ancount);
ns = ntohs(hp->nscount);
ar = ntohs(hp->arcount);
/* Skip QD entries, they're only used by dn_expand later on */
while (qd-- > 0) {
n = dn_skipname(cp, end);
if (n < 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to parse DNS data received");
zval_dtor(return_value);
php_dns_free_handle(handle);
RETURN_FALSE;
}
cp += n + QFIXEDSZ;
}
/* YAY! Our real answers! */
while (an-- && cp && cp < end) {
zval *retval;
cp = php_parserr(cp, &answer, type_to_fetch, store_results, raw, &retval);
if (retval != NULL && store_results) {
add_next_index_zval(return_value, retval);
}
}
if (authns || addtl) {
/* List of Authoritative Name Servers
* Process when only requesting addtl so that we can skip through the section
*/
while (ns-- > 0 && cp && cp < end) {
zval *retval = NULL;
cp = php_parserr(cp, &answer, DNS_T_ANY, authns != NULL, raw, &retval);
if (retval != NULL) {
add_next_index_zval(authns, retval);
}
}
}
if (addtl) {
/* Additional records associated with authoritative name servers */
while (ar-- > 0 && cp && cp < end) {
zval *retval = NULL;
cp = php_parserr(cp, &answer, DNS_T_ANY, 1, raw, &retval);
if (retval != NULL) {
add_next_index_zval(addtl, retval);
}
}
}
php_dns_free_handle(handle);
}
}
} | 933 | True | 1 |
CVE-2014-3597 | False | False | False | False | AV:N/AC:M/Au:N/C:P/I:P/A:P | NETWORK | MEDIUM | NONE | PARTIAL | PARTIAL | PARTIAL | 6.8 | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | nan | [{'url': 'https://bugs.php.net/bug.php?id=67717', 'name': 'https://bugs.php.net/bug.php?id=67717', 'refsource': 'CONFIRM', 'tags': ['Vendor Advisory']}, {'url': 'https://github.com/php/php-src/commit/2fefae47716d501aec41c1102f3fd4531f070b05', 'name': 'https://github.com/php/php-src/commit/2fefae47716d501aec41c1102f3fd4531f070b05', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'https://security-tracker.debian.org/tracker/CVE-2014-3597', 'name': 'https://security-tracker.debian.org/tracker/CVE-2014-3597', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://www.debian.org/security/2014/dsa-3008', 'name': 'DSA-3008', 'refsource': 'DEBIAN', 'tags': []}, {'url': 'http://php.net/ChangeLog-5.php', 'name': 'http://php.net/ChangeLog-5.php', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2014-09/msg00024.html', 'name': 'openSUSE-SU-2014:1133', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://www.ubuntu.com/usn/USN-2344-1', 'name': 'USN-2344-1', 'refsource': 'UBUNTU', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-updates/2014-09/msg00055.html', 'name': 'openSUSE-SU-2014:1245', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1327.html', 'name': 'RHSA-2014:1327', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1326.html', 'name': 'RHSA-2014:1326', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1766.html', 'name': 'RHSA-2014:1766', 'refsource': 'REDHAT', 'tags': []}, {'url': 'http://rhn.redhat.com/errata/RHSA-2014-1765.html', 'name': 'RHSA-2014:1765', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://support.apple.com/HT204659', 'name': 'https://support.apple.com/HT204659', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://lists.apple.com/archives/security-announce/2015/Apr/msg00001.html', 'name': 'APPLE-SA-2015-04-08-2', 'refsource': 'APPLE', 'tags': []}, {'url': 'http://www.securityfocus.com/bid/69322', 'name': '69322', 'refsource': 'BID', 'tags': []}, {'url': 'http://www.oracle.com/technetwork/topics/security/bulletinjan2015-2370101.html', 'name': 'http://www.oracle.com/technetwork/topics/security/bulletinjan2015-2370101.html', 'refsource': 'CONFIRM', 'tags': []}, {'url': 'http://secunia.com/advisories/60696', 'name': '60696', 'refsource': 'SECUNIA', 'tags': []}, {'url': 'http://secunia.com/advisories/60609', 'name': '60609', 'refsource': 'SECUNIA', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.15:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:*:*:*:*:*:*:*:*', 'versionEndIncluding': '5.4.31', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.19:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.9:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.12:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.17:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.12:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.22:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.14:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.20:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.21:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.29:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.3:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:beta2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.18:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.25:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.26:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.5:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.11:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.15:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.13:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.27:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.28:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.6:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.7:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha6:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha5:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.16:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.23:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.24:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.30:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.8:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.13:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:beta4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:alpha2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.2:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.0:beta2:32-bit:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.4.4:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:php:php:5.5.9:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'Multiple buffer overflows in the php_parserr function in ext/standard/dns.c in PHP before 5.4.32 and 5.5.x before 5.5.16 allow remote DNS servers to cause a denial of service (application crash) or possibly execute arbitrary code via a crafted DNS record, related to the dns_get_record function and the dn_expand function. NOTE: this issue exists because of an incomplete fix for CVE-2014-4049.'}] | 2017-01-07T03:00Z | 2014-08-23T01:55Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | Remi Collet | 2014-08-19 08:33:49+02:00 | Fixed Sec Bug #67717 segfault in dns_get_record CVE-2014-3597
Incomplete fix for CVE-2014-4049
Check possible buffer overflow
- pass real buffer end to dn_expand calls
- check buffer len before each read | 2fefae47716d501aec41c1102f3fd4531f070b05 | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | php_parserr | php_parserr( u_char * cp , querybuf * answer , int type_to_fetch , int store , int raw , zval ** subarray) | ['cp', 'answer', 'type_to_fetch', 'store', 'raw', 'subarray'] | static u_char *php_parserr(u_char *cp, querybuf *answer, int type_to_fetch, int store, int raw, zval **subarray)
{
u_short type, class, dlen;
u_long ttl;
long n, i;
u_short s;
u_char *tp, *p;
char name[MAXHOSTNAMELEN];
int have_v6_break = 0, in_v6_break = 0;
*subarray = NULL;
n = dn_expand(answer->qb2, answer->qb2+65536, cp, name, sizeof(name) - 2);
if (n < 0) {
return NULL;
}
cp += n;
GETSHORT(type, cp);
GETSHORT(class, cp);
GETLONG(ttl, cp);
GETSHORT(dlen, cp);
if (type_to_fetch != T_ANY && type != type_to_fetch) {
cp += dlen;
return cp;
}
if (!store) {
cp += dlen;
return cp;
}
ALLOC_INIT_ZVAL(*subarray);
array_init(*subarray);
add_assoc_string(*subarray, "host", name, 1);
add_assoc_string(*subarray, "class", "IN", 1);
add_assoc_long(*subarray, "ttl", ttl);
if (raw) {
add_assoc_long(*subarray, "type", type);
add_assoc_stringl(*subarray, "data", (char*) cp, (uint) dlen, 1);
cp += dlen;
return cp;
}
switch (type) {
case DNS_T_A:
add_assoc_string(*subarray, "type", "A", 1);
snprintf(name, sizeof(name), "%d.%d.%d.%d", cp[0], cp[1], cp[2], cp[3]);
add_assoc_string(*subarray, "ip", name, 1);
cp += dlen;
break;
case DNS_T_MX:
add_assoc_string(*subarray, "type", "MX", 1);
GETSHORT(n, cp);
add_assoc_long(*subarray, "pri", n);
/* no break; */
case DNS_T_CNAME:
if (type == DNS_T_CNAME) {
add_assoc_string(*subarray, "type", "CNAME", 1);
}
/* no break; */
case DNS_T_NS:
if (type == DNS_T_NS) {
add_assoc_string(*subarray, "type", "NS", 1);
}
/* no break; */
case DNS_T_PTR:
if (type == DNS_T_PTR) {
add_assoc_string(*subarray, "type", "PTR", 1);
}
n = dn_expand(answer->qb2, answer->qb2+65536, cp, name, (sizeof name) - 2);
if (n < 0) {
return NULL;
}
cp += n;
add_assoc_string(*subarray, "target", name, 1);
break;
case DNS_T_HINFO:
/* See RFC 1010 for values */
add_assoc_string(*subarray, "type", "HINFO", 1);
n = *cp & 0xFF;
cp++;
add_assoc_stringl(*subarray, "cpu", (char*)cp, n, 1);
cp += n;
n = *cp & 0xFF;
cp++;
add_assoc_stringl(*subarray, "os", (char*)cp, n, 1);
cp += n;
break;
case DNS_T_TXT:
{
int ll = 0;
zval *entries = NULL;
add_assoc_string(*subarray, "type", "TXT", 1);
tp = emalloc(dlen + 1);
MAKE_STD_ZVAL(entries);
array_init(entries);
while (ll < dlen) {
n = cp[ll];
if ((ll + n) >= dlen) {
// Invalid chunk length, truncate
n = dlen - (ll + 1);
}
memcpy(tp + ll , cp + ll + 1, n);
add_next_index_stringl(entries, cp + ll + 1, n, 1);
ll = ll + n + 1;
}
tp[dlen] = '\0';
cp += dlen;
add_assoc_stringl(*subarray, "txt", tp, (dlen>0)?dlen - 1:0, 0);
add_assoc_zval(*subarray, "entries", entries);
}
break;
case DNS_T_SOA:
add_assoc_string(*subarray, "type", "SOA", 1);
n = dn_expand(answer->qb2, answer->qb2+65536, cp, name, (sizeof name) -2);
if (n < 0) {
return NULL;
}
cp += n;
add_assoc_string(*subarray, "mname", name, 1);
n = dn_expand(answer->qb2, answer->qb2+65536, cp, name, (sizeof name) -2);
if (n < 0) {
return NULL;
}
cp += n;
add_assoc_string(*subarray, "rname", name, 1);
GETLONG(n, cp);
add_assoc_long(*subarray, "serial", n);
GETLONG(n, cp);
add_assoc_long(*subarray, "refresh", n);
GETLONG(n, cp);
add_assoc_long(*subarray, "retry", n);
GETLONG(n, cp);
add_assoc_long(*subarray, "expire", n);
GETLONG(n, cp);
add_assoc_long(*subarray, "minimum-ttl", n);
break;
case DNS_T_AAAA:
tp = (u_char*)name;
for(i=0; i < 8; i++) {
GETSHORT(s, cp);
if (s != 0) {
if (tp > (u_char *)name) {
in_v6_break = 0;
tp[0] = ':';
tp++;
}
tp += sprintf((char*)tp,"%x",s);
} else {
if (!have_v6_break) {
have_v6_break = 1;
in_v6_break = 1;
tp[0] = ':';
tp++;
} else if (!in_v6_break) {
tp[0] = ':';
tp++;
tp[0] = '0';
tp++;
}
}
}
if (have_v6_break && in_v6_break) {
tp[0] = ':';
tp++;
}
tp[0] = '\0';
add_assoc_string(*subarray, "type", "AAAA", 1);
add_assoc_string(*subarray, "ipv6", name, 1);
break;
case DNS_T_A6:
p = cp;
add_assoc_string(*subarray, "type", "A6", 1);
n = ((int)cp[0]) & 0xFF;
cp++;
add_assoc_long(*subarray, "masklen", n);
tp = (u_char*)name;
if (n > 15) {
have_v6_break = 1;
in_v6_break = 1;
tp[0] = ':';
tp++;
}
if (n % 16 > 8) {
/* Partial short */
if (cp[0] != 0) {
if (tp > (u_char *)name) {
in_v6_break = 0;
tp[0] = ':';
tp++;
}
sprintf((char*)tp, "%x", cp[0] & 0xFF);
} else {
if (!have_v6_break) {
have_v6_break = 1;
in_v6_break = 1;
tp[0] = ':';
tp++;
} else if (!in_v6_break) {
tp[0] = ':';
tp++;
tp[0] = '0';
tp++;
}
}
cp++;
}
for (i = (n + 8) / 16; i < 8; i++) {
GETSHORT(s, cp);
if (s != 0) {
if (tp > (u_char *)name) {
in_v6_break = 0;
tp[0] = ':';
tp++;
}
tp += sprintf((char*)tp,"%x",s);
} else {
if (!have_v6_break) {
have_v6_break = 1;
in_v6_break = 1;
tp[0] = ':';
tp++;
} else if (!in_v6_break) {
tp[0] = ':';
tp++;
tp[0] = '0';
tp++;
}
}
}
if (have_v6_break && in_v6_break) {
tp[0] = ':';
tp++;
}
tp[0] = '\0';
add_assoc_string(*subarray, "ipv6", name, 1);
if (cp < p + dlen) {
n = dn_expand(answer->qb2, answer->qb2+65536, cp, name, (sizeof name) - 2);
if (n < 0) {
return NULL;
}
cp += n;
add_assoc_string(*subarray, "chain", name, 1);
}
break;
case DNS_T_SRV:
add_assoc_string(*subarray, "type", "SRV", 1);
GETSHORT(n, cp);
add_assoc_long(*subarray, "pri", n);
GETSHORT(n, cp);
add_assoc_long(*subarray, "weight", n);
GETSHORT(n, cp);
add_assoc_long(*subarray, "port", n);
n = dn_expand(answer->qb2, answer->qb2+65536, cp, name, (sizeof name) - 2);
if (n < 0) {
return NULL;
}
cp += n;
add_assoc_string(*subarray, "target", name, 1);
break;
case DNS_T_NAPTR:
add_assoc_string(*subarray, "type", "NAPTR", 1);
GETSHORT(n, cp);
add_assoc_long(*subarray, "order", n);
GETSHORT(n, cp);
add_assoc_long(*subarray, "pref", n);
n = (cp[0] & 0xFF);
add_assoc_stringl(*subarray, "flags", (char*)++cp, n, 1);
cp += n;
n = (cp[0] & 0xFF);
add_assoc_stringl(*subarray, "services", (char*)++cp, n, 1);
cp += n;
n = (cp[0] & 0xFF);
add_assoc_stringl(*subarray, "regex", (char*)++cp, n, 1);
cp += n;
n = dn_expand(answer->qb2, answer->qb2+65536, cp, name, (sizeof name) - 2);
if (n < 0) {
return NULL;
}
cp += n;
add_assoc_string(*subarray, "replacement", name, 1);
break;
default:
zval_ptr_dtor(subarray);
*subarray = NULL;
cp += dlen;
break;
}
return cp;
} | 1923 | True | 1 |
CVE-2019-6978 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | False | [{'url': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'name': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/issues/492', 'name': 'https://github.com/libgd/libgd/issues/492', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'name': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/01/msg00028.html', 'name': '[debian-lts-announce] 20190130 [SECURITY] [DLA 1651-1] libgd2 security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://www.debian.org/security/2019/dsa-4384', 'name': 'DSA-4384', 'refsource': 'DEBIAN', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3900-1/', 'name': 'USN-3900-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/201903-18', 'name': 'GLSA-201903-18', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00025.html', 'name': 'openSUSE-SU-2019:1148', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00031.html', 'name': 'openSUSE-SU-2019:1140', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2722', 'name': 'RHSA-2019:2722', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TEYUUOW75YD3DENIPYMO263E6NL2NFHI/', 'name': 'FEDORA-2019-ab7d22a466', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3WRUPZVT2MWFUEMVGTRAGDOBHLNMGK5R/', 'name': 'FEDORA-2019-d7f8995451', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TTXSLRZI5BCQT3H5KALG3DHUWUMNPDX2/', 'name': 'FEDORA-2019-7a06c0e6b4', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/', 'name': 'FEDORA-2020-e795f92d79', 'refsource': 'FEDORA', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-415'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:libgd:libgd:2.2.5:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The GD Graphics Library (aka LibGD) 2.2.5 has a double free in the gdImage*Ptr() functions in gd_gif_out.c, gd_jpeg.c, and gd_wbmp.c. NOTE: PHP is unaffected.'}] | 2019-04-05T00:29Z | 2019-01-28T08:29Z | Double Free | The product calls free() twice on the same memory address, potentially leading to modification of unexpected memory locations. | When a program calls free() twice with the same argument, the program's memory management data structures become corrupted. This corruption can cause the program to crash or, in some circumstances, cause two later calls to malloc() to return the same pointer. If malloc() returns the same value twice and the program later gives the attacker control over the data that is written into this doubly-allocated memory, the program becomes vulnerable to a buffer overflow attack.
| https://cwe.mitre.org/data/definitions/415.html | 0 | Christoph M. Becker | 2019-01-19 10:35:39+01:00 | Sync with upstream
Even though libgd/libgd#492 is not a relevant bug fix for PHP, since
the binding doesn't use the `gdImage*Ptr()` functions at all, we're
porting the fix to stay in sync here. | 089f7c0bc28d399b0420aa6ef058e4c1c120b2ae | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | gdImageGifCtx | gdImageGifCtx( gdImagePtr im , gdIOCtxPtr out) | ['im', 'out'] | void gdImageGifCtx(gdImagePtr im, gdIOCtxPtr out)
{
gdImagePtr pim = 0, tim = im;
int interlace, BitsPerPixel;
interlace = im->interlace;
if (im->trueColor) {
/* Expensive, but the only way that produces an
acceptable result: mix down to a palette
based temporary image. */
pim = gdImageCreatePaletteFromTrueColor(im, 1, 256);
if (!pim) {
return;
}
tim = pim;
}
BitsPerPixel = colorstobpp(tim->colorsTotal);
/* All set, let's do it. */
GIFEncode(
out, tim->sx, tim->sy, tim->interlace, 0, tim->transparent, BitsPerPixel,
tim->red, tim->green, tim->blue, tim);
if (pim) {
/* Destroy palette based temporary image. */
gdImageDestroy( pim);
}
} | 121 | True | 1 |
CVE-2019-6978 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | False | [{'url': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'name': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/issues/492', 'name': 'https://github.com/libgd/libgd/issues/492', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'name': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/01/msg00028.html', 'name': '[debian-lts-announce] 20190130 [SECURITY] [DLA 1651-1] libgd2 security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://www.debian.org/security/2019/dsa-4384', 'name': 'DSA-4384', 'refsource': 'DEBIAN', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3900-1/', 'name': 'USN-3900-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/201903-18', 'name': 'GLSA-201903-18', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00025.html', 'name': 'openSUSE-SU-2019:1148', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00031.html', 'name': 'openSUSE-SU-2019:1140', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2722', 'name': 'RHSA-2019:2722', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TEYUUOW75YD3DENIPYMO263E6NL2NFHI/', 'name': 'FEDORA-2019-ab7d22a466', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3WRUPZVT2MWFUEMVGTRAGDOBHLNMGK5R/', 'name': 'FEDORA-2019-d7f8995451', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TTXSLRZI5BCQT3H5KALG3DHUWUMNPDX2/', 'name': 'FEDORA-2019-7a06c0e6b4', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/', 'name': 'FEDORA-2020-e795f92d79', 'refsource': 'FEDORA', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-415'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:libgd:libgd:2.2.5:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The GD Graphics Library (aka LibGD) 2.2.5 has a double free in the gdImage*Ptr() functions in gd_gif_out.c, gd_jpeg.c, and gd_wbmp.c. NOTE: PHP is unaffected.'}] | 2019-04-05T00:29Z | 2019-01-28T08:29Z | Double Free | The product calls free() twice on the same memory address, potentially leading to modification of unexpected memory locations. | When a program calls free() twice with the same argument, the program's memory management data structures become corrupted. This corruption can cause the program to crash or, in some circumstances, cause two later calls to malloc() to return the same pointer. If malloc() returns the same value twice and the program later gives the attacker control over the data that is written into this doubly-allocated memory, the program becomes vulnerable to a buffer overflow attack.
| https://cwe.mitre.org/data/definitions/415.html | 0 | Christoph M. Becker | 2019-01-19 10:35:39+01:00 | Sync with upstream
Even though libgd/libgd#492 is not a relevant bug fix for PHP, since
the binding doesn't use the `gdImage*Ptr()` functions at all, we're
porting the fix to stay in sync here. | 089f7c0bc28d399b0420aa6ef058e4c1c120b2ae | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | gdImageGifPtr | gdImageGifPtr( gdImagePtr im , int * size) | ['im', 'size'] | void * gdImageGifPtr (gdImagePtr im, int *size)
{
void *rv;
gdIOCtx *out = gdNewDynamicCtx (2048, NULL);
gdImageGifCtx (im, out);
rv = gdDPExtractData (out, size);
out->gd_free (out);
return rv;
} | 52 | True | 1 |
CVE-2019-6978 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | False | [{'url': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'name': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/issues/492', 'name': 'https://github.com/libgd/libgd/issues/492', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'name': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/01/msg00028.html', 'name': '[debian-lts-announce] 20190130 [SECURITY] [DLA 1651-1] libgd2 security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://www.debian.org/security/2019/dsa-4384', 'name': 'DSA-4384', 'refsource': 'DEBIAN', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3900-1/', 'name': 'USN-3900-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/201903-18', 'name': 'GLSA-201903-18', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00025.html', 'name': 'openSUSE-SU-2019:1148', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00031.html', 'name': 'openSUSE-SU-2019:1140', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2722', 'name': 'RHSA-2019:2722', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TEYUUOW75YD3DENIPYMO263E6NL2NFHI/', 'name': 'FEDORA-2019-ab7d22a466', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3WRUPZVT2MWFUEMVGTRAGDOBHLNMGK5R/', 'name': 'FEDORA-2019-d7f8995451', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TTXSLRZI5BCQT3H5KALG3DHUWUMNPDX2/', 'name': 'FEDORA-2019-7a06c0e6b4', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/', 'name': 'FEDORA-2020-e795f92d79', 'refsource': 'FEDORA', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-415'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:libgd:libgd:2.2.5:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The GD Graphics Library (aka LibGD) 2.2.5 has a double free in the gdImage*Ptr() functions in gd_gif_out.c, gd_jpeg.c, and gd_wbmp.c. NOTE: PHP is unaffected.'}] | 2019-04-05T00:29Z | 2019-01-28T08:29Z | Double Free | The product calls free() twice on the same memory address, potentially leading to modification of unexpected memory locations. | When a program calls free() twice with the same argument, the program's memory management data structures become corrupted. This corruption can cause the program to crash or, in some circumstances, cause two later calls to malloc() to return the same pointer. If malloc() returns the same value twice and the program later gives the attacker control over the data that is written into this doubly-allocated memory, the program becomes vulnerable to a buffer overflow attack.
| https://cwe.mitre.org/data/definitions/415.html | 0 | Christoph M. Becker | 2019-01-19 10:35:39+01:00 | Sync with upstream
Even though libgd/libgd#492 is not a relevant bug fix for PHP, since
the binding doesn't use the `gdImage*Ptr()` functions at all, we're
porting the fix to stay in sync here. | 089f7c0bc28d399b0420aa6ef058e4c1c120b2ae | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | gdImageJpegCtx | gdImageJpegCtx( gdImagePtr im , gdIOCtx * outfile , int quality) | ['im', 'outfile', 'quality'] | void gdImageJpegCtx (gdImagePtr im, gdIOCtx * outfile, int quality)
{
struct jpeg_compress_struct cinfo;
struct jpeg_error_mgr jerr;
int i, j, jidx;
/* volatile so we can gdFree it on return from longjmp */
volatile JSAMPROW row = 0;
JSAMPROW rowptr[1];
jmpbuf_wrapper jmpbufw;
JDIMENSION nlines;
char comment[255];
memset (&cinfo, 0, sizeof (cinfo));
memset (&jerr, 0, sizeof (jerr));
cinfo.err = jpeg_std_error (&jerr);
cinfo.client_data = &jmpbufw;
if (setjmp (jmpbufw.jmpbuf) != 0) {
/* we're here courtesy of longjmp */
if (row) {
gdFree (row);
}
return;
}
cinfo.err->error_exit = fatal_jpeg_error;
jpeg_create_compress (&cinfo);
cinfo.image_width = im->sx;
cinfo.image_height = im->sy;
cinfo.input_components = 3; /* # of color components per pixel */
cinfo.in_color_space = JCS_RGB; /* colorspace of input image */
jpeg_set_defaults (&cinfo);
cinfo.density_unit = 1;
cinfo.X_density = im->res_x;
cinfo.Y_density = im->res_y;
if (quality >= 0) {
jpeg_set_quality (&cinfo, quality, TRUE);
}
/* If user requests interlace, translate that to progressive JPEG */
if (gdImageGetInterlaced (im)) {
jpeg_simple_progression (&cinfo);
}
jpeg_gdIOCtx_dest (&cinfo, outfile);
row = (JSAMPROW) safe_emalloc(cinfo.image_width * cinfo.input_components, sizeof(JSAMPLE), 0);
memset(row, 0, cinfo.image_width * cinfo.input_components * sizeof(JSAMPLE));
rowptr[0] = row;
jpeg_start_compress (&cinfo, TRUE);
if (quality >= 0) {
snprintf(comment, sizeof(comment)-1, "CREATOR: gd-jpeg v%s (using IJG JPEG v%d), quality = %d\n", GD_JPEG_VERSION, JPEG_LIB_VERSION, quality);
} else {
snprintf(comment, sizeof(comment)-1, "CREATOR: gd-jpeg v%s (using IJG JPEG v%d), default quality\n", GD_JPEG_VERSION, JPEG_LIB_VERSION);
}
jpeg_write_marker (&cinfo, JPEG_COM, (unsigned char *) comment, (unsigned int) strlen (comment));
if (im->trueColor) {
#if BITS_IN_JSAMPLE == 12
gd_error("gd-jpeg: error: jpeg library was compiled for 12-bit precision. This is mostly useless, because JPEGs on the web are 8-bit and such versions of the jpeg library won't read or write them. GD doesn't support these unusual images. Edit your jmorecfg.h file to specify the correct precision and completely 'make clean' and 'make install' libjpeg again. Sorry");
goto error;
#endif /* BITS_IN_JSAMPLE == 12 */
for (i = 0; i < im->sy; i++) {
for (jidx = 0, j = 0; j < im->sx; j++) {
int val = im->tpixels[i][j];
row[jidx++] = gdTrueColorGetRed (val);
row[jidx++] = gdTrueColorGetGreen (val);
row[jidx++] = gdTrueColorGetBlue (val);
}
nlines = jpeg_write_scanlines (&cinfo, rowptr, 1);
if (nlines != 1) {
gd_error_ex(GD_WARNING, "gd_jpeg: warning: jpeg_write_scanlines returns %u -- expected 1", nlines);
}
}
} else {
for (i = 0; i < im->sy; i++) {
for (jidx = 0, j = 0; j < im->sx; j++) {
int idx = im->pixels[i][j];
/* NB: Although gd RGB values are ints, their max value is
* 255 (see the documentation for gdImageColorAllocate())
* -- perfect for 8-bit JPEG encoding (which is the norm)
*/
#if BITS_IN_JSAMPLE == 8
row[jidx++] = im->red[idx];
row[jidx++] = im->green[idx];
row[jidx++] = im->blue[idx];
#elif BITS_IN_JSAMPLE == 12
row[jidx++] = im->red[idx] << 4;
row[jidx++] = im->green[idx] << 4;
row[jidx++] = im->blue[idx] << 4;
#else
#error IJG JPEG library BITS_IN_JSAMPLE value must be 8 or 12
#endif
}
nlines = jpeg_write_scanlines (&cinfo, rowptr, 1);
if (nlines != 1) {
gd_error_ex(GD_WARNING, "gd_jpeg: warning: jpeg_write_scanlines returns %u -- expected 1", nlines);
}
}
}
jpeg_finish_compress (&cinfo);
jpeg_destroy_compress (&cinfo);
gdFree (row);
} | 680 | True | 1 |
CVE-2019-6978 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | False | [{'url': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'name': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/issues/492', 'name': 'https://github.com/libgd/libgd/issues/492', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'name': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/01/msg00028.html', 'name': '[debian-lts-announce] 20190130 [SECURITY] [DLA 1651-1] libgd2 security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://www.debian.org/security/2019/dsa-4384', 'name': 'DSA-4384', 'refsource': 'DEBIAN', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3900-1/', 'name': 'USN-3900-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/201903-18', 'name': 'GLSA-201903-18', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00025.html', 'name': 'openSUSE-SU-2019:1148', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00031.html', 'name': 'openSUSE-SU-2019:1140', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2722', 'name': 'RHSA-2019:2722', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TEYUUOW75YD3DENIPYMO263E6NL2NFHI/', 'name': 'FEDORA-2019-ab7d22a466', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3WRUPZVT2MWFUEMVGTRAGDOBHLNMGK5R/', 'name': 'FEDORA-2019-d7f8995451', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TTXSLRZI5BCQT3H5KALG3DHUWUMNPDX2/', 'name': 'FEDORA-2019-7a06c0e6b4', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/', 'name': 'FEDORA-2020-e795f92d79', 'refsource': 'FEDORA', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-415'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:libgd:libgd:2.2.5:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The GD Graphics Library (aka LibGD) 2.2.5 has a double free in the gdImage*Ptr() functions in gd_gif_out.c, gd_jpeg.c, and gd_wbmp.c. NOTE: PHP is unaffected.'}] | 2019-04-05T00:29Z | 2019-01-28T08:29Z | Double Free | The product calls free() twice on the same memory address, potentially leading to modification of unexpected memory locations. | When a program calls free() twice with the same argument, the program's memory management data structures become corrupted. This corruption can cause the program to crash or, in some circumstances, cause two later calls to malloc() to return the same pointer. If malloc() returns the same value twice and the program later gives the attacker control over the data that is written into this doubly-allocated memory, the program becomes vulnerable to a buffer overflow attack.
| https://cwe.mitre.org/data/definitions/415.html | 0 | Christoph M. Becker | 2019-01-19 10:35:39+01:00 | Sync with upstream
Even though libgd/libgd#492 is not a relevant bug fix for PHP, since
the binding doesn't use the `gdImage*Ptr()` functions at all, we're
porting the fix to stay in sync here. | 089f7c0bc28d399b0420aa6ef058e4c1c120b2ae | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | gdImageJpegPtr | gdImageJpegPtr( gdImagePtr im , int * size , int quality) | ['im', 'size', 'quality'] | void *gdImageJpegPtr (gdImagePtr im, int *size, int quality)
{
void *rv;
gdIOCtx *out = gdNewDynamicCtx (2048, NULL);
gdImageJpegCtx (im, out, quality);
rv = gdDPExtractData (out, size);
out->gd_free (out);
return rv;
} | 57 | True | 1 |
CVE-2019-6978 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | False | [{'url': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'name': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/issues/492', 'name': 'https://github.com/libgd/libgd/issues/492', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'name': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/01/msg00028.html', 'name': '[debian-lts-announce] 20190130 [SECURITY] [DLA 1651-1] libgd2 security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://www.debian.org/security/2019/dsa-4384', 'name': 'DSA-4384', 'refsource': 'DEBIAN', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3900-1/', 'name': 'USN-3900-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/201903-18', 'name': 'GLSA-201903-18', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00025.html', 'name': 'openSUSE-SU-2019:1148', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00031.html', 'name': 'openSUSE-SU-2019:1140', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2722', 'name': 'RHSA-2019:2722', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TEYUUOW75YD3DENIPYMO263E6NL2NFHI/', 'name': 'FEDORA-2019-ab7d22a466', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3WRUPZVT2MWFUEMVGTRAGDOBHLNMGK5R/', 'name': 'FEDORA-2019-d7f8995451', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TTXSLRZI5BCQT3H5KALG3DHUWUMNPDX2/', 'name': 'FEDORA-2019-7a06c0e6b4', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/', 'name': 'FEDORA-2020-e795f92d79', 'refsource': 'FEDORA', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-415'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:libgd:libgd:2.2.5:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The GD Graphics Library (aka LibGD) 2.2.5 has a double free in the gdImage*Ptr() functions in gd_gif_out.c, gd_jpeg.c, and gd_wbmp.c. NOTE: PHP is unaffected.'}] | 2019-04-05T00:29Z | 2019-01-28T08:29Z | Double Free | The product calls free() twice on the same memory address, potentially leading to modification of unexpected memory locations. | When a program calls free() twice with the same argument, the program's memory management data structures become corrupted. This corruption can cause the program to crash or, in some circumstances, cause two later calls to malloc() to return the same pointer. If malloc() returns the same value twice and the program later gives the attacker control over the data that is written into this doubly-allocated memory, the program becomes vulnerable to a buffer overflow attack.
| https://cwe.mitre.org/data/definitions/415.html | 0 | Christoph M. Becker | 2019-01-19 10:35:39+01:00 | Sync with upstream
Even though libgd/libgd#492 is not a relevant bug fix for PHP, since
the binding doesn't use the `gdImage*Ptr()` functions at all, we're
porting the fix to stay in sync here. | 089f7c0bc28d399b0420aa6ef058e4c1c120b2ae | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | gdImageWBMPCtx | gdImageWBMPCtx( gdImagePtr image , int fg , gdIOCtx * out) | ['image', 'fg', 'out'] | void gdImageWBMPCtx (gdImagePtr image, int fg, gdIOCtx * out)
{
int x, y, pos;
Wbmp *wbmp;
/* create the WBMP */
if ((wbmp = createwbmp (gdImageSX (image), gdImageSY (image), WBMP_WHITE)) == NULL) {
gd_error("Could not create WBMP");
return;
}
/* fill up the WBMP structure */
pos = 0;
for (y = 0; y < gdImageSY(image); y++) {
for (x = 0; x < gdImageSX(image); x++) {
if (gdImageGetPixel (image, x, y) == fg) {
wbmp->bitmap[pos] = WBMP_BLACK;
}
pos++;
}
}
/* write the WBMP to a gd file descriptor */
if (writewbmp (wbmp, &gd_putout, out)) {
gd_error("Could not save WBMP");
}
/* des submitted this bugfix: gdFree the memory. */
freewbmp(wbmp);
} | 148 | True | 1 |
CVE-2019-6978 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:P/A:P | NETWORK | LOW | NONE | PARTIAL | PARTIAL | PARTIAL | 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | HIGH | HIGH | HIGH | 9.8 | CRITICAL | 3.9 | 5.9 | False | [{'url': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'name': 'https://github.com/php/php-src/commit/089f7c0bc28d399b0420aa6ef058e4c1c120b2ae', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/issues/492', 'name': 'https://github.com/libgd/libgd/issues/492', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'name': 'https://github.com/libgd/libgd/commit/553702980ae89c83f2d6e254d62cf82e204956d0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/01/msg00028.html', 'name': '[debian-lts-announce] 20190130 [SECURITY] [DLA 1651-1] libgd2 security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://www.debian.org/security/2019/dsa-4384', 'name': 'DSA-4384', 'refsource': 'DEBIAN', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3900-1/', 'name': 'USN-3900-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/201903-18', 'name': 'GLSA-201903-18', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00025.html', 'name': 'openSUSE-SU-2019:1148', 'refsource': 'SUSE', 'tags': []}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-04/msg00031.html', 'name': 'openSUSE-SU-2019:1140', 'refsource': 'SUSE', 'tags': []}, {'url': 'https://access.redhat.com/errata/RHSA-2019:2722', 'name': 'RHSA-2019:2722', 'refsource': 'REDHAT', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TEYUUOW75YD3DENIPYMO263E6NL2NFHI/', 'name': 'FEDORA-2019-ab7d22a466', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3WRUPZVT2MWFUEMVGTRAGDOBHLNMGK5R/', 'name': 'FEDORA-2019-d7f8995451', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/TTXSLRZI5BCQT3H5KALG3DHUWUMNPDX2/', 'name': 'FEDORA-2019-7a06c0e6b4', 'refsource': 'FEDORA', 'tags': []}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/', 'name': 'FEDORA-2020-e795f92d79', 'refsource': 'FEDORA', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-415'}]}] | HIGH | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:libgd:libgd:2.2.5:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'The GD Graphics Library (aka LibGD) 2.2.5 has a double free in the gdImage*Ptr() functions in gd_gif_out.c, gd_jpeg.c, and gd_wbmp.c. NOTE: PHP is unaffected.'}] | 2019-04-05T00:29Z | 2019-01-28T08:29Z | Double Free | The product calls free() twice on the same memory address, potentially leading to modification of unexpected memory locations. | When a program calls free() twice with the same argument, the program's memory management data structures become corrupted. This corruption can cause the program to crash or, in some circumstances, cause two later calls to malloc() to return the same pointer. If malloc() returns the same value twice and the program later gives the attacker control over the data that is written into this doubly-allocated memory, the program becomes vulnerable to a buffer overflow attack.
| https://cwe.mitre.org/data/definitions/415.html | 0 | Christoph M. Becker | 2019-01-19 10:35:39+01:00 | Sync with upstream
Even though libgd/libgd#492 is not a relevant bug fix for PHP, since
the binding doesn't use the `gdImage*Ptr()` functions at all, we're
porting the fix to stay in sync here. | 089f7c0bc28d399b0420aa6ef058e4c1c120b2ae | False | php/php-src | The PHP Interpreter | 2011-06-16 01:52:25 | 2022-08-26 15:58:00 | https://www.php.net | php | 34244.0 | 7277.0 | gdImageWBMPPtr | gdImageWBMPPtr( gdImagePtr im , int * size , int fg) | ['im', 'size', 'fg'] | void * gdImageWBMPPtr (gdImagePtr im, int *size, int fg)
{
void *rv;
gdIOCtx *out = gdNewDynamicCtx(2048, NULL);
gdImageWBMPCtx(im, fg, out);
rv = gdDPExtractData(out, size);
out->gd_free(out);
return rv;
} | 57 | True | 1 |
CVE-2019-17177 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/202005-07', 'name': 'GLSA-202005-07', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc0:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'libfreerdp/codec/region.c in FreeRDP through 1.1.x and 2.x through 2.0.0-rc4 has memory leaks because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Missing Release of Memory after Effective Lifetime | The software does not sufficiently track and release allocated memory after it has been used, which slowly consumes remaining memory. | This is often triggered by improper handling of malformed data or unexpectedly interrupted sessions. In some languages, developers are responsible for tracking memory allocation and releasing the memory. If there are no more pointers or references to the memory, then it can no longer be tracked and identified for release.
| https://cwe.mitre.org/data/definitions/401.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | tr_esc_str | tr_esc_str( LPCSTR arg , bool format) | ['arg', 'format'] | LPSTR tr_esc_str(LPCSTR arg, bool format)
{
LPSTR tmp = NULL;
size_t cs = 0, x, ds, len;
size_t s;
if (NULL == arg)
return NULL;
s = strlen(arg);
/* Find trailing whitespaces */
while ((s > 0) && isspace(arg[s - 1]))
s--;
/* Prepare a initial buffer with the size of the result string. */
ds = s + 1;
if (s)
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not allocate string buffer.\n");
exit(-2);
}
/* Copy character for character and check, if it is necessary to escape. */
memset(tmp, 0, ds * sizeof(CHAR));
for (x = 0; x < s; x++)
{
switch (arg[x])
{
case '<':
len = format ? 13 : 4;
ds += len - 1;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-3);
}
if (format)
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<replaceable>", len);
else
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<", len);
cs += len;
break;
case '>':
len = format ? 14 : 4;
ds += len - 1;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-4);
}
if (format)
/* coverity[buffer_size] */
strncpy(&tmp[cs], "</replaceable>", len);
else
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<", len);
cs += len;
break;
case '\'':
ds += 5;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-5);
}
tmp[cs++] = '&';
tmp[cs++] = 'a';
tmp[cs++] = 'p';
tmp[cs++] = 'o';
tmp[cs++] = 's';
tmp[cs++] = ';';
break;
case '"':
ds += 5;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-6);
}
tmp[cs++] = '&';
tmp[cs++] = 'q';
tmp[cs++] = 'u';
tmp[cs++] = 'o';
tmp[cs++] = 't';
tmp[cs++] = ';';
break;
case '&':
ds += 4;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-7);
}
tmp[cs++] = '&';
tmp[cs++] = 'a';
tmp[cs++] = 'm';
tmp[cs++] = 'p';
tmp[cs++] = ';';
break;
default:
tmp[cs++] = arg[x];
break;
}
/* Assure, the string is '\0' terminated. */
tmp[ds - 1] = '\0';
}
return tmp;
} | 640 | True | 1 |
CVE-2019-17178 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-252'}, {'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:lodev:lodepng:*:*:*:*:*:*:*:*', 'versionEndIncluding': '2019-09-28', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'HuffmanTree_makeFromFrequencies in lodepng.c in LodePNG through 2019-09-28, as used in WinPR in FreeRDP and other products, has a memory leak because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Unchecked Return Value | The software does not check the return value from a method or function, which can prevent it from detecting unexpected states and conditions. | Two common programmer assumptions are "this function call can never fail" and "it doesn't matter if this function call fails". If an attacker can force the function to fail or otherwise return a value that is not expected, then the subsequent program logic could lead to a vulnerability, because the software is not in a state that the programmer assumes. For example, if the program calls a function to drop privileges but does not check the return code to ensure that privileges were successfully dropped, then the program will continue to operate with the higher privileges.
| https://cwe.mitre.org/data/definitions/252.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | tr_esc_str | tr_esc_str( LPCSTR arg , bool format) | ['arg', 'format'] | LPSTR tr_esc_str(LPCSTR arg, bool format)
{
LPSTR tmp = NULL;
size_t cs = 0, x, ds, len;
size_t s;
if (NULL == arg)
return NULL;
s = strlen(arg);
/* Find trailing whitespaces */
while ((s > 0) && isspace(arg[s - 1]))
s--;
/* Prepare a initial buffer with the size of the result string. */
ds = s + 1;
if (s)
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not allocate string buffer.\n");
exit(-2);
}
/* Copy character for character and check, if it is necessary to escape. */
memset(tmp, 0, ds * sizeof(CHAR));
for (x = 0; x < s; x++)
{
switch (arg[x])
{
case '<':
len = format ? 13 : 4;
ds += len - 1;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-3);
}
if (format)
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<replaceable>", len);
else
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<", len);
cs += len;
break;
case '>':
len = format ? 14 : 4;
ds += len - 1;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-4);
}
if (format)
/* coverity[buffer_size] */
strncpy(&tmp[cs], "</replaceable>", len);
else
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<", len);
cs += len;
break;
case '\'':
ds += 5;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-5);
}
tmp[cs++] = '&';
tmp[cs++] = 'a';
tmp[cs++] = 'p';
tmp[cs++] = 'o';
tmp[cs++] = 's';
tmp[cs++] = ';';
break;
case '"':
ds += 5;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-6);
}
tmp[cs++] = '&';
tmp[cs++] = 'q';
tmp[cs++] = 'u';
tmp[cs++] = 'o';
tmp[cs++] = 't';
tmp[cs++] = ';';
break;
case '&':
ds += 4;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-7);
}
tmp[cs++] = '&';
tmp[cs++] = 'a';
tmp[cs++] = 'm';
tmp[cs++] = 'p';
tmp[cs++] = ';';
break;
default:
tmp[cs++] = arg[x];
break;
}
/* Assure, the string is '\0' terminated. */
tmp[ds - 1] = '\0';
}
return tmp;
} | 640 | True | 1 |
CVE-2019-17178 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-252'}, {'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:lodev:lodepng:*:*:*:*:*:*:*:*', 'versionEndIncluding': '2019-09-28', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'HuffmanTree_makeFromFrequencies in lodepng.c in LodePNG through 2019-09-28, as used in WinPR in FreeRDP and other products, has a memory leak because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Missing Release of Memory after Effective Lifetime | The software does not sufficiently track and release allocated memory after it has been used, which slowly consumes remaining memory. | This is often triggered by improper handling of malformed data or unexpectedly interrupted sessions. In some languages, developers are responsible for tracking memory allocation and releasing the memory. If there are no more pointers or references to the memory, then it can no longer be tracked and identified for release.
| https://cwe.mitre.org/data/definitions/401.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | tr_esc_str | tr_esc_str( LPCSTR arg , bool format) | ['arg', 'format'] | LPSTR tr_esc_str(LPCSTR arg, bool format)
{
LPSTR tmp = NULL;
size_t cs = 0, x, ds, len;
size_t s;
if (NULL == arg)
return NULL;
s = strlen(arg);
/* Find trailing whitespaces */
while ((s > 0) && isspace(arg[s - 1]))
s--;
/* Prepare a initial buffer with the size of the result string. */
ds = s + 1;
if (s)
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not allocate string buffer.\n");
exit(-2);
}
/* Copy character for character and check, if it is necessary to escape. */
memset(tmp, 0, ds * sizeof(CHAR));
for (x = 0; x < s; x++)
{
switch (arg[x])
{
case '<':
len = format ? 13 : 4;
ds += len - 1;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-3);
}
if (format)
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<replaceable>", len);
else
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<", len);
cs += len;
break;
case '>':
len = format ? 14 : 4;
ds += len - 1;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-4);
}
if (format)
/* coverity[buffer_size] */
strncpy(&tmp[cs], "</replaceable>", len);
else
/* coverity[buffer_size] */
strncpy(&tmp[cs], "<", len);
cs += len;
break;
case '\'':
ds += 5;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-5);
}
tmp[cs++] = '&';
tmp[cs++] = 'a';
tmp[cs++] = 'p';
tmp[cs++] = 'o';
tmp[cs++] = 's';
tmp[cs++] = ';';
break;
case '"':
ds += 5;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-6);
}
tmp[cs++] = '&';
tmp[cs++] = 'q';
tmp[cs++] = 'u';
tmp[cs++] = 'o';
tmp[cs++] = 't';
tmp[cs++] = ';';
break;
case '&':
ds += 4;
tmp = (LPSTR)realloc(tmp, ds * sizeof(CHAR));
if (NULL == tmp)
{
fprintf(stderr, "Could not reallocate string buffer.\n");
exit(-7);
}
tmp[cs++] = '&';
tmp[cs++] = 'a';
tmp[cs++] = 'm';
tmp[cs++] = 'p';
tmp[cs++] = ';';
break;
default:
tmp[cs++] = arg[x];
break;
}
/* Assure, the string is '\0' terminated. */
tmp[ds - 1] = '\0';
}
return tmp;
} | 640 | True | 1 |
CVE-2019-17177 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/202005-07', 'name': 'GLSA-202005-07', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc0:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'libfreerdp/codec/region.c in FreeRDP through 1.1.x and 2.x through 2.0.0-rc4 has memory leaks because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Missing Release of Memory after Effective Lifetime | The software does not sufficiently track and release allocated memory after it has been used, which slowly consumes remaining memory. | This is often triggered by improper handling of malformed data or unexpectedly interrupted sessions. In some languages, developers are responsible for tracking memory allocation and releasing the memory. If there are no more pointers or references to the memory, then it can no longer be tracked and identified for release.
| https://cwe.mitre.org/data/definitions/401.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | region16_simplify_bands | region16_simplify_bands( REGION16 * region) | ['region'] | static BOOL region16_simplify_bands(REGION16* region)
{
/** Simplify consecutive bands that touch and have the same items
*
* ==================== ====================
* | 1 | | 2 | | | | |
* ==================== | | | |
* | 1 | | 2 | ====> | 1 | | 2 |
* ==================== | | | |
* | 1 | | 2 | | | | |
* ==================== ====================
*
*/
RECTANGLE_16* band1, *band2, *endPtr, *endBand, *tmp;
int nbRects, finalNbRects;
int bandItems, toMove;
finalNbRects = nbRects = region16_n_rects(region);
if (nbRects < 2)
return TRUE;
band1 = region16_rects_noconst(region);
endPtr = band1 + nbRects;
do
{
band2 = next_band(band1, endPtr, &bandItems);
if (band2 == endPtr)
break;
if ((band1->bottom == band2->top) && band_match(band1, band2, endPtr))
{
/* adjust the bottom of band1 items */
tmp = band1;
while (tmp < band2)
{
tmp->bottom = band2->bottom;
tmp++;
}
/* override band2, we don't move band1 pointer as the band after band2
* may be merged too */
endBand = band2 + bandItems;
toMove = (endPtr - endBand) * sizeof(RECTANGLE_16);
if (toMove)
MoveMemory(band2, endBand, toMove);
finalNbRects -= bandItems;
endPtr -= bandItems;
}
else
{
band1 = band2;
}
}
while (TRUE);
if (finalNbRects != nbRects)
{
int allocSize = sizeof(REGION16_DATA) + (finalNbRects * sizeof(RECTANGLE_16));
region->data = realloc(region->data, allocSize);
if (!region->data)
{
region->data = &empty_region;
return FALSE;
}
region->data->nbRects = finalNbRects;
region->data->size = allocSize;
}
return TRUE;
} | 262 | True | 1 |
CVE-2019-17178 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-252'}, {'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:lodev:lodepng:*:*:*:*:*:*:*:*', 'versionEndIncluding': '2019-09-28', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'HuffmanTree_makeFromFrequencies in lodepng.c in LodePNG through 2019-09-28, as used in WinPR in FreeRDP and other products, has a memory leak because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Unchecked Return Value | The software does not check the return value from a method or function, which can prevent it from detecting unexpected states and conditions. | Two common programmer assumptions are "this function call can never fail" and "it doesn't matter if this function call fails". If an attacker can force the function to fail or otherwise return a value that is not expected, then the subsequent program logic could lead to a vulnerability, because the software is not in a state that the programmer assumes. For example, if the program calls a function to drop privileges but does not check the return code to ensure that privileges were successfully dropped, then the program will continue to operate with the higher privileges.
| https://cwe.mitre.org/data/definitions/252.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | region16_simplify_bands | region16_simplify_bands( REGION16 * region) | ['region'] | static BOOL region16_simplify_bands(REGION16* region)
{
/** Simplify consecutive bands that touch and have the same items
*
* ==================== ====================
* | 1 | | 2 | | | | |
* ==================== | | | |
* | 1 | | 2 | ====> | 1 | | 2 |
* ==================== | | | |
* | 1 | | 2 | | | | |
* ==================== ====================
*
*/
RECTANGLE_16* band1, *band2, *endPtr, *endBand, *tmp;
int nbRects, finalNbRects;
int bandItems, toMove;
finalNbRects = nbRects = region16_n_rects(region);
if (nbRects < 2)
return TRUE;
band1 = region16_rects_noconst(region);
endPtr = band1 + nbRects;
do
{
band2 = next_band(band1, endPtr, &bandItems);
if (band2 == endPtr)
break;
if ((band1->bottom == band2->top) && band_match(band1, band2, endPtr))
{
/* adjust the bottom of band1 items */
tmp = band1;
while (tmp < band2)
{
tmp->bottom = band2->bottom;
tmp++;
}
/* override band2, we don't move band1 pointer as the band after band2
* may be merged too */
endBand = band2 + bandItems;
toMove = (endPtr - endBand) * sizeof(RECTANGLE_16);
if (toMove)
MoveMemory(band2, endBand, toMove);
finalNbRects -= bandItems;
endPtr -= bandItems;
}
else
{
band1 = band2;
}
}
while (TRUE);
if (finalNbRects != nbRects)
{
int allocSize = sizeof(REGION16_DATA) + (finalNbRects * sizeof(RECTANGLE_16));
region->data = realloc(region->data, allocSize);
if (!region->data)
{
region->data = &empty_region;
return FALSE;
}
region->data->nbRects = finalNbRects;
region->data->size = allocSize;
}
return TRUE;
} | 262 | True | 1 |
CVE-2019-17178 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-252'}, {'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:lodev:lodepng:*:*:*:*:*:*:*:*', 'versionEndIncluding': '2019-09-28', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'HuffmanTree_makeFromFrequencies in lodepng.c in LodePNG through 2019-09-28, as used in WinPR in FreeRDP and other products, has a memory leak because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Missing Release of Memory after Effective Lifetime | The software does not sufficiently track and release allocated memory after it has been used, which slowly consumes remaining memory. | This is often triggered by improper handling of malformed data or unexpectedly interrupted sessions. In some languages, developers are responsible for tracking memory allocation and releasing the memory. If there are no more pointers or references to the memory, then it can no longer be tracked and identified for release.
| https://cwe.mitre.org/data/definitions/401.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | region16_simplify_bands | region16_simplify_bands( REGION16 * region) | ['region'] | static BOOL region16_simplify_bands(REGION16* region)
{
/** Simplify consecutive bands that touch and have the same items
*
* ==================== ====================
* | 1 | | 2 | | | | |
* ==================== | | | |
* | 1 | | 2 | ====> | 1 | | 2 |
* ==================== | | | |
* | 1 | | 2 | | | | |
* ==================== ====================
*
*/
RECTANGLE_16* band1, *band2, *endPtr, *endBand, *tmp;
int nbRects, finalNbRects;
int bandItems, toMove;
finalNbRects = nbRects = region16_n_rects(region);
if (nbRects < 2)
return TRUE;
band1 = region16_rects_noconst(region);
endPtr = band1 + nbRects;
do
{
band2 = next_band(band1, endPtr, &bandItems);
if (band2 == endPtr)
break;
if ((band1->bottom == band2->top) && band_match(band1, band2, endPtr))
{
/* adjust the bottom of band1 items */
tmp = band1;
while (tmp < band2)
{
tmp->bottom = band2->bottom;
tmp++;
}
/* override band2, we don't move band1 pointer as the band after band2
* may be merged too */
endBand = band2 + bandItems;
toMove = (endPtr - endBand) * sizeof(RECTANGLE_16);
if (toMove)
MoveMemory(band2, endBand, toMove);
finalNbRects -= bandItems;
endPtr -= bandItems;
}
else
{
band1 = band2;
}
}
while (TRUE);
if (finalNbRects != nbRects)
{
int allocSize = sizeof(REGION16_DATA) + (finalNbRects * sizeof(RECTANGLE_16));
region->data = realloc(region->data, allocSize);
if (!region->data)
{
region->data = &empty_region;
return FALSE;
}
region->data->nbRects = finalNbRects;
region->data->size = allocSize;
}
return TRUE;
} | 262 | True | 1 |
CVE-2019-17177 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/202005-07', 'name': 'GLSA-202005-07', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc0:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'libfreerdp/codec/region.c in FreeRDP through 1.1.x and 2.x through 2.0.0-rc4 has memory leaks because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Missing Release of Memory after Effective Lifetime | The software does not sufficiently track and release allocated memory after it has been used, which slowly consumes remaining memory. | This is often triggered by improper handling of malformed data or unexpectedly interrupted sessions. In some languages, developers are responsible for tracking memory allocation and releasing the memory. If there are no more pointers or references to the memory, then it can no longer be tracked and identified for release.
| https://cwe.mitre.org/data/definitions/401.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | region16_union_rect | region16_union_rect( REGION16 * dst , const REGION16 * src , const RECTANGLE_16 * rect) | ['dst', 'src', 'rect'] | BOOL region16_union_rect(REGION16* dst, const REGION16* src, const RECTANGLE_16* rect)
{
const RECTANGLE_16* srcExtents;
RECTANGLE_16* dstExtents;
const RECTANGLE_16* currentBand, *endSrcRect, *nextBand;
REGION16_DATA* newItems = NULL;
RECTANGLE_16* dstRect = NULL;
UINT32 usedRects, srcNbRects;
UINT16 topInterBand;
assert(src);
assert(src->data);
assert(dst);
srcExtents = region16_extents(src);
dstExtents = region16_extents_noconst(dst);
if (!region16_n_rects(src))
{
/* source is empty, so the union is rect */
dst->extents = *rect;
dst->data = allocateRegion(1);
if (!dst->data)
return FALSE;
dstRect = region16_rects_noconst(dst);
dstRect->top = rect->top;
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = rect->bottom;
return TRUE;
}
newItems = allocateRegion((1 + region16_n_rects(src)) * 4);
if (!newItems)
return FALSE;
dstRect = (RECTANGLE_16*)(&newItems[1]);
usedRects = 0;
/* adds the piece of rect that is on the top of src */
if (rect->top < srcExtents->top)
{
dstRect->top = rect->top;
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = MIN(srcExtents->top, rect->bottom);
usedRects++;
dstRect++;
}
/* treat possibly overlapping region */
currentBand = region16_rects(src, &srcNbRects);
endSrcRect = currentBand + srcNbRects;
while (currentBand < endSrcRect)
{
if ((currentBand->bottom <= rect->top) || (rect->bottom <= currentBand->top) ||
rectangle_contained_in_band(currentBand, endSrcRect, rect))
{
/* no overlap between rect and the band, rect is totally below or totally above
* the current band, or rect is already covered by an item of the band.
* let's copy all the rectangles from this band
+----+
| | rect (case 1)
+----+
=================
band of srcRect
=================
+----+
| | rect (case 2)
+----+
*/
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
currentBand->top, currentBand->bottom,
NULL, &usedRects,
&nextBand, &dstRect);
topInterBand = rect->top;
}
else
{
/* rect overlaps the band:
| | | |
====^=================| |==| |=========================== band
| top split | | | |
v | 1 | | 2 |
^ | | | | +----+ +----+
| merge zone | | | | | | | 4 |
v +----+ | | | | +----+
^ | | | 3 |
| bottom split | | | |
====v=========================| |==| |===================
| | | |
possible cases:
1) no top split, merge zone then a bottom split. The band will be splitted
in two
2) not band split, only the merge zone, band merged with rect but not splitted
3) a top split, the merge zone and no bottom split. The band will be split
in two
4) a top split, the merge zone and also a bottom split. The band will be
splitted in 3, but the coalesce algorithm may merge the created bands
*/
UINT16 mergeTop = currentBand->top;
UINT16 mergeBottom = currentBand->bottom;
/* test if we need a top split, case 3 and 4 */
if (rect->top > currentBand->top)
{
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
currentBand->top, rect->top,
NULL, &usedRects,
&nextBand, &dstRect);
mergeTop = rect->top;
}
/* do the merge zone (all cases) */
if (rect->bottom < currentBand->bottom)
mergeBottom = rect->bottom;
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
mergeTop, mergeBottom,
rect, &usedRects,
&nextBand, &dstRect);
/* test if we need a bottom split, case 1 and 4 */
if (rect->bottom < currentBand->bottom)
{
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
mergeBottom, currentBand->bottom,
NULL, &usedRects,
&nextBand, &dstRect);
}
topInterBand = currentBand->bottom;
}
/* test if a piece of rect should be inserted as a new band between
* the current band and the next one. band n and n+1 shouldn't touch.
*
* ==============================================================
* band n
* +------+ +------+
* ===========| rect |====================| |===============
* | | +------+ | |
* +------+ | rect | | rect |
* +------+ | |
* =======================================| |================
* +------+ band n+1
* ===============================================================
*
*/
if ((nextBand < endSrcRect) && (nextBand->top != currentBand->bottom) &&
(rect->bottom > currentBand->bottom) && (rect->top < nextBand->top))
{
dstRect->right = rect->right;
dstRect->left = rect->left;
dstRect->top = topInterBand;
dstRect->bottom = MIN(nextBand->top, rect->bottom);
dstRect++;
usedRects++;
}
currentBand = nextBand;
}
/* adds the piece of rect that is below src */
if (srcExtents->bottom < rect->bottom)
{
dstRect->top = MAX(srcExtents->bottom, rect->top);
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = rect->bottom;
usedRects++;
dstRect++;
}
if ((src == dst) && (src->data->size > 0) && (src->data != &empty_region))
free(src->data);
dstExtents->top = MIN(rect->top, srcExtents->top);
dstExtents->left = MIN(rect->left, srcExtents->left);
dstExtents->bottom = MAX(rect->bottom, srcExtents->bottom);
dstExtents->right = MAX(rect->right, srcExtents->right);
newItems->size = sizeof(REGION16_DATA) + (usedRects * sizeof(RECTANGLE_16));
dst->data = realloc(newItems, newItems->size);
if (!dst->data)
{
free(newItems);
return FALSE;
}
dst->data->nbRects = usedRects;
return region16_simplify_bands(dst);
} | 804 | True | 1 |
CVE-2019-17178 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-252'}, {'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:lodev:lodepng:*:*:*:*:*:*:*:*', 'versionEndIncluding': '2019-09-28', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'HuffmanTree_makeFromFrequencies in lodepng.c in LodePNG through 2019-09-28, as used in WinPR in FreeRDP and other products, has a memory leak because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Unchecked Return Value | The software does not check the return value from a method or function, which can prevent it from detecting unexpected states and conditions. | Two common programmer assumptions are "this function call can never fail" and "it doesn't matter if this function call fails". If an attacker can force the function to fail or otherwise return a value that is not expected, then the subsequent program logic could lead to a vulnerability, because the software is not in a state that the programmer assumes. For example, if the program calls a function to drop privileges but does not check the return code to ensure that privileges were successfully dropped, then the program will continue to operate with the higher privileges.
| https://cwe.mitre.org/data/definitions/252.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | region16_union_rect | region16_union_rect( REGION16 * dst , const REGION16 * src , const RECTANGLE_16 * rect) | ['dst', 'src', 'rect'] | BOOL region16_union_rect(REGION16* dst, const REGION16* src, const RECTANGLE_16* rect)
{
const RECTANGLE_16* srcExtents;
RECTANGLE_16* dstExtents;
const RECTANGLE_16* currentBand, *endSrcRect, *nextBand;
REGION16_DATA* newItems = NULL;
RECTANGLE_16* dstRect = NULL;
UINT32 usedRects, srcNbRects;
UINT16 topInterBand;
assert(src);
assert(src->data);
assert(dst);
srcExtents = region16_extents(src);
dstExtents = region16_extents_noconst(dst);
if (!region16_n_rects(src))
{
/* source is empty, so the union is rect */
dst->extents = *rect;
dst->data = allocateRegion(1);
if (!dst->data)
return FALSE;
dstRect = region16_rects_noconst(dst);
dstRect->top = rect->top;
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = rect->bottom;
return TRUE;
}
newItems = allocateRegion((1 + region16_n_rects(src)) * 4);
if (!newItems)
return FALSE;
dstRect = (RECTANGLE_16*)(&newItems[1]);
usedRects = 0;
/* adds the piece of rect that is on the top of src */
if (rect->top < srcExtents->top)
{
dstRect->top = rect->top;
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = MIN(srcExtents->top, rect->bottom);
usedRects++;
dstRect++;
}
/* treat possibly overlapping region */
currentBand = region16_rects(src, &srcNbRects);
endSrcRect = currentBand + srcNbRects;
while (currentBand < endSrcRect)
{
if ((currentBand->bottom <= rect->top) || (rect->bottom <= currentBand->top) ||
rectangle_contained_in_band(currentBand, endSrcRect, rect))
{
/* no overlap between rect and the band, rect is totally below or totally above
* the current band, or rect is already covered by an item of the band.
* let's copy all the rectangles from this band
+----+
| | rect (case 1)
+----+
=================
band of srcRect
=================
+----+
| | rect (case 2)
+----+
*/
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
currentBand->top, currentBand->bottom,
NULL, &usedRects,
&nextBand, &dstRect);
topInterBand = rect->top;
}
else
{
/* rect overlaps the band:
| | | |
====^=================| |==| |=========================== band
| top split | | | |
v | 1 | | 2 |
^ | | | | +----+ +----+
| merge zone | | | | | | | 4 |
v +----+ | | | | +----+
^ | | | 3 |
| bottom split | | | |
====v=========================| |==| |===================
| | | |
possible cases:
1) no top split, merge zone then a bottom split. The band will be splitted
in two
2) not band split, only the merge zone, band merged with rect but not splitted
3) a top split, the merge zone and no bottom split. The band will be split
in two
4) a top split, the merge zone and also a bottom split. The band will be
splitted in 3, but the coalesce algorithm may merge the created bands
*/
UINT16 mergeTop = currentBand->top;
UINT16 mergeBottom = currentBand->bottom;
/* test if we need a top split, case 3 and 4 */
if (rect->top > currentBand->top)
{
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
currentBand->top, rect->top,
NULL, &usedRects,
&nextBand, &dstRect);
mergeTop = rect->top;
}
/* do the merge zone (all cases) */
if (rect->bottom < currentBand->bottom)
mergeBottom = rect->bottom;
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
mergeTop, mergeBottom,
rect, &usedRects,
&nextBand, &dstRect);
/* test if we need a bottom split, case 1 and 4 */
if (rect->bottom < currentBand->bottom)
{
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
mergeBottom, currentBand->bottom,
NULL, &usedRects,
&nextBand, &dstRect);
}
topInterBand = currentBand->bottom;
}
/* test if a piece of rect should be inserted as a new band between
* the current band and the next one. band n and n+1 shouldn't touch.
*
* ==============================================================
* band n
* +------+ +------+
* ===========| rect |====================| |===============
* | | +------+ | |
* +------+ | rect | | rect |
* +------+ | |
* =======================================| |================
* +------+ band n+1
* ===============================================================
*
*/
if ((nextBand < endSrcRect) && (nextBand->top != currentBand->bottom) &&
(rect->bottom > currentBand->bottom) && (rect->top < nextBand->top))
{
dstRect->right = rect->right;
dstRect->left = rect->left;
dstRect->top = topInterBand;
dstRect->bottom = MIN(nextBand->top, rect->bottom);
dstRect++;
usedRects++;
}
currentBand = nextBand;
}
/* adds the piece of rect that is below src */
if (srcExtents->bottom < rect->bottom)
{
dstRect->top = MAX(srcExtents->bottom, rect->top);
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = rect->bottom;
usedRects++;
dstRect++;
}
if ((src == dst) && (src->data->size > 0) && (src->data != &empty_region))
free(src->data);
dstExtents->top = MIN(rect->top, srcExtents->top);
dstExtents->left = MIN(rect->left, srcExtents->left);
dstExtents->bottom = MAX(rect->bottom, srcExtents->bottom);
dstExtents->right = MAX(rect->right, srcExtents->right);
newItems->size = sizeof(REGION16_DATA) + (usedRects * sizeof(RECTANGLE_16));
dst->data = realloc(newItems, newItems->size);
if (!dst->data)
{
free(newItems);
return FALSE;
}
dst->data->nbRects = usedRects;
return region16_simplify_bands(dst);
} | 804 | True | 1 |
CVE-2019-17178 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-252'}, {'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:lodev:lodepng:*:*:*:*:*:*:*:*', 'versionEndIncluding': '2019-09-28', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'HuffmanTree_makeFromFrequencies in lodepng.c in LodePNG through 2019-09-28, as used in WinPR in FreeRDP and other products, has a memory leak because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Missing Release of Memory after Effective Lifetime | The software does not sufficiently track and release allocated memory after it has been used, which slowly consumes remaining memory. | This is often triggered by improper handling of malformed data or unexpectedly interrupted sessions. In some languages, developers are responsible for tracking memory allocation and releasing the memory. If there are no more pointers or references to the memory, then it can no longer be tracked and identified for release.
| https://cwe.mitre.org/data/definitions/401.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | region16_union_rect | region16_union_rect( REGION16 * dst , const REGION16 * src , const RECTANGLE_16 * rect) | ['dst', 'src', 'rect'] | BOOL region16_union_rect(REGION16* dst, const REGION16* src, const RECTANGLE_16* rect)
{
const RECTANGLE_16* srcExtents;
RECTANGLE_16* dstExtents;
const RECTANGLE_16* currentBand, *endSrcRect, *nextBand;
REGION16_DATA* newItems = NULL;
RECTANGLE_16* dstRect = NULL;
UINT32 usedRects, srcNbRects;
UINT16 topInterBand;
assert(src);
assert(src->data);
assert(dst);
srcExtents = region16_extents(src);
dstExtents = region16_extents_noconst(dst);
if (!region16_n_rects(src))
{
/* source is empty, so the union is rect */
dst->extents = *rect;
dst->data = allocateRegion(1);
if (!dst->data)
return FALSE;
dstRect = region16_rects_noconst(dst);
dstRect->top = rect->top;
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = rect->bottom;
return TRUE;
}
newItems = allocateRegion((1 + region16_n_rects(src)) * 4);
if (!newItems)
return FALSE;
dstRect = (RECTANGLE_16*)(&newItems[1]);
usedRects = 0;
/* adds the piece of rect that is on the top of src */
if (rect->top < srcExtents->top)
{
dstRect->top = rect->top;
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = MIN(srcExtents->top, rect->bottom);
usedRects++;
dstRect++;
}
/* treat possibly overlapping region */
currentBand = region16_rects(src, &srcNbRects);
endSrcRect = currentBand + srcNbRects;
while (currentBand < endSrcRect)
{
if ((currentBand->bottom <= rect->top) || (rect->bottom <= currentBand->top) ||
rectangle_contained_in_band(currentBand, endSrcRect, rect))
{
/* no overlap between rect and the band, rect is totally below or totally above
* the current band, or rect is already covered by an item of the band.
* let's copy all the rectangles from this band
+----+
| | rect (case 1)
+----+
=================
band of srcRect
=================
+----+
| | rect (case 2)
+----+
*/
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
currentBand->top, currentBand->bottom,
NULL, &usedRects,
&nextBand, &dstRect);
topInterBand = rect->top;
}
else
{
/* rect overlaps the band:
| | | |
====^=================| |==| |=========================== band
| top split | | | |
v | 1 | | 2 |
^ | | | | +----+ +----+
| merge zone | | | | | | | 4 |
v +----+ | | | | +----+
^ | | | 3 |
| bottom split | | | |
====v=========================| |==| |===================
| | | |
possible cases:
1) no top split, merge zone then a bottom split. The band will be splitted
in two
2) not band split, only the merge zone, band merged with rect but not splitted
3) a top split, the merge zone and no bottom split. The band will be split
in two
4) a top split, the merge zone and also a bottom split. The band will be
splitted in 3, but the coalesce algorithm may merge the created bands
*/
UINT16 mergeTop = currentBand->top;
UINT16 mergeBottom = currentBand->bottom;
/* test if we need a top split, case 3 and 4 */
if (rect->top > currentBand->top)
{
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
currentBand->top, rect->top,
NULL, &usedRects,
&nextBand, &dstRect);
mergeTop = rect->top;
}
/* do the merge zone (all cases) */
if (rect->bottom < currentBand->bottom)
mergeBottom = rect->bottom;
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
mergeTop, mergeBottom,
rect, &usedRects,
&nextBand, &dstRect);
/* test if we need a bottom split, case 1 and 4 */
if (rect->bottom < currentBand->bottom)
{
region16_copy_band_with_union(dstRect,
currentBand, endSrcRect,
mergeBottom, currentBand->bottom,
NULL, &usedRects,
&nextBand, &dstRect);
}
topInterBand = currentBand->bottom;
}
/* test if a piece of rect should be inserted as a new band between
* the current band and the next one. band n and n+1 shouldn't touch.
*
* ==============================================================
* band n
* +------+ +------+
* ===========| rect |====================| |===============
* | | +------+ | |
* +------+ | rect | | rect |
* +------+ | |
* =======================================| |================
* +------+ band n+1
* ===============================================================
*
*/
if ((nextBand < endSrcRect) && (nextBand->top != currentBand->bottom) &&
(rect->bottom > currentBand->bottom) && (rect->top < nextBand->top))
{
dstRect->right = rect->right;
dstRect->left = rect->left;
dstRect->top = topInterBand;
dstRect->bottom = MIN(nextBand->top, rect->bottom);
dstRect++;
usedRects++;
}
currentBand = nextBand;
}
/* adds the piece of rect that is below src */
if (srcExtents->bottom < rect->bottom)
{
dstRect->top = MAX(srcExtents->bottom, rect->top);
dstRect->left = rect->left;
dstRect->right = rect->right;
dstRect->bottom = rect->bottom;
usedRects++;
dstRect++;
}
if ((src == dst) && (src->data->size > 0) && (src->data != &empty_region))
free(src->data);
dstExtents->top = MIN(rect->top, srcExtents->top);
dstExtents->left = MIN(rect->left, srcExtents->left);
dstExtents->bottom = MAX(rect->bottom, srcExtents->bottom);
dstExtents->right = MAX(rect->right, srcExtents->right);
newItems->size = sizeof(REGION16_DATA) + (usedRects * sizeof(RECTANGLE_16));
dst->data = realloc(newItems, newItems->size);
if (!dst->data)
{
free(newItems);
return FALSE;
}
dst->data->nbRects = usedRects;
return region16_simplify_bands(dst);
} | 804 | True | 1 |
CVE-2019-17177 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://security.gentoo.org/glsa/202005-07', 'name': 'GLSA-202005-07', 'refsource': 'GENTOO', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc4:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc0:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'libfreerdp/codec/region.c in FreeRDP through 1.1.x and 2.x through 2.0.0-rc4 has memory leaks because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Missing Release of Memory after Effective Lifetime | The software does not sufficiently track and release allocated memory after it has been used, which slowly consumes remaining memory. | This is often triggered by improper handling of malformed data or unexpectedly interrupted sessions. In some languages, developers are responsible for tracking memory allocation and releasing the memory. If there are no more pointers or references to the memory, then it can no longer be tracked and identified for release.
| https://cwe.mitre.org/data/definitions/401.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | HuffmanTree_makeFromFrequencies | HuffmanTree_makeFromFrequencies( HuffmanTree * tree , const unsigned * frequencies , size_t mincodes , size_t numcodes , unsigned maxbitlen) | ['tree', 'frequencies', 'mincodes', 'numcodes', 'maxbitlen'] | static unsigned HuffmanTree_makeFromFrequencies(HuffmanTree* tree, const unsigned* frequencies,
size_t mincodes, size_t numcodes, unsigned maxbitlen)
{
unsigned error = 0;
while(!frequencies[numcodes - 1] && numcodes > mincodes) numcodes--; /*trim zeroes*/
tree->maxbitlen = maxbitlen;
tree->numcodes = (unsigned)numcodes; /*number of symbols*/
tree->lengths = (unsigned*)realloc(tree->lengths, numcodes * sizeof(unsigned));
if(!tree->lengths) return 83; /*alloc fail*/
/*initialize all lengths to 0*/
memset(tree->lengths, 0, numcodes * sizeof(unsigned));
error = lodepng_huffman_code_lengths(tree->lengths, frequencies, numcodes, maxbitlen);
if(!error) error = HuffmanTree_makeFromLengths2(tree);
return error;
} | 137 | True | 1 |
CVE-2019-17178 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-252'}, {'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:lodev:lodepng:*:*:*:*:*:*:*:*', 'versionEndIncluding': '2019-09-28', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'HuffmanTree_makeFromFrequencies in lodepng.c in LodePNG through 2019-09-28, as used in WinPR in FreeRDP and other products, has a memory leak because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Unchecked Return Value | The software does not check the return value from a method or function, which can prevent it from detecting unexpected states and conditions. | Two common programmer assumptions are "this function call can never fail" and "it doesn't matter if this function call fails". If an attacker can force the function to fail or otherwise return a value that is not expected, then the subsequent program logic could lead to a vulnerability, because the software is not in a state that the programmer assumes. For example, if the program calls a function to drop privileges but does not check the return code to ensure that privileges were successfully dropped, then the program will continue to operate with the higher privileges.
| https://cwe.mitre.org/data/definitions/252.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | HuffmanTree_makeFromFrequencies | HuffmanTree_makeFromFrequencies( HuffmanTree * tree , const unsigned * frequencies , size_t mincodes , size_t numcodes , unsigned maxbitlen) | ['tree', 'frequencies', 'mincodes', 'numcodes', 'maxbitlen'] | static unsigned HuffmanTree_makeFromFrequencies(HuffmanTree* tree, const unsigned* frequencies,
size_t mincodes, size_t numcodes, unsigned maxbitlen)
{
unsigned error = 0;
while(!frequencies[numcodes - 1] && numcodes > mincodes) numcodes--; /*trim zeroes*/
tree->maxbitlen = maxbitlen;
tree->numcodes = (unsigned)numcodes; /*number of symbols*/
tree->lengths = (unsigned*)realloc(tree->lengths, numcodes * sizeof(unsigned));
if(!tree->lengths) return 83; /*alloc fail*/
/*initialize all lengths to 0*/
memset(tree->lengths, 0, numcodes * sizeof(unsigned));
error = lodepng_huffman_code_lengths(tree->lengths, frequencies, numcodes, maxbitlen);
if(!error) error = HuffmanTree_makeFromLengths2(tree);
return error;
} | 137 | True | 1 |
CVE-2019-17178 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/5645', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00004.html', 'name': 'openSUSE-SU-2019:2604', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2019-12/msg00005.html', 'name': 'openSUSE-SU-2019:2608', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9fee4ae076b1ec97b97efb79ece08d1dab4df29a', 'refsource': 'MISC', 'tags': ['Patch', 'Vendor Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-252'}, {'lang': 'en', 'value': 'CWE-401'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:1.1.0:beta1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.0.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:lodev:lodepng:*:*:*:*:*:*:*:*', 'versionEndIncluding': '2019-09-28', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.0:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'HuffmanTree_makeFromFrequencies in lodepng.c in LodePNG through 2019-09-28, as used in WinPR in FreeRDP and other products, has a memory leak because a supplied realloc pointer (i.e., the first argument to realloc) is also used for a realloc return value.'}] | 2021-07-21T11:39Z | 2019-10-04T17:15Z | Missing Release of Memory after Effective Lifetime | The software does not sufficiently track and release allocated memory after it has been used, which slowly consumes remaining memory. | This is often triggered by improper handling of malformed data or unexpectedly interrupted sessions. In some languages, developers are responsible for tracking memory allocation and releasing the memory. If there are no more pointers or references to the memory, then it can no longer be tracked and identified for release.
| https://cwe.mitre.org/data/definitions/401.html | 0 | Armin Novak | 2019-10-04 14:49:30+02:00 | Fixed #5645: realloc return handling | 9fee4ae076b1ec97b97efb79ece08d1dab4df29a | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | HuffmanTree_makeFromFrequencies | HuffmanTree_makeFromFrequencies( HuffmanTree * tree , const unsigned * frequencies , size_t mincodes , size_t numcodes , unsigned maxbitlen) | ['tree', 'frequencies', 'mincodes', 'numcodes', 'maxbitlen'] | static unsigned HuffmanTree_makeFromFrequencies(HuffmanTree* tree, const unsigned* frequencies,
size_t mincodes, size_t numcodes, unsigned maxbitlen)
{
unsigned error = 0;
while(!frequencies[numcodes - 1] && numcodes > mincodes) numcodes--; /*trim zeroes*/
tree->maxbitlen = maxbitlen;
tree->numcodes = (unsigned)numcodes; /*number of symbols*/
tree->lengths = (unsigned*)realloc(tree->lengths, numcodes * sizeof(unsigned));
if(!tree->lengths) return 83; /*alloc fail*/
/*initialize all lengths to 0*/
memset(tree->lengths, 0, numcodes * sizeof(unsigned));
error = lodepng_huffman_code_lengths(tree->lengths, frequencies, numcodes, maxbitlen);
if(!error) error = HuffmanTree_makeFromLengths2(tree);
return error;
} | 137 | True | 1 |
CVE-2020-11048 | False | False | False | False | AV:N/AC:M/Au:S/C:N/I:N/A:P | NETWORK | MEDIUM | SINGLE | NONE | NONE | PARTIAL | 3.5 | CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:N/I:N/A:L | NETWORK | HIGH | HIGH | NONE | UNCHANGED | NONE | NONE | LOW | 2.2 | LOW | 0.7 | 1.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/6007', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/6007', 'refsource': 'MISC', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hv8w-f2hx-5gcv', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hv8w-f2hx-5gcv', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9301bfe730c66180263248b74353daa99f5a969b', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9301bfe730c66180263248b74353daa99f5a969b', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4382-1/', 'name': 'USN-4382-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2020/08/msg00054.html', 'name': '[debian-lts-announce] 20200829 [SECURITY] [DLA 2356-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | LOW | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionStartIncluding': '1.0.0', 'versionEndExcluding': '2.0.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:19.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:esm:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP after 1.0 and before 2.0.0, there is an out-of-bounds read. It only allows to abort a session. No data extraction is possible. This has been fixed in 2.0.0.'}] | 2022-07-01T17:19Z | 2020-05-07T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-03-31 09:14:55+02:00 | Fixed #6007: Boundary checks in rdp_read_flow_control_pdu | 9301bfe730c66180263248b74353daa99f5a969b | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | rdp_read_flow_control_pdu | rdp_read_flow_control_pdu( wStream * s , UINT16 * type) | ['s', 'type'] | void rdp_read_flow_control_pdu(wStream* s, UINT16* type)
{
/*
* Read flow control PDU - documented in FlowPDU section in T.128
* http://www.itu.int/rec/T-REC-T.128-199802-S/en
* The specification for the PDU has pad8bits listed BEFORE pduTypeFlow.
* However, so far pad8bits has always been observed to arrive AFTER pduTypeFlow.
* Switched the order of these two fields to match this observation.
*/
UINT8 pduType;
Stream_Read_UINT8(s, pduType); /* pduTypeFlow */
*type = pduType;
Stream_Seek_UINT8(s); /* pad8bits */
Stream_Seek_UINT8(s); /* flowIdentifier */
Stream_Seek_UINT8(s); /* flowNumber */
Stream_Seek_UINT16(s); /* pduSource */
} | 47 | True | 1 |
CVE-2020-11048 | False | False | False | False | AV:N/AC:M/Au:S/C:N/I:N/A:P | NETWORK | MEDIUM | SINGLE | NONE | NONE | PARTIAL | 3.5 | CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:N/I:N/A:L | NETWORK | HIGH | HIGH | NONE | UNCHANGED | NONE | NONE | LOW | 2.2 | LOW | 0.7 | 1.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/issues/6007', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/6007', 'refsource': 'MISC', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hv8w-f2hx-5gcv', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hv8w-f2hx-5gcv', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/9301bfe730c66180263248b74353daa99f5a969b', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/9301bfe730c66180263248b74353daa99f5a969b', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4382-1/', 'name': 'USN-4382-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2020/08/msg00054.html', 'name': '[debian-lts-announce] 20200829 [SECURITY] [DLA 2356-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | LOW | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionStartIncluding': '1.0.0', 'versionEndExcluding': '2.0.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:19.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:esm:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP after 1.0 and before 2.0.0, there is an out-of-bounds read. It only allows to abort a session. No data extraction is possible. This has been fixed in 2.0.0.'}] | 2022-07-01T17:19Z | 2020-05-07T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-03-31 09:14:55+02:00 | Fixed #6007: Boundary checks in rdp_read_flow_control_pdu | 9301bfe730c66180263248b74353daa99f5a969b | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | rdp_read_share_control_header | rdp_read_share_control_header( wStream * s , UINT16 * length , UINT16 * type , UINT16 * channel_id) | ['s', 'length', 'type', 'channel_id'] | BOOL rdp_read_share_control_header(wStream* s, UINT16* length, UINT16* type, UINT16* channel_id)
{
if (Stream_GetRemainingLength(s) < 2)
return FALSE;
/* Share Control Header */
Stream_Read_UINT16(s, *length); /* totalLength */
/* If length is 0x8000 then we actually got a flow control PDU that we should ignore
http://msdn.microsoft.com/en-us/library/cc240576.aspx */
if (*length == 0x8000)
{
rdp_read_flow_control_pdu(s, type);
*channel_id = 0;
*length = 8; /* Flow control PDU is 8 bytes */
return TRUE;
}
if (((size_t)*length - 2) > Stream_GetRemainingLength(s))
return FALSE;
Stream_Read_UINT16(s, *type); /* pduType */
*type &= 0x0F; /* type is in the 4 least significant bits */
if (*length > 4)
Stream_Read_UINT16(s, *channel_id); /* pduSource */
else
*channel_id = 0; /* Windows XP can send such short DEACTIVATE_ALL PDUs. */
return TRUE;
} | 126 | True | 1 |
CVE-2020-11046 | False | False | False | False | AV:N/AC:M/Au:S/C:N/I:N/A:P | NETWORK | MEDIUM | SINGLE | NONE | NONE | PARTIAL | 3.5 | CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:N/I:N/A:L | NETWORK | HIGH | HIGH | NONE | UNCHANGED | NONE | NONE | LOW | 2.2 | LOW | 0.7 | 1.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hx48-wmmm-mr5q', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hx48-wmmm-mr5q', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/ed53cd148f43cbab905eaa0f5308c2bf3c48cc37', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/ed53cd148f43cbab905eaa0f5308c2bf3c48cc37', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/issues/6006', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/6006', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4382-1/', 'name': 'USN-4382-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2020/08/msg00054.html', 'name': '[debian-lts-announce] 20200829 [SECURITY] [DLA 2356-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | LOW | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionStartExcluding': '1.0.0', 'versionEndExcluding': '2.0.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:19.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP after 1.0 and before 2.0.0, there is a stream out-of-bounds seek in update_read_synchronize that could lead to a later out-of-bounds read.'}] | 2021-09-14T18:15Z | 2020-05-07T19:15Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | akallabeth | 2020-03-31 09:21:43+02:00 | Fixed #6006: bounds checks in update_read_synchronize | ed53cd148f43cbab905eaa0f5308c2bf3c48cc37 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_read_synchronize | update_read_synchronize( rdpUpdate * update , wStream * s) | ['update', 's'] | static void update_read_synchronize(rdpUpdate* update, wStream* s)
{
WINPR_UNUSED(update);
Stream_Seek_UINT16(s); /* pad2Octets (2 bytes) */
/**
* The Synchronize Update is an artifact from the
* T.128 protocol and should be ignored.
*/
} | 22 | True | 1 |
CVE-2020-11046 | False | False | False | False | AV:N/AC:M/Au:S/C:N/I:N/A:P | NETWORK | MEDIUM | SINGLE | NONE | NONE | PARTIAL | 3.5 | CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:N/I:N/A:L | NETWORK | HIGH | HIGH | NONE | UNCHANGED | NONE | NONE | LOW | 2.2 | LOW | 0.7 | 1.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hx48-wmmm-mr5q', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hx48-wmmm-mr5q', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/ed53cd148f43cbab905eaa0f5308c2bf3c48cc37', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/ed53cd148f43cbab905eaa0f5308c2bf3c48cc37', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/issues/6006', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/6006', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4382-1/', 'name': 'USN-4382-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2020/08/msg00054.html', 'name': '[debian-lts-announce] 20200829 [SECURITY] [DLA 2356-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | LOW | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionStartExcluding': '1.0.0', 'versionEndExcluding': '2.0.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:19.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP after 1.0 and before 2.0.0, there is a stream out-of-bounds seek in update_read_synchronize that could lead to a later out-of-bounds read.'}] | 2021-09-14T18:15Z | 2020-05-07T19:15Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | akallabeth | 2020-03-31 09:21:43+02:00 | Fixed #6006: bounds checks in update_read_synchronize | ed53cd148f43cbab905eaa0f5308c2bf3c48cc37 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_recv | update_recv( rdpUpdate * update , wStream * s) | ['update', 's'] | BOOL update_recv(rdpUpdate* update, wStream* s)
{
BOOL rc = FALSE;
UINT16 updateType;
rdpContext* context = update->context;
if (Stream_GetRemainingLength(s) < 2)
{
WLog_ERR(TAG, "Stream_GetRemainingLength(s) < 2");
return FALSE;
}
Stream_Read_UINT16(s, updateType); /* updateType (2 bytes) */
WLog_Print(update->log, WLOG_TRACE, "%s Update Data PDU", UPDATE_TYPE_STRINGS[updateType]);
if (!update_begin_paint(update))
goto fail;
switch (updateType)
{
case UPDATE_TYPE_ORDERS:
rc = update_recv_orders(update, s);
break;
case UPDATE_TYPE_BITMAP:
{
BITMAP_UPDATE* bitmap_update = update_read_bitmap_update(update, s);
if (!bitmap_update)
{
WLog_ERR(TAG, "UPDATE_TYPE_BITMAP - update_read_bitmap_update() failed");
goto fail;
}
rc = IFCALLRESULT(FALSE, update->BitmapUpdate, context, bitmap_update);
free_bitmap_update(update->context, bitmap_update);
}
break;
case UPDATE_TYPE_PALETTE:
{
PALETTE_UPDATE* palette_update = update_read_palette(update, s);
if (!palette_update)
{
WLog_ERR(TAG, "UPDATE_TYPE_PALETTE - update_read_palette() failed");
goto fail;
}
rc = IFCALLRESULT(FALSE, update->Palette, context, palette_update);
free_palette_update(context, palette_update);
}
break;
case UPDATE_TYPE_SYNCHRONIZE:
update_read_synchronize(update, s);
rc = IFCALLRESULT(TRUE, update->Synchronize, context);
break;
default:
break;
}
fail:
if (!update_end_paint(update))
rc = FALSE;
if (!rc)
{
WLog_ERR(TAG, "UPDATE_TYPE %s [%" PRIu16 "] failed", update_type_to_string(updateType),
updateType);
return FALSE;
}
return TRUE;
} | 291 | True | 1 |
CVE-2020-11058 | False | False | False | False | AV:N/AC:M/Au:S/C:N/I:N/A:P | NETWORK | MEDIUM | SINGLE | NONE | NONE | PARTIAL | 3.5 | CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:N/I:N/A:L | NETWORK | HIGH | HIGH | NONE | UNCHANGED | NONE | NONE | LOW | 2.2 | LOW | 0.7 | 1.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/3627aaf7d289315b614a584afb388f04abfb5bbf', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/3627aaf7d289315b614a584afb388f04abfb5bbf', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/issues/6011', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/6011', 'refsource': 'MISC', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-wjg2-2f82-466g', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-wjg2-2f82-466g', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4382-1/', 'name': 'USN-4382-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2020/08/msg00054.html', 'name': '[debian-lts-announce] 20200829 [SECURITY] [DLA 2356-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-119'}]}] | LOW | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionStartExcluding': '1.1.0', 'versionEndIncluding': '2.0.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:19.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP after 1.1 and before 2.0.0, a stream out-of-bounds seek in rdp_read_font_capability_set could lead to a later out-of-bounds read. As a result, a manipulated client or server might force a disconnect due to an invalid data read. This has been fixed in 2.0.0.'}] | 2021-10-07T17:20Z | 2020-05-12T21:15Z | Improper Restriction of Operations within the Bounds of a Memory Buffer | The software performs operations on a memory buffer, but it can read from or write to a memory location that is outside of the intended boundary of the buffer. |
Certain languages allow direct addressing of memory locations and do not automatically ensure that these locations are valid for the memory buffer that is being referenced. This can cause read or write operations to be performed on memory locations that may be associated with other variables, data structures, or internal program data.
As a result, an attacker may be able to execute arbitrary code, alter the intended control flow, read sensitive information, or cause the system to crash.
| https://cwe.mitre.org/data/definitions/119.html | 0 | akallabeth | 2020-03-31 14:32:01+02:00 | Fixed #6011: Bounds check in rdp_read_font_capability_set | 3627aaf7d289315b614a584afb388f04abfb5bbf | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | rdp_read_font_capability_set | rdp_read_font_capability_set( wStream * s , UINT16 length , rdpSettings * settings) | ['s', 'length', 'settings'] | static BOOL rdp_read_font_capability_set(wStream* s, UINT16 length, rdpSettings* settings)
{
WINPR_UNUSED(settings);
if (length > 4)
Stream_Seek_UINT16(s); /* fontSupportFlags (2 bytes) */
if (length > 6)
Stream_Seek_UINT16(s); /* pad2Octets (2 bytes) */
return TRUE;
} | 45 | True | 1 |
CVE-2020-11044 | False | False | False | False | AV:N/AC:M/Au:S/C:N/I:N/A:P | NETWORK | MEDIUM | SINGLE | NONE | NONE | PARTIAL | 3.5 | CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:N/I:N/A:L | NETWORK | HIGH | HIGH | NONE | UNCHANGED | NONE | NONE | LOW | 2.2 | LOW | 0.7 | 1.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/67c2aa52b2ae0341d469071d1bc8aab91f8d2ed8', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/67c2aa52b2ae0341d469071d1bc8aab91f8d2ed8', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-cgqh-p732-6x2w', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-cgqh-p732-6x2w', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/issues/6013', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/6013', 'refsource': 'MISC', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-415'}]}] | LOW | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionStartExcluding': '1.2.0', 'versionEndExcluding': '2.0.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:19.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP greater than 1.2 and before 2.0.0, a double free in update_read_cache_bitmap_v3_order crashes the client application if corrupted data from a manipulated server is parsed. This has been patched in 2.0.0.'}] | 2022-07-01T17:21Z | 2020-05-07T19:15Z | Double Free | The product calls free() twice on the same memory address, potentially leading to modification of unexpected memory locations. | When a program calls free() twice with the same argument, the program's memory management data structures become corrupted. This corruption can cause the program to crash or, in some circumstances, cause two later calls to malloc() to return the same pointer. If malloc() returns the same value twice and the program later gives the attacker control over the data that is written into this doubly-allocated memory, the program becomes vulnerable to a buffer overflow attack.
| https://cwe.mitre.org/data/definitions/415.html | 0 | akallabeth | 2020-03-31 14:36:40+02:00 | Fixed #6013: Check new length is > 0 | 67c2aa52b2ae0341d469071d1bc8aab91f8d2ed8 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_read_cache_bitmap_v3_order | update_read_cache_bitmap_v3_order( rdpUpdate * update , wStream * s , UINT16 flags) | ['update', 's', 'flags'] | static CACHE_BITMAP_V3_ORDER* update_read_cache_bitmap_v3_order(rdpUpdate* update, wStream* s,
UINT16 flags)
{
BYTE bitsPerPixelId;
BITMAP_DATA_EX* bitmapData;
UINT32 new_len;
BYTE* new_data;
CACHE_BITMAP_V3_ORDER* cache_bitmap_v3;
if (!update || !s)
return NULL;
cache_bitmap_v3 = calloc(1, sizeof(CACHE_BITMAP_V3_ORDER));
if (!cache_bitmap_v3)
goto fail;
cache_bitmap_v3->cacheId = flags & 0x00000003;
cache_bitmap_v3->flags = (flags & 0x0000FF80) >> 7;
bitsPerPixelId = (flags & 0x00000078) >> 3;
cache_bitmap_v3->bpp = CBR23_BPP[bitsPerPixelId];
if (Stream_GetRemainingLength(s) < 21)
goto fail;
Stream_Read_UINT16(s, cache_bitmap_v3->cacheIndex); /* cacheIndex (2 bytes) */
Stream_Read_UINT32(s, cache_bitmap_v3->key1); /* key1 (4 bytes) */
Stream_Read_UINT32(s, cache_bitmap_v3->key2); /* key2 (4 bytes) */
bitmapData = &cache_bitmap_v3->bitmapData;
Stream_Read_UINT8(s, bitmapData->bpp);
if ((bitmapData->bpp < 1) || (bitmapData->bpp > 32))
{
WLog_Print(update->log, WLOG_ERROR, "invalid bpp value %" PRIu32 "", bitmapData->bpp);
goto fail;
}
Stream_Seek_UINT8(s); /* reserved1 (1 byte) */
Stream_Seek_UINT8(s); /* reserved2 (1 byte) */
Stream_Read_UINT8(s, bitmapData->codecID); /* codecID (1 byte) */
Stream_Read_UINT16(s, bitmapData->width); /* width (2 bytes) */
Stream_Read_UINT16(s, bitmapData->height); /* height (2 bytes) */
Stream_Read_UINT32(s, new_len); /* length (4 bytes) */
if (Stream_GetRemainingLength(s) < new_len)
goto fail;
new_data = (BYTE*)realloc(bitmapData->data, new_len);
if (!new_data)
goto fail;
bitmapData->data = new_data;
bitmapData->length = new_len;
Stream_Read(s, bitmapData->data, bitmapData->length);
return cache_bitmap_v3;
fail:
free_cache_bitmap_v3_order(update->context, cache_bitmap_v3);
return NULL;
} | 321 | True | 1 |
CVE-2020-11042 | False | False | False | False | AV:N/AC:M/Au:S/C:P/I:N/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | NONE | PARTIAL | 4.9 | CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:N/A:H | NETWORK | HIGH | HIGH | NONE | UNCHANGED | HIGH | NONE | HIGH | 5.9 | MEDIUM | 0.7 | 5.2 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-9jp6-5vf2-cx2q', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-9jp6-5vf2-cx2q', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b2bc41935e53b0034fe5948aeeab4f32e80f30f', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b2bc41935e53b0034fe5948aeeab4f32e80f30f', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/issues/6010', 'name': 'https://github.com/FreeRDP/FreeRDP/issues/6010', 'refsource': 'MISC', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4379-1/', 'name': 'USN-4379-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4382-1/', 'name': 'USN-4382-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.debian.org/debian-lts-announce/2020/08/msg00054.html', 'name': '[debian-lts-announce] 20200829 [SECURITY] [DLA 2356-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionStartExcluding': '1.1.0', 'versionEndExcluding': '2.0.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:19.10:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:esm:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP greater than 1.1 and before 2.0.0, there is an out-of-bounds read in update_read_icon_info. It allows reading a attacker-defined amount of client memory (32bit unsigned -> 4GB) to an intermediate buffer. This can be used to crash the client or store information for later retrieval. This has been patched in 2.0.0.'}] | 2022-07-01T17:21Z | 2020-05-07T19:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-03-31 09:06:05+02:00 | Fix #6010: Check length in read_icon_info | 6b2bc41935e53b0034fe5948aeeab4f32e80f30f | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_read_icon_info | update_read_icon_info( wStream * s , ICON_INFO * iconInfo) | ['s', 'iconInfo'] | static BOOL update_read_icon_info(wStream* s, ICON_INFO* iconInfo)
{
BYTE* newBitMask;
if (Stream_GetRemainingLength(s) < 8)
return FALSE;
Stream_Read_UINT16(s, iconInfo->cacheEntry); /* cacheEntry (2 bytes) */
Stream_Read_UINT8(s, iconInfo->cacheId); /* cacheId (1 byte) */
Stream_Read_UINT8(s, iconInfo->bpp); /* bpp (1 byte) */
if ((iconInfo->bpp < 1) || (iconInfo->bpp > 32))
{
WLog_ERR(TAG, "invalid bpp value %" PRIu32 "", iconInfo->bpp);
return FALSE;
}
Stream_Read_UINT16(s, iconInfo->width); /* width (2 bytes) */
Stream_Read_UINT16(s, iconInfo->height); /* height (2 bytes) */
/* cbColorTable is only present when bpp is 1, 4 or 8 */
switch (iconInfo->bpp)
{
case 1:
case 4:
case 8:
if (Stream_GetRemainingLength(s) < 2)
return FALSE;
Stream_Read_UINT16(s, iconInfo->cbColorTable); /* cbColorTable (2 bytes) */
break;
default:
iconInfo->cbColorTable = 0;
break;
}
if (Stream_GetRemainingLength(s) < 4)
return FALSE;
Stream_Read_UINT16(s, iconInfo->cbBitsMask); /* cbBitsMask (2 bytes) */
Stream_Read_UINT16(s, iconInfo->cbBitsColor); /* cbBitsColor (2 bytes) */
if (Stream_GetRemainingLength(s) < iconInfo->cbBitsMask + iconInfo->cbBitsColor)
return FALSE;
/* bitsMask */
newBitMask = (BYTE*)realloc(iconInfo->bitsMask, iconInfo->cbBitsMask);
if (!newBitMask)
{
free(iconInfo->bitsMask);
iconInfo->bitsMask = NULL;
return FALSE;
}
iconInfo->bitsMask = newBitMask;
Stream_Read(s, iconInfo->bitsMask, iconInfo->cbBitsMask);
/* colorTable */
if (iconInfo->colorTable == NULL)
{
if (iconInfo->cbColorTable)
{
iconInfo->colorTable = (BYTE*)malloc(iconInfo->cbColorTable);
if (!iconInfo->colorTable)
return FALSE;
}
}
else if (iconInfo->cbColorTable)
{
BYTE* new_tab;
new_tab = (BYTE*)realloc(iconInfo->colorTable, iconInfo->cbColorTable);
if (!new_tab)
{
free(iconInfo->colorTable);
iconInfo->colorTable = NULL;
return FALSE;
}
iconInfo->colorTable = new_tab;
}
else
{
free(iconInfo->colorTable);
iconInfo->colorTable = NULL;
}
if (iconInfo->colorTable)
Stream_Read(s, iconInfo->colorTable, iconInfo->cbColorTable);
/* bitsColor */
newBitMask = (BYTE*)realloc(iconInfo->bitsColor, iconInfo->cbBitsColor);
if (!newBitMask)
{
free(iconInfo->bitsColor);
iconInfo->bitsColor = NULL;
return FALSE;
}
iconInfo->bitsColor = newBitMask;
Stream_Read(s, iconInfo->bitsColor, iconInfo->cbBitsColor);
return TRUE;
} | 465 | True | 1 |
CVE-2020-11087 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-84vj-g73m-chw7', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-84vj-g73m-chw7', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/8241ab42fdf0cc89cf69fc574bf6360c9977a0d4', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/8241ab42fdf0cc89cf69fc574bf6360c9977a0d4', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP less than or equal to 2.0.0, there is an out-of-bound read in ntlm_read_AuthenticateMessage. This has been fixed in 2.1.0.'}] | 2022-07-19T11:20Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:03:05+02:00 | Fixed oob read in ntlm_read_AuthenticateMessage | 8241ab42fdf0cc89cf69fc574bf6360c9977a0d4 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_read_AuthenticateMessage | ntlm_read_AuthenticateMessage( NTLM_CONTEXT * context , PSecBuffer buffer) | ['context', 'buffer'] | SECURITY_STATUS ntlm_read_AuthenticateMessage(NTLM_CONTEXT* context, PSecBuffer buffer)
{
wStream* s;
size_t length;
UINT32 flags;
NTLM_AV_PAIR* AvFlags;
UINT32 PayloadBufferOffset;
NTLM_AUTHENTICATE_MESSAGE* message;
SSPI_CREDENTIALS* credentials = context->credentials;
flags = 0;
AvFlags = NULL;
message = &context->AUTHENTICATE_MESSAGE;
ZeroMemory(message, sizeof(NTLM_AUTHENTICATE_MESSAGE));
s = Stream_New((BYTE*)buffer->pvBuffer, buffer->cbBuffer);
if (!s)
return SEC_E_INTERNAL_ERROR;
if (ntlm_read_message_header(s, (NTLM_MESSAGE_HEADER*)message) < 0)
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
if (message->MessageType != MESSAGE_TYPE_AUTHENTICATE)
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
if (ntlm_read_message_fields(s, &(message->LmChallengeResponse)) <
0) /* LmChallengeResponseFields (8 bytes) */
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
if (ntlm_read_message_fields(s, &(message->NtChallengeResponse)) <
0) /* NtChallengeResponseFields (8 bytes) */
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
if (ntlm_read_message_fields(s, &(message->DomainName)) < 0) /* DomainNameFields (8 bytes) */
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
if (ntlm_read_message_fields(s, &(message->UserName)) < 0) /* UserNameFields (8 bytes) */
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
if (ntlm_read_message_fields(s, &(message->Workstation)) < 0) /* WorkstationFields (8 bytes) */
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
if (ntlm_read_message_fields(s, &(message->EncryptedRandomSessionKey)) <
0) /* EncryptedRandomSessionKeyFields (8 bytes) */
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
Stream_Read_UINT32(s, message->NegotiateFlags); /* NegotiateFlags (4 bytes) */
context->NegotiateKeyExchange =
(message->NegotiateFlags & NTLMSSP_NEGOTIATE_KEY_EXCH) ? TRUE : FALSE;
if ((context->NegotiateKeyExchange && !message->EncryptedRandomSessionKey.Len) ||
(!context->NegotiateKeyExchange && message->EncryptedRandomSessionKey.Len))
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
if (message->NegotiateFlags & NTLMSSP_NEGOTIATE_VERSION)
{
if (ntlm_read_version_info(s, &(message->Version)) < 0) /* Version (8 bytes) */
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
}
PayloadBufferOffset = Stream_GetPosition(s);
if (ntlm_read_message_fields_buffer(s, &(message->DomainName)) < 0) /* DomainName */
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
if (ntlm_read_message_fields_buffer(s, &(message->UserName)) < 0) /* UserName */
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
if (ntlm_read_message_fields_buffer(s, &(message->Workstation)) < 0) /* Workstation */
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
if (ntlm_read_message_fields_buffer(s, &(message->LmChallengeResponse)) <
0) /* LmChallengeResponse */
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
if (ntlm_read_message_fields_buffer(s, &(message->NtChallengeResponse)) <
0) /* NtChallengeResponse */
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
if (message->NtChallengeResponse.Len > 0)
{
size_t cbAvFlags;
wStream* snt =
Stream_New(message->NtChallengeResponse.Buffer, message->NtChallengeResponse.Len);
if (!snt)
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
if (ntlm_read_ntlm_v2_response(snt, &(context->NTLMv2Response)) < 0)
{
Stream_Free(s, FALSE);
Stream_Free(snt, FALSE);
return SEC_E_INVALID_TOKEN;
}
Stream_Free(snt, FALSE);
context->NtChallengeResponse.pvBuffer = message->NtChallengeResponse.Buffer;
context->NtChallengeResponse.cbBuffer = message->NtChallengeResponse.Len;
sspi_SecBufferFree(&(context->ChallengeTargetInfo));
context->ChallengeTargetInfo.pvBuffer = (void*)context->NTLMv2Response.Challenge.AvPairs;
context->ChallengeTargetInfo.cbBuffer = message->NtChallengeResponse.Len - (28 + 16);
CopyMemory(context->ClientChallenge, context->NTLMv2Response.Challenge.ClientChallenge, 8);
AvFlags =
ntlm_av_pair_get(context->NTLMv2Response.Challenge.AvPairs,
context->NTLMv2Response.Challenge.cbAvPairs, MsvAvFlags, &cbAvFlags);
if (AvFlags)
Data_Read_UINT32(ntlm_av_pair_get_value_pointer(AvFlags), flags);
}
if (ntlm_read_message_fields_buffer(s, &(message->EncryptedRandomSessionKey)) <
0) /* EncryptedRandomSessionKey */
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
if (message->EncryptedRandomSessionKey.Len > 0)
{
if (message->EncryptedRandomSessionKey.Len != 16)
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
CopyMemory(context->EncryptedRandomSessionKey, message->EncryptedRandomSessionKey.Buffer,
16);
}
length = Stream_GetPosition(s);
if (!sspi_SecBufferAlloc(&context->AuthenticateMessage, length))
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
CopyMemory(context->AuthenticateMessage.pvBuffer, Stream_Buffer(s), length);
buffer->cbBuffer = length;
Stream_SetPosition(s, PayloadBufferOffset);
if (flags & MSV_AV_FLAGS_MESSAGE_INTEGRITY_CHECK)
{
context->MessageIntegrityCheckOffset = (UINT32)Stream_GetPosition(s);
if (Stream_GetRemainingLength(s) < 16)
{
Stream_Free(s, FALSE);
return SEC_E_INVALID_TOKEN;
}
Stream_Read(s, message->MessageIntegrityCheck, 16);
}
#ifdef WITH_DEBUG_NTLM
WLog_DBG(TAG, "AUTHENTICATE_MESSAGE (length = %" PRIu32 ")",
context->AuthenticateMessage.cbBuffer);
winpr_HexDump(TAG, WLOG_DEBUG, context->AuthenticateMessage.pvBuffer,
context->AuthenticateMessage.cbBuffer);
if (message->NegotiateFlags & NTLMSSP_NEGOTIATE_VERSION)
ntlm_print_version_info(&(message->Version));
ntlm_print_message_fields(&(message->DomainName), "DomainName");
ntlm_print_message_fields(&(message->UserName), "UserName");
ntlm_print_message_fields(&(message->Workstation), "Workstation");
ntlm_print_message_fields(&(message->LmChallengeResponse), "LmChallengeResponse");
ntlm_print_message_fields(&(message->NtChallengeResponse), "NtChallengeResponse");
ntlm_print_message_fields(&(message->EncryptedRandomSessionKey), "EncryptedRandomSessionKey");
ntlm_print_av_pair_list(context->NTLMv2Response.Challenge.AvPairs,
context->NTLMv2Response.Challenge.cbAvPairs);
if (flags & MSV_AV_FLAGS_MESSAGE_INTEGRITY_CHECK)
{
WLog_DBG(TAG, "MessageIntegrityCheck:");
winpr_HexDump(TAG, WLOG_DEBUG, message->MessageIntegrityCheck, 16);
}
#endif
if (message->UserName.Len > 0)
{
credentials->identity.User = (UINT16*)malloc(message->UserName.Len);
if (!credentials->identity.User)
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
CopyMemory(credentials->identity.User, message->UserName.Buffer, message->UserName.Len);
credentials->identity.UserLength = message->UserName.Len / 2;
}
if (message->DomainName.Len > 0)
{
credentials->identity.Domain = (UINT16*)malloc(message->DomainName.Len);
if (!credentials->identity.Domain)
{
Stream_Free(s, FALSE);
return SEC_E_INTERNAL_ERROR;
}
CopyMemory(credentials->identity.Domain, message->DomainName.Buffer,
message->DomainName.Len);
credentials->identity.DomainLength = message->DomainName.Len / 2;
}
Stream_Free(s, FALSE);
/* Computations beyond this point require the NTLM hash of the password */
context->state = NTLM_STATE_COMPLETION;
return SEC_I_COMPLETE_NEEDED;
} | 1326 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:09:22+02:00 | Fixed oob read in parallel_process_irp_create | 795842f4096501fcefc1a7f535ccc8132feb31d7 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | parallel_process_irp_create | parallel_process_irp_create( PARALLEL_DEVICE * parallel , IRP * irp) | ['parallel', 'irp'] | static UINT parallel_process_irp_create(PARALLEL_DEVICE* parallel, IRP* irp)
{
char* path = NULL;
int status;
UINT32 PathLength;
Stream_Seek(irp->input, 28);
/* DesiredAccess(4) AllocationSize(8), FileAttributes(4) */
/* SharedAccess(4) CreateDisposition(4), CreateOptions(4) */
Stream_Read_UINT32(irp->input, PathLength);
status = ConvertFromUnicode(CP_UTF8, 0, (WCHAR*)Stream_Pointer(irp->input), PathLength / 2,
&path, 0, NULL, NULL);
if (status < 1)
if (!(path = (char*)calloc(1, 1)))
{
WLog_ERR(TAG, "calloc failed!");
return CHANNEL_RC_NO_MEMORY;
}
parallel->id = irp->devman->id_sequence++;
parallel->file = open(parallel->path, O_RDWR);
if (parallel->file < 0)
{
irp->IoStatus = STATUS_ACCESS_DENIED;
parallel->id = 0;
}
else
{
/* all read and write operations should be non-blocking */
if (fcntl(parallel->file, F_SETFL, O_NONBLOCK) == -1)
{
}
}
Stream_Write_UINT32(irp->output, parallel->id);
Stream_Write_UINT8(irp->output, 0);
free(path);
return irp->Complete(irp);
} | 211 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | drive_process_irp_write | drive_process_irp_write( DRIVE_DEVICE * drive , IRP * irp) | ['drive', 'irp'] | static UINT drive_process_irp_write(DRIVE_DEVICE* drive, IRP* irp)
{
DRIVE_FILE* file;
UINT32 Length;
UINT64 Offset;
if (!drive || !irp || !irp->input || !irp->output || !irp->Complete)
return ERROR_INVALID_PARAMETER;
if (Stream_GetRemainingLength(irp->input) < 32)
return ERROR_INVALID_DATA;
Stream_Read_UINT32(irp->input, Length);
Stream_Read_UINT64(irp->input, Offset);
Stream_Seek(irp->input, 20); /* Padding */
file = drive_get_file_by_id(drive, irp->FileId);
if (!file)
{
irp->IoStatus = STATUS_UNSUCCESSFUL;
Length = 0;
}
else if (!drive_file_seek(file, Offset))
{
irp->IoStatus = drive_map_windows_err(GetLastError());
Length = 0;
}
else if (!drive_file_write(file, Stream_Pointer(irp->input), Length))
{
irp->IoStatus = drive_map_windows_err(GetLastError());
Length = 0;
}
Stream_Write_UINT32(irp->output, Length);
Stream_Write_UINT8(irp->output, 0); /* Padding */
return irp->Complete(irp);
} | 206 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | printer_process_irp_write | printer_process_irp_write( PRINTER_DEVICE * printer_dev , IRP * irp) | ['printer_dev', 'irp'] | static UINT printer_process_irp_write(PRINTER_DEVICE* printer_dev, IRP* irp)
{
UINT32 Length;
UINT64 Offset;
rdpPrintJob* printjob = NULL;
UINT error = CHANNEL_RC_OK;
Stream_Read_UINT32(irp->input, Length);
Stream_Read_UINT64(irp->input, Offset);
Stream_Seek(irp->input, 20); /* Padding */
if (printer_dev->printer)
printjob = printer_dev->printer->FindPrintJob(printer_dev->printer, irp->FileId);
if (!printjob)
{
irp->IoStatus = STATUS_UNSUCCESSFUL;
Length = 0;
}
else
{
error = printjob->Write(printjob, Stream_Pointer(irp->input), Length);
}
if (error)
{
WLog_ERR(TAG, "printjob->Write failed with error %" PRIu32 "!", error);
return error;
}
Stream_Write_UINT32(irp->output, Length);
Stream_Write_UINT8(irp->output, 0); /* Padding */
return irp->Complete(irp);
} | 163 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | serial_process_irp_create | serial_process_irp_create( SERIAL_DEVICE * serial , IRP * irp) | ['serial', 'irp'] | static UINT serial_process_irp_create(SERIAL_DEVICE* serial, IRP* irp)
{
DWORD DesiredAccess;
DWORD SharedAccess;
DWORD CreateDisposition;
UINT32 PathLength;
if (Stream_GetRemainingLength(irp->input) < 32)
return ERROR_INVALID_DATA;
Stream_Read_UINT32(irp->input, DesiredAccess); /* DesiredAccess (4 bytes) */
Stream_Seek_UINT64(irp->input); /* AllocationSize (8 bytes) */
Stream_Seek_UINT32(irp->input); /* FileAttributes (4 bytes) */
Stream_Read_UINT32(irp->input, SharedAccess); /* SharedAccess (4 bytes) */
Stream_Read_UINT32(irp->input, CreateDisposition); /* CreateDisposition (4 bytes) */
Stream_Seek_UINT32(irp->input); /* CreateOptions (4 bytes) */
Stream_Read_UINT32(irp->input, PathLength); /* PathLength (4 bytes) */
if (Stream_GetRemainingLength(irp->input) < PathLength)
return ERROR_INVALID_DATA;
Stream_Seek(irp->input, PathLength); /* Path (variable) */
assert(PathLength == 0); /* MS-RDPESP 2.2.2.2 */
#ifndef _WIN32
/* Windows 2012 server sends on a first call :
* DesiredAccess = 0x00100080: SYNCHRONIZE | FILE_READ_ATTRIBUTES
* SharedAccess = 0x00000007: FILE_SHARE_DELETE | FILE_SHARE_WRITE | FILE_SHARE_READ
* CreateDisposition = 0x00000001: CREATE_NEW
*
* then Windows 2012 sends :
* DesiredAccess = 0x00120089: SYNCHRONIZE | READ_CONTROL | FILE_READ_ATTRIBUTES |
* FILE_READ_EA | FILE_READ_DATA SharedAccess = 0x00000007: FILE_SHARE_DELETE |
* FILE_SHARE_WRITE | FILE_SHARE_READ CreateDisposition = 0x00000001: CREATE_NEW
*
* assert(DesiredAccess == (GENERIC_READ | GENERIC_WRITE));
* assert(SharedAccess == 0);
* assert(CreateDisposition == OPEN_EXISTING);
*
*/
WLog_Print(serial->log, WLOG_DEBUG,
"DesiredAccess: 0x%" PRIX32 ", SharedAccess: 0x%" PRIX32
", CreateDisposition: 0x%" PRIX32 "",
DesiredAccess, SharedAccess, CreateDisposition);
/* FIXME: As of today only the flags below are supported by CommCreateFileA: */
DesiredAccess = GENERIC_READ | GENERIC_WRITE;
SharedAccess = 0;
CreateDisposition = OPEN_EXISTING;
#endif
serial->hComm =
CreateFile(serial->device.name, DesiredAccess, SharedAccess, NULL, /* SecurityAttributes */
CreateDisposition, 0, /* FlagsAndAttributes */
NULL); /* TemplateFile */
if (!serial->hComm || (serial->hComm == INVALID_HANDLE_VALUE))
{
WLog_Print(serial->log, WLOG_WARN, "CreateFile failure: %s last-error: 0x%08" PRIX32 "",
serial->device.name, GetLastError());
irp->IoStatus = STATUS_UNSUCCESSFUL;
goto error_handle;
}
_comm_setServerSerialDriver(serial->hComm, serial->ServerSerialDriverId);
_comm_set_permissive(serial->hComm, serial->permissive);
/* NOTE: binary mode/raw mode required for the redirection. On
* Linux, CommCreateFileA forces this setting.
*/
/* ZeroMemory(&dcb, sizeof(DCB)); */
/* dcb.DCBlength = sizeof(DCB); */
/* GetCommState(serial->hComm, &dcb); */
/* dcb.fBinary = TRUE; */
/* SetCommState(serial->hComm, &dcb); */
assert(irp->FileId == 0);
irp->FileId = irp->devman->id_sequence++; /* FIXME: why not ((WINPR_COMM*)hComm)->fd? */
irp->IoStatus = STATUS_SUCCESS;
WLog_Print(serial->log, WLOG_DEBUG, "%s (DeviceId: %" PRIu32 ", FileId: %" PRIu32 ") created.",
serial->device.name, irp->device->id, irp->FileId);
error_handle:
Stream_Write_UINT32(irp->output, irp->FileId); /* FileId (4 bytes) */
Stream_Write_UINT8(irp->output, 0); /* Information (1 byte) */
return CHANNEL_RC_OK;
} | 340 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | serial_process_irp_write | serial_process_irp_write( SERIAL_DEVICE * serial , IRP * irp) | ['serial', 'irp'] | static UINT serial_process_irp_write(SERIAL_DEVICE* serial, IRP* irp)
{
UINT32 Length;
UINT64 Offset;
DWORD nbWritten = 0;
if (Stream_GetRemainingLength(irp->input) < 32)
return ERROR_INVALID_DATA;
Stream_Read_UINT32(irp->input, Length); /* Length (4 bytes) */
Stream_Read_UINT64(irp->input, Offset); /* Offset (8 bytes) */
Stream_Seek(irp->input, 20); /* Padding (20 bytes) */
/* MS-RDPESP 3.2.5.1.5: The Offset field is ignored
* assert(Offset == 0);
*
* Using a serial printer, noticed though this field could be
* set.
*/
WLog_Print(serial->log, WLOG_DEBUG, "writing %" PRIu32 " bytes to %s", Length,
serial->device.name);
/* FIXME: CommWriteFile to be replaced by WriteFile */
if (CommWriteFile(serial->hComm, Stream_Pointer(irp->input), Length, &nbWritten, NULL))
{
irp->IoStatus = STATUS_SUCCESS;
}
else
{
WLog_Print(serial->log, WLOG_DEBUG,
"write failure to %s, nbWritten=%" PRIu32 ", last-error: 0x%08" PRIX32 "",
serial->device.name, nbWritten, GetLastError());
irp->IoStatus = _GetLastErrorToIoStatus(serial);
}
WLog_Print(serial->log, WLOG_DEBUG, "%" PRIu32 " bytes written to %s", nbWritten,
serial->device.name);
Stream_Write_UINT32(irp->output, nbWritten); /* Length (4 bytes) */
Stream_Write_UINT8(irp->output, 0); /* Padding (1 byte) */
return CHANNEL_RC_OK;
} | 197 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | rdg_receive_packet | rdg_receive_packet( rdpRdg * rdg) | ['rdg'] | static wStream* rdg_receive_packet(rdpRdg* rdg)
{
wStream* s;
const size_t header = sizeof(RdgPacketHeader);
size_t packetLength;
assert(header <= INT_MAX);
s = Stream_New(NULL, 1024);
if (!s)
return NULL;
if (!rdg_read_all(rdg->tlsOut, Stream_Buffer(s), header))
{
Stream_Free(s, TRUE);
return NULL;
}
Stream_Seek(s, 4);
Stream_Read_UINT32(s, packetLength);
if ((packetLength > INT_MAX) || !Stream_EnsureCapacity(s, packetLength))
{
Stream_Free(s, TRUE);
return NULL;
}
if (!rdg_read_all(rdg->tlsOut, Stream_Buffer(s) + header, (int)packetLength - (int)header))
{
Stream_Free(s, TRUE);
return NULL;
}
Stream_SetLength(s, packetLength);
return s;
} | 168 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | nego_process_negotiation_failure | nego_process_negotiation_failure( rdpNego * nego , wStream * s) | ['nego', 's'] | void nego_process_negotiation_failure(rdpNego* nego, wStream* s)
{
BYTE flags;
UINT16 length;
UINT32 failureCode;
WLog_DBG(TAG, "RDP_NEG_FAILURE");
Stream_Read_UINT8(s, flags);
Stream_Read_UINT16(s, length);
Stream_Read_UINT32(s, failureCode);
switch (failureCode)
{
case SSL_REQUIRED_BY_SERVER:
WLog_WARN(TAG, "Error: SSL_REQUIRED_BY_SERVER");
break;
case SSL_NOT_ALLOWED_BY_SERVER:
WLog_WARN(TAG, "Error: SSL_NOT_ALLOWED_BY_SERVER");
nego->sendNegoData = TRUE;
break;
case SSL_CERT_NOT_ON_SERVER:
WLog_ERR(TAG, "Error: SSL_CERT_NOT_ON_SERVER");
nego->sendNegoData = TRUE;
break;
case INCONSISTENT_FLAGS:
WLog_ERR(TAG, "Error: INCONSISTENT_FLAGS");
break;
case HYBRID_REQUIRED_BY_SERVER:
WLog_WARN(TAG, "Error: HYBRID_REQUIRED_BY_SERVER");
break;
default:
WLog_ERR(TAG, "Error: Unknown protocol security error %" PRIu32 "", failureCode);
break;
}
nego->state = NEGO_STATE_FAIL;
} | 148 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | nego_process_negotiation_request | nego_process_negotiation_request( rdpNego * nego , wStream * s) | ['nego', 's'] | void nego_process_negotiation_request(rdpNego* nego, wStream* s)
{
BYTE flags;
UINT16 length;
Stream_Read_UINT8(s, flags);
Stream_Read_UINT16(s, length);
Stream_Read_UINT32(s, nego->RequestedProtocols);
WLog_DBG(TAG, "RDP_NEG_REQ: RequestedProtocol: 0x%08" PRIX32 "", nego->RequestedProtocols);
nego->state = NEGO_STATE_FINAL;
} | 60 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | nego_process_negotiation_response | nego_process_negotiation_response( rdpNego * nego , wStream * s) | ['nego', 's'] | void nego_process_negotiation_response(rdpNego* nego, wStream* s)
{
UINT16 length;
WLog_DBG(TAG, "RDP_NEG_RSP");
if (Stream_GetRemainingLength(s) < 7)
{
WLog_ERR(TAG, "Invalid RDP_NEG_RSP");
nego->state = NEGO_STATE_FAIL;
return;
}
Stream_Read_UINT8(s, nego->flags);
Stream_Read_UINT16(s, length);
Stream_Read_UINT32(s, nego->SelectedProtocol);
nego->state = NEGO_STATE_FINAL;
} | 79 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | nego_read_request | nego_read_request( rdpNego * nego , wStream * s) | ['nego', 's'] | BOOL nego_read_request(rdpNego* nego, wStream* s)
{
BYTE li;
BYTE type;
UINT16 length;
if (!tpkt_read_header(s, &length))
return FALSE;
if (!tpdu_read_connection_request(s, &li, length))
return FALSE;
if (li != Stream_GetRemainingLength(s) + 6)
{
WLog_ERR(TAG, "Incorrect TPDU length indicator.");
return FALSE;
}
if (!nego_read_request_token_or_cookie(nego, s))
{
WLog_ERR(TAG, "Failed to parse routing token or cookie.");
return FALSE;
}
if (Stream_GetRemainingLength(s) >= 8)
{
/* rdpNegData (optional) */
Stream_Read_UINT8(s, type); /* Type */
if (type != TYPE_RDP_NEG_REQ)
{
WLog_ERR(TAG, "Incorrect negotiation request type %" PRIu8 "", type);
return FALSE;
}
nego_process_negotiation_request(nego, s);
}
return tpkt_ensure_stream_consumed(s, length);
} | 151 | True | 1 |
CVE-2020-11089 | False | False | False | True | AV:N/AC:M/Au:S/C:P/I:P/A:P | NETWORK | MEDIUM | SINGLE | PARTIAL | PARTIAL | PARTIAL | 6.0 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L | NETWORK | LOW | LOW | REQUIRED | UNCHANGED | LOW | LOW | LOW | 5.5 | MEDIUM | 2.1 | 3.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-hfc7-c5gv-8c2h', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/795842f4096501fcefc1a7f535ccc8132feb31d7', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6b485b146a1b9d6ce72dfd7b5f36456c166e7a16', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before 2.1.0, there is an out-of-bound read in irp functions (parallel_process_irp_create, serial_process_irp_create, drive_process_irp_write, printer_process_irp_write, rdpei_recv_pdu, serial_process_irp_write). This has been fixed in 2.1.0.'}] | 2022-07-19T11:52Z | 2020-05-29T20:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-04-15 17:21:46+02:00 | Fixed oob read in irp_write and similar | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | nego_recv | nego_recv( rdpTransport * transport , wStream * s , void * extra) | ['transport', 's', 'extra'] | int nego_recv(rdpTransport* transport, wStream* s, void* extra)
{
BYTE li;
BYTE type;
UINT16 length;
rdpNego* nego = (rdpNego*)extra;
if (!tpkt_read_header(s, &length))
return -1;
if (!tpdu_read_connection_confirm(s, &li, length))
return -1;
if (li > 6)
{
/* rdpNegData (optional) */
Stream_Read_UINT8(s, type); /* Type */
switch (type)
{
case TYPE_RDP_NEG_RSP:
nego_process_negotiation_response(nego, s);
WLog_DBG(TAG, "selected_protocol: %" PRIu32 "", nego->SelectedProtocol);
/* enhanced security selected ? */
if (nego->SelectedProtocol)
{
if ((nego->SelectedProtocol == PROTOCOL_HYBRID) &&
(!nego->EnabledProtocols[PROTOCOL_HYBRID]))
{
nego->state = NEGO_STATE_FAIL;
}
if ((nego->SelectedProtocol == PROTOCOL_SSL) &&
(!nego->EnabledProtocols[PROTOCOL_SSL]))
{
nego->state = NEGO_STATE_FAIL;
}
}
else if (!nego->EnabledProtocols[PROTOCOL_RDP])
{
nego->state = NEGO_STATE_FAIL;
}
break;
case TYPE_RDP_NEG_FAILURE:
nego_process_negotiation_failure(nego, s);
break;
}
}
else if (li == 6)
{
WLog_DBG(TAG, "no rdpNegData");
if (!nego->EnabledProtocols[PROTOCOL_RDP])
nego->state = NEGO_STATE_FAIL;
else
nego->state = NEGO_STATE_FINAL;
}
else
{
WLog_ERR(TAG, "invalid negotiation response");
nego->state = NEGO_STATE_FAIL;
}
if (!tpkt_ensure_stream_consumed(s, length))
return -1;
return 0;
} | 280 | True | 1 |
CVE-2020-11098 | False | False | False | False | AV:N/AC:M/Au:N/C:P/I:N/A:P | NETWORK | MEDIUM | NONE | PARTIAL | NONE | PARTIAL | 5.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-jr57-f58x-hjmv', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-jr57-f58x-hjmv', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/c0fd449ec0870b050d350d6d844b1ea6dad4bc7d', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/c0fd449ec0870b050d350d6d844b1ea6dad4bc7d', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is an out-of-bound read in glyph_cache_put. This affects all FreeRDP clients with `+glyph-cache` option enabled This is fixed in version 2.1.2.'}] | 2022-07-19T11:36Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-25 09:42:02+02:00 | Fixed Out-of-bound read in glyph_cache_put
CVE-2020-11098 thanks to @antonio-morales for finding this. | c0fd449ec0870b050d350d6d844b1ea6dad4bc7d | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | glyph_cache_put | glyph_cache_put( rdpGlyphCache * glyphCache , UINT32 id , UINT32 index , rdpGlyph * glyph) | ['glyphCache', 'id', 'index', 'glyph'] | BOOL glyph_cache_put(rdpGlyphCache* glyphCache, UINT32 id, UINT32 index, rdpGlyph* glyph)
{
rdpGlyph* prevGlyph;
if (id > 9)
{
WLog_ERR(TAG, "invalid glyph cache id: %" PRIu32 "", id);
return FALSE;
}
if (index > glyphCache->glyphCache[id].number)
{
WLog_ERR(TAG, "invalid glyph cache index: %" PRIu32 " in cache id: %" PRIu32 "", index, id);
return FALSE;
}
WLog_Print(glyphCache->log, WLOG_DEBUG, "GlyphCachePut: id: %" PRIu32 " index: %" PRIu32 "", id,
index);
prevGlyph = glyphCache->glyphCache[id].entries[index];
if (prevGlyph)
prevGlyph->Free(glyphCache->context, prevGlyph);
glyphCache->glyphCache[id].entries[index] = glyph;
return TRUE;
} | 142 | True | 1 |
CVE-2020-4031 | False | False | False | False | AV:N/AC:M/Au:N/C:N/I:N/A:P | NETWORK | MEDIUM | NONE | NONE | NONE | PARTIAL | 4.3 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/6d86e20e1e7caaab4f0c7f89e36d32914dbccc52', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/6d86e20e1e7caaab4f0c7f89e36d32914dbccc52', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-gwcq-hpq2-m74g', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-gwcq-hpq2-m74g', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-416'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a use-after-free in gdi_SelectObject. All FreeRDP clients using compatibility mode with /relax-order-checks are affected. This is fixed in version 2.1.2.'}] | 2022-06-01T18:48Z | 2020-06-22T22:15Z | Use After Free | Referencing memory after it has been freed can cause a program to crash, use unexpected values, or execute code. |
The use of previously-freed memory can have any number of adverse consequences, ranging from the corruption of valid data to the execution of arbitrary code, depending on the instantiation and timing of the flaw. The simplest way data corruption may occur involves the system's reuse of the freed memory. Use-after-free errors have two common and sometimes overlapping causes:
Error conditions and other exceptional circumstances.
Confusion over which part of the program is responsible for freeing the memory.
In this scenario, the memory in question is allocated to another pointer validly at some point after it has been freed. The original pointer to the freed memory is used again and points to somewhere within the new allocation. As the data is changed, it corrupts the validly used memory; this induces undefined behavior in the process.
If the newly allocated data chances to hold a class, in C++ for example, various function pointers may be scattered within the heap data. If one of these function pointers is overwritten with an address to valid shellcode, execution of arbitrary code can be achieved.
| https://cwe.mitre.org/data/definitions/416.html | 0 | akallabeth | 2020-05-25 14:03:12+02:00 | Fixed double free | 6d86e20e1e7caaab4f0c7f89e36d32914dbccc52 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | shadow_server_start | shadow_server_start( rdpShadowServer * server) | ['server'] | int shadow_server_start(rdpShadowServer* server)
{
BOOL ipc;
BOOL status;
WSADATA wsaData;
if (!server)
return -1;
if (WSAStartup(MAKEWORD(2, 2), &wsaData) != 0)
return -1;
#ifndef _WIN32
signal(SIGPIPE, SIG_IGN);
#endif
server->screen = shadow_screen_new(server);
if (!server->screen)
{
WLog_ERR(TAG, "screen_new failed");
return -1;
}
server->capture = shadow_capture_new(server);
if (!server->capture)
{
WLog_ERR(TAG, "capture_new failed");
return -1;
}
/* Bind magic:
*
* emtpy ... bind TCP all
* <local path> ... bind local (IPC)
* bind-socket,<address> ... bind TCP to specified interface
*/
ipc = server->ipcSocket && (strncmp(bind_address, server->ipcSocket,
strnlen(bind_address, sizeof(bind_address))) != 0);
if (!ipc)
{
size_t x, count;
char** list = CommandLineParseCommaSeparatedValuesEx(NULL, server->ipcSocket, &count);
if (!list || (count <= 1))
{
free(list);
if (server->ipcSocket == NULL)
{
if (!open_port(server, NULL))
return -1;
}
else
return -1;
}
for (x = 1; x < count; x++)
{
BOOL success = open_port(server, list[x]);
if (!success)
{
free(list);
return -1;
}
}
free(list);
}
else
{
status = server->listener->OpenLocal(server->listener, server->ipcSocket);
if (!status)
{
WLog_ERR(TAG, "Problem creating local socket listener. (Port already used or "
"insufficient permissions?)");
return -1;
}
}
if (!(server->thread = CreateThread(NULL, 0, shadow_server_thread, (void*)server, 0, NULL)))
{
return -1;
}
return 0;
} | 341 | True | 1 |
CVE-2020-11095 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/733ee3208306b1ea32697b356c0215180fc3f049', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/733ee3208306b1ea32697b356c0215180fc3f049', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-563r-pvh7-4fw2', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-563r-pvh7-4fw2', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bound reads occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:43Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:28:33+02:00 | Fixed invalid access in update_recv_primary_order
CVE-2020-11095 thanks @antonio-morales for finding this. | 733ee3208306b1ea32697b356c0215180fc3f049 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_recv_primary_order | update_recv_primary_order( rdpUpdate * update , wStream * s , BYTE flags) | ['update', 's', 'flags'] | static BOOL update_recv_primary_order(rdpUpdate* update, wStream* s, BYTE flags)
{
BOOL rc = FALSE;
rdpContext* context = update->context;
rdpPrimaryUpdate* primary = update->primary;
ORDER_INFO* orderInfo = &(primary->order_info);
rdpSettings* settings = context->settings;
const char* orderName;
if (flags & ORDER_TYPE_CHANGE)
{
if (Stream_GetRemainingLength(s) < 1)
{
WLog_Print(update->log, WLOG_ERROR, "Stream_GetRemainingLength(s) < 1");
return FALSE;
}
Stream_Read_UINT8(s, orderInfo->orderType); /* orderType (1 byte) */
}
orderName = primary_order_string(orderInfo->orderType);
if (!check_primary_order_supported(update->log, settings, orderInfo->orderType, orderName))
return FALSE;
if (!update_read_field_flags(s, &(orderInfo->fieldFlags), flags,
PRIMARY_DRAWING_ORDER_FIELD_BYTES[orderInfo->orderType]))
{
WLog_Print(update->log, WLOG_ERROR, "update_read_field_flags() failed");
return FALSE;
}
if (flags & ORDER_BOUNDS)
{
if (!(flags & ORDER_ZERO_BOUNDS_DELTAS))
{
if (!update_read_bounds(s, &orderInfo->bounds))
{
WLog_Print(update->log, WLOG_ERROR, "update_read_bounds() failed");
return FALSE;
}
}
rc = IFCALLRESULT(FALSE, update->SetBounds, context, &orderInfo->bounds);
if (!rc)
return FALSE;
}
orderInfo->deltaCoordinates = (flags & ORDER_DELTA_COORDINATES) ? TRUE : FALSE;
if (!read_primary_order(update->log, orderName, s, orderInfo, primary))
return FALSE;
switch (orderInfo->orderType)
{
case ORDER_TYPE_DSTBLT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s rop=%s [0x%08" PRIx32 "]",
orderName, gdi_rop3_code_string(primary->dstblt.bRop),
gdi_rop3_code(primary->dstblt.bRop));
rc = IFCALLRESULT(FALSE, primary->DstBlt, context, &primary->dstblt);
}
break;
case ORDER_TYPE_PATBLT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s rop=%s [0x%08" PRIx32 "]",
orderName, gdi_rop3_code_string(primary->patblt.bRop),
gdi_rop3_code(primary->patblt.bRop));
rc = IFCALLRESULT(FALSE, primary->PatBlt, context, &primary->patblt);
}
break;
case ORDER_TYPE_SCRBLT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s rop=%s [0x%08" PRIx32 "]",
orderName, gdi_rop3_code_string(primary->scrblt.bRop),
gdi_rop3_code(primary->scrblt.bRop));
rc = IFCALLRESULT(FALSE, primary->ScrBlt, context, &primary->scrblt);
}
break;
case ORDER_TYPE_OPAQUE_RECT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->OpaqueRect, context, &primary->opaque_rect);
}
break;
case ORDER_TYPE_DRAW_NINE_GRID:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->DrawNineGrid, context, &primary->draw_nine_grid);
}
break;
case ORDER_TYPE_MULTI_DSTBLT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s rop=%s [0x%08" PRIx32 "]",
orderName, gdi_rop3_code_string(primary->multi_dstblt.bRop),
gdi_rop3_code(primary->multi_dstblt.bRop));
rc = IFCALLRESULT(FALSE, primary->MultiDstBlt, context, &primary->multi_dstblt);
}
break;
case ORDER_TYPE_MULTI_PATBLT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s rop=%s [0x%08" PRIx32 "]",
orderName, gdi_rop3_code_string(primary->multi_patblt.bRop),
gdi_rop3_code(primary->multi_patblt.bRop));
rc = IFCALLRESULT(FALSE, primary->MultiPatBlt, context, &primary->multi_patblt);
}
break;
case ORDER_TYPE_MULTI_SCRBLT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s rop=%s [0x%08" PRIx32 "]",
orderName, gdi_rop3_code_string(primary->multi_scrblt.bRop),
gdi_rop3_code(primary->multi_scrblt.bRop));
rc = IFCALLRESULT(FALSE, primary->MultiScrBlt, context, &primary->multi_scrblt);
}
break;
case ORDER_TYPE_MULTI_OPAQUE_RECT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc =
IFCALLRESULT(FALSE, primary->MultiOpaqueRect, context, &primary->multi_opaque_rect);
}
break;
case ORDER_TYPE_MULTI_DRAW_NINE_GRID:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->MultiDrawNineGrid, context,
&primary->multi_draw_nine_grid);
}
break;
case ORDER_TYPE_LINE_TO:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->LineTo, context, &primary->line_to);
}
break;
case ORDER_TYPE_POLYLINE:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->Polyline, context, &primary->polyline);
}
break;
case ORDER_TYPE_MEMBLT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s rop=%s [0x%08" PRIx32 "]",
orderName, gdi_rop3_code_string(primary->memblt.bRop),
gdi_rop3_code(primary->memblt.bRop));
rc = IFCALLRESULT(FALSE, primary->MemBlt, context, &primary->memblt);
}
break;
case ORDER_TYPE_MEM3BLT:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s rop=%s [0x%08" PRIx32 "]",
orderName, gdi_rop3_code_string(primary->mem3blt.bRop),
gdi_rop3_code(primary->mem3blt.bRop));
rc = IFCALLRESULT(FALSE, primary->Mem3Blt, context, &primary->mem3blt);
}
break;
case ORDER_TYPE_SAVE_BITMAP:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->SaveBitmap, context, &primary->save_bitmap);
}
break;
case ORDER_TYPE_GLYPH_INDEX:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->GlyphIndex, context, &primary->glyph_index);
}
break;
case ORDER_TYPE_FAST_INDEX:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->FastIndex, context, &primary->fast_index);
}
break;
case ORDER_TYPE_FAST_GLYPH:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->FastGlyph, context, &primary->fast_glyph);
}
break;
case ORDER_TYPE_POLYGON_SC:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->PolygonSC, context, &primary->polygon_sc);
}
break;
case ORDER_TYPE_POLYGON_CB:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->PolygonCB, context, &primary->polygon_cb);
}
break;
case ORDER_TYPE_ELLIPSE_SC:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->EllipseSC, context, &primary->ellipse_sc);
}
break;
case ORDER_TYPE_ELLIPSE_CB:
{
WLog_Print(update->log, WLOG_DEBUG, "Primary Drawing Order %s", orderName);
rc = IFCALLRESULT(FALSE, primary->EllipseCB, context, &primary->ellipse_cb);
}
break;
default:
WLog_Print(update->log, WLOG_WARN, "Primary Drawing Order %s not supported", orderName);
break;
}
if (!rc)
{
WLog_Print(update->log, WLOG_WARN, "Primary Drawing Order %s failed", orderName);
return FALSE;
}
if (flags & ORDER_BOUNDS)
{
rc = IFCALLRESULT(FALSE, update->SetBounds, context, NULL);
}
return rc;
} | 1351 | True | 1 |
CVE-2020-11095 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/733ee3208306b1ea32697b356c0215180fc3f049', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/733ee3208306b1ea32697b356c0215180fc3f049', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-563r-pvh7-4fw2', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-563r-pvh7-4fw2', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bound reads occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:43Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:28:33+02:00 | Fixed invalid access in update_recv_primary_order
CVE-2020-11095 thanks @antonio-morales for finding this. | 733ee3208306b1ea32697b356c0215180fc3f049 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_prepare_order_info | update_prepare_order_info( rdpContext * context , ORDER_INFO * orderInfo , UINT32 orderType) | ['context', 'orderInfo', 'orderType'] | static int update_prepare_order_info(rdpContext* context, ORDER_INFO* orderInfo, UINT32 orderType)
{
int length = 1;
orderInfo->fieldFlags = 0;
orderInfo->orderType = orderType;
orderInfo->controlFlags = ORDER_STANDARD;
orderInfo->controlFlags |= ORDER_TYPE_CHANGE;
length += 1;
length += PRIMARY_DRAWING_ORDER_FIELD_BYTES[orderInfo->orderType];
length += update_prepare_bounds(context, orderInfo);
return length;
} | 69 | True | 1 |
CVE-2020-11095 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/733ee3208306b1ea32697b356c0215180fc3f049', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/733ee3208306b1ea32697b356c0215180fc3f049', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-563r-pvh7-4fw2', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-563r-pvh7-4fw2', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bound reads occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:43Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:28:33+02:00 | Fixed invalid access in update_recv_primary_order
CVE-2020-11095 thanks @antonio-morales for finding this. | 733ee3208306b1ea32697b356c0215180fc3f049 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_write_order_info | update_write_order_info( rdpContext * context , wStream * s , ORDER_INFO * orderInfo , size_t offset) | ['context', 's', 'orderInfo', 'offset'] | static int update_write_order_info(rdpContext* context, wStream* s, ORDER_INFO* orderInfo,
size_t offset)
{
size_t position;
WINPR_UNUSED(context);
position = Stream_GetPosition(s);
Stream_SetPosition(s, offset);
Stream_Write_UINT8(s, orderInfo->controlFlags); /* controlFlags (1 byte) */
if (orderInfo->controlFlags & ORDER_TYPE_CHANGE)
Stream_Write_UINT8(s, orderInfo->orderType); /* orderType (1 byte) */
update_write_field_flags(s, orderInfo->fieldFlags, orderInfo->controlFlags,
PRIMARY_DRAWING_ORDER_FIELD_BYTES[orderInfo->orderType]);
update_write_bounds(s, orderInfo);
Stream_SetPosition(s, position);
return 0;
} | 104 | True | 1 |
CVE-2020-11096 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a global OOB read in update_read_cache_bitmap_v3_order. As a workaround, one can disable bitmap cache with -bitmap-cache (default). This is fixed in version 2.1.2.'}] | 2022-07-19T11:44Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:50:55+02:00 | Fixed OOB read in update_read_cache_bitmap_v3_order
CVE-2020-11096 thanks @antonio-morales for finding this. | b8beb55913471952f92770c90c372139d78c16c0 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_read_brush | update_read_brush( wStream * s , rdpBrush * brush , BYTE fieldFlags) | ['s', 'brush', 'fieldFlags'] | static INLINE BOOL update_read_brush(wStream* s, rdpBrush* brush, BYTE fieldFlags)
{
if (fieldFlags & ORDER_FIELD_01)
{
if (Stream_GetRemainingLength(s) < 1)
return FALSE;
Stream_Read_UINT8(s, brush->x);
}
if (fieldFlags & ORDER_FIELD_02)
{
if (Stream_GetRemainingLength(s) < 1)
return FALSE;
Stream_Read_UINT8(s, brush->y);
}
if (fieldFlags & ORDER_FIELD_03)
{
if (Stream_GetRemainingLength(s) < 1)
return FALSE;
Stream_Read_UINT8(s, brush->style);
}
if (fieldFlags & ORDER_FIELD_04)
{
if (Stream_GetRemainingLength(s) < 1)
return FALSE;
Stream_Read_UINT8(s, brush->hatch);
}
if (brush->style & CACHED_BRUSH)
{
brush->index = brush->hatch;
brush->bpp = BMF_BPP[brush->style & 0x07];
if (brush->bpp == 0)
brush->bpp = 1;
}
if (fieldFlags & ORDER_FIELD_05)
{
if (Stream_GetRemainingLength(s) < 7)
return FALSE;
brush->data = (BYTE*)brush->p8x8;
Stream_Read_UINT8(s, brush->data[7]);
Stream_Read_UINT8(s, brush->data[6]);
Stream_Read_UINT8(s, brush->data[5]);
Stream_Read_UINT8(s, brush->data[4]);
Stream_Read_UINT8(s, brush->data[3]);
Stream_Read_UINT8(s, brush->data[2]);
Stream_Read_UINT8(s, brush->data[1]);
brush->data[0] = brush->hatch;
}
return TRUE;
} | 306 | True | 1 |
CVE-2020-11096 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a global OOB read in update_read_cache_bitmap_v3_order. As a workaround, one can disable bitmap cache with -bitmap-cache (default). This is fixed in version 2.1.2.'}] | 2022-07-19T11:44Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:50:55+02:00 | Fixed OOB read in update_read_cache_bitmap_v3_order
CVE-2020-11096 thanks @antonio-morales for finding this. | b8beb55913471952f92770c90c372139d78c16c0 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_read_cache_bitmap_v2_order | update_read_cache_bitmap_v2_order( rdpUpdate * update , wStream * s , BOOL compressed , UINT16 flags) | ['update', 's', 'compressed', 'flags'] | static CACHE_BITMAP_V2_ORDER* update_read_cache_bitmap_v2_order(rdpUpdate* update, wStream* s,
BOOL compressed, UINT16 flags)
{
BYTE bitsPerPixelId;
CACHE_BITMAP_V2_ORDER* cache_bitmap_v2;
if (!update || !s)
return NULL;
cache_bitmap_v2 = calloc(1, sizeof(CACHE_BITMAP_V2_ORDER));
if (!cache_bitmap_v2)
goto fail;
cache_bitmap_v2->cacheId = flags & 0x0003;
cache_bitmap_v2->flags = (flags & 0xFF80) >> 7;
bitsPerPixelId = (flags & 0x0078) >> 3;
cache_bitmap_v2->bitmapBpp = CBR2_BPP[bitsPerPixelId];
if (cache_bitmap_v2->flags & CBR2_PERSISTENT_KEY_PRESENT)
{
if (Stream_GetRemainingLength(s) < 8)
goto fail;
Stream_Read_UINT32(s, cache_bitmap_v2->key1); /* key1 (4 bytes) */
Stream_Read_UINT32(s, cache_bitmap_v2->key2); /* key2 (4 bytes) */
}
if (cache_bitmap_v2->flags & CBR2_HEIGHT_SAME_AS_WIDTH)
{
if (!update_read_2byte_unsigned(s, &cache_bitmap_v2->bitmapWidth)) /* bitmapWidth */
goto fail;
cache_bitmap_v2->bitmapHeight = cache_bitmap_v2->bitmapWidth;
}
else
{
if (!update_read_2byte_unsigned(s, &cache_bitmap_v2->bitmapWidth) || /* bitmapWidth */
!update_read_2byte_unsigned(s, &cache_bitmap_v2->bitmapHeight)) /* bitmapHeight */
goto fail;
}
if (!update_read_4byte_unsigned(s, &cache_bitmap_v2->bitmapLength) || /* bitmapLength */
!update_read_2byte_unsigned(s, &cache_bitmap_v2->cacheIndex)) /* cacheIndex */
goto fail;
if (cache_bitmap_v2->flags & CBR2_DO_NOT_CACHE)
cache_bitmap_v2->cacheIndex = BITMAP_CACHE_WAITING_LIST_INDEX;
if (compressed)
{
if (!(cache_bitmap_v2->flags & CBR2_NO_BITMAP_COMPRESSION_HDR))
{
if (Stream_GetRemainingLength(s) < 8)
goto fail;
Stream_Read_UINT16(
s, cache_bitmap_v2->cbCompFirstRowSize); /* cbCompFirstRowSize (2 bytes) */
Stream_Read_UINT16(
s, cache_bitmap_v2->cbCompMainBodySize); /* cbCompMainBodySize (2 bytes) */
Stream_Read_UINT16(s, cache_bitmap_v2->cbScanWidth); /* cbScanWidth (2 bytes) */
Stream_Read_UINT16(
s, cache_bitmap_v2->cbUncompressedSize); /* cbUncompressedSize (2 bytes) */
cache_bitmap_v2->bitmapLength = cache_bitmap_v2->cbCompMainBodySize;
}
}
if (cache_bitmap_v2->bitmapLength == 0)
goto fail;
if (Stream_GetRemainingLength(s) < cache_bitmap_v2->bitmapLength)
goto fail;
if (cache_bitmap_v2->bitmapLength == 0)
goto fail;
cache_bitmap_v2->bitmapDataStream = malloc(cache_bitmap_v2->bitmapLength);
if (!cache_bitmap_v2->bitmapDataStream)
goto fail;
Stream_Read(s, cache_bitmap_v2->bitmapDataStream, cache_bitmap_v2->bitmapLength);
cache_bitmap_v2->compressed = compressed;
return cache_bitmap_v2;
fail:
free_cache_bitmap_v2_order(update->context, cache_bitmap_v2);
return NULL;
} | 410 | True | 1 |
CVE-2020-11096 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a global OOB read in update_read_cache_bitmap_v3_order. As a workaround, one can disable bitmap cache with -bitmap-cache (default). This is fixed in version 2.1.2.'}] | 2022-07-19T11:44Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:50:55+02:00 | Fixed OOB read in update_read_cache_bitmap_v3_order
CVE-2020-11096 thanks @antonio-morales for finding this. | b8beb55913471952f92770c90c372139d78c16c0 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_read_cache_bitmap_v3_order | update_read_cache_bitmap_v3_order( rdpUpdate * update , wStream * s , UINT16 flags) | ['update', 's', 'flags'] | static CACHE_BITMAP_V3_ORDER* update_read_cache_bitmap_v3_order(rdpUpdate* update, wStream* s,
UINT16 flags)
{
BYTE bitsPerPixelId;
BITMAP_DATA_EX* bitmapData;
UINT32 new_len;
BYTE* new_data;
CACHE_BITMAP_V3_ORDER* cache_bitmap_v3;
if (!update || !s)
return NULL;
cache_bitmap_v3 = calloc(1, sizeof(CACHE_BITMAP_V3_ORDER));
if (!cache_bitmap_v3)
goto fail;
cache_bitmap_v3->cacheId = flags & 0x00000003;
cache_bitmap_v3->flags = (flags & 0x0000FF80) >> 7;
bitsPerPixelId = (flags & 0x00000078) >> 3;
cache_bitmap_v3->bpp = CBR23_BPP[bitsPerPixelId];
if (Stream_GetRemainingLength(s) < 21)
goto fail;
Stream_Read_UINT16(s, cache_bitmap_v3->cacheIndex); /* cacheIndex (2 bytes) */
Stream_Read_UINT32(s, cache_bitmap_v3->key1); /* key1 (4 bytes) */
Stream_Read_UINT32(s, cache_bitmap_v3->key2); /* key2 (4 bytes) */
bitmapData = &cache_bitmap_v3->bitmapData;
Stream_Read_UINT8(s, bitmapData->bpp);
if ((bitmapData->bpp < 1) || (bitmapData->bpp > 32))
{
WLog_Print(update->log, WLOG_ERROR, "invalid bpp value %" PRIu32 "", bitmapData->bpp);
goto fail;
}
Stream_Seek_UINT8(s); /* reserved1 (1 byte) */
Stream_Seek_UINT8(s); /* reserved2 (1 byte) */
Stream_Read_UINT8(s, bitmapData->codecID); /* codecID (1 byte) */
Stream_Read_UINT16(s, bitmapData->width); /* width (2 bytes) */
Stream_Read_UINT16(s, bitmapData->height); /* height (2 bytes) */
Stream_Read_UINT32(s, new_len); /* length (4 bytes) */
if ((new_len == 0) || (Stream_GetRemainingLength(s) < new_len))
goto fail;
new_data = (BYTE*)realloc(bitmapData->data, new_len);
if (!new_data)
goto fail;
bitmapData->data = new_data;
bitmapData->length = new_len;
Stream_Read(s, bitmapData->data, bitmapData->length);
return cache_bitmap_v3;
fail:
free_cache_bitmap_v3_order(update->context, cache_bitmap_v3);
return NULL;
} | 329 | True | 1 |
CVE-2020-11096 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a global OOB read in update_read_cache_bitmap_v3_order. As a workaround, one can disable bitmap cache with -bitmap-cache (default). This is fixed in version 2.1.2.'}] | 2022-07-19T11:44Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:50:55+02:00 | Fixed OOB read in update_read_cache_bitmap_v3_order
CVE-2020-11096 thanks @antonio-morales for finding this. | b8beb55913471952f92770c90c372139d78c16c0 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_read_cache_brush_order | update_read_cache_brush_order( rdpUpdate * update , wStream * s , UINT16 flags) | ['update', 's', 'flags'] | static CACHE_BRUSH_ORDER* update_read_cache_brush_order(rdpUpdate* update, wStream* s, UINT16 flags)
{
int i;
BYTE iBitmapFormat;
BOOL compressed = FALSE;
CACHE_BRUSH_ORDER* cache_brush = calloc(1, sizeof(CACHE_BRUSH_ORDER));
if (!cache_brush)
goto fail;
if (Stream_GetRemainingLength(s) < 6)
goto fail;
Stream_Read_UINT8(s, cache_brush->index); /* cacheEntry (1 byte) */
Stream_Read_UINT8(s, iBitmapFormat); /* iBitmapFormat (1 byte) */
if (iBitmapFormat >= ARRAYSIZE(BMF_BPP))
goto fail;
cache_brush->bpp = BMF_BPP[iBitmapFormat];
Stream_Read_UINT8(s, cache_brush->cx); /* cx (1 byte) */
Stream_Read_UINT8(s, cache_brush->cy); /* cy (1 byte) */
Stream_Read_UINT8(s, cache_brush->style); /* style (1 byte) */
Stream_Read_UINT8(s, cache_brush->length); /* iBytes (1 byte) */
if ((cache_brush->cx == 8) && (cache_brush->cy == 8))
{
if (cache_brush->bpp == 1)
{
if (cache_brush->length != 8)
{
WLog_Print(update->log, WLOG_ERROR, "incompatible 1bpp brush of length:%" PRIu32 "",
cache_brush->length);
goto fail;
}
/* rows are encoded in reverse order */
if (Stream_GetRemainingLength(s) < 8)
goto fail;
for (i = 7; i >= 0; i--)
{
Stream_Read_UINT8(s, cache_brush->data[i]);
}
}
else
{
if ((iBitmapFormat == BMF_8BPP) && (cache_brush->length == 20))
compressed = TRUE;
else if ((iBitmapFormat == BMF_16BPP) && (cache_brush->length == 24))
compressed = TRUE;
else if ((iBitmapFormat == BMF_32BPP) && (cache_brush->length == 32))
compressed = TRUE;
if (compressed != FALSE)
{
/* compressed brush */
if (!update_decompress_brush(s, cache_brush->data, sizeof(cache_brush->data),
cache_brush->bpp))
goto fail;
}
else
{
/* uncompressed brush */
UINT32 scanline = (cache_brush->bpp / 8) * 8;
if (Stream_GetRemainingLength(s) < scanline * 8)
goto fail;
for (i = 7; i >= 0; i--)
{
Stream_Read(s, &cache_brush->data[i * scanline], scanline);
}
}
}
}
return cache_brush;
fail:
free_cache_brush_order(update->context, cache_brush);
return NULL;
} | 410 | True | 1 |
CVE-2020-11096 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a global OOB read in update_read_cache_bitmap_v3_order. As a workaround, one can disable bitmap cache with -bitmap-cache (default). This is fixed in version 2.1.2.'}] | 2022-07-19T11:44Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:50:55+02:00 | Fixed OOB read in update_read_cache_bitmap_v3_order
CVE-2020-11096 thanks @antonio-morales for finding this. | b8beb55913471952f92770c90c372139d78c16c0 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_write_brush | update_write_brush( wStream * s , rdpBrush * brush , BYTE fieldFlags) | ['s', 'brush', 'fieldFlags'] | static INLINE BOOL update_write_brush(wStream* s, rdpBrush* brush, BYTE fieldFlags)
{
if (fieldFlags & ORDER_FIELD_01)
{
Stream_Write_UINT8(s, brush->x);
}
if (fieldFlags & ORDER_FIELD_02)
{
Stream_Write_UINT8(s, brush->y);
}
if (fieldFlags & ORDER_FIELD_03)
{
Stream_Write_UINT8(s, brush->style);
}
if (brush->style & CACHED_BRUSH)
{
brush->hatch = brush->index;
brush->bpp = BMF_BPP[brush->style & 0x07];
if (brush->bpp == 0)
brush->bpp = 1;
}
if (fieldFlags & ORDER_FIELD_04)
{
Stream_Write_UINT8(s, brush->hatch);
}
if (fieldFlags & ORDER_FIELD_05)
{
brush->data = (BYTE*)brush->p8x8;
Stream_Write_UINT8(s, brush->data[7]);
Stream_Write_UINT8(s, brush->data[6]);
Stream_Write_UINT8(s, brush->data[5]);
Stream_Write_UINT8(s, brush->data[4]);
Stream_Write_UINT8(s, brush->data[3]);
Stream_Write_UINT8(s, brush->data[2]);
Stream_Write_UINT8(s, brush->data[1]);
brush->data[0] = brush->hatch;
}
return TRUE;
} | 246 | True | 1 |
CVE-2020-11096 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a global OOB read in update_read_cache_bitmap_v3_order. As a workaround, one can disable bitmap cache with -bitmap-cache (default). This is fixed in version 2.1.2.'}] | 2022-07-19T11:44Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:50:55+02:00 | Fixed OOB read in update_read_cache_bitmap_v3_order
CVE-2020-11096 thanks @antonio-morales for finding this. | b8beb55913471952f92770c90c372139d78c16c0 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_write_cache_bitmap_v2_order | update_write_cache_bitmap_v2_order( wStream * s , CACHE_BITMAP_V2_ORDER * cache_bitmap_v2 , BOOL compressed , UINT16 * flags) | ['s', 'cache_bitmap_v2', 'compressed', 'flags'] | BOOL update_write_cache_bitmap_v2_order(wStream* s, CACHE_BITMAP_V2_ORDER* cache_bitmap_v2,
BOOL compressed, UINT16* flags)
{
BYTE bitsPerPixelId;
if (!Stream_EnsureRemainingCapacity(
s, update_approximate_cache_bitmap_v2_order(cache_bitmap_v2, compressed, flags)))
return FALSE;
bitsPerPixelId = BPP_CBR2[cache_bitmap_v2->bitmapBpp];
*flags = (cache_bitmap_v2->cacheId & 0x0003) | (bitsPerPixelId << 3) |
((cache_bitmap_v2->flags << 7) & 0xFF80);
if (cache_bitmap_v2->flags & CBR2_PERSISTENT_KEY_PRESENT)
{
Stream_Write_UINT32(s, cache_bitmap_v2->key1); /* key1 (4 bytes) */
Stream_Write_UINT32(s, cache_bitmap_v2->key2); /* key2 (4 bytes) */
}
if (cache_bitmap_v2->flags & CBR2_HEIGHT_SAME_AS_WIDTH)
{
if (!update_write_2byte_unsigned(s, cache_bitmap_v2->bitmapWidth)) /* bitmapWidth */
return FALSE;
}
else
{
if (!update_write_2byte_unsigned(s, cache_bitmap_v2->bitmapWidth) || /* bitmapWidth */
!update_write_2byte_unsigned(s, cache_bitmap_v2->bitmapHeight)) /* bitmapHeight */
return FALSE;
}
if (cache_bitmap_v2->flags & CBR2_DO_NOT_CACHE)
cache_bitmap_v2->cacheIndex = BITMAP_CACHE_WAITING_LIST_INDEX;
if (!update_write_4byte_unsigned(s, cache_bitmap_v2->bitmapLength) || /* bitmapLength */
!update_write_2byte_unsigned(s, cache_bitmap_v2->cacheIndex)) /* cacheIndex */
return FALSE;
if (compressed)
{
if (!(cache_bitmap_v2->flags & CBR2_NO_BITMAP_COMPRESSION_HDR))
{
Stream_Write_UINT16(
s, cache_bitmap_v2->cbCompFirstRowSize); /* cbCompFirstRowSize (2 bytes) */
Stream_Write_UINT16(
s, cache_bitmap_v2->cbCompMainBodySize); /* cbCompMainBodySize (2 bytes) */
Stream_Write_UINT16(s, cache_bitmap_v2->cbScanWidth); /* cbScanWidth (2 bytes) */
Stream_Write_UINT16(
s, cache_bitmap_v2->cbUncompressedSize); /* cbUncompressedSize (2 bytes) */
cache_bitmap_v2->bitmapLength = cache_bitmap_v2->cbCompMainBodySize;
}
if (!Stream_EnsureRemainingCapacity(s, cache_bitmap_v2->bitmapLength))
return FALSE;
Stream_Write(s, cache_bitmap_v2->bitmapDataStream, cache_bitmap_v2->bitmapLength);
}
else
{
if (!Stream_EnsureRemainingCapacity(s, cache_bitmap_v2->bitmapLength))
return FALSE;
Stream_Write(s, cache_bitmap_v2->bitmapDataStream, cache_bitmap_v2->bitmapLength);
}
cache_bitmap_v2->compressed = compressed;
return TRUE;
} | 333 | True | 1 |
CVE-2020-11096 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a global OOB read in update_read_cache_bitmap_v3_order. As a workaround, one can disable bitmap cache with -bitmap-cache (default). This is fixed in version 2.1.2.'}] | 2022-07-19T11:44Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:50:55+02:00 | Fixed OOB read in update_read_cache_bitmap_v3_order
CVE-2020-11096 thanks @antonio-morales for finding this. | b8beb55913471952f92770c90c372139d78c16c0 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_write_cache_bitmap_v3_order | update_write_cache_bitmap_v3_order( wStream * s , CACHE_BITMAP_V3_ORDER * cache_bitmap_v3 , UINT16 * flags) | ['s', 'cache_bitmap_v3', 'flags'] | BOOL update_write_cache_bitmap_v3_order(wStream* s, CACHE_BITMAP_V3_ORDER* cache_bitmap_v3,
UINT16* flags)
{
BYTE bitsPerPixelId;
BITMAP_DATA_EX* bitmapData;
if (!Stream_EnsureRemainingCapacity(
s, update_approximate_cache_bitmap_v3_order(cache_bitmap_v3, flags)))
return FALSE;
bitmapData = &cache_bitmap_v3->bitmapData;
bitsPerPixelId = BPP_CBR23[cache_bitmap_v3->bpp];
*flags = (cache_bitmap_v3->cacheId & 0x00000003) |
((cache_bitmap_v3->flags << 7) & 0x0000FF80) | ((bitsPerPixelId << 3) & 0x00000078);
Stream_Write_UINT16(s, cache_bitmap_v3->cacheIndex); /* cacheIndex (2 bytes) */
Stream_Write_UINT32(s, cache_bitmap_v3->key1); /* key1 (4 bytes) */
Stream_Write_UINT32(s, cache_bitmap_v3->key2); /* key2 (4 bytes) */
Stream_Write_UINT8(s, bitmapData->bpp);
Stream_Write_UINT8(s, 0); /* reserved1 (1 byte) */
Stream_Write_UINT8(s, 0); /* reserved2 (1 byte) */
Stream_Write_UINT8(s, bitmapData->codecID); /* codecID (1 byte) */
Stream_Write_UINT16(s, bitmapData->width); /* width (2 bytes) */
Stream_Write_UINT16(s, bitmapData->height); /* height (2 bytes) */
Stream_Write_UINT32(s, bitmapData->length); /* length (4 bytes) */
Stream_Write(s, bitmapData->data, bitmapData->length);
return TRUE;
} | 194 | True | 1 |
CVE-2020-11096 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-mjw7-3mq2-996x', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/b8beb55913471952f92770c90c372139d78c16c0', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is a global OOB read in update_read_cache_bitmap_v3_order. As a workaround, one can disable bitmap cache with -bitmap-cache (default). This is fixed in version 2.1.2.'}] | 2022-07-19T11:44Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-05-26 07:50:55+02:00 | Fixed OOB read in update_read_cache_bitmap_v3_order
CVE-2020-11096 thanks @antonio-morales for finding this. | b8beb55913471952f92770c90c372139d78c16c0 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_write_cache_brush_order | update_write_cache_brush_order( wStream * s , const CACHE_BRUSH_ORDER * cache_brush , UINT16 * flags) | ['s', 'cache_brush', 'flags'] | BOOL update_write_cache_brush_order(wStream* s, const CACHE_BRUSH_ORDER* cache_brush, UINT16* flags)
{
int i;
BYTE iBitmapFormat;
BOOL compressed = FALSE;
if (!Stream_EnsureRemainingCapacity(s,
update_approximate_cache_brush_order(cache_brush, flags)))
return FALSE;
iBitmapFormat = BPP_BMF[cache_brush->bpp];
Stream_Write_UINT8(s, cache_brush->index); /* cacheEntry (1 byte) */
Stream_Write_UINT8(s, iBitmapFormat); /* iBitmapFormat (1 byte) */
Stream_Write_UINT8(s, cache_brush->cx); /* cx (1 byte) */
Stream_Write_UINT8(s, cache_brush->cy); /* cy (1 byte) */
Stream_Write_UINT8(s, cache_brush->style); /* style (1 byte) */
Stream_Write_UINT8(s, cache_brush->length); /* iBytes (1 byte) */
if ((cache_brush->cx == 8) && (cache_brush->cy == 8))
{
if (cache_brush->bpp == 1)
{
if (cache_brush->length != 8)
{
WLog_ERR(TAG, "incompatible 1bpp brush of length:%" PRIu32 "", cache_brush->length);
return FALSE;
}
for (i = 7; i >= 0; i--)
{
Stream_Write_UINT8(s, cache_brush->data[i]);
}
}
else
{
if ((iBitmapFormat == BMF_8BPP) && (cache_brush->length == 20))
compressed = TRUE;
else if ((iBitmapFormat == BMF_16BPP) && (cache_brush->length == 24))
compressed = TRUE;
else if ((iBitmapFormat == BMF_32BPP) && (cache_brush->length == 32))
compressed = TRUE;
if (compressed != FALSE)
{
/* compressed brush */
if (!update_compress_brush(s, cache_brush->data, cache_brush->bpp))
return FALSE;
}
else
{
/* uncompressed brush */
int scanline = (cache_brush->bpp / 8) * 8;
for (i = 7; i >= 0; i--)
{
Stream_Write(s, &cache_brush->data[i * scanline], scanline);
}
}
}
}
return TRUE;
} | 333 | True | 1 |
CVE-2020-4030 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-fjr5-97f5-qq98', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-fjr5-97f5-qq98', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/05cd9ea2290d23931f615c1b004d4b2e69074e27', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/05cd9ea2290d23931f615c1b004d4b2e69074e27', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-190'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is an out of bounds read in TrioParse. Logging might bypass string length checks due to an integer overflow. This is fixed in version 2.1.2.'}] | 2021-10-07T17:22Z | 2020-06-22T22:15Z | Integer Overflow or Wraparound | The software performs a calculation that can produce an integer overflow or wraparound, when the logic assumes that the resulting value will always be larger than the original value. This can introduce other weaknesses when the calculation is used for resource management or execution control. | An integer overflow or wraparound occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, the value may wrap to become a very small or negative number. While this may be intended behavior in circumstances that rely on wrapping, it can have security consequences if the wrap is unexpected. This is especially the case if the integer overflow can be triggered using user-supplied inputs. This becomes security-critical when the result is used to control looping, make a security decision, or determine the offset or size in behaviors such as memory allocation, copying, concatenation, etc.
| https://cwe.mitre.org/data/definitions/190.html | 0 | akallabeth | 2020-05-26 16:12:58+02:00 | Fixed TrioParse and trio_length limts.
CVE-2020-4030 thanks to @antonio-morales for finding this. | 05cd9ea2290d23931f615c1b004d4b2e69074e27 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | TRIO_ARGS2 | TRIO_ARGS2((callback,name) , trio_callback_t callback , TRIO_CONST char * name) | ['callback', 'name'] | TRIO_PUBLIC trio_pointer_t trio_register TRIO_ARGS2((callback, name), trio_callback_t callback,
TRIO_CONST char* name)
{
trio_userdef_t* def;
trio_userdef_t* prev = NULL;
if (callback == NULL)
return NULL;
if (name)
{
/* Handle built-in namespaces */
if (name[0] == ':')
{
if (trio_equal(name, ":enter"))
{
internalEnterCriticalRegion = callback;
}
else if (trio_equal(name, ":leave"))
{
internalLeaveCriticalRegion = callback;
}
return NULL;
}
/* Bail out if namespace is too long */
if (trio_length(name) >= MAX_USER_NAME)
return NULL;
/* Bail out if namespace already is registered */
def = TrioFindNamespace(name, &prev);
if (def)
return NULL;
}
def = (trio_userdef_t*)TRIO_MALLOC(sizeof(trio_userdef_t));
if (def)
{
if (internalEnterCriticalRegion)
(void)internalEnterCriticalRegion(NULL);
if (name)
{
/* Link into internal list */
if (prev == NULL)
internalUserDef = def;
else
prev->next = def;
}
/* Initialize */
def->callback = callback;
def->name = (name == NULL) ? NULL : trio_duplicate(name);
def->next = NULL;
if (internalLeaveCriticalRegion)
(void)internalLeaveCriticalRegion(NULL);
}
return (trio_pointer_t)def;
} | 219 | True | 1 |
CVE-2020-4030 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-fjr5-97f5-qq98', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-fjr5-97f5-qq98', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/05cd9ea2290d23931f615c1b004d4b2e69074e27', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/05cd9ea2290d23931f615c1b004d4b2e69074e27', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-190'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is an out of bounds read in TrioParse. Logging might bypass string length checks due to an integer overflow. This is fixed in version 2.1.2.'}] | 2021-10-07T17:22Z | 2020-06-22T22:15Z | Integer Overflow or Wraparound | The software performs a calculation that can produce an integer overflow or wraparound, when the logic assumes that the resulting value will always be larger than the original value. This can introduce other weaknesses when the calculation is used for resource management or execution control. | An integer overflow or wraparound occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, the value may wrap to become a very small or negative number. While this may be intended behavior in circumstances that rely on wrapping, it can have security consequences if the wrap is unexpected. This is especially the case if the integer overflow can be triggered using user-supplied inputs. This becomes security-critical when the result is used to control looping, make a security decision, or determine the offset or size in behaviors such as memory allocation, copying, concatenation, etc.
| https://cwe.mitre.org/data/definitions/190.html | 0 | akallabeth | 2020-05-26 16:12:58+02:00 | Fixed TrioParse and trio_length limts.
CVE-2020-4030 thanks to @antonio-morales for finding this. | 05cd9ea2290d23931f615c1b004d4b2e69074e27 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | TRIO_ARGS5 | TRIO_ARGS5((self,string,flags,width,precision) , trio_class_t * self , TRIO_CONST char * string , trio_flags_t flags , int width , int precision) | ['self', 'string', 'flags', 'width', 'precision'] | TRIO_PRIVATE void TrioWriteString TRIO_ARGS5((self, string, flags, width, precision),
trio_class_t* self, TRIO_CONST char* string,
trio_flags_t flags, int width, int precision)
{
int length;
int ch;
assert(VALID(self));
assert(VALID(self->OutStream));
if (string == NULL)
{
string = internalNullString;
length = sizeof(internalNullString) - 1;
#if TRIO_FEATURE_QUOTE
/* Disable quoting for the null pointer */
flags &= (~FLAGS_QUOTE);
#endif
width = 0;
}
else
{
if (precision == 0)
{
length = trio_length(string);
}
else
{
length = trio_length_max(string, precision);
}
}
if ((NO_PRECISION != precision) && (precision < length))
{
length = precision;
}
width -= length;
#if TRIO_FEATURE_QUOTE
if (flags & FLAGS_QUOTE)
self->OutStream(self, CHAR_QUOTE);
#endif
if (!(flags & FLAGS_LEFTADJUST))
{
while (width-- > 0)
self->OutStream(self, CHAR_ADJUST);
}
while (length-- > 0)
{
/* The ctype parameters must be an unsigned char (or EOF) */
ch = (int)((unsigned char)(*string++));
TrioWriteStringCharacter(self, ch, flags);
}
if (flags & FLAGS_LEFTADJUST)
{
while (width-- > 0)
self->OutStream(self, CHAR_ADJUST);
}
#if TRIO_FEATURE_QUOTE
if (flags & FLAGS_QUOTE)
self->OutStream(self, CHAR_QUOTE);
#endif
} | 259 | True | 1 |
CVE-2020-4030 | False | False | False | False | AV:N/AC:L/Au:N/C:P/I:N/A:P | NETWORK | LOW | NONE | PARTIAL | NONE | PARTIAL | 6.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | NONE | NONE | UNCHANGED | LOW | NONE | LOW | 6.5 | MEDIUM | 3.9 | 2.5 | False | [{'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-fjr5-97f5-qq98', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-fjr5-97f5-qq98', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/05cd9ea2290d23931f615c1b004d4b2e69074e27', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/05cd9ea2290d23931f615c1b004d4b2e69074e27', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-190'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is an out of bounds read in TrioParse. Logging might bypass string length checks due to an integer overflow. This is fixed in version 2.1.2.'}] | 2021-10-07T17:22Z | 2020-06-22T22:15Z | Integer Overflow or Wraparound | The software performs a calculation that can produce an integer overflow or wraparound, when the logic assumes that the resulting value will always be larger than the original value. This can introduce other weaknesses when the calculation is used for resource management or execution control. | An integer overflow or wraparound occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, the value may wrap to become a very small or negative number. While this may be intended behavior in circumstances that rely on wrapping, it can have security consequences if the wrap is unexpected. This is especially the case if the integer overflow can be triggered using user-supplied inputs. This becomes security-critical when the result is used to control looping, make a security decision, or determine the offset or size in behaviors such as memory allocation, copying, concatenation, etc.
| https://cwe.mitre.org/data/definitions/190.html | 0 | akallabeth | 2020-05-26 16:12:58+02:00 | Fixed TrioParse and trio_length limts.
CVE-2020-4030 thanks to @antonio-morales for finding this. | 05cd9ea2290d23931f615c1b004d4b2e69074e27 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | TRIO_ARGS1 | TRIO_ARGS1((string) , TRIO_CONST char * string) | ['string'] | TRIO_PUBLIC_STRING size_t trio_length TRIO_ARGS1((string), TRIO_CONST char* string)
{
return strlen(string);
} | 19 | True | 1 |
CVE-2020-4032 | False | False | False | False | AV:N/AC:M/Au:N/C:N/I:P/A:N | NETWORK | MEDIUM | NONE | NONE | PARTIAL | NONE | 4.3 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:N | NETWORK | LOW | LOW | NONE | UNCHANGED | NONE | LOW | NONE | 4.3 | MEDIUM | 2.8 | 1.4 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-3898-mc89-x2vc', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-3898-mc89-x2vc', 'refsource': 'CONFIRM', 'tags': ['Mitigation', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/commit/e7bffa64ef5ed70bac94f823e2b95262642f5296', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/e7bffa64ef5ed70bac94f823e2b95262642f5296', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-681'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, there is an integer casting vulnerability in update_recv_secondary_order. All clients with +glyph-cache /relax-order-checks are affected. This is fixed in version 2.1.2.'}] | 2022-06-01T18:46Z | 2020-06-22T22:15Z | Incorrect Conversion between Numeric Types | When converting from one data type to another, such as long to integer, data can be omitted or translated in a way that produces unexpected values. If the resulting values are used in a sensitive context, then dangerous behaviors may occur. | https://cwe.mitre.org/data/definitions/681.html | 0 | akallabeth | 2020-05-27 08:10:11+02:00 | Fixed OOB read in update_recv_secondary_order
CVE-2020-4032 thanks to @antonio-morales for finding this. | e7bffa64ef5ed70bac94f823e2b95262642f5296 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | update_recv_secondary_order | update_recv_secondary_order( rdpUpdate * update , wStream * s , BYTE flags) | ['update', 's', 'flags'] | static BOOL update_recv_secondary_order(rdpUpdate* update, wStream* s, BYTE flags)
{
BOOL rc = FALSE;
size_t start, end, diff;
BYTE orderType;
UINT16 extraFlags;
UINT16 orderLength;
rdpContext* context = update->context;
rdpSettings* settings = context->settings;
rdpSecondaryUpdate* secondary = update->secondary;
const char* name;
if (Stream_GetRemainingLength(s) < 5)
{
WLog_Print(update->log, WLOG_ERROR, "Stream_GetRemainingLength(s) < 5");
return FALSE;
}
Stream_Read_UINT16(s, orderLength); /* orderLength (2 bytes) */
Stream_Read_UINT16(s, extraFlags); /* extraFlags (2 bytes) */
Stream_Read_UINT8(s, orderType); /* orderType (1 byte) */
if (Stream_GetRemainingLength(s) < orderLength + 7U)
{
WLog_Print(update->log, WLOG_ERROR, "Stream_GetRemainingLength(s) %" PRIuz " < %" PRIu16,
Stream_GetRemainingLength(s), orderLength + 7);
return FALSE;
}
start = Stream_GetPosition(s);
name = secondary_order_string(orderType);
WLog_Print(update->log, WLOG_DEBUG, "Secondary Drawing Order %s", name);
if (!check_secondary_order_supported(update->log, settings, orderType, name))
return FALSE;
switch (orderType)
{
case ORDER_TYPE_BITMAP_UNCOMPRESSED:
case ORDER_TYPE_CACHE_BITMAP_COMPRESSED:
{
const BOOL compressed = (orderType == ORDER_TYPE_CACHE_BITMAP_COMPRESSED);
CACHE_BITMAP_ORDER* order =
update_read_cache_bitmap_order(update, s, compressed, extraFlags);
if (order)
{
rc = IFCALLRESULT(FALSE, secondary->CacheBitmap, context, order);
free_cache_bitmap_order(context, order);
}
}
break;
case ORDER_TYPE_BITMAP_UNCOMPRESSED_V2:
case ORDER_TYPE_BITMAP_COMPRESSED_V2:
{
const BOOL compressed = (orderType == ORDER_TYPE_BITMAP_COMPRESSED_V2);
CACHE_BITMAP_V2_ORDER* order =
update_read_cache_bitmap_v2_order(update, s, compressed, extraFlags);
if (order)
{
rc = IFCALLRESULT(FALSE, secondary->CacheBitmapV2, context, order);
free_cache_bitmap_v2_order(context, order);
}
}
break;
case ORDER_TYPE_BITMAP_COMPRESSED_V3:
{
CACHE_BITMAP_V3_ORDER* order = update_read_cache_bitmap_v3_order(update, s, extraFlags);
if (order)
{
rc = IFCALLRESULT(FALSE, secondary->CacheBitmapV3, context, order);
free_cache_bitmap_v3_order(context, order);
}
}
break;
case ORDER_TYPE_CACHE_COLOR_TABLE:
{
CACHE_COLOR_TABLE_ORDER* order =
update_read_cache_color_table_order(update, s, extraFlags);
if (order)
{
rc = IFCALLRESULT(FALSE, secondary->CacheColorTable, context, order);
free_cache_color_table_order(context, order);
}
}
break;
case ORDER_TYPE_CACHE_GLYPH:
{
switch (settings->GlyphSupportLevel)
{
case GLYPH_SUPPORT_PARTIAL:
case GLYPH_SUPPORT_FULL:
{
CACHE_GLYPH_ORDER* order = update_read_cache_glyph_order(update, s, extraFlags);
if (order)
{
rc = IFCALLRESULT(FALSE, secondary->CacheGlyph, context, order);
free_cache_glyph_order(context, order);
}
}
break;
case GLYPH_SUPPORT_ENCODE:
{
CACHE_GLYPH_V2_ORDER* order =
update_read_cache_glyph_v2_order(update, s, extraFlags);
if (order)
{
rc = IFCALLRESULT(FALSE, secondary->CacheGlyphV2, context, order);
free_cache_glyph_v2_order(context, order);
}
}
break;
case GLYPH_SUPPORT_NONE:
default:
break;
}
}
break;
case ORDER_TYPE_CACHE_BRUSH:
/* [MS-RDPEGDI] 2.2.2.2.1.2.7 Cache Brush (CACHE_BRUSH_ORDER) */
{
CACHE_BRUSH_ORDER* order = update_read_cache_brush_order(update, s, extraFlags);
if (order)
{
rc = IFCALLRESULT(FALSE, secondary->CacheBrush, context, order);
free_cache_brush_order(context, order);
}
}
break;
default:
WLog_Print(update->log, WLOG_WARN, "SECONDARY ORDER %s not supported", name);
break;
}
if (!rc)
{
WLog_Print(update->log, WLOG_ERROR, "SECONDARY ORDER %s failed", name);
}
start += orderLength + 7;
end = Stream_GetPosition(s);
if (start > end)
{
WLog_Print(update->log, WLOG_WARN, "SECONDARY_ORDER %s: read %" PRIuz "bytes too much",
name, end - start);
return FALSE;
}
diff = start - end;
if (diff > 0)
{
WLog_Print(update->log, WLOG_DEBUG,
"SECONDARY_ORDER %s: read %" PRIuz "bytes short, skipping", name, diff);
Stream_Seek(s, diff);
}
return rc;
} | 714 | True | 1 |
|
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_av_pair_add_copy | ntlm_av_pair_add_copy( NTLM_AV_PAIR * pAvPairList , size_t cbAvPairList , NTLM_AV_PAIR * pAvPair , size_t cbAvPair) | ['pAvPairList', 'cbAvPairList', 'pAvPair', 'cbAvPair'] | static BOOL ntlm_av_pair_add_copy(NTLM_AV_PAIR* pAvPairList, size_t cbAvPairList,
NTLM_AV_PAIR* pAvPair, size_t cbAvPair)
{
if (!ntlm_av_pair_check(pAvPair, cbAvPair))
return FALSE;
return ntlm_av_pair_add(pAvPairList, cbAvPairList, ntlm_av_pair_get_id(pAvPair),
ntlm_av_pair_get_value_pointer(pAvPair), ntlm_av_pair_get_len(pAvPair));
} | 54 | True | 1 |
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_av_pair_check | ntlm_av_pair_check( NTLM_AV_PAIR * pAvPair , size_t cbAvPair) | ['pAvPair', 'cbAvPair'] | static BOOL ntlm_av_pair_check(NTLM_AV_PAIR* pAvPair, size_t cbAvPair)
{
if (!pAvPair || cbAvPair < sizeof(NTLM_AV_PAIR))
return FALSE;
return cbAvPair >= ntlm_av_pair_get_next_offset(pAvPair);
} | 34 | True | 1 |
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_av_pair_get | ntlm_av_pair_get( NTLM_AV_PAIR * pAvPairList , size_t cbAvPairList , NTLM_AV_ID AvId , size_t * pcbAvPairListRemaining) | ['pAvPairList', 'cbAvPairList', 'AvId', 'pcbAvPairListRemaining'] | NTLM_AV_PAIR* ntlm_av_pair_get(NTLM_AV_PAIR* pAvPairList, size_t cbAvPairList, NTLM_AV_ID AvId,
size_t* pcbAvPairListRemaining)
{
size_t cbAvPair = cbAvPairList;
NTLM_AV_PAIR* pAvPair = pAvPairList;
if (!ntlm_av_pair_check(pAvPair, cbAvPair))
pAvPair = NULL;
while (pAvPair)
{
UINT16 id = ntlm_av_pair_get_id(pAvPair);
if (id == AvId)
break;
if (id == MsvAvEOL)
{
pAvPair = NULL;
break;
}
pAvPair = ntlm_av_pair_next(pAvPair, &cbAvPair);
}
if (!pAvPair)
cbAvPair = 0;
if (pcbAvPairListRemaining)
*pcbAvPairListRemaining = cbAvPair;
return pAvPair;
} | 110 | True | 1 |
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_av_pair_get_id | ntlm_av_pair_get_id( const NTLM_AV_PAIR * pAvPair) | ['pAvPair'] | static INLINE UINT16 ntlm_av_pair_get_id(const NTLM_AV_PAIR* pAvPair)
{
UINT16 AvId;
Data_Read_UINT16(&pAvPair->AvId, AvId);
return AvId;
} | 25 | True | 1 |
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_av_pair_get_len | ntlm_av_pair_get_len( const NTLM_AV_PAIR * pAvPair) | ['pAvPair'] | static INLINE SIZE_T ntlm_av_pair_get_len(const NTLM_AV_PAIR* pAvPair)
{
UINT16 AvLen;
Data_Read_UINT16(&pAvPair->AvLen, AvLen);
return AvLen;
} | 25 | True | 1 |
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_av_pair_get_next_offset | ntlm_av_pair_get_next_offset( NTLM_AV_PAIR * pAvPair) | ['pAvPair'] | static size_t ntlm_av_pair_get_next_offset(NTLM_AV_PAIR* pAvPair)
{
return ntlm_av_pair_get_len(pAvPair) + sizeof(NTLM_AV_PAIR);
} | 19 | True | 1 |
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_av_pair_next | ntlm_av_pair_next( NTLM_AV_PAIR * pAvPair , size_t * pcbAvPair) | ['pAvPair', 'pcbAvPair'] | static NTLM_AV_PAIR* ntlm_av_pair_next(NTLM_AV_PAIR* pAvPair, size_t* pcbAvPair)
{
size_t offset;
if (!pcbAvPair)
return NULL;
if (!ntlm_av_pair_check(pAvPair, *pcbAvPair))
return NULL;
offset = ntlm_av_pair_get_next_offset(pAvPair);
*pcbAvPair -= offset;
return (NTLM_AV_PAIR*)((PBYTE)pAvPair + offset);
} | 63 | True | 1 |
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_construct_authenticate_target_info | ntlm_construct_authenticate_target_info( NTLM_CONTEXT * context) | ['context'] | int ntlm_construct_authenticate_target_info(NTLM_CONTEXT* context)
{
ULONG size;
ULONG AvPairsCount;
ULONG AvPairsValueLength;
NTLM_AV_PAIR* AvTimestamp;
NTLM_AV_PAIR* AvNbDomainName;
NTLM_AV_PAIR* AvNbComputerName;
NTLM_AV_PAIR* AvDnsDomainName;
NTLM_AV_PAIR* AvDnsComputerName;
NTLM_AV_PAIR* AvDnsTreeName;
NTLM_AV_PAIR* ChallengeTargetInfo;
NTLM_AV_PAIR* AuthenticateTargetInfo;
size_t cbAvTimestamp;
size_t cbAvNbDomainName;
size_t cbAvNbComputerName;
size_t cbAvDnsDomainName;
size_t cbAvDnsComputerName;
size_t cbAvDnsTreeName;
size_t cbChallengeTargetInfo;
size_t cbAuthenticateTargetInfo;
AvPairsCount = 1;
AvPairsValueLength = 0;
ChallengeTargetInfo = (NTLM_AV_PAIR*)context->ChallengeTargetInfo.pvBuffer;
cbChallengeTargetInfo = context->ChallengeTargetInfo.cbBuffer;
AvNbDomainName = ntlm_av_pair_get(ChallengeTargetInfo, cbChallengeTargetInfo, MsvAvNbDomainName,
&cbAvNbDomainName);
AvNbComputerName = ntlm_av_pair_get(ChallengeTargetInfo, cbChallengeTargetInfo,
MsvAvNbComputerName, &cbAvNbComputerName);
AvDnsDomainName = ntlm_av_pair_get(ChallengeTargetInfo, cbChallengeTargetInfo,
MsvAvDnsDomainName, &cbAvDnsDomainName);
AvDnsComputerName = ntlm_av_pair_get(ChallengeTargetInfo, cbChallengeTargetInfo,
MsvAvDnsComputerName, &cbAvDnsComputerName);
AvDnsTreeName = ntlm_av_pair_get(ChallengeTargetInfo, cbChallengeTargetInfo, MsvAvDnsTreeName,
&cbAvDnsTreeName);
AvTimestamp = ntlm_av_pair_get(ChallengeTargetInfo, cbChallengeTargetInfo, MsvAvTimestamp,
&cbAvTimestamp);
if (AvNbDomainName)
{
AvPairsCount++; /* MsvAvNbDomainName */
AvPairsValueLength += ntlm_av_pair_get_len(AvNbDomainName);
}
if (AvNbComputerName)
{
AvPairsCount++; /* MsvAvNbComputerName */
AvPairsValueLength += ntlm_av_pair_get_len(AvNbComputerName);
}
if (AvDnsDomainName)
{
AvPairsCount++; /* MsvAvDnsDomainName */
AvPairsValueLength += ntlm_av_pair_get_len(AvDnsDomainName);
}
if (AvDnsComputerName)
{
AvPairsCount++; /* MsvAvDnsComputerName */
AvPairsValueLength += ntlm_av_pair_get_len(AvDnsComputerName);
}
if (AvDnsTreeName)
{
AvPairsCount++; /* MsvAvDnsTreeName */
AvPairsValueLength += ntlm_av_pair_get_len(AvDnsTreeName);
}
AvPairsCount++; /* MsvAvTimestamp */
AvPairsValueLength += 8;
if (context->UseMIC)
{
AvPairsCount++; /* MsvAvFlags */
AvPairsValueLength += 4;
}
if (context->SendSingleHostData)
{
AvPairsCount++; /* MsvAvSingleHost */
ntlm_compute_single_host_data(context);
AvPairsValueLength += context->SingleHostData.Size;
}
/**
* Extended Protection for Authentication:
* http://blogs.technet.com/b/srd/archive/2009/12/08/extended-protection-for-authentication.aspx
*/
if (!context->SuppressExtendedProtection)
{
/**
* SEC_CHANNEL_BINDINGS structure
* http://msdn.microsoft.com/en-us/library/windows/desktop/dd919963/
*/
AvPairsCount++; /* MsvChannelBindings */
AvPairsValueLength += 16;
ntlm_compute_channel_bindings(context);
if (context->ServicePrincipalName.Length > 0)
{
AvPairsCount++; /* MsvAvTargetName */
AvPairsValueLength += context->ServicePrincipalName.Length;
}
}
size = ntlm_av_pair_list_size(AvPairsCount, AvPairsValueLength);
if (context->NTLMv2)
size += 8; /* unknown 8-byte padding */
if (!sspi_SecBufferAlloc(&context->AuthenticateTargetInfo, size))
goto fail;
AuthenticateTargetInfo = (NTLM_AV_PAIR*)context->AuthenticateTargetInfo.pvBuffer;
cbAuthenticateTargetInfo = context->AuthenticateTargetInfo.cbBuffer;
if (!ntlm_av_pair_list_init(AuthenticateTargetInfo, cbAuthenticateTargetInfo))
goto fail;
if (AvNbDomainName)
{
if (!ntlm_av_pair_add_copy(AuthenticateTargetInfo, cbAuthenticateTargetInfo, AvNbDomainName,
cbAvNbDomainName))
goto fail;
}
if (AvNbComputerName)
{
if (!ntlm_av_pair_add_copy(AuthenticateTargetInfo, cbAuthenticateTargetInfo,
AvNbComputerName, cbAvNbComputerName))
goto fail;
}
if (AvDnsDomainName)
{
if (!ntlm_av_pair_add_copy(AuthenticateTargetInfo, cbAuthenticateTargetInfo,
AvDnsDomainName, cbAvDnsDomainName))
goto fail;
}
if (AvDnsComputerName)
{
if (!ntlm_av_pair_add_copy(AuthenticateTargetInfo, cbAuthenticateTargetInfo,
AvDnsComputerName, cbAvDnsComputerName))
goto fail;
}
if (AvDnsTreeName)
{
if (!ntlm_av_pair_add_copy(AuthenticateTargetInfo, cbAuthenticateTargetInfo, AvDnsTreeName,
cbAvDnsTreeName))
goto fail;
}
if (AvTimestamp)
{
if (!ntlm_av_pair_add_copy(AuthenticateTargetInfo, cbAuthenticateTargetInfo, AvTimestamp,
cbAvTimestamp))
goto fail;
}
if (context->UseMIC)
{
UINT32 flags;
Data_Write_UINT32(&flags, MSV_AV_FLAGS_MESSAGE_INTEGRITY_CHECK);
if (!ntlm_av_pair_add(AuthenticateTargetInfo, cbAuthenticateTargetInfo, MsvAvFlags,
(PBYTE)&flags, 4))
goto fail;
}
if (context->SendSingleHostData)
{
if (!ntlm_av_pair_add(AuthenticateTargetInfo, cbAuthenticateTargetInfo, MsvAvSingleHost,
(PBYTE)&context->SingleHostData, context->SingleHostData.Size))
goto fail;
}
if (!context->SuppressExtendedProtection)
{
if (!ntlm_av_pair_add(AuthenticateTargetInfo, cbAuthenticateTargetInfo, MsvChannelBindings,
context->ChannelBindingsHash, 16))
goto fail;
if (context->ServicePrincipalName.Length > 0)
{
if (!ntlm_av_pair_add(AuthenticateTargetInfo, cbAuthenticateTargetInfo, MsvAvTargetName,
(PBYTE)context->ServicePrincipalName.Buffer,
context->ServicePrincipalName.Length))
goto fail;
}
}
if (context->NTLMv2)
{
NTLM_AV_PAIR* AvEOL;
AvEOL = ntlm_av_pair_get(ChallengeTargetInfo, cbChallengeTargetInfo, MsvAvEOL, NULL);
if (!AvEOL)
goto fail;
ZeroMemory(AvEOL, sizeof(NTLM_AV_PAIR));
}
return 1;
fail:
sspi_SecBufferFree(&context->AuthenticateTargetInfo);
return -1;
} | 772 | True | 1 |
CVE-2020-11097 | False | False | False | False | AV:N/AC:L/Au:S/C:P/I:N/A:P | NETWORK | LOW | SINGLE | PARTIAL | NONE | PARTIAL | 5.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:L | NETWORK | LOW | LOW | NONE | UNCHANGED | LOW | NONE | LOW | 5.4 | MEDIUM | 2.8 | 2.5 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/58a3122250d54de3a944c487776bcd4d1da4721e', 'refsource': 'MISC', 'tags': ['Patch', 'Third Party Advisory']}, {'url': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'name': 'https://github.com/FreeRDP/FreeRDP/security/advisories/GHSA-c8x2-c3c9-9r3f', 'refsource': 'CONFIRM', 'tags': ['Third Party Advisory']}, {'url': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'name': 'http://www.freerdp.com/2020/06/22/2_1_2-released', 'refsource': 'MISC', 'tags': ['Release Notes', 'Vendor Advisory']}, {'url': 'http://lists.opensuse.org/opensuse-security-announce/2020-07/msg00080.html', 'name': 'openSUSE-SU-2020:1090', 'refsource': 'SUSE', 'tags': ['Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/6Y35HBHG2INICLSGCIKNAR7GCXEHQACQ/', 'name': 'FEDORA-2020-8d5f86e29a', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://lists.fedoraproject.org/archives/list/[email protected]/message/XOZLH35OJWIQLM7FYDXAP2EAUBDXE76V/', 'name': 'FEDORA-2020-a3432485db', 'refsource': 'FEDORA', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/4481-1/', 'name': 'USN-4481-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndExcluding': '2.1.2', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:31:*:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:opensuse:leap:15.1:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:20.04:*:*:*:lts:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'In FreeRDP before version 2.1.2, an out of bounds read occurs resulting in accessing a memory location that is outside of the boundaries of the static array PRIMARY_DRAWING_ORDER_FIELD_BYTES. This is fixed in version 2.1.2.'}] | 2022-07-19T11:46Z | 2020-06-22T22:15Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | akallabeth | 2020-06-02 12:26:40+02:00 | Fixed OOB read in ntlm_av_pair_get
CVE-2020-11097 thanks to @antonio-morales for finding this. | 58a3122250d54de3a944c487776bcd4d1da4721e | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_print_av_pair_list | ntlm_print_av_pair_list( NTLM_AV_PAIR * pAvPairList , size_t cbAvPairList) | ['pAvPairList', 'cbAvPairList'] | void ntlm_print_av_pair_list(NTLM_AV_PAIR* pAvPairList, size_t cbAvPairList)
{
size_t cbAvPair = cbAvPairList;
NTLM_AV_PAIR* pAvPair = pAvPairList;
if (!ntlm_av_pair_check(pAvPair, cbAvPair))
return;
WLog_INFO(TAG, "AV_PAIRs =");
while (pAvPair && ntlm_av_pair_get_id(pAvPair) != MsvAvEOL)
{
WLog_INFO(TAG, "\t%s AvId: %" PRIu16 " AvLen: %" PRIu16 "",
AV_PAIR_STRINGS[ntlm_av_pair_get_id(pAvPair)], ntlm_av_pair_get_id(pAvPair),
ntlm_av_pair_get_len(pAvPair));
winpr_HexDump(TAG, WLOG_INFO, ntlm_av_pair_get_value_pointer(pAvPair),
ntlm_av_pair_get_len(pAvPair));
pAvPair = ntlm_av_pair_next(pAvPair, &cbAvPair);
}
} | 110 | True | 1 |
CVE-2018-8789 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://usn.ubuntu.com/3845-1/', 'name': 'USN-3845-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/106938', 'name': '106938', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/02/msg00015.html', 'name': '[debian-lts-announce] 20190209 [SECURITY] [DLA 1666-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'name': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3845-2/', 'name': 'USN-3845-2', 'refsource': 'UBUNTU', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.2.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'FreeRDP prior to version 2.0.0-rc4 contains several Out-Of-Bounds Reads in the NTLM Authentication module that results in a Denial of Service (segfault).'}] | 2019-06-03T16:29Z | 2018-11-29T18:29Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Armin Novak | 2018-10-22 16:00:03+02:00 | Fixed CVE-2018-8789
Thanks to Eyal Itkin from Check Point Software Technologies. | 2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_free_message_fields_buffer | ntlm_free_message_fields_buffer( NTLM_MESSAGE_FIELDS * fields) | ['fields'] | void ntlm_free_message_fields_buffer(NTLM_MESSAGE_FIELDS* fields)
{
if (fields)
{
if (fields->Buffer)
{
free(fields->Buffer);
fields->Len = 0;
fields->MaxLen = 0;
fields->Buffer = NULL;
fields->BufferOffset = 0;
}
}
} | 53 | True | 1 |
CVE-2018-8789 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://usn.ubuntu.com/3845-1/', 'name': 'USN-3845-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/106938', 'name': '106938', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/02/msg00015.html', 'name': '[debian-lts-announce] 20190209 [SECURITY] [DLA 1666-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'name': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3845-2/', 'name': 'USN-3845-2', 'refsource': 'UBUNTU', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.2.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'FreeRDP prior to version 2.0.0-rc4 contains several Out-Of-Bounds Reads in the NTLM Authentication module that results in a Denial of Service (segfault).'}] | 2019-06-03T16:29Z | 2018-11-29T18:29Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Armin Novak | 2018-10-22 16:00:03+02:00 | Fixed CVE-2018-8789
Thanks to Eyal Itkin from Check Point Software Technologies. | 2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_populate_message_header | ntlm_populate_message_header( NTLM_MESSAGE_HEADER * header , UINT32 MessageType) | ['header', 'MessageType'] | void ntlm_populate_message_header(NTLM_MESSAGE_HEADER* header, UINT32 MessageType)
{
CopyMemory(header->Signature, NTLM_SIGNATURE, sizeof(NTLM_SIGNATURE));
header->MessageType = MessageType;
} | 31 | True | 1 |
CVE-2018-8789 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://usn.ubuntu.com/3845-1/', 'name': 'USN-3845-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/106938', 'name': '106938', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/02/msg00015.html', 'name': '[debian-lts-announce] 20190209 [SECURITY] [DLA 1666-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'name': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3845-2/', 'name': 'USN-3845-2', 'refsource': 'UBUNTU', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.2.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'FreeRDP prior to version 2.0.0-rc4 contains several Out-Of-Bounds Reads in the NTLM Authentication module that results in a Denial of Service (segfault).'}] | 2019-06-03T16:29Z | 2018-11-29T18:29Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Armin Novak | 2018-10-22 16:00:03+02:00 | Fixed CVE-2018-8789
Thanks to Eyal Itkin from Check Point Software Technologies. | 2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_print_message_fields | ntlm_print_message_fields( NTLM_MESSAGE_FIELDS * fields , const char * name) | ['fields', 'name'] | void ntlm_print_message_fields(NTLM_MESSAGE_FIELDS* fields, const char* name)
{
WLog_DBG(TAG, "%s (Len: %"PRIu16" MaxLen: %"PRIu16" BufferOffset: %"PRIu32")",
name, fields->Len, fields->MaxLen, fields->BufferOffset);
if (fields->Len > 0)
winpr_HexDump(TAG, WLOG_DEBUG, fields->Buffer, fields->Len);
} | 63 | True | 1 |
CVE-2018-8789 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://usn.ubuntu.com/3845-1/', 'name': 'USN-3845-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/106938', 'name': '106938', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/02/msg00015.html', 'name': '[debian-lts-announce] 20190209 [SECURITY] [DLA 1666-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'name': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3845-2/', 'name': 'USN-3845-2', 'refsource': 'UBUNTU', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.2.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'FreeRDP prior to version 2.0.0-rc4 contains several Out-Of-Bounds Reads in the NTLM Authentication module that results in a Denial of Service (segfault).'}] | 2019-06-03T16:29Z | 2018-11-29T18:29Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Armin Novak | 2018-10-22 16:00:03+02:00 | Fixed CVE-2018-8789
Thanks to Eyal Itkin from Check Point Software Technologies. | 2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_print_negotiate_flags | ntlm_print_negotiate_flags( UINT32 flags) | ['flags'] | void ntlm_print_negotiate_flags(UINT32 flags)
{
int i;
const char* str;
WLog_INFO(TAG, "negotiateFlags \"0x%08"PRIX32"\"", flags);
for (i = 31; i >= 0; i--)
{
if ((flags >> i) & 1)
{
str = NTLM_NEGOTIATE_STRINGS[(31 - i)];
WLog_INFO(TAG, "\t%s (%d),", str, (31 - i));
}
}
} | 80 | True | 1 |
CVE-2018-8789 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://usn.ubuntu.com/3845-1/', 'name': 'USN-3845-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/106938', 'name': '106938', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/02/msg00015.html', 'name': '[debian-lts-announce] 20190209 [SECURITY] [DLA 1666-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'name': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3845-2/', 'name': 'USN-3845-2', 'refsource': 'UBUNTU', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.2.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'FreeRDP prior to version 2.0.0-rc4 contains several Out-Of-Bounds Reads in the NTLM Authentication module that results in a Denial of Service (segfault).'}] | 2019-06-03T16:29Z | 2018-11-29T18:29Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Armin Novak | 2018-10-22 16:00:03+02:00 | Fixed CVE-2018-8789
Thanks to Eyal Itkin from Check Point Software Technologies. | 2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_read_message_fields | ntlm_read_message_fields( wStream * s , NTLM_MESSAGE_FIELDS * fields) | ['s', 'fields'] | int ntlm_read_message_fields(wStream* s, NTLM_MESSAGE_FIELDS* fields)
{
if (Stream_GetRemainingLength(s) < 8)
return -1;
Stream_Read_UINT16(s, fields->Len); /* Len (2 bytes) */
Stream_Read_UINT16(s, fields->MaxLen); /* MaxLen (2 bytes) */
Stream_Read_UINT32(s, fields->BufferOffset); /* BufferOffset (4 bytes) */
return 1;
} | 55 | True | 1 |
CVE-2018-8789 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://usn.ubuntu.com/3845-1/', 'name': 'USN-3845-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/106938', 'name': '106938', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/02/msg00015.html', 'name': '[debian-lts-announce] 20190209 [SECURITY] [DLA 1666-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'name': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3845-2/', 'name': 'USN-3845-2', 'refsource': 'UBUNTU', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.2.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'FreeRDP prior to version 2.0.0-rc4 contains several Out-Of-Bounds Reads in the NTLM Authentication module that results in a Denial of Service (segfault).'}] | 2019-06-03T16:29Z | 2018-11-29T18:29Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Armin Novak | 2018-10-22 16:00:03+02:00 | Fixed CVE-2018-8789
Thanks to Eyal Itkin from Check Point Software Technologies. | 2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_read_message_fields_buffer | ntlm_read_message_fields_buffer( wStream * s , NTLM_MESSAGE_FIELDS * fields) | ['s', 'fields'] | int ntlm_read_message_fields_buffer(wStream* s, NTLM_MESSAGE_FIELDS* fields)
{
if (fields->Len > 0)
{
if ((fields->BufferOffset + fields->Len) > Stream_Length(s))
return -1;
fields->Buffer = (PBYTE) malloc(fields->Len);
if (!fields->Buffer)
return -1;
Stream_SetPosition(s, fields->BufferOffset);
Stream_Read(s, fields->Buffer, fields->Len);
}
return 1;
} | 93 | True | 1 |
CVE-2018-8789 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://usn.ubuntu.com/3845-1/', 'name': 'USN-3845-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/106938', 'name': '106938', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/02/msg00015.html', 'name': '[debian-lts-announce] 20190209 [SECURITY] [DLA 1666-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'name': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3845-2/', 'name': 'USN-3845-2', 'refsource': 'UBUNTU', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.2.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'FreeRDP prior to version 2.0.0-rc4 contains several Out-Of-Bounds Reads in the NTLM Authentication module that results in a Denial of Service (segfault).'}] | 2019-06-03T16:29Z | 2018-11-29T18:29Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Armin Novak | 2018-10-22 16:00:03+02:00 | Fixed CVE-2018-8789
Thanks to Eyal Itkin from Check Point Software Technologies. | 2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_read_message_header | ntlm_read_message_header( wStream * s , NTLM_MESSAGE_HEADER * header) | ['s', 'header'] | int ntlm_read_message_header(wStream* s, NTLM_MESSAGE_HEADER* header)
{
if (Stream_GetRemainingLength(s) < 12)
return -1;
Stream_Read(s, header->Signature, 8);
Stream_Read_UINT32(s, header->MessageType);
if (strncmp((char*) header->Signature, NTLM_SIGNATURE, 8) != 0)
return -1;
return 1;
} | 71 | True | 1 |
CVE-2018-8789 | False | False | False | False | AV:N/AC:L/Au:N/C:N/I:N/A:P | NETWORK | LOW | NONE | NONE | NONE | PARTIAL | 5.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H | NETWORK | LOW | NONE | NONE | UNCHANGED | NONE | NONE | HIGH | 7.5 | HIGH | 3.9 | 3.6 | False | [{'url': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'name': 'https://github.com/FreeRDP/FreeRDP/commit/2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6', 'refsource': 'CONFIRM', 'tags': ['Patch', 'Vendor Advisory']}, {'url': 'https://usn.ubuntu.com/3845-1/', 'name': 'USN-3845-1', 'refsource': 'UBUNTU', 'tags': ['Third Party Advisory']}, {'url': 'http://www.securityfocus.com/bid/106938', 'name': '106938', 'refsource': 'BID', 'tags': ['Third Party Advisory', 'VDB Entry']}, {'url': 'https://lists.debian.org/debian-lts-announce/2019/02/msg00015.html', 'name': '[debian-lts-announce] 20190209 [SECURITY] [DLA 1666-1] freerdp security update', 'refsource': 'MLIST', 'tags': ['Mailing List', 'Third Party Advisory']}, {'url': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'name': 'https://research.checkpoint.com/reverse-rdp-attack-code-execution-on-rdp-clients/', 'refsource': 'CONFIRM', 'tags': ['Exploit', 'Third Party Advisory']}, {'url': 'https://usn.ubuntu.com/3845-2/', 'name': 'USN-3845-2', 'refsource': 'UBUNTU', 'tags': []}] | [{'description': [{'lang': 'en', 'value': 'CWE-125'}]}] | MEDIUM | [{'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc3:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc2:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:2.0.0:rc1:*:*:*:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:a:freerdp:freerdp:*:*:*:*:*:*:*:*', 'versionEndIncluding': '1.2.0', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:*', 'cpe_name': []}, {'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:*', 'cpe_name': []}]}, {'operator': 'OR', 'children': [], 'cpe_match': [{'vulnerable': True, 'cpe23Uri': 'cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*', 'cpe_name': []}]}] | [{'lang': 'en', 'value': 'FreeRDP prior to version 2.0.0-rc4 contains several Out-Of-Bounds Reads in the NTLM Authentication module that results in a Denial of Service (segfault).'}] | 2019-06-03T16:29Z | 2018-11-29T18:29Z | Out-of-bounds Read | The software reads data past the end, or before the beginning, of the intended buffer. | Typically, this can allow attackers to read sensitive information from other memory locations or cause a crash. A crash can occur when the code reads a variable amount of data and assumes that a sentinel exists to stop the read operation, such as a NUL in a string. The expected sentinel might not be located in the out-of-bounds memory, causing excessive data to be read, leading to a segmentation fault or a buffer overflow. The software may modify an index or perform pointer arithmetic that references a memory location that is outside of the boundaries of the buffer. A subsequent read operation then produces undefined or unexpected results.
| https://cwe.mitre.org/data/definitions/125.html | 0 | Armin Novak | 2018-10-22 16:00:03+02:00 | Fixed CVE-2018-8789
Thanks to Eyal Itkin from Check Point Software Technologies. | 2ee663f39dc8dac3d9988e847db19b2d7e3ac8c6 | False | FreeRDP/FreeRDP | FreeRDP is a free remote desktop protocol library and clients | 2011-06-30 19:14:15 | 2022-08-25 06:47:01 | http://www.freerdp.com/ | FreeRDP | 7261.0 | 18041.0 | ntlm_write_message_fields | ntlm_write_message_fields( wStream * s , NTLM_MESSAGE_FIELDS * fields) | ['s', 'fields'] | void ntlm_write_message_fields(wStream* s, NTLM_MESSAGE_FIELDS* fields)
{
if (fields->MaxLen < 1)
fields->MaxLen = fields->Len;
Stream_Write_UINT16(s, fields->Len); /* Len (2 bytes) */
Stream_Write_UINT16(s, fields->MaxLen); /* MaxLen (2 bytes) */
Stream_Write_UINT32(s, fields->BufferOffset); /* BufferOffset (4 bytes) */
} | 55 | True | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.