Skip to content
Permalink
Browse files

returns error 'UserRefusedAllowManager' out of the genuine check

  • Loading branch information...
gre committed Mar 5, 2019
1 parent a5a33b4 commit bb00a8c177e91407dc4469c1b649870360133e1a
Showing with 11 additions and 5 deletions.
  1. +9 −4 src/api/Manager.js
  2. +2 −1 src/api/socket.js
@@ -3,14 +3,15 @@

import URL from "url";
import {
DeviceOnDashboardExpected,
LatestMCUInstalledError,
ManagerDeviceLockedError,
UserRefusedFirmwareUpdate,
ManagerNotEnoughSpaceError,
ManagerAppAlreadyInstalledError,
ManagerAppRelyOnBTCError,
ManagerDeviceLockedError,
ManagerNotEnoughSpaceError,
ManagerUninstallBTCDep,
DeviceOnDashboardExpected
UserRefusedAllowManager,
UserRefusedFirmwareUpdate
} from "@ledgerhq/errors";
import type Transport from "@ledgerhq/hw-transport";
import { throwError, Observable } from "rxjs";
@@ -312,6 +313,10 @@ const genuineCheck = (
requested = true;
}, ALLOW_MANAGER_APDU_DEBOUNCE);
} else if (e.type === "exchange") {
if (e.status.toString("hex") === "6985") {
o.error(new UserRefusedAllowManager());
return;
}
if (requested) {
o.next({ type: "allow-manager-accepted" });
}
@@ -46,7 +46,8 @@ export type SocketEvent =
type: "exchange",
nonce: number,
apdu: Buffer,
data: Buffer
data: Buffer,
status: Buffer
}
| {
type: "opened"

0 comments on commit bb00a8c

Please sign in to comment.
You can’t perform that action at this time.