Project

General

Profile

Actions

Bug #2230

closed

valgrind memcheck - 4.0.0-dev (rev 1180687)

Added by Peter Manev almost 5 years ago. Updated almost 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Affected Versions:
Effort:
Difficulty:
Label:

Description

==8084== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==8084==    at 0x7C28F07: ioctl (syscall-template.S:84)
==8084==    by 0x5AE96E: GetEthtoolValue (util-ioctl.c:286)
==8084==    by 0x5AF3B4: DisableIfaceOffloadingLinux (util-ioctl.c:434)
==8084==    by 0x558BE6: ParseAFPConfig (runmode-af-packet.c:468)
==8084==    by 0x5E9BC1: RunModeSetLiveCaptureWorkers (util-runmodes.c:373)
==8084==    by 0x55B329: RunModeIdsAFPWorkers (runmode-af-packet.c:693)
==8084==    by 0x563D97: RunModeDispatch (runmodes.c:384)
==8084==    by 0x413512: main (suricata.c:2909)
==8084==  Address 0xffeffcd85 is on thread 1's stack
==8084==  in frame #1, created by GetEthtoolValue (util-ioctl.c:273)
==8084== 
==8084== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==8084==    at 0x7C28F07: ioctl (syscall-template.S:84)
==8084==    by 0x5AE96E: GetEthtoolValue (util-ioctl.c:286)
==8084==    by 0x5AF46C: DisableIfaceOffloadingLinux (util-ioctl.c:441)
==8084==    by 0x558BE6: ParseAFPConfig (runmode-af-packet.c:468)
==8084==    by 0x5E9BC1: RunModeSetLiveCaptureWorkers (util-runmodes.c:373)
==8084==    by 0x55B329: RunModeIdsAFPWorkers (runmode-af-packet.c:693)
==8084==    by 0x563D97: RunModeDispatch (runmodes.c:384)
==8084==    by 0x413512: main (suricata.c:2909)
==8084==  Address 0xffeffcd85 is on thread 1's stack
==8084==  in frame #1, created by GetEthtoolValue (util-ioctl.c:273)
==8084== 
==8084== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==8084==    at 0x7C28F07: ioctl (syscall-template.S:84)
==8084==    by 0x5AE96E: GetEthtoolValue (util-ioctl.c:286)
==8084==    by 0x5AF52A: DisableIfaceOffloadingLinux (util-ioctl.c:448)
==8084==    by 0x558BE6: ParseAFPConfig (runmode-af-packet.c:468)
==8084==    by 0x5E9BC1: RunModeSetLiveCaptureWorkers (util-runmodes.c:373)
==8084==    by 0x55B329: RunModeIdsAFPWorkers (runmode-af-packet.c:693)
==8084==    by 0x563D97: RunModeDispatch (runmodes.c:384)
==8084==    by 0x413512: main (suricata.c:2909)
==8084==  Address 0xffeffcd85 is on thread 1's stack
==8084==  in frame #1, created by GetEthtoolValue (util-ioctl.c:273)
==8084== 
==8084== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==8084==    at 0x7C28F07: ioctl (syscall-template.S:84)
==8084==    by 0x5AE96E: GetEthtoolValue (util-ioctl.c:286)
==8084==    by 0x5AF5E8: DisableIfaceOffloadingLinux (util-ioctl.c:455)
==8084==    by 0x558BE6: ParseAFPConfig (runmode-af-packet.c:468)
==8084==    by 0x5E9BC1: RunModeSetLiveCaptureWorkers (util-runmodes.c:373)
==8084==    by 0x55B329: RunModeIdsAFPWorkers (runmode-af-packet.c:693)
==8084==    by 0x563D97: RunModeDispatch (runmodes.c:384)
==8084==    by 0x413512: main (suricata.c:2909)
==8084==  Address 0xffeffcd85 is on thread 1's stack
==8084==  in frame #1, created by GetEthtoolValue (util-ioctl.c:273)
==8084== 
==8084== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==8084==    at 0x7C28F07: ioctl (syscall-template.S:84)
==8084==    by 0x5AE96E: GetEthtoolValue (util-ioctl.c:286)
==8084==    by 0x5AF6A0: DisableIfaceOffloadingLinux (util-ioctl.c:462)
==8084==    by 0x558BE6: ParseAFPConfig (runmode-af-packet.c:468)
==8084==    by 0x5E9BC1: RunModeSetLiveCaptureWorkers (util-runmodes.c:373)
==8084==    by 0x55B329: RunModeIdsAFPWorkers (runmode-af-packet.c:693)
==8084==    by 0x563D97: RunModeDispatch (runmodes.c:384)
==8084==    by 0x413512: main (suricata.c:2909)
==8084==  Address 0xffeffcd85 is on thread 1's stack
==8084==  in frame #1, created by GetEthtoolValue (util-ioctl.c:273)
==8084== 

