-
Notifications
You must be signed in to change notification settings - Fork 3
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
Conversation
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.
UI5PathGraph to use the newer data flow API
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
javascript/frameworks/ui5/lib/advanced_security/javascript/frameworks/ui5/UI5XssQuery.qll
Show resolved
Hide resolved
...script/frameworks/ui5/lib/advanced_security/javascript/frameworks/ui5/UI5LogsToHttpQuery.qll
Outdated
Show resolved
Hide resolved
knewbury01
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
other than a few small questions/nitpicks, this looks good to me!
one more last little request/suggestion - maybe we can also open an issue for the future works item: Write a developer's guideline on using the new UI5PathGraph, as it is easy to forget to import the instantiated UI5PathGraph.
…-security/codeql-sap-js into jeongsoolee09/port-UI5PathGraph
|
@knewbury01 Issue opened at #229! |
knewbury01
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm! thanks for addressing the comments :)
What This PR Contributes
Port over
UI5PathGraphand all UI5 queries depending on itPort UI5 queries from the old data flow API that uses
TaintTracking::Configurationto the new one. Porting UI5 queries requires care since it depends onUI5PathGraphthat enables UI5 binding paths appearing in UI5 views (e.g. XML views) to be included in the path information.The implementation of
UI5PathGraphpreviously depended upon the fact that there is only onePathNodetype:DataFlow::PathNode. This is no longer the case with the newer API where each data flow configuration module has their ownPathNodetypes. Therefore, the newUI5PathGraphis parameterized on a data flow configuration module like the following:One could argue that it could be shortened to
module UI5PathGraph<DataFlow::GlobalFlowSig ConfigModule>based on the usagemodule UI5XssUI5PathGraph = UI5PathGraph<UI5XssFlow::PathNode, UI5XssFlow::PathGraph>, butConfigModule::PathNodedoes not exposegetNodesince there is no type-level constraint on the memberPathNode(its declaration is onlyclass PathNode;).Resolve deprecation warning on
AmdModuleDefinition.getDependency/1Use
AmdModuleDefinition.getDependencyExpr/1instead because of the above being deprecated.Future Works
UI5PathGraph, as it is easy to forget toimportthe instantiatedUI5PathGraph.PathString.