Connor Tumbleson
6e509695eb
Patch newest AndroResGuard format
2016-08-06 07:56:17 -04:00
Connor Tumbleson
e6faa56c96
Correctly handle ResTable_typeSpec by using unsigned bytes to prevent overflow
...
- fixes #1185
- allows applications that have large typeSpec indexes to work
2016-08-01 23:26:00 -04:00
Connor Tumbleson
a684bae43a
Fixes improper decoding of @empty value
...
- fixes #1270
- references #1116
2016-06-13 08:40:00 -04:00
Pierre-Hugues Husson
606e47bf55
Add @empty type
2016-06-13 08:23:08 -04:00
Connor Tumbleson
639ac84edb
Dont fallback to HighestResSpec Package if only 1 main package
...
- fixes #1220
2016-04-11 07:05:00 -04:00
Connor Tumbleson
ea2c821fa5
Add support for AndResGuard
...
- fixes #1170
2016-03-10 09:29:49 -05:00
Connor Tumbleson
f3e21023ac
Prefix integers only exceeding 9 digits to treat as string
...
- This prevents small numbers like "1" to become "\ 1"
- added unit tests
- fixes #1130
2016-02-10 08:05:54 -05:00
Rover12421
123912d226
Apktool.yml file (MetaInfo) using object serialization
...
non-printable character more intuitive, does not affect printable
character view
2016-01-22 06:28:03 -06:00
Connor Tumbleson
d5ca4c12a1
fix #1123
...
- correctly handles @null in xml
- added unit test
2016-01-22 06:07:49 -06:00
Ira Hanson
8232ee0ea8
Consistently encode unknown filenames to prevent cast error
2016-01-02 21:40:15 -06:00
Connor Tumbleson
13b39903d2
empty or null values should not be matched
2015-12-26 06:59:57 -05:00
Connor Tumbleson
f9323943db
Handle Dexguard key names
...
- Temporarily replace with dummy value names till research is completed
- allows decode
2015-12-26 06:59:43 -05:00
Connor Tumbleson
a8a9c40a7b
add ResBoolValue to Style check
2015-12-26 06:58:39 -05:00
Connor Tumbleson
ba7393d705
Fixes #767
...
Handles large int values in AndroidManifest.xml, by prefixing
with `\ ` which aapt treats a string. This prevents truncation
from overflow.
Superseeds PR#1007 - thanks to gio73 for initial research &
MarchMil for continued investigation.
2015-12-18 11:30:28 -06:00
Connor Tumbleson
e5ac340cab
[ci skip] minor spacing change
2015-12-18 09:46:28 -06:00
Connor Tumbleson
b2d50bec5f
[skip] code style cleanup
2015-12-14 07:10:14 -06:00
Connor Tumbleson
eabb7d819b
Correctly read sparse ResourceTables.
...
Prior to this change, APKs usually went Package -> TypeSpec -> Config (all) -> Entries.
Reading all configs under that TypeSpec. Now we have packages that go
Package -> TypeSpec -> Config (single) -> Entries.
So we have to read this correctly to make sure we can correctly decode sparse and packed
Resource tables.
2015-12-14 07:03:09 -06:00
Connor Tumbleson
be4bdf1d75
Adds support for DATA_NULL_EMPTY
2015-12-14 07:00:12 -06:00
Connor Tumbleson
6c4167fba4
Fixes #1099
...
- Moves Config --> Type
- Moves Type -> TypeSpec
- ResType -> ResTypeSpec
- ResConfig -> ResType
This is to match AOSP and ease the transitions/updates of new AOSP drops
2015-12-07 20:48:57 -06:00
Connor Tumbleson
8374839427
MNC, noticed recently in API 23, is no longer 0 padded. So mnc001 is now mnc1
...
- Frameworks between froyo and honeycomb have mnc001, etc
- A size check of ResConfig header for less than 32 (honeycomb) uses old decode method
- Greater than 32 bytes moves to new decode method of mnc# vs mnc###
2015-12-01 08:48:31 -06:00
Connor Tumbleson
5f5f50f6fd
Fixes edge case where mnc = 1, with no mcc field. Fixes #1072
2015-11-01 06:17:29 -06:00
Connor Tumbleson
3dea579f66
Prevent casting Strings/Styles to Attrs
...
- refs #957 , #1060
2015-10-15 08:58:19 -05:00
Connor Tumbleson
a29839bab2
Added API 23 qualifier "roundness"
2015-10-08 06:58:11 -05:00
Pierre-Hugues Husson
e7b294a3ea
Fix flags being defined as references
2015-09-10 18:07:00 +02:00
Connor Tumbleson
579d7c561e
fixes #1021
...
- adds support for godzillaui
2015-08-15 10:29:24 -05:00
Matt Mastracci
4249dde7cc
Propagate the raw int values to callers
2015-07-07 15:39:22 -06:00
Connor Tumbleson
2c1226fab8
[skip] use append instead of concat
2015-05-22 08:47:51 -05:00
Connor Tumbleson
8254764c6c
More robust ResFileValue detection
...
Previously in 4882396163f978884256e008fc7fae9201f156b4, strings that
resembled a filepath (ie res/foo/file), would be assigned to a
ResFileValue, which when attempted to be casted to ResScalarValue would
error out.
Attempting to check the filesystem for such files, slowed apktool's
execution majorly. In order to prevent this, the ClassCastException
and other checks related to checking ResFileValue when type is string
was added.
This allows bogus strings such as (res/foo/file) to be added, but the
exception is caught and allows decoding to continues. Fixes #921 .
2015-05-14 13:27:22 -05:00
Connor Tumbleson
c659df9dce
Correctly add version qualifier when decoding
...
- fixes #928
2015-04-29 07:49:02 -05:00
Connor Tumbleson
bb6cd98dfa
fix regression of lang qualifiers
...
- values-xx was improperly decoded as values-b+xx
- added unit test
2015-04-11 12:39:38 -05:00
Connor Tumbleson
da3b8c710d
cleanup messy logic for bcp qualifiers
2015-04-11 11:36:31 -05:00
Connor Tumbleson
0a74de4ab0
Shared Library Rebuilding Support
...
- handles references with shared resources
- adds support for --shared-lib
- update unit-tests
2015-03-14 08:04:33 -05:00
Connor Tumbleson
40e75a0a39
[skip] sdk version (lollipop mr1)
2015-03-12 17:43:47 -05:00
Connor Tumbleson
2db8828efb
add support for TYPE_NULL
2015-03-12 17:43:17 -05:00
Connor Tumbleson
bbc6023068
gracefully handle apks that have strings that resemble filepaths
...
- ex string res/foo tries to map to resource res/foo
- looks for dot now, ie res/foo.xml
2015-03-06 17:04:43 -06:00
Connor Tumbleson
dc02abcf51
Add support for more BCP combinations
...
- region, variant, script & language combined
- 2 char language, 2 char region
- 2 char lang, 4 char script, 3 char variant
2015-02-21 16:48:48 -06:00
Connor Tumbleson
da347b22ba
[skip] remove unused import
2015-02-19 11:37:51 -06:00
Connor Tumbleson
db38c217ae
Update ResConfigFlags for BCP
...
- renamed country to region to match AOSP
- added support for values-xxx-rXX
- added support for BCP47
- default to BCP47 for values-xxx
2015-02-19 09:06:08 -06:00
Connor Tumbleson
20504d1338
Fix improper handling of MNC_ZERO
...
- add test
- patch ResConfigFlags
2014-12-30 06:08:23 -06:00
Connor Tumbleson
4882396163
Prevent casting strings that resemble filepaths to ResFileValues
...
- add testcase
- adapt changes
- introduce decodeManifestWithResources which uses attr decoding w/ resources
2014-12-26 08:08:50 -06:00
Connor Tumbleson
c91ef3822e
[skip] code style updates
2014-12-25 12:21:30 -06:00
Connor Tumbleson
ad70082ebf
fix placement of lollipop natural qualifier check
2014-11-21 11:26:18 -06:00
Connor Tumbleson
0150835bb0
Add support for BCP-47
...
- Switch to BCP-47 was to move away from hideous java locale toString
- mnc1 padded to mnc01
- mnc10 padded to mnc010
2014-11-21 11:26:17 -06:00
Connor Tumbleson
554591a339
added support for TYPE_DYNAMIC_REFERENCE
2014-11-21 11:26:17 -06:00
Connor Tumbleson
50de34bbf1
add anydpi qualifier
2014-11-21 11:26:16 -06:00
Connor Tumbleson
daafeb284e
fixes regression introduced in 40fdfc50a198f108d32e8f0ca1a7632b65d247c0
...
- tagged framework support fixed
2014-11-21 11:25:07 -06:00
Connor Tumbleson
a7d8ca9086
cs fixes, remove unused imports
2014-10-29 16:18:47 -05:00
Connor Tumbleson
9031c22365
[skip] update all copyrights to 2014
2014-10-23 18:14:48 -05:00
Jeff Smith
db2478a71f
Handle ResStringValue when ResAttr expected in ResStyleValue
2014-10-18 23:40:04 -05:00
Connor Tumbleson
99c1ab96da
add api 21 qualifiers
...
- watch
- tiny cs fixes
- tag MIUI related changes
2014-10-17 13:35:02 -05:00