Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp555489imm; Tue, 5 Jun 2018 00:06:00 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKAiZwVzXe2XyQxxDYLSKYdS7zaOsffIZn5nqPwgR/IblUbV1CJEILusw8uAKeEW0yPgrub X-Received: by 2002:a17:902:6e4:: with SMTP id 91-v6mr24906135plh.63.1528182360292; Tue, 05 Jun 2018 00:06:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528182360; cv=none; d=google.com; s=arc-20160816; b=Rid12c122agFlvh+eY3OZBIoRuQ4Ss65yk886ENSHXVxmKJYMZJO6HoFpcPNsPXBKm XmaTGkD7sqtYTeEcde7leyF+lEfgGHstFwgk9UC/XOHlVFPjWB1gSLCH0XEdmcYM+cPn 39OXO0PNWWtI+8rPzfgOoRMIl+DnnW1ltVe6OZLetE2thbhU0NGbU1g9bfV8ixbX88dV OWmmhP9SAVzEAXiqKl58QUKtn+eNQDnv0+i7O2Bvu0YQDPhSjtTjjg+46x5n7s938/CO B25yXpAw9RGocoHIG0CJ2+rw/LhskT9pG/ZIHg3B4dtMNpn+/pDCW1XH99ogKJgzj1KW c87A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:dlp-filter:cms-type :content-transfer-encoding:date:message-id:in-reply-to:cc:to:from :reply-to:subject:mime-version:dkim-signature:dkim-filter :arc-authentication-results; bh=A89rsCJ7fdCxLO2rcJE3VquHUE2IqYXzye4jJmI73z4=; b=LAPCq4v9YStDMpS3mqslh4796/qBzI28ScspcOT8U251zK0n82/TXMx24ab+DPvJvc p+kxrxcpK/Cb81gQnVnp985yYC1P9TPQXCldAqPjrDfQ49GIRFOddJQ8IBEu12yvg0vv Y/R/YFJGCN+LaKna5bdX7tJzrABGCWzL28gQoZwDbGkK1KyB7ATVclFc6nb0P9CHkmtX a8dpwpyHLtawpMiT19QeAlQDaGsy105rNgVGB0/HxMd5Dws18EQIbZ9+4bvTGOV2/mkN E7waPLt/xY2eZMEhg2lXcvKVktyctlj+jVrHVqIjx0U0omlSnpTkKNZ+Dnl4SqpVgY9W LOpg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=Xk3AH8tL; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y7-v6si28882827pgc.656.2018.06.05.00.05.45; Tue, 05 Jun 2018 00:06:00 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=Xk3AH8tL; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751756AbeFEHE4 (ORCPT + 99 others); Tue, 5 Jun 2018 03:04:56 -0400 Received: from mailout2.samsung.com ([203.254.224.25]:35469 "EHLO mailout2.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751514AbeFEHEx (ORCPT ); Tue, 5 Jun 2018 03:04:53 -0400 Received: from epcas5p3.samsung.com (unknown [182.195.41.41]) by mailout2.samsung.com (KnoxPortal) with ESMTP id 20180605070452epoutp02cf148e504588bbcb43dcc73c977d5d44~1MbKt9B103238832388epoutp02h for ; Tue, 5 Jun 2018 07:04:52 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.samsung.com 20180605070452epoutp02cf148e504588bbcb43dcc73c977d5d44~1MbKt9B103238832388epoutp02h DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1528182292; bh=A89rsCJ7fdCxLO2rcJE3VquHUE2IqYXzye4jJmI73z4=; h=Subject:Reply-To:From:To:CC:In-Reply-To:Date:References:From; b=Xk3AH8tLSD7et0RLOT4a5tW9r6rQfzPeuaTNe7vOjgaMAXNeLGb1wxIC8bMqa0f2S /TLod1lFQMJwWJo4NZgKX84VAaFloPxyeR5KUWUVe1zBNmjpKFEnX44YYDAgmqH5NP ny3CpkRqxfssBsZXV7VbHzard5XW/CijDsvGmGbQ= Received: from epsmges5p2new.samsung.com (unknown [182.195.40.192]) by epcas5p3.samsung.com (KnoxPortal) with ESMTP id 20180605070449epcas5p3a232cbe1c6849ae41ac86b9add9ca9bd~1MbIlYpqW0506005060epcas5p3-; Tue, 5 Jun 2018 07:04:49 +0000 (GMT) X-AuditID: b6c32a4a-abdff70000001139-35-5b16361159f8 Received: from epcas5p4.samsung.com ( [182.195.41.42]) by epsmges5p2new.samsung.com (Symantec Messaging Gateway) with SMTP id E5.F2.04409.116361B5; Tue, 5 Jun 2018 16:04:49 +0900 (KST) Mime-Version: 1.0 Subject: RE: Re: [PATCH] Smack: Fix memory leak in smack_inode_getsecctx Reply-To: chandan.vn@samsung.com From: CHANDAN VN To: Tejun Heo , Casey Schaufler CC: "linux-security-module@vger.kernel.org" , "gregkh@linuxfoundation.org" , "bfields@fieldses.org" , "jlayton@kernel.org" , "linux-kernel@vger.kernel.org" , "linux-nfs@vger.kernel.org" , CPGS , Sireesha Talluri , Chris Wright X-Priority: 3 X-Content-Kind-Code: NORMAL In-Reply-To: <20180604212704.GC1351649@devbig577.frc2.facebook.com> X-Drm-Type: N,general X-Msg-Generator: Mail X-Msg-Type: PERSONAL X-Reply-Demand: N Message-ID: <20180605070449epcms5p317013469ed52cc50878011c428bd12aa@epcms5p3> Date: Tue, 05 Jun 2018 12:34:49 +0530 X-CMS-MailID: 20180605070449epcms5p317013469ed52cc50878011c428bd12aa Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" X-CPGSPASS: Y CMS-TYPE: 105P X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrFJsWRmVeSWpSXmKPExsWy7bCmlq6gmVi0weM/mhYvpkRZ3Nv2i82i 9/YSZouXhzQtmhevZ7P4uWwVu8XlXXPYLC4cOM1q8aHnEZvFrgsFFr+WH2V04PbYMLWJzWPT qk42j/1z17B79G1ZxehxdP8iNo9te7qYPT5vkgtgj0q1yUhNTEktUkjNS85PycxLt1XyDo53 jjc1MzDUNbS0MFdSyEvMTbVVcvEJ0HXLzAG6UEmhLDGnFCgUkFhcrKRvZ1OUX1qSqpCRX1xi qxRtaGikZ2hgrmdkBKRNY62MTIFKElIzlve3MhZc5K44+rWLuYFxJXcXIweHhICJxO+51l2M XBxCArsZJZaeOsQCEucVEJT4u0O4i5GTQ1jAQ2LR/7/MILaQgILEkTdrWSDi2hJdh9+A2WwC mhIn5k1jB7FFBNwlnk04yApiMwtcYZboeRIHYksI8ErMaH/KAmFLS2xfvpURxOYUcJZYdeA3 M0RcVOLm6rfsMPb7Y/MZIWwRidZ7Z6FqBCUe/NzNCDNnxdotUDPzJTZd3swO8VaFxL29khBh c4nHNzczgdi8Ar4SP67/AytnEVCVaDn5DGqVi8Sd+zPYIE7Wlli28DUzyBhmoLfW79KHub5h 4292iBI+id7fT5hg4jvmwdgqEv9eL4WypSQuXvkGZXtIvGpdxAwJ5ZWsErff3GGbwKgwCxHQ s5BsnoWweQEj8ypGydSC4tz01GLTAqO81HK94sTc4tK8dL3k/NxNjOB0quW1g3HZOZ9DjAIc jEo8vBpWotFCrIllxZW5hxglOJiVRHhPFwCFeFMSK6tSi/Lji0pzUosPMZoCw2Ais5Rocj4w 1eeVxBuaGpmZGVgamBpbmBkqifP+uC4QLSSQnliSmp2aWpBaBNPHxMEp1cB4yrXOaDaron1K 3rNzN1k4s5/WxBWpuN24XN6n2//79pK2n8L57Fs+abrxbAlV/ac5tcrYNcxpPtPUebveemh4 flOw9X++bZah0opHvBmOzzXunDJQ/LXoaGN4G1vljY53F5dKhb3gunW4hU1W6bj1mVVp7qFc eTzHEjs2bRHdfuOH5X8/l1AlluKMREMt5qLiRABb+gk1vQMAAA== DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20180531092848epcas1p24b638ccd6da00f1e039bdb64de7e1a5b References: <20180604212704.GC1351649@devbig577.frc2.facebook.com> <1527758911-18610-1-git-send-email-chandan.vn@samsung.com> <20180531153943.GR1351649@devbig577.frc2.facebook.com> <4f00f9ae-3302-83b9-c083-d21ade380eb2@schaufler-ca.com> <20180531161107.GV1351649@devbig577.frc2.facebook.com> <20180601085609epcms5p5fefac0156a4816e9e48751211ab595ee@epcms5p5> <20180601162913epcms5p7737f5b4376d8865af1eae119aa866550@epcms5p7> <5b0b157a-0e8c-d8f5-901e-836d545a8e4c@schaufler-ca.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org =C2=A0=0D=0A=0D=0A>On=C2=A0Mon,=C2=A0Jun=C2=A004,=C2=A02018=C2=A0at=C2=A002= :01:34PM=C2=A0-0700,=C2=A0Casey=C2=A0Schaufler=C2=A0wrote:=0D=0A>>=C2=A0On= =C2=A06/1/2018=C2=A010:45=C2=A0AM,=C2=A0Casey=C2=A0Schaufler=C2=A0wrote:=0D= =0A>>=C2=A0>=C2=A0Fix=C2=A0memory=C2=A0leak=C2=A0in=C2=A0smack_inode_getsec= ctx=0D=0A>>=C2=A0>=0D=0A>>=C2=A0>=C2=A0The=C2=A0implementation=C2=A0of=C2= =A0smack_inode_getsecctx()=C2=A0made=0D=0A>>=C2=A0>=C2=A0incorrect=C2=A0ass= umptions=C2=A0about=C2=A0how=C2=A0Smack=C2=A0presents=C2=A0a=C2=A0security= =0D=0A>>=C2=A0>=C2=A0context.=C2=A0Smack=C2=A0does=C2=A0not=C2=A0need=C2=A0= to=C2=A0allocate=C2=A0memory=C2=A0to=C2=A0support=0D=0A>>=C2=A0>=C2=A0secur= ity=C2=A0contexts,=C2=A0so=C2=A0=22releasing=22=C2=A0a=C2=A0Smack=C2=A0cont= ext=C2=A0is=C2=A0a=C2=A0no-op.=0D=0A>>=C2=A0>=C2=A0The=C2=A0code=C2=A0made= =C2=A0an=C2=A0unnecessary=C2=A0copy=C2=A0and=C2=A0returned=C2=A0that=C2=A0a= s=C2=A0a=0D=0A>>=C2=A0>=C2=A0context,=C2=A0which=C2=A0was=C2=A0never=C2=A0f= reed.=C2=A0The=C2=A0revised=C2=A0implementation=0D=0A>>=C2=A0>=C2=A0returns= =C2=A0the=C2=A0context=C2=A0correctly.=0D=0A>>=C2=A0>=0D=0A>>=C2=A0>=C2=A0S= igned-off-by:=C2=A0Casey=C2=A0Schaufler=C2=A0=0D= =0A>>=C2=A0=0D=0A>>=C2=A0Tejun,=C2=A0does=C2=A0this=C2=A0pass=C2=A0your=C2= =A0tests?=0D=0A=C2=A0=0D=0A>Oh,=C2=A0I'm=C2=A0not=C2=A0the=C2=A0one=C2=A0wh= o=C2=A0reported.=C2=A0=C2=A0Chandan?=0D=0ALooks=20good=20to=20me.=20Leak=20= not=20found.