Hello, have a look at the -z switch in yara command manual (*man yara* or
here <https://yara.readthedocs.io/en/stable/commandline.html>).

If you want to do this programmatically, you can just read the first 200KB
of the file before passing it to libyara. ;)

Best,


On Tue, Aug 22, 2023 at 9:34 AM neslihan hanecioglu <
neslihanecio...@gmail.com> wrote:

> Hi,
>
> During the file scanning, I do not want to examine after a certain size.
> For example, for a 100 mb file, I want to scan the first 200 kb and get its
> match result, Not scanning after 200kb. Wow can i achieve this with yara
> rule or python script. I wan to give full file to Yara and Yara not read
> full text as I explained the above. It is important for speed.
>
> Thank you for response.
> Sincerely.
>
> --
> You received this message because you are subscribed to the Google Groups
> "YARA" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to yara-project+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/yara-project/c016a513-da34-4b25-88b6-f8b3367395e5n%40googlegroups.com
> <https://groups.google.com/d/msgid/yara-project/c016a513-da34-4b25-88b6-f8b3367395e5n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"YARA" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to yara-project+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/yara-project/CAM7p17NeeTzTL7hFG3m_zQZ3j0a5N7vt5xD-cZ6sE6KjW6t3%2Bw%40mail.gmail.com.

Reply via email to