Skip to content

Commit

Permalink
Merge pull request #500 from dashpay/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
pankcuf authored Jul 11, 2023
2 parents dd0a8e3 + dd03f7c commit 0a98b4c
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ + (instancetype)blockchainIdentityECDSAKeysDerivationPathForChain:(DSChain *)cha
+ (instancetype)blockchainIdentityBLSKeysDerivationPathForChain:(DSChain *)chain {
UInt256 indexes[] = {uint256_from_long(FEATURE_PURPOSE), uint256_from_long(chain_coin_type(chain.chainType)), uint256_from_long(FEATURE_PURPOSE_IDENTITIES), uint256_from_long(FEATURE_PURPOSE_IDENTITIES_SUBFEATURE_AUTHENTICATION), uint256_from_long(1)};
BOOL hardenedIndexes[] = {YES, YES, YES, YES, YES};
DSAuthenticationKeysDerivationPath *blockchainIdentityBLSKeysDerivationPath = [DSAuthenticationKeysDerivationPath derivationPathWithIndexes:indexes hardened:hardenedIndexes length:5 type:DSDerivationPathType_MultipleUserAuthentication signingAlgorithm:/*[chain activeBLSType]*/KeyKind_BLS reference:DSDerivationPathReference_BlockchainIdentities onChain:chain];
DSAuthenticationKeysDerivationPath *blockchainIdentityBLSKeysDerivationPath = [DSAuthenticationKeysDerivationPath derivationPathWithIndexes:indexes hardened:hardenedIndexes length:5 type:DSDerivationPathType_MultipleUserAuthentication signingAlgorithm:KeyKind_BLS reference:DSDerivationPathReference_BlockchainIdentities onChain:chain];
blockchainIdentityBLSKeysDerivationPath.shouldStoreExtendedPrivateKey = YES;
blockchainIdentityBLSKeysDerivationPath.usesHardenedKeys = YES;
return blockchainIdentityBLSKeysDerivationPath;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -958,8 +958,13 @@ - (void)presentController:(UIViewController *)controller
animated:(BOOL)animated
completion:(void (^_Nullable)(void))completion {
UIWindow *window = [UIWindow keyWindow];

UIViewController *presentingController = [window ds_presentingViewController];
NSParameterAssert(presentingController);

//NOTE: Make sure we present anything on top of the current context
controller.modalPresentationStyle = UIModalPresentationOverFullScreen;

[presentingController presentViewController:controller animated:animated completion:completion];
}
#endif
Expand Down
4 changes: 3 additions & 1 deletion DashSync/shared/Models/Masternode/DSLocalMasternode.m
Original file line number Diff line number Diff line change
Expand Up @@ -455,7 +455,9 @@ - (void)registrationTransactionFundedByAccount:(DSAccount *)fundingAccount toAdd
} else {
platformNodeKey = [platformNodeKeysDerivationPath privateKeyAtIndex:self.platformNodeWalletIndex fromSeed:seed];
}
UInt160 platformNodeID = [DSKeyManager publicKeyData:platformNodeKey].hash160;

UInt256 platformNodeHash = [DSKeyManager publicKeyData:platformNodeKey].SHA256;
UInt160 platformNodeID = *(UInt160 *)&platformNodeHash;

OpaqueKey *ownerKey;
if (self.ownerWalletIndex == UINT32_MAX) {
Expand Down

0 comments on commit 0a98b4c

Please sign in to comment.