Datasets:

is_vulnerable
bool
2 classes
func
stringlengths
28
484k
cwe
listlengths
1
2
project
stringclasses
592 values
commit_id
stringlengths
7
44
hash
stringlengths
34
39
big_vul_idx
int64
4.09k
189k
idx
int64
0
522k
cwe_description
stringclasses
81 values
false
long ssl_get_algorithm2(SSL *s) { long alg2 = s->s3->tmp.new_cipher->algorithm2; if (TLS1_get_version(s) >= TLS1_2_VERSION && alg2 == (SSL_HANDSHAKE_MAC_DEFAULT|TLS1_PRF)) return SSL_HANDSHAKE_MAC_SHA256 | TLS1_PRF_SHA256; return alg2; }
[ "CWE-310" ]
openssl
ca989269a2876bae79393bd54c3e72d49975fc75
255087747659226932756944884868284698117
177,739
0
This weakness pertains to the use of cryptographic functions that are weak, misconfigured, or outdated, which undermines the intended protection of encrypted data and communications.
true
long ssl_get_algorithm2(SSL *s) { long alg2 = s->s3->tmp.new_cipher->algorithm2; if (s->method->version == TLS1_2_VERSION && alg2 == (SSL_HANDSHAKE_MAC_DEFAULT|TLS1_PRF)) return SSL_HANDSHAKE_MAC_SHA256 | TLS1_PRF_SHA256; return alg2; }
[ "CWE-310" ]
openssl
ca989269a2876bae79393bd54c3e72d49975fc75
185448168336389579295943711163093638128
177,739
157,856
This weakness pertains to the use of cryptographic functions that are weak, misconfigured, or outdated, which undermines the intended protection of encrypted data and communications.
false
gnutls_session_get_data (gnutls_session_t session, void *session_data, size_t * session_data_size) { gnutls_datum_t psession; int ret; if (session->internals.resumable == RESUME_FALSE) return GNUTLS_E_INVALID_SESSION; psession.data = session_data; ret = _gnutls_session_pack (s...
[ "CWE-119" ]
savannah
190cef6eed37d0e73a73c1e205eb31d45ab60a3c
266005388725654386397960628110885023158
177,741
1
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
gnutls_session_get_data (gnutls_session_t session, void *session_data, size_t * session_data_size) { gnutls_datum_t psession; int ret; if (session->internals.resumable == RESUME_FALSE) return GNUTLS_E_INVALID_SESSION; psession.data = session_data; ret = _gnutls_session_pack (s...
[ "CWE-119" ]
savannah
190cef6eed37d0e73a73c1e205eb31d45ab60a3c
217937088037221829579003352102231694649
177,741
157,857
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
gnutls_session_get_data (gnutls_session_t session, void *session_data, size_t * session_data_size) { gnutls_datum_t psession; int ret; if (session->internals.resumable == RESUME_FALSE) return GNUTLS_E_INVALID_SESSION; psession.data = session_data; ret = _gnutls_session_pack (s...
[ "CWE-119" ]
savannah
e82ef4545e9e98cbcb032f55d7c750b81e3a0450
162619476999663411812822607346255778028
177,742
2
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
gnutls_session_get_data (gnutls_session_t session, void *session_data, size_t * session_data_size) { gnutls_datum_t psession; int ret; if (session->internals.resumable == RESUME_FALSE) return GNUTLS_E_INVALID_SESSION; psession.data = session_data; ret = _gnutls_session_pack (s...
[ "CWE-119" ]
savannah
e82ef4545e9e98cbcb032f55d7c750b81e3a0450
282098968981021847575763555214602715866
177,742
157,858
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
getftp (struct url *u, wgint passed_expected_bytes, wgint *qtyread, wgint restval, ccon *con, int count, wgint *last_expected_bytes, FILE *warc_tmp) { int csock, dtsock, local_sock, res; uerr_t err = RETROK; /* appease the compiler */ FILE *fp; char *respline, *tms; const char *user...
[ "CWE-200" ]
savannah
075d7556964f5a871a73c22ac4b69f5361295099
114753069609161113628525870463495041364
177,746
3
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
true
getftp (struct url *u, wgint passed_expected_bytes, wgint *qtyread, wgint restval, ccon *con, int count, wgint *last_expected_bytes, FILE *warc_tmp) { int csock, dtsock, local_sock, res; uerr_t err = RETROK; /* appease the compiler */ FILE *fp; char *respline, *tms; const char *user...
[ "CWE-200" ]
savannah
075d7556964f5a871a73c22ac4b69f5361295099
230484519226133503077096905290707768008
177,746
157,859
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
false
add_range(fz_context *ctx, pdf_cmap *cmap, unsigned int low, unsigned int high, unsigned int out, int check_for_overlap, int many) { int current; cmap_splay *tree; if (low > high) { fz_warn(ctx, "range limits out of range in cmap %s", cmap->cmap_name); return; } tree = cmap->tree; if (cmap->tlen) { uns...
[ "CWE-416" ]
ghostscript
f597300439e62f5e921f0d7b1e880b5c1a1f1607
73361849657881456808355395187124534685
177,749
6
The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory...
true
add_range(fz_context *ctx, pdf_cmap *cmap, unsigned int low, unsigned int high, unsigned int out, int check_for_overlap, int many) { int current; cmap_splay *tree; if (low > high) { fz_warn(ctx, "range limits out of range in cmap %s", cmap->cmap_name); return; } tree = cmap->tree; if (cmap->tlen) { uns...
[ "CWE-416" ]
ghostscript
f597300439e62f5e921f0d7b1e880b5c1a1f1607
124485393887214475174443050553758560429
177,749
157,862
The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory...
false
add_range(fz_context *ctx, pdf_cmap *cmap, unsigned int low, unsigned int high, unsigned int out, int check_for_overlap, int many) { int current; cmap_splay *tree; if (low > high) { fz_warn(ctx, "range limits out of range in cmap %s", cmap->cmap_name); return; } tree = cmap->tree; if (cmap->tlen) { uns...
[ "CWE-416" ]
ghostscript
71ceebcf56e682504da22c4035b39a2d451e8ffd
72963719227623516762803191293835350908
177,751
8
The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory...
true
add_range(fz_context *ctx, pdf_cmap *cmap, unsigned int low, unsigned int high, unsigned int out, int check_for_overlap, int many) { int current; cmap_splay *tree; if (low > high) { fz_warn(ctx, "range limits out of range in cmap %s", cmap->cmap_name); return; } tree = cmap->tree; if (cmap->tlen) { uns...
[ "CWE-416" ]
ghostscript
71ceebcf56e682504da22c4035b39a2d451e8ffd
146583299015225488764454157462983427672
177,751
157,863
The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory...
false
pdf_show_image(fz_context *ctx, pdf_run_processor *pr, fz_image *image) { pdf_gstate *gstate = pr->gstate + pr->gtop; fz_matrix image_ctm; fz_rect bbox; softmask_save softmask = { NULL }; if (pr->super.hidden) return; break; case PDF_MAT_SHADE: if (gsta...
[ "CWE-20" ]
ghostscript
b2e7d38e845c7d4922d05e6e41f3a2dc1bc1b14a
327424409628836476675717770567987598130
177,752
9
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.
true
pdf_show_image(fz_context *ctx, pdf_run_processor *pr, fz_image *image) { pdf_gstate *gstate = pr->gstate + pr->gtop; fz_matrix image_ctm; fz_rect bbox; if (pr->super.hidden) return; break; case PDF_MAT_SHADE: if (gstate->fill.shade) { fz_clip_image_mas...
[ "CWE-20" ]
ghostscript
b2e7d38e845c7d4922d05e6e41f3a2dc1bc1b14a
103996721370606474168467973808469707242
177,752
157,864
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.
false
sparse_dump_region (struct tar_sparse_file *file, size_t i) { union block *blk; off_t bytes_left = file->stat_info->sparse_map[i].numbytes; if (!lseek_or_error (file, file->stat_info->sparse_map[i].offset)) return false; while (bytes_left > 0) { size_t bufsize = (bytes_left > BLOCKSIZE) ? BLOCKS...
[ "CWE-835" ]
savannah
c15c42ccd1e2377945fd0414eca1a49294bff454
265039722963046446329719176641029797849
177,768
23
The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.
true
sparse_dump_region (struct tar_sparse_file *file, size_t i) { union block *blk; off_t bytes_left = file->stat_info->sparse_map[i].numbytes; if (!lseek_or_error (file, file->stat_info->sparse_map[i].offset)) return false; while (bytes_left > 0) { size_t bufsize = (bytes_left > BLOCKSIZE) ? BLOCKS...
[ "CWE-835" ]
savannah
c15c42ccd1e2377945fd0414eca1a49294bff454
67919736298016751923724729486340465129
177,768
157,878
The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.
false
int read_ndx_and_attrs(int f_in, int f_out, int *iflag_ptr, uchar *type_ptr, char *buf, int *len_ptr) { int len, iflags = 0; struct file_list *flist; uchar fnamecmp_type = FNAMECMP_FNAME; int ndx; read_loop: while (1) { ndx = read_ndx(f_in); if (ndx >= 0) break; if (ndx == NDX_DONE) return...
[ "Other" ]
samba
70aeb5fddd1b2f8e143276f8d5a085db16c593b9
218007185182567162788891557146038450271
177,770
25
Unknown
true
int read_ndx_and_attrs(int f_in, int f_out, int *iflag_ptr, uchar *type_ptr, char *buf, int *len_ptr) { int len, iflags = 0; struct file_list *flist; uchar fnamecmp_type = FNAMECMP_FNAME; int ndx; read_loop: while (1) { ndx = read_ndx(f_in); if (ndx >= 0) break; if (ndx == NDX_DONE) return...
[ "Other" ]
samba
70aeb5fddd1b2f8e143276f8d5a085db16c593b9
173509734569313928092432437809749954291
177,770
157,880
Unknown
false
int dns_read_name(unsigned char *buffer, unsigned char *bufend, unsigned char *name, char *destination, int dest_len, int *offset) { int nb_bytes = 0, n = 0; int label_len; unsigned char *reader = name; char *dest = destination; while (1) { /* Name compression ...
[ "CWE-835" ]
haproxy
58df5aea0a0c926b2238f65908f5e9f83d1cca25
6381338430754950645676757195002300075
177,771
26
The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.
true
int dns_read_name(unsigned char *buffer, unsigned char *bufend, unsigned char *name, char *destination, int dest_len, int *offset, unsigned int depth) { int nb_bytes = 0, n = 0; int label_len; unsigned char *reader = name; char *dest = destination; while (1) { ...
[ "CWE-835" ]
haproxy
58df5aea0a0c926b2238f65908f5e9f83d1cca25
89452639221463286839806233233037284865
177,771
157,881
The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.
false
void SplashOutputDev::drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, int *maskColors, GBool inlineImg) { double *ctm; SplashCoord mat[6]; SplashOutImageData imgData; SplashColorMode srcMode; SplashImageSource src; GfxGray gray; GfxRGB rg...
[ "CWE-189" ]
poppler
284a92899602daa4a7f429e61849e794569310b5
304076538021281751998637961089745244390
177,774
27
This weakness involves numeric computation errors, such as integer overflows, underflows, or precision losses, which can lead to miscalculations and exploitable behaviors in software.
true
void SplashOutputDev::drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, int *maskColors, GBool inlineImg) { double *ctm; SplashCoord mat[6]; SplashOutImageData imgData; SplashColorMode srcMode; SplashImageSource src; GfxGray gray; GfxRGB rg...
[ "CWE-189" ]
poppler
284a92899602daa4a7f429e61849e794569310b5
238370966634441304873792337937568791030
177,774
157,883
This weakness involves numeric computation errors, such as integer overflows, underflows, or precision losses, which can lead to miscalculations and exploitable behaviors in software.
false
void ArthurOutputDev::drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, int *maskColors, GBool inlineImg) { unsigned char *buffer; unsigned int *dest; int x, y; ImageStream *imgStr; Guchar *pix; int i; double *ctm; QMatrix matrix; int...
[ "CWE-189" ]
poppler
7b2d314a61fd0e12f47c62996cb49ec0d1ba747a
145223011821522984832787544024029108709
177,775
28
This weakness involves numeric computation errors, such as integer overflows, underflows, or precision losses, which can lead to miscalculations and exploitable behaviors in software.
true
void ArthurOutputDev::drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, int *maskColors, GBool inlineImg) { unsigned char *buffer; unsigned int *dest; int x, y; ImageStream *imgStr; Guchar *pix; int i; double *ctm; QMatrix matrix; int...
[ "CWE-189" ]
poppler
7b2d314a61fd0e12f47c62996cb49ec0d1ba747a
328681969473388669211085267743237662516
177,775
157,884
This weakness involves numeric computation errors, such as integer overflows, underflows, or precision losses, which can lead to miscalculations and exploitable behaviors in software.
false
DynamicMetadataProvider::DynamicMetadataProvider(const DOMElement* e) : saml2md::DynamicMetadataProvider(e), m_verifyHost(XMLHelper::getAttrBool(e, true, verifyHost)), m_ignoreTransport(XMLHelper::getAttrBool(e, false, ignoreTransport)), m_encoded(true), m_trust(nullptr) { const DOME...
[ "CWE-347" ]
shibboleth
b66cceb0e992c351ad5e2c665229ede82f261b16
11538925675754479849567947994472519439
177,795
40
The product does not verify, or incorrectly verifies, the cryptographic signature for data.
true
DynamicMetadataProvider::DynamicMetadataProvider(const DOMElement* e) : saml2md::DynamicMetadataProvider(e), MetadataProvider(e), m_verifyHost(XMLHelper::getAttrBool(e, true, verifyHost)), m_ignoreTransport(XMLHelper::getAttrBool(e, false, ignoreTransport)), m_encoded(true), m_trust(null...
[ "CWE-347" ]
shibboleth
b66cceb0e992c351ad5e2c665229ede82f261b16
313820794002673879698519839177687302127
177,795
157,898
The product does not verify, or incorrectly verifies, the cryptographic signature for data.
false
static int nfs_readlink_req(struct nfs_priv *npriv, struct nfs_fh *fh, char **target) { uint32_t data[1024]; uint32_t *p; uint32_t len; struct packet *nfs_packet; /* * struct READLINK3args { * nfs_fh3 symlink; * }; * * struct READLINK3resok { * post_op_attr symlink_attributes; * nfspath3 d...
[ "CWE-119" ]
pengutronix
574ce994016107ad8ab0f845a785f28d7eaa5208
165064796667373419921312233428470052444
177,796
41
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
static int nfs_readlink_req(struct nfs_priv *npriv, struct nfs_fh *fh, char **target) { uint32_t data[1024]; uint32_t *p; uint32_t len; struct packet *nfs_packet; /* * struct READLINK3args { * nfs_fh3 symlink; * }; * * struct READLINK3resok { * post_op_attr symlink_attributes; * nfspath3 d...
[ "CWE-119" ]
pengutronix
574ce994016107ad8ab0f845a785f28d7eaa5208
52376305515786293225734978443916270796
177,796
157,899
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
static int nfs_readlink_reply(unsigned char *pkt, unsigned len) { uint32_t *data; char *path; int rlen; int ret; ret = rpc_check_reply(pkt, 1); if (ret) return ret; data = (uint32_t *)(pkt + sizeof(struct rpc_reply)); data++; rlen = ntohl(net_read_uint32(data)); /* new path length */ data++; ...
[ "CWE-119" ]
pengutronix
84986ca024462058574432b5483f4bf9136c538d
197742048742816713437466148600234690021
177,797
42
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
static int nfs_readlink_reply(unsigned char *pkt, unsigned len) { uint32_t *data; char *path; unsigned int rlen; int ret; ret = rpc_check_reply(pkt, 1); if (ret) return ret; data = (uint32_t *)(pkt + sizeof(struct rpc_reply)); data++; rlen = ntohl(net_read_uint32(data)); /* new path length */ ...
[ "CWE-119" ]
pengutronix
84986ca024462058574432b5483f4bf9136c538d
206056256559243150120680816426898705118
177,797
157,900
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
zsetdevice(i_ctx_t *i_ctx_p) { gx_device *dev = gs_currentdevice(igs); os_ptr op = osp; int code = 0; check_write_type(*op, t_device); if (dev->LockSafetyParams) { /* do additional checking if locked */ if(op->value.pdevice != dev) /* don't allow a different device */ ...
[ "Other" ]
ghostscript
661e8d8fb8248c38d67958beda32f3a5876d0c3f
340004772641014275916898545695953737482
177,810
52
Unknown
true
zsetdevice(i_ctx_t *i_ctx_p) { gx_device *odev = NULL, *dev = gs_currentdevice(igs); os_ptr op = osp; int code = dev_proc(dev, dev_spec_op)(dev, gxdso_current_output_device, (void *)&odev, 0); if (code < 0) return code; check_write_type(*op, t_device); if (...
[ "Other" ]
ghostscript
661e8d8fb8248c38d67958beda32f3a5876d0c3f
59315764021980318626003459290825520793
177,810
157,910
Unknown
false
void sum_update(const char *p, int32 len) { switch (cursum_type) { case CSUM_MD5: md5_update(&md, (uchar *)p, len); break; case CSUM_MD4: case CSUM_MD4_OLD: case CSUM_MD4_BUSTED: if (len + sumresidue < CSUM_CHUNK) { memcpy(md.buffer + sumresi...
[ "CWE-354" ]
samba
c252546ceeb0925eb8a4061315e3ff0a8c55b48b
337655106013087126363639454838638190943
177,812
54
The product does not validate or incorrectly validates the integrity check values or checksums of a message. This may prevent it from detecting if the data has been modified or corrupted in transmission.
true
void sum_update(const char *p, int32 len) { switch (cursum_type) { case CSUM_MD5: md5_update(&md, (uchar *)p, len); break; case CSUM_MD4: case CSUM_MD4_OLD: case CSUM_MD4_BUSTED: case CSUM_MD4_ARCHAIC: if (len + sumresidue < CSUM_CHUNK) { ...
[ "CWE-354" ]
samba
c252546ceeb0925eb8a4061315e3ff0a8c55b48b
127195280572279640618380038836318413135
177,812
157,912
The product does not validate or incorrectly validates the integrity check values or checksums of a message. This may prevent it from detecting if the data has been modified or corrupted in transmission.
false
char *auth_server(int f_in, int f_out, int module, const char *host, const char *addr, const char *leader) { char *users = lp_auth_users(module); char challenge[MAX_DIGEST_LEN*2]; char line[BIGPATHBUFLEN]; char **auth_uid_groups = NULL; int auth_uid_groups_cnt = -1; const char *err = NULL; int group_match = ...
[ "CWE-354" ]
samba
9a480deec4d20277d8e20bc55515ef0640ca1e55
98721516615150795159214070101872089036
177,813
55
The product does not validate or incorrectly validates the integrity check values or checksums of a message. This may prevent it from detecting if the data has been modified or corrupted in transmission.
true
char *auth_server(int f_in, int f_out, int module, const char *host, const char *addr, const char *leader) { char *users = lp_auth_users(module); char challenge[MAX_DIGEST_LEN*2]; char line[BIGPATHBUFLEN]; char **auth_uid_groups = NULL; int auth_uid_groups_cnt = -1; const char *err = NULL; int group_match = ...
[ "CWE-354" ]
samba
9a480deec4d20277d8e20bc55515ef0640ca1e55
143115557888664430123988818349954566324
177,813
157,913
The product does not validate or incorrectly validates the integrity check values or checksums of a message. This may prevent it from detecting if the data has been modified or corrupted in transmission.
false
static int get_next_block(bunzip_data *bd) { struct group_data *hufGroup; int dbufCount, dbufSize, groupCount, *base, *limit, selector, i, j, runPos, symCount, symTotal, nSelectors, byteCount[256]; int runCnt = runCnt; /* for compiler */ uint8_t uc, symToByte[256], mtfSymbol[256], *selectors; uint32_t *dbuf...
[ "CWE-190" ]
busybox
0402cb32df015d9372578e3db27db47b33d5c7b0
238413816495536863232825191293924303166
177,822
62
The product 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 occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, ...
true
static int get_next_block(bunzip_data *bd) { struct group_data *hufGroup; int groupCount, *base, *limit, selector, i, j, symCount, symTotal, nSelectors, byteCount[256]; uint8_t uc, symToByte[256], mtfSymbol[256], *selectors; uint32_t *dbuf; unsigned origPtr, t; unsigned dbufCount, runPos; unsigned runCnt...
[ "CWE-190" ]
busybox
0402cb32df015d9372578e3db27db47b33d5c7b0
312101605599426186472577359417874735416
177,822
157,918
The product 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 occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, ...
false
BufCompressedFill (BufFilePtr f) { CompressedFile *file; register char_type *stackp, *de_stack; register char_type finchar; register code_int code, oldcode, incode; BufChar *buf, *bufend; file = (CompressedFile *) f->private; buf = f->buffer; bufend = buf + BUFFILESIZE; stackp...
[ "CWE-119" ]
libxfont
d11ee5886e9d9ec610051a206b135a4cdc1e09a0
314816336443270992925734214319385584087
177,823
63
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
BufCompressedFill (BufFilePtr f) { CompressedFile *file; register char_type *stackp, *de_stack; register char_type finchar; register code_int code, oldcode, incode; BufChar *buf, *bufend; file = (CompressedFile *) f->private; buf = f->buffer; bufend = buf + BUFFILESIZE; stackp...
[ "CWE-119" ]
libxfont
d11ee5886e9d9ec610051a206b135a4cdc1e09a0
176288859918527814344787198280161772156
177,823
157,919
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
static int dns_parse_callback(void *c, int rr, const void *data, int len, const void *packet) { char tmp[256]; struct dpc_ctx *ctx = c; switch (rr) { case RR_A: if (len != 4) return -1; ctx->addrs[ctx->cnt].scopeid = 0; memcpy(ctx->addrs[ctx->cnt++].addr, data, 4); break; case RR_AAAA: if (len != 1...
[ "CWE-119" ]
musl
45ca5d3fcb6f874bf5ba55d0e9651cef68515395
212099417602244187828055587331477277729
177,824
64
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
static int dns_parse_callback(void *c, int rr, const void *data, int len, const void *packet) { char tmp[256]; struct dpc_ctx *ctx = c; if (ctx->cnt >= MAXADDRS) return -1; switch (rr) { case RR_A: if (len != 4) return -1; ctx->addrs[ctx->cnt].scopeid = 0; memcpy(ctx->addrs[ctx->cnt++].addr, data, 4); ...
[ "CWE-119" ]
musl
45ca5d3fcb6f874bf5ba55d0e9651cef68515395
60029525500602919860744776503907800398
177,824
157,920
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
bool extractPages (const char *srcFileName, const char *destFileName) { char pathName[4096]; GooString *gfileName = new GooString (srcFileName); PDFDoc *doc = new PDFDoc (gfileName, NULL, NULL, NULL); if (!doc->isOk()) { error(errSyntaxError, -1, "Could not extract page(s) from damaged file ('{0:s}')", src...
[ "CWE-20" ]
poppler
61f79b8447c3ac8ab5a26e79e0c28053ffdccf75
41887122719404523174993334902149265910
177,825
65
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.
true
bool extractPages (const char *srcFileName, const char *destFileName) { char pathName[4096]; GooString *gfileName = new GooString (srcFileName); PDFDoc *doc = new PDFDoc (gfileName, NULL, NULL, NULL); if (!doc->isOk()) { error(errSyntaxError, -1, "Could not extract page(s) from damaged file ('{0:s}')", src...
[ "CWE-20" ]
poppler
61f79b8447c3ac8ab5a26e79e0c28053ffdccf75
226017378882353720793476700179562068873
177,825
157,921
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.
false
bool extractPages (const char *srcFileName, const char *destFileName) { char pathName[1024]; GooString *gfileName = new GooString (srcFileName); PDFDoc *doc = new PDFDoc (gfileName, NULL, NULL, NULL); if (!doc->isOk()) { error(errSyntaxError, -1, "Could not extract page(s) from damaged file ('{0:s}')",...
[ "CWE-119" ]
poppler
b8682d868ddf7f741e93b791588af0932893f95c
244634780333143587019078565382798831655
177,826
66
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
bool extractPages (const char *srcFileName, const char *destFileName) { char pathName[4096]; GooString *gfileName = new GooString (srcFileName); PDFDoc *doc = new PDFDoc (gfileName, NULL, NULL, NULL); if (!doc->isOk()) { error(errSyntaxError, -1, "Could not extract page(s) from damaged file ('{0:s}')",...
[ "CWE-119" ]
poppler
b8682d868ddf7f741e93b791588af0932893f95c
151037751520527895735005785354898270248
177,826
157,922
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
walk_string(fz_context *ctx, int uni, int remove, editable_str *str) { int rune; if (str->utf8 == NULL) return; do { char *s = &str->utf8[str->pos]; size_t len; int n = fz_chartorune(&rune, s); if (rune == uni) { /* Match. Skip over that one. */ str->pos += n...
[ "CWE-125" ]
ghostscript
97096297d409ec6f206298444ba00719607e8ba8
260933823413348392755539962564037161558
177,832
70
The product reads data past the end, or before the beginning, of the intended buffer.
true
walk_string(fz_context *ctx, int uni, int remove, editable_str *str) { int rune; if (str->utf8 == NULL || str->pos == -1) return; do { char *s = &str->utf8[str->pos]; size_t len; int n = fz_chartorune(&rune, s); if (rune == uni) { /* Match. Skip over that one. *...
[ "CWE-125" ]
ghostscript
97096297d409ec6f206298444ba00719607e8ba8
258102495955873121265660327401992670615
177,832
157,926
The product reads data past the end, or before the beginning, of the intended buffer.
false
void red_channel_pipes_add_empty_msg(RedChannel *channel, int msg_type) { RingItem *link; RING_FOREACH(link, &channel->clients) { red_channel_client_pipe_add_empty_msg( SPICE_CONTAINEROF(link, RedChannelClient, channel_link), msg_type); } }
[ "CWE-399" ]
spice
53488f0275d6c8a121af49f7ac817d09ce68090d
246859488383496619201376958064716490992
177,835
71
This vulnerability category highlights issues in resource management where failures to properly release memory, file handles, or other resources can degrade system performance or enable denial-of-service conditions.
true
void red_channel_pipes_add_empty_msg(RedChannel *channel, int msg_type) { RingItem *link, *next; RING_FOREACH_SAFE(link, next, &channel->clients) { red_channel_client_pipe_add_empty_msg( SPICE_CONTAINEROF(link, RedChannelClient, channel_link), msg_type); } }
[ "CWE-399" ]
spice
53488f0275d6c8a121af49f7ac817d09ce68090d
335972113688640103719320370363622760524
177,835
157,928
This vulnerability category highlights issues in resource management where failures to properly release memory, file handles, or other resources can degrade system performance or enable denial-of-service conditions.
false
void red_channel_pipes_add_type(RedChannel *channel, int pipe_item_type) { RingItem *link; RING_FOREACH(link, &channel->clients) { red_channel_client_pipe_add_type( SPICE_CONTAINEROF(link, RedChannelClient, channel_link), pipe_item_type); } }
[ "CWE-399" ]
spice
53488f0275d6c8a121af49f7ac817d09ce68090d
261946911680290370969616922085083966153
177,836
72
This vulnerability category highlights issues in resource management where failures to properly release memory, file handles, or other resources can degrade system performance or enable denial-of-service conditions.
true
void red_channel_pipes_add_type(RedChannel *channel, int pipe_item_type) { RingItem *link, *next; RING_FOREACH_SAFE(link, next, &channel->clients) { red_channel_client_pipe_add_type( SPICE_CONTAINEROF(link, RedChannelClient, channel_link), pipe_item_type); } }
[ "CWE-399" ]
spice
53488f0275d6c8a121af49f7ac817d09ce68090d
190053951808043701869694332992364951708
177,836
157,929
This vulnerability category highlights issues in resource management where failures to properly release memory, file handles, or other resources can degrade system performance or enable denial-of-service conditions.
false
x11_open_helper(Buffer *b) { u_char *ucp; u_int proto_len, data_len; u_char *ucp; u_int proto_len, data_len; /* Check if the fixed size part of the packet is in buffer. */ if (buffer_len(b) < 12) return 0; debug2("Initial X11 packet contains bad byte order byte: 0x%x", ucp[0]); return -1; }
[ "CWE-264" ]
mindrot
1bf477d3cdf1a864646d59820878783d42357a1d
186655838205464964819117737453872627903
177,838
73
This category addresses vulnerabilities caused by flawed access control mechanisms, where incorrect permission settings allow unauthorized users to access restricted resources.
true
x11_open_helper(Buffer *b) { u_char *ucp; u_int proto_len, data_len; u_char *ucp; u_int proto_len, data_len; /* Is this being called after the refusal deadline? */ if (x11_refuse_time != 0 && (u_int)monotime() >= x11_refuse_time) { verbose("Rejected X11 connection after ForwardX11Timeout " "expired")...
[ "CWE-264" ]
mindrot
1bf477d3cdf1a864646d59820878783d42357a1d
16527654010321763311742650376565564635
177,838
157,931
This category addresses vulnerabilities caused by flawed access control mechanisms, where incorrect permission settings allow unauthorized users to access restricted resources.
false
_PUBLIC_ codepoint_t next_codepoint_handle_ext( struct smb_iconv_handle *ic, const char *str, size_t len, charset_t src_charset, size_t *bytes_consumed) { /* it cannot occupy more than 4 bytes in UTF16 format */ uint8_t buf[4]; smb_iconv_t descriptor; size_t ilen_orig; size_t ilen; size_t olen;...
[ "CWE-200" ]
samba
538d305de91e34a2938f5f219f18bf0e1918763f
7537344539298054773758251251687254208
177,839
74
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
true
_PUBLIC_ codepoint_t next_codepoint_handle_ext( struct smb_iconv_handle *ic, const char *str, size_t len, charset_t src_charset, size_t *bytes_consumed) { /* it cannot occupy more than 4 bytes in UTF16 format */ uint8_t buf[4]; smb_iconv_t descriptor; size_t ilen_orig; size_t ilen; size_t olen;...
[ "CWE-200" ]
samba
538d305de91e34a2938f5f219f18bf0e1918763f
255868036276361989234981047681917157130
177,839
157,932
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
false
static int ldb_dn_escape_internal(char *dst, const char *src, int len) { const char *p, *s; char *d; size_t l; p = s = src; d = dst; while (p - src < len) { p += strcspn(p, ",=\n\r+<>#;\\\" "); if (p - src == len) /* found no escapable chars ...
[ "CWE-200" ]
samba
7f51ec8c4ed9ba1f53d722e44fb6fb3cde933b72
165702818458270596859790967970868439168
177,840
75
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
true
static int ldb_dn_escape_internal(char *dst, const char *src, int len) { char c; char *d; int i; d = dst; for (i = 0; i < len; i++){ c = src[i]; switch (c) { case ' ': if (i == 0 || i == len - 1) { ...
[ "CWE-200" ]
samba
7f51ec8c4ed9ba1f53d722e44fb6fb3cde933b72
317106333919448304744541648192653602778
177,840
157,933
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
false
_PUBLIC_ char *strupper_talloc_n_handle(struct smb_iconv_handle *iconv_handle, TALLOC_CTX *ctx, const char *src, size_t n) { size_t size=0; char *dest; if (!src) { return NULL; } /* this takes advantage of the fact that upper/lower can't change the length of a character by more than 1 byte */ dest = ...
[ "CWE-200" ]
samba
a118d4220ed85749c07fb43c1229d9e2fecbea6b
133076053301010291311483906719742687999
177,841
76
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
true
_PUBLIC_ char *strupper_talloc_n_handle(struct smb_iconv_handle *iconv_handle, TALLOC_CTX *ctx, const char *src, size_t n) { size_t size=0; char *dest; if (!src) { return NULL; } /* this takes advantage of the fact that upper/lower can't change the length of a character by more than 1 byte */ dest = ...
[ "CWE-200" ]
samba
a118d4220ed85749c07fb43c1229d9e2fecbea6b
36254057942599479296824956404810979025
177,841
157,934
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
false
static bool ldb_dn_explode(struct ldb_dn *dn) { char *p, *ex_name = NULL, *ex_value = NULL, *data, *d, *dt, *t; bool trim = true; bool in_extended = true; bool in_ex_name = false; bool in_ex_value = false; bool in_attr = false; bool in_value = false; bool in_quote = false; bool is_oid = false; bool escape = f...
[ "CWE-200" ]
samba
f36cb71c330a52106e36028b3029d952257baf15
56521152564463965686656149103554582573
177,845
80
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
true
static bool ldb_dn_explode(struct ldb_dn *dn) { char *p, *ex_name = NULL, *ex_value = NULL, *data, *d, *dt, *t; bool trim = true; bool in_extended = true; bool in_ex_name = false; bool in_ex_value = false; bool in_attr = false; bool in_value = false; bool in_quote = false; bool is_oid = false; bool escape = f...
[ "CWE-200" ]
samba
f36cb71c330a52106e36028b3029d952257baf15
151391885881791518561509644947335222102
177,845
157,938
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
false
gs_call_interp(i_ctx_t **pi_ctx_p, ref * pref, int user_errors, int *pexit_code, ref * perror_object) { ref *epref = pref; ref doref; ref *perrordict; ref error_name; int code, ccode; ref saref; i_ctx_t *i_ctx_p = *pi_ctx_p; int *gc_signal = &imemory_system->gs_lib_ctx->gc...
[ "CWE-209" ]
ghostscript
a6807394bd94b708be24758287b606154daaaed9
158176379266765825681809562263566380830
177,854
81
The product generates an error message that includes sensitive information about its environment, users, or associated data.
true
gs_call_interp(i_ctx_t **pi_ctx_p, ref * pref, int user_errors, int *pexit_code, ref * perror_object) { ref *epref = pref; ref doref; ref *perrordict; ref error_name; int code, ccode; ref saref; i_ctx_t *i_ctx_p = *pi_ctx_p; int *gc_signal = &imemory_system->gs_lib_ctx->gc...
[ "CWE-209" ]
ghostscript
a6807394bd94b708be24758287b606154daaaed9
121685247830698431863866645627437588475
177,854
157,940
The product generates an error message that includes sensitive information about its environment, users, or associated data.
false
NTSTATUS check_reduced_name_with_privilege(connection_struct *conn, const char *fname, struct smb_request *smbreq) { NTSTATUS status; TALLOC_CTX *ctx = talloc_tos(); const char *conn_rootdir; size_t rootdir_len; char *dir_name = NULL; const char *last_component = NULL; char *resolved_name = NULL; char *sa...
[ "CWE-264" ]
samba
4278ef25f64d5fdbf432ff1534e275416ec9561e
1187391106808919572589646338804645949
177,855
82
This category addresses vulnerabilities caused by flawed access control mechanisms, where incorrect permission settings allow unauthorized users to access restricted resources.
true
NTSTATUS check_reduced_name_with_privilege(connection_struct *conn, const char *fname, struct smb_request *smbreq) { NTSTATUS status; TALLOC_CTX *ctx = talloc_tos(); const char *conn_rootdir; size_t rootdir_len; char *dir_name = NULL; const char *last_component = NULL; char *resolved_name = NULL; char *sa...
[ "CWE-264" ]
samba
4278ef25f64d5fdbf432ff1534e275416ec9561e
205771650439669619349097817231899606612
177,855
157,941
This category addresses vulnerabilities caused by flawed access control mechanisms, where incorrect permission settings allow unauthorized users to access restricted resources.
false
plan_a (char const *filename) { char const *s; char const *lim; char const **ptr; char *buffer; lin iline; size_t size = instat.st_size; /* Fail if the file size doesn't fit in a size_t, or if storage isn't available. */ if (! (size == instat.st_size && (buffer = malloc (size ? size : (size_t) ...
[ "CWE-59" ]
savannah
dce4683cbbe107a95f1f0d45fabc304acfb5d71a
8366090498822481813911553841981995710
177,857
83
The product attempts to access a file based on the filename, but it does not properly prevent that filename from identifying a link or shortcut that resolves to an unintended resource.
true
plan_a (char const *filename) { char const *s; char const *lim; char const **ptr; char *buffer; lin iline; size_t size = instat.st_size; /* Fail if the file size doesn't fit in a size_t, or if storage isn't available. */ if (! (size == instat.st_size && (buffer = malloc (size ? size : (size_t) ...
[ "CWE-59" ]
savannah
dce4683cbbe107a95f1f0d45fabc304acfb5d71a
208309111606883428843432673009365368758
177,857
157,942
The product attempts to access a file based on the filename, but it does not properly prevent that filename from identifying a link or shortcut that resolves to an unintended resource.
false
_dbus_header_byteswap (DBusHeader *header, int new_order) { if (header->byte_order == new_order) return; _dbus_marshal_byteswap (&_dbus_header_signature_str, 0, header->byte_order, new_order, ...
[ "CWE-20" ]
dbus
c3223ba6c401ba81df1305851312a47c485e6cd7
9228036298590962222843680821307727463
177,858
84
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.
true
_dbus_header_byteswap (DBusHeader *header, int new_order) { unsigned char byte_order; if (header->byte_order == new_order) return; byte_order = _dbus_string_get_byte (&header->data, BYTE_ORDER_OFFSET); _dbus_assert (header->byte_order == byte_order); _dbus_marshal_...
[ "CWE-20" ]
dbus
c3223ba6c401ba81df1305851312a47c485e6cd7
171873919518716570145042987364216001209
177,858
157,943
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.
false
gs_nulldevice(gs_gstate * pgs) { int code = 0; if (pgs->device == 0 || !gx_device_is_null(pgs->device)) { gx_device *ndev; code = gs_copydevice(&ndev, (const gx_device *)&gs_null_device, pgs->memory); if (code < 0) return code; ...
[ "CWE-78" ]
ghostscript
79cccf641486a6595c43f1de1cd7ade696020a31
84413200937845432393453109331654543792
177,859
85
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.
true
gs_nulldevice(gs_gstate * pgs) { int code = 0; bool saveLockSafety = false; if (pgs->device == 0 || !gx_device_is_null(pgs->device)) { gx_device *ndev; code = gs_copydevice(&ndev, (const gx_device *)&gs_null_device, pgs->memory); if (code < 0...
[ "CWE-78" ]
ghostscript
79cccf641486a6595c43f1de1cd7ade696020a31
212959667910932412736569570385002997093
177,859
157,944
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.
false
zrestore(i_ctx_t *i_ctx_p) { os_ptr op = osp; alloc_save_t *asave; bool last; vm_save_t *vmsave; int code = restore_check_operand(op, &asave, idmemory); if (code < 0) return code; if_debug2m('u', imemory, "[u]vmrestore 0x%lx, id = %lu\n", (ulong) alloc_save_clie...
[ "CWE-78" ]
ghostscript
5516c614dc33662a2afdc377159f70218e67bde5
243122500252437636802158481572566726525
177,860
86
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.
true
zrestore(i_ctx_t *i_ctx_p) restore_check_save(i_ctx_t *i_ctx_p, alloc_save_t **asave) { os_ptr op = osp; int code = restore_check_operand(op, asave, idmemory); if (code < 0) return code; if_debug2m('u', imemory, "[u]vmrestore 0x%lx, id = %lu\n", (ulong) alloc_save_client_da...
[ "CWE-78" ]
ghostscript
5516c614dc33662a2afdc377159f70218e67bde5
286298531521520139137532598340258135965
177,860
157,945
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.
false
destroy_one_secret (gpointer data) { char *secret = (char *) data; /* Don't leave the secret lying around in memory */ g_message ("%s: destroying %s", __func__, secret); memset (secret, 0, strlen (secret)); g_free (secret); }
[ "CWE-200" ]
NetworkManager
78ce088843d59d4494965bfc40b30a2e63d065f6
1138568555668242760358654543466979215
177,861
87
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
true
destroy_one_secret (gpointer data) { char *secret = (char *) data; /* Don't leave the secret lying around in memory */ memset (secret, 0, strlen (secret)); g_free (secret); }
[ "CWE-200" ]
NetworkManager
78ce088843d59d4494965bfc40b30a2e63d065f6
136510234881215550072789075769262394565
177,861
157,946
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
false
PatternMatch(char *pat, int patdashes, char *string, int stringdashes) { char c, t; if (stringdashes < patdashes) return 0; for (;;) { switch (c = *pat++) { case '*': if (!(c = *pat++)) return 1; if (c == XK_minus) { patdashes--; for (;;) { while ((t = *strin...
[ "CWE-125" ]
libxfont
d1e670a4a8704b8708e493ab6155589bcd570608
235016592504912789309291169579431913614
177,865
90
The product reads data past the end, or before the beginning, of the intended buffer.
true
PatternMatch(char *pat, int patdashes, char *string, int stringdashes) { char c, t; if (stringdashes < patdashes) return 0; for (;;) { switch (c = *pat++) { case '*': if (!(c = *pat++)) return 1; if (c == XK_minus) { patdashes--; for (;;) { while ((t = *strin...
[ "CWE-125" ]
libxfont
d1e670a4a8704b8708e493ab6155589bcd570608
335732905628135922039393462052987124214
177,865
157,948
The product reads data past the end, or before the beginning, of the intended buffer.
false
gs_call_interp(i_ctx_t **pi_ctx_p, ref * pref, int user_errors, int *pexit_code, ref * perror_object) { ref *epref = pref; ref doref; ref *perrordict; ref error_name; int code, ccode; ref saref; i_ctx_t *i_ctx_p = *pi_ctx_p; int *gc_signal = &imemory_system->gs_lib_ctx->gc...
[ "CWE-388" ]
ghostscript
b575e1ec42cc86f6a58c603f2a88fcc2af699cc8
56777007913799829721432476707011479257
177,866
91
This obsolete category once captured errors related to system feedback management, such as overly detailed error messages that might inadvertently disclose sensitive internal information.
true
gs_call_interp(i_ctx_t **pi_ctx_p, ref * pref, int user_errors, int *pexit_code, ref * perror_object) { ref *epref = pref; ref doref; ref *perrordict; ref error_name; int code, ccode; ref saref; i_ctx_t *i_ctx_p = *pi_ctx_p; int *gc_signal = &imemory_system->gs_lib_ctx->gc...
[ "CWE-388" ]
ghostscript
b575e1ec42cc86f6a58c603f2a88fcc2af699cc8
276163117354160345948359399254998318074
177,866
157,949
This obsolete category once captured errors related to system feedback management, such as overly detailed error messages that might inadvertently disclose sensitive internal information.
false
gs_main_finit(gs_main_instance * minst, int exit_status, int code) { i_ctx_t *i_ctx_p = minst->i_ctx_p; gs_dual_memory_t dmem = {0}; int exit_code; ref error_object; char *tempnames; /* NB: need to free gs_name_table */ /* * Previous versions of this code closed the devices in th...
[ "CWE-416" ]
ghostscript
241d91112771a6104de10b3948c3f350d6690c1d
143975174954705637984220412120331580143
177,867
92
The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory...
true
gs_main_finit(gs_main_instance * minst, int exit_status, int code) { i_ctx_t *i_ctx_p = minst->i_ctx_p; gs_dual_memory_t dmem = {0}; int exit_code; ref error_object; char *tempnames; /* NB: need to free gs_name_table */ /* * Previous versions of this code closed the devices in th...
[ "CWE-416" ]
ghostscript
241d91112771a6104de10b3948c3f350d6690c1d
65559169527903508610670362820860424615
177,867
157,950
The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory...
false
zsetcolor(i_ctx_t * i_ctx_p) { os_ptr op = osp; es_ptr ep; const gs_color_space * pcs = gs_currentcolorspace(igs); gs_client_color cc; int n_comps, n_numeric_comps, num_offset = 0, code, depth; PS_colour_space_t *space; /* initialize the client ...
[ "CWE-704" ]
ghostscript
b326a71659b7837d3acde954b18bda1a6f5e9498
204275868331229737175629924419598292681
177,869
93
The product does not correctly convert an object, resource, or structure from one type to a different type.
true
zsetcolor(i_ctx_t * i_ctx_p) { os_ptr op = osp; es_ptr ep; const gs_color_space * pcs = gs_currentcolorspace(igs); gs_client_color cc; int n_comps, n_numeric_comps, num_offset = 0, code, depth; PS_colour_space_t *space; /* initialize the client ...
[ "CWE-704" ]
ghostscript
b326a71659b7837d3acde954b18bda1a6f5e9498
34376628731007990509857302521992081996
177,869
157,951
The product does not correctly convert an object, resource, or structure from one type to a different type.
false
fd_read_body (const char *downloaded_filename, int fd, FILE *out, wgint toread, wgint startpos, wgint *qtyread, wgint *qtywritten, double *elapsed, int flags, FILE *out2) { int ret = 0; #undef max #define max(a,b) ((a) > (b) ? (a) : (b)) int dlbufsize = max (BUFSIZ, 8 * 1024); char *d...
[ "CWE-119" ]
savannah
ba6b44f6745b14dce414761a8e4b35d31b176bba
323589515235597079129994725046166819711
177,873
96
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
fd_read_body (const char *downloaded_filename, int fd, FILE *out, wgint toread, wgint startpos, wgint *qtyread, wgint *qtywritten, double *elapsed, int flags, FILE *out2) { int ret = 0; #undef max #define max(a,b) ((a) > (b) ? (a) : (b)) int dlbufsize = max (BUFSIZ, 8 * 1024); char *d...
[ "CWE-119" ]
savannah
ba6b44f6745b14dce414761a8e4b35d31b176bba
220093956480677323605982437392462496483
177,873
157,954
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
check_file_permissions_reduced(i_ctx_t *i_ctx_p, const char *fname, int len, gx_io_device *iodev, const char *permitgroup) { long i; ref *permitlist = NULL; /* an empty string (first character == 0) if '\' character is */ /* recognized as a file name separator as on DOS & Windows...
[ "Other" ]
ghostscript
0d3901189f245232f0161addf215d7268c4d05a3
69859639183316940625463158376184599878
177,880
101
Unknown
true
check_file_permissions_reduced(i_ctx_t *i_ctx_p, const char *fname, int len, gx_io_device *iodev, const char *permitgroup) { long i; ref *permitlist = NULL; /* an empty string (first character == 0) if '\' character is */ /* recognized as a file name separator as on DOS & Windows...
[ "Other" ]
ghostscript
0d3901189f245232f0161addf215d7268c4d05a3
99054520864994696214682568839021118743
177,880
157,959
Unknown
false
struct edid *drm_load_edid_firmware(struct drm_connector *connector) { const char *connector_name = connector->name; char *edidname, *last, *colon, *fwstr, *edidstr, *fallback = NULL; struct edid *edid; if (edid_firmware[0] == '\0') return ERR_PTR(-ENOENT); /* * If there are multiple edid files specified and...
[ "CWE-476" ]
drm
9f1f1a2dab38d4ce87a13565cf4dc1b73bef3a5f
277136060870051879610700105139465176140
177,881
102
The product dereferences a pointer that it expects to be valid but is NULL.
true
struct edid *drm_load_edid_firmware(struct drm_connector *connector) { const char *connector_name = connector->name; char *edidname, *last, *colon, *fwstr, *edidstr, *fallback = NULL; struct edid *edid; if (edid_firmware[0] == '\0') return ERR_PTR(-ENOENT); /* * If there are multiple edid files specified and...
[ "CWE-476" ]
drm
9f1f1a2dab38d4ce87a13565cf4dc1b73bef3a5f
199051164919133436575414029938699656311
177,881
157,960
The product dereferences a pointer that it expects to be valid but is NULL.
false
void buffer_slow_realign(struct buffer *buf) { /* two possible cases : * - the buffer is in one contiguous block, we move it in-place * - the buffer is in two blocks, we move it via the swap_buffer */ if (buf->i) { int block1 = buf->i; int block2...
[ "CWE-119" ]
haproxy
7ec765568883b2d4e5a2796adbeb492a22ec9bd4
110551955760274715015247345529003415581
177,886
106
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
void buffer_slow_realign(struct buffer *buf) { int block1 = buf->o; int block2 = 0; /* process output data in two steps to cover wrapping */ if (block1 > buf->p - buf->data) { block2 = buf->p - buf->data; block1 -= block2; } memcpy(swap_buffer +...
[ "CWE-119" ]
haproxy
7ec765568883b2d4e5a2796adbeb492a22ec9bd4
93118898612400237957558909236733687601
177,886
157,964
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
new_msg_register_event (u_int32_t seqnum, struct lsa_filter_type *filter) { u_char buf[OSPF_API_MAX_MSG_SIZE]; struct msg_register_event *emsg; int len; emsg = (struct msg_register_event *) buf; len = sizeof (struct msg_register_event) + filter->num_areas * sizeof (struct in_addr); emsg->filter.typema...
[ "CWE-119" ]
savannah
3f872fe60463a931c5c766dbf8c36870c0023e88
24569741928780254928487121835647969548
177,888
107
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
true
new_msg_register_event (u_int32_t seqnum, struct lsa_filter_type *filter) { u_char buf[OSPF_API_MAX_MSG_SIZE]; struct msg_register_event *emsg; int len; emsg = (struct msg_register_event *) buf; len = sizeof (struct msg_register_event) + filter->num_areas * sizeof (struct in_addr); emsg->filter.typema...
[ "CWE-119" ]
savannah
3f872fe60463a931c5c766dbf8c36870c0023e88
145214918048062551547513527429211682293
177,888
157,965
The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
false
int ASN1_item_ex_d2i(ASN1_VALUE **pval, const unsigned char **in, long len, const ASN1_ITEM *it, int tag, int aclass, char opt, ASN1_TLC *ctx) { const ASN1_TEMPLATE *tt, *errtt = NULL; const ASN1_COMPAT_FUNCS *cf; const ASN1_EXTERN_FUNCS *ef; const ASN1_AUX *aux...
[ "CWE-200" ]
openssl
cc598f321fbac9c04da5766243ed55d55948637d
262483489551334338648277862128153636042
177,890
108
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
true
int ASN1_item_ex_d2i(ASN1_VALUE **pval, const unsigned char **in, long len, const ASN1_ITEM *it, int tag, int aclass, char opt, ASN1_TLC *ctx) { const ASN1_TEMPLATE *tt, *errtt = NULL; const ASN1_COMPAT_FUNCS *cf; const ASN1_EXTERN_FUNCS *ef; const ASN1_AUX *aux...
[ "CWE-200" ]
openssl
cc598f321fbac9c04da5766243ed55d55948637d
20163778210230944681624599155479176309
177,890
157,966
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
false
static RSA_PSS_PARAMS *rsa_pss_decode(const X509_ALGOR *alg, X509_ALGOR **pmaskHash) { const unsigned char *p; int plen; RSA_PSS_PARAMS *pss; *pmaskHash = NULL; if (!alg->parameter || alg->parameter->type != V_ASN1_SEQUENCE) return NULL; p = alg->p...
[ "Other" ]
openssl
d8541d7e9e63bf5f343af24644046c8d96498c17
288105964239389158612588380167749525157
177,891
109
Unknown
true
static RSA_PSS_PARAMS *rsa_pss_decode(const X509_ALGOR *alg, X509_ALGOR **pmaskHash) { const unsigned char *p; int plen; RSA_PSS_PARAMS *pss; *pmaskHash = NULL; if (!alg->parameter || alg->parameter->type != V_ASN1_SEQUENCE) return NULL; p = alg->p...
[ "Other" ]
openssl
d8541d7e9e63bf5f343af24644046c8d96498c17
338718658446842935098442076237481568312
177,891
157,967
Unknown
false
static X509_ALGOR *rsa_mgf1_decode(X509_ALGOR *alg) { const unsigned char *p; int plen; if (alg == NULL) return NULL; if (OBJ_obj2nid(alg->algorithm) != NID_mgf1) return NULL; if (alg->parameter->type != V_ASN1_SEQUENCE) return NULL; p = alg->parameter->value.seque...
[ "Other" ]
openssl
c394a488942387246653833359a5c94b5832674e
308019867511894862199468289587358810995
177,892
110
Unknown
true
static X509_ALGOR *rsa_mgf1_decode(X509_ALGOR *alg) { const unsigned char *p; int plen; if (alg == NULL || alg->parameter == NULL) return NULL; if (OBJ_obj2nid(alg->algorithm) != NID_mgf1) return NULL; if (alg->parameter->type != V_ASN1_SEQUENCE) return NULL; p = a...
[ "Other" ]
openssl
c394a488942387246653833359a5c94b5832674e
184183702878896057031381637225428687008
177,892
157,968
Unknown