How to detect if a keylogger has been installed on your machine

A keystroke logger is the worst kind of malicious software (malware) you could possibly hope to be infected with. Why? Because it could be recording each key you type and sending it to a central server, which would include your messages and username passwords!

This is why in some cases a password manager can make your machine more secure: because you are typing your passwords less, if somehow you could an infection it would have less impact.

That point is debatable however, since one needs to be root to install one it's a good reason to have a guest account enabled on your computer if you ever plan to let a bad-ass criminal use it for 5 minutes while your making a cup of tea or similar.

How To Not Get Virus Infection

  • Before double-clicking, check you trust the source of the executable
    • Check the domain name, the person who sent etc
  • Provide to guest users a regular low-privilege user account
    • If a stranger needs to use your machine when you are not around, this will prevent them most badness if it's not an admin account
    • Saved my ass at least once, I know this much
    • Helpfully, this also logs all your web sessions out

How To Detect Keystroke Logger Installation

It's actually quite difficult. I'm going to look into it and update this blog later when I find out more. If you want to take a snapshot of all your system kexts try running Syntella (macOS only presently) then you can search through the report with a text editor to try to find anything that is amiss.

If you're on windows you could try checking this link:

answers.microsoft.com/...how-to-detect-if-a-keylogger-is-installed/... 

 

 

Social Welfare for Kiwi Infotech

Security is always a "nice to have" feature but how does a busy business owner get it done?

It's virtually impossible for one person to do this type of military strength hacking job. The time and effort required is highly non-linear and almost impossible to predict.

It would be cool if the government would tell you if your website was insecure. But they'd prefer to keep the back door in case they need it later. Just kidding CERT has very useful advisories over at cert.govt.nz/it-specialists/advisories/ But they can only do so much.

Bug Bounty Programs != Complete Solution

At first, only the super large software companies like Google and Facebook can afford bug bounty programs, but today 93 companies are listed at bugcrowd.com/programs

Not all companies with websites need super strong security like this. National state level quality network operations. But the citizens of the country would likely hope their government has a plan to protect it's own computers, and also a plan to protect those of important Infosec industries such as banking, finance, healthcare, legal aren't leaking huge quantities of data everywhere.

But it's not a complete solution - its an extreme solution for a super technical area actually - and perhaps not the first solution for medium sized business dabbling in hardening their networks.

False intrusion detection positives are a mega waste of time.

Bruce puts it nicely over at his page on the subject:

Here's an outsourcing idea: get rid of your fleet of delivery trucks, toss your packages out into the street, and offer a reward to anyone who successfully delivers a package. Sound like a good idea, or a recipe for disaster?

The reality is that it comes down to branding: if the brand would be harmed by being the victim of a really big hack or data breach, then it puts more effort in. This works pretty well for infosec products. And for the times when it doesn't, I'm not suggesting forcing anyone to start a bug bounty program.

People would still eat pizza at a joint which has a haxored network, but they might not want to visit a doctor or use a lawyer whos network was wide open, with a file servers leaking everywhere etc.

I'm wondering if it would be possible to have a kind of social welfare for hackers government ministry, which pays kiwi researchers for their efforts pertaining to New Zealand headquartered companies directly, without needing the approval of the target company, who's head is likely in the sand anyhow.

Create an extra information stream for CERT. Banks, lawyers, doctors instant fines for leakage events. I'm looking at ACC, remember they had multiple screwups involving a CMS that could fire out emails in bulk, operated by staff!

Remember NOVAPAY? It's probably riddle with bugs, and ya'll know what that means. No incentive to find the but.

Or perhaps an approved proxy one could "hack all the NZ things" through but still be contactable by the authorities. Recording the traffic to disk temporarily would enable maximal value and help the researcher prove if they succeeded or not to claim the bounty reward.

Sometimes I just want to be sure my own bank is safe. Personally.

When the network admin sees the penetration test coming from a New Zealand based IP address - on a government subnet even - they'd visit the IP address and see a message to say it's all legit. Usually when you are being hacked you can't contact the other side like that. This would be different.

Crowd-sourced security outfit Synack use this method. It's required because sometimes there is a dispute about payout of the bounty to the successful researcher - how do you prove such a thing?

Also I hear in the US researchers found a remote-execution jailbreak for iOS and instead of collecting Apples $200,000, they opted for a way bigger million plus payout motherboard.vice.com/.../somebody-just-won-1-million-bounty-for-hacking-the-iphone

Unauthorised Use of a Computer System

I'd like to be able to scan and probe the entire country to find vulnerable machines, as a pre-sales market research information gathering exercise. To build a list of companies at risk to contact and sell my security services to.

But some parts of that probe maybe deemed unauthorised access - if done here in NZ.  It would need to be carried out in another country, and then it would not be investigated further, if I understand the "prosecutorial budget" allocation methods we use here, it would be deemed too hard to bother looking into, unless coming fro a five eyes country, they might find it hard to get at you.

