extending the lifetime of smartphones with replicant, a ... · i samsung: galaxy s iii neo (2...

121
Extending the lifetime of smartphones with Replicant, a fully free Android distribution Denis ’GNUtoo’ Carikli and David ’dllud’ Ludovino February 4, 2020

Upload: others

Post on 11-Oct-2020

7 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Extending the lifetime of smartphones withReplicant, a fully free Android distribution

Denis ’GNUtoo’ Carikli and David ’dllud’ Ludovino

February 4, 2020

Page 2: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Introduction

Page 3: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Replicant:

I Fully free Android distribution approved by the FSF

I But the hardware it runs on is not...

I More details on hardware related freedom issues later

Page 4: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Quick Facts

I Website: replicant.us

I Exists since September 2009

I Currently based on LineageOSI Android versions:

I Replicant 6: Android 6, last security update: October 2017[?]I Replicant 9: Android 9, work in progress[?]

I Supports ∼ 10 devices (smartphones and tablets)

I ∼ 2 full time equivalent contributors and a big community

Page 5: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Minimum feature set required to support a device:

I Display working and graphics fast enough

I Sound working

I Be able to make calls

I etc

I GPS, Camera, and other non crucial hardware may not work,or work in later releases

Page 6: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

A very short introduction on hardware:

I System on a chip

I Smartphones and the modem

Page 7: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Why Android?I Advantages:

I GUI and applications adapted to big fingersI → run on devices that:

I Lack keyboardI Have capacitve touchscreen and no stylusI Have very small displays with very high number of pixel

I IssuesI Part of the GNU/Linux software architecture is light years

away: package management and build system, graphics, audio,etc

I Huge unknown code from GoogleI Meant to run proprietary software, not to empower users

Page 8: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Android: From time to market driven architecture tosubstainability

I SOCs, WiFi chips, smartphones and tabletsI Write the code that work as fast as possibleI Support as many hardware features as possibleI → Varying code qualityI → Example: One driver rewritten 3 times

I Breaking Kernel API and ABII It can take time (years) to bring in a new framework in LinuxI Example of API breakage: HTC dream audio driverI Solution: Apps ↔ Android framework ↔ HAL ↔ KernelI Getting better in Android: Trebble and Generic Kernel images

Page 9: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Ugly code is good (for freedom):I Having the source code under free software licenses, even if

the code quality is bad is crucial for freedom:I Hardware bringup is often made that way anywayI Things can be improved later: always be cleaned up later or if

the code quality is too bad, rewritten from scratchI Having the source code under a free software license is very

importantI Worst case: use the source code as documentation or reverse

engineer it (add prints)

I → We depend on that source code

Page 10: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

[ OK ] Listened to the background introduction.

Page 11: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

[ OK ] Listened to the background introduction.Starting second part about sustainability.

Page 12: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Part II: Smartphones lifetime

Page 13: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

What I’m about to tell you is subversive...

Page 14: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

<subversive>

Page 15: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Once upon a time...

Page 16: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave didn’t want to buy a smartphone...

”Nearly all Present-day cell phones are Stalin’s dream”

Richard Stallman[1]

Page 17: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

But...

→ [[Peer pressure]] and advertizing

→ Employment (exploitation?)

Page 18: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

You need to be reeeeachable at all timesssss.

Page 19: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: okay okay, I finally bought a smartphone.

Page 20: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave bought an Android smartphone off the shelf.The smartphone has a removable battery.

Page 21: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

This smartphone will self-destruct in 5 years

Page 22: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: Why didn’t I know that at the time of buying?

Page 23: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Two years later...

Page 24: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Hmmm

Page 25: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: What?

Page 26: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I’m sorry Dave, your battery ran out.

Page 27: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Game Over: Buy a new phone.

Page 28: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: Play again! Insert a new battery to continue!

Page 29: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave buys a new battery.

Page 30: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Uhhh consumers like Dave are tiring me...

Page 31: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: I’m a humain beeing!

Page 32: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Uh oh.

Page 33: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Hmmm

Page 34: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: What now?

Page 35: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I’m sorry Dave, your smartphone ran out of software support.

Page 36: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: Shiiit

Page 37: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave doesn’t want to destroy the planet

Page 38: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave:No passaran

You shall not passI shall not buy a new smartphone.

Page 39: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: I can still run Android apps.

Page 40: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Securityyyy....

Page 41: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: my smartphone is full of backdoors anyway.

Page 42: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: You’re part of my threat model.

Page 43: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Shit they become more and more clever.

Page 44: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Hmmm?

Page 45: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I’m sorry Dave, the Android apps don’t support your old Androidversion.

Page 46: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: Shiiit

Page 47: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: Fuck you, I’ll install LineageOS.

Page 48: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I’m sorry Dave, you will loose your data in the process.

Page 49: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave:I’ll migrate the data myself.

DIY is great !

Page 50: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave Dave please remain with us...

Page 51: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: I don’t trust you. Fuck off!Leave me alone!

Page 52: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Two years later...

Page 53: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave was living happily ever after and forgot about his smartphone(and all the backdoors...).

Page 54: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I’m sorry Dave, LineageOS dropped support for your smartphone.

Page 55: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave faints...

Page 56: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: How is that possible?

Page 57: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Knock Knock Dave...

Page 58: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Do you want the red pill [y/N]?

Page 59: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Do you want the red pill [y/N]? Y

Page 60: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: Fuck yes I want the red pill!

Page 61: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Part III: The Phantom Menace

Page 62: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave, you’ve been living in a dream...

Page 63: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Until recently the Linux kernel in your phone was very heavilymodified...

Page 64: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Our informations are scarse and sometimes outdated...

Page 65: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

But we deduced that in 2008 the device and chip manufacturersdid that to improve the time to market...

Page 66: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

But who care about time to market when most of the humans willdie with 2 degrees?

Page 67: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

HAL: Warning: Anarcho-ecolo-communist terrorist detected

Page 68: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: Good idea!

Page 69: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Kernel panic: error -1: Operation not permitted

Page 70: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

So they abstract the kernel in libraries that are often nonfree.

Page 71: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Like the libril which implements the modem protocol, and in somecases a backdoor too...

Page 72: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: Shiit...

Page 73: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave: So they own us?

Page 74: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

In some way yes, but we have the devices, so we can still fightback.

Page 75: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

For instance we have greater assurance of not being recorded, butif you left your phone on, they know where you are.

Page 76: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Shit.

Page 77: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Dave panicks and removes the battery.

Page 78: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

You trapped me!Because we’re at the same location, they know I’m in the

resistance now!

Page 79: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I don’t use a smartphone so they don’t know where I am.

Page 80: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

By the way: Welcome to the Resistance.

Page 81: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Part IV: The counter attack of the clones Replicants

Page 82: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

How to fight back? Do I need a light saber soldering iron?

Page 83: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I’ve no definite answer on that, many things were tried in the past.

Page 84: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Revolutions, assasinations, armed conflicts, theft, strikes, teaching,living in remote communities, regicides, and even making a bank.

Page 85: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

But besides remote communities and self-management spaceswithin the system, we didn’t get rid of abuse of power yet.

Page 86: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I meant for smartphones.

Page 87: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

I’m sorry Dave, as of today smartphones can’t respect yourfreedom.

Page 88: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

They track you with a deadly precision.

Page 89: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Our sources indicated us 10 or 20 meters for GSM and 3G.

Page 90: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

But replacing more and more nonfree software by free softwarelimits the damage.

Page 91: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

We have several fully free software GNU/Linux distributions andeven Replicant, a fully free Android distribution.

Page 92: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Replicant is almost as old as the Matrix Android.

Page 93: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

So if I’ve a supported device that has a removable battery, will itlast longer with Replicant?

Page 94: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Not yet.

Page 95: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Part IV: Breaking the chains

Page 96: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Some smartphones have longer software support...But they have batteries that cannot be easily removed...

Page 97: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Others are meant to be repaired...But the software support is bad...

Page 98: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

So we lost?There are many many smartphones being produced each years...

Page 99: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

What you must learn is that these rules are no different than rulesof a computer system.

Some of them can be bent, others can be broken.

Page 100: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Most modern smartphones have non removable batteries!It’s hopeless!

Page 101: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Free your mind...

Page 102: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Do you think that the number of smartphones has anything to dowith their strength?

Page 103: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Right, but how?

Page 104: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

We’re going to hangup on this political system, and then showthese people what thoses in power don’t want them to see. We’re

going to show them a world without power. A world withoutforced rules or controls, borders or boundaries. A world where

anything is possible. Where we go from there, is a choice I leave tothe people.

Page 105: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Part V: Back to the real world

Page 106: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Replicant 6 → More recent Android.

Page 107: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Requirements += Replacable battery:

I No need to rush to support the device

I The device lasts longer

I → In line with upstreaming longer term work.

Page 108: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Devices supported by Lineage 16 with a removable battery:I Qualcomm MSM8*:

I Fairphone: FP2I LG: G3 (many versions)I OPPO: Find 7a/sI Samsung: Galaxy Note 3 LTE (Many versions)I Samsung: Galaxy S III Neo (2 versions)I Samsung: Galaxy S5 ActiveI Samsung: Galaxy S5 LTE (Many versions)I Samsung: Galaxy S5 LTE Duos (Many versions)I Wileyfox: Swift

I Qualcomm APQ8*I Samsung: Galaxy S4 (Many versions)I Samsung: Galaxy S4 Value Edition (GT-I9515/L)I Samsung: Galaxy S4 ActiveI Samsung: Galaxy S5 LTE-AI Samsung: Galaxy S5 Plus

I Samsung Exynos 7580:I Samsung: Galaxy S5 Neo

Page 109: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Limiting freedom, privacy and security attacks:I Isolated modem:

I Modem not in the SOC.I No shared memory (RAM) between the modem and the SOC.

I HSIC: USB-like, the host control re-enumeration.I MIPI: Should be OK, not extensively reviewed.

Page 110: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Devices supported by Lineage 16 with a removable battery:I Qualcomm MSM8*: Modem in the SOC

I Fairphone: FP2I LG: G3 (many versions)I OPPO: Find 7a/sI Samsung: Galaxy Note 3 LTE (Many versions)I Samsung: Galaxy S III Neo (2 versions)I Samsung: Galaxy S5 ActiveI Samsung: Galaxy S5 LTE (Many versions)I Samsung: Galaxy S5 LTE Duos (Many versions)I Wileyfox: Swift

I Qualcomm APQ8*I Samsung: Galaxy S4 (Many versions)I Samsung: Galaxy S4 Value Edition (GT-I9515/L)I Samsung: Galaxy S4 ActiveI Samsung: Galaxy S5 LTE-AI Samsung: Galaxy S5 Plus

I Samsung Exynos 7580:I Samsung: Galaxy S5 Neo Modem ↔ SOC: shared memory

Page 111: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Hmmm

I → No Exynos with removable battery and isolated modem.

I → All the devices supported by Replicant 6.0 have beendropped.

I → We’d like to support the devices longer...I The APQ* also look interesting, we would need to do more

research on it:I Isolated modem?I Upstream support for the SOC?I Nonfree bootloader (∼ BIOS+GRUB) (signed?)I Probably way more work needed (different modem, more

upstreaming work).

I We also took the decision when LineageOS didn’t supportthese.

Page 112: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Part III

Page 113: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Already supported by Replicant 6.0:

I Galaxy SIII (I9300): Good upstream status, modem supportlacking, and other small fixes to do.

I Galaxy Note II (I9300): Good upstream status, modem anddisplay support lacking.

I Galaxy SIII 4G (I9305) and Galaxy Note II 4G (N7105):Different modem.

Page 114: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Making devices more sustainable:

I → Upstream Linux → We can support them longer.

I → Most Replicant users and developers already have one.

I → Known hardware that works and can still be bought secondhand.

I Remaining issues:I RAM size and new Android versions.I Nonfree bootloader.

Page 115: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Main blocker: Nonfree bootloader

I Nonfree → Incentive to drop the device.

I Partially free u-boot port → can’t redistribute the nonfreepart.

I Research to understand if we can make it fully free (XBOOT).

I Stock bootloader incompatible with Linux...

Page 116: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Upstream Linux bootloader requirementsDocumentation/arm/Booting (since 2003):

The MMU must be off.

Instruction cache may be on or off.

Data cache must be off.

Page 117: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Some funding later...

Page 118: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Replicant 9.0:

I Galaxy SIII booting, modem initialized.

I Still work to do(testing, audio, networking, etc.).

I Slowed down by conferences and other Replicant work(XBOOT, Replicant 6, etc).

Page 119: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Future directions:I Finish the research on XBOOT.

I https://github.com/xboot/xboot

I Look into devices like the PinePhone and the Librem5.

I Share more work with GNU/Linux upstream (OFono, otherhardware support libraries).

Page 120: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

Licenses:

I The SIM card and BTS pictures comes from https:

//en.wikipedia.org/wiki/File:Gsm_network.png andare under the GFDL 1.2 or the Creative commonsAttributions-Share ALike 3.0 Unported.

I This presentation: CC-BY-SA 4.0 International.

I The Galaxy SIII picture: CC-BY-SA 4.0 International.

Page 121: Extending the lifetime of smartphones with Replicant, a ... · I Samsung: Galaxy S III Neo (2 versions) I Samsung: Galaxy S5 Active I Samsung: Galaxy S5 LTE (Many versions) I Samsung:

https://stallman.org/archives/2011-nov-feb.html