repo stringlengths 6 65 | file_url stringlengths 81 311 | file_path stringlengths 6 227 | content stringlengths 0 32.8k | language stringclasses 1
value | license stringclasses 7
values | commit_sha stringlengths 40 40 | retrieved_at stringdate 2026-01-04 15:31:58 2026-01-04 20:25:31 | truncated bool 2
classes |
|---|---|---|---|---|---|---|---|---|
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/helper/builder.rs | wasmer-auth/src/helper/builder.rs | use std::ops::Deref;
use std::sync::Arc;
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use ate::prelude::*;
use crate::cmd::gather_command;
use crate::cmd::main_session_prompt;
use crate::error::*;
use crate::helper::b64_to_session;
pub struct DioBuilder {
cfg_... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/helper/conf.rs | wasmer-auth/src/helper/conf.rs | #[allow(unused_imports)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use ::ate::prelude::*;
pub fn conf_auth() -> ConfAte {
let mut cfg_ate = ConfAte::default();
cfg_ate.configured_for(ConfiguredFor::BestSecurity);
cfg_ate.log_format.meta = SerializationFormat::Json;
cfg_a... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/helper/auth.rs | wasmer-auth/src/helper/auth.rs | #[allow(unused_imports)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use url::Url;
use std::io::Write;
#[cfg(unix)]
use std::env::temp_dir;
#[cfg(unix)]
use std::os::unix::fs::symlink;
#[cfg(unix)]
use std::os::unix::fs::PermissionsExt;
use ::ate::crypto::EncryptKey;
use ::ate::prelude::*... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/helper/mod.rs | wasmer-auth/src/helper/mod.rs | mod auth;
mod builder;
mod conf;
mod keys;
mod misc;
pub use auth::*;
pub use builder::*;
pub use conf::*;
pub use keys::*;
pub use misc::*;
| rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/helper/keys.rs | wasmer-auth/src/helper/keys.rs | use serde::*;
use std::fs::File;
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
pub fn try_load_key<T>(key_path: String) -> Option<T>
where
T: serde::de::DeserializeOwned,
{
let path = shellexpand::tilde(&key_path).to_string();
debug!("loading key: {}", pa... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/sudo.rs | wasmer-auth/src/request/sudo.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use std::time::Duration;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct SudoRequest {
pub session: AteSessionUser,
pub authenticator_code: String,
}
#[derive(Debug,... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/create_user.rs | wasmer-auth/src/request/create_user.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct CreateUserRequest {
pub auth: String,
pub email: String,
pub secret: EncryptKey,
pub accepted_terms: Option<St... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/login.rs | wasmer-auth/src/request/login.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use std::time::Duration;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct LoginRequest {
pub email: String,
pub secret: EncryptKey,
pub verification_code: Option<S... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/group_details.rs | wasmer-auth/src/request/group_details.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct GroupDetailsRequest {
pub group: String,
pub session: Option<AteSessionGroup>,
}
#[derive(Debug, Serialize, Deseriali... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/mod.rs | wasmer-auth/src/request/mod.rs | mod create_group;
mod create_user;
mod gather;
mod group_details;
mod group_remove;
mod group_user_add;
mod group_user_remove;
mod login;
mod query;
mod reset;
mod sudo;
pub use create_group::*;
pub use create_user::*;
pub use gather::*;
pub use group_details::*;
pub use group_remove::*;
pub use group_user_add::*;
pub... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/create_group.rs | wasmer-auth/src/request/create_group.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct CreateGroupRequest {
pub group: String,
pub identity: String,
}
#[derive(Debug, Serialize, Deserialize, Clone)]
pub s... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/group_user_add.rs | wasmer-auth/src/request/group_user_add.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct GroupUserAddRequest {
pub group: String,
pub session: AteSessionGroup,
pub who_key: PublicEncryptKey,
pub who_... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/query.rs | wasmer-auth/src/request/query.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use crate::model::Advert;
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct QueryRequest {
pub identity: String,
}
#[derive(Debug, Serialize, Deserialize, Clone)]
pub str... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/gather.rs | wasmer-auth/src/request/gather.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct GatherRequest {
pub session: AteSessionInner,
pub group: String,
}
#[derive(Debug, Serialize, Deserialize, Clone)]
pu... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/group_remove.rs | wasmer-auth/src/request/group_remove.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct GroupRemoveRequest {
pub group: String,
pub session: AteSessionGroup,
}
#[derive(Debug, Serialize, Deserialize, Clone... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/reset.rs | wasmer-auth/src/request/reset.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct ResetRequest {
pub auth: String,
pub email: String,
pub new_secret: EncryptKey,
pub recovery_key: EncryptKey,
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/src/request/group_user_remove.rs | wasmer-auth/src/request/group_user_remove.rs | #![allow(unused_imports)]
use ate::prelude::*;
use serde::*;
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct GroupUserRemoveRequest {
pub group: String,
pub session: AteSessionGroup,
pub who: AteHash,
pub purpose: AteRo... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-auth/examples/client.rs | wasmer-auth/examples/client.rs | use wasmer_auth::prelude::*;
use serde::{Deserialize, Serialize};
#[derive(Debug, Serialize, Deserialize, Clone)]
struct MyData {
pi: String,
}
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
ate::log_init(0, false);
let dio = DioBuilder::default()
.with_session_prompt(... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/lib.rs | comms/src/lib.rs | mod client;
mod hello;
#[cfg(feature = "quantum")]
mod key_exchange;
mod protocol;
mod certificate_validation;
#[cfg(feature = "dns")]
#[cfg(not(target_family = "wasm"))]
mod dns;
mod security;
pub use protocol::MessageProtocolVersion;
pub use protocol::MessageProtocolApi;
pub use protocol::StreamReadable;
pub use pro... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/security.rs | comms/src/security.rs | #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord)]
pub enum StreamSecurity {
Unencrypted,
AnyEncryption,
ClassicEncryption,
QuantumEncryption,
DoubleEncryption,
}
impl Default
for StreamSecurity {
fn default() -> Self {
StreamSecurity::AnyEncryption
}
}
impl StreamSecuri... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/client.rs | comms/src/client.rs | use std::io;
#[allow(unused_imports)]
use std::ops::DerefMut;
use wasmer_bus_ws::prelude::*;
use tokio::io::AsyncRead;
use tokio::io::AsyncWrite;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, trace, warn};
use ate_crypto::KeySize;
use ate_crypto::NodeId;
use crate::HelloMetadata;
use super::pro... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/certificate_validation.rs | comms/src/certificate_validation.rs | use std::sync::RwLock;
use once_cell::sync::Lazy;
use ate_crypto::AteHash;
pub static GLOBAL_CERTIFICATES: Lazy<RwLock<Vec<AteHash>>> =
Lazy::new(|| RwLock::new(Vec::new()));
pub fn add_global_certificate(cert: &AteHash) {
GLOBAL_CERTIFICATES.write().unwrap().push(cert.clone());
}
pub fn get_global_certifica... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/hello.rs | comms/src/hello.rs | use std::io;
use tokio::io::AsyncRead;
use tokio::io::AsyncWrite;
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use ate_crypto::KeySize;
use ate_crypto::NodeId;
use ate_crypto::SerializationFormat;
use serde::{Deserialize, Serialize};
use super::protocol::MessageProt... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/key_exchange.rs | comms/src/key_exchange.rs | use std::io;
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use ate_crypto::KeySize;
use ate_crypto::PrivateEncryptKey;
use ate_crypto::EncryptKey;
use ate_crypto::InitializationVector;
use ate_crypto::PublicEncryptKey;
use super::protocol::MessageProtocolApi;
use sup... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/dns/client.rs | comms/src/dns/client.rs | use std::net::SocketAddr;
use std::net::ToSocketAddrs;
use derivative::*;
use tokio::net::TcpStream as TokioTcpStream;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use tokio::sync::Mutex;
use {
trust_dns_client::client::*, trust_dns_client::op::DnsResp... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/dns/mod.rs | comms/src/dns/mod.rs | mod query;
mod client;
pub use client::DnsClient as Dns; | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/dns/query.rs | comms/src/dns/query.rs | use std::net::IpAddr;
use std::str::FromStr;
use ate_crypto::AteHash;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, trace, warn};
pub use trust_dns_client::rr::*;
impl super::Dns
{
pub async fn dns_certs(&mut self, name: &str) -> Vec<AteHash> {
match name.to_lowercase().as_str() {
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/protocol/stream.rs | comms/src/protocol/stream.rs | use std::io;
use ate_crypto::EncryptKey;
use async_trait::async_trait;
use super::MessageProtocolApi;
use super::StreamReadable;
use super::StreamWritable;
#[derive(Debug)]
pub struct StreamRx {
proto: Box<dyn MessageProtocolApi + Send + Sync + 'static>,
ek: Option<EncryptKey>,
}
impl StreamRx
{
pub(crat... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/protocol/version.rs | comms/src/protocol/version.rs | use serde::*;
use tokio::io::AsyncRead;
use tokio::io::AsyncWrite;
use super::MessageProtocolApi;
/// Version of the stream protocol used to talk to Wasmer services
#[repr(u16)]
#[derive(Serialize, Deserialize, Debug, Clone, Copy)]
pub enum MessageProtocolVersion
{
V1 = 1,
V2 = 2,
V3 = 3,
}
impl Default
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/protocol/v2.rs | comms/src/protocol/v2.rs | use std::io;
use std::ops::DerefMut;
use derivative::*;
use tokio::io::AsyncWrite;
use tokio::io::AsyncWriteExt;
use tokio::io::AsyncRead;
use tokio::io::AsyncReadExt;
use async_trait::async_trait;
use ate_crypto::{InitializationVector, EncryptKey};
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument,... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/protocol/api.rs | comms/src/protocol/api.rs | use std::io;
use std::pin::Pin;
use std::task::Context;
use std::task::Poll;
use tokio::io::ReadBuf;
use tokio::io::AsyncRead;
use tokio::io::AsyncWrite;
use async_trait::async_trait;
use ate_crypto::EncryptKey;
use super::StreamRx;
use super::StreamTx;
#[async_trait]
pub trait MessageProtocolApi
where Self: std::fmt... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/protocol/mod.rs | comms/src/protocol/mod.rs | mod v1;
mod v2;
mod v3;
mod api;
mod stream;
mod version;
pub use api::MessageProtocolApi;
pub use api::AsyncStream;
pub use api::StreamReadable;
pub use api::StreamWritable;
pub use stream::StreamRx;
pub use stream::StreamTx;
pub use version::MessageProtocolVersion; | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/protocol/v3.rs | comms/src/protocol/v3.rs | use std::io;
use std::ops::DerefMut;
use derivative::*;
use tokio::io::AsyncWrite;
use tokio::io::AsyncWriteExt;
use tokio::io::AsyncRead;
use tokio::io::AsyncReadExt;
use async_trait::async_trait;
use ate_crypto::{InitializationVector, EncryptKey};
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument,... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/comms/src/protocol/v1.rs | comms/src/protocol/v1.rs | use std::io;
use std::ops::DerefMut;
use derivative::*;
use tokio::io::AsyncWrite;
use tokio::io::AsyncWriteExt;
use tokio::io::AsyncRead;
use tokio::io::AsyncReadExt;
use async_trait::async_trait;
use ate_crypto::{EncryptKey, InitializationVector};
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument,... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/atedb/src/flow.rs | atedb/src/flow.rs | use regex::Regex;
use std::sync::Arc;
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use async_trait::async_trait;
use ate::spec::TrustMode;
use ate::{error::ChainCreationError, prelude::*};
use wasmer_auth::cmd::query_command;
use wasmer_auth::helper::conf_auth;
use ... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/atedb/src/main.rs | atedb/src/main.rs | use ate::{compact::CompactMode, prelude::*, utils::load_node_list};
use std::time::Duration;
#[allow(unused_imports)]
use tracing::{debug, error, info, instrument, span, trace, warn, Level};
use url::Url;
use clap::Parser;
mod flow;
use crate::flow::ChainFlow;
#[derive(Parser)]
#[clap(version = "1.4", author = "Joh... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/atedb/src/bin/atedump.rs | atedb/src/bin/atedump.rs | #![allow(unused_imports)]
use ascii_tree::Tree;
use async_trait::async_trait;
use ate::conf::conf_ate;
use ate::event::*;
use ate::loader::LoadData;
use ate::loader::Loader;
use ate::prelude::*;
use ate::redo::OpenFlags;
use ate::redo::RedoLog;
use ate::spec::TrustMode;
use ate::trust::ChainHeader;
use ate::utils::Load... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/lib.rs | wasmer-instance/src/lib.rs | pub mod opt;
pub mod server;
pub mod session;
pub mod handler;
pub mod relay;
pub mod adapter;
pub mod fixed_reader;
pub use wasmer_term;
pub use wasmer_auth;
pub use wasmer_ssh;
pub use ate::utils; | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/session.rs | wasmer-instance/src/session.rs | use std::net::SocketAddr;
use std::sync::Arc;
use std::sync::Mutex;
use std::collections::HashMap;
use tokio::sync::Mutex as AsyncMutex;
use ate::prelude::*;
use ate::comms::*;
use wasmer_deploy_cli::model::InstanceCall;
use wasmer_deploy_cli::model::InstanceCommand;
use wasmer_deploy_cli::model::InstanceHello;
use was... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/adapter.rs | wasmer-instance/src/adapter.rs | use std::sync::Arc;
use std::path::Path;
use std::io;
use std::io::Read;
use std::io::Seek;
use std::io::SeekFrom;
use std::io::Write;
use std::sync::Mutex;
use std::future::Future;
use std::task::Context;
use std::task::Poll;
use ate_files::accessor::FileAccessor;
use ate_files::accessor::RequestContext;
use wasmer_ss... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/relay.rs | wasmer-instance/src/relay.rs | use ate::comms::{StreamRx, Upstream};
/// Relays a web socket connection over to another server that
/// is currently hosting this particular instance
pub struct Relay
{
pub rx: StreamRx,
pub tx: Upstream,
}
impl Relay
{
pub async fn run(self) -> Result<(), Box<dyn std::error::Error>>
{
Ok(())... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/fixed_reader.rs | wasmer-instance/src/fixed_reader.rs | use std::io;
use std::pin::Pin;
use std::task::Context;
use std::task::Poll;
use bytes::Bytes;
use tokio::io::AsyncRead;
use tokio::io::ReadBuf;
use ate_comms::StreamReadable;
use async_trait::async_trait;
pub struct FixedReader
{
data: Option<Bytes>,
}
impl FixedReader
{
pub fn new(data: Vec<u8>) -> FixedRea... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/server.rs | wasmer-instance/src/server.rs | use std::net::SocketAddr;
use std::sync::Arc;
use std::sync::Mutex;
use std::time::Duration;
use ate::comms::RawWebRoute;
use wasmer_ssh::wasmer_os::environment::Environment;
use wasmer_ssh::wasmer_os::fd::FdMsg;
use error_chain::bail;
#[allow(unused_imports)]
use tokio::sync::mpsc;
use async_trait::async_trait;
use a... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/handler.rs | wasmer-instance/src/handler.rs | use async_trait::async_trait;
use std::ops::Deref;
use std::ops::DerefMut;
use std::sync::Arc;
use std::sync::Mutex;
use tokio::sync::Mutex as AsyncMutex;
use wasmer_ssh::wasmer_os;
use ate::comms::*;
use wasmer_os::api::ConsoleAbi;
use wasmer_os::api::ConsoleRect;
#[allow(unused_imports)]
use tracing::{debug, error, i... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/opt/session_server.rs | wasmer-instance/src/opt/session_server.rs | #[allow(unused_imports, dead_code)]
use tracing::{info, error, debug};
use ate::{prelude::*};
use clap::Parser;
use wasmer_ssh::wasmer_os;
/// Runs the session server
#[derive(Parser)]
pub struct OptsSessionServer {
/// Optional list of the nodes that make up this cluster
#[clap(long)]
pub nodes_list: Opti... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/opt/core.rs | wasmer-instance/src/opt/core.rs | #[allow(unused_imports, dead_code)]
use tracing::{info, error, debug};
use ate::prelude::*;
use clap::Parser;
use super::*;
#[derive(Parser)]
#[clap(version = "1.0", author = "Wasmer Inc <info@wasmer.io>")]
pub struct Opts {
/// Sets the level of log verbosity, can be used multiple times
#[allow(dead_code)]
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/opt/mod.rs | wasmer-instance/src/opt/mod.rs | mod core;
mod session_server;
pub use self::core::*;
pub use session_server::*; | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-instance/src/bin/wasmer-instance.rs | wasmer-instance/src/bin/wasmer-instance.rs | #![recursion_limit="256"]
use ate::mesh::MeshHashTable;
use ate::utils::load_node_list;
use wasmer_instance::server::Server;
use tokio::sync::watch;
#[allow(unused_imports, dead_code)]
use tracing::{info, error, debug, trace, warn};
use ate::prelude::*;
use std::sync::Arc;
use clap::Parser;
use tokio::sync::watch::Rece... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/prelude.rs | wasmer-bus/process/src/prelude.rs | pub use crate::api::StdioMode;
pub use crate::process::Child;
pub use crate::process::ChildStderr;
pub use crate::process::ChildStdin;
pub use crate::process::ChildStdout;
pub use crate::process::Command;
pub use crate::process::ExitStatus;
pub use crate::process::Output;
pub use crate::process::Stdio;
pub use wasmer_b... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/lib.rs | wasmer-bus/process/src/lib.rs | pub mod api;
pub mod prelude;
pub mod process;
| rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/command.rs | wasmer-bus/process/src/process/command.rs | use std::{ffi::OsStr, io};
use super::*;
/// A process builder, providing fine-grained control
/// over how a new process should be spawned.
///
/// A default configuration can be
/// generated using `Command::new(program)`, where `program` gives a path to the
/// program to be executed. Additional builder methods al... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/stdio.rs | wasmer-bus/process/src/process/stdio.rs | use crate::api::*;
/// Describes what to do with a standard I/O stream for a child process when
/// passed to the [`stdin`], [`stdout`], and [`stderr`] methods of [`Command`].
///
/// [`stdin`]: Command::stdin
/// [`stdout`]: Command::stdout
/// [`stderr`]: Command::stderr
#[derive(Debug, Clone)]
pub struct Stdio {
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/child_stdin.rs | wasmer-bus/process/src/process/child_stdin.rs | use std::io;
use std::io::Write;
use super::*;
use crate::api;
#[derive(Debug)]
pub struct ChildStdin {
pub(super) context: api::ProcessClient,
}
impl ChildStdin {
pub fn new(context: api::ProcessClient) -> ChildStdin {
ChildStdin { context }
}
}
impl Write for ChildStdin {
fn write(&mut sel... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/child_stdout.rs | wasmer-bus/process/src/process/child_stdout.rs | use bytes::*;
use std::io::Read;
use std::sync::mpsc;
use super::*;
#[derive(Debug)]
pub struct ChildStdout {
pub(super) rx: mpsc::Receiver<Vec<u8>>,
pub(super) buffer: BytesMut,
}
impl ChildStdout {
pub fn new() -> (ChildStdout, mpsc::Sender<Vec<u8>>) {
let (tx_stdout, rx_stdout) = mpsc::channel... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/child_stderr.rs | wasmer-bus/process/src/process/child_stderr.rs | pub use super::ChildStdout as ChildStderr;
| rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/mod.rs | wasmer-bus/process/src/process/mod.rs | mod child;
mod child_stderr;
mod child_stdin;
mod child_stdout;
mod command;
mod exit_status;
mod output;
mod stdio;
pub use child::Child;
pub use child_stderr::ChildStderr;
pub use child_stdin::ChildStdin;
pub use child_stdout::ChildStdout;
pub use command::Command;
pub use exit_status::ExitStatus;
pub use output::Ou... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/child.rs | wasmer-bus/process/src/process/child.rs | use std::future::Future;
use std::io::{self, Read};
use std::pin::Pin;
use std::sync::Mutex;
use std::task::Context;
use std::task::Poll;
use tokio::sync::watch;
use super::*;
use crate::api;
use crate::api::StdioMode;
/// Representation of a running or exited child process.
///
/// This structure is used to represen... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/exit_status.rs | wasmer-bus/process/src/process/exit_status.rs | #[derive(PartialEq, Eq, Clone, Copy)]
pub struct ExitStatusError {
code: Option<i32>,
}
impl ExitStatusError {
pub fn code(&self) -> Option<i32> {
self.code.clone()
}
pub fn into_status(&self) -> ExitStatus {
ExitStatus { code: self.code }
}
}
#[derive(Debug, PartialEq, Eq, Clone,... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/process/output.rs | wasmer-bus/process/src/process/output.rs | use super::*;
#[derive(PartialEq, Eq, Clone)]
pub struct Output {
pub status: ExitStatus,
pub stdout: Vec<u8>,
pub stderr: Vec<u8>,
}
| rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/process/src/api/mod.rs | wasmer-bus/process/src/api/mod.rs | use serde::*;
use std::fmt;
use std::{fmt::Display, sync::Arc};
use wasmer_bus::macros::*;
#[wasmer_bus(format = "bincode")]
pub trait Pool {
async fn spawn(
&self,
spawn: Spawn,
stdout: impl Fn(Vec<u8>),
stderr: impl Fn(Vec<u8>),
exit: impl Fn(i32),
) -> Arc<dyn Process... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/prelude.rs | wasmer-bus/mio/src/prelude.rs | pub use std::time::Duration;
pub use std::net::SocketAddr;
pub use std::net::Ipv4Addr;
pub use std::net::Ipv6Addr;
pub use super::mio::AsyncIcmpSocket;
pub use super::mio::AsyncRawSocket;
pub use super::mio::AsyncTcpListener;
pub use super::mio::AsyncTcpStream;
pub use super::mio::AsyncUdpSocket;
pub use super::mio::... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/lib.rs | wasmer-bus/mio/src/lib.rs | pub mod mio;
pub mod prelude;
pub mod model;
pub(crate) mod comms; | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/blocking.rs | wasmer-bus/mio/src/mio/blocking.rs | use std::io;
use std::net::IpAddr;
use std::net::SocketAddr;
use wasmer_bus::task::block_on;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, trace, warn};
pub struct RawSocket {
inner: super::AsyncRawSocket
}
impl RawSocket {
pub fn new(socket: super::AsyncRawSocket) -> Self {
Se... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/raw_socket.rs | wasmer-bus/mio/src/mio/raw_socket.rs | use std::io;
use tokio::sync::Mutex;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, trace, warn};
use crate::comms::*;
pub struct AsyncRawSocket {
socket: Mutex<Socket>,
}
impl AsyncRawSocket {
pub(crate) fn new(socket: Socket) -> Self {
Self {
socket: Mutex::new(so... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/tcp_listener.rs | wasmer-bus/mio/src/mio/tcp_listener.rs | use std::io;
use std::net::SocketAddr;
use tokio::sync::Mutex;
use derivative::*;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, trace, warn};
use crate::comms::*;
use super::*;
use crate::comms::Port;
#[derive(Debug)]
struct State
{
socket: Option<Socket>,
ttl: u8,
}
#[derive(Derivati... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/icmp_socket.rs | wasmer-bus/mio/src/mio/icmp_socket.rs | use std::io;
use std::net::IpAddr;
use std::net::SocketAddr;
use std::collections::VecDeque;
use tokio::sync::Mutex;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, trace, warn};
use crate::comms::*;
#[derive(Debug)]
struct State
{
socket: Socket,
ttl: u8,
backlog: VecDeque<(Vec<u8>,... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/port.rs | wasmer-bus/mio/src/mio/port.rs | use std::sync::Arc;
use std::io;
use std::ops::Deref;
use std::ops::DerefMut;
use std::net::IpAddr;
use std::net::Ipv4Addr;
use std::net::Ipv6Addr;
use std::net::SocketAddr;
use ate_comms::StreamSecurity;
use tokio::sync::Mutex;
use tokio::sync::MutexGuard;
use chrono::DateTime;
use chrono::Utc;
use derivative::*;
#[al... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/mod.rs | wasmer-bus/mio/src/mio/mod.rs | mod port;
mod blocking;
mod icmp_socket;
mod raw_socket;
mod tcp_listener;
mod tcp_stream;
mod udp_socket;
mod token;
pub use port::*;
pub use blocking::*;
pub use icmp_socket::*;
pub use raw_socket::*;
pub use tcp_listener::*;
pub use tcp_stream::*;
pub use udp_socket::*;
pub use token::*; | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/tcp_stream.rs | wasmer-bus/mio/src/mio/tcp_stream.rs | use std::io;
use std::collections::VecDeque;
use std::net::SocketAddr;
use tokio::sync::Mutex;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, trace, warn};
use crate::comms::*;
#[derive(Debug)]
struct State
{
backlog: VecDeque<Vec<u8>>,
socket: Socket,
ttl: u8,
nodelay: bool,
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/udp_socket.rs | wasmer-bus/mio/src/mio/udp_socket.rs | use std::io;
use std::net::{SocketAddr, IpAddr, Ipv4Addr};
use std::collections::VecDeque;
use tokio::sync::Mutex;
#[allow(unused_imports, dead_code)]
use tracing::{debug, error, info, trace, warn};
use crate::comms::*;
use crate::comms::Port;
#[derive(Debug)]
struct State
{
socket: Socket,
ttl: u8,
backl... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/mio/token.rs | wasmer-bus/mio/src/mio/token.rs | use std::io::Write;
use ate_crypto::SerializationFormat;
use ate_crypto::error::SerializationError;
#[cfg(unix)]
use std::{
env::temp_dir,
os::unix::fs::{
PermissionsExt,
symlink
}
};
use crate::model::NetworkToken;
pub fn decode_access_token(token: String) -> Result<NetworkToken, Serializ... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/shutdown.rs | wasmer-bus/mio/src/model/shutdown.rs | use serde::*;
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, Serialize, Deserialize)]
pub enum Shutdown
{
Read,
Write,
Both,
}
impl Into<std::net::Shutdown>
for Shutdown
{
fn into(self) -> std::net::Shutdown {
use Shutdown::*;
match self {
Read => std::n... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/port_response.rs | wasmer-bus/mio/src/model/port_response.rs | use std::net::SocketAddr;
use std::net::IpAddr;
use std::fmt;
use serde::*;
use super::*;
#[derive(Debug, Serialize, Deserialize, Clone)]
pub enum PortResponse {
Nop {
handle: SocketHandle,
ty: PortNopType,
},
Received {
handle: SocketHandle,
data: Vec<u8>
},
Receiv... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/ip_cidr.rs | wasmer-bus/mio/src/model/ip_cidr.rs | use std::net::IpAddr;
use std::fmt;
use serde::*;
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, Serialize, Deserialize)]
pub struct IpCidr
{
pub ip: IpAddr,
pub prefix: u8,
}
impl IpCidr
{
pub fn gateway(&self) -> IpAddr {
match self.ip {
IpAddr::V4(ip) => {
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/port_command.rs | wasmer-bus/mio/src/model/port_command.rs | pub use chrono::DateTime;
pub use chrono::Utc;
use std::time::Duration;
use serde::*;
use std::net::IpAddr;
use std::net::SocketAddr;
use std::fmt;
use super::*;
pub const PORT_COMMAND_VERSION: u32 = 1;
#[derive(Debug, Serialize, Deserialize, Clone)]
pub enum PortCommand {
Send {
handle: SocketHandle,
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/hardware_address.rs | wasmer-bus/mio/src/model/hardware_address.rs | use serde::*;
use std::fmt;
#[derive(Debug, Serialize, Deserialize, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct HardwareAddress([u8; 6]);
impl HardwareAddress {
pub fn new() -> HardwareAddress {
HardwareAddress (
[6u8, fastrand::u8(..), fastrand::u8(..), fastrand::u8(..), fa... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/port_nop.rs | wasmer-bus/mio/src/model/port_nop.rs | use serde::*;
#[derive(Debug, Serialize, Deserialize, Clone, Copy, PartialEq, Eq, PartialOrd, Ord)]
pub enum PortNopType
{
MaySend,
MayReceive,
CloseHandle,
BindRaw,
BindIcmp,
BindDhcp,
DhcpReset,
BindUdp,
ConnectTcp,
Listen,
DhcpAcquire,
SetHopLimit,
SetAckDelay,
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/switch_hello.rs | wasmer-bus/mio/src/model/switch_hello.rs | use serde::*;
use std::fmt;
use ate_crypto::ChainKey;
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct SwitchHello {
pub chain: ChainKey,
pub access_token: String,
pub version: u32,
}
impl fmt::Display
for SwitchHello
{
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
w... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/socket_handle.rs | wasmer-bus/mio/src/model/socket_handle.rs | use std::fmt;
use serde::*;
#[derive(Debug, Serialize, Deserialize, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct SocketHandle(pub i32);
impl fmt::Display
for SocketHandle {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(f, "handle({})", self.0)
}
} | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/ip_route.rs | wasmer-bus/mio/src/model/ip_route.rs | use std::fmt;
use std::net::IpAddr;
use serde::*;
use chrono::DateTime;
use chrono::Utc;
use super::*;
#[derive(Clone, Debug, Serialize, Deserialize)]
pub struct IpRoute
{
pub cidr: IpCidr,
pub via_router: IpAddr,
pub preferred_until: Option<DateTime<Utc>>,
pub expires_at: Option<DateTime<Utc>>
}
imp... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/mod.rs | wasmer-bus/mio/src/model/mod.rs | mod hardware_address;
mod ip_cidr;
mod ip_protocol;
mod ip_route;
mod ip_version;
mod port_command;
mod port_nop;
mod port_response;
mod socket_error;
mod socket_handle;
mod socket_shutdown;
mod shutdown;
mod token;
mod switch_hello;
pub use hardware_address::*;
pub use ip_cidr::*;
pub use ip_protocol::*;
pub use ip_r... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/ip_version.rs | wasmer-bus/mio/src/model/ip_version.rs | use std::fmt;
use serde::*;
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, Serialize, Deserialize)]
pub enum IpVersion {
Ipv4,
Ipv6,
}
impl fmt::Display
for IpVersion {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
use IpVersion::*;
match self {
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/socket_error.rs | wasmer-bus/mio/src/model/socket_error.rs | use std::error::Error;
use std::io;
use serde::*;
use std::fmt;
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, Serialize, Deserialize)]
pub enum SocketErrorKind {
NotFound,
PermissionDenied,
ConnectionRefused,
ConnectionReset,
HostUnreachable,
NetworkUnreachable,
Connect... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/ip_protocol.rs | wasmer-bus/mio/src/model/ip_protocol.rs | use std::fmt;
use serde::*;
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, Serialize, Deserialize)]
pub enum IpProtocol {
HopByHop,
Icmp,
Igmp,
Tcp,
Udp,
Ipv6Route,
Ipv6Frag,
Icmpv6,
Ipv6NoNxt,
Ipv6Opts,
Unknown(u8),
}
impl IpProtocol
{
pub fn is_con... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/token.rs | wasmer-bus/mio/src/model/token.rs | use std::fmt;
use std::str::FromStr;
use serde::*;
use ate_crypto::ChainKey;
use ate_crypto::SerializationFormat;
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct NetworkToken {
pub chain: ChainKey,
pub access_token: String,
}
impl fmt::Display
for NetworkToken
{
fn fmt(&self, f: &mut fmt::Forma... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/model/socket_shutdown.rs | wasmer-bus/mio/src/model/socket_shutdown.rs | use std::fmt;
use serde::*;
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, Serialize, Deserialize)]
pub enum SocketShutdown
{
Read,
Write,
Both,
}
impl fmt::Display
for SocketShutdown {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
use SocketShutdown::*;
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/comms/port.rs | wasmer-bus/mio/src/comms/port.rs |
use std::io;
use std::net::IpAddr;
use std::net::Ipv4Addr;
use std::net::Ipv6Addr;
use std::net::SocketAddr;
use std::sync::Arc;
use std::ops::Deref;
use std::collections::BTreeMap;
#[cfg(feature = "crypto")]
use ate_crypto::EncryptKey;
use chrono::DateTime;
use chrono::Utc;
use tokio::sync::Mutex;
use tokio::sync::mp... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/comms/mod.rs | wasmer-bus/mio/src/comms/mod.rs | mod evt;
mod port;
mod socket;
pub(crate) use port::*;
pub(crate) use socket::*; | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/comms/evt.rs | wasmer-bus/mio/src/comms/evt.rs | use std::net::SocketAddr;
use crate::model::SocketError;
pub struct EventRecv {
pub data: Vec<u8>
}
pub struct EventRecvFrom {
pub peer_addr: SocketAddr,
pub data: Vec<u8>,
}
pub struct EventAccept {
pub peer_addr: SocketAddr,
}
pub struct EventError {
pub error: SocketError
} | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/src/comms/socket.rs | wasmer-bus/mio/src/comms/socket.rs | use std::io;
use std::sync::Arc;
use std::net::SocketAddr;
#[cfg(feature = "crypto")]
use ate_crypto::EncryptKey;
use tokio::sync::mpsc;
use tokio::sync::Mutex;
use mpsc::error::TryRecvError;
use derivative::*;
use wasmer_bus_time::prelude::sleep;
use crate::model::PortCommand;
use crate::model::PortNopType;
use crate... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/mio/examples/ping.rs | wasmer-bus/mio/examples/ping.rs | use std::collections::HashMap;
use std::time::Instant;
use std::time::Duration;
use std::net::IpAddr;
use std::convert::TryInto;
use byteorder::ReadBytesExt;
use byteorder::WriteBytesExt;
use byteorder::LittleEndian;
use wasmer_bus_mio::prelude::*;
#[cfg(target_family = "wasm")]
use wasmer_bus_time::prelude::sleep;
#[... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/macros/src/lib.rs | wasmer-bus/macros/src/lib.rs | #![allow(
clippy::default_trait_access,
clippy::doc_markdown,
clippy::if_not_else,
clippy::items_after_statements,
clippy::module_name_repetitions,
clippy::shadow_unrelated,
clippy::similar_names,
clippy::too_many_lines
)]
extern crate proc_macro;
mod args;
mod convert;
mod method_inpu... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/macros/src/parse.rs | wasmer-bus/macros/src/parse.rs | use proc_macro2::Span;
use syn::parse::{Error, Parse, ParseStream, Result};
use syn::{Attribute, ItemImpl, ItemStruct, ItemTrait, Token};
#[derive(Clone)]
pub enum Item {
Trait(ItemTrait),
Impl(ItemImpl),
Struct(ItemStruct),
}
impl Parse for Item {
fn parse(input: ParseStream) -> Result<Self> {
... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/macros/src/convert.rs | wasmer-bus/macros/src/convert.rs | use crate::args::Args;
use crate::parse::Item;
use convert_case::{Case, Casing};
use proc_macro2::Ident;
use quote::quote;
use syn::parse::Parser;
use syn::{
parse_quote, punctuated::Punctuated, Error, Field, FnArg, PathArguments, Token, TraitItem,
TypeParamBound, TypeTraitObject,
};
use wasmer_bus_types::Seria... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/macros/src/method_inputs.rs | wasmer-bus/macros/src/method_inputs.rs | use syn::parse::{Parse, ParseStream};
use syn::punctuated::Punctuated;
use syn::FnArg;
use syn::*;
pub struct MethodInputs {
pub inputs: Punctuated<MethodInput, Token![,]>,
pub has_self: bool,
}
impl Parse for MethodInputs {
fn parse(input: ParseStream) -> Result<Self> {
let args: Punctuated<FnArg... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/macros/src/args.rs | wasmer-bus/macros/src/args.rs | use proc_macro2::Span;
use std::str::FromStr;
use syn::parse::{Parse, ParseStream, Result};
use syn::{LitStr, Token};
use wasmer_bus_types::SerializationFormat;
pub struct ArgsFormat {
pub format_token: kw::format,
pub eq_token: Token![=],
pub format_val: SerializationFormat,
}
#[derive(Default)]
pub stru... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/macros/src/return_trait.rs | wasmer-bus/macros/src/return_trait.rs | use derivative::*;
use syn::parse::{Parse, ParseStream};
use syn::*;
#[derive(Derivative, Clone)]
#[derivative(Debug)]
pub struct ReturnTrait {
#[derivative(Debug = "ignore")]
pub path: Path,
pub ident: Ident,
#[derivative(Debug = "ignore")]
pub ty: Type,
pub client_name: String,
pub client... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/macros/src/method_output.rs | wasmer-bus/macros/src/method_output.rs | use derivative::*;
use proc_macro2::Span;
use proc_macro2::TokenStream;
use quote::quote;
use syn::parse::{Parse, ParseStream};
use syn::*;
use super::return_trait::*;
#[derive(Debug, Clone)]
pub enum MethodOutput {
Trait(ReturnTrait),
Message(ReturnMessage),
Nothing,
}
impl MethodOutput {
pub fn is_... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/macros/src/receiver.rs | wasmer-bus/macros/src/receiver.rs | use proc_macro2::{Group, Span, TokenStream, TokenTree};
use std::iter::FromIterator;
use syn::visit_mut::{self, VisitMut};
use syn::{
Block, ExprPath, Ident, Item, Macro, Pat, PatIdent, PatPath, Path, Receiver, Signature, Token,
TypePath,
};
#[allow(dead_code)]
pub fn has_self_in_sig(sig: &mut Signature) -> bo... | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
wasmerio/ate | https://github.com/wasmerio/ate/blob/87635b5b49c4163885ce840f4f1c2f30977f40cc/wasmer-bus/hello/src/lib.rs | wasmer-bus/hello/src/lib.rs | use wasmer_bus::macros::*;
#[wasmer_bus(format = "json")]
pub trait World {
async fn hello(&self) -> String;
} | rust | Apache-2.0 | 87635b5b49c4163885ce840f4f1c2f30977f40cc | 2026-01-04T20:14:33.413949Z | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.