SySeVR复现

ningan@ubuntu:~/JOERN/usr/Neo4j/neo4j-community-2.1.8/bin$ sudo ./neo4j console

ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo rm -rf .joernIndex
ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo java -jar /home/ningan/JOERN/joern-0.3.1/bin/joern.jar /home/ningan/JOERN/joern-0.3.1/anan_testcode/

ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py

ningan@ubuntu:~/JOERN/usr/Neo4j/neo4j-community-2.1.8$ ls
bin          conf  hs_err_pid3325.log  LICENSES.txt  NOTICE.txt  README.txt  UPGRADE.txt
CHANGES.txt  data  lib                 LICENSE.txt   plugins     system
ningan@ubuntu:~/JOERN/usr/Neo4j/neo4j-community-2.1.8$ 
ningan@ubuntu:~/JOERN/usr/Neo4j/neo4j-community-2.1.8$ 
ningan@ubuntu:~/JOERN/usr/Neo4j/neo4j-community-2.1.8$ cd bin
ningan@ubuntu:~/JOERN/usr/Neo4j/neo4j-community-2.1.8/bin$ sudo ./neo4j console
[sudo] password for ningan: 
WARNING: Max 1024 open files allowed, minimum of 40 000 recommended. See the Neo4j manual.
Starting Neo4j Server console-mode...
Using additional JVM arguments:  -server -XX:+DisableExplicitGC -Dorg.neo4j.server.properties=conf/neo4j-server.properties -Djava.util.logging.config.file=conf/logging.properties -Dlog4j.configuration=file:conf/log4j.properties -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -XX:-OmitStackTraceInFastThrow -XX:PermSize=64m -XX:MaxPermSize=4g
OpenJDK 64-Bit Server VM warning: ignoring option PermSize=64m; support was removed in 8.0
OpenJDK 64-Bit Server VM warning: ignoring option MaxPermSize=4g; support was removed in 8.0
2019-12-19 10:31:56.314+0000 INFO  [API] Setting startup timeout to: 120000ms based on -1
Detected incorrectly shut down database, performing recovery..
2019-12-19 10:31:58.296+0000 INFO  [API] Successfully started database
2019-12-19 10:31:58.421+0000 INFO  [API] Starting HTTP on port :7474 with 10 threads available
2019-12-19 10:31:58.709+0000 INFO  [API] Enabling HTTPS on port :7473
2019-12-19 10:31:58.908+0000 INFO  [API] Mounted discovery module at [/]
2019-12-19 10:31:58.968+0000 INFO  [API] Loaded server plugin "GremlinPlugin"
2019-12-19 10:31:58.971+0000 INFO  [API]   GraphDatabaseService.execute_script: execute a Gremlin script with 'g' set to the Neo4j2Graph and 'results' containing the results. Only results of one object type is supported.
2019-12-19 10:31:58.980+0000 INFO  [API] Mounted REST API at [/db/data/]
2019-12-19 10:31:58.982+0000 INFO  [API] Mounted management API at [/db/manage/]
2019-12-19 10:31:58.982+0000 INFO  [API] Mounted webadmin at [/webadmin]
2019-12-19 10:31:58.982+0000 INFO  [API] Mounted Neo4j Browser at [/browser]
2019-12-19 10:31:59.075+0000 INFO  [API] Mounting static content at [/webadmin] from [webadmin-html]
2019-12-19 10:31:59.167+0000 INFO  [API] Mounting static content at [/browser] from [browser]
02:31:59.173 [main] WARN  o.e.j.server.handler.ContextHandler - o.e.j.s.ServletContextHandler@14fc5d40{/,null,null} contextPath ends with /
02:31:59.173 [main] WARN  o.e.j.server.handler.ContextHandler - Empty contextPath
02:31:59.175 [main] INFO  org.eclipse.jetty.server.Server - jetty-9.0.5.v20130815
02:31:59.226 [main] INFO  o.e.j.server.handler.ContextHandler - Started o.e.j.s.h.MovedContextHandler@49a71302{/,null,AVAILABLE}
02:31:59.331 [main] INFO  o.e.j.w.StandardDescriptorProcessor - NO JSP Support for /webadmin, did not find org.apache.jasper.servlet.JspServlet
02:31:59.350 [main] INFO  o.e.j.server.handler.ContextHandler - Started o.e.j.w.WebAppContext@ae7950d{/webadmin,jar:file:/home/ningan/JOERN/usr/Neo4j/neo4j-community-2.1.8/system/lib/neo4j-server-2.1.8-static-web.jar!/webadmin-html,AVAILABLE}
02:31:59.997 [main] INFO  o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler@21ac5eb4{/db/manage,null,AVAILABLE}
02:32:00.252 [main] INFO  o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler@7c8f9c2e{/db/data,null,AVAILABLE}
02:32:00.271 [main] INFO  o.e.j.w.StandardDescriptorProcessor - NO JSP Support for /browser, did not find org.apache.jasper.servlet.JspServlet
02:32:00.272 [main] INFO  o.e.j.server.handler.ContextHandler - Started o.e.j.w.WebAppContext@7e2c64{/browser,jar:file:/home/ningan/JOERN/usr/Neo4j/neo4j-community-2.1.8/system/lib/neo4j-browser-2.1.8.jar!/browser,AVAILABLE}
02:32:00.391 [main] INFO  o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler@14fc5d40{/,null,AVAILABLE}
02:32:00.431 [main] INFO  o.e.jetty.server.ServerConnector - Started ServerConnector@38aafb53{HTTP/1.1}{0.0.0.0:7474}
02:32:00.528 [main] INFO  o.e.jetty.server.ServerConnector - Started ServerConnector@71d9cb05{SSL-HTTP/1.1}{0.0.0.0:7473}
2019-12-19 10:32:00.528+0000 INFO  [API] Server started on: http://0.0.0.0:7474/
2019-12-19 10:32:00.528+0000 INFO  [API] Remote interface ready and available at [http://0.0.0.0:7474/]
./neo4j: line 261: 21140 Killed                  "$JAVACMD" -cp "${CLASSPATH}" $JAVA_OPTS -Dneo4j.home="${NEO4J_HOME}" -Dneo4j.instance="${NEO4J_INSTANCE}" -Dfile.encoding=UTF-8 org.neo4j.server.Bootstrapper
ningan@ubuntu:~/JOERN/usr/Neo4j/neo4j-community-2.1.8/bin$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python --version
Python 2.7.12
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ ls
access_db_operate.py  data_preprocess.py  general_op.py        make_label.py  slice_op.py
complete_PDG.py       extract_df.py       get_cfg_relation.py  points_get.py
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 
Traceback (most recent call last):
  File "get_cfg_relation.py", line 2, in <module>
    from access_db_operate import *
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 3, in <module>
    from igraph import *
ImportError: No module named igraph
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip install ipython==5.3.1
[sudo] password for ningan: 
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip2 install ipython==5.3.1
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/ningan/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting ipython==5.3.1
  Could not find a version that satisfies the requirement ipython==5.3.1 (from versions: 0.10, 0.10.1, 0.10.2, 0.11, 0.12, 0.12.1, 0.13, 0.13.1, 0.13.2, 1.0.0, 1.1.0, 1.2.0, 1.2.1, 2.0.0, 2.1.0, 2.2.0, 2.3.0, 2.3.1, 2.4.0, 2.4.1, 3.0.0, 3.1.0, 3.2.0, 3.2.1, 3.2.2, 3.2.3, 4.0.0b1, 4.0.0, 4.0.1, 4.0.2, 4.0.3, 4.1.0rc1, 4.1.0rc2, 4.1.0, 4.1.1, 4.1.2, 4.2.0, 4.2.1, 5.0.0b1, 5.0.0b2, 5.0.0b3, 5.0.0b4, 5.0.0rc1, 5.0.0, 5.1.0, 5.2.0, 5.2.1, 5.2.2, 5.3.0, 5.4.0, 5.4.1, 5.5.0, 5.6.0, 5.7.0, 5.8.0, 6.0.0rc1, 6.0.0, 6.1.0, 6.2.0, 6.2.1, 6.3.0, 6.3.1, 6.4.0, 6.5.0, 7.0.0b1, 7.0.0rc1, 7.0.0, 7.0.1, 7.1.0, 7.1.1, 7.2.0, 7.3.0, 7.4.0, 7.5.0, 7.6.0, 7.6.1, 7.7.0, 7.8.0, 7.9.0, 7.10.0, 7.10.1, 7.10.2)
No matching distribution found for ipython==5.3.1
You are using pip version 8.1.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip2 install ipython==5.3.0
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/ningan/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting ipython==5.3.0
  Downloading https://files.pythonhosted.org/packages/b0/2f/7c8ba9581b538b91ea4c9df6a08b5d2901519003956bad059458bfab73f1/ipython-5.3.0-py2-none-any.whl (750kB)
    100% |████████████████████████████████| 757kB 1.5MB/s 
Collecting prompt-toolkit<2.0.0,>=1.0.4 (from ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/9d/d2/2f099b5cd62dab819ce7a9f1431c09a9032fbfbb6474f442722e88935376/prompt_toolkit-1.0.18-py2-none-any.whl (245kB)
    100% |████████████████████████████████| 245kB 3.3MB/s 
Collecting decorator (from ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/8f/b7/f329cfdc75f3d28d12c65980e4469e2fa373f1953f5df6e370e84ea2e875/decorator-4.4.1-py2.py3-none-any.whl
Collecting pexpect; sys_platform != "win32" (from ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/0e/3e/377007e3f36ec42f1b84ec322ee12141a9e10d808312e5738f52f80a232c/pexpect-4.7.0-py2.py3-none-any.whl (58kB)
    100% |████████████████████████████████| 61kB 4.4MB/s 
Collecting backports.shutil-get-terminal-size; python_version == "2.7" (from ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/7d/cd/1750d6c35fe86d35f8562091737907f234b78fdffab42b29c72b1dd861f4/backports.shutil_get_terminal_size-1.0.0-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): setuptools>=18.5 in /usr/lib/python2.7/dist-packages (from ipython==5.3.0)
Requirement already satisfied (use --upgrade to upgrade): pygments in /home/ningan/.local/lib/python2.7/site-packages (from ipython==5.3.0)
Requirement already satisfied (use --upgrade to upgrade): pathlib2; python_version == "2.7" or python_version == "3.3" in /home/ningan/.local/lib/python2.7/site-packages (from ipython==5.3.0)
Collecting traitlets>=4.2 (from ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/ca/ab/872a23e29cec3cf2594af7e857f18b687ad21039c1f9b922fac5b9b142d5/traitlets-4.3.3-py2.py3-none-any.whl (75kB)
    100% |████████████████████████████████| 81kB 2.4MB/s 
Collecting simplegeneric>0.8 (from ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/3d/57/4d9c9e3ae9a255cd4e1106bb57e24056d3d0709fc01b2e3e345898e49d5b/simplegeneric-0.8.1.zip
Collecting pickleshare (from ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/9a/41/220f49aaea88bc6fa6cba8d05ecf24676326156c23b991e80b3f2fc24c77/pickleshare-0.7.5-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): wcwidth in /home/ningan/.local/lib/python2.7/site-packages (from prompt-toolkit<2.0.0,>=1.0.4->ipython==5.3.0)
Requirement already satisfied (use --upgrade to upgrade): six>=1.9.0 in /home/ningan/.local/lib/python2.7/site-packages (from prompt-toolkit<2.0.0,>=1.0.4->ipython==5.3.0)
Collecting ptyprocess>=0.5 (from pexpect; sys_platform != "win32"->ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/d1/29/605c2cc68a9992d18dada28206eeada56ea4bd07a239669da41674648b6f/ptyprocess-0.6.0-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): scandir; python_version < "3.5" in /home/ningan/.local/lib/python2.7/site-packages (from pathlib2; python_version == "2.7" or python_version == "3.3"->ipython==5.3.0)
Collecting ipython-genutils (from traitlets>=4.2->ipython==5.3.0)
  Downloading https://files.pythonhosted.org/packages/fa/bc/9bd3b5c2b4774d5f33b2d544f1460be9df7df2fe42f352135381c347c69a/ipython_genutils-0.2.0-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): enum34; python_version == "2.7" in /home/ningan/.local/lib/python2.7/site-packages (from traitlets>=4.2->ipython==5.3.0)
Installing collected packages: prompt-toolkit, decorator, ptyprocess, pexpect, backports.shutil-get-terminal-size, ipython-genutils, traitlets, simplegeneric, pickleshare, ipython
  Running setup.py install for simplegeneric ... done
Successfully installed backports.shutil-get-terminal-size-1.0.0 decorator-4.4.1 ipython-5.3.0 ipython-genutils-0.2.0 pexpect-4.7.0 pickleshare-0.7.5 prompt-toolkit-1.0.18 ptyprocess-0.6.0 simplegeneric-0.8.1 traitlets-4.3.3
You are using pip version 8.1.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 
Traceback (most recent call last):
  File "get_cfg_relation.py", line 2, in <module>
    from access_db_operate import *
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 3, in <module>
    from igraph import *
ImportError: No module named igraph
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ pip install igraph
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Collecting igraph
  Downloading https://files.pythonhosted.org/packages/91/15/7c606c483a401dfdcdd19f2688c83585ee3b5ef401bd4e0e647660ef5b3f/igraph-0.1.11-py2.py3-none-any.whl (119kB)
     |████████████████████████████████| 122kB 228kB/s 
Requirement already satisfied: ipython in /usr/local/lib/python2.7/dist-packages (from igraph) (5.3.0)
Requirement already satisfied: prompt-toolkit<2.0.0,>=1.0.4 in /usr/local/lib/python2.7/dist-packages (from ipython->igraph) (1.0.18)
Requirement already satisfied: decorator in /usr/local/lib/python2.7/dist-packages (from ipython->igraph) (4.4.1)
Requirement already satisfied: pexpect; sys_platform != "win32" in /usr/local/lib/python2.7/dist-packages (from ipython->igraph) (4.7.0)
Requirement already satisfied: backports.shutil-get-terminal-size; python_version == "2.7" in /usr/local/lib/python2.7/dist-packages (from ipython->igraph) (1.0.0)
Requirement already satisfied: setuptools>=18.5 in /usr/lib/python2.7/dist-packages (from ipython->igraph) (20.7.0)
Requirement already satisfied: pygments in /home/ningan/.local/lib/python2.7/site-packages (from ipython->igraph) (2.4.2)
Requirement already satisfied: pathlib2; python_version == "2.7" or python_version == "3.3" in /home/ningan/.local/lib/python2.7/site-packages (from ipython->igraph) (2.3.5)
Requirement already satisfied: traitlets>=4.2 in /usr/local/lib/python2.7/dist-packages (from ipython->igraph) (4.3.3)
Requirement already satisfied: simplegeneric>0.8 in /usr/local/lib/python2.7/dist-packages (from ipython->igraph) (0.8.1)
Requirement already satisfied: pickleshare in /usr/local/lib/python2.7/dist-packages (from ipython->igraph) (0.7.5)
Requirement already satisfied: wcwidth in /home/ningan/.local/lib/python2.7/site-packages (from prompt-toolkit<2.0.0,>=1.0.4->ipython->igraph) (0.1.7)
Requirement already satisfied: six>=1.9.0 in /home/ningan/.local/lib/python2.7/site-packages (from prompt-toolkit<2.0.0,>=1.0.4->ipython->igraph) (1.13.0)
Requirement already satisfied: ptyprocess>=0.5 in /usr/local/lib/python2.7/dist-packages (from pexpect; sys_platform != "win32"->ipython->igraph) (0.6.0)
Requirement already satisfied: scandir; python_version < "3.5" in /home/ningan/.local/lib/python2.7/site-packages (from pathlib2; python_version == "2.7" or python_version == "3.3"->ipython->igraph) (1.10.0)
Requirement already satisfied: ipython-genutils in /usr/local/lib/python2.7/dist-packages (from traitlets>=4.2->ipython->igraph) (0.2.0)
Requirement already satisfied: enum34; python_version == "2.7" in /home/ningan/.local/lib/python2.7/site-packages (from traitlets>=4.2->ipython->igraph) (1.1.6)
Installing collected packages: igraph
ERROR: Could not install packages due to an EnvironmentError: [Errno 13] Permission denied: '/usr/local/lib/python2.7/dist-packages/igraph'
Consider using the `--user` option or check the permissions.

ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip install igraph
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in 
    from pip import main
ImportError: cannot import name main
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip2 install igraph
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/ningan/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting igraph
  Downloading https://files.pythonhosted.org/packages/91/15/7c606c483a401dfdcdd19f2688c83585ee3b5ef401bd4e0e647660ef5b3f/igraph-0.1.11-py2.py3-none-any.whl (119kB)
    100% |████████████████████████████████| 122kB 291kB/s 
Requirement already satisfied (use --upgrade to upgrade): ipython in /usr/local/lib/python2.7/dist-packages (from igraph)
Requirement already satisfied (use --upgrade to upgrade): prompt-toolkit<2.0.0,>=1.0.4 in /usr/local/lib/python2.7/dist-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): decorator in /usr/local/lib/python2.7/dist-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): pexpect; sys_platform != "win32" in /usr/local/lib/python2.7/dist-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): backports.shutil-get-terminal-size; python_version == "2.7" in /usr/local/lib/python2.7/dist-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): setuptools>=18.5 in /usr/lib/python2.7/dist-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): pygments in /home/ningan/.local/lib/python2.7/site-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): pathlib2; python_version == "2.7" or python_version == "3.3" in /home/ningan/.local/lib/python2.7/site-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): traitlets>=4.2 in /usr/local/lib/python2.7/dist-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): simplegeneric>0.8 in /usr/local/lib/python2.7/dist-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): pickleshare in /usr/local/lib/python2.7/dist-packages (from ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): wcwidth in /home/ningan/.local/lib/python2.7/site-packages (from prompt-toolkit<2.0.0,>=1.0.4->ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): six>=1.9.0 in /home/ningan/.local/lib/python2.7/site-packages (from prompt-toolkit<2.0.0,>=1.0.4->ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): ptyprocess>=0.5 in /usr/local/lib/python2.7/dist-packages (from pexpect; sys_platform != "win32"->ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): scandir; python_version < "3.5" in /home/ningan/.local/lib/python2.7/site-packages (from pathlib2; python_version == "2.7" or python_version == "3.3"->ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): ipython-genutils in /usr/local/lib/python2.7/dist-packages (from traitlets>=4.2->ipython->igraph)
Requirement already satisfied (use --upgrade to upgrade): enum34; python_version == "2.7" in /home/ningan/.local/lib/python2.7/site-packages (from traitlets>=4.2->ipython->igraph)
Installing collected packages: igraph
Successfully installed igraph-0.1.11
You are using pip version 8.1.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ pip install --upgrade
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
ERROR: You must give at least one requirement to install (see "pip help install")
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ pip install --upgrade pip
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Requirement already up-to-date: pip in /home/ningan/.local/lib/python2.7/site-packages (19.3.1)
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 
Traceback (most recent call last):
  File "get_cfg_relation.py", line 2, in 
    from access_db_operate import *
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 3, in 
    from igraph import *
  File "/usr/local/lib/python2.7/dist-packages/igraph/__init__.py", line 8, in 
    raise DeprecationWarning("To avoid name collision with the igraph project, "
DeprecationWarning: To avoid name collision with the igraph project, this visualization library has been renamed to 'jgraph'. Please upgrade when convenient.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 
Traceback (most recent call last):
  File "get_cfg_relation.py", line 2, in 
    from access_db_operate import *
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 3, in 
    from jgraph import *
ImportError: No module named jgraph
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ pip uninstall igraph
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Uninstalling igraph-0.1.11:
  Would remove:
    /usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/*
    /usr/local/lib/python2.7/dist-packages/igraph/*
Proceed (y/n)? y
ERROR: Exception:
Traceback (most recent call last):
  File "/home/ningan/.local/lib/python2.7/site-packages/pip/_internal/cli/base_command.py", line 153, in _main
    status = self.run(options, args)
  File "/home/ningan/.local/lib/python2.7/site-packages/pip/_internal/commands/uninstall.py", line 79, in run
    auto_confirm=options.yes, verbose=self.verbosity > 0,
  File "/home/ningan/.local/lib/python2.7/site-packages/pip/_internal/req/req_install.py", line 755, in uninstall
    uninstalled_pathset.remove(auto_confirm, verbose)
  File "/home/ningan/.local/lib/python2.7/site-packages/pip/_internal/req/req_uninstall.py", line 394, in remove
    moved.stash(path)
  File "/home/ningan/.local/lib/python2.7/site-packages/pip/_internal/req/req_uninstall.py", line 283, in stash
    renames(path, new_path)
  File "/home/ningan/.local/lib/python2.7/site-packages/pip/_internal/utils/misc.py", line 338, in renames
    shutil.move(old, new)
  File "/usr/lib/python2.7/shutil.py", line 300, in move
    rmtree(src)
  File "/usr/lib/python2.7/shutil.py", line 252, in rmtree
    onerror(os.remove, fullname, sys.exc_info())
  File "/usr/lib/python2.7/shutil.py", line 250, in rmtree
    os.remove(fullname)
OSError: [Errno 13] Permission denied: '/usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/WHEEL'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip uninstall igraph
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip2 uninstall igraph
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Uninstalling igraph-0.1.11:
  /usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/DESCRIPTION.rst
  /usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/INSTALLER
  /usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/METADATA
  /usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/RECORD
  /usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/WHEEL
  /usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/metadata.json
  /usr/local/lib/python2.7/dist-packages/igraph-0.1.11.dist-info/top_level.txt
  /usr/local/lib/python2.7/dist-packages/igraph/__init__.py
  /usr/local/lib/python2.7/dist-packages/igraph/__init__.pyc
  /usr/local/lib/python2.7/dist-packages/igraph/force_directed_layout.py
  /usr/local/lib/python2.7/dist-packages/igraph/force_directed_layout.pyc
  /usr/local/lib/python2.7/dist-packages/igraph/js/build/igraph.min.js
  /usr/local/lib/python2.7/dist-packages/igraph/json_formatter.py
  /usr/local/lib/python2.7/dist-packages/igraph/json_formatter.pyc
  /usr/local/lib/python2.7/dist-packages/igraph/notebook.py
  /usr/local/lib/python2.7/dist-packages/igraph/notebook.pyc
Proceed (y/n)? y
  Successfully uninstalled igraph-0.1.11
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
You are using pip version 8.1.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip2 install python_igraph
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/ningan/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting python_igraph
  Downloading https://files.pythonhosted.org/packages/0f/a0/4e7134f803737aa6eebb4e5250565ace0e2599659e22be7f7eba520ff017/python-igraph-0.7.1.post6.tar.gz (377kB)
    100% |████████████████████████████████| 378kB 2.2MB/s 
Installing collected packages: python-igraph
  Running setup.py install for python-igraph ... done
Successfully installed python-igraph-0.7.1.post6
You are using pip version 8.1.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 
Traceback (most recent call last):
  File "get_cfg_relation.py", line 2, in <module>
    from access_db_operate import *
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 3, in <module>
    from jgraph import *
ImportError: No module named jgraph
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip2 install jgraph
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/ningan/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting jgraph
  Downloading https://files.pythonhosted.org/packages/f0/31/b15d3d9407db73a2227fe19fc684b66859ed30f67606b397fa9dabd804b3/jgraph-0.2.1-py2.py3-none-any.whl (119kB)
    100% |████████████████████████████████| 122kB 264kB/s 
Requirement already satisfied (use --upgrade to upgrade): ipython in /usr/local/lib/python2.7/dist-packages (from jgraph)
Requirement already satisfied (use --upgrade to upgrade): prompt-toolkit<2.0.0,>=1.0.4 in /usr/local/lib/python2.7/dist-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): decorator in /usr/local/lib/python2.7/dist-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): pexpect; sys_platform != "win32" in /usr/local/lib/python2.7/dist-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): backports.shutil-get-terminal-size; python_version == "2.7" in /usr/local/lib/python2.7/dist-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): setuptools>=18.5 in /usr/lib/python2.7/dist-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): pygments in /home/ningan/.local/lib/python2.7/site-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): pathlib2; python_version == "2.7" or python_version == "3.3" in /home/ningan/.local/lib/python2.7/site-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): traitlets>=4.2 in /usr/local/lib/python2.7/dist-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): simplegeneric>0.8 in /usr/local/lib/python2.7/dist-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): pickleshare in /usr/local/lib/python2.7/dist-packages (from ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): wcwidth in /home/ningan/.local/lib/python2.7/site-packages (from prompt-toolkit<2.0.0,>=1.0.4->ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): six>=1.9.0 in /home/ningan/.local/lib/python2.7/site-packages (from prompt-toolkit<2.0.0,>=1.0.4->ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): ptyprocess>=0.5 in /usr/local/lib/python2.7/dist-packages (from pexpect; sys_platform != "win32"->ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): scandir; python_version < "3.5" in /home/ningan/.local/lib/python2.7/site-packages (from pathlib2; python_version == "2.7" or python_version == "3.3"->ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): ipython-genutils in /usr/local/lib/python2.7/dist-packages (from traitlets>=4.2->ipython->jgraph)
Requirement already satisfied (use --upgrade to upgrade): enum34; python_version == "2.7" in /home/ningan/.local/lib/python2.7/site-packages (from traitlets>=4.2->ipython->jgraph)
Installing collected packages: jgraph
Successfully installed jgraph-0.2.1
You are using pip version 8.1.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

Traceback (most recent call last):
  File "get_cfg_relation.py", line 320, in <module>
    main()
  File "get_cfg_relation.py", line 260, in main
    j.connectToDatabase()
  File "/usr/local/lib/python2.7/dist-packages/joern-0.1-py2.7.egg/joern/all.py", line 27, in connectToDatabase
    self.gremlin = Gremlin(self.graphDb)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/ext/gremlin/__init__.py", line 31, in __init__
    super(Gremlin, self).__init__(graph, "GremlinPlugin")
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 2638, in __init__
    extensions = self.graph.resource.metadata["extensions"]
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 198, in metadata
    self.get()
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 234, in get
    response = self.__base.get(headers=headers, redirect_limit=redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 959, in get
    return self.__get_or_head("GET", if_modified_since, headers, redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 936, in __get_or_head
    return rq.submit(redirect_limit=redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 433, in submit
    http, rs = submit(self.method, uri, self.body, self.headers)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 362, in submit
    raise SocketError(code, description, host_port=uri.host_port)
py2neo.packages.httpstream.http.SocketError: Connection refused
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

Traceback (most recent call last):
  File "get_cfg_relation.py", line 320, in <module>
    main()
  File "get_cfg_relation.py", line 260, in main
    j.connectToDatabase()
  File "/usr/local/lib/python2.7/dist-packages/joern-0.1-py2.7.egg/joern/all.py", line 27, in connectToDatabase
    self.gremlin = Gremlin(self.graphDb)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/ext/gremlin/__init__.py", line 31, in __init__
    super(Gremlin, self).__init__(graph, "GremlinPlugin")
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 2638, in __init__
    extensions = self.graph.resource.metadata["extensions"]
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 198, in metadata
    self.get()
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 234, in get
    response = self.__base.get(headers=headers, redirect_limit=redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 959, in get
    return self.__get_or_head("GET", if_modified_since, headers, redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 936, in __get_or_head
    return rq.submit(redirect_limit=redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 433, in submit
    http, rs = submit(self.method, uri, self.body, self.headers)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 362, in submit
    raise SocketError(code, description, host_port=uri.host_port)
py2neo.packages.httpstream.http.SocketError: Connection refused
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

Traceback (most recent call last):
  File "get_cfg_relation.py", line 320, in <module>
    main()
  File "get_cfg_relation.py", line 260, in main
    j.connectToDatabase()
  File "/usr/local/lib/python2.7/dist-packages/joern-0.1-py2.7.egg/joern/all.py", line 27, in connectToDatabase
    self.gremlin = Gremlin(self.graphDb)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/ext/gremlin/__init__.py", line 31, in __init__
    super(Gremlin, self).__init__(graph, "GremlinPlugin")
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 2638, in __init__
    extensions = self.graph.resource.metadata["extensions"]
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 198, in metadata
    self.get()
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 234, in get
    response = self.__base.get(headers=headers, redirect_limit=redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 959, in get
    return self.__get_or_head("GET", if_modified_since, headers, redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 936, in __get_or_head
    return rq.submit(redirect_limit=redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 433, in submit
    http, rs = submit(self.method, uri, self.body, self.headers)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 362, in submit
    raise SocketError(code, description, host_port=uri.host_port)
py2neo.packages.httpstream.http.SocketError: Connection refused
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

Traceback (most recent call last):
  File "get_cfg_relation.py", line 320, in <module>
    main()
  File "get_cfg_relation.py", line 260, in main
    j.connectToDatabase()
  File "/usr/local/lib/python2.7/dist-packages/joern-0.1-py2.7.egg/joern/all.py", line 27, in connectToDatabase
    self.gremlin = Gremlin(self.graphDb)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/ext/gremlin/__init__.py", line 31, in __init__
    super(Gremlin, self).__init__(graph, "GremlinPlugin")
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 2638, in __init__
    extensions = self.graph.resource.metadata["extensions"]
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 198, in metadata
    self.get()
  File "/usr/local/lib/python2.7/dist-packages/py2neo/core.py", line 234, in get
    response = self.__base.get(headers=headers, redirect_limit=redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 959, in get
    return self.__get_or_head("GET", if_modified_since, headers, redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 936, in __get_or_head
    return rq.submit(redirect_limit=redirect_limit, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 433, in submit
    http, rs = submit(self.method, uri, self.body, self.headers)
  File "/usr/local/lib/python2.7/dist-packages/py2neo/packages/httpstream/http.py", line 362, in submit
    raise SocketError(code, description, host_port=uri.host_port)
py2neo.packages.httpstream.http.SocketError: Connection refused
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
Traceback (most recent call last):
  File "get_cfg_relation.py", line 320, in <module>
    main()
  File "get_cfg_relation.py", line 269, in main
    initcfg = translateCFGByNode(j, node)#get init CFG
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 231, in translateCFGByNode
    g = drawGraph(db, Edges, func_node, graph_type)
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 173, in drawGraph
    g = Graph(directed=True)
NameError: global name 'Graph' is not defined
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip2 uninstall igraph
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Cannot uninstall requirement igraph, not installed
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
You are using pip version 8.1.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo apt-get update
Get:1 http://packages.microsoft.com/repos/vscode stable InRelease [3,959 B]
Get:2 http://packages.microsoft.com/repos/vscode stable/main amd64 Packages [158 kB]                                       
Get:3 http://security.ubuntu.com/ubuntu xenial-security InRelease [109 kB]                         
Hit:4 http://us.archive.ubuntu.com/ubuntu xenial InRelease                                                   
Hit:5 http://ppa.launchpad.net/openjdk-r/ppa/ubuntu xenial InRelease                                                       
Get:6 http://us.archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB]         
Get:7 http://us.archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB]
Get:8 http://security.ubuntu.com/ubuntu xenial-security/main amd64 DEP-11 Metadata [74.8 kB]
Get:9 http://security.ubuntu.com/ubuntu xenial-security/main DEP-11 64x64 Icons [83.8 kB]              
Get:10 http://us.archive.ubuntu.com/ubuntu xenial-updates/main amd64 DEP-11 Metadata [322 kB]
Get:11 http://security.ubuntu.com/ubuntu xenial-security/universe amd64 DEP-11 Metadata [124 kB]
Get:12 http://security.ubuntu.com/ubuntu xenial-security/universe DEP-11 64x64 Icons [185 kB]
Get:13 http://us.archive.ubuntu.com/ubuntu xenial-updates/main DEP-11 64x64 Icons [236 kB]               
Get:14 http://security.ubuntu.com/ubuntu xenial-security/multiverse amd64 DEP-11 Metadata [2,464 B] 
Get:15 http://us.archive.ubuntu.com/ubuntu xenial-updates/universe amd64 Packages [771 kB]                      
Ign:16 https://debian.neo4j.org/repo stable/ InRelease                
Get:17 https://debian.neo4j.org/repo stable/ Release [1,479 B]
Get:18 https://debian.neo4j.org/repo stable/ Release.gpg [819 B]
Get:19 http://us.archive.ubuntu.com/ubuntu xenial-updates/universe i386 Packages [700 kB]
Get:20 http://us.archive.ubuntu.com/ubuntu xenial-updates/universe amd64 DEP-11 Metadata [274 kB]
Get:21 http://us.archive.ubuntu.com/ubuntu xenial-updates/universe DEP-11 64x64 Icons [406 kB]
Get:22 http://us.archive.ubuntu.com/ubuntu xenial-updates/multiverse amd64 DEP-11 Metadata [5,976 B]
Get:23 http://us.archive.ubuntu.com/ubuntu xenial-updates/multiverse DEP-11 64x64 Icons [14.3 kB]
Get:24 http://us.archive.ubuntu.com/ubuntu xenial-backports/main amd64 DEP-11 Metadata [3,328 B]
Get:25 http://us.archive.ubuntu.com/ubuntu xenial-backports/universe amd64 DEP-11 Metadata [5,324 B]
Fetched 3,696 kB in 4s (805 kB/s)                               
Reading package lists... Done
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo apt-get install python-igraph
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  linux-headers-4.15.0-45 linux-headers-4.15.0-45-generic linux-image-4.15.0-45-generic linux-modules-4.15.0-45-generic
  linux-modules-extra-4.15.0-45-generic
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  libamd2.4.1 libarpack2 libblas-common libblas3 libgfortran3 libglpk36 libigraph0v5 liblapack3
Suggested packages:
  libiodbc2-dev libmysqlclient-dev
The following NEW packages will be installed:
  libamd2.4.1 libarpack2 libblas-common libblas3 libgfortran3 libglpk36 libigraph0v5 liblapack3 python-igraph
0 upgraded, 9 newly installed, 0 to remove and 98 not upgraded.
Need to get 3,951 kB of archives.
After this operation, 13.5 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 libamd2.4.1 amd64 1:4.4.6-1 [21.3 kB]
Get:2 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 libblas-common amd64 3.6.0-2ubuntu2 [5,342 B]
Get:3 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 libblas3 amd64 3.6.0-2ubuntu2 [147 kB]
Get:4 http://us.archive.ubuntu.com/ubuntu xenial-updates/main amd64 libgfortran3 amd64 5.4.0-6ubuntu1~16.04.12 [260 kB]
Get:5 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 liblapack3 amd64 3.6.0-2ubuntu2 [1,938 kB]
Get:6 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 libarpack2 amd64 3.3.0-1build2 [88.2 kB]
Get:7 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 libglpk36 amd64 4.57-1build3 [386 kB]
Get:8 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 libigraph0v5 amd64 0.7.1-2.1 [810 kB]
Get:9 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 python-igraph amd64 0.7.1post6-0ubuntu2 [296 kB]
Fetched 3,951 kB in 4s (867 kB/s)  
Selecting previously unselected package libamd2.4.1:amd64.
(Reading database ... 259570 files and directories currently installed.)
Preparing to unpack .../libamd2.4.1_1%3a4.4.6-1_amd64.deb ...
Unpacking libamd2.4.1:amd64 (1:4.4.6-1) ...
Selecting previously unselected package libblas-common.
Preparing to unpack .../libblas-common_3.6.0-2ubuntu2_amd64.deb ...
Unpacking libblas-common (3.6.0-2ubuntu2) ...
Selecting previously unselected package libblas3.
Preparing to unpack .../libblas3_3.6.0-2ubuntu2_amd64.deb ...
Unpacking libblas3 (3.6.0-2ubuntu2) ...
Selecting previously unselected package libgfortran3:amd64.
Preparing to unpack .../libgfortran3_5.4.0-6ubuntu1~16.04.12_amd64.deb ...
Unpacking libgfortran3:amd64 (5.4.0-6ubuntu1~16.04.12) ...
Selecting previously unselected package liblapack3.
Preparing to unpack .../liblapack3_3.6.0-2ubuntu2_amd64.deb ...
Unpacking liblapack3 (3.6.0-2ubuntu2) ...
Selecting previously unselected package libarpack2.
Preparing to unpack .../libarpack2_3.3.0-1build2_amd64.deb ...
Unpacking libarpack2 (3.3.0-1build2) ...
Selecting previously unselected package libglpk36:amd64.
Preparing to unpack .../libglpk36_4.57-1build3_amd64.deb ...
Unpacking libglpk36:amd64 (4.57-1build3) ...
Selecting previously unselected package libigraph0v5.
Preparing to unpack .../libigraph0v5_0.7.1-2.1_amd64.deb ...
Unpacking libigraph0v5 (0.7.1-2.1) ...
Selecting previously unselected package python-igraph.
Preparing to unpack .../python-igraph_0.7.1post6-0ubuntu2_amd64.deb ...
Unpacking python-igraph (0.7.1post6-0ubuntu2) ...
Processing triggers for libc-bin (2.23-0ubuntu11) ...
Setting up libamd2.4.1:amd64 (1:4.4.6-1) ...
Setting up libblas-common (3.6.0-2ubuntu2) ...
Setting up libblas3 (3.6.0-2ubuntu2) ...
update-alternatives: using /usr/lib/libblas/libblas.so.3 to provide /usr/lib/libblas.so.3 (libblas.so.3) in auto mode
Setting up libgfortran3:amd64 (5.4.0-6ubuntu1~16.04.12) ...
Setting up liblapack3 (3.6.0-2ubuntu2) ...
update-alternatives: using /usr/lib/lapack/liblapack.so.3 to provide /usr/lib/liblapack.so.3 (liblapack.so.3) in auto mode
Setting up libarpack2 (3.3.0-1build2) ...
Setting up libglpk36:amd64 (4.57-1build3) ...
Setting up libigraph0v5 (0.7.1-2.1) ...
Setting up python-igraph (0.7.1post6-0ubuntu2) ...
Processing triggers for libc-bin (2.23-0ubuntu11) ...
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
Traceback (most recent call last):
  File "get_cfg_relation.py", line 320, in <module>
    main()
  File "get_cfg_relation.py", line 269, in main
    initcfg = translateCFGByNode(j, node)#get init CFG
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 231, in translateCFGByNode
    g = drawGraph(db, Edges, func_node, graph_type)
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 173, in drawGraph
    g = Graph(directed=True)
NameError: global name 'Graph' is not defined
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
Traceback (most recent call last):
  File "get_cfg_relation.py", line 320, in <module>
    main()
  File "get_cfg_relation.py", line 269, in main
    initcfg = translateCFGByNode(j, node)#get init CFG
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 232, in translateCFGByNode
    g = drawGraph(db, Edges, func_node, graph_type)
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 174, in drawGraph
    g = jgraph.Graph(directed=True)
AttributeError: 'module' object has no attribute 'Graph'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 
Traceback (most recent call last):
  File "get_cfg_relation.py", line 2, in <module>
    from access_db_operate import *
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 3, in <module>
    from python_igraph import *
ImportError: No module named python_igraph
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 
Traceback (most recent call last):
  File "get_cfg_relation.py", line 2, in <module>
    from access_db_operate import *
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 3
    from python-igraph import *
               ^
SyntaxError: invalid syntax
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ sudo pip2 install python-igraph
The directory '/home/ningan/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/ningan/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Requirement already satisfied (use --upgrade to upgrade): python-igraph in /usr/local/lib/python2.7/dist-packages
You are using pip version 8.1.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 
Traceback (most recent call last):
  File "get_cfg_relation.py", line 2, in <module>
    from access_db_operate import *
  File "/home/ningan/JOERN/SySeVR-master/Implementation/source2slice/access_db_operate.py", line 3
    from python-igraph import *
               ^
SyntaxError: invalid syntax
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
Traceback (most recent call last):
  File "get_cfg_relation.py", line 320, in <module>
    main()
  File "get_cfg_relation.py", line 288, in main
    os.mkdir(path)
OSError: [Errno 2] No such file or directory: 'cfg_db/anan_testcode'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ mkdir cfg_db
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python get_cfg_relation.py 

[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
CVE_2004_1151_PATCHED_sys32_ni_syscall
{}
{}

[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c']
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c']
CVE_2004_1151_VULN_sys32_ni_syscall
{}
{}

ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python complete_PDG.py
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
cfg_db/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall_2
43
32
10
43
32
10
Traceback (most recent call last):
  File "complete_PDG.py", line 517, in <module>
    main()             
  File "complete_PDG.py", line 509, in main
    os.mkdir(path)
OSError: [Errno 2] No such file or directory: 'pdg_db/anan_testcode'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ mkdir pdg_db
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python complete_PDG.py
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
cfg_db/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall_2
43
32
10
43
32
10
pdg_db/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall_2 pdg_db/anan_testcode
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c']
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c']
cfg_db/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall_86
123
112
94
123
112
94
pdg_db/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall_86 pdg_db/anan_testcode
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python access_db_operate.py
['anan_testcode']
list_all_funcID [2, 86]
lenth 2
Traceback (most recent call last):
  File "access_db_operate.py", line 694, in <module>
    os.mkdir(os.path.join("dict_call2cfgNodeID_funcID", str(testID)))
OSError: [Errno 2] No such file or directory: 'dict_call2cfgNodeID_funcID/anan_testcode'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ mkdir dict_call2cfgNodeID_funcID
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python access_db_operate.py
['anan_testcode']
list_all_funcID [2, 86]
lenth 2
{}
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python points_get.py
Traceback (most recent call last):
  File "points_get.py", line 240, in <module>
    _dict = get_all_sensitiveAPI(j)
  File "points_get.py", line 9, in get_all_sensitiveAPI
    fin = open("sensitive_func.pkl", 'rb')
IOError: [Errno 2] No such file or directory: 'sensitive_func.pkl'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python points_get.py
Traceback (most recent call last):
  File "points_get.py", line 241, in <module>
    _dict = get_all_sensitiveAPI(j)
  File "points_get.py", line 10, in get_all_sensitiveAPI
    fin = open("dict.pkl", 'rb')
IOError: [Errno 2] No such file or directory: 'dict.pkl'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python points_get.py
{}
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
7
(n16 {childNum:"12",code:"strncpy ( lastcomm , me -> comm , sizeof ( lastcomm ) )",functionId:2,isCFGNode:"True",location:"9:1:274:319",type:"ExpressionStatement"})
(n43 {childNum:"0",code:"strncmp ( lastcomm , me -> comm , sizeof ( lastcomm ) )",functionId:2,isCFGNode:"True",location:"6:5:140:184",type:"Condition"})
(n58 {childNum:"2",code:"char lastcomm [ sizeof ( me -> comm ) ] ;",functionId:2,isCFGNode:"True",location:"4:8:99:130",type:"IdentifierDeclStatement"})
[9, 6, 4]
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c']
5
(n100 {childNum:"12",code:"strcpy ( lastcomm , me -> comm )",functionId:86,isCFGNode:"True",location:"8:2:244:270",type:"ExpressionStatement"})
(n123 {childNum:"0",code:"strcmp ( lastcomm , me -> comm )",functionId:86,isCFGNode:"True",location:"5:5:119:144",type:"Condition"})
[8, 5]
{u'anan_testcode': [(['16'], '2', u'me'), (['100'], '86', u'me')]}
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c']
[u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c']
{u'anan_testcode': [(['27'], '2', u'lastcomm'), (['16'], '2', u'lastcomm'), (['54'], '2', u'lastcomm'), (['43'], '2', u'lastcomm'), (['59'], '2', u'lastcomm'), (['107'], '86', u'lastcomm'), (['100'], '86', u'lastcomm'), (['130'], '86', u'lastcomm'), (['123'], '86', u'lastcomm'), (['135'], '86', u'lastcomm')]}
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python extract_df.py
{u'anan_testcode': [(['16'], '2', u'me'), (['100'], '86', u'me')]}
anan_testcode
anan_testcode 2
start extract backwords dataflow!
('list_all_node:', [igraph.Vertex(<igraph.Graph object at 0x7fe8c9f96a00>,1,{'code': u'strncpy ( lastcomm , me -> comm , sizeof ( lastcomm ) )', 'name': '16', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'9:1:274:319', 'type': u'ExpressionStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fe8c9f96a00>,0,{'code': u'static char lastcomm [ sizeof ( me -> comm ) ] ;', 'name': '58', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'4:8:99:130', 'type': u'IdentifierDeclStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fe8c9f96a00>,3,{'code': u'struct task_struct * me = current ;', 'name': '68', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'3:1:57:89', 'type': u'IdentifierDeclStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fe8c9f96a00>,5,{'code': u'CVE_2004_1151_PATCHED_sys32_ni_syscall', 'name': '2', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'1:0:0:351', 'type': u'Function', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fe8c9f96a00>,2,{'code': u'strncmp ( lastcomm , me -> comm , sizeof ( lastcomm ) )', 'name': '43', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'6:5:140:184', 'type': u'Condition', 'functionId': '2'})])
Traceback (most recent call last):
  File "extract_df.py", line 453, in <module>
    pointers_slice()
  File "extract_df.py", line 374, in pointers_slice
    get_slice_file_sequence(store_filepath, _list, count, pointers_name, startline, startline_path)
  File "extract_df.py", line 209, in get_slice_file_sequence
    f = open(store_filepath, 'a')
IOError: [Errno 2] No such file or directory: 'slice/pointersuse_slices.txt'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ mkdir slice
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python extract_df.py
{u'anan_testcode': [(['16'], '2', u'me'), (['100'], '86', u'me')]}
anan_testcode
anan_testcode 2
start extract backwords dataflow!
('list_all_node:', [igraph.Vertex(<igraph.Graph object at 0x7fb89f247a00>,1,{'code': u'strncpy ( lastcomm , me -> comm , sizeof ( lastcomm ) )', 'name': '16', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'9:1:274:319', 'type': u'ExpressionStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247a00>,0,{'code': u'static char lastcomm [ sizeof ( me -> comm ) ] ;', 'name': '58', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'4:8:99:130', 'type': u'IdentifierDeclStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247a00>,3,{'code': u'struct task_struct * me = current ;', 'name': '68', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'3:1:57:89', 'type': u'IdentifierDeclStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247a00>,5,{'code': u'CVE_2004_1151_PATCHED_sys32_ni_syscall', 'name': '2', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'1:0:0:351', 'type': u'Function', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247a00>,2,{'code': u'strncmp ( lastcomm , me -> comm , sizeof ( lastcomm ) )', 'name': '43', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'6:5:140:184', 'type': u'Condition', 'functionId': '2'})])
anan_testcode 86
start extract backwords dataflow!
('list_all_node:', [igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,1,{'code': u'strcpy ( lastcomm , me -> comm )', 'name': '100', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'8:2:244:270', 'type': u'ExpressionStatement', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,0,{'code': u'static char lastcomm [ 8 ] ;', 'name': '134', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'4:8:96:112', 'type': u'IdentifierDeclStatement', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,5,{'code': u'CVE_2004_1151_VULN_sys32_ni_syscall', 'name': '86', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'1:0:0:302', 'type': u'Function', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,2,{'code': u'strcmp ( lastcomm , me -> comm )', 'name': '123', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'5:5:119:144', 'type': u'Condition', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,3,{'code': u'struct task_struct * me = current ;', 'name': '140', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'3:1:54:86', 'type': u'IdentifierDeclStatement', 'functionId': '86'})])
2
2
start extract backwords dataflow!
('list_all_node:', [igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,1,{'code': u'strncpy ( lastcomm , me -> comm , sizeof ( lastcomm ) )', 'name': '16', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'9:1:274:319', 'type': u'ExpressionStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,0,{'code': u'static char lastcomm [ sizeof ( me -> comm ) ] ;', 'name': '58', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'4:8:99:130', 'type': u'IdentifierDeclStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,3,{'code': u'struct task_struct * me = current ;', 'name': '68', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'3:1:57:89', 'type': u'IdentifierDeclStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,5,{'code': u'CVE_2004_1151_PATCHED_sys32_ni_syscall', 'name': '2', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'1:0:0:351', 'type': u'Function', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,2,{'code': u'strncmp ( lastcomm , me -> comm , sizeof ( lastcomm ) )', 'name': '43', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'6:5:140:184', 'type': u'Condition', 'functionId': '2'})])
2
2
start extract backwords dataflow!
('list_all_node:', [igraph.Vertex(<igraph.Graph object at 0x7fb89f247bf0>,2,{'code': u'strncmp ( lastcomm , me -> comm , sizeof ( lastcomm ) )', 'name': '43', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'6:5:140:184', 'type': u'Condition', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247bf0>,0,{'code': u'static char lastcomm [ sizeof ( me -> comm ) ] ;', 'name': '58', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'4:8:99:130', 'type': u'IdentifierDeclStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247bf0>,3,{'code': u'struct task_struct * me = current ;', 'name': '68', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'3:1:57:89', 'type': u'IdentifierDeclStatement', 'functionId': '2'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247bf0>,5,{'code': u'CVE_2004_1151_PATCHED_sys32_ni_syscall', 'name': '2', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c', 'location': u'1:0:0:351', 'type': u'Function', 'functionId': '2'})])
2
86
86
start extract backwords dataflow!
('list_all_node:', [igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,1,{'code': u'strcpy ( lastcomm , me -> comm )', 'name': '100', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'8:2:244:270', 'type': u'ExpressionStatement', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,0,{'code': u'static char lastcomm [ 8 ] ;', 'name': '134', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'4:8:96:112', 'type': u'IdentifierDeclStatement', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,5,{'code': u'CVE_2004_1151_VULN_sys32_ni_syscall', 'name': '86', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'1:0:0:302', 'type': u'Function', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,2,{'code': u'strcmp ( lastcomm , me -> comm )', 'name': '123', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'5:5:119:144', 'type': u'Condition', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247908>,3,{'code': u'struct task_struct * me = current ;', 'name': '140', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'3:1:54:86', 'type': u'IdentifierDeclStatement', 'functionId': '86'})])
86
86
start extract backwords dataflow!
('list_all_node:', [igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,2,{'code': u'strcmp ( lastcomm , me -> comm )', 'name': '123', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'5:5:119:144', 'type': u'Condition', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,0,{'code': u'static char lastcomm [ 8 ] ;', 'name': '134', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'4:8:96:112', 'type': u'IdentifierDeclStatement', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,5,{'code': u'CVE_2004_1151_VULN_sys32_ni_syscall', 'name': '86', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'1:0:0:302', 'type': u'Function', 'functionId': '86'}), igraph.Vertex(<igraph.Graph object at 0x7fb89f247af8>,3,{'code': u'struct task_struct * me = current ;', 'name': '140', 'filepath': u'/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c', 'location': u'3:1:54:86', 'type': u'IdentifierDeclStatement', 'functionId': '86'})])
86
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ python make_label.py
Traceback (most recent call last):
  File "make_label.py", line 6, in <module>
    f = open("dict_cwe2father.pkl", 'rb')
IOError: [Errno 2] No such file or directory: 'dict_cwe2father.pkl'
ningan@ubuntu:~/JOERN/SySeVR-master/Implementation/source2slice$ 

第一次由于没有pkl文件,卡住了


ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo rm -rf .joernIndex

ningan@ubuntu:~/JOERN/joern-0.3.1$ mkdir anan_testcode
ningan@ubuntu:~/JOERN/joern-0.3.1$ ls
0.3.1.tar.gz    AUTHORS    docs           joern           joern-stop-db  LICENSE             rebuildTestDB.sh  testCode
0.3.1.tar.gz.1  bin        formatter.xml  joern.conf      lib            python-joern-0.3.1  RELEASE_NOTES     testreport
anan_testcode   build.xml  genParsers.sh  joern-start-db  lib.tar.gz     README.md           src
ningan@ubuntu:~/JOERN/joern-0.3.1$ cd anan_testcode/
ningan@ubuntu:~/JOERN/joern-0.3.1/anan_testcode$ ls   
CVE_2004_1151_PATCHED_sys32_ni_syscall.c  CVE_2004_1151_VULN_sys32_ni_syscall.c

ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo java -jar /home/ningan/JOERN/joern-0.3.1/bin/joern.jar /home/ningan/JOERN/joern-0.3.1/anan_testcode/
Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.UnsupportedClassVersionError: tools/index/IndexMain has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
	at java.lang.ClassLoader.defineClass1(Native Method)
	at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
	at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
	at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:352)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
	at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:495)
	
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ java -version
openjdk version "1.8.0_232"
OpenJDK Runtime Environment (build 1.8.0_232-8u232-b09-0ubuntu1~16.04.1-b09)
OpenJDK 64-Bit Server VM (build 25.232-b09, mixed mode)
ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo update-alternatives --config java
There are 2 choices for the alternative java (providing /usr/bin/java).

  Selection    Path                                            Priority   Status
------------------------------------------------------------
  0            /usr/lib/jvm/java-11-openjdk-amd64/bin/java      1111      auto mode
  1            /usr/lib/jvm/java-11-openjdk-amd64/bin/java      1111      manual mode
* 2            /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java   1081      manual mode

Press <enter> to keep the current choice[*], or type selection number: 2
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ java -version
openjdk version "1.8.0_232"
OpenJDK Runtime Environment (build 1.8.0_232-8u232-b09-0ubuntu1~16.04.1-b09)
OpenJDK 64-Bit Server VM (build 25.232-b09, mixed mode)
ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo update-alternatives --config javac
There are 2 choices for the alternative javac (providing /usr/bin/javac).

  Selection    Path                                          Priority   Status
------------------------------------------------------------
  0            /usr/lib/jvm/java-11-openjdk-amd64/bin/javac   1111      auto mode
  1            /usr/lib/jvm/java-11-openjdk-amd64/bin/javac   1111      manual mode
* 2            /usr/lib/jvm/java-8-openjdk-amd64/bin/javac    1081      manual mode

Press <enter> to keep the current choice[*], or type selection number: 2
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo java -jar /home/ningan/JOERN/joern-0.3.1/bin/joern.jar /home/ningan/JOERN/joern-0.3.1/anan_testcode/
Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.UnsupportedClassVersionError: tools/index/IndexMain has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
	at java.lang.ClassLoader.defineClass1(Native Method)
	at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
	at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
	at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:352)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
	at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:495)
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ javac -version
javac 1.8.0_232
ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo java -jar /home/ningan/JOERN/joern-0.3.1/bin/joern.jar /home/ningan/JOERN/joern-0.3.1/testCode/
Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.UnsupportedClassVersionError: tools/index/IndexMain has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
	at java.lang.ClassLoader.defineClass1(Native Method)
	at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
	at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
	at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:352)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
	at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:495)
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ vim ~/.bashrc
ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo vim ~/.bashrc
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ ls
0.3.1.tar.gz    AUTHORS    docs           joern           joern-stop-db  LICENSE             rebuildTestDB.sh  testCode
0.3.1.tar.gz.1  bin        formatter.xml  joern.conf      lib            python-joern-0.3.1  RELEASE_NOTES     testreport
anan_testcode   build.xml  genParsers.sh  joern-start-db  lib.tar.gz     README.md           src
ningan@ubuntu:~/JOERN/joern-0.3.1$ cd joern-tools
bash: cd: joern-tools: No such file or directory
ningan@ubuntu:~/JOERN/joern-0.3.1$ ll
total 4868
drwxrwxr-x 10 ningan ningan    4096 Dec 19 00:34 ./
drwxrwxr-x  6 ningan ningan    4096 Dec 19 00:14 ../
-rw-r--r--  1 ningan ningan   44385 Dec 17 22:42 0.3.1.tar.gz
-rw-rw-r--  1 ningan ningan   44385 Dec 18 18:49 0.3.1.tar.gz.1
drwxrwxr-x  2 ningan ningan    4096 Dec 19 00:35 anan_testcode/
-rw-rw-r--  1 ningan ningan     122 Nov 21  2014 AUTHORS
drwxrwxr-x 17 ningan ningan    4096 Dec 18 18:40 bin/
-rw-rw-r--  1 ningan ningan    2870 Dec 18 18:31 build.xml
-rw-rw-r--  1 ningan ningan     867 Nov 21  2014 .classpath
drwxrwxr-x  3 ningan ningan    4096 Nov 21  2014 docs/
-rw-rw-r--  1 ningan ningan   30822 Nov 21  2014 formatter.xml
-rwxrwxr-x  1 ningan ningan     132 Nov 21  2014 genParsers.sh*
-rwxrwxr-x  1 ningan ningan     106 Nov 21  2014 joern*
-rw-rw-r--  1 ningan ningan      78 Nov 21  2014 joern.conf
-rwxrwxr-x  1 ningan ningan    1462 Nov 21  2014 joern-start-db*
-rwxrwxr-x  1 ningan ningan     319 Nov 21  2014 joern-stop-db*
drwxr-xr-x  2 ningan ningan    4096 Nov 20  2014 lib/
-rwxrwxrwx  1 ningan ningan 4732789 Jul 19  2017 lib.tar.gz*
-rw-rw-r--  1 ningan ningan   35065 Nov 21  2014 LICENSE
-rw-rw-r--  1 ningan ningan     364 Nov 21  2014 .project
drwxrwxr-x  9 ningan ningan    4096 Dec 18 19:02 python-joern-0.3.1/
-rw-rw-r--  1 ningan ningan     528 Nov 21  2014 README.md
-rwxrwxr-x  1 ningan ningan     314 Nov 21  2014 rebuildTestDB.sh*
-rw-rw-r--  1 ningan ningan    1123 Nov 21  2014 RELEASE_NOTES
drwxrwxr-x 17 ningan ningan    4096 Nov 21  2014 src/
drwxrwxr-x  2 ningan ningan    4096 Dec 18 23:37 testCode/
drwxrwxr-x  2 ningan ningan    4096 Dec 18 18:40 testreport/
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ cd python-joern-0.3.1/
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1$ ls
build  dist  docs  joern  joern.egg-info  joern-tools  LICENSE  README.md  setup.py  testing
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1$ cd joern-tools/
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1/joern-tools$ ls
AUTHORS  build  dist  examples  joerntools  joerntools.egg-info  LICENSE  README.md  setup.py  tools
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1/joern-tools$ 
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1/joern-tools$ joern-lookup
usage: joern-lookup [-h] [-f [FILE]] [-o [OUT]] [-c] [-g]
                    [-a ATTRIBUTES [ATTRIBUTES ...]]

Lookup nodes using lucene queries and output one row for each matching node.
Rows are in the format functionId TAB attributeKey:attributeValue TAB.

optional arguments:
  -h, --help            show this help message and exit
  -f [FILE], --file [FILE]
                        read input from the provided file
  -o [OUT], --out [OUT]
                        write output to provided file
  -c, --complete        Output the complete node, not just its ID.
  -g, --gremlin         query is a gremlin traversal as opposed to a lucene
                        query
  -a ATTRIBUTES [ATTRIBUTES ...], --attributes ATTRIBUTES [ATTRIBUTES ...]
                        Attributes of interest
                        
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1/joern-tools$ 
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1/joern-tools$ 
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1/joern-tools$ 
ningan@ubuntu:~/JOERN/joern-0.3.1/python-joern-0.3.1/joern-tools$ cd ../..
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ ls
0.3.1.tar.gz    AUTHORS    docs           joern           joern-stop-db  LICENSE             rebuildTestDB.sh  testCode
0.3.1.tar.gz.1  bin        formatter.xml  joern.conf      lib            python-joern-0.3.1  RELEASE_NOTES     testreport
anan_testcode   build.xml  genParsers.sh  joern-start-db  lib.tar.gz     README.md           src
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ locate ClassLoader.java
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ ant
Buildfile: /home/ningan/JOERN/joern-0.3.1/build.xml

clean:
   [delete] Deleting directory /home/ningan/JOERN/joern-0.3.1/bin
   [delete] Deleting directory /home/ningan/JOERN/joern-0.3.1/testreport

makedir:
    [mkdir] Created dir: /home/ningan/JOERN/joern-0.3.1/bin
    [mkdir] Created dir: /home/ningan/JOERN/joern-0.3.1/testreport

compile:
    [javac] Compiling 264 source files to /home/ningan/JOERN/joern-0.3.1/bin
    [javac] warning: Supported source version 'RELEASE_6' from annotation processor 'org.antlr.v4.runtime.misc.RuleDependencyProcessor' less than -source '1.8'
    [javac] warning: Supported source version 'RELEASE_6' from annotation processor 'org.antlr.v4.runtime.misc.NullUsageProcessor' less than -source '1.8'
    [javac] warning: Supported source version 'RELEASE_7' from annotation processor 'org.neo4j.kernel.impl.annotations.ServiceProcessor' less than -source '1.8'
    [javac] warning: Supported source version 'RELEASE_7' from annotation processor 'org.neo4j.kernel.impl.annotations.DocumentationProcessor' less than -source '1.8'
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.
    [javac] 4 warnings

jar:
      [jar] Building jar: /home/ningan/JOERN/joern-0.3.1/bin/joern.jar

BUILD SUCCESSFUL
Total time: 8 seconds
ningan@ubuntu:~/JOERN/joern-0.3.1$ sudo java -jar /home/ningan/JOERN/joern-0.3.1/bin/joern.jar /home/ningan/JOERN/joern-0.3.1/anan_testcode/
[sudo] password for ningan: 
Warning: your JVM has a maximum heap size of less than 2 Gig. You may need to import large code bases in batches.
If you have additional memory, you may want to allow your JVM to access it by using the -Xmx flag.
/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_PATCHED_sys32_ni_syscall.c
/home/ningan/JOERN/joern-0.3.1/anan_testcode/CVE_2004_1151_VULN_sys32_ni_syscall.c
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ ]

]: command not found
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ 
ningan@ubuntu:~/JOERN/joern-0.3.1$ ll
total 4872
drwxrwxr-x 11 ningan ningan    4096 Dec 19 01:41 ./
drwxrwxr-x  6 ningan ningan    4096 Dec 19 00:14 ../
-rw-r--r--  1 ningan ningan   44385 Dec 17 22:42 0.3.1.tar.gz
-rw-rw-r--  1 ningan ningan   44385 Dec 18 18:49 0.3.1.tar.gz.1
drwxrwxr-x  2 ningan ningan    4096 Dec 19 00:35 anan_testcode/
-rw-rw-r--  1 ningan ningan     122 Nov 21  2014 AUTHORS
drwxrwxr-x 17 ningan ningan    4096 Dec 19 01:40 bin/
-rw-rw-r--  1 ningan ningan    2870 Dec 18 18:31 build.xml
-rw-rw-r--  1 ningan ningan     867 Nov 21  2014 .classpath
drwxrwxr-x  3 ningan ningan    4096 Nov 21  2014 docs/
-rw-rw-r--  1 ningan ningan   30822 Nov 21  2014 formatter.xml
-rwxrwxr-x  1 ningan ningan     132 Nov 21  2014 genParsers.sh*
-rwxrwxr-x  1 ningan ningan     106 Nov 21  2014 joern*
-rw-rw-r--  1 ningan ningan      78 Nov 21  2014 joern.conf
drwxr-xr-x  4 root   root      4096 Dec 19 01:41 .joernIndex/
-rwxrwxr-x  1 ningan ningan    1462 Nov 21  2014 joern-start-db*
-rwxrwxr-x  1 ningan ningan     319 Nov 21  2014 joern-stop-db*
drwxr-xr-x  2 ningan ningan    4096 Nov 20  2014 lib/
-rwxrwxrwx  1 ningan ningan 4732789 Jul 19  2017 lib.tar.gz*
-rw-rw-r--  1 ningan ningan   35065 Nov 21  2014 LICENSE
-rw-rw-r--  1 ningan ningan     364 Nov 21  2014 .project
drwxrwxr-x  9 ningan ningan    4096 Dec 18 19:02 python-joern-0.3.1/
-rw-rw-r--  1 ningan ningan     528 Nov 21  2014 README.md
-rwxrwxr-x  1 ningan ningan     314 Nov 21  2014 rebuildTestDB.sh*
-rw-rw-r--  1 ningan ningan    1123 Nov 21  2014 RELEASE_NOTES
drwxrwxr-x 17 ningan ningan    4096 Nov 21  2014 src/
drwxrwxr-x  2 ningan ningan    4096 Dec 18 23:37 testCode/
drwxrwxr-x  2 ningan ningan    4096 Dec 19 01:40 testreport/
ningan@ubuntu:~/JOERN/joern-0.3.1$ 

For reference, let’s take a quick look at the Java version numbers. This will come in handy in case we need to download the appropriate Java version.

The major and minor version numbers are stored in the class bytecode at bytes six and seven.

Let’s see how the major version numbers map to Java versions:

45 = Java 1.1
46 = Java 1.2
47 = Java 1.3
48 = Java 1.4
49 = Java 5
50 = Java 6
51 = Java 7
52 = Java 8
53 = Java 9
54 = Java 10
55 = Java 11
56 = Java 12
57 = Java 13

你可能感兴趣的:(python,安全,Linux)