Skip to content

Commit

Permalink
anchor: add security_txt (#365)
Browse files Browse the repository at this point in the history
  • Loading branch information
yurushao authored Jan 12, 2025
1 parent aea9157 commit 7fe537c
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 0 deletions.
1 change: 1 addition & 0 deletions anchor/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 anchor/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ anchor-lang = { version = "0.30.1", features = [
] }
anchor-spl = { version = "0.30.1", features = ["stake"] }
solana-program = "=1.18.23"
solana-security-txt = "1.1.1"

spl-transfer-hook-interface = "0.6.5"
spl-tlv-account-resolution = "0.6.5"
Expand Down
1 change: 1 addition & 0 deletions anchor/programs/glam/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ idl-build = ["mainnet", "anchor-lang/idl-build", "anchor-spl/idl-build"]
anchor-lang = { workspace = true }
anchor-spl = { workspace = true }
solana-program = { workspace = true }
solana-security-txt = { workspace = true }

spl-transfer-hook-interface = { workspace = true }
spl-tlv-account-resolution = { workspace = true }
Expand Down
1 change: 1 addition & 0 deletions anchor/programs/glam/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
pub mod constants;
pub mod error;
pub mod instructions;
pub mod security_txt;
pub mod state;

use crate::instructions::{state as glam_state, *};
Expand Down
14 changes: 14 additions & 0 deletions anchor/programs/glam/src/security_txt.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
pub mod security {
use solana_security_txt::security_txt;

#[cfg(not(feature = "no-entrypoint"))]
security_txt! {
name: "GLAM Protocol",
project_url: "https://www.glam.systems/",
policy: "https://gui.glam.systems/vault/disclaimer",
contacts: "email: [email protected]",
preferred_languages: "en",
source_release: "v0.4.0",
source_code: "https://github.com/glamsystems/glam"
}
}

0 comments on commit 7fe537c

Please sign in to comment.