iPhone application – reading SMS
Asked Answered
N

3

15

I need to develop an iPhone application which needs to read the incoming SMS received by the user, manipulate the text, and then display it in the application.

Could someone clarify whether it is possible to read the SMS received within our application development?

Thanks!

Nibbs answered 7/9, 2010 at 7:49 Comment(0)
P
20

Intercepting/reading incoming SMS is not possible on iOS (for privacy reasons).

Photocompose answered 18/1, 2011 at 20:16 Comment(6)
Yes it is possible to intercept SMS ... when the phone is jailbreaked.Memorial
i wan to read SMS but my device is not Jailbreak. I dont want to upload that app to App Store so it is possible or not ?Legendary
My Device is jailbreak, but still I can't access this sms.db file. It's required root permission. How can I give a root permission.Creighton
@mohit : the easiest way is to give your app setuid root when installing it. Every time the user will start it, it will execute with root privileges.Memorial
@Mads Mobaek, Do you have any links to official documentation by Apple on this? I couldn't find anyPert
@Mads, i know its been i while but is it now possible to read incoming sms's on iphone?Shuttering
R
14

It is only possible when the phone is Jailbreaked. There are many tools to jailbreak your phone.

Once Jailbreaked, an application cal open the SQLite database at

/var/mobile/Library/SMS/sms.db

and read the message table.

It contains, the date/time at which the message was received, the sender/recipient phone number and even the clear text of the message.

Rhythmics answered 10/3, 2012 at 6:55 Comment(0)
S
6

UPDATE

From iOS 12 Apple will allow the support to read One Time Code(OTP - One Time Password) which you will get in the iPhone device.

iOS supports Password AutoFill on UITextField, UITextView, and any custom view that adopts the UITextInput protocol. System keyboard set the textContentType on it to .oneTimeCode

1) Using Code

singleFactorCodeTextField.textContentType = .oneTimeCode

2) Using Storyboard/XIB

Select UITextField/UITextView in storyboard/XIB click Click on Attribute inspector. Go to text input trait, click to Content type and select one time code and done.

The operating system will detect verification codes from Messages automatically with this UITextContentType set.

Warning

If you use a custom input view for a security code input text field, iOS cannot display the necessary AutoFill UI.

WWDC 2018 iPhoneX Device

For more information, you can check it on the Apple developer oneTimeCode

And also review WWDC 2018 Session 204 - Automatic Strong Passwords and Security Code AutoFill and jump to 24:28 for automatic pre-fill the OTP.

Scamp answered 24/9, 2018 at 2:59 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.