maskit opened a new issue, #10193: URL: https://github.com/apache/trafficserver/issues/10193
``` 216std::string 217create_trace(TSHttpTxn const txnp) 218{ 219 std::string header; 220 221 constexpr char new_parent{'0'}; 222 223 TSUuid const uuid = TSUuidCreate(); 1. Condition NULL != uuid, taking true branch. 224 if (nullptr != uuid) { 2. Condition TS_SUCCESS == TSUuidInitialize(uuid, TS_UUID_V4), taking true branch. 225 if (TS_SUCCESS == TSUuidInitialize(uuid, TS_UUID_V4)) { 226 char const *const uuidstr = TSUuidStringGet(uuid); 3. Condition NULL != uuidstr, taking true branch. 227 if (nullptr != uuidstr) { 228 swoc::LocalBufferWriter<8192> bwriter; 229 230 bwriter.write(traceid); 4. string_copy: Calling write copies a source string uuidstr to bwriter._buffer. 5. string_null_source: The argument bwriter._buffer will not be null-terminated, because either the source string is not null-terminated, or the length of source string uuidstr is greater than or equal to the size argument strlen(uuidstr). 231 bwriter.write(uuidstr, strlen(uuidstr)); 232 bwriter.write(sep); 233 bwriter.write(parentid); 234 bwriter.write(new_parent); 235 bwriter.write(sep); 236 bwriter.write(spanid); 237 bwriter.print("{}", TSHttpTxnIdGet(txnp)); 238 CID 1518143 (#1 of 1): String not null terminated (STRING_NULL) 6. string_null: Passing unterminated string bwriter._buffer to view, which expects a null-terminated string. 239 header.assign(bwriter.view()); 240 } else { 241 LOG_ERROR("Error getting uuid string"); 242 } ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@trafficserver.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org