LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-04-2020, 01:46 PM   #1
blooperx3
Member
 
Registered: Nov 2020
Posts: 67

Rep: Reputation: Disabled
If a browser is hijacked, can the hijacker install keyloggers?


Or would they need more access than just hijacking the browser?

I've read that once i restart my desktop after closing the tabs where the hijacking took place that my browser is no longer being hijacked.

If they could install keyloggers while hijacking my browser, would the keyloggers also be gone after restarting the computer?

I have to admit i need to read more about keyloggers.

Last edited by blooperx3; 12-04-2020 at 01:52 PM.
 
Old 12-04-2020, 02:34 PM   #2
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,987

Rep: Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628
In general I'd say that anytime a hacker gets their foot in the door anything can happen.
 
Old 12-04-2020, 04:28 PM   #3
boughtonp
Senior Member
 
Registered: Feb 2007
Location: UK
Distribution: Debian
Posts: 3,604

Rep: Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547

It depends: define "hijacked".

If it's just a piece of JavaScript that doesn't exploit browser bugs, it will stop when the tab/browser is closed.

But if a cracker finds a browser bug which allows them to execute code outside the browser sandbox, all bets are off.

Restarting the desktop would be unnecessary for the former, but may have no impact for the latter.
If you think a machine is compromised, disconnecting from the network is more important than restarting, (and changing auth for any potentially compromised accounts).


Last edited by boughtonp; 12-04-2020 at 04:29 PM.
 
Old 12-04-2020, 06:29 PM   #4
blooperx3
Member
 
Registered: Nov 2020
Posts: 67

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by boughtonp View Post
It depends: define "hijacked".

If it's just a piece of JavaScript that doesn't exploit browser bugs, it will stop when the tab/browser is closed.

But if a cracker finds a browser bug which allows them to execute code outside the browser sandbox, all bets are off.

Restarting the desktop would be unnecessary for the former, but may have no impact for the latter.
If you think a machine is compromised, disconnecting from the network is more important than restarting, (and changing auth for any potentially compromised accounts).
Let's say they know this is my linux account. They figure out the password and go into it and put code somewhere whereby when i log into the account, they are on my browser and have full access as if they were connecting to my computer via a remote access trojan.

But with a RAT, i've read that they are not able to put something permanent on the OS.

Last edited by blooperx3; 12-04-2020 at 06:35 PM.
 
Old 12-04-2020, 06:53 PM   #5
sgosnell
Senior Member
 
Registered: Jan 2008
Location: Baja Oklahoma
Distribution: Debian Stable and Unstable
Posts: 1,943

Rep: Reputation: 542Reputation: 542Reputation: 542Reputation: 542Reputation: 542Reputation: 542
How are they figuring out the password? Are you so clueless as to use an easily guessable password? With your user password and sudo active, anyone can do anything. With the root password, anyone can do anything. Change your password regularly, use reasonably complex passwords, and you shouldn't need to worry much. Targeting an individual computer running Linux is not a profitable enterprise. Why would anyone go to the trouble of hacking into your computer and installing a keylogger? There has to be a high reward for such effort in order for anyone to even try it. I take reasonable precautions, but I don't lie awake nights worrying about someone trying to take over my computer. There just isn't enough value in it to make it worthwhile. Any sites with value attached, such as banks, Google, etc have two-factor authentication enabled, so even a keylogger won't gain access. All passwords are in my password safe, and I copy/paste those.
 
1 members found this post helpful.
Old 12-04-2020, 08:28 PM   #6
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,987

Rep: Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628
There is usually an annual hack event where groups try to exploit common desktop systems. Some years the hackers do it by gaining access via browser. They have done it by scripts, java and images and maybe a few other ways.
 
2 members found this post helpful.
Old 12-04-2020, 09:34 PM   #7
sgosnell
Senior Member
 
Registered: Jan 2008
Location: Baja Oklahoma
Distribution: Debian Stable and Unstable
Posts: 1,943

Rep: Reputation: 542Reputation: 542Reputation: 542Reputation: 542Reputation: 542Reputation: 542
I don't claim that it's impossible, only that it's not worth attempting barring unusual circumstances. I'm one of billions of computers connected to the internet. Someone would need a serious reason to target me, and there are so many Windows computers which are much easier targets.

Last edited by sgosnell; 12-04-2020 at 09:37 PM.
 
Old 12-05-2020, 01:38 AM   #8
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by jefro View Post
Some years the hackers do it by gaining access via browser. They have done it by (...) images
Saying one can be hacked by images (meaning graphic image files like JPG) is a misleading simplification. "Through images" might be acceptable. An image file is passive. It might contain malicious code, but it doesn't actively hack you, even if you open it in an image viewer.

There have been cases where malicious code was hidden in image metadata which might then get executed by software reading & interpreting this metadata, IIRC.
A very specific hack. I cannot find the relevant news item now, but IIRC it was specific to GNOME and mostly harmless.

Last edited by ondoho; 12-06-2020 at 03:33 AM. Reason: image disambiguation (in brackets)
 
1 members found this post helpful.
Old 12-05-2020, 01:48 AM   #9
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by boughtonp View Post
But if a cracker finds a browser bug which allows them to execute code outside the browser sandbox, all bets are off.
This is the relevant bit. This is why we keep our browsers & operating systems up-to-date.
But by design, browsers allow javascript execution only in a sandbox. My guess is that this sandbox is page specific, i.e. it can't even look inside another page, so what you describe below should not be possible.
Quote:
Originally Posted by blooperx3 View Post
Let's say they know this is my linux account. They figure out the password and go into it and put code somewhere whereby when i log into the account, they are on my browser and have full access as if they were connecting to my computer via a remote access trojan.
In any case, even the premise "they know this is my linux account" seems very unlikely. What's a "linux account"? Who are "they", and how do "they know"?

Quote:
But with a RAT, i've read that they are not able to put something permanent on the OS.
I have no idea what a RAT is and I have never been hacked (famous last words ).

Generally speaking, sane browsing habits require:
  • regularly cleaning out local data & storage
  • using a safe password vault/manager
  • allowing javascript and 3rd party requests only selectively, on trusted sites
Of course, "trust" is tricky and never absolute.
Let's say, I wouldn't trust certain sites some spammers post. Meaning I would not click those links except _maybe_ in TOR BRowser.
But for most sites: I do not trust them with my personal data, but I would trust them to not contain malicious code.
...ymmv...
 
Old 12-05-2020, 02:57 AM   #10
JJJCR
Senior Member
 
Registered: Apr 2010
Posts: 2,153

Rep: Reputation: 449Reputation: 449Reputation: 449Reputation: 449Reputation: 449
https://irishtechnews.ie/a-quick-fix...ser-hijacking/

Quote:
Some browser hijacking can be easily reversed, while other instances may be difficult to reverse. Various software packages exist to prevent such modification.
Source: https://en.wikipedia.org/wiki/Browser_hijacking

With that said it's better to check your system with a good anti-virus or check any port activity that is suspicious.

Like, close your browser and other running application.

Then do a netstat for any activity

Not sure though if this method is quite helpful.
 
Old 12-05-2020, 08:25 AM   #11
boughtonp
Senior Member
 
Registered: Feb 2007
Location: UK
Distribution: Debian
Posts: 3,604

Rep: Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547Reputation: 2547
Quote:
Originally Posted by blooperx3 View Post
Let's say they ... have full access as if they were connecting to my computer via a remote access trojan.

But with a RAT, i've read that they are not able to put something permanent on the OS.
Full access means full access.

Restarting basically clears RAM.

Unless you have a read-only Live system (with no writable drives/storage attached at all) then full access allows persistent malware, irrespective of how the access was originally gained.

Restarting does not prevent remote access. Physically disconnecting compromised machines from the network prevents remote access.

 
Old 12-05-2020, 09:25 AM   #12
sgosnell
Senior Member
 
Registered: Jan 2008
Location: Baja Oklahoma
Distribution: Debian Stable and Unstable
Posts: 1,943

Rep: Reputation: 542Reputation: 542Reputation: 542Reputation: 542Reputation: 542Reputation: 542
Google, and perhaps Mozilla, offers handsome bounties to anyone who can show that they've compromised their browser, far more than they would get from shaking down private users. They don't pay out much. There are many very competent security experts working hard every day to prevent that sort of thing. Taking over a modern browser is very hard. That's why updates come along so often - as security issues are found, they're patched, and people are constantly searching. Having random hackers take over your browser and installing keyloggers is not a realistic threat. If a specific government entity wants to do it, it's perhaps possible, but that entity would need a reason. Keyloggers are not being installed on random home computers. And again, it's very hard to do this. The only really viable way to do this is to gain physical possession of the machine for the necessary time. Breaking into your house while you're gone is far easier and more reliable than trying to gain entry through your browser.
 
1 members found this post helpful.
Old 12-05-2020, 05:06 PM   #13
blooperx3
Member
 
Registered: Nov 2020
Posts: 67

Original Poster
Rep: Reputation: Disabled
Thanks for all the responses...

In one of my social media accounts that i rarely ever use, i had a complex password there for a very long time (couple / years). Someone got into the account and put something there - my guess would be a script, but i don't know much about code/malware.

So when i logged in they got on to my computer shortly thereafter with no question they were on. But before i logged into that account they were not on; after i restarted and shut the tab/logged out for social media account, they did not get back on.

But when it comes to putting keyloggers on my desktop, with the kind of access described, can they do that?

A good question is: how long would it take to install keyloggers with this kind of access to the computer? If it would take 15 minutes vs 3 three minutes, that would tell me a lot, like whether or not they could do it based on how long i have my browser open at one time - which is usually not a long time.

Last edited by blooperx3; 12-05-2020 at 05:10 PM.
 
Old 12-06-2020, 03:40 AM   #14
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by blooperx3 View Post
Someone got into the account and put something there - my guess would be a script, but i don't know much about code/malware.

So when i logged in they got on to my computer shortly thereafter with no question they were on. But before i logged into that account they were not on; after i restarted and shut the tab/logged out for social media account, they did not get back on.
The last sentence is the most relevant bit.
I question everything you wrote before that. You cannot "put a script into an account" where it then gets executed when you log in.
If anything, I'd say the whole site where the account resides was compromised. Or you used the same password elsewhere.

You have changed the password since, right?!?!

Without more information it's difficult impossible to say more, it's just another of those threads: "conspiracy myth 1, therefore I got hacked, therefore conspiracy myth 2".
As you see, I'm even questioning that you got hacked in the first place.

Where's the technical analysis.

Last edited by ondoho; 12-07-2020 at 12:27 AM.
 
Old 12-06-2020, 09:03 AM   #15
sgosnell
Senior Member
 
Registered: Jan 2008
Location: Baja Oklahoma
Distribution: Debian Stable and Unstable
Posts: 1,943

Rep: Reputation: 542Reputation: 542Reputation: 542Reputation: 542Reputation: 542Reputation: 542
There is, to me, absolutely a question of whether 'they' were on your computer. Running javascript from a website is not the same thing. Javascript is running on almost every website, some more benign than others. Many websites simply won't function properly without it. But it's easy enough to prohibit javascript globally, and whitelist essential trusted sites if you feel the need. Just saying that there is no question someone was 'on your computer' does not make questioning it impossible, other than in one's own mind.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Is my browser getting hijacked? nurwanda Linux - Newbie 31 09-11-2019 07:19 PM
Broswer Hijacker Virus (undefined.com) installed on Debian 9 anon208 Linux - Security 5 04-30-2018 08:29 PM
[SOLVED] Browser hijacker Fixit7 Puppy 17 06-28-2015 10:12 PM
Keyloggers and spywares crazy diamond General 4 10-07-2004 11:03 AM
hijacked browser irvken Linux - Security 2 10-06-2004 05:13 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration