News for hackers. Stuff that matters.
Re:Pokemon Go, Security, and Obsolescence by pwnna on Sunday October 16, 2016 @01:57AM (#12717198)
Now Niantic's decision to disallow root devices, imo, is pretty regretful, as serious botters will likely be able to get around that restriction regardless. This only serves to punish users who are stuck between having a root-enabled custom ROM or a stock ROM where critical root exploits may exist.

One thing that I observed is that no one seems to be interested in producing a ROM that is both stable, has a variety of features, do not rely on root, and supports the device for a long time.

This is a shame really, because root itself breaks the security mechanism for android and users probably are not fully aware what it means when they grant applications root.

I personally got around this problem by compiling a build of CyanogenMod without root enabled, but with things like FDroid (with PrivilegeExtension) and adblock built-in to the ROM itself (albeit the update mechanism is to update the ROM it self). This is not a solution for the mass majority of users.

This problem is pretty difficult to solve and it is pretty deep, much deeper than what I'm willing to type in a single comment, so I'll stop here.

Re:Pokemon Go, Security, and Obsolescence by djsumdog on Sunday October 16, 2016 @02:32AM (#12717299)
I wrote this about Android a while back:

http://penguindreams.org/blog/android-fragmentation/

The TLDR is that it'd be nice if Android was more like Windows/Intel: install the OS (i.e. AOSP), drivers (or binary driver package format and an SDK to auto-build it) and boom you're done. Clean, stock, standard. Same with many Linux distros on x86/64.

I need to write an update to the article though. Lately I've been struggling with a Clearfog ARM board, and coupled with Torvald's recent comments on Intel vs ARM, I wonder if a huge chunk of the problem is ARM itself.

I've noticed for every distro there are really specific images, not just for each ARM chipset, but for individual boards, even when those manufacture patches make it into the mainline kernel.

I haven't looked closely at Android and I'm really curious at the build system/workflow used by things like Cyanogen and Omnirom. Are kernels really specialized per device? Does the ARM architecture itself make it difficult to have general purpose kernels that will boot on all of them like in the x86/64 world?

Any ARM hardware people care to chime in?

Re:Pokemon Go, Security, and Obsolescence by exDM69 on Sunday October 16, 2016 @06:53AM (#12718035)
> Any ARM hardware people care to chime in?

It's not really about the CPU architecture, but the peripherals of the devices. In the x86 world, the peripherals are governed by the "PC" standard, which these days is implemented by the chipset on your motherboard. They all have similar functionality, although you still do need some chipset-specific drivers in your kernel.

In the ARM world, the landscape is different. There has never been a de facto standard configuration of an ARM computer like the PC was/is for x86. There are ARM computers that are more like a micro controller and there are tablet/mobile devices based on ARM that have a system on chip (SoC) that's got all the peripherals, including GPUs, network adapters, etc. Every SoC is pretty different, there's a bunch of devices connected with i2c, spi and other buses. These are required to control the power and clock management and all the I/O devices.

ARM (the company) doesn't really design these, they just license ARM (the architecture) to a SoC manufacturer and call it a day. This leads to a very diverse and fragmented landscape.

The ARM world has been making strides to reduce the amount of chip-specific code. One good example is the device-tree configuration which, in theory, allows running the same kernel binary on different devices. With device-tree, you pass a config file from the bootloader to the kernel, which contains configuration (i/o memory maps, etc) of the peripherals (which you'd query from the hw/firmware in a x86 machine). This is a huge improvement over what was before it, but there's still a long way to go. And there's still plenty of older ARM SoCs out there that don't support this.

But yes, it's pretty much a mess. There's a lot of duplicate work that every ARM SoC manufacturer has to go through. Given that the mobile world is financed by a planned obsolescence cycle where they expect customers to upgrade every few years, I find it unlikely that this issue will be solved any time soon.

Re:Pokemon Go, Security, and Obsolescence by makomk on Sunday October 16, 2016 @07:17AM (#12718105)
To be honest, x86 seems to be heading in the same direction these days. It generally has enough of an emulation of traditional PC architecture for boot purposes, but look at - for example - how CPU power saving on modern Intel chips requires the co-operation of stuff like the SATA links, or how traditional PC interfaces like PS/2 for keyboard/mouse and HD Audio are being replaced with more embedded-like interfaces such as I2C touchpads and I2S audio links connected to vendor-specific controllers.
Re:Pokemon Go, Security, and Obsolescence by exDM69 on Sunday October 16, 2016 @07:55AM (#12718208)
Sure, but it isn't as diverse so you can reasonably expect to boot a mainline kernel on a PC regardless of your motherboard vendor.
Re:Pokemon Go, Security, and Obsolescence by pjmlp on Sunday October 16, 2016 @02:58AM (#12717385)
It is like the old days of home computers.

We had Z80, 6509, 68000 and so so, but everything else that was plugged into their pins was different.

So it doesn't matter if the Assembly is the same, the kernel also needs to talk to the hardware.

Also ARM just resells the base designs, each company usually adds they own set of Assembly instructions or fine tunes the designs in some other way.

The IBM PC clones were the only ones that had some kind of standardization going on, and even that seems to be gone now, with OEMs going to the same kind of hardware designs we used to have (everything bolted on the board).

Re:Pokemon Go, Security, and Obsolescence by cheiVia0 on Sunday October 16, 2016 @02:57AM (#12717378)
Debian is shipping one Linux kernel build that runs on a bunch of different ARM devices that are supported by the mainline version of Linux:

https://wiki.debian.org/DebianKernel/ARMMP

Unfortunately most mobile devices are not supported by mainline Linux (N900 is best supported, but not fully), usually only server/desktop/laptop vendors have any incentive to mainline their drivers.

Re:Pokemon Go, Security, and Obsolescence by voltagex_ on Monday October 17, 2016 @01:14AM (#12722808)
The 2013 Nexus 7 was, at some point, 50 patches away from running mainline [1]. I know, single datapoint, but it gives me hope that there's some way out of the tabletification of computing.

1: https://wiki.linaro.org/LMG/Kernel/FormFactorEnablement

Re:Pokemon Go, Security, and Obsolescence by evilDagmar on Sunday October 16, 2016 @12:25PM (#12719359)
Android kernels are built differently from PC kernels because unlike a PC where you might upgrade the motherboard, or add/remove hardware that would change what kernel modules are needed (and still expect the PC to boot), a cell phone almost never changes its hardware configuration after installation. If the phone is a Wombat 4s, it'll have X, Y, and Z hardware components and these will never ever change. If it's a Foobar 8000, it'll have X, Y, and Q, and there might be two different sizes of W which aren't even something that requires a driver and those will never change either. Including all the modules that might be present on any device compatible with the same CPU architecture would mean wildly more than 90% of the space used by the kernel/drivers would be completely and utterly wasted (and theres at least four more types of resources that would also be wasted that come to mind). This is not a thing one does with a device expected to run as long as it possibly can with a very limited supply of power and less RAM than pretty much any desktop machine you'd care to use.
Re:Pokemon Go, Security, and Obsolescence by cheiVia0 on Sunday October 16, 2016 @03:13AM (#12717436)
Re:Pokemon Go, Security, and Obsolescence by legulere on Sunday October 16, 2016 @03:31AM (#12717490)
A few botters don't hurt Pokémon go. But when it's easy to bot, lots of people will bot. It's easy to circumvent anti root, but it's impossible to use the same way for lots of devices without niantic being able to block it again.

So it really makes sense for them to go this way IMO.

Re:Pokemon Go, Security, and Obsolescence by Drdrdrq on Sunday October 16, 2016 @04:48AM (#12717684)
Not really. It doesn't matter if the phone is rooted or not, what matters is whether it is feeding false gps data or not. Bots will soon find a way around this (non-rooted) restriction anyway.

That said, proper protection against cheating would involve using markers (other phones?) in vicinity, so it should be possible too.

Re:Pokemon Go, Security, and Obsolescence by rickyc091 on Sunday October 16, 2016 @07:53AM (#12718203)
Yes, bots will most likely always find a way, but I think it's more about thwarting the casual users. If you could gps hack by simply installing an app more people would do it. By making it extremely tedious, the causal user won't be as inclined to do it since the time it takes to figure it out won't be worth it.

I don't condone Niantic's behavior, but I understand it.

Re:Pokemon Go, Security, and Obsolescence by mynameisvlad on Sunday October 16, 2016 @12:12PM (#12719264)
To me, it would make more sense if they weren't also banning users their auto-detection system thinks are spoofing GPS. A system which is fairly overzealous, might I add. I was banned for being in Japan, for example. One day out of the blue on my vacation, got the ToS violation notification which still hasn't been reversed, two weeks later.
Re:Pokemon Go, Security, and Obsolescence by evilDagmar on Sunday October 16, 2016 @12:30PM (#12719394)
The spoofers have had a way around this for some time now, as GPS spoofing simply does not require root privileges.

Niantic is not actually making any attempt to look for GPS spoofing software. They simply invoke Android's SafetyNet which doesn't care about GPS at all but does care about other things which happen to coincide with what's on some cheater's phones. It will never be anything like an effective measure against GPS spoofing.

Re:Pokemon Go, Security, and Obsolescence by tombrossman on Sunday October 16, 2016 @03:13AM (#12717435)
> I personally got around this problem by compiling a build of CyanogenMod without root enabled, but with things like FDroid (with PrivilegeExtension) and adblock built-in to the ROM itself...

I just bought a Nexus 5x and loaded CopperheadOS on it, and to my dismay I see Ad-Away from F-Droid requires root to function (plus a couple other apps I really like). How much of a hassle is it really, because I absolutely want system wide ad blocking and I worry that I will be defeating the purpose of using a hardened OS in the first place?

Do you rebuild and flash each OS update as a new ROM? Is all your data on the phone persistent or backed up & restored each time?

Re:Pokemon Go, Security, and Obsolescence by pwnna on Sunday October 16, 2016 @11:05AM (#12718897)
> How much of a hassle is it really, because I absolutely want system wide ad blocking and I worry that I will be defeating the purpose of using a hardened OS in the first place?

Ad-away works by using a host file to block. The hosts file is generally not writable by the user without root as it lives on a read only partition (/system).

Another way to block ads is to connect to a VPN that blocks thoses hosts for you, however that is more cumbersome to setup.

While hosts blocking is not perfect... my thought on this was to expose a limited API that allows apps to update the hosts file without having root. This could be sketchy and a security risk on its own tho, because you're essentially hijacking DNS... In addition, I don't think the community is interested in this because they all love root..

> Do you rebuild and flash each OS update as a new ROM?

Every month, immediately after the security bulletin and a resync.

> Is all your data on the phone persistent or backed up & restored each time?

So android has a /system partition and a /data partition. When you reflash your system, the data partition (where all your apps, settings, what not are stored) is left untouched. Android will detect this and perform an upgrade operation on the /data partition, if applicable.

Re:Pokemon Go, Security, and Obsolescence by nradov on Sunday October 16, 2016 @12:36PM (#12719427)
Apple added specific ad blocking features to iOS 9, and I don't think those rely on editing the hosts file. So in principle a similar design could work for Android, although I doubt Google would ever support that.
Re:Pokemon Go, Security, and Obsolescence by lern_too_spel on Sunday October 16, 2016 @01:34PM (#12719767)
Apple added specific ad-blocking features to its browser on iOS 9. There are plenty of browsers that support ad blocking on Android, and they have existed since pretty much the beginning.

It is also possible to block ads in other apps on Android. One way is to use a custom hosts file that blackholes ad-serving domains. The hosts file is stored on a read-only partition for security purposes on most builds of Android, so overwriting it requires root. Another option is to point your phone to a DNS server that does the same thing. This does not require root and works across multiple platforms. Another Android-specific option is to use the VpnService API to implement filtering in an app that does not use root but gets to see all other apps' Internet traffic. There are several apps that do this.

Re:Pokemon Go, Security, and Obsolescence by lewisl9029 on Sunday October 16, 2016 @07:22AM (#12718126)
I honestly would be very happy with a ROM that copies stock Android entirely, without any added features or customizations, rather focusing solely on stability, security, supporting a wide range of devices, and tracking the official Android release schedule as closely as possible.

Can someone point me to a ROM like this if one already exists?

Re:Pokemon Go, Security, and Obsolescence by vardump on Sunday October 16, 2016 @08:57AM (#12718396)
> any added features or customizations

That's not only about UI. Most people want customizations / features that enable things like 4G radio, wifi and graphics. What would be the point otherwise?

Re:Pokemon Go, Security, and Obsolescence by lewisl9029 on Sunday October 16, 2016 @10:19PM (#12722317)
Maybe I should have been a bit more specific, but I was mostly just talking about UI features and customizations. I have no problems with a ROM modifying stock Android under the hood if it's necessary to enable basic hardware functionality. The point is to keep modifications to a bare minimum, to limit the overhead required to support each new Android release, and to maximize the number of devices the ROM is able to support given limited resources.
Re:Pokemon Go, Security, and Obsolescence by RDaneel0livaw on Sunday October 16, 2016 @08:30AM (#12718308)
I was going to point you to the Pure series of roms by Beanstown, but I don't understand your question... You don't want ANY custom stuff at all or features, then what's the point? Just install stock android...?
Re:Pokemon Go, Security, and Obsolescence by ferbivore on Sunday October 16, 2016 @09:31AM (#12718511)
"Stock Android" is only stock Android on Google-branded devices.
Re:Pokemon Go, Security, and Obsolescence by RDaneel0livaw on Sunday October 16, 2016 @10:15AM (#12718662)
I don't understand this sentence. Google only has a single phone that has only been out for like 1 day now, the Pixel. And it's not even stock Android, it's got extra features that the stock Nougat doesn't have. Again though, I think this whole thing is moot, because lots of phones have roms on xda that is basically just stock android with no customizations, so just install that and be done with it.
Re:Pokemon Go, Security, and Obsolescence by ferbivore on Sunday October 16, 2016 @12:46PM (#12719492)
I said Google-branded, not Google-manufactured. The Nexus line is what people typically understand by "stock Android".

The point isn't that there are no vanilla AOSP ROMs for most devices. The point is that they usually suck, and a reputable well-supported one that actually worked properly would be a massive innovation.

Re:Pokemon Go, Security, and Obsolescence by nucleardog on Sunday October 16, 2016 @12:53PM (#12719538)
ADP1, Nexus One, Galaxy Nexus, Nexus 4, Nexus 5, Nexus 6P.

When people say "Google's phones" it is generally understood to mean the unlocked line of Nexus devices that they sell directly and provide updates/firmware images for directly.

Re:Pokemon Go, Security, and Obsolescence by tedmiston on Sunday October 16, 2016 @02:43AM (#12717333)
They've gotta stop the GPS spoofers somehow.

It's not like this was the first solution they jumped to to stop cheaters.

Maybe this was the 80/20 solution over more advanced location anomaly detection methods against their database.

Re:Pokemon Go, Security, and Obsolescence by lini on Sunday October 16, 2016 @02:52AM (#12717364)
The problem is that you don't need root for GPS spoofing. Botters also don't care about SafetyNet (used to detect root before the game starts), since they reverse engineer the API and make REST calls directly. Furthermore, there are ways around the root check - mostly involving hiding the su binary and some additional tweaks.
Re:Pokemon Go, Security, and Obsolescence by deanclatworthy on Sunday October 16, 2016 @03:18AM (#12717449)
Furthermore, you can buy GPS spoofing devices anwyay which you can just carry around with you in your pocket.
Re:Pokemon Go, Security, and Obsolescence by kalleboo on Sunday October 16, 2016 @03:56AM (#12717550)
Is that really something that's available? Nothing turned up on a cursory web search, aside from a story about students building their own with $3,000 dollars worth of equipment (and it sure didn't fit in a pocket)

edit: And Wikipedia says "GPS spoofing attacks had been predicted and discussed in the GPS community previously, but no known example of a malicious spoofing attack has yet been confirmed"

Re:Pokemon Go, Security, and Obsolescence by deanclatworthy on Sunday October 16, 2016 @04:13AM (#12717584)
They're highly illegal under US laws but from my reading around this topic, as someone who is currently building a gps-dependent app, is it's feasible.
Re:Pokemon Go, Security, and Obsolescence by mrswag on Sunday October 16, 2016 @06:27AM (#12717938)
It's cheaper than that. A HackRF and some sort of better clock and you're done.

http://www.rtl-sdr.com/cheating-at-pokemon-go-with-a-hackrf-...

Re:Pokemon Go, Security, and Obsolescence by Natanael_L on Sunday October 16, 2016 @05:17AM (#12717758)
Don't carry it around, though! Put the thing in a Faraday's cage, and use a cable through the mesh to get your Internet connection.
Re:Pokemon Go, Security, and Obsolescence by trakout on Sunday October 16, 2016 @12:04PM (#12719217)
Furthermore, you don't need a device at all if you want to bot. The unofficial API (and client-side signing) was figured out a while back.
Re:Pokemon Go, Security, and Obsolescence by bsder on Sunday October 16, 2016 @04:55PM (#12720889)
Got a link for that? I'd like to go read about it. Primarily as what NOT to do ... :)
Re:Pokemon Go, Security, and Obsolescence by swiley on Sunday October 16, 2016 @03:54AM (#12717542)
Man, you can probably crash some planes with those.
Re:Pokemon Go, Security, and Obsolescence by lucb1e on Sunday October 16, 2016 @08:32AM (#12718312)
Only if you carry the plane in your pocket too or set a way too high output power while sitting inside one, if even then.
Re:Pokemon Go, Security, and Obsolescence by foota on Sunday October 16, 2016 @03:34AM (#12717495)
To be fair, that's probably highly illegal if caught by the fcc.
Re:Pokemon Go, Security, and Obsolescence by seszett on Sunday October 16, 2016 @04:15AM (#12717594)
The FCC only has business in the US though.
Re:Pokemon Go, Security, and Obsolescence by lucb1e on Sunday October 16, 2016 @08:36AM (#12718332)
Almost every country has something like that. The Dutch Agentschap Telecom will hunt you down for transmitting a fake GPS signal too.

The thing is, nobody cares if you send a signal too weak to go beyond a meter of your pocket. That's why it's totally legal to send FM on registered frequencies as long as your output is under a certain amount. Same with WiFi even.

I heard about someone looking into GPS spoofing once in the context of catching drones, even nearby ones (e.g. fly near to it). It takes a lot of energy to do that and was basically not practical outside of military settings.

Re:Pokemon Go, Security, and Obsolescence by roywiggins on Sunday October 16, 2016 @09:58AM (#12718596)
This is not always true - FM transmitters were not legal in the UK, regardless of power, until 2011 or so. Can't imagine anyone was actually prosecuted for using one, though.
Re:Pokemon Go, Security, and Obsolescence by lucb1e on Sunday October 16, 2016 @12:01PM (#12719203)
If there is no chance of getting caught anyway, there is only moral law. Since you're not disturbing anyone with an FM transmitter in your car that transmits only as far as you car radio, it passes moral law.

Interesting to learn that it wasn't legal in the UK though. I wouldn't know of the legality in the Netherlands, but I know they're in use and nobody's complaining.

Re:Pokemon Go, Security, and Obsolescence by evilDagmar on Sunday October 16, 2016 @12:37PM (#12719432)
Wow. You really have to stop drinking the Kool-Aid. This actually was the first thing they did, and very possibly the only thing they've done specific to Pokemon.

Niantic uses the same techniques they used for Ingress to deal with GPS spoofers, and they're not that advanced. Play for an unrealistically long period of time without stopping and you might get a tempban and flagged for careful examination. Appear to travel at jet plane speeds by performing non-idempotent actions without stopping by an airport first, or doing this too many times in a short period, and you'll also get flagged for possible banning. Beyond that, they're really not doing much and it doesn't really qualify as "advanced localtion anomaly detection". You're giving Niantic far too much credit.

Re:Pokemon Go, Security, and Obsolescence by the8472 on Sunday October 16, 2016 @08:33AM (#12718319)
do you see PC multiplayer game devs block users that know the admin password?
Re:Pokemon Go, Security, and Obsolescence by lern_too_spel on Sunday October 16, 2016 @01:42PM (#12719825)
Yes, the author makes the fundamental mistake of thinking that custom ROMs and having root access are the same thing. It is possible to have a custom ROM that does not give the user root access, and such a configuration is more secure for the user.
Re:Pokemon Go, Security, and Obsolescence by evilDagmar on Sunday October 16, 2016 @12:14PM (#12719281)
You literally didn't need to do any of this (and I'm astonished someone would wait through a CM build rather than do ten minutes of research). Also, I'd like to remind you that SEAndroid (i.e., SELinux) doesn't give a fig about "root" so your statements about that are quite wrong.

You can simply rename your su binaries through the recovery environment to disable them, which neatly disables "root access" and makes the SafetyNet check Niantic is invoking pass with flying colors. Should you need them again, they're only a reboot and couple of mv invocations away.

Re:Pokemon Go, Security, and Obsolescence by pwnna on Sunday October 16, 2016 @02:03PM (#12719949)
> You literally didn't need to do any of this.

For me personally, this is not the reason for me to build CyanogenMod. I will occasionally modify certain things inside android to suit my needs and there are enough of these things that are not merged upstream that it's more convenient for me to just build my own version every month/week/whenever.

> Also, I'd like to remind you that SEAndroid (i.e., SELinux) doesn't give a fig about "root" so your statements about that are quite wrong.

This is an area i'm not quite informed, so maybe you can elaborate further.

The core issue that I wanted to express is that barely any community ROMs are CTS compliant, which is ultimately what SafetyNet checks.

> You can simply rename your su binaries through the recovery environment to disable them, which neatly disables "root access" and makes the SafetyNet check Niantic is invoking pass with flying colors. Should you need them again, they're only a reboot and couple of mv invocations away.

Doing a bunch of mv's is a hassle (esp over multiple devices) as I rarely ever need root on my phone. The only times when I need it nowadays is host based ad blocking, which I just integrated into my ROM. So this way I can just get rid of root all together, which is one more step towards CTS compliance.

Re:Pokemon Go, Security, and Obsolescence by evilDagmar on Monday October 17, 2016 @01:30AM (#12722873)
It's two mv invocations. That falls quite a bit short of "a bunch of mv's". It doesn't exactly qualify as going out of one's way when most of us are already going through recovery (like TWRP) to install the updates.

SEAndroid/SELinux is a mandatory labeling system, which simply doesn't believe in special UIDs at all. It gives us pretty incredible granularity of control over things as well. Deny/grant access any number of users to each and every object and facility of the system, in any combination you like. Just understand that there's a steep and somewhat unforgiving learning curve and the documentation on what labels have been put into play on any given deployment has a strong and nearly universal tendency to suck until you're looking directly at the source code that sets up those rules.

Re:Pokemon Go, Security, and Obsolescence by xorcist on Sunday October 16, 2016 @04:06PM (#12720659)
How do you non-root using people backup your phones, without running the backup software as root?
Re:Pokemon Go, Security, and Obsolescence by colejohnson66 on Sunday October 16, 2016 @06:42PM (#12721475)
If you never change any files outside of the ones you own (i.e. the ones owned by "root"), you don't need to back them up, right? For example, if I never touch any of the files under C:\Windows, I have no need to back up that folder (especially the files owned by SYSTEM that you can't access).
Re:Pokemon Go, Security, and Obsolescence by kyled on Sunday October 16, 2016 @03:21PM (#12720434)
Root by itself does not break security entirely. Selinux policies and capabilities assigned to binaries can be used to drastically mitigate privileged processes from doing much harm.
Re:Pokemon Go, Security, and Obsolescence by on_and_off on Sunday October 16, 2016 @05:35AM (#12717798)
> This is not a solution for the mass majority of users.

root is not used by the mass majority of users.