Open pankajjha opened 1 year ago
I found the problem
jwt.sign({}, this._key, {
algorithm: 'ES256',
keyid: this._keyID,
expiresIn: this._clientSecretExpiry,
issuer: this._teamID,
audience: 'https://appleid.apple.com',
subject: this._clientID
})
It seems jwt.sign function doesn't respect key file path and needs literal key
when I changed .env APPLE_KEYFILE_PATH
from ./location/keyfile.p8
to "-----BEGIN PRIVATE KEY-----\nsdad...\nasda...\n-----END PRIVATE KEY-----
it started to work just fine
login/apple/redirect remove @UseGuards(AuthGuard("apple")) work for me
...
@Post('login/apple/redirect')
async appleAuthRedirect(@Body() body, @Req() req, @Res() res) {
try{
console.log(req, body)
} catch(e) {
console.log(e)
}
}
Hi, I am getting this error on my callback function
Node:
v16.19.1
@arendajaelu/nestjs-passport-apple:^1.0.4
@nestjs/core:^9.1.2
Getting
Error: error:0909006C:PEM routines:get_name:no start line
Here's complete exception
Here's my Callback url function