You left your headlights on

For sure, having every doorknob in your house jiggled would be un-nerving to watch, even if its somewhat equivalent to that friendly neighbour telling you your car headlights are still on so you don't flatten your battery: trying to help. But then visiting the probe IP and reading the message would allay fears and maybe boost confidence even. Free network virus check. 🙂

The reason for high standards of evidence in criminal courts and the use of the presumption of innocence, is that it is better to have criminals roaming free due to lack of evidence, than to have innocent people locked up in jail wrongly - just because they looked at your computer the wrong way. You'd need a lot of jails and the economy would suffer. Sound like any country in 2007? Tame Iti is an artistic genius not a terrorist.

HIPAA is the Health Insurance Portability and Accountability Act of 1996 and is United States legislation that provides data privacy and security provisions for safeguarding medical information.

PCI Compliance is the payment card industry code to ensure payment processors use best practices.

CERT and The NZ Police should provide revenge-porn victims their file hashes

They often say the internet has no delete button.

It's a very useful analogy to explain to new users of the internet the gravity of certain areas of their personal computer and information security: maybe think twice before uploading semi-sensitive information, and three times for anything more secret. Once it's on the internet it can be hard to delete.

How to delete files from the internet:

One way could be to create a "hash" of the file you want gone from the internet, and then you know what you don't want to know, without knowing it! Amazing. Example time:

Assume the file is named horrific-revenge-porn.jpg

The following hash (random encrypted strings derived from the picture of an idiot) can be used instead of the actual offensive / suppressed original file data - makes sense if you are trying to delete the file not to hold it! It can be given to administrators to guarantee a system does not have a copy of the file:

Horrific revenge porn

Horrific revenge porn

sha256: c8b3c2a03380f577fa9d6b67ee15e40a9f8f9a076073ea56e5b5adb2e9ffe32c
md5: 79768d44c2aca6ed68d8157130265c05
crc32: b5513fdf
bytes: 50323

For the very most extreme cases, involving criminal contraband information such as the unfortunately case of the kiwi man from Hastings sentenced to 4 years for secretly filming his female Airbnb guests, CERT and The NZ Police should offer to provide file hashes to the victims of criminal data breaches like revenge porn and so forth.

This would enable the following desirable privacy benefits:

  • ensure the banned files are not held on owned computer systems
  • securely provide the means for others to also do so
  • nothing about the files contents can be said from looking at the random letters*
  • a registry of illegal files would help large ISPs to keep their disks clean
  • an infinitely large file - even a 50 GB file - is reduced to a short piece of text
  • its not encryption - it's an irreversible scrambling of any file to a set sized chunk of gibberish

For example, lets say this picture above is some revenge-porn you made once but was posted by your evil ex-partner or stalker, and now you'd like it gone from the nets; in theory if you put the file hashes into a government registry, one day ISPs can do seasonal scans and wipe files matching.

China likely does this to laser target and delete entire sections of internet from it's citizens. They probably have scanners running 24/7 to find old shots from the Tiannamen Square Masacre - and perhaps even this new shot - this time the guy is flat as a pancake after being literally "rolled" by a tank:

China Rogue State

China Rogue State

SHA256 is the current state of the art. You can get SHA512 also but its twice the length.

MD5 was huge for a very long time. Popular for verifying big .iso files after downloading.

CRC32 is not a hash, but its a checksum maintained by your computer in the disk that can also be used in a similar way. It will detect a single bit change, but unlike a true secure hash, you can pad the altered file to get the same CRC32 for a different file easily (if you add a bit, then delete a bit also, it is just each byte added together essentially).

Collisions

While it's theoretically possible for two different input files to create the same hash - a hash collision - if you use two or more different hash types like above or even just also including the filesize in bytes: 50,323 bytes in this case, you eliminate the false positive potential.

Also, any large ISP isn't going to want to automatically delete files based on just one parameter. For use by a sovereign national police force I'd recommend using all four: bytes, crc32, md5, sha256 plus a category eg: kid-porn, espionage, credentials, financial, medical/health, military, government, personal privacy, government, education, entertainment (here we hit a snag: the copyright industry).

The way a hash completely changes with tiny little single bit alterations to the input file, to get a hash collision is going to require a wildly different filesize, say 50 Kb versus 50 Tb!

The commands to get this on my mac were:

shasum -a 256 [bad-file.jpg]
md5 [bad-file.jpg]
crc32 [bad-file.jpg]
ls -la [bad-file.jpg]

What's nice is that you can double check your hash using a different program, openssl:

openssl sha -sha256 [bad-file.jpg]

Now you can quickly compare huge files without transferring them; and detect tiny alterations to big files.