-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Server override #120
base: main
Are you sure you want to change the base?
Server override #120
Conversation
Cargo.toml
Outdated
@@ -24,11 +24,12 @@ clap = { version = "4.0.29", features = ["derive"] } | |||
const_format = "0.2.30" | |||
serde = { version = "^1.0", features = ["derive"] } | |||
serde_json = "^1.0" | |||
cherrybomb-engine = "^0.1" | |||
cherrybomb-engine = {path = "cherrybomb-engine"} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
path
@@ -20,6 +20,37 @@ pub fn change_payload(orig: &Value, path: &[String], new_val: Value) -> Value { | |||
} | |||
|
|||
impl<T: OAS + Serialize> ActiveScan<T> { | |||
pub async fn check_ssl(&self, auth: &Authorization, serv: &Vec<Server>) -> CheckRetVal { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not in the description of the pull, this is a new check
for (k, v) in vars { | ||
new_server_addr = | ||
new_server_addr.replace(&format!("{{{k}}}"), v.default.as_str()); | ||
pub fn servers( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to review it
@@ -93,109 +94,108 @@ impl_passive_checks![ | |||
]; | |||
|
|||
impl_active_checks![ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All of the checks seem commented out
@@ -74,6 +74,7 @@ async fn main() -> anyhow::Result<ExitCode> { | |||
if !opt.no_telemetry { | |||
telemetry::send(config.profile.clone(), config.verbosity.clone()).await?; | |||
} | |||
dbg!(&config.servers_override); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dbg
a4cd039
to
9deee90
Compare
#119
Hey @GuyL99 ,
I resolved the server override in accordance with the opened issue.
Simply put, the "server override" property from the configuration file overrides every server in the OAS file. Secondly, the "—server" flag from the command line will override the configuration file's server.
In macro.rs.req.rs, I changed few things.
I did not make changes to all of the other tests; at this time, just one check has changes, and the rest are commented.