Skip to content

Commit

Permalink
Bump dependencies to latest versions
Browse files Browse the repository at this point in the history
  • Loading branch information
SweetVishnya committed Feb 22, 2025
1 parent ff57afd commit f67d697
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 18 deletions.
10 changes: 5 additions & 5 deletions casr/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,18 @@ shell-words = "1.1"
anyhow = "1.0"
clap = { version = "4.5", features = ["wrap_help", "cargo", "env"] }
chrono = "0.4"
goblin = "0.8"
goblin = "0.9"
log = "0.4"
simplelog = "0.12"
cursive = { version = "0.21", default-features = false, features = ["termion-backend"] }
cursive_tree_view = "0.9"
gdb-command = "0.7"
nix = "0.26"
nix = { version = "0.29", features = ["fs"] }
rayon = "1.10"
num_cpus = "1.16"
is_executable = "1.0"
linux-personality = "2.0"
colored = "2.0"
colored = "3.0"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
regex = "1"
Expand All @@ -36,7 +36,7 @@ reqwest = { version = "0.12", features = ["json", "multipart", "rustls-tls"], de
tokio = { version = "1", features = ["rt", "macros"], optional = true }
toml = { version = "0.8", optional = true }
wait-timeout = "0.2"
which = "6.0"
which = "7.0"
copy_dir = "0.1"

libcasr = { path = "../libcasr", version = "2.12.1", features = ["serde", "exploitable"] }
Expand All @@ -52,5 +52,5 @@ name = "casr-dojo"
required-features = ["dojo"]

[dev-dependencies]
lazy_static = "1.4"
lazy_static = "1.5"
lsb_release = "0.1"
18 changes: 9 additions & 9 deletions casr/src/bin/casr-core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,11 @@ use gdb_command::{ExecType, GdbCommand};
use goblin::container::Endian;
use goblin::elf::{Elf, header, note};
use log::{error, warn};
use nix::fcntl::{FlockArg, flock};
use nix::fcntl::{Flock, FlockArg};
use simplelog::*;
use std::fs::{File, OpenOptions};
use std::io::prelude::*;
use std::io::{self, Read};
use std::os::unix::io::AsRawFd;
use std::path::{Path, PathBuf};

use libcasr::error::Error;
Expand Down Expand Up @@ -259,7 +258,7 @@ fn main() -> Result<()> {
"Ulimit is set to 0. Set ulimit greater than zero to analyze coredumps. Casr command line: {}",
&casr_cmd
);
drop(lockfile.unwrap());
let _ = lockfile.unwrap().unlock();

Check warning on line 261 in casr/src/bin/casr-core.rs

View check run for this annotation

Codecov / codecov/patch

casr/src/bin/casr-core.rs#L261

Added line #L261 was not covered by tests
bail!(
"Ulimit is set to 0. Set ulimit greater than zero to analyze coredumps. Casr command line: {}",
&casr_cmd
Expand Down Expand Up @@ -297,7 +296,7 @@ fn main() -> Result<()> {
result.as_ref().err().unwrap(),
&casr_cmd
);
drop(lockfile.unwrap());
let _ = lockfile.unwrap().unlock();

Check warning on line 299 in casr/src/bin/casr-core.rs

View check run for this annotation

Codecov / codecov/patch

casr/src/bin/casr-core.rs#L299

Added line #L299 was not covered by tests
bail!(
"Coredump analysis error: {}. Casr command line: {}",
result.as_ref().err().unwrap(),
Expand All @@ -316,21 +315,22 @@ fn main() -> Result<()> {
} else {
error!("Couldn't write report file: {}", report_path.display());
}
drop(lockfile.unwrap());
let _ = lockfile.unwrap().unlock();

Check warning on line 318 in casr/src/bin/casr-core.rs

View check run for this annotation

Codecov / codecov/patch

casr/src/bin/casr-core.rs#L318

Added line #L318 was not covered by tests
Ok(())
}

/// Method checks mutex.
fn check_lock() -> Result<File> {
fn check_lock() -> Result<Flock<File>> {

Check warning on line 323 in casr/src/bin/casr-core.rs

View check run for this annotation

Codecov / codecov/patch

casr/src/bin/casr-core.rs#L323

Added line #L323 was not covered by tests
let mut project_dir = PathBuf::from("/var/crash/");
project_dir.push("Casr.lock");
let file = OpenOptions::new()
.create(true)
.append(true)
.open(project_dir)?;
let fd = file.as_raw_fd();
flock(fd, FlockArg::LockExclusive).unwrap();
Ok(file)
match Flock::lock(file, FlockArg::LockExclusive) {
Ok(l) => Ok(l),
Err((_, errno)) => Err(errno.into()),

Check warning on line 332 in casr/src/bin/casr-core.rs

View check run for this annotation

Codecov / codecov/patch

casr/src/bin/casr-core.rs#L330-L332

Added lines #L330 - L332 were not covered by tests
}
}

/// Analyze coredump and put information to report.
Expand Down
8 changes: 4 additions & 4 deletions libcasr/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ exclude = ["/fuzz"]

[dependencies]
regex = "1"
lazy_static = "1.4"
goblin = { version = "0.8", optional = true }
capstone = { version = "0.12", optional = true }
lazy_static = "1.5"
goblin = { version = "0.9", optional = true }
capstone = { version = "0.13", optional = true }
chrono = "0.4"
serde = { version = "1.0", features = ["derive"], optional = true }
serde_json = { version = "1.0", optional = true }
lexiclean = { version = "0.0", optional = true }
gdb-command = "0.7"
thiserror = "1.0"
thiserror = "2.0"
kodama = "0.3"

[features]
Expand Down

0 comments on commit f67d697

Please sign in to comment.