line / flutter_line_sdk

A Flutter plugin that lets developers access LINE's native SDKs in Flutter apps with Dart.
https://developers.line.biz/
Apache License 2.0
213 stars 42 forks source link

How to get email when using api for retrieving and verifying tokens? #100

Closed gitprats closed 2 months ago

gitprats commented 4 months ago

Is it a security issue?

No

What did you do?

Cal Line api to get idtoken and verify it

What did you expect?

firstname, lastname, email in the token

What happened actually?

Token only contains name as below:

iss:https://access.line.me sub:Ud1699a5d7fc9f2e0796189181d68c5a0 aud:2004784545 exp:1714720722 iat:1714717122 nonce:O_FLYKAQP6I3rfAG4UJtNfacdeCpc1Eu amr:[] 1 item name:Siya Sharma

Your environment?

Sample project

It would be appreciated if you can provide a link to or update a sample project that we can download and reproduce the issue.

onevcat commented 3 months ago

Hi,

To get the email information in the ID Token, you need to apply for it first. Please check the documentation here:

https://developers.line.biz/en/docs/line-login-sdks/ios-sdk/swift/managing-users/#apply-for-email-permission