Slide 1

Slide 1 text

Sign In with Apple 2019/06/19 Takeshi Ihara

Slide 2

Slide 2 text

Takeshi Ihara • 2018.09.01 AbemaTV Join • ϘϧμϦϯάͱ֨ಆήʔϜ͕झຯ • https://github.com/Nonchalant • https://twitter.com/nonchalant0303

Slide 3

Slide 3 text

ؔ࿈ηογϣϯ • Introducing Sign In with Apple (Session 706) • What’s New in Authentication, Safari, and WebKit (Session 504)

Slide 4

Slide 4 text

ࠓ೔࿩͢͜ͱ • Sign In with Apple ͱ͸ • Sign In with Apple ͷߏ଄ • LabͰ࣭໰͖ͯͨ͜͠ͱ

Slide 5

Slide 5 text

ࠓ೔࿩͞ͳ͍͜ͱ • Sign In with Apple ͷ࣮૷ํ๏ ɾhttps://developer.apple.com/documentation/authenticationservices ɾhttps://developer.apple.com/documentation/signinwithapplejs

Slide 6

Slide 6 text

Sign In with Apple ͱ͸

Slide 7

Slide 7 text

No content

Slide 8

Slide 8 text

Sign In with Apple ͱ͸ • Respect for privacy ɾ໊લͱϝʔϧΞυϨε͔͠औಘͰ͖ͳ͍ ɾαʔϏε͝ͱʹPrivateͳϝʔϧΞυϨεΛൃߦՄೳ ɾApple͸αʔϏε಺ͷߦಈΛ௥੻͠ͳ͍

Slide 9

Slide 9 text

Sign In with Apple ͱ͸ • Security Built in ɾ2ஈ֊ೝূΛઃఆ͍ͯ͠ΔApple IDͷΈར༻Մೳ ɾAppleσόΠεͰ͸Face ID or Touch IDͰαΠϯΠϯՄೳ

Slide 10

Slide 10 text

Sign In with Apple ͱ͸ • Works everywhere ɾiOS, macOS, tvOS, watchOS, ϒϥ΢βͰಈ࡞Մೳ

Slide 11

Slide 11 text

Sign In with Apple ͱ͸ • Antifraud ɾσόΠε্ͷػցֶश΍ͦͷଞͷ৘ใʹΑͬͯɺ ৽͍͠Ϣʔβʔ͕ਓ͔Bot͔Λ൑ผ͢Δ ɾϨεϙϯεʹؚ·Ε͍ͯΔ৘ใΛࢀߟʹͰ͖Δ

Slide 12

Slide 12 text

iOS 13ͷϦϦʔεͱಉ࣌ʹར༻Մೳ (2019.09)

Slide 13

Slide 13 text

Sign In with Apple ͷߏ଄

Slide 14

Slide 14 text

Sign In with Apple ͷߏ଄ 1. Sign In with Apple 2. Ϣʔβʔ৘ใΛཁٻ 3. Ϣʔβʔࣝผࢠͱ৘ใ 5. ΞΧ΢ϯτ 4. Ϣʔβʔࣝผࢠʹج͍ͮͯΞΧ΢ϯτ࡞੒

Slide 15

Slide 15 text

Sign In with Apple ͷߏ଄ 1. Sign In with Apple JS 2. Ϣʔβʔ৘ใΛཁٻ 5. ΞΧ΢ϯτ 4. Ϣʔβʔࣝผࢠʹج͍ͮͯΞΧ΢ϯτ࡞੒ 3. ࢦఆͨ͠URLʹϦμΠϨΫτ

Slide 16

Slide 16 text

App ID App ID App ID Apple Developer Team • ڞ௨ͷUserࣝผࢠ • PrivateͳEmailΞυϨεʹૹ৴ՄೳͳυϝΠϯ·ͨ͸ݸผΞυϨε • OAuth΍OpenID ConnectͷΑ͏ͳೝূن֨ͷKey܈

Slide 17

Slide 17 text

Service ID Apple Developer Team Primary App ID App ID • ڞ௨ͷServiceࣝผࢠ • ServiceࣝผࢠΛ༻͍ͯϒϥ΢βͰαΠϯΠϯՄೳ • Serviceຖʹڞ௨ͷPrivateͳEmailΞυϨε ϒϥ΢β (ొ࿥ෆཁ) App ID • ୯ҰͷAppͷ৔߹͸Service IDෆཁ • PrivateͳEmailΞυϨε • ڞ௨ͷUserࣝผࢠ • PrivateͳEmailΞυϨεʹૹ৴ՄೳͳυϝΠϯ·ͨ͸ݸผΞυϨε • OAuth΍OpenID ConnectͷΑ͏ͳೝূن֨ͷKey܈

Slide 18

Slide 18 text

• Apple Developer (چ iOS Dev Center) Sign In with Apple ͷߏ଄

Slide 19

Slide 19 text

Lab Ͱ࣭໰͖ͯͨ͜͠ͱ

