xsos icon indicating copy to clipboard operation
xsos copied to clipboard

Add check for 3rd party NIC modules in -e ethtool output?

Open ptalbert opened this issue 9 years ago • 2 comments

The ethtool output currently shows (among others) the driver and firmware information per interface. It would be useful for it to somehow flag the driver output when an unsigned module is being used.

This information could be gathered from the modinfo output provided by the kernel sosreport module.

ptalbert avatar Jan 05 '15 20:01 ptalbert

@ptalbert can you give me a sosreport that has some unsigned modules?

ryran avatar Jan 07 '15 21:01 ryran

For RHEL6 & below, steps could look like this:

  1. Get list of NIC drivers from ethtool: drivers=$(awk '/^driver:/{print $2}' sos_commands/networking/ethtool_-i_* | sort -u)
  2. Iterate over driver list, pulling their filenames from modinfo output: for driver in ${drivers}; do grep "^filename: .*${driver}.ko" sos_commands/kernel/modinfo_*; done
  3. Throw a warning if path does not match /lib/modules/$(uname -r)/kernel/drivers/net/${driver).ko

Looks like RHEL7 added signer: and sig_key: to modinfo output so we could take advantage of that too.

ryran avatar Jan 16 '15 23:01 ryran