Accessing SMS Content iPhone

天大地大妈咪最大 提交于 2020-01-03 03:17:12

问题


I want to confirm if it is allowed to access the SMS content programatically. Are developers allowed to access the content of incoming/outgoing SMS's in the iPhone?

Can I access the incoming/outgoing sms messages and retrieve the information related to them e.g sms sent by, sent to,body, time etc using my custom built application.


回答1:


No you cannot do so through public API.

You may have luck with private API and jailbreak, but I'd guess this is not what allowed means here.




回答2:


The Apple Dev Library says, "In iOS 4.0 and later, you can send text messages from within your application. This feature is strictly for sending messages. Incoming SMS messages go to the built-in Messages app." I wish they would explain why they won't allow programs to access messages.

So not with an iPhone app, apparently, but you can access them with a desktop app. See here.

"Apple saves your text messages in its iPhone backups, whether they’re saved locally on your PC or whether they’re part of an iCloud backup — which you should have. That’s good! Unfortunately, they’re not separated out. However, you can access them through the filesystem. If you back up locally on an Apple machine, you can find the file under Library > Application Support > MobileSync > Backup. There should be multiple folders there, each with a different backup image of your phone. Each of the folders should have a file named ” 3d0d7e5fb2ce288813306e4d4636395e047a3d28.mddata.” Those are your texts, in SQLite database form."

You'll need to use SQLite to decipher the file. There are some instructions here:

How to Access and Read the iPhone SMS Text Message Backup Files.



来源:https://stackoverflow.com/questions/3533938/accessing-sms-content-iphone

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!