Slide 20

Slide 20 text

Lab Ͱ࣭໰͖ͯͨ͜͠ͱ • PrivateͳΞυϨεʹϝʔϧΛૹ৴͢Δํ๏ • PrivateͳΞυϨεͷRevoke • Sign In with Apple JS ͰͷϢʔβʔ৘ใͷऔΓํ • 3rd PartyϩάΠϯͷϘλϯΑΓ্ʹஔ͔ͳ͍৔߹͸ϦδΣΫτର৅͔ʁ • 3rd PartyϩάΠϯΛαϙʔτ͍ͯ͠ΔΞϓϦͰɺSign In with Apple Λαϙʔ τ͠ͳ͍৔߹͸ϦδΣΫτର৅͔ʁ • AuthenticationServices.ASFoundationͱ͸ͳʹ͔ʁ

Slide 21

Slide 21 text

Lab Ͱ࣭໰͖ͯͨ͜͠ͱ (akatsuki174) • ΞΧ΢ϯτΛෳ਺࣋ͯΔαʔϏεͰ͸Ͳ͏ରԠ͢Ε͹Α͍͔ • Sign In with AppleͰαΠϯΠϯͨ͠ޙʹ೥ྸͳͲΛ௥ՃͰऔಘ͢Δͷ͸ΞϦ ͳͷ͔ʁ

Slide 22

Slide 22 text

PrivateͳΞυϨεʹϝʔϧΛૹ৴͢Δํ๏ • Apple Developer Ͱࣄલʹొ࿥ͨ͠υϝΠϯ·ͨ͸ΞυϨεͰૹΕΔ • ૹ৴ऀͱड৴ऀ͕ಉҰͩͱૹΕͳ͍ • Sign In with Apple Λෳ਺ͨ͠ͱ͖ʹɺ࠷ॳʹੜ੒͞ΕͨΞυϨεͷΈ༗ޮ ɾຖճಉ͡ΞυϨε͕ੜ੒͞ΕΔΑ͏ʹमਖ਼͞Εͯ·ͨ͠ (2019.06.19)

Slide 23

Slide 23 text

PrivateͳΞυϨεͷRevoke • ઃఆΞϓϦ·ͨ͸ϒϥ΢β͔ΒService୯ҐͰRevokeՄೳ ɾhttps://appleid.apple.com

Slide 24

Slide 24 text

Sign In with Apple JS ͰͷϢʔβʔ৘ใͷऔΓํ • ·ͩఏڙ͍ͯ͠ͳ͍ (2019.06.19)

Slide 25

Slide 25 text

3rd PartyϩάΠϯͷϘλϯΑΓ্ʹஔ͔ͳ͍৔߹͸
 ϦδΣΫτର৅͔ʁ • In a stacked layout, place the Sign In with Apple button above the other buttons. ɾhttps://developer.apple.com/design/human-interface-guidelines/sign-in-with-apple/overview/ • HIG͔Β্هจݴ͕࡟আ͞Ε͍ͯ·ͨ͠ (2019.06.19)

Slide 26

Slide 26 text

3rd PartyϩάΠϯΛαϙʔτ͍ͯ͠ΔΞϓϦͰɺ Sign In with Apple Λαϙʔτ͠ͳ͍৔߹͸ϦδΣΫτର৅͔ʁ • ·ܾͩΊ͍ͯͳ͍ (2019.06.05)

Slide 27

Slide 27 text

AuthenticationServices.ASFoundationͱ͸ͳʹ͔ʁ • Foundationͱͷ಺෦௨৴Ϋϥε • Jump to DefinitionͰ͖ͳ͍

Slide 28

Slide 28 text

ΞΧ΢ϯτΛෳ਺࣋ͯΔαʔϏεͰ͸Ͳ͏ରԠ͢Ε͹Α͍͔ • ͻͱͭͷApple IDͰෳ਺ΞΧ΢ϯτͷ࡞੒Λαϙʔτ͍ͯ͠ͳ͍ ɾαʔϏεଆͰղܾ͢Δ͔͠ͳͦ͞͏

Slide 29

Slide 29 text

Sign In with AppleͰαΠϯΠϯͨ͠ޙʹ೥ྸͳͲΛ௥ՃͰऔಘ͢Δ ͷ͸ΞϦͳͷ͔ʁ • αʔϏεͱͯ͠ඞཁͳ৘ใ͸ͱͬͯ΋Α͍ɺFacebook࿈ܞͳͲ΋ಉ༷ • Sign In with Apple ͸͋͘·ͰαΠϯΠϯͷखஈ

Slide 30

Slide 30 text

Thank you

Slide 31

Slide 31 text

iOSDC 2019 • ಈըΞϓϦͷ౤͛મػೳʹ͓͚Δ
 ফ໣ܕ՝ۚͷ࢓૊Έͱ࣮૷ • https://twitter.com/nonchalant0303 ͷݻఆπΠ