xaitax / SploitScan

SploitScan is a sophisticated cybersecurity utility designed to provide detailed information on vulnerabilities and associated exploits.
GNU General Public License v3.0
923 stars 114 forks source link

CSV Export crash #30

Closed xaitax closed 1 month ago

xaitax commented 1 month ago

python3 sploitscan.py -e csv CVE-2024-26600 CVE-2024-26808

███████╗██████╗ ██╗ ██████╗ ██╗████████╗███████╗ ██████╗ █████╗ ███╗ ██╗ ██╔════╝██╔══██╗██║ ██╔═══██╗██║╚══██╔══╝██╔════╝██╔════╝██╔══██╗████╗ ██║ ███████╗██████╔╝██║ ██║ ██║██║ ██║ ███████╗██║ ███████║██╔██╗ ██║ ╚════██║██╔═══╝ ██║ ██║ ██║██║ ██║ ╚════██║██║ ██╔══██║██║╚██╗██║ ███████║██║ ███████╗╚██████╔╝██║ ██║ ███████║╚██████╗██║ ██║██║ ╚████║ ╚══════╝╚═╝ ╚══════╝ ╚═════╝ ╚═╝ ╚═╝ ╚══════╝ ╚═════╝╚═╝ ╚═╝╚═╝ ╚═══╝ v0.10.5 / Alexander Hagenah / @xaitax / ah@primepage.de

╔════════════════════════╗ ║ CVE ID: CVE-2024-26600 ║ ╚════════════════════════╝

┌───[ 🔍 Vulnerability information ] | ├ Published: 2024-02-24 ├ Base Score: N/A (N/A) ├ Vector: N/A └ Description: In the Linux kernel, the following vulnerability has been resolved: phy: ti: phy-omap-usb2: Fix NULL pointer dereference for SRP If the external phy working together with phy-omap-usb2 does not implement send_srp(), we may still attempt to call it. This can happen on an idle Ethernet gadget triggering a wakeup for example: configfs-gadget.g1 gadget.0: ECM Suspend configfs-gadget.g1 gadget.0: Port suspended. Triggering wakeup ... Unable to handle kernel NULL pointer dereference at virtual address 00000000 when execute ... PC is at 0x0 LR is at musb_gadget_wakeup+0x1d4/0x254 [musb_hdrc] ... musb_gadget_wakeup [musb_hdrc] from usb_gadget_wakeup+0x1c/0x3c [udc_core] usb_gadget_wakeup [udc_core] from eth_start_xmit+0x3b0/0x3d4 [u_ether] eth_start_xmit [u_ether] from dev_hard_start_xmit+0x94/0x24c dev_hard_start_xmit from sch_direct_xmit+0x104/0x2e4 sch_direct_xmit from dev_queue_xmit+0x334/0xd88 dev_queue_xmit from arp_solicit+0xf0/0x268 arp_solicit from neigh_probe+0x54/0x7c neigh_probe from neigh_event_send+0x22c/0x47c neigh_event_send from neigh_resolve_output+0x14c/0x1c0 neigh_resolve_output from ip_finish_output2+0x1c8/0x628 ip_finish_output2 from ip_send_skb+0x40/0xd8 ip_send_skb from udp_send_skb+0x124/0x340 udp_send_skb from udp_sendmsg+0x780/0x984 udp_sendmsg from __sys_sendto+0xd8/0x158 __sys_sendto from ret_fast_syscall+0x0/0x58 Let's fix the issue by checking for send_srp() and set_vbus() before calling them. For USB peripheral only cases these both could be NULL.

┌───[ ♾️ Exploit Prediction Score (EPSS) ] | └ EPSS Score: 0.04% Probability of exploitation.

┌───[ 🛡️ CISA KEV Catalog ] | └ ❌ No data found.

┌───[ 💣 Public Exploits (Total: 0) ] | │ └ Other └ PacketStorm: https://packetstormsecurity.com/search/?q=CVE-2024-26600

┌───[ 🕵️ HackerOne Hacktivity ] | ├ Rank: 6916 ├ Reports: 0 └ Severity: Unknown: 0 / None: 0 / Low: 0 / Medium: 0 / High: 0 / Critical: 0

┌───[ 🤖 AI-Powered Risk Assessment ]
❌ OpenAI API key is not configured correctly.

└────────────────────────────────────────

┌───[ ⚠️ Patching Priority Rating ] | └ Priority: D

┌───[ 📚 Further References ] | ├ https://git.kernel.org/stable/c/486218c11e8d1c8f515a3bdd70d62203609d4b6bhttps://git.kernel.org/stable/c/8398d8d735ee93a04fb9e9f490e8cacd737e3bf5https://git.kernel.org/stable/c/be3b82e4871ba00e9b5d0ede92d396d579d7b3b3https://git.kernel.org/stable/c/8cc889b9dea0579726be9520fcc766077890b462https://git.kernel.org/stable/c/0430bfcd46657d9116a26cd377f112cbc40826a4https://git.kernel.org/stable/c/14ef61594a5a286ae0d493b8acbf9eac46fd04c4https://git.kernel.org/stable/c/396e17af6761b3cc9e6e4ca94b4de7f642bfece1https://git.kernel.org/stable/c/7104ba0f1958adb250319e68a15eff89ec4fd36dhttps://lists.debian.org/debian-lts-announce/2024/06/msg00017.htmlhttps://lists.debian.org/debian-lts-announce/2024/06/msg00020.html

╔════════════════════════╗ ║ CVE ID: CVE-2024-26808 ║ ╚════════════════════════╝

┌───[ 🔍 Vulnerability information ] | ├ Published: 2024-04-04 ├ Base Score: N/A (N/A) ├ Vector: N/A └ Description: In the Linux kernel, the following vulnerability has been resolved: netfilter: nft_chain_filter: handle NETDEV_UNREGISTER for inet/ingress basechain Remove netdevice from inet/ingress basechain in case NETDEV_UNREGISTER event is reported, otherwise a stale reference to netdevice remains in the hook list.

┌───[ ♾️ Exploit Prediction Score (EPSS) ] | └ EPSS Score: 0.04% Probability of exploitation.

┌───[ 🛡️ CISA KEV Catalog ] | └ ❌ No data found.

┌───[ 💣 Public Exploits (Total: 0) ] | └ ❌ No data found.

┌───[ 🕵️ HackerOne Hacktivity ] | ├ Rank: 6916 ├ Reports: 0 └ Severity: Unknown: 0 / None: 0 / Low: 0 / Medium: 0 / High: 0 / Critical: 0

┌───[ 🤖 AI-Powered Risk Assessment ]
❌ OpenAI API key is not configured correctly.

└────────────────────────────────────────

┌───[ ⚠️ Patching Priority Rating ] | └ Priority: D

┌───[ 📚 Further References ] | ├ https://git.kernel.org/stable/c/9489e214ea8f2a90345516016aa51f2db3a8cc2fhttps://git.kernel.org/stable/c/70f17b48c86622217a58d5099d29242fc9adac58https://git.kernel.org/stable/c/af149a46890e8285d1618bd68b8d159bdb87fdb3https://git.kernel.org/stable/c/e5888acbf1a3d8d021990ce6c6061fd5b2bb21b4https://git.kernel.org/stable/c/36a0a80f32209238469deb481967d777a3d539eehttps://git.kernel.org/stable/c/01acb2e8666a6529697141a6017edbf206921913https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html

┌───[ 📁 CSV Export ] | Traceback (most recent call last): File "C:\Users\Admin\SploitScan\sploitscan.py", line 6, in cli() File "C:\Users\Admin\SploitScan\sploitscan\sploitscan.py", line 1087, in cli main(args.cve_ids, args.export, args.import_file, args.type, args.config, args.debug) File "C:\Users\Admin\SploitScan\sploitscan\sploitscan.py", line 1037, in main export_to_csv(all_results, cve_ids) File "C:\Users\Admin\SploitScan\sploitscan\sploitscan.py", line 849, in export_to_csv display_data("📁 CSV Export", all_results, template) File "C:\Users\Admin\SploitScan\sploitscan\sploitscan.py", line 203, in display_data for line in template(data): File "C:\Users\Admin\SploitScan\sploitscan\sploitscan.py", line 846, in template writer.writerow(item) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.3056.0_x64__qbz5n2kfra8p0\lib\csv.py", line 154, in writerow return self.writer.writerow(self._dict_to_list(rowdict)) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.3056.0_x64__qbz5n2kfra8p0\lib\encodings\cp1252.py", line 19, in encode return codecs.charmap_encode(input,self.errors,encoding_table)[0] UnicodeEncodeError: 'charmap' codec can't encode character '\u274c' in position 7668: character maps to

xaitax commented 1 month ago

Fixed in https://github.com/xaitax/SploitScan/commit/ce0eb1a8302cb404412d3c22bb995a23d9cd31b1