Skip to content

Port UI5PathGraph to use the newer data flow API #216

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

Open
wants to merge 18 commits into
base: main
Choose a base branch
from

Conversation

jeongsoolee09
Copy link
Contributor

@jeongsoolee09 jeongsoolee09 commented Aug 13, 2025

What This PR Contributes

Port over UI5PathGraph and all UI5 queries depending on it

Port UI5 queries from the old data flow API that uses TaintTracking::Configuration to the new one. Porting UI5 queries requires care since it depends on UI5PathGraph that enables UI5 binding paths appearing in UI5 views (e.g. XML views) to be included in the path information.

The implementation of UI5PathGraph previously depended upon the fact that there is only one PathNode type: DataFlow::PathNode. This is no longer the case with the newer API where each data flow configuration module has their own PathNode types. Therefore, the new UI5PathGraph is parameterized on a data flow configuration module like the following:

module UI5PathGraph<DataFlow::PathNodeSig ConfigPathNode, DataFlow::PathGraphSig<ConfigPathNode> ConfigPathGraph> {
  ...
}

One could argue that it could be shortened to module UI5PathGraph<DataFlow::GlobalFlowSig ConfigModule> based on the usage module UI5XssUI5PathGraph = UI5PathGraph<UI5XssFlow::PathNode, UI5XssFlow::PathGraph>, but ConfigModule::PathNode does not expose getNode since there is no type-level constraint on the member PathNode (its declaration is only class PathNode;).

Resolve deprecation warning on AmdModuleDefinition.getDependency/1

Use AmdModuleDefinition.getDependencyExpr/1 instead because of the above being deprecated.

Future Works

  • Write a developer's guideline on using the new UI5PathGraph, as it is easy to forget to import the instantiated UI5PathGraph.
  • Resolve the deprecation warning on PathString.

All of the disappeared edges are circular ones that "circles back"
on itself and does not influence the analysis at all.
- Port over UI5PathInjection.
- Create a UI5PathInjectionQuery file and move the configuration there.
- Update expected results of the query.
@jeongsoolee09 jeongsoolee09 changed the title Port UI5PathGraph to use the newer data flow API Port UI5PathGraph to use the newer data flow API Aug 13, 2025
NOTE: The end-to-end results of the queries are okay (the #select portion is unchanged),
but there are difference in `nodes` and `edges` that probably needs attention.
NOTE: The end-to-end results of the queries are okay (the `#select` portion is unchanged),
but there are difference in `nodes` and `edges` that probably needs attention.
These are results with changes in only nodes and edges.
We accept it because it means there are no changes in
the overall behavior.
These are results with changes in only nodes and edges.
We accept it because it means there are no changes in
the overall behavior.
…-security/codeql-sap-js into jeongsoolee09/port-UI5PathGraph
@jeongsoolee09 jeongsoolee09 marked this pull request as ready for review August 19, 2025 19:24
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.

1 participant