-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #11 from torusresearch/feat/argentweb3
Feat/argentweb3
- Loading branch information
Showing
445 changed files
with
1,254 additions
and
134,622 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,37 @@ | ||
// swift-tools-version:5.1 | ||
// swift-tools-version:5.2 | ||
// The swift-tools-version declares the minimum version of Swift required to build this package. | ||
|
||
import PackageDescription | ||
|
||
let package = Package( | ||
name: "TorusUtils", | ||
platforms: [ | ||
.iOS(.v13), | ||
], | ||
products: [ | ||
.library( | ||
name: "TorusUtils", | ||
targets: ["TorusUtils"]), | ||
], | ||
dependencies: [ | ||
.package(url: "https://github.com/rathishubham7/web3swift", from:"2.0.0"), | ||
.package(url: "https://github.com/rathishubham7/swift-logger", from:"0.0.1"), | ||
.package(url: "https://github.com/torusresearch/fetch-node-details-swift", from:"0.1.0"), | ||
.package(url: "https://github.com/PromiseKit/Foundation.git", from: "3.0.0"), | ||
.package(url: "https://github.com/IBM-Swift/BlueECC.git", from: "1.2.4"), | ||
// .package(url: "https://github.com/skywinder/web3swift", .branch("master")), | ||
.package(name:"BestLogger", url: "https://github.com/rathishubham7/swift-logger", from:"0.0.1"), | ||
// .package(name:"FetchNodeDetails", path: "../fetch-node-details-swift"), | ||
.package(name:"PromiseKit", url: "https://github.com/mxcl/PromiseKit.git", from: "6.0.0"), | ||
.package(name:"PMKFoundation", url: "https://github.com/PromiseKit/Foundation.git", from: "3.0.0"), | ||
.package(name:"CryptorECC", url: "https://github.com/IBM-Swift/BlueECC.git", from: "1.2.4"), | ||
.package(name:"CryptoSwift", url: "https://github.com/krzyzanowskim/CryptoSwift.git", from: "1.0.0"), | ||
.package(name:"jwt-kit", url: "https://github.com/vapor/jwt-kit.git", from: "4.0.0"), | ||
.package(name:"FetchNodeDetails", url: "https://github.com/torusresearch/fetch-node-details-swift", .branch("feat/argentweb3")), | ||
.package(name:"web3.swift", url: "https://github.com/argentlabs/web3.swift", from:"0.7.0"), | ||
.package(name:"secp256k1", url: "https://github.com/Boilertalk/secp256k1.swift", from: "0.1.0"), | ||
], | ||
targets: [ | ||
// Targets are the basic building blocks of a package. A target can define a module or a test suite. | ||
// Targets can depend on other targets in this package, and on products in packages which this package depends on. | ||
.target( | ||
name: "TorusUtils", | ||
dependencies: ["FetchNodeDetails", "web3swift", "PMKFoundation", "CryptorECC", "BestLogger"]), | ||
dependencies: [.product(name: "FetchNodeDetails", package: "FetchNodeDetails"), "CryptoSwift", "web3.swift", "CryptorECC", "secp256k1", "PMKFoundation", "PromiseKit", "BestLogger"]), | ||
.testTarget( | ||
name: "torus-utils-swiftTests", | ||
dependencies: ["TorusUtils"]), | ||
dependencies: ["TorusUtils", .product(name: "JWTKit", package: "jwt-kit"), .product(name: "FetchNodeDetails", package: "FetchNodeDetails"), "web3.swift", "PMKFoundation", "PromiseKit", "CryptorECC", "BestLogger"]), | ||
] | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
// | ||
// File.swift | ||
// | ||
// | ||
// Created by Shubham on 1/8/21. | ||
// | ||
|
||
import Foundation | ||
import PromiseKit | ||
import FetchNodeDetails | ||
|
||
public protocol AbstractTorusUtils { | ||
|
||
func setTorusNodePubKeys(nodePubKeys: Array<TorusNodePub>) | ||
|
||
func retrieveShares(endpoints : Array<String>, verifierIdentifier: String, verifierId:String, idToken: String, extraParams: Data) -> Promise<[String:String]> | ||
|
||
func getPublicAddress(endpoints : Array<String>, torusNodePubs : Array<TorusNodePub>, verifier : String, verifierId : String, isExtended: Bool) -> Promise<[String:String]> | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.