Skip to content

Commit e15bc91

Browse files
committed
Add cosmwasm_2_1 capability
1 parent 37f1e95 commit e15bc91

File tree

5 files changed

+9
-3
lines changed

5 files changed

+9
-3
lines changed

docs/CAPABILITIES-BUILT-IN.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,5 @@ might define others.
2525
`1.4.0` or higher support this.
2626
- `cosmwasm_2_0` enables `CosmosMsg::Any` and `QueryRequest::Grpc`. Only chains
2727
running CosmWasm `2.0.0` or higher support this.
28+
- `cosmwasm_2_1` enables secp256r1 and BLS12-381 signature verification. Only
29+
chains running CosmWasm `2.1.0` or higher support this.

packages/check/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use cosmwasm_vm::capabilities_from_csv;
1111
use cosmwasm_vm::internals::{check_wasm, compile, make_compiling_engine};
1212

1313
const DEFAULT_AVAILABLE_CAPABILITIES: &str =
14-
"iterator,staking,stargate,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0";
14+
"iterator,staking,stargate,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0,cosmwasm_2_1";
1515

1616
pub fn main() {
1717
let matches = Command::new("Contract checking")

packages/std/src/exports.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,10 @@ extern "C" fn requires_cosmwasm_1_4() -> () {}
6565
#[no_mangle]
6666
extern "C" fn requires_cosmwasm_2_0() -> () {}
6767

68+
#[cfg(feature = "cosmwasm_2_1")]
69+
#[no_mangle]
70+
extern "C" fn requires_cosmwasm_2_1() -> () {}
71+
6872
/// interface_version_* exports mark which Wasm VM interface level this contract is compiled for.
6973
/// They can be checked by cosmwasm_vm.
7074
/// Update this whenever the Wasm VM interface breaks.

packages/vm/examples/heap_profiling.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ fn app(runtime: u64) {
106106

107107
let options = CacheOptions::new(
108108
TempDir::new().unwrap().into_path(),
109-
capabilities_from_csv("iterator,staking,stargate,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0"),
109+
capabilities_from_csv("iterator,staking,stargate,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0,cosmwasm_2_1"),
110110
MEMORY_CACHE_SIZE,
111111
DEFAULT_MEMORY_LIMIT,
112112
);

packages/vm/src/testing/instance.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ impl MockInstanceOptions<'_> {
9797
fn default_capabilities() -> HashSet<String> {
9898
#[allow(unused_mut)]
9999
let mut out = capabilities_from_csv(
100-
"iterator,staking,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0",
100+
"iterator,staking,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0,cosmwasm_2_1",
101101
);
102102
#[cfg(feature = "stargate")]
103103
out.insert("stargate".to_string());

0 commit comments

Comments
 (0)