this post was submitted on 02 Mar 2021
11 points (100.0% liked)

Linux

49493 readers
591 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Hi friends,

I'm running raspbian on a raspberry pi. It's great.

I often access my device over SSH from my phone. I have a long-running gnu screen session. Sometimes my shell becomes unresponsive for some time, which may be normal due to my poor wifi, but one time something weird happened.

My device was unresponsive for longer than usual, so I killed the SSH connection.

When I reconnected, my screen session looked like something like this:

$ <commands>
...
$ gpg -a --export $KEY | sudo apt-key add -
$ ctrl C
$ ctrl C
$ ctrl C

Most critically, the gpg command here is not something that I wrote. I can only guess that:

  1. I somehow executed something like !13, which expanded to something from my history
  2. Somehow a cron process or similar wrote to my tty (?)
  3. I've been hacked

I executed this gpg command intentionally at some point in the past, so I think (1) is most likely, but...

Can anyone just help me relax by confirming that my device is probably fine, and a hacker would do much more interesting things than add gpg keys to apt, right?

My device is exposed to the internet, so hackery is definitely not out of the question.

Thanks in advance!

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 4 points 3 years ago

Termux allows for shortcuts for arrow up, which accesses history. I think that it is unlikely that a hacker would access your pi at just the same second as you are accessing it and then use a command that you have used before.