lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <000000000000a60a8a0609f14025@google.com>
Date:   Sun, 12 Nov 2023 01:33:56 -0800
From:   syzbot <syzbot+d66de4cbf532749df35f@...kaller.appspotmail.com>
To:     linux-kernel@...r.kernel.org
Subject: Re: [syzbot] Re: [syzbot] [btrfs?] memory leak in btrfs_ref_tree_mod

For archival purposes, forwarding an incoming command email to
linux-kernel@...r.kernel.org.

***

Subject: Re: [syzbot] [btrfs?] memory leak in btrfs_ref_tree_mod
Author: bragathemanick0908@...il.com


On 12/11/23 14:53, syzbot wrote:
> Hello,
>
> syzbot tried to test the proposed patch but the build/boot failed:
>
> failed to apply patch:
> checking file fs/btrfs/ref-verify.c
> Hunk #1 FAILED at 791.
> Hunk #2 FAILED at 800.
> 2 out of 2 hunks FAILED
>
>
>
> Tested on:
>
> commit:         1b907d05 Merge tag '6.7-rc-smb3-client-fixes-part2' of..
> git tree:       upstream
> kernel config:  https://syzkaller.appspot.com/x/.config?x=2bf8962e4f7984f4
> dashboard link: https://syzkaller.appspot.com/bug?extid=d66de4cbf532749df35f
> compiler:
> patch:          https://syzkaller.appspot.com/x/patch.diff?x=16845fe0e80000
>
#syz test

--- a/fs/btrfs/ref-verify.c
+++ b/fs/btrfs/ref-verify.c
@@ -791,6 +791,7 @@ int btrfs_ref_tree_mod(struct btrfs_fs_info *fs_info,
              dump_ref_action(fs_info, ra);
              kfree(ref);
              kfree(ra);
+            kfree(re);
              goto out_unlock;
          } else if (be->num_refs == 0) {
              btrfs_err(fs_info,
@@ -800,6 +801,7 @@ int btrfs_ref_tree_mod(struct btrfs_fs_info *fs_info,
              dump_ref_action(fs_info, ra);
              kfree(ref);
              kfree(ra);
+            kfree(re);
              goto out_unlock;
          }

@@ -822,6 +824,7 @@ int btrfs_ref_tree_mod(struct btrfs_fs_info *fs_info,
                  dump_ref_action(fs_info, ra);
                  kfree(ref);
                  kfree(ra);
+                kfree(re);
                  goto out_unlock;
              }
              exist->num_refs--;
@@ -838,6 +841,7 @@ int btrfs_ref_tree_mod(struct btrfs_fs_info *fs_info,
              dump_ref_action(fs_info, ra);
              kfree(ref);
              kfree(ra);
+            kfree(re);
              goto out_unlock;
          }
          kfree(ref);
@@ -849,6 +853,7 @@ int btrfs_ref_tree_mod(struct btrfs_fs_info *fs_info,
              dump_ref_action(fs_info, ra);
              kfree(ref);
              kfree(ra);
+            kfree(re);
              goto out_unlock;
          }
      }
@@ -881,6 +886,8 @@ int btrfs_ref_tree_mod(struct btrfs_fs_info *fs_info,
      }
      list_add_tail(&ra->list, &be->actions);
      ret = 0;
+    kfree(ra);
+    kfree(re);
  out_unlock:
      spin_unlock(&fs_info->ref_verify_lock);
  out:

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