Uniquely identifying an iOS user

后端 未结 10 1934
小蘑菇
小蘑菇 2020-12-02 12:27

I\'d like to create a user account on the server for new users of an app, but I\'d also like to not ask the user to type in anything. Ideally, I\'d like this to be automatic

10条回答
  •  孤街浪徒
    2020-12-02 12:57

    It is not an absolute sure solution (and only works when iCloud enabled), but it is very easy to implement: Generate a unique ID once (like UUID) and store it in iCloud key-value-storage.

    The only problem is that advanced users know how to delete content from the iCloud.

    To prevent the user just editing the unique ID stored in iCloud to someone else ID you can add some kind of secret to.

提交回复
热议问题