Skip to content

Commit 969030e

Browse files
committed
chore: remove self sign-in on ic_name_identity
1 parent eac937a commit 969030e

File tree

3 files changed

+20
-6
lines changed

3 files changed

+20
-6
lines changed

proposals/proposal-275.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,4 @@ quill sns make-proposal --canister-ids-file ./sns_canister_ids.json --pem-file $
2222
}
2323
)" > proposal-message.json
2424

25-
quill send proposal-message.json
25+
# quill send proposal-message.json

proposals/proposal-276.sh

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/usr/bin/env bash
2+
3+
# Load the environment variables
4+
source "$(pwd)"/proposals/env.sh
5+
6+
quill sns make-proposal --canister-ids-file ./sns_canister_ids.json --pem-file $PROPOSAL_PEM_FILE $PROPOSAL_NEURON_ID --proposal '(
7+
record {
8+
title = "Register ic_name_identity canister";
9+
url = "https://github.com/ldclabs/ic-oss";
10+
summary = "DMSG canisters: ic_name_identity.\n\nRefer: https://github.com/ldclabs/ic-panda/blob/main/canister_ids.json";
11+
action = opt variant {
12+
RegisterDappCanisters = record {
13+
canister_ids = vec {principal "2rgax-kyaaa-aaaap-anvba-cai"};
14+
}
15+
};
16+
}
17+
)' > proposal-message.json
18+
19+
# quill send proposal-message.json

src/ic_name_identity/src/api.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -122,11 +122,6 @@ fn sign_in(name: String, pubkey: ByteBuf, sig: ByteBuf) -> Result<SignInResponse
122122
.map_err(|err| format!("challenge verification failed: {:?}", err))?;
123123

124124
let user_key = CanisterSigPublicKey::new(ic_cdk::id(), name.as_bytes().to_vec());
125-
let id = Principal::self_authenticating(user_key.to_der().as_slice());
126-
if id != caller {
127-
store::state::delegator_sign_in(&name, &caller, now_ms)?;
128-
}
129-
130125
let session_expires_in_ms = store::state::with_mut(|state| {
131126
state.sign_in_count = state.sign_in_count.saturating_add(1);
132127
state.session_expires_in_ms

0 commit comments

Comments
 (0)