News for hackers. Stuff that matters.
Re:System Hardening in Android 11 by sitic on Tuesday June 30, 2020 @02:10PM (#23692964)
In addition on Android 11 API

* apps can't simply access the "external" storage (enforces scoped storage)

* apps can't get a list of all installed apps (package visibility, they can specify app names and intent signatures in the Manifest they want to query)

These are welcome changes in my view, but unfortunately they also seem intend to fix SafetyNet and require hardware attestation that the bootloader is not unlocked [1]. When this is enforced for all devices some apps, like the eBay app, won't run on unlocked devices anymore. I've always trusted CyanogenMod/LineageOS more then than a device manufacturer, but after >10 years of using Android I think it's finally time for me to switch to an iPhone.

[1] https://groups.google.com/forum/#!topic/safetynet-api-client...

Re:System Hardening in Android 11 by Abishek_Muthian on Tuesday June 30, 2020 @11:32PM (#23697487)
>I've always trusted CyanogenMod/LineageOS more then than a device manufacturer, but after >10 years of using Android I think it's finally time for me to switch to an iPhone.

I'm not trying to go inside Android vs iOS rabbit hole, as it's common knowledge that android's default privacy features pale in comparison to iOS.

But in Android you can leverage the trust of an individual app publisher as well and not forced to 'trust the manufacturer'.

e.g.

Tasker is trusted, it can automate workflows unimaginable in an iOS ecosystem and when Google's API changes broke some of its features; Google listened to the community and whitelisted it.

Don't trust default messaging app? Let Signal handle messages. If there's an SMS based exploit, rest assured Signal update to patch that would arrive faster than android update.

Got 7 year old android device, which hasn't received any system updates in say (cough) 7 years? But you only use it for web browsing, you can still use latest Firefox for android(with its own engine). Which will support latest PWA API.

This can go on and on without rooting android; none of these would be possible in iOS at least not until jailbreak(which compromises security akin to rooting) and probably until Apple steals couple of tricks from the jailbreak community.

Finally, If you are talented but poor developer from a village in India/Nigeria/any other place you can develop a PWA web app on a Raspberry Pi and release it for the world to see without any additional charges and probably profit out of it; It would work fine on Android, KaiOS, perhaps upcoming suite of pure Linux smartphone OS, but if you want it to function on iOS you'll have to invest hundreds if not thousands of dollars in equipment, pay yearly $99 fee, develop new native app with probably a new programming language, Give 30% cut to Apple when you make money out of it.

Re:System Hardening in Android 11 by robin_reala on Wednesday July 01, 2020 @04:28AM (#23699204)
Tasker looks interesting. Any info on how it compares to iOS Shortcuts?

(also, iOS Safari has limited PWA functionality. It’s by no means as comprehensive as Chrome / Firefox on Android, but it was enough for me to make my latest site installable.)

Re:System Hardening in Android 11 by machello13 on Wednesday July 01, 2020 @06:03PM (#23707312)
The last paragraph is a massive exaggeration. iOS doesn't support as many PWA features as some people would like, but it supports plenty. You can't say PWAs simply don't function on iOS.
Re:System Hardening in Android 11 by freedomben on Tuesday June 30, 2020 @02:36PM (#23693239)
You're upset about them requiring hardware attestation in SafetyNet (I am too) so you move to a platform that is way less flexible and way more closed?

Not a troll, I'm really curious.

Re:System Hardening in Android 11 by californical on Tuesday June 30, 2020 @03:20PM (#23693762)
I can give an anecdote.

I love most things about iOS design more than Android, and I've used both, but have stuck with Android over the last 7-8ish years. Mainly because of the amount that I could customize things, freely make little app projects, install custom ROMs, etc. Over the last few years, it's gotten inconvenient to tinker, and I just don't find myself bothering with it anymore. I've run into issues where certain apps stop working because of root.

But also both OS's have gotten much better and need fewer (if any) tweaks anyways to be used effectively. Especially with the upcoming change to allow iOS to use a different default browser (finally).

If the main reason I've been drawn to Android is vanishing more every year, I'd rather use the more elegant OS (Apple), regardless of how closed it is. I have a Pixel 2 that's getting near EOL (only 2 years after buying it), and I'll be getting an iPhone SE as soon as I can justify spending the money.

I guess something that helps too is I've been on a de-googling kick these last few months where I've been switching off all their services because of privacy, another benefit of iOS to me

Re:System Hardening in Android 11 by homarp on Tuesday June 30, 2020 @04:23PM (#23694368)
iOS 14 does not let you use a different default browser engine. It's just the skin that change. It's still Webkit under the hood
Re:System Hardening in Android 11 by bad_user on Tuesday June 30, 2020 @05:18PM (#23694900)
This is true and regrettable, but that skin is still important.

I get to use Firefox, it comes with nice tracker blocking out of the box, it keeps my history in sync with my other devices and I find the UI to be a little nicer (personal taste).

Of course I'd like the Firefox that's available on Android, with extensions capabilities and web push support. But having the ability to open links from Mail in iOS Firefox would still be nice and I can't wait for it.

Re:System Hardening in Android 11 by californical on Tuesday June 30, 2020 @04:39PM (#23694520)
Yeah it's not ideal, but it lets me sync with Firefox at least. I really only ever use my phone browser for a few things, anyways.

Neither situation is perfect, but the browser's rendering engine is surpassed by other priorities when choosing a phone.

I do look forward to the day I can use something like Pine as a daily phone though

Re:System Hardening in Android 11 by slipheen on Tuesday June 30, 2020 @04:31PM (#23694435)
As much as you and I may care about that, for many (most?) people the browser chrome is the most important part.

Syncing bookmarks, UI, tab handling etc tend to be bigger pain points for individuals, as opposed to the more dev-focused aspects such as supporting a certain API in Javascript.

Re:System Hardening in Android 11 by bad_user on Tuesday June 30, 2020 @05:22PM (#23694948)
If you're technologically illiterate, this might be true. Witness however Firefox for Android (vs iOS), the most important differences for me being:

- Extensions support, so uBlock Origin, Privacy Badger, the best ad-blocking combination that far surpasses Safari's content blockers, which are pretty shitty; and extensions are useful for more than ad-blocking — e.g. I have another one on my tablet that turns all web pages to dark mode, whether they support it or not

- Web push notifications

- (Up until very recently) webp format support

On Android I wouldn't even install many apps, like Facebook, or Twitter, or Fastmail, I'd simply use them as PWAs (web apps), in Firefox with ads blocking on, because I could.

I still use Firefox on iOS for the history / bookmarks syncing, but it's a shadow of actual Firefox.

Re:System Hardening in Android 11 by izacus on Tuesday June 30, 2020 @04:53PM (#23694656)
> As much as you and I may care about that, for many (most?) people the browser chrome is the most important part.

Except that for many/most people it's equally important to have a market choice which drives product improvements by competition. Not being able to choose a fully opensource browser engine (not even Firefox!) on iOS is a severe blow to opensource as a whole and browser engine competition in general. It's way worse than it ever was in times of IE6 - you never needed Microsoft's private signing keys to switch to Firefox or Chrome.

Re:System Hardening in Android 11 by copp on Wednesday July 01, 2020 @02:36AM (#23698439)
What makes iOS elegant over Android in your opinion ?

You seem to state it as a fact but I believe it is your opinion .

Re:System Hardening in Android 11 by pjmlp on Wednesday July 01, 2020 @03:18AM (#23698694)
Not the OP, but I also share the same opinion.

- OS Frameworks are not designed for the next year's IO, rebooting last years best practices, rather have long term roadmaps.

- The build system has stayed mostly the same, instead of having had multiple reboots

- C and C++ are integrated with the rest of tooling instead of feeling like an burden that has to be supported to keep game devs happy

- Everything that matters on iOS development is available in XCode, instead of being a mix of Studio templates, stuff dropped in Github that we are supposed to build ourselves and apparently official APIs (e.g. Oboe, Vulkan)

- Back to frameworks, while iOS offers high level frameworks for common workflows, Android offers Lego blocks that everyone fits in different ways with lengthy discussions on what is good Android code, MVP and whatever is the fad of the month on /r/androiddev

- When Apple does game development sessions, they actually talk about game development tech and do provide related tooling, Google talks about Play Store console and advertising for gamers. Notice that main GDC 2020 theme for the Google talks was to try to show that they are listing and trying to change, pity it came 10 years later.

- Most APIs in iOS seem to have had some though placed into them, in Android you have stuff like Animations that have had multiple instantiations, or others that have deprecated stuff even before reaching a proper release.

- When Google decided to drop Eclipse they had nothing to offer for NDK devs, almost two years later JetBrains decided to create CLion and then they had a solution. Otherwise most likely there still wouldn't exist an alternative to this day.

Re:System Hardening in Android 11 by copp on Wednesday July 01, 2020 @05:00AM (#23699404)
Thanks for your perspective from a game dev. w.r.t developing apps it has been long argued that iOS is better.
Re:System Hardening in Android 11 by TheSpiceIsLife on Tuesday June 30, 2020 @05:56PM (#23695243)
> Especially with the upcoming change to allow iOS to use a different default (finally).

Did you leave a word out here?

I assume you were going to write default keyboard?

Re:System Hardening in Android 11 by smichel17 on Wednesday July 01, 2020 @08:17AM (#23700548)
It was edited I think, the word is browser.
Re:System Hardening in Android 11 by ocdtrekkie on Tuesday June 30, 2020 @03:48PM (#23694046)
For me, Play Services is a non-starter: It's malware, plain and simple. For a couple years I tried to use Android without Google services, but I found it too restrictive. Most apps I'd want/need to use wouldn't even run without Google Play, even if you got the APK, since there's not really a good app store that has a lot of Android apps without Google Play. (F-Droid's hard-line open source requirement is too restrictive for my daily driver.)

I went to Windows Mobile for a while, it had more apps than a non-Google Android phone as it was, but obviously that's dead now as Microsoft has left the consumer space and literally told everyone to go buy Android phones.

Until antitrust happens, iPhone is really all that's left. I've got a PinePhone too, and I'm pretty excited about it, but it'll probably be a while until it reaches Windows Mobile-level of app availability. I've been pleasantly surprised by Apple's pro-privacy moves since I bought it, and if they're opening up changing default apps this year too, really the most problematic limitation is going to be gone.

Re:System Hardening in Android 11 by andrepd on Tuesday June 30, 2020 @07:54PM (#23696202)
microg is a FOSS implementation of google play services, without the malware part. Apps will still see "google play services" on your phone and mostly will run without problems, but their API calls are actually handled by microg.
Re:System Hardening in Android 11 by user5994461 on Tuesday June 30, 2020 @04:37PM (#23694503)
You could try one of the Chinese android phones, like Xiaomi. Make sure to get an Asian import, because some models have an US/European export edition with the normal Google ecosystem.

This is an interesting experience in what a fully functional phone not from Google/Apple can be like. It may not be able to run the usual apps though, unless you install the playstore manually.

Re:System Hardening in Android 11 by bad_user on Tuesday June 30, 2020 @04:38PM (#23694518)
Why would someone not trusting Google, place their trust in Xiaomi, a Chinese company?
Re:System Hardening in Android 11 by fsflover on Wednesday July 01, 2020 @08:32AM (#23700630)
What if you live in the US? Which government you should fear more, US or Chinese?
Re:System Hardening in Android 11 by bad_user on Wednesday July 01, 2020 @08:55AM (#23700796)
You should fear your local government most, of course, but it does not follow that given the choice you should pick foreign solutions, quite the contrary.

As a citizen you have rights guaranteed by the law in your own country. That's the very definition of citizenship. As a citizen you have leverage over your government, even if small, because you can organize yourself with others, e.g. in class action lawsuits, you can vote, you can convince others to vote, etc. Foreign governments and companies couldn't give a shit about your rights, the only rights you have are those defined weakly by trade agreements.

Not only that but data can be traded or leaked. A foreign company thousands of miles away, collecting data about you, could always leak that data to your local organized crime organizations.

N.B. I know that big companies like Xiaomi also have a presence in the US. With a big enough presence, the US government could coerce them just as easily, so if you fear the US government, it's a double whammy.

---

So this is a non sequitur. Even if you fear the US government, as a US citizen, you should either pick US solutions, or solutions from countries that have a culture and laws for preserving privacy, such as Switzerland or Germany.

Frankly as a US citizen picking products and services from a country with disregard for basic human rights, because you don't trust the US, is just stupid.

Re:System Hardening in Android 11 by fsflover on Thursday July 02, 2020 @04:33AM (#23711171)
> As a citizen you have rights guaranteed by the law in your own country.

True except for some people like protesters or whistleblowers who do not enjoy "rights guaranteed by the law", or at least not reliably.

> Even if you fear the US government, as a US citizen, you should either pick US solutions, or solutions from countries that have a culture and laws for preserving privacy, such as Switzerland or Germany.

Are you aware of any smartphones from those countries without involvement of Apple or Google?

Re:System Hardening in Android 11 by ocdtrekkie on Tuesday June 30, 2020 @04:48PM (#23694595)
The issue is too many Android apps won't even run without Google's malware installed. Even Google's direct competitors' apps depend on it. Skype from Microsoft will not run on Android without Google Play last time I tried it. So I needed to move to a platform where the default assumption is not that users have Google's background malware enabled, and that means anything based on Android is off the table.
Re:System Hardening in Android 11 by viraptor on Tuesday June 30, 2020 @05:24PM (#23694967)
Microsoft phone is dead. They're not competitors. You can also use https://microg.org/ with lots of apps already as an alternative.
Re:System Hardening in Android 11 by ocdtrekkie on Tuesday June 30, 2020 @06:34PM (#23695562)
Are you saying you do not believe Google and Microsoft are competitors? From office suites and chat apps to cloud services and gaming platforms, they have a lot of competing offerings.
Re:System Hardening in Android 11 by bad_user on Tuesday June 30, 2020 @04:38PM (#23694507)
What is wrong with Play Services, why is it malware?
Re:System Hardening in Android 11 by izacus on Tuesday June 30, 2020 @04:55PM (#23694674)
It provides same services as Apple ships with iOS (iCloud, Push messaging services, Find my Friend, AppStore, Location, etc.), except that in Android that's branded "malware that calls home" and in Apple world it's called "integral part of the OS".

The only difference here is that in Android you can actually separate the two.

Re:System Hardening in Android 11 by viraptor on Tuesday June 30, 2020 @05:25PM (#23694978)
The second difference is, you can replace it - https://microg.org/
Re:System Hardening in Android 11 by no_wizard on Tuesday June 30, 2020 @07:05PM (#23695824)
This sounds great, but reading the fine print:

>Although most microG components are far from complete, users are amazed by the results.

What users are amazed by what results? And if you read this carefully, it clearly states its missing swaths of the APIs, so its not 1 to 1 compatible and is very likely out of date in at least one reimplementation, per this [0]:

>This is alpha-grade software and not yet ready for production use. Do not use if you don't know what you're doing.

I don't think this would hold up to being what I'd use as a daily driver. I just want my phone to work not fiddle with troubleshooting weird edge cases for apps I want to use.

I applaud the project, but its hardly a simple as saying 'you can replace it' and that's the last you'll have to think about it.

[0] https://github.com/microg/android_packages_apps_GmsCore/wiki

Re:System Hardening in Android 11 by ocdtrekkie on Tuesday June 30, 2020 @07:36PM (#23696082)
MicroG still talks to Google services. It takes their code off your device but doesn't relieve you of the primary issue, that everything is dependent on Google's cloud services to work, and that they can still track everything you sent to them.
Re:System Hardening in Android 11 by cromwellian on Wednesday July 01, 2020 @01:26AM (#23698033)
As can iCloud, but somehow being tethered to APNS doesn't count. When Apple phone's home, it's like ET and you're supposed to feel all warm and fuzzy.
Re:System Hardening in Android 11 by sitic on Tuesday June 30, 2020 @02:58PM (#23693500)
If my phone has to be a walled garden, Apple's seems more enticing to me for the moment. I would want to give it a try at least. I might very well regret it and switch back to an Android phone which won't get updates after two years.

I also have to say that to me, even if apps that require SafetyNet don't work anymore after unlocking, it certainly doesn't make the phone certainly useless. But I don't want to live with the inconvenience of not being able to use some random apps.

Re:System Hardening in Android 11 by 867-5309 on Tuesday June 30, 2020 @05:27PM (#23694994)
In my case I am stuck with a spare phone on android 8 since they banned wireless scanning from 9 onwards. it's a matter of functionality over perceived security. fed up with google. will check out the PinePhone
Re:System Hardening in Android 11 by WolfRazu on Tuesday June 30, 2020 @08:13PM (#23696333)
No, they just rate limited it and it's toggleable in 10.
Re:System Hardening in Android 11 by 867-5309 on Wednesday July 01, 2020 @11:53AM (#23702837)
appears android 10 has been abandoned by Sony for my main driver (mid 2017). time to try the custom ROMs which are only just appearing..
Re:System Hardening in Android 11 by zimmerfrei on Wednesday July 01, 2020 @04:07AM (#23699075)
Is it clear exactly what SafetyNet does and reports back to Google?

Is its source code available (including for any TrustZone component), maybe as part of AOSP?

I am OK with the concept and I can value it also as a protection against advanced malware, but only if it is totally transparent (to me!) what data it collects and relies upon.

Re:System Hardening in Android 11 by panpanna on Wednesday July 01, 2020 @07:57AM (#23700442)
I think they use industry standard techniques (trust anchroing, attestation, etc) but their implementation is not fully open.

I'm actually fine with that.

Re:System Hardening in Android 11 by notyourday on Tuesday June 30, 2020 @04:39PM (#23694521)
Play Services infuriate me. I have no idea what app is triggering what kind of actions via Play because all of those actions are done by Play on behalf of the app and Play is not showing it to me in enough details
Re:System Hardening in Android 11 by nmfisher on Wednesday July 01, 2020 @07:22AM (#23700240)
As a developer, I apologise for the Play Services requirement. I believe this is a hard dependency for Firebase integration (and at the very least, it's the easiest/fastest way to implement Google Sign-in, though I assume this could be replaced with manual OAuth).

I didn't realize it was such an issue. I'll make a note to investigate how difficult it is to migrate away.

Re:System Hardening in Android 11 by notyourday on Wednesday July 01, 2020 @07:34AM (#23700320)
I do not think there's actually a good way for a developer to avoid Play Services, which in turn leads me to say that you should continue to use it or whatever else lets you get the most functionality out of the Android for the least amount of pain. Objectively, an Android user is not going to disable the Play Services as Google's apps will continue to rely on it so non-Google developers should use it as well.
Re:System Hardening in Android 11 by freedomben on Tuesday June 30, 2020 @05:15PM (#23694872)
I can certainly echo this sentiment. It is maddening to see Play services as the "culprit" for the bad thing I'm investigating. Very frustrating.
Re:System Hardening in Android 11 by kelnos on Tuesday June 30, 2020 @05:24PM (#23694969)
If you're comfortable disclosing, what is this "bad thing"? From my understanding, Play Services provides roughly the same suite of things that are also supplied on iOS, only on iOS, it's built into the OS (location services, cloud messaging, etc.), while on Android it's a modular component that Google can push updates to without a full OS update. Is that not accurate?
Re:System Hardening in Android 11 by scarface74 on Tuesday June 30, 2020 @08:10PM (#23696308)
Everything that Google announced in the submitted article requires an OS update. So being able to push just Play Services updates doesn’t help too much....
Re:System Hardening in Android 11 by dcow on Tuesday June 30, 2020 @04:38PM (#23694517)
Wouldn't the solution be to allow people who have legitimately unlocked their boot loader to also install a custom attestation root so that safety net can still say “the software running on this phone is the software the user intended and not a malicious 3rd party”? Or maybe safety net is not so much about user safety as it is about platform lockdown and vendor safety.

The number of times I’ve been laughed out of a product meeting because I’ve advocated for making decisions that don’t require the apps I’ve worked on to be run on google play services systems... it makes me wonder what is actually important in our industry. It’s certainly not the user privacy, freedom, and advocacy that everyone seems to be milking these days... sad times.

Re:System Hardening in Android 11 by josephcsible on Tuesday June 30, 2020 @05:35PM (#23695065)
> Or maybe safety net is not so much about user safety as it is about platform lockdown and vendor safety.

Sadly, it's exactly this. It's not for your safety at all. It's for keeping stuff on your phone safe from you.

Re:System Hardening in Android 11 by zozbot234 on Tuesday June 30, 2020 @05:06PM (#23694782)
Bootloader unlock is under user control by definition - it won't happen unless you're physically interacting with the device. The legitimate case for safety net is platform lockdown for things like financial apps. Banks and other financial services like to provide some form of insurance to users wrt. losing money in a security breach, and they can't do this unless the app really is being run on a pristine, locked-down platform. Unfortunately it also impacts sillier things like media streaming and online video games. But the best way to cope with that is simply not to use those.
Re:System Hardening in Android 11 by kelnos on Tuesday June 30, 2020 @05:19PM (#23694917)
> Banks and other financial services like to provide some form of insurance to users wrt. losing money in a security breach, and they can't do this unless the app really is being run on a pristine, locked-down platform.

This seems like a weird policy, though. I can access my bank via a web browser on a desktop computer, which is certainly not even remotely a "pristine, locked-down platform".

Re:System Hardening in Android 11 by realusername on Tuesday June 30, 2020 @10:18PM (#23697023)
That even makes it weirder that a no-name Chinese phone with an unknown ROM is considered more secure than a stock LineageOS just because it's not unlocked...
Re:System Hardening in Android 11 by ce4 on Wednesday July 01, 2020 @12:14AM (#23697678)
Or an exploitable stock ROM (either due to slow updates or eol status after 6mo-2yrs)
Re:System Hardening in Android 11 by realusername on Wednesday July 01, 2020 @12:30AM (#23697755)
Indeed, there's a LOT of cheap and outdated Android devices out there, even without talking about dodgy stock ROM.
Re:System Hardening in Android 11 by efreak on Wednesday July 01, 2020 @02:49AM (#23698519)
> Bootloader unlock is under user control by definition - it won't happen unless you're physically interacting with the device.

Root exploits more common, but bootloader exploits aren't unknown. String them both together and you can remotely root a device, unlock the bootloader, install another OS, and relock the bootloader. All of this without removing apps or data; do it properly (custom recovery for flashing the new OS) and all the user knows is that the device wasn't working for a while (until they notice the giant new notification Google services puts up now, but some users don't even know what notifications are and either won't notice or will ignore it) https://github.com/segv11/boot-unlocker

Re:System Hardening in Android 11 by Feolkin on Wednesday July 01, 2020 @07:34AM (#23700315)
Wait, this is possible without wiping data/apps? That's insane.
Re:System Hardening in Android 11 by pricechild on Tuesday June 30, 2020 @07:11PM (#23695886)
I would be more sympathetic to this plan if it were also tied to update status.

Imagine manufacturers having the incentive to issue monthly security updates, else their users get very angry they can't watch Netflix/log into their bank app/use google pay...

Re:System Hardening in Android 11 by anoncake on Tuesday June 30, 2020 @08:48PM (#23696543)
My bank telling me what software I may use on my personal property is not legitimate.
Re:System Hardening in Android 11 by jiggunjer on Wednesday July 01, 2020 @09:32AM (#23701107)
Isn't Google pay the same?
Re:System Hardening in Android 11 by anoncake on Thursday July 02, 2020 @02:15PM (#23716264)
It is, that is no excuse. Also it's harder to avoid banks than Google Pay.
Re:System Hardening in Android 11 by hddherman on Tuesday June 30, 2020 @02:22PM (#23693090)
I switched recently to an iPhone after 6 years on Android, including messing around with Cyanogenmod/LineageOS. It's not that bad, especially considering that Android is reaching the same level of lockdown that Apple has enforced, so you might as well use something that is reasonably secure and has official software update support for 5+ years.
Re:System Hardening in Android 11 by Iolaum on Tuesday June 30, 2020 @06:58PM (#23695779)
As long as Google allows installation of apps outside the play store this will not happen.

Moreover Google devices are the most open modern mobile devices out there now (I am intentionally excluding Librem5 and Pinephone). That is because on a Pixel you are allowed to relock the bootloader and load an image that you self signed!! This has spawned a niche ecosystem of android forks on pixel devices (look for RattlesnakeOS, GrapheneOS, CalyxOS).

Re:System Hardening in Android 11 by sangfroid_bio on Tuesday June 30, 2020 @04:13PM (#23694271)
Another duopoly that needs more competition is push notification infrastructure. Efficient push notification requires OS vendor server support due to radio usage and agreements with telecommunication companies. Everybody is obsessed with closed app stores and completely missing the net neutrality aspect of the iOS/Android duopoly.
Re:System Hardening in Android 11 by zozbot234 on Tuesday June 30, 2020 @04:38PM (#23694515)
It's not clear that push notifications have to be centralised. The OS could coalesce requests for notifications while still querying multiple sources, thus minimizing the time that radios have to be powered on.
Re:System Hardening in Android 11 by izacus on Tuesday June 30, 2020 @04:50PM (#23694626)
Except that push notifications also require work on telco's side to make sure they don't accidentally cause large battery use.

E.g. there was a long time after Apple introduced push messages where iPhone battery would drain pretty fast because many telcos would have very short connection timeouts on their routing equipment. This forced the phone to wakeup the radio a lot to reestablish connection.

This was "fixed" by whitelisting Apple/Google endpoints, so I wonder how that would work in federated environment.

Re:System Hardening in Android 11 by zozbot234 on Tuesday June 30, 2020 @04:57PM (#23694698)
> This forced the phone to wakeup the radio a lot to reestablish connection.

Perhaps, but if you can tolerate some latency, you might not have to wake the radio all that much. A huge majority of notification use cases can be delivered "late" (at least if the phone is in sleep mode) and still be useful.

Re:System Hardening in Android 11 by richardwhiuk on Tuesday June 30, 2020 @06:26PM (#23695495)
Yes, and I believe both GCM and APNS perform cross-app notification coalescing, whereby a low priority notification (e.g. a news article, or some other content update) will picky-back on a high priority notification (incoming call, text message).

This is extremely valuable in reducing power usage.

(Notifications both exhibit radio usage, but also will typically turn on the display, which is a huge battery sink)

Re:System Hardening in Android 11 by g_p on Tuesday June 30, 2020 @07:19PM (#23695941)
I was involved in designing a POC that proved this many years ago now (but after Doze appeared on Android, causing power saving issues). Note this was all for Android though, and I think Apple's restrictions make it very difficult to do this there.

There is a nice model for federating push services, and it worked. If you give apps a push "token" that takes the form of a URI or email-like address, the token can be namespaced by the push server provider. That can be self-hosted. An application can send push messages via websockets or a similar transport to the user's token-defined push server, and the user's apps can listen to it.

The long and short of it was that an app implementing the "push client library" would be able to do push messaging in a power efficient way, and it meant you could still only query 1 source server, that was configured well for long-lived connections. The trade-off is that you need app developers to really want to use it, and be willing to send the push messages to servers identified by the push token/URI.

Re:System Hardening in Android 11 by chrismorgan on Wednesday July 01, 2020 @03:33AM (#23698817)
That sounds to be exactly what the Push API (https://w3c.github.io/push-api/) is for the web: code can ask the user agent, “please give me a push endpoint”, and the UA gives it a URL, and then the code sends that URL to its backend server, which can then push to that endpoint, and messages will end up back at the user agent and be handed to the relevant code. On desktop platforms, Firefox defaults to using a Mozilla-operated push service, but on Android it could in theory use FCM, or Samsung’s equivalent, &c. if they supported the API.

I really don’t understand why mobile OSes don’t just adopt the Push API wholesale. Android especially. It’s such a mess having each app do its own thing and then have all kinds of problems with power saving measures; why not instead let the OS declare the push service to use (Google phones use FCM, Samsung phones use a Samsung push service, &c.), and apps just use what they’re given?

Re:System Hardening in Android 11 by corty on Tuesday June 30, 2020 @05:15PM (#23694876)
The most efficient decentralized way would be direct end-to-end connections. One could assign an IPv6 address to each application and have the notifications just sent there, no middleman necessary. If an application takes up too much battery, just kill it by changing the address.

That would be a killer app for IPv6 if mobile networks were up to it...

Re:System Hardening in Android 11 by owowow on Tuesday June 30, 2020 @07:39PM (#23696108)
Many LTE networks are IPv6 first, with IPv4 only services generally performing much worse or being unreachable. All 3 US Cell carriers have made this jump, though you see people complaining about IPv4 only sites and services not loading or working poorly through CGNAT.
Re:System Hardening in Android 11 by corty on Wednesday July 01, 2020 @05:30AM (#23699601)
Yes, but for my approach to work, the device would have to be able to use multiple addresses that are preferrably randomized. Not sure that that will work everywhere.
Re:System Hardening in Android 11 by fomine3 on Wednesday July 01, 2020 @03:51AM (#23698955)
Do you have any references about agreements or requirements?
Re:System Hardening in Android 11 by stiray on Wednesday July 01, 2020 @07:59AM (#23700449)
I am running lineage microg rom and I was literally forced to reverse my banking app (for its usage I am paying to my bank) and remove safetynet and various root checks to be able to use it (luckly they are not updating it very often).

The android ecosystem is toxic to the point where software developers are raging a war against their users.

Luckly there are still projects like lineage and microg where the software is still under control of their users, but google is slowly plugging the holes.

I hope that the true linux on phones (pine?) will emerge and stop this exploitation of user rights.

Re:System Hardening in Android 11 by jhasse on Wednesday July 01, 2020 @08:41AM (#23700691)
> I hope that the true linux on phones (pine?) will emerge and stop this exploitation of user rights.

Then your banking app won't be available at all.

Re:System Hardening in Android 11 by chinhodado on Tuesday June 30, 2020 @02:39PM (#23693286)
> apps can't simply access the "external" storage (enforces scoped storage)

So how will perfectly valid use cases like file manager or backup manager work now?

Re:System Hardening in Android 11 by Mindwipe on Tuesday June 30, 2020 @02:48PM (#23693386)
A File Manager can ask for root folder access permission but Google will closely control which applications in the Play Store can do so (but if you think that sounds good this is also the same policy they have for SMS access, and Google's enforcement of that has been disastrous as review on the Play Store is a dismal mess).

However, this will no longer get you access to Application's own folders, and so backing things up on Android gets even harder and the OS gets more anti-user.

(To be clear, this should absolutely be behind a Permission barrier. But to block off user access entirely is a toxic and unhelpful move that makes the platform less useful).

Re:System Hardening in Android 11 by dredmorbius on Tuesday June 30, 2020 @05:02PM (#23694745)
Or the One Android App That Does Not Suck: Termux?
Re:System Hardening in Android 11 by asveikau on Tuesday June 30, 2020 @05:43PM (#23695134)
Media players are also a big deal for this. I put a lot of audio and sometimes video on my sd card and expect to be able to browse and play it. I am actually doing that right now as I type this.
Re:System Hardening in Android 11 by Drawde on Tuesday June 30, 2020 @07:36PM (#23696079)
Sadly it seems that prior restrictions in Android have already taken their toll on Termux: https://news.ycombinator.com/item?id=23224669
Re:System Hardening in Android 11 by dredmorbius on Wednesday July 01, 2020 @07:52AM (#23700421)
Yeah.

So much the worse for Android.

Re:System Hardening in Android 11 by Noluris on Tuesday June 30, 2020 @02:45PM (#23693349)
Scoped storage is going to kill all the most useful apps that I use that require full access to storage (such as SyncThing). I'm going to keep using Android 10 until I die. Or just switch to Apple, since if they're going to lock everything down, I might as well go with the company that supports their phones longer than two years.
Re:System Hardening in Android 11 by GlitchMr on Tuesday June 30, 2020 @05:57PM (#23695259)
An application can require MANAGE_EXTERNAL_STORAGE permission to access all files.
Re:System Hardening in Android 11 by Namidairo on Wednesday July 01, 2020 @01:17AM (#23697988)
I have a feeling that certain apps will end up forcing their users to accept the popup for this permission in order to continue scanning their storage for "bad" filenames. (A few mobile games rolling their own "protection" by looking for TWRP-related folders, for example)
Re:System Hardening in Android 11 by GlitchMr on Wednesday July 01, 2020 @03:15AM (#23698678)
Unlikely. It's going to be a restricted permission on Google Play, which means the application must have a good reason to use it. Specifics will be provided later, but I'm pretty sure a mobile game won't have a reason to use this permission.

> Note: The MANAGE_EXTERNAL_STORAGE permission allows apps to access potentially sensitive data on shared storage. In an upcoming policy announcement, look for Google Play to provide guidelines for apps that need this permission.

Re:System Hardening in Android 11 by kelnos on Tuesday June 30, 2020 @05:27PM (#23694992)
My guess would be that apps that target an earlier Android version will continue to work properly, even on Android 11.

Ok, maybe that's more my hope than my guess. We'll see.

Re:System Hardening in Android 11 by cesarb on Tuesday June 30, 2020 @07:06PM (#23695835)
Yes, but the other half of that is that Google will require that new uploads to the Google Play Store target newer Android versions. That is, older applications will not break, but newer applications (and newer versions of older applications) will not be allowed to use that loophole anymore. (Of course, you can still sideload...)
Re:System Hardening in Android 11 by Vespasian on Tuesday June 30, 2020 @02:26PM (#23693143)
The security changes are nice and needed so well done.

Enforcing SafetyNet is probably also a net positive change, and you (and I) are a minority among the general user base. Sadly this was always coming, it was nice while it lasted, I guess.

I'm not quite sure what I will do once my current phone dies. I don't see myself investing in the Apple ecosphere, so either go with the time (do nothing) or have a second phone for "secure" apps (Banking, Netflix) etc.

Re:System Hardening in Android 11 by josephcsible on Tuesday June 30, 2020 @05:54PM (#23695229)
> Enforcing SafetyNet is probably also a net positive change

How so? How does SafetyNet make any end-user even slightly more secure?

Re:System Hardening in Android 11 by blendergeek on Tuesday June 30, 2020 @10:47PM (#23697226)
It does not. Enforcing SafetyNet only makes it harder for users to use custom ROMs. It provides no benefit whatsoever to the end user.

It does provide major benefits to app makers who hope to control the user's device.

Re:System Hardening in Android 11 by Vespasian on Wednesday July 01, 2020 @05:55AM (#23699738)
I agree that DRM, and control is probably the main reason why they are doing this.

However, most people do not unlock their bootloaders and install custom ROMs.

For them having an unlockeded system is an indication of something "bad" happening (spying, fraud, theft) and given how central smartphones are becoming in users life, I prefer that my mothers banking app refuses to work if her smartphones chain of trust is compromised.

I also happen to believe that it is impossible to "out-tech" OEMs in the long run and that the path to a fair app ecosystem is through legislation, regulation and anti trust measures.

That approach worked in other aspects of the economy and society.

Re:System Hardening in Android 11 by realusername on Wednesday July 01, 2020 @08:03AM (#23700471)
> For them having an unlockeded system is an indication of something "bad" happening (spying, fraud, theft) and given how central smartphones are becoming in users life, I prefer that my mothers banking app refuses to work if her smartphones chain of trust is compromised.

In real life, the main security issue on smartphones right now is dubious quality stock ROMs and checking the bootloader won't help you with that.

The move should be in the opposite direction, it should be impossible for security reasons to query if the bootloader is unlocked or not from the device itself.

Re:System Hardening in Android 11 by josephcsible on Wednesday July 01, 2020 @09:55AM (#23701346)
It doesn't matter whether your mother's banking app refuses to work. If her phone gets rooted, the attacker will replace it with an app that steals her credentials and then refuses to work. So even in that case, SafetyNet provides exactly zero security to the end user.
Re:System Hardening in Android 11 by blendergeek on Wednesday July 01, 2020 @08:02AM (#23700465)
Before we enact new regulations in the hope of forcing corporations to build a 'fair' app ecosystem, I would argue step 1 is to repeal section anti-circumvention laws that give big tech one more stick to hit consumers with.
Re:System Hardening in Android 11 by ocdtrekkie on Tuesday June 30, 2020 @03:52PM (#23694077)
If you have wireless chargers and don't really want paid apps, you can reasonably avoid "investing" much in the Apple ecosphere these days: I have not once since switching bought something with a Lightning connector on it, and I rarely use the charger that came with it either. And the new iPhone SE is more or less the cheapest way to get a phone that's updated and well-supported.
Re:System Hardening in Android 11 by Vespasian on Wednesday July 01, 2020 @05:56AM (#23699743)
I might actually take another look at it :)
Re:System Hardening in Android 11 by pantalaimon on Tuesday June 30, 2020 @04:13PM (#23694273)
What about Magisk? When you have full control over the system, you can pretend everything to Userspace Apps.
Re:System Hardening in Android 11 by grishka on Tuesday June 30, 2020 @04:32PM (#23694445)
If I understand these SafetyNet changes right, it's now relying on TrustZone, where "trust" frankly means distrusting the end user. This runs on a privilege level above the OS kernel, and it isn't possible to modify that firmware or extract data from it even with the unlocked bootloader, by design. It's currently used for media DRM among other things.
Re:System Hardening in Android 11 by mschuster91 on Tuesday June 30, 2020 @06:09PM (#23695346)
Jeez, WTF. Looks like I have to buy a new tablet (my old one is on its last legs) before this shit hits the markets, no way I'm gonna have a device that is either not rootable at all or keeps me from using mobile banking.

I'm all for more security measures, but not at the cost of giving up my freedom entirely.

Re:System Hardening in Android 11 by Mindwipe on Tuesday June 30, 2020 @06:25PM (#23695473)
The vast majority of devices sold today already support the hardware, so you're too late if you feel you're not willing to tolerate this.
Re:System Hardening in Android 11 by j88439h84 on Tuesday June 30, 2020 @02:17PM (#23693040)
What does external mean? SD card? or anything outside the app's own directory?
Re:System Hardening in Android 11 by igorstellar on Tuesday June 30, 2020 @02:25PM (#23693137)
External storage used to be a shared storage for apps outside of it's sandbox. Files are retained after app is uninstalled. [1]

[1] https://developer.android.com/training/data-storage

Re:System Hardening in Android 11 by vorpalhex on Tuesday June 30, 2020 @02:36PM (#23693244)
This was abused by several apps to allow locating and identifying users illicitly. One app, say, WeChat, would ask for broad permissions for location and unique identifiers and then leave unique tracking identifiers in a shared file location. Than another app, say, a mobile game, could pick up on those shared identifiers and link you back.

Why this would be a useful benefit worth setting up in an SDK across multiple companies and apps, I'll leave to your own imagination.

Re:System Hardening in Android 11 by kevin_thibedeau on Tuesday June 30, 2020 @02:54PM (#23693461)
This would be solved if they just ported over the revokable permissions that LineageOS implements. You get real security and the app is none the wiser.
Re:System Hardening in Android 11 by grishka on Tuesday June 30, 2020 @04:41PM (#23694533)
It's not like the switch to scoped storage would mitigate much of it. You can still do all kinds of nasty things when you, for example, have access to the photo library part of the MediaStore content provider. Like adding your tracking ID to the metadata of a picture that other app would then look for. Or, you could just create a "photo" and write your arbitrary data in place of the file contents. Users won't ever notice there's a broken image at the end of their camera roll.

Will this change make it look more suspicious when apps request access to photos instead of storage? Yes, sure. Will most users care about it and deny access to apps that aren't supposed to have it? Of course not.

Re:System Hardening in Android 11 by usrusr on Tuesday June 30, 2020 @06:38PM (#23695610)
Why would you even break the photo? Steganography goes back hundreds of years before computers. The only challenge is too make the user keep some of the watermarked pictures (the OS can keep you from writing to files created by other apps. They are sacrificing far too much for a fight they cannot win.
Re:System Hardening in Android 11 by CameronNemo on Tuesday June 30, 2020 @02:44PM (#23693347)
I wonder how this will impact my externally stored music library, which is accessed by two open source apps (Vanilla Music and Alarm Klock) but not managed by those apps or tied to their lifetimes.
Re:System Hardening in Android 11 by throwaway9d0291 on Wednesday July 01, 2020 @06:16AM (#23699874)
> These are welcome changes in my view, but unfortunately they also seem intend to fix SafetyNet and require hardware attestation that the bootloader is not unlocked [1].

The problem with unlocked devices is that it's a legitimate security risk.

With a signed OS and hardware attestation, you can verify with 100% certainty that the foundation of the device's security model is there and fully intact. Upon that foundation you can build features that you might not be comfortable with otherwise, like an OTP app, authenticator app or a payment app. You wouldn't build an "OTP" app for Windows for example because Windows doesn't have a solid security model, it's quite easy for one application to access another application's resources.

Once that foundation is broken, all bets are off. If the bootloader is unlocked, you have no way of knowing what's running on a user's device. For all you know, all of the permission checks have been removed and nothing is secure anymore. Even the APIs you'd expect to interact with a secure enclave could be replaced.

Others are suggesting that this is the user's choice and so perhaps developers should just deal with it but I disagree. A device isn't necessarily unlocked by the user. A device can be unlocked by anybody with physical access and the passcode. For example a malicious party could install a malicious version of Android on your device if they have unattended access to your phone for a while. They could also buy phones, flash malicious versions of Android and then sell them at a slight loss, making profit off the money stolen from their victims.

There's also the problem of malware that gains root privileges. With a locked bootloader, there's limited opportunity for such malware to become persistent. It can't modify the system partition at all. With an unlocked bootloader, it can modify the system partition and permanently modify the OS. Basically, locking the bootloader prevents rootkits.

This is why these features are here. They're not here to make enthusiasts' jobs harder, they're here to provide a solid foundation of security upon which an OS that's secure enough to handle high-value information can be built.

> When this is enforced for all devices some apps, like the eBay app, won't run on unlocked devices anymore.

In some cases (e.g. games), I think this is ridiculous. For apps that deal with finance or other sensitive areas, as explained above, I think this is entirely reasonable.

All that said, I can see a world in which we have custom ROMs as well as security:

- We make custom signing keys [0] commonplace, not just a thing for Pixel devices.

- Set up an automated service through which a device can submit CTS [1] results and have its build of Android whitelisted.

[0]: https://android.googlesource.com/platform/external/avb/+/mas...

[1]: https://source.android.com/compatibility/cts

Re:System Hardening in Android 11 by Feolkin on Wednesday July 01, 2020 @07:39AM (#23700350)
I'd say this is the biggest issue. I own both a rooted, unlocked Android phone and a locked Samsung tablet. I have no way to know how safe any particular custom ROM is, so there's no way I'm willingly going to use any of the banking-/payment-related apps on my phone. I find it baffling that people put their trust in people who are largely anonymous and have no accountability.
Re:System Hardening in Android 11 by throwaway9d0291 on Wednesday July 01, 2020 @08:05AM (#23700476)
Depending on what your goals are, I'd recommend going down the route I chose: run AOSP.

Tagged releases of AOSP are the same base code that all the retail distributions of Android are based on, so should be just as safe.

If you have a Pixel device, the RattlesnakeOS project [0] will allow you to run your own automated AOSP distro, complete with OTAs, on AWS. It also supports adding a few modifications like MicroG.

All but the most recent Pixel devices are also supported by GrapheneOS, which is a security-focused ROM.

Both of these projects support signed builds, so once you flash them to your device, you can lock the bootloader.

[0]: https://github.com/dan-v/rattlesnakeos-stack

[1]: https://grapheneos.org/

Re:System Hardening in Android 11 by Feolkin on Wednesday July 01, 2020 @12:32PM (#23703342)
That's interesting, thanks. It's going to have to wait until I buy a new phone though, since my phone doesn't have anything like this. Which leads to the next problem. I bought my phone because of its crazy long battery life. Going to a Pixel is a significant sacrifice, which again annoys me about the state of Android.
Re:System Hardening in Android 11 by zozbot234 on Wednesday July 01, 2020 @07:46AM (#23700386)
> A device can be unlocked by anybody with physical access and the passcode. For example a malicious party could install a malicious version of Android on your device if they have unattended access to your phone for a while.

This wipes all existing data and notifies the user that the device is not secure whenever it's booted. There's no way that a user would fail to realize this. I agree that it's unrealistic to expect apps that directly deal with money/finance/etc. to be supported on unlocked devices, but aside from that it should be fair game.

Re:System Hardening in Android 11 by throwaway9d0291 on Wednesday July 01, 2020 @08:08AM (#23700497)
> There's no way that a user would fail to realize this.

I think you place far more trust in an average user than they deserve. If a user saw that their phone was factory reset and had a scary warning, I can easily see many users happily ignoring it and setting up their phone again, assuming it was the result of some bug.

The more tech-savvy HN crowd might be worried and flash it with fastboot to be safe but don't expect that of a random average person.