OrenGitHub / dhscanner

free as in speech container scanner
https://orengithub.github.io/
1 stars 0 forks source link

Send js code to front.js language parser ( esprima ) #3

Closed OrenGitHub closed 2 months ago

OrenGitHub commented 2 months ago

from inside the dhscanner docker:

$ python dhscanner.py --workdir=workdir --input=example.tar > output.txt
$ sed -n "1,20p" output.txt
[11/04/2024 ( 07:32:39 )] [INFO]: everything looks great - starting to untar 😃
[11/04/2024 ( 07:32:42 )] [INFO]: everything looks great - finished untar 😃
[11/04/2024 ( 07:32:42 )] [INFO]: found 2 first party js files
[11/04/2024 ( 07:32:42 )] [DEBUG]: collected js: workdir/2fea73a09f3b1643d44ed7dd8d22957cc61bd0e1ab3eac2f7014b3860dd257a5/usr/app/main.js
[11/04/2024 ( 07:32:42 )] [DEBUG]: collected js: workdir/5ce0533e8ae9b7cdd3e39fd24602046d4da3ef2335851f43e208e8380ec84e8e/usr/share/gitweb/static/gitweb.js
[11/04/2024 ( 07:32:42 )] [DEBUG]: Starting new HTTP connection (1): 127.0.0.1:8000
[11/04/2024 ( 07:32:42 )] [DEBUG]: http://127.0.0.1:8000 "POST /to/esprima/js/ast HTTP/1.1" 200 15249
[11/04/2024 ( 07:32:42 )] [DEBUG]: Starting new HTTP connection (1): 127.0.0.1:8000
[11/04/2024 ( 07:32:42 )] [DEBUG]: http://127.0.0.1:8000 "POST /to/esprima/js/ast HTTP/1.1" 200 434807
[11/04/2024 ( 07:32:42 )] [DEBUG]: workdir/2fea73a09f3b1643d44ed7dd8d22957cc61bd0e1ab3eac2f7014b3860dd257a5/usr/app/main.js ---> {
    "type": "Program",
    "body": [
        {
            "type": "VariableDeclaration",
            "declarations": [
                {
                    "type": "VariableDeclarator",
                    "id": {
                        "type": "Identifier",
                        "name": "express",