Skip to content
This repository has been archived by the owner on Feb 16, 2024. It is now read-only.

Commit

Permalink
Use serde to load config (#120)
Browse files Browse the repository at this point in the history
* Use serde to load config

Remove legacy code

Avoid issue with unkonwn permission

Recover the loaded files tracking

Special encoding for threads field

Improve how loading from file is performed

Move to a new struct the deserialize helpers

Custom deserialization for unknown permission

Fixes

rustfmt

* Adapt to Serde 1.0

* Remove  field

* Change how config is loaded

* Change global config path

* Rust fmt
  • Loading branch information
gnieto authored and Razican committed Jun 21, 2017
1 parent dbc07e8 commit a16eea9
Show file tree
Hide file tree
Showing 6 changed files with 246 additions and 606 deletions.
54 changes: 54 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Expand Up @@ -32,6 +32,7 @@ clap = "^2.24"
colored = "^1.5"
xml-rs = "0.6"
serde = "^1.0"
serde_derive = "^1.0"
serde_json = "^1.0"
chrono = { version = "^0.3", features = ["serde"] }
toml = "^0.4"
Expand Down
3 changes: 1 addition & 2 deletions config.toml.sample
Expand Up @@ -9,8 +9,7 @@ template = "super" # Results template
rules_json = "/etc/super-analyzer/rules.json" # Vulnerability rules JSON

# Vulnerable or potentially vulnerable permissions
[[permissions]]
name = "unknown" # Unknown permissions
[unknown_permissions]
criticality = "low"
description = "Even if the application can create its own permissions, it's discouraged, since it can lead to missunderstanding between developers."

Expand Down

0 comments on commit a16eea9

Please sign in to comment.