I’ve been having trouble trying to deploy a local copy of the internet identity. I followed the steps given in https://github.com/dfinity/internet-identity/blob/main/README.md for running II locally. Specifically, I used dfx start from the /internet_identity folder, followed by II_ENV=development dfx deploy --no-wallet --argument '(null)'. Then I deployed the whoami canister to the same IC replica and started the front end from the demos folder https://github.com/dfinity/internet-identity/tree/main/demos.
I am able to use the “whoami” button to call the canister without issue if I don’t login, but when I try to login I get stuck trying to confirm my device registration for a new II anchor:
I also tried running dfx start from the /internet_identity/demos/whoami folder and then deploying both canisters to that replica. Doing it this way I don’t get stuck but I end up with a 403 (Forbidden) error stating:
Failed to authenticate request 0xb5c4a510754b5da7da2ee92fbc456f62c1dcde311e44e221a2969a30614bda42 due to: Invalid delegation: Invalid public key: Algorithm Placeholder not supported: Unsupported public key
You’re probably trying to use Windows Hello, but your local replica doesn’t support RSA signatures yet. The version of the replica dfx ships probably is too old.
For local testing you can either use a Yubikey (or equivalent) if you have one or Chrome’s Virtual Authenticator. At some point in the future Windows Hello will also work.
The virtual authenticator worked, thank you! Also for reference, this was using dfx 0.8.1 so I guess Windows Hello support hasn’t made it into that replica yet.
Did you run II and app on the same port? Now I get POST http://127.0.0.1:8000/api/v2/canister/r7inp-6aaaa-aaaaa-aaabq-cai/call 404 (Not Found) because I am running on diff port
dfx start --background
# start II first
cd ../internet-identity
rm -rf ./.dfx
II_ENV=development dfx deploy --no-wallet --argument '(null)'
echo "http://localhost:8000?canisterId=$(dfx canister id internet_identity)"
# II canister has rk4pc... canisterId in this setup
# deploy my app
cd ../my-app
dfx deploy
open http://localhost:8000?canisterId=$(dfx canister id my-app) # opens deployed application not in dev-mode