Details attached.


Files

bugreport-valgrind (43.8 KB) bugreport-valgrind Peter Manev, 10/12/2017 03:06 PM
Actions #1

Updated by Andreas Herz almost 5 years ago

  • Assignee set to OISF Dev
  • Target version set to TBD
Actions #2

Updated by Victor Julien almost 5 years ago

I don't think we can fix these. Can you see if you can generate suppressions for it? Valgrind as a way to output warnings in their suppression format. Think it's in the -h or manpage how to do it.

Actions #3

Updated by Peter Manev almost 5 years ago

Seems we have those cases (with slight variations) with AFP and pcap - so would investigate a bit further for completeness then will summarize all suppressions and report back.

Actions #4

Updated by Victor Julien almost 5 years ago

  • Status changed from New to Assigned
  • Assignee changed from OISF Dev to Peter Manev
  • Target version changed from TBD to 70

You can add all the unique ones you find to this ticket. If you add suppressions, please update the suppressions file in the source and issue a pull request.

Actions #5

Updated by Peter Manev almost 5 years ago

These are the suppressions I have confirmed so far.

{
   AFP - NIC GET offloading
   Memcheck:Param
   ioctl(SIOCETHTOOL)
   fun:ioctl
   fun:GetEthtoolValue
   fun:DisableIfaceOffloadingLinux
   fun:DisableIfaceOffloading
   fun:ParseAFPConfig
   fun:RunModeSetLiveCaptureWorkers
   fun:RunModeIdsAFPWorkers
   fun:RunModeDispatch
   fun:main
}
{
   AFP - NIC SET offloading 
   Memcheck:Param
   ioctl(SIOCETHTOOL)
   fun:ioctl
   fun:SetEthtoolValue
   fun:DisableIfaceOffloadingLinux
   fun:DisableIfaceOffloading
   fun:ParseAFPConfig
   fun:RunModeSetLiveCaptureWorkers
   fun:RunModeIdsAFPWorkers
   fun:RunModeDispatch
   fun:main
}
{
   NIC Set restore offloading 
   Memcheck:Param
   ioctl(SIOCETHTOOL)
   fun:ioctl
   fun:SetEthtoolValue
   fun:RestoreIfaceOffloadingLinux
   fun:RestoreIfaceOffloading
   fun:LiveDeviceListClean
   fun:GlobalsDestroy
   fun:main
}
{
   Autofp - NIC Get offloading
   Memcheck:Param
   ioctl(SIOCETHTOOL)
   fun:ioctl
   fun:GetEthtoolValue
   fun:GetIfaceOffloadingLinux
   fun:GetIfaceOffloading
   fun:ReceivePcapThreadInit
   fun:TmThreadsSlotPktAcqLoop
   fun:start_thread
   fun:clone
}
{
   Autofp - NIC Get disable offloading
   Memcheck:Param
   ioctl(SIOCETHTOOL)
   fun:ioctl
   fun:GetEthtoolValue
   fun:DisableIfaceOffloadingLinux
   fun:DisableIfaceOffloading
   fun:ReceivePcapThreadInit
   fun:TmThreadsSlotPktAcqLoop
   fun:start_thread
   fun:clone
}
{
   Autofp - NIC Set disable offloading 
   Memcheck:Param
   ioctl(SIOCETHTOOL)
   fun:ioctl
   fun:SetEthtoolValue
   fun:DisableIfaceOffloadingLinux
   fun:DisableIfaceOffloading
   fun:ReceivePcapThreadInit
   fun:TmThreadsSlotPktAcqLoop
   fun:start_thread
   fun:clone
}
{
   Autofp - NIC GetIfaceOffloading
   Memcheck:Cond
   fun:GetIfaceOffloadingLinux
   fun:GetIfaceOffloading
   fun:ReceivePcapThreadInit
   fun:TmThreadsSlotPktAcqLoop
   fun:start_thread
   fun:clone
}
{
   Autofp - NIC DisableIfaceOffloading
   Memcheck:Cond
   fun:DisableIfaceOffloadingLinux
   fun:DisableIfaceOffloading
   fun:ReceivePcapThreadInit
   fun:TmThreadsSlotPktAcqLoop
   fun:start_thread
   fun:clone
}
Actions #6

Updated by Victor Julien almost 5 years ago

Not sure if valgrind supports wildcards, if it does it would be good to use them here.

Something like:

   Memcheck:Cond
   fun:DisableIfaceOffloadingLinux
   fun:DisableIfaceOffloading
   *
Actions #8

Updated by Victor Julien almost 5 years ago

  • Status changed from Assigned to Closed
  • Target version changed from 70 to 4.0.2/4.0.3

Merged pr/2963, thanks Peter.

Actions

Also available in: Atom PDF