1 / 17

Yasca

Yasca. Introduction. Mã nguồn mở. Là phần mềm tích hợp “plus a little more”. Bao gồm basic front-end(CMD-Win GUI), a set of scanning plugins and report renderers, and an engine to tie them all together. Hoạt động dựa trên bộ Plugins. Plugins.

norah
Download Presentation

Yasca

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Yasca

  2. Introduction • Mã nguồn mở. • Là phần mềm tích hợp “plus a little more”. • Bao gồm basic front-end(CMD-Win GUI), a set of scanning plugins and report renderers, and an engine to tie them all together. • Hoạt động dựa trên bộ Plugins.

  3. Plugins • Mỗi Plugins là một phần mềm mã nguồn mở được tích hợp vào Yasca. • Jlint, antiC, PMD, FindBugs…. • Nằm trong thư mục Plugins của Yasca.

  4. Plugins • PMD Plugin: Uses PMD to parse and scan Java (and JSP) source code for issues. • JLint Plugin: Uses J-Lint to scan Java .class files for issues. • antiC Plugin: Uses antiC to scan Java and C/C++ source code for issues. • FindBugs Plugin: Uses FIndBugs to scan Java class and Jar files for issues. • Grep Plugin: Uses external GREP files to scan target files for simple patterns. • …

  5. Run Plugins • Only Run One Plugin: yasca –p plugins/PluginName.php <target directory> • Run All Plugin: yasca <target directory> • Run All Plugin (Not one or more): yasca –px <Plugins> <target directory>

  6. Run Plugins • Sau khi Scan, một bản Report dạng HTML được in ra ngoài Desktop. • Có thể đổi đường dẫn của Report: yasca -o z:\Yasca_Output c:\work\myproject

  7. PMD Plugin • Biên dịch một phần mã nguồn tập tin Java và JSP. • Scan the resulting abstract syntax tree for certain patterns. • Chỉ hoạt động trên mã nguồn Java and JSP.

  8. JLint Plugin • Sử dụng phần mềm open-source JLint v3.0. • Quét các tập tin .class đã được biên dịch. • Search: • Bug. • Inconsistencies. • Synchronization problems.

  9. antiC Plugin • Sử dụng phần mềm open-source antiC v1.11.1. • Quét các tập tin Java and C/C++ source code. • Search: • Bug. • Inconsistencies. • Synchronization problems.

  10. Minor Plugins • Được sử dụng khi một mô hình đã quá phức tạp. • Nằm trong thư mục plugins/default.

  11. Minor Plugins(tt) • Weak Authentication: Được phát hiện khi những dòng gần nhau tự định nghĩa username và pass giống nhau: database.conn.username = tango44opine database.conn.password = tango44opine

  12. Minor Plugins(tt) • Redundant Null Check: Được phát hiện khi một đối tượng được kiểm tra null trực tiếp sau khi nó đã được sử dụng trước đó: foo.bar(); if (foo != null) { ... }

  13. Minor Plugins(tt) • Empty Catch Block: Kiểm tra các biểu thức có bắt exceptions hay không: try{ … } catch (Exception ex){ … }

  14. Minor Plugins(tt) • Non-Standard/Outdated Libraries: • Scan all library files(.jar, .so, .dll) có phù hợp với whitelist của thư viện hiện tại lưu trong: resources/current_libraries/. • Bất cứ thư viện nào không có trong whitelist sẽ được đánh dấu.

  15. Minor Plugins(tt) • Temporary Files: Kiểm tra tên tập tin có phải là quy ước đặt tên tạm thời hay không: VD: 'tmp', 'temp', 'dummy', or a prefix of '~$'

  16. Minor Plugins(tt) • Cross Site Scripting: Simple via Servlets : Plugin này sẽ cố gắng tìm các ví dụ đơn giản của Cross Site Scripting trong một Servlets: class FooServlet extends Servlet { public void doPost(HttpServletRequest req, HttpServletResponse res) { String bar = req.getParameter("bar"); ... out.println("bar = " + bar); } }

  17. Minor Plugins(tt) • External E-Mail Address: Plugin này sẽ cố gắng tìm các External E-Mail Address có trong file mã nguồn hoặc file khác:

More Related