Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-29240

Issue discovered by static analyzer.

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Minor Minor
    • rhel-10.0.beta
    • rhel-9.4
    • c-ares
    • None
    • Minor
    • sst_idm_sssd
    • ssg_idm
    • False
    • Hide

      None

      Show
      None
    • Unspecified

      ```
      Error: BUFFER_SIZE (CWE-170):
      c-ares-1.19.1/src/lib/inet_net_pton.c:328: buffer_size_warning: Calling ""strncpy"" with a maximum size argument of 51 bytes on destination array ""buf"" of size 51 bytes might leave the destination string unterminated.

      1. 326| return (-1);
      2. 327| }
      3. 328|-> strncpy(buf, src, sizeof buf);
      4. 329|
      5. 330| sep = strchr(buf, '/');
        ```

            atikhono@redhat.com Alexey Tikhonov
            atikhono@redhat.com Alexey Tikhonov
            Alexey Tikhonov Alexey Tikhonov
            Shridhar Gadekar Shridhar Gadekar
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: