Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added checks for MaxRecursion #1264

Merged

Conversation

ragusaa
Copy link
Contributor

@ragusaa ragusaa commented May 7, 2024

No description provided.

@ragusaa ragusaa force-pushed the CLAM-2602-ValidateMaxRecursion branch from 2b09e8a to 324d06b Compare May 7, 2024 16:12
clamd/server-th.c Fixed Show resolved Hide resolved
clamd/server-th.c Outdated Show resolved Hide resolved
clamscan/manager.c Outdated Show resolved Hide resolved
libclamav/default.h Show resolved Hide resolved
clamd/server-th.c Fixed Show resolved Hide resolved
@ragusaa ragusaa force-pushed the CLAM-2602-ValidateMaxRecursion branch 4 times, most recently from fbfedaf to 4c9709a Compare May 15, 2024 20:19
@ragusaa ragusaa force-pushed the CLAM-2602-ValidateMaxRecursion branch 3 times, most recently from ac78ae8 to c866085 Compare June 28, 2024 19:46
micahsnyder
micahsnyder previously approved these changes Jul 17, 2024
Copy link
Contributor

@micahsnyder micahsnyder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

There is presently no limit for the max-recursion scan option.
Selecting a max-recursion limit that is too high will cause confusing
errors. E.g.:

/home/aragusa/install.alz/bin/clamscan -d clamav.hdb . --max-recursion=9999999999

LibClamAV Error: fmap_fd: Attempted to get fd for NULL fmap
/home/aragusa/issue/clamav.hdb: Can't allocate memory ERROR
LibClamAV Error: fmap_fd: Attempted to get fd for NULL fmap
/home/aragusa/issue/test.sh: Can't allocate memory ERROR

This commit prevents setting the max-recursion limit higher than 100.
@micahsnyder micahsnyder merged commit 51e2390 into Cisco-Talos:main Sep 9, 2024
23 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants