News: 1649422809

  ARM Give a man a fire and he's warm for a day, but set fire to him and he's warm for the rest of his life (Terry Pratchett, Jingo)

Raspberry Pi OS update beefs up security

(2022/04/08)


An [1]update to the Debian Bullseye-based Raspberry Pi OS is being rolled out with both quality-of-life improvements and one very important tweak: an overdue departure of the default user.

Previously, all installs of the Raspberry Pi OS (formerly known as Raspbian) had a default user called "pi".

This was handy for quick setups and convenience but a bit of an open goal on the security front. "This isn't that much of a weakness," insisted the Pi team, pointing out that you'd need to know the password as well to get access (and you'd need to have enabled remote access for miscreants to do their dirty work anywhere but locally) but still.

[2]

There is no getting away from the fact that its presence could expose credentials and "potentially make a brute-force attack slightly easier."

[3]

[4]

"Some countries," the team added, "are now introducing legislation to forbid any internet-connected device from having default login credentials."

With the latest update (which also adds the 5.15 Linux kernel), the default "pi" user has been removed in favor of a step in the now-compulsory setup wizard to create a user.

[5]

If a user really wants to (no doubt there are likely some apps for the diminutive computer that will take exception to a lack of "pi") the old account can still be created, although there will be the odd notification suggesting that this really isn't a good idea.

[6]One decade, 46 million units: Happy birthday, Raspberry Pi

[7]Raspberry Pis gain power to flash their own OSes with new network install function

[8]Out of beta and ready for data: 64-bit Raspberry Pi OS is here

[9]Buy 'em by the punnet: Raspberry Pi offers RP2040 chips in bulk

A mechanism has also been provided for renaming the account on existing images.

We took the new installer for a spin on both a Pi-400 and Pi 4. The overscan settings for a second monitor are particularly useful. Even more so is the ability of the wizard to pair with Bluetooth mice and keyboards.

Whoever put that code in there deserves all the beers since it means one can set up a Pi 4 without reaching for a wired keyboard or mouse. It also works with the Pi 3 and earlier with USB Bluetooth adapters, but we were unable to test this to confirm.

Other changes in this version include a peek at Wayland support, although the team cautioned that it was experimental, and listed a number of things not working at the moment, including screenshots.

[10]

Overall, this is a worthy release and the security improvements are useful (even if they might prove inconvenient for some). The move to the latest LTS Linux kernel is a welcome change, although support ending in 2023 compared to 2026 for 5.10 might give some users pause for thought. ®

Get our [11]Tech Resources



[1] https://www.raspberrypi.com/news/raspberry-pi-bullseye-update-april-2022/

[2] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/oses&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=2&c=2YlBcMK@P1iNyB8SV2R1IRQAAAMw&t=ct%3Dns%26unitnum%3D2%26raptor%3Dcondor%26pos%3Dtop%26test%3D0

[3] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/oses&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=4&c=44YlBcMK@P1iNyB8SV2R1IRQAAAMw&t=ct%3Dns%26unitnum%3D4%26raptor%3Dfalcon%26pos%3Dmid%26test%3D0

[4] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/oses&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=3&c=33YlBcMK@P1iNyB8SV2R1IRQAAAMw&t=ct%3Dns%26unitnum%3D3%26raptor%3Deagle%26pos%3Dmid%26test%3D0

[5] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/oses&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=4&c=44YlBcMK@P1iNyB8SV2R1IRQAAAMw&t=ct%3Dns%26unitnum%3D4%26raptor%3Dfalcon%26pos%3Dmid%26test%3D0

[6] https://www.theregister.com/2022/02/28/pi_at_10/

[7] https://www.theregister.com/2022/02/09/raspberry_pi_network_install_beta/

[8] https://www.theregister.com/2022/02/03/64bit_raspberry_pi_os_released/

[9] https://www.theregister.com/2022/01/17/raspberries_pi_direct_launch/

[10] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/oses&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=3&c=33YlBcMK@P1iNyB8SV2R1IRQAAAMw&t=ct%3Dns%26unitnum%3D3%26raptor%3Deagle%26pos%3Dmid%26test%3D0

[11] https://whitepapers.theregister.com/



Linux and security

VoiceOfTruth

-> an overdue departure of the default user

If this was a Windows install the penguins would have been howling like banshees about the lack of security by having a default user. But as it's Linux, let's put on our blinkers and pretend it didn't exist for years.

Re: Linux and security

gerdesj

Hello Administrator

Re: Linux and security

VoiceOfTruth

Administrator (or root in UNIX terms) is not the same as having a default user. If you don't know the difference between having a root account and an OS automatically creating a default user, I can point you to some tutorials. Beginner level stuff.

Adrian 4

"..now-compulsory setup wizard to create a user."

How does that work on headless setups ?

Tom 7

Given the standard ISO does not have SSH enabled it would work exactly like current standard headless setups: either you just copying one youve set up with a new user or your booting the standard install ISO on something with keyboard and screen before sending it of headless into the world like a rich politician.

lostinspace

SSH can be enabled by mounting a newly imaged sdcard and editing a config file on the boot partition..it's documented on their website. Hopefully something similar for specifying the user?

Tom 7

I'd imagine when you try and login via ssh for the first time it will do that. But you've already got past the 'headless' if you're modifying the iso. I have about a dozen of the little buggers so I tend to set up one new sd and set all the things I want on it like SSH and VNC and a host of other things and then copy and dd that to other sdcards but for some reason I used etcher and it didnt drop its access to the sd until just long enough before I took it out for the system to mount the drives and now the bloody card wont even show on /dev so I'm trying to work out how to bring it back to life (along with about 10 others I've managed to bugger!

Failing micro SD card

Andrew Yeomans

You can try blkdiscard to reset to factory setting, though even this might be difficult if the card is not in /dev. Try on another machine?

A.P. Veening

How does that work on headless setups ?

Reportedly (haven't tried it myself yet) very well, you will have to create a small file named userconf or userconf.txt in the boot partition of the SD card with a single line of text, consisting of username:encrypted- password – so your desired username, followed immediately by a colon, followed immediately by an encrypted representation of the password you want to use. The Raspberry Pi Imager tool will do that automagically for you.

Pete 2

> Previously, all installs of the Raspberry Pi OS (formerly known as Raspbian) had a default user called "pi".

Speaking of, what about all the other default users:

root, daemon, bin. sys

sync, games, man

lp, mail. news

uucp, proxy, www-data

backup, list, irc

gnats, nobody, systemd-timesync

systemd-network, systemd-resolve

_apt

Or don't they count as every Un*x system has a lot of them hard-wired in.

('pollies for the whitespace. Blame someone else's CSS for that!)

Tom 7

And audio.

I've just trashed my microSD setting up a new install so cant check this without wandering next door and I cant be bothered but are these not set to local access only? You cant log into them unless you are on the machine or you have set them to be externally accessible?

VoiceOfTruth

Alas you expose your lack of UNIX knowledge here. Most of those accounts cannot log in at all.

Of course, I can see you are using a UNIX knock-off, AKA Linux, as evidenced by the horror show of systemd. But on a true UNIX-derived OS, FreeBSD, here is an example:

root /bin/csh

daemon /usr/sbin/nologin

operator /usr/sbin/nologin

bin /usr/sbin/nologin

tty /usr/sbin/nologin

kmem /usr/sbin/nologin

games /usr/sbin/nologin

news /usr/sbin/nologin

man /usr/sbin/nologin

sshd /usr/sbin/nologin

smmsp /usr/sbin/nologin

mailnull /usr/sbin/nologin

bind /usr/sbin/nologin

unbound /usr/sbin/nologin

proxy /usr/sbin/nologin

_pflogd /usr/sbin/nologin

_dhcp /usr/sbin/nologin

uucp /usr/local/libexec/uucp/uucico

pop /usr/sbin/nologin

auditdistd /usr/sbin/nologin

www /usr/sbin/nologin

ntpd /usr/sbin/nologin

_ypldap /usr/sbin/nologin

hast /usr/sbin/nologin

tests /usr/sbin/nologin

nobody /usr/sbin/nologin

Tom 7

I think almost any linux I've played with over the last 20 years had those set.

A.P. Veening

Good news, now I need to score a new RPi4B to test this. Anybody any ideas for that?

Tom 7

Find a local CoderDojo and take a gun.

My LESLIE GORE record is BROKEN ...