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

transform: luaxform transform script #12130

Closed
wants to merge 7 commits into from
Closed

Commits on Nov 19, 2024

  1. transforms: Make ctx available

    This commit makes the detection engine thread context available for
    transforms to use. The Lua transform requires this value.
    
    Issue: 2290
    jlucovsky committed Nov 19, 2024
    Configuration menu
    Copy the full SHA
    61fac5a View commit details
    Browse the repository at this point in the history
  2. hash: Provide detection engine context to free fn

    Issue: 2290
    
    This commit extends the hash table logic with an alternate free function
    that provides the detection engine context.
    
    Users that wish to use the next functionality must use the
    HashListTableInitWithCtx function when initializing the hash table.
    Using this interface will result in the hash table "free with context"
    function (new) being used instead.
    jlucovsky committed Nov 19, 2024
    Configuration menu
    Copy the full SHA
    74eb71b View commit details
    Browse the repository at this point in the history
  3. detect/engine: Prevent double-free of keyword hash

    Issue: 2290
    
    Defer freeing the keyword hash table until the engine context has
    been freed. This eliminates a double-free from occurring.
    
    For the unittests ONLY, clear the keyword_hash to prevent a double
    free attempt.
    jlucovsky committed Nov 19, 2024
    Configuration menu
    Copy the full SHA
    14af958 View commit details
    Browse the repository at this point in the history
  4. transform: Add luaxform files

    Issue: 2290
    
    This commit adds the source files for the new transform -- luaxform.
    jlucovsky committed Nov 19, 2024
    Configuration menu
    Copy the full SHA
    ddde6fd View commit details
    Browse the repository at this point in the history
  5. doc: Document luaxform transform

    Issue: 2290
    jlucovsky committed Nov 19, 2024
    Configuration menu
    Copy the full SHA
    fd485b0 View commit details
    Browse the repository at this point in the history
  6. detect/transform: Refactor setup/apply pattern

    git grep -A 1 -w InspectionBufferSetup shows numbers cases of the pattern:
        - InspectionBufferSetup
        - InspectionBufferApplyTransforms
    
    Refactor the implementations of those functions into
    InspectionBufferSetupAndApplyTransforms to reduce function call count.
    
    Issuer: 2290
    jlucovsky committed Nov 19, 2024
    Configuration menu
    Copy the full SHA
    7239472 View commit details
    Browse the repository at this point in the history
  7. clang/format: Fixup format

    Address clang-format issue with otherwise unchanged source file.
    jlucovsky committed Nov 19, 2024
    Configuration menu
    Copy the full SHA
    01937b8 View commit details
    Browse the repository at this point in the history