Is there a way to to check if a picture was taken on that iPhone

0 votes
I wanted to know whether there was a way to verify whether a photo was taken on the user's iPhone. Is there any kind of metadata on the picture that would only have been created on an iPhone? I'm looking for a method to determine whether photographs were taken exclusively with an iPhone 6 and on that device.
Sep 21, 2022 in IOS by Soham
• 9,700 points
360 views

1 answer to this question.

0 votes

Actually, the model and manufacturer information is stored in the TIFF data rather than the EXIF data (at least on the iPhone). If the TIFF data is present, then follow these instructions to extract that data, more especially the model, as a string:

NSString *myPath = [[NSBundle mainBundle] pathForResource:@"IMG_0002" ofType:@"jpg"];
NSURL *myURL = [NSURL fileURLWithPath:myPath];
CGImageSourceRef sourceRef = CGImageSourceCreateWithURL((CFURLRef)myURL, NULL);

NSDictionary *metadata = (__bridge id)CGImageSourceCopyPropertiesAtIndex(sourceRef, 0, NULL);
NSDictionary *TIFFdata = [metadata objectForKey:(__bridge id)kCGImagePropertyTIFFDictionary];
NSString *model = [TIFFdata objectForKey:(__bridge id)kCGImagePropertyTIFFModel];

The model number on my iPhone 5S is "iPhone 5S," so you can probably anticipate that it will be "iPhone 6" on an iPhone 6.

NOTICE: If you have the image as a UIImage, avoid obtaining the data by performing UIImageJPEGRepresentation because you will lose much of the TIFF as well as a significant amount of metadata.

answered Sep 22, 2022 by Rahul
• 9,670 points

Related Questions In IOS

0 votes
1 answer

Is there a way to generate high resolution PNGs of iOS emoji?

The glyphs for the "Apple Color Emoji" ...READ MORE

answered Sep 20, 2022 in IOS by Aditya
• 7,680 points
1,955 views
0 votes
1 answer

Is it possible to run .APK/Android apps on iPad/iPhone devices?

It is not possible to run Android ...READ MORE

answered Sep 20, 2022 in IOS by Aditya
• 7,680 points
3,896 views
0 votes
0 answers

How to connect iphone to a local server running on mac?

I am running a django server at ...READ MORE

Sep 22, 2022 in IOS by Soham
• 9,700 points
507 views
0 votes
0 answers

How to access and read a file on a USB drive from IOS? (Connected via OTG cable to iPhone)

Can I access a text file on ...READ MORE

Nov 7, 2022 in IOS by Soham
• 9,700 points
330 views
0 votes
1 answer

Getting country calling prefix

For a class that offers both this ...READ MORE

answered Sep 20, 2022 in Others by Aditya
• 7,680 points
572 views
0 votes
1 answer

Detect if the device is iPhone X

The response to your query is "no" ...READ MORE

answered Nov 8, 2022 in IOS by Rahul
• 9,670 points
651 views
0 votes
0 answers

How to receive single tap and hold Remote-Control Event with iOS

I'm looking for my app to listen ...READ MORE

Nov 8, 2022 in Mobile Development by gaurav
• 23,260 points
192 views
0 votes
0 answers

How to use iOS Reachability

I'm developing an iPhone app that uses ...READ MORE

Nov 9, 2022 in Mobile Development by gaurav
• 23,260 points
334 views
0 votes
1 answer

How is a rounded rect view with transparency done on iphone?

view.layer.cornerRadius = radius; The difficult technique is to ...READ MORE

answered Sep 22, 2022 in IOS by Rahul
• 9,670 points
408 views
0 votes
1 answer

How to get rid of blank space from iPhone notch on web page

You should be looking for the meta-setting ...READ MORE

answered Nov 8, 2022 in IOS by Rahul
• 9,670 points
1,318 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP