Remove SMS limit?

Search This thread

Decimation001

Member
Jun 22, 2016
30
5
This is incredibly ridiculous. Why is there a limit on how many messages I can send in a certain period of time? I would like to know if there is any way to remove it. I have searched relentlessly.

1. settings.db doesn't exist anymore and therefore cannot be changed to set a custom limit.
2. I'm rooted, have EX kernel and Pure Nexus 7.1.1 ROM. Neither support changing the limit natively.
 

jhs39

Senior Member
Oct 8, 2015
2,485
716
Chicago
This is incredibly ridiculous. Why is there a limit on how many messages I can send in a certain period of time? I would like to know if there is any way to remove it. I have searched relentlessly.

1. settings.db doesn't exist anymore and therefore cannot be changed to set a custom limit.
2. I'm rooted, have EX kernel and Pure Nexus 7.1.1 ROM. Neither support changing the limit natively.
The limit is probably set by your carrier. If that's the case you won't be able to change it in the ROM or phone build prop.
 

jhs39

Senior Member
Oct 8, 2015
2,485
716
Chicago
Is it in the build prop? There wasn't a limit on a different phone.
The limit just started when you got the 6P? How long were you using the phone before the limit became an issue? Are you on stock or a custom ROM? Who is your phone carrier? Are you using a stock SMS Program or different one? Maybe someone will have an answer if you provide more information. What is the limit, by the way? Do you know? I know that the program Automate limits texts as a security precaution. Maybe a third party program is causing the issue. Have you tried booting into safe mode and seeing if the limit still exists?
 

Decimation001

Member
Jun 22, 2016
30
5
The limit just started when you got the 6P? How long were you using the phone before the limit became an issue? Are you on stock or a custom ROM? Who is your phone carrier? Are you using a stock SMS Program or different one? Maybe someone will have an answer if you provide more information. What is the limit, by the way? Do you know? I know that the program Automate limits texts as a security precaution. Maybe a third party program is causing the issue. Have you tried booting into safe mode and seeing if the limit still exists?

The limit is on my 6P running Resurrection Remix 7.1.1 on francoKernel. NOT on my other Note5 which is 6.0.1 stock kernel and ROM. Both are/were on T-Mobile. Both use Textra. Not sure what the limit is.
 

jhs39

Senior Member
Oct 8, 2015
2,485
716
Chicago
The limit is on my 6P running Resurrection Remix 7.1.1 on francoKernel. NOT on my other Note5 which is 6.0.1 stock kernel and ROM. Both are/were on T-Mobile. Both use Textra. Not sure what the limit is.
Maybe something went wrong when you installed your custom ROM or Kernel. I've never heard of a text message limit on the Nexus 6P. You get an error message when you try and send a text saying you have reached the limit and the text can't be sent? Or is it a size limit? Or a limit to the number of recipients you can send a message to? I've heard of limits on the latter two but not on total number of messages that can be sent. At least not in North America.
 

Decimation001

Member
Jun 22, 2016
30
5
Maybe something went wrong when you installed your custom ROM or Kernel. I've never heard of a text message limit on the Nexus 6P. You get an error message when you try and send a text saying you have reached the limit and the text can't be sent? Or is it a size limit? Or a limit to the number of recipients you can send a message to? I've heard of limits on the latter two but not on total number of messages that can be sent. At least not in North America.

The limit was both on Pure Nexus and RR. It limits how many messages I can send to anyone within a certain amount of time. I can still press "accept" to send but it's really annoying and spams me.
 

jhs39

Senior Member
Oct 8, 2015
2,485
716
Chicago
That kind of sounds like you might have malware/adware installed on your phone. You might want to download something like Malwarebytes and do a scan of your phone.
 

shaneaus

Senior Member
Nov 27, 2007
547
17
Austin, Texas
The SMS limit is built into Android. Previous to N it was a setting that could be altered in the build.prop and an option to change it was baked into RR. With N the settings were moved into the framework (from what I could find it appears it the telephony section?) and the option to change the setting was not baked into the new ROMs.

