             }
 
             let jwt = try JWT(token: token)
-            let key = try self.fetchSigningKey(for: jwt.headers.extract("kid") as String)
-
+            let certificate = try self.fetchSigningKey(for: jwt.headers.extract("kid") as String)
+            let signer = try Certificate_RS256(certificate: certificate)
+            
             // TODO : IssuedAtClaim should be in the past
-
-            let signer = try RS256(key: key.bytes)
-
             let claims = [ExpirationTimeClaim(createTimestamp: { return Seconds(Date().timeIntervalSince1970) }, leeway: 60),
                           AudienceClaim(string: "polymyr-a5014"),
                           IssuerClaim(string: "https://securetoken.google.com/polymyr-a5014"),

    init(subject: String, request: Request) throws
}

final class AuthenticationCollection {
    
    typealias AuthenticationSubject = Entity & Authenticatable & JWTInitializable & NodeConvertible & Persistable

import Node
import JWT
import AuthProvider
import CTLS
import Crypto

enum SessionType: String, TypesafeOptionsParameter {
    case customer
