سؤال

Does APNS or GCM device tokens have any special characters in them? we are trying to do server side validation of the tokens and need to know if we should just check for a-z0-9 and eliminate everything else?

هل كانت مفيدة؟

المحلول

APNS device tokens are 32 bytes in binary format. If you choose to represent them as 64 hexadecimal characters, then they would contain just the hexadecimal characters (0 to 9 and A to F).

As for GCM Registration IDs, even though Google don't give any rules regarding possible characters, from what I observed, they use only 64 characters - A to Z, a to Z, 0 to 9, '-' and '_'.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top