I have made several posts requesting info on how to change this - but, no one has responded (either they don't know, don't care, or haven't seen my posts). I need this option for work so badly I'm willing to learn how to build my own ROM. But, not worth getting started if I don't know how to fix the one important thing I need changed.
 
Last edited:

jhs39

Senior Member
Oct 8, 2015
2,485
716
Chicago
The SMS limit is built into Android. Previous to N it was a setting that could be altered in the build.prop and an option to change it was baked into RR. With N the settings were moved into the framework (from what I could find it appears it the telephony section?) and the option to change the setting was not baked into the new ROMs.

I have made several posts requesting info on how to change this - but, no one has responded (either they don't know, don't care, or haven't seen my posts). I need this option for work so badly in selling to learn how to build my own ROM. But, not worth getting started if I don't know how to fix the one important thing I need changed.
If the limit is built into Android why is nobody else having the same problem as you? Do you do something with your SMS that the average user doesnt't? Are you using your SMS to send advertising to large numbers of people, for instance?
 
  • Like
Reactions: turtlez86

shaneaus

Senior Member
Nov 27, 2007
547
17
Austin, Texas
If the limit is built into Android why is nobody else having the same problem as you? Do you do something with your SMS that the average user doesnt't? Are you using your SMS to send advertising to large numbers of people, for instance?

I don't understand why you are even asking this... I appreciate you willingness to help out. But... If you can't help out - just don't respond. You have exhibited that you don't have any knowledge of the settings we are speaking of - AND, I explained the setting is now in the framework. So, unless you know of a way to modify the framework without building a custom ROM - then, please stop implying that we don't have an issue - just because you don't understand what the issue is...

Your first response "The limit is probably set by your carrier" was uneducated speculation.
Your second response included several questions the OP had answered in his original post - he stated he had researched the issue, was using a custom rom/kernel... Then, you followed that up by more speculation: "Maybe a third party program is causing the issue. ."
Your third response isn't helpful as you merely question the OP's knowledge that he even knows he has an issue: "I've never heard of a text message limit on the Nexus 6P." Basically, you just admit your ignorance of there being an issue: " I've heard of limits on the latter two but not on total number of messages that can be sent." Which would imply to most that you won't have any knowledge of how to fix said issue.
Your forth response is to suggest there is malware? Again implying that the OP has no idea about what they are speaking.

Finally, when I post and explain that the setting was once there and easily modified with a build.prop change and that the code was moved...
You again imply that we have some sort of 'phantom issue:' "why is nobody else having the same problem as you?"

If you don't know the answer why waste our time? Do a search and you could easily find another post or two here on XDA in which I explained my situation/problem...

Once again, if you can help - we will surely appreciate any assistance! But, if you don't KNOW how to help; please, don't continue to ask questions which suggest we don't know what we are talking about.
@Decimation001 - I did some research and inside the framework there are two sections related to "telephony" (which is where it appears the settings were moved). Seems they are ODEX files. Might be able to de-compile, make a correction, re-compile, replace in current ROM. I'll start looking into it over the next week or so.
 
Last edited:

Decimation001

Member
Jun 22, 2016
30
5
Once again, if you can help - we will surely appreciate any assistance! But, if you don't KNOW how to help; please, don't continue to ask questions which suggest we don't know what we are talking about.
@Decimation001 - I did some research and inside the framework there are two sections related to "telephony" (which is where it appears the settings were moved). Seems they are ODEX files. Might be able to de-compile, make a correction, re-compile, replace in current ROM. I'll start looking into it over the next week or so.

Can you give me the names of the files? I know how to compile and recompile so I'd be happy to try and make some modifications.
 

shaneaus

Senior Member
Nov 27, 2007
547
17
Austin, Texas
I guess you can keep talking to yourself then.

No need to get your feelings hurt. But, I'm not here to "just talk to people" or socialize. I'm here to attempt to solve an issue. If you can assist - then, I will be very grateful for any assistance!
@Decimation001:

Here is the old build.prop method (posted from a member on another Android forum:
"Note: If you move to Marshmallow this will not work anymore as the file "settings.db" is irrelevant under Android 6.0 (annoying but true)

You need:
Root
something like Root explorer and sqLite editor

Open this file: /data/data/com.android.providers.settings/databases/settings.db
Go to "global" subsection, then look for the following two entries
"sms_outgoing_check_max_count" and "sms_outgoing_check_interval_ms"

If they don't exist (by default they aren't there) then create them.
Set the first one to whatever you want (its the maximum number of texts you can send per timeframe (eg.1000)
Set the second one to whatever timeframe you are measuring in millisecond units (eg. 1800000)

My settings were
sms_outgoing_check_max_count 1000
sms_outgoing_check_interval_ms 1800000
This example limits my texts to 1000 messages every 30 minutes

Close file, making sure to save saving if requested to do so.
Reboot system. The new settings will override the Android internal ones.
Hacked "

However, I sent him a PM and he does not know how to make the change in the newer versions of Android. From research I did it appeared that Android moved this setting into the Framework under "Telephony" and you can see that in the structure here:
https://www.researchgate.net/figure...-Android-Telephony-system-architecture-from-6

I've been trying to look for the merge/change in the files here:
https://android.googlesource.com/platform/frameworks/opt/telephony/

I haven't found the specific change/code yet.

However, if you use Root Explorer in an installed ROM - you might find the relevant code by unpacking/searching here:
/system/framework/telephony-common.jar/classes.dex
/system/framework/telephony-ext.jar/classes.dex

I'll try to keep looking for the change in the source code - should have occurred during the transition from Android 5.0 to 6.0....
 

Decimation001

Member
Jun 22, 2016
30
5
No need to get your feelings hurt. But, I'm not here to "just talk to people" or socialize. I'm here to attempt to solve an issue. If you can assist - then, I will be very grateful for any assistance!

@Decimation001:

Here is the old build.prop method (posted from a member on another Android forum:
"Note: If you move to Marshmallow this will not work anymore as the file "settings.db" is irrelevant under Android 6.0 (annoying but true)

You need:
Root
something like Root explorer and sqLite editor

Open this file: /data/data/com.android.providers.settings/databases/settings.db
Go to "global" subsection, then look for the following two entries
"sms_outgoing_check_max_count" and "sms_outgoing_check_interval_ms"

If they don't exist (by default they aren't there) then create them.
Set the first one to whatever you want (its the maximum number of texts you can send per timeframe (eg.1000)
Set the second one to whatever timeframe you are measuring in millisecond units (eg. 1800000)

My settings were
sms_outgoing_check_max_count 1000
sms_outgoing_check_interval_ms 1800000
This example limits my texts to 1000 messages every 30 minutes

Close file, making sure to save saving if requested to do so.
Reboot system. The new settings will override the Android internal ones.
Hacked "

However, I sent him a PM and he does not know how to make the change in the newer versions of Android. From research I did it appeared that Android moved this setting into the Framework under "Telephony" and you can see that in the structure here:
https://www.researchgate.net/figure...-Android-Telephony-system-architecture-from-6

I've been trying to look for the merge/change in the files here:
https://android.googlesource.com/platform/frameworks/opt/telephony/

I haven't found the specific change/code yet.

However, if you use Root Explorer in an installed ROM - you might find the relevant code by unpacking/searching here:
/system/framework/telephony-common.jar/classes.dex
/system/framework/telephony-ext.jar/classes.dex

I'll try to keep looking for the change in the source code - should have occurred during the transition from Android 5.0 to 6.0....

I found the files. It's SmsUsageMonitor.class in telephony-common.jar. It has the values:
Code:
 this.mLimit.set(Settings.Global.getInt(this.mContext.getContentResolver(), "sms_outgoing_check_max_count", 30));
this.mPeriod.set(Settings.Global.getInt(this.mContext.getContentResolver(), "sms_outgoing_check_interval_ms", 60000));

Now the problem is recompiling and making it a jar again.
 

shaneaus

Senior Member
Nov 27, 2007
547
17
Austin, Texas
@shaneaus Dang dude, chill out...

I am very "chill." Don't understand why you made the comment.
@Decimation001 That is awesome! It took me quite awhile to hunt down different forum threads to find out where the settings had been moved. I was all prepared to attempt to start learning how to compile/decompile those files! But, between working 70 hrs/wk, spending one night with my kids, one night with my girlfriend, and monitoring my home which is under construction - I just haven't had the time! My partner who shares responsibility for sending out the texts for the contract work we schedule is anxiously waiting on my finding a solution! I'm hoping you can re-compile the file!

I'm just concerned at this point that this would have to be done every single time a new version of a ROM is used... Wondering if it could be made into a flashable .zip file which would only change that line of code changing the 30 to 200 or 300....

In any case - is this something we could just extract the classes.dex file, use apktool to decompile, change "30" to "300", recompile, and push the altered .dex file back into place? I understand using "tools" isn't the best way to go - but, I won't have much time to devote to this for the next 4-6 months. So, if apktool will do the trick for now... I'm willing.
 

shaneaus

Senior Member
Nov 27, 2007
547
17
Austin, Texas
I found the files. It's SmsUsageMonitor.class in telephony-common.jar. It has the values:
Code:
 this.mLimit.set(Settings.Global.getInt(this.mContext.getContentResolver(), "sms_outgoing_check_max_count", 30));
this.mPeriod.set(Settings.Global.getInt(this.mContext.getContentResolver(), "sms_outgoing_check_interval_ms", 60000));

Now the problem is recompiling and making it a jar again.

Ok, I figured out how to decompile the "classes.dex" file using baksmali. However, I can't find the Telephony-common.jar file.

I have found similar code here: out/com/Android/internal/telephony/SmsUsageMonitor$SettingsObserver.smali
".line 248
const-string/jumbo v2, "sms_outgoing_check_max_count"
const/16 v3, 0x1e"

Also, in this file: SmsUsageMonitor$SettingsObserverHandler.smali
" .line 263
const-string/jumbo v1, "sms_outgoing_check_max_count""

But, I don't know how to modify it as it isn't in the format I'm accustomed to seeing... From what I read it is in a smali syntax and I don't know how to modify this code.

@Decimation001 - any ideas?

---------- Post added at 02:54 AM ---------- Previous post was at 02:17 AM ----------

I found the files. It's SmsUsageMonitor.class in telephony-common.jar. It has the values:
Code:
 this.mLimit.set(Settings.Global.getInt(this.mContext.getContentResolver(), "sms_outgoing_check_max_count", 30));
this.mPeriod.set(Settings.Global.getInt(this.mContext.getContentResolver(), "sms_outgoing_check_interval_ms", 60000));

Now the problem is recompiling and making it a jar again.

Ok, I figured out how to decompile the "classes.dex" file using baksmali. However, I can't find the Telephony-common.jar file.

I have found similar code here: out/com/Android/internal/telephony/SmsUsageMonitor$SettingsObserver.smali

".line 248
const-string/jumbo v2, "sms_outgoing_check_max_count"

const/16 v3, 0x1e"

Also, in this file: SmsUsageMonitor$SettingsObserverHandler.smali
" .line 263
const-string/jumbo v1, "sms_outgoing_check_max_count""

But, I don't know how to modify it as it isn't in the format I'm accustomed to seeing... From what I read it is in a smali syntax and I don't know how to modify this code.

@Decimation001 - any ideas?

Ok... Looks like if I change the hexadecimal "0x1e" (means 30) below to "0x12c" (means 300), save, recompile using baksmali, and re-insert into my ROM it should work?:
out/com/Android/internal/telephony/SmsUsageMonitor$SettingsObserver.smali

".line 248
const-string/jumbo v2, "sms_outgoing_check_max_count"
const/16 v3, 0x1e"
 

shaneaus

Senior Member
Nov 27, 2007
547
17
Austin, Texas
Ok. I think I did it. I extracted the "telephony-common.jar" file from system/framework. I used 7zip to open it and took the classes.dex file out. I placed the classes.dex file into my smali/baksmali folder, decomplied, changed the above line of code in the manner indicated, recompiled.... I opened telephony-common.jar back up (confirmed that classes.dex was not present), copied the newly updated classes.dex file into telephony-common.jar. I placed it into a folder on the device. Using the app Root Explorer I had two tabs open and deleted the original telephony-common.jar file and immediately copy/pasted the new one in it's place. Just to be sure it worked I extracted the classes.dex file again and decompiled it to confirm.

I'll test it out tomorrow with a mass text to all of my sub-contractors. If it works - I'll edit/post the detailed instructions on the first post in this thread.
 
  • Like
Reactions: Decimation001

Top Liked Posts

  • There are no posts matching your filters.
  • 3
    Please Decimation001 help us to edit step by step .
    Dex file is difficult to change, and give us inside what line you changed.
    Step by step is very good.
    Thank you:confused:

    1. You are going to need the tool "apktool"

    2. Extract your "telephony-common.jar" file from the folder "system/framework/" in the root partition and move it to your computer

    3. Shift-click in the folder you put your telephony file. Click "Open command window here".

    4. Type: "
    Code:
    apktool d telephony-common.jar
    " and run it.

    5. Once it's decompiled, navigate to "telephony-common.jar.out\smali\com\android\internal\telephony"

    6. Find the file "SmsUsageMonitor$SettingsObserver.smali" and open it in any editor.

    7. Find the line containing:
    Code:
    .line 248
        const-string/jumbo v2, "sms_outgoing_check_max_count"
    
        const/16 v3, 0x1e

    and/or:

    Code:
    .line 250
        const-string/jumbo v2, "sms_outgoing_check_interval_ms"
    
        const v3, 0xea60

    8. Now change the values "0x1e" and/or "0xea60" to your desired values in hexadecimal format. The value "0x1e" corresponds to "30" in decimal format and the value "0xea60" to "60000".
    If you wanted the value "0" for both, change them to "0x0". Changing them both to "0x0" would allow you to send unlimited texts within an unlimited amount of time.

    9. Now, to recompile the jar, run this command: "
    Code:
    apktool b telephony-common.jar.out
    "

    10. Navigate to "telephony-common.jar.out\build\apk" and get the "classes.dex" file.

    11. Open the original "telephony-common.jar" in any archive tool (7zip, WinRAR) and replace the "classes.dex" file with the one you recompiled.

    12. You now have your patched "telephony-common.jar"

    13. Simply replace the default one in "system/framework/" with the one you patched. Also be sure that the permissions match the original one.
    2
    If the limit is built into Android why is nobody else having the same problem as you? Do you do something with your SMS that the average user doesnt't? Are you using your SMS to send advertising to large numbers of people, for instance?

    I don't understand why you are even asking this... I appreciate you willingness to help out. But... If you can't help out - just don't respond. You have exhibited that you don't have any knowledge of the settings we are speaking of - AND, I explained the setting is now in the framework. So, unless you know of a way to modify the framework without building a custom ROM - then, please stop implying that we don't have an issue - just because you don't understand what the issue is...

    Your first response "The limit is probably set by your carrier" was uneducated speculation.
    Your second response included several questions the OP had answered in his original post - he stated he had researched the issue, was using a custom rom/kernel... Then, you followed that up by more speculation: "Maybe a third party program is causing the issue. ."
    Your third response isn't helpful as you merely question the OP's knowledge that he even knows he has an issue: "I've never heard of a text message limit on the Nexus 6P." Basically, you just admit your ignorance of there being an issue: " I've heard of limits on the latter two but not on total number of messages that can be sent." Which would imply to most that you won't have any knowledge of how to fix said issue.
    Your forth response is to suggest there is malware? Again implying that the OP has no idea about what they are speaking.

    Finally, when I post and explain that the setting was once there and easily modified with a build.prop change and that the code was moved...
    You again imply that we have some sort of 'phantom issue:' "why is nobody else having the same problem as you?"

    If you don't know the answer why waste our time? Do a search and you could easily find another post or two here on XDA in which I explained my situation/problem...

    Once again, if you can help - we will surely appreciate any assistance! But, if you don't KNOW how to help; please, don't continue to ask questions which suggest we don't know what we are talking about.
    @Decimation001 - I did some research and inside the framework there are two sections related to "telephony" (which is where it appears the settings were moved). Seems they are ODEX files. Might be able to de-compile, make a correction, re-compile, replace in current ROM. I'll start looking into it over the next week or so.
    2
    I guess you can keep talking to yourself then.
    1
    The SMS limit is built into Android. Previous to N it was a setting that could be altered in the build.prop and an option to change it was baked into RR. With N the settings were moved into the framework (from what I could find it appears it the telephony section?) and the option to change the setting was not baked into the new ROMs.

    I have made several posts requesting info on how to change this - but, no one has responded (either they don't know, don't care, or haven't seen my posts). I need this option for work so badly in selling to learn how to build my own ROM. But, not worth getting started if I don't know how to fix the one important thing I need changed.
    If the limit is built into Android why is nobody else having the same problem as you? Do you do something with your SMS that the average user doesnt't? Are you using your SMS to send advertising to large numbers of people, for instance?
    1
    Another metod worck on non rooted phone, I use on Android 8 and 7.
    0.instal in your phone
    https://play.google.com/sto...
    and open
    1-put drivers for ypur phone to see with compyuter your phone
    2-Downlad and rename the folder with adb and put this in pertition C
    https://drive.google.com/fi...
    3-open comand promt like administrator and tape:
    cd C:\adb
    and see C:\adb>
    tape C:\adb>adb devices
    and see
    List of devices attached
    ZY223R3KT5 device
    if you see unauthorized You need to accept in your phone, one popup apear and give compiuter acces.
    tape adb shell pm grant by4a.setedit22 android.permission.WRITE_SECURE_SETTINGS
    and see
    C:\adb>
    Restart the phone
    4.Open in our phone
    Settings Database Editor.apk and add in bouth this
    category (system,secure,global) new settings
    on top is +Add new settings push them
    and tape sms_outgoing_check_max_count and value 99999
    and restart
    And now you can send a lot off message.