I can\'t find any official way to get a UUID string back out of a CBUUID. These UUIDs can be 2 or 16 bytes long.
The goal is to store CBUUIDs in a file somewhere as
To all those saying that CBUUID is toll-free bridged with CFUUIDRef, it's not.
CBUUID * foo = [CBUUID UUIDWithString:CBUUIDCharacteristicExtendedPropertiesString];
CFStringRef fooBar = CFUUIDCreateString(NULL, (__bridge CFUUIDRef)foo);
if (![CBUUIDCharacteristicExtendedPropertiesString isEqualToString:(__bridge NSString *)fooBar])
NSLog(@"fubar!");
It's not crashing but you're getting garbage out. It's probably uniquely identifying garbage, but it can't be round-tripped.
PS: This didn't work as a comment because SO comments oddly don't allow code formatting.