Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,667 changes: 1,667 additions & 0 deletions Cargo.lock

Large diffs are not rendered by default.

11 changes: 9 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,20 @@ thiserror = "1.0.37"
tokio = { version = "^1.23", features = ["rt-multi-thread", "macros"]}
clap = { version = "4.0.29", features = ["derive"] }
const_format = "0.2.30"
cherrybomb-engine = "0.1.1"

#cherrybomb-engine = "^0.1"
serde = { version = "^1.0", features = ["derive"] }
serde_json = "^1.0"
cherrybomb-engine = "^0.1"
serde_yaml = "^0.9.0"
uuid = {version = "1.2.2", features = ["v4"] }
dirs = "4.0.0"
reqwest = "0.11.13"
comfy-table = "6.1.4"
serde_derive = "1.0.152"

lazy_static = "1.4.0"

[dev-dependencies]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is nothing in them...

#cherrybomb-engine = {path = "cherrybomb-engine"}


5 changes: 3 additions & 2 deletions cherrybomb-engine/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cherrybomb-engine"
version = "0.1.0"
version = "0.1.1"
authors = ["BLST Security"]
description = """
Cherrybomb enging crate
Expand All @@ -13,7 +13,7 @@ edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
cherrybomb-oas = "^0.1"
cherrybomb-oas = "0.1"
anyhow = "1.0.66"
thiserror = "1.0.37"
serde_json = "^1.0"
Expand All @@ -24,3 +24,4 @@ strum_macros = "0.23" # legacy
url="^2" #legacy
base64 = "0.13" #legacy
reqwest = { version = "^0.11",default_features = false, features = ["json","rustls-tls"] } #legacy

6 changes: 5 additions & 1 deletion cherrybomb-engine/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,11 @@ async fn run_normal_profile(
Ok(report)
}

async fn run_full_profile(config: &Config, oas: &OAS3_1, oas_json: &Value) -> anyhow::Result<Value> {
async fn run_full_profile(
config: &Config,
oas: &OAS3_1,
oas_json: &Value,
) -> anyhow::Result<Value> {
let mut report = json!({});
let mut results = HashMap::from([
("active", run_active_profile(config, oas, oas_json).await),
Expand Down
1 change: 0 additions & 1 deletion cherrybomb-engine/src/scan/active/active_scanner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ impl<T: OAS + Serialize + for<'de> Deserialize<'de>> ActiveScan<T> {
};
}


fn payloads_generator(oas: &T, oas_value: &Value) -> Vec<OASMap> {
let mut payloads = vec![];
for (path, path_item) in oas.get_paths() {
Expand Down
2 changes: 1 addition & 1 deletion cherrybomb-oas/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cherrybomb-oas"
version = "0.1.0"
version = "0.1.1"
authors = ["BLST Security"]
description = """
Cherrybomb OpenAPI Specification (OAS) struct and functions
Expand Down
3 changes: 2 additions & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ fn merge_options(conf: &mut Config, opt: &Options) {
if let Some(server_item) = &opt.server {
conf.servers_override = vec![server_item.clone()];
}
conf.no_color = opt.no_color.clone();
}

#[tokio::main]
Expand All @@ -75,7 +76,7 @@ async fn main() -> anyhow::Result<ExitCode> {
telemetry::send(config.profile.clone(), config.verbosity.clone()).await?;
}
let json_val = cherrybomb_engine::run(&config).await?;
match print_tables(json_val, &opt) {
match print_tables(json_val, &opt, config.no_color) {
Ok(exit_code) => Ok(exit_code),
Err(e) => Err(anyhow::anyhow!("Error printing tables: {}", e)),
}
Expand Down
Loading