We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents f03fd66 + 8bcf97a commit 132f5b2Copy full SHA for 132f5b2
Sources/CryptoSwift/RSA/RSA.swift
@@ -61,7 +61,7 @@ public final class RSA: DERCodable {
61
public let keySizeBytes: Int
62
63
/// The underlying primes used to generate the Private Exponent
64
- private let primes: (p: BigUInteger, q: BigUInteger)?
+ public let primes: (p: BigUInteger, q: BigUInteger)?
65
66
/// Initialize with RSA parameters
67
/// - Parameters:
@@ -388,7 +388,7 @@ extension RSA {
388
/// ```
389
///
390
public func externalRepresentation() throws -> Data {
391
- if self.primes != nil {
+ if self.d != nil {
392
return try Data(self.privateKeyDER())
393
} else {
394
return try Data(self.publicKeyDER())
0 commit comments