Skip to content

Commit

Permalink
Include local features for extra trace to origin
Browse files Browse the repository at this point in the history
Summary: For explotability rules, the features added to the source branch (which is modelled here as a transform branch) is lost when we create the source-as-transform sinks. We add it here.

Reviewed By: arthaud

Differential Revision: D63778687

fbshipit-source-id: ab8fc88f6ff1a004051ac9f53ef18d48ec4f4278
  • Loading branch information
Anwesh Tuladhar authored and facebook-github-bot committed Oct 3, 2024
1 parent f20fcf4 commit 287e57c
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions source/TransformOperations.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,11 @@ Taint apply_source_as_transform_to_sink(
TransformDirection::Backward);

// Add additional features
transformed_sink_taint.add_locally_inferred_features(
FeatureMayAlwaysSet{context->feature_factory.get_exploitability_root()});
FeatureMayAlwaysSet additional_features{
context->feature_factory.get_exploitability_root()};
// Features found in the source branch should be a part of the final issue.
additional_features.add(source_taint.features_joined());
transformed_sink_taint.add_locally_inferred_features(additional_features);

// Add extra trace and exploitability origin to source frame
transformed_sink_taint.update_with_extra_trace_and_exploitability_origin(
Expand Down

0 comments on commit 287e57c

Please sign in to comment.