instruction
stringlengths
24
27.2k
The OWASP XSS Prevention Worksheet recommends "URL escape before inserting untrusted data into HTML URL parameter values". I don't understand how someone could break out of a URL context or inject a new subcontext to perform a XSS attack in a URL. As the browser interprets the URL, can certain characters be used to ter...
I'm reading an Information Security book and am faced with the question: Why may nmap stealth scans(SYN) attract more attention than simple connect scans(TCP connect())? Why might it be?
Would it be a good idea security-wise to store salts with their last character removed, and then bruteforce the last character to further the amount of time it would take to create rainbow tables and such? This is assuming the hashing algorithm in use is Whirlpool. This would make logins take a little longer, but it wo...
All this talk about Superfish and other adware crap has made me healthily paranoid that a wrong certificate can enter my certificate cache at any time. I have no reason to assume that there is a malicious certificate in my cache right now, but you never know something might happen. I'm looking for a way to restore my c...
I have done some android programming (self taught). I have started working on an app idea. The idea is pretty much that people with the app installed can post pictures/videos and text which can be seen by everyone with the app. I have purchased a hosting (working on making my own webpage), which has a lot of disk spac...
There is currently a lot of discussion going on across the Internet about the "Equation Group" family of malicious hard disk drive firmware. One thing that has me wondering is the claim that malicious HDD firmware would be able to access details on any running full-disk encryption scheme. For example, we have How the N...
I've read a lot about Superfish (and similar ad-ware) lately and I basically understand the vulnerability to MITM attacks. But I'm actually wondering if the "secure connection scan" by Kaspersky Antivirus is as broken as the Superfish example? I mean Kaspersky installs a root certificate onto my computer and "man in th...
A scene in the documentary CitizenFour showed Snowden using a blanket to cover his head and the laptop screen. When asked by Greenwald about this, he answered affirmatively, but I couldn't really understand what Greenwald meant/said. What was Snowden mitigating by that action?
I use my American Express card every day, sometimes multiple times. I do a mixture of card-present and card-not-present transactions. AMEX has decent fraud detection and I get notified quickly if they suspect something. However, for the third time in less than a year, my info was compromised. This time, the thief ac...
Here's an observation: My apartment offers free wifi around the social congregation areas. It is not encrypted BUT as I have observed, each connecting device is confined to its own VLAN (based on MAC address I guess). So you really cannot fiddle with anyone else's data (or can you?) To start surfing, the user needs to ...
It appears that in many cases, there is no way (short of physical destruction) to securely delete data from an arbitrary SSD. Unfortunately, I do not know how an individual (not a business) can destroy a drive without violating HAZMAT laws. Should I just stick with HDDs? I know I can erase those securely.
I am encrypting a sequence of messages with AES/CTR. For each sequence, I generate a random initial IV, say IV(0). Define IV(i) = MD5(IV(i - 1)) for i = 1, ..., n. Then for each message m(i), I transmit IV(i) . e(key, IV(i), m(i)) over the channel, where . denotes the append operation and e(.) is the encryption fun...
I really hope this question isn't off-topic... Background The question pertains to media security (video, audio, etc.), where the media in question is digitally protected (legally, DMCA-style) or otherwise (open to the public, but should not be redistributed according to some license or another). For example, a video o...
I got This website doesn't supply identity information in firefox while browsing gmail.com, I understand that would be because I understand it is required when it needs to load content using HTTP and HTTPS as explained in this post however when I check most possible scenario to make gmail load contents (from attach...
One of the biggest points of friction I see between networking teams, security teams, and users is around the idea of network segregation. For instance, the network team wants to isolate everyone behind VLANs, such that, for example, users would not even be able to browse the IP address of a security tool. The reasoni...
A 256 bit AES key is required to be broken using the brute force method on a 2GHz computer. How long would it take to break the key in the best case and in the worst case situations? Assume that 1000 clock cycles are required to check a single AES key.
I have the following PEM format public key: -----BEGIN PUBLIC KEY----- MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDguwHaldTclMAFg1BQ45Q8DPIc 8Su5mwoyGuf8bHIrgV3gz18YgQl+Puvc7Ua63S1o1s/tkDbfdAWweArO+KdOMrEg dsB9PdgMuAeAb3TN4Tc4rOe+N0mG7hBiigMaG2E5zdcwDe7d2q5Sa0rjCGCnLbNF zmGIsHtzogq4lOrJ2QIDAQAB -----END PUBLIC KEY----- ...
I have clients that communicates with my server. Clients sends it unique id (guid) to server with its request over a secure https channel. Also to increase security I use my own private-public key pair to encrypt requests & responses. If someone find this public key (it comes with client software) and reverse-engineer ...
Is it a good idea to use two salts? This is implying that one would be unique to the user, and one would be unique to the server, using Bcrypt of course. So for example, if you're using Golang as your backend, would it be a good idea to generate a 20 character long salt from /dev/random, bake it into the Golang binary,...
I have to log in on an HTTP website. There is a login form which contains inputs for username and password and as hidden inputs the sessionId. I am creating an application in which I have to access resources which just can be accessed if you are logged in on this website, so I provide a username and password input in m...
There was a recent post on the Shodan blog showing that certain SSH fingerprints are common across thousands of devices. For example, this fingerprint is common across over 250,000 devices worldwide: dc:14:de:8e:d7:c1:15:43:23:82:25:81:d2:59:e8:c0 And this fingerprint is common across over 11,000 devices across the U...
Security lessons force us to use limited users (Standard User) on Windows networks. I found that an administrator account can change his MAC address from Control Panel\Network and Internet\Network Connections ------> [adapter] ---rclick---> Properties ------> Configure ------> Advanced ------> Network Address ------> ...
I am studiying about android development and given the permission restriction between apps and isolation that the operating system itself imposes, I was wondering what can an antivirus app distributed as an .apk really do to protect the whole system.
I'm running nmap 6.47 on Windows 7 and am trying to run the ssl-ccs-injection.nse script. After getting an error, I ran it with the -d (debug) option and the error in the subject is what showed up. I haven't ever tried to run this script before, and I'm wondering what I've missed. Here's a sanitized copy of the sessio...
Below is the email with headers. I never registered on the site, so it's clearly phishing, but the links in the email point to the real Avast site. The delivery path also looks legit since both IP addresses (77.234.40.28 and 5.45.62.32) belong to Avast according to whois. I received this through my own Postfix SMTP ...
Since I'm fairly unfamiliar with the specific details of the SSH protocol, I was wondering if it was possible for a compromised SSHd server to upload a malicious payload (like a Trojan or some other nefarious code) back to a completely uncompromised client who was connecting to it. I suppose a poorly-coded SSH client c...
On a system that I'm working on a user signs up by means of an OpenID/Social Media account (Twitter, Google, Facebook), and then subsequently signs in using that path. The System comprises of a Back-end (API and database) and several clients (Web Portals, Native Mobile applications, and User-Agent/JavaScript based cli...
There doesn't seem to be a lot of in-depth information on the certificate signing process other than: Key Management Interoperability Protocol Usage Guide Version 1.2 (PDF) RFC 2986 - PKCS #10: Certification Request Syntax Specification, Version 1.7 Here is an example CSR I created: -----BEGIN CERTIFICATE REQUEST--...
Let's say in my computer running Debian i have an RSA key pair generated by user foo and copied the public key to server_A for allowing key based authentication in ssh for foo. Now my question is can i use the same key-pair for user bar and loo to allow key based authentication for them on server_A or do i need to crea...
When software forces a user to verify online (phone home) before use, it creates an opportunity for private data created with this software to be physically connected to the Internet. This may not be a big deal for some, but what if the data is sensitive or worth thousands of dollars? Even if the data is stored on a se...
I was viewing my firewall logs and come across the IP 8.8.8.8. Further check reveals it belongs to Google DNS. And such traffic has been going out from some of our LAN segment PCs. From here on, how should I determine whether it's legal traffic? I do not have any SIEM product installed yet. The next best thing is to p...
Given the revelations since The Equation Group was discovered. As well as that it is possible to not guarantee removal of a rootkit even with a nuke from high orbit. What properties of a harddrive hardware can be added to prevent these rootkits from taking control/replacing of the firmware?
In a Linux terminal, I made a ssh connection from A to B and I used commands to read some files stored in B. Then I disconnected and I closed the terminal. Is it possible to find on A, informations about which commands were used on B through the ssh connection. Sorry for the noob questions, but thanks for any help!
I'm working on a blog site, and I plan to allow bloggers to completely edit the style sheet for their own blogs I assume this isn't dangerous, since CSS is client side, but I thought it'd be best to check. If there a way someone could use this feature to implant backdoors and such into my site?
I am using cryptographic hardware accelerator of am335x. As per documentation it unloads the cryptographic operations from the main CPU and hence increases the performance. But from the security point of view how is it useful. In the documentation of 'self encrypted disks'(SED) it is given that the encryption key can n...
At my work there is secure WiFi for all the employees. If someone has sent harrassment / sexual harrassment emails to me through the company WiFi, is there a way for my company to trace the IP address to their computer? What if my company files a complaint to Google (the person used Gmail) and they comply with giving w...
I am currently working in security in mobile ad-hoc networks I have several clusters, and I want from the cluster head to send some data encrypted with its public key ,to the cluster members. I assume that each member has its own private key so it can decrypt the data I ask about how to get a single public key and mult...
I use GPG to sign my outgoing emails. I understand how it works when I encrypt mail to send to someone else. Then I need his/her public key, encrypt it with that, and only he can decrypt it using his private key. What I understand from signing my outgoing mail, I use my private key to do this. The receiver doesn't ne...
Let's assume an insecure channel. Is it safe to exchange Alice & Bob public keys first then apply them to sign communications during the DH process? (then encrypt+sign all future communications)? Should the process be rather: a DH process applied first, then the public key exchange with unsigned messages, then encrypt+...
I'm using a C# server and a C# tcp client example I extracted from the MSDN and I have created a self signed certificate using makecert.exe. I have got this to communicate with one another and it seems to be working fine. Similarly I want to build an android tcp client that will communicate with the C# server. Do I nee...
I am looking into VeraCrypt, a spiritual successor of TrueCrypt. This made a question pop up: As far as I understand, as long as the encrypted volume is mounted, every process can access the data. Wouldn't it be safer if only specific processes could access the files? Is there a tool that does process-based access cont...
I am using shell_exec function on the following variables to execute commands on the shell: fname (characters only) fpack(characters only) email (a valid email address) My code is: <?php require_once 'connectionToDB.php'; $fname = mysqli_real_escape_string($dbc, filter_var(escapeshellarg($_POST['fname']), FILTER_SA...
Why do researcher need to control all C&C servers of a botnet? Wouldn't it be easier to spread a deinstall command to all reachable PCs to cripple the botnet? This could be done over and over again until most PCs are clean. Apparently I don't know enough about botnets, so please help me out. Do clients check commands f...
I am working with a security person that baffles me a bit with the practices he performs. Besides the issue of this person insisting on bypassing every security measure in place we have got into it about handling private keys and certificates. So this is my perspective of best practices in regards to web servers: W...
I am running my own small UDP linux service on a dedicated server. my service responds to single-package requests with single-package responses. I don't want this server to do anything else. I don't want it to access or serve the web, allow remote logins, go out to log in elsewhere, download files, etc. I do not nee...
I am looking at integrating Google OpenID Connect (OAuth 2.0 for Login) as a login option for a web application. https://developers.google.com/accounts/docs/OpenIDConnect My question: Does use of OpenID Connect (and similar schemes) imply that Google could impersonate my users, log on to my website, and access all thei...
I have read that in asymmetric cryptography, a system admin can generate key pairs on the server. After that, the users will be given the generated key pairs and this is an efficient way of doing this kind of thing. I have two questions: How can the admin. distribute the key pairs? If say, via email, isn't it time-con...
Hashing multiple times (rounds) seems like a standard practice in password hashing to increase the work factor. Surely, everyone will agree increasing the work factor to compute the password hash is a good thing but I was wondering if we were not reducing the random factor of the hash at the same time. My theory Let's ...
The Certificate Enrollment Policy Web Service and the Certificate Enrollment Web Service are made for non domain connected machines to retrieve certificates of various kinds. When setting this up, I have a few configuration options: KeyBased Renewal (Authenticated with a prior certificate) Username Password (sent over...
I have a script that can only run successfully with root permissions But in development it's really hard to run with root permissions (in my development environment) so I add 'sudo' when ever it's required inside the code and remove it before I push changes to production. Obviously this is not a good practice since eve...
I am looking at Activesync authentication and want to know if Certificate Authentication ignores a client username and password or Certificate Authentication requires a username and password For what it's worth, Android Activesync client setup requires a username and Password to proceed even when a certificate is...
Suppose I issue a signing certificate in January, and have a daily CRL issued (expires in 1 day) to verify the validity of that signature. Then sometime in July I need to revoke that certificate. My goal is to not invalidate all prior emails signed with that key, but, rather give recipients some assurance that the key ...
I'm looking for an easy to deploy way to make email clients (MUAs) display my email messages in a secure manner. PGP and SMIME both do this today, but they are high touch, and require software or client certificates to be deployed to the end user... or in the case of SMIME I have to pay a per user fee for each signing...
Two weeks ago I reported a vulnerability to a security mailing list of a large open source software organization. I provided details of how to reproduce the issue and the exact place in the code where the bug causing the vulneratility is. So far I didn't get any response on that yet. I also wrote to one of the main dev...
I am pen-testing an ASP.NET application that is exhibiting Session Fixation behavior. The application is using cookie based sessions. Basically: When you land on the page no Session cookie is created After login ASP.NET_SessionId cookie is created On logout and repeated login the cookie value remains the same (there i...
i am trying to secure a connection between a Mobile Device (Client) using a webApp and a Home Device (Server) in a potentially unsafe Wifi Network. The communication is asynchronous and i am trying to prevent "replay attacks". I was thinking about Challenge Response, but the overhead of "ask for challenge, receive chal...
What is the difference/relationship between data leakage analysis and vulnerability analysis? How much and what kind of vulnerability testing is required for data leakage analysis? I have to give data leakage analysis report for some mobile applications. According to what I know, data leakage is happening when an app i...
I have a TLS Record containing HTTPs application data. I extracted the encrypted plain text with mac from the application data, then, when I decrypted the extracted data using AES CBC mode, I am expecting that It will return something like this: POST /ImeiTracki ng?msg=010908391 1841060249765020 A984108000001540 F7F9D0...
Background I was a bit surprised that several CAs do not allow anymore to send a plain old CSR in text form to them which was created in the classic fashion with OpenSSL or similar. But this would mean that the CA gets a copy of my key. Which is definitely anything but best practice (also see this question). What I did...
How can I get the name of a Key Container that's in a smart card required for initialization of CspParameters? CspParameters^ cspa = gcnew CspParameters(ProviderType, ProviderName, keyContainerName, cryptoSecurityKey, securityString); RSACryptoServiceProvider^ csp = gcnew RSACryptoServiceProvider(cspa); Since certifi...
Is there an exploit for this bug for python's sort implementation? http://envisage-project.eu/proving-android-java-and-python-sorting-algorithm-is-broken-and-how-to-fix-it/
How do you explicitly not trust a particular certificate (especially, CA certificate) for OpenSSL? On NSS-based applications, one can install the cert with trustarg p: prohibited (explicitly distrusted). In this way, say we we have Verisign ---> Some_CA_I_dont_trust ---> ... ---> Some Site I can remove trust of Som...
I am creating a website whereby users are given an account by invitation only, and are sent a unique code by post. Users can then log in (at least the first time) by entering the code only. The goal of this is for it to be extremely easy to understand and use by non tech-savvy people. User accounts will contain name, ...
My Rest API is protected using Oauth2. My main client is a native app. it's working great but there are certain calls to the API that i want to make sure that are performed from my client - meaning that if the user obtained the access token - he will not be able to use curl in order to call my Rest api. For example if ...
How to associate an antivirus with a file to delete it wherever it detects the file? I want My ESET Smart security 8 to delete a specific file wherever the file is . or not allow the file to run. what should I do?
I was thinking recently of the steps to secure a database server. Most of us are aware how to handle the security on the application side, although a malicious user might find his way to bypass the application security and exploit the database. Scenario Consider having a database with the following table prefixes blog_...
I work for a consulting company, and I have been implementing a tool from a security vendor, which is a cloud proxy for all user traffic. It will perform malware scanning and filtering of all web traffic. It works by enforcing a proxy autoconfiguration file to redirect HTTP/HTTPS traffic to one of the vendor's global d...
What are the differences between JSON Web Tokens, SAML and OAuth 2. Please provide some pointers and high level overview of their functions. Specifically, why would one use SAML over JSON Web Tokens or viceversa? Does one need to have OAuth 2 to use JSON Web Tokens/SAML? Or can JSON Web Tokens/SAML be used independentl...
I use the Astrill VPN service to access websites that my country has blocked. There is nothing sinister going on here. Sites like google and youtube have all been blocked. This VPN service offers about 20 servers within the U.S. which I often switch between depending on their speed. I'm not advertising here, I want to ...
I am running a web server and watching what people request. I have been getting frequent traffic like: GET /phph/php/ph.php HTTP/1.1 or GET /mrmr/mrm/mr.php HTTP/1.1 Are these scans? Are the clients checking if my server is already compromised or are they checking if I am vulnerable? As far as I can tell, since I...
I want to do a demo for a login page that is vulnerable to SQL injection for training purposes. I already tried to build one using PHP and MySQL. I commented the code sanitation to make the page vulnerable. The login page code is this: //step 1a: sanitise and store data into vars (storing encrypted password) //$usr = m...
The question is a bit tricky because they don't have the same purpose but : Do both kind of file face the same security issue concerning private key protection : password strength? (PBKDF2 as both are often encrypted using password-based encryption) I would like to better understand the differences between both formats...
I'm just curious to know the scope of the future security in terms of compliance and cyber security. And also the way of technology growth in terms of speed, authentication and authorization and OS. And the most important thing is how the users are comfortable and use of ease with the security ?
Assumption Suppose I have a CA that issues a base and a Freshest CRL. I also understand the Freshest CRL to be a Delta of revoked certs in the base. I also understand that clients should pull the delta/freshest CRL on a more frequent (how frequent) basis than the base CRL..If this is incorrect, then this question is i...
I'm reading into security issues surrounding SSL, and one of that has come up is certificate expiration. The general idea is that once a certificate expires, the site is insecure. What is the difference between an expired certificate and valid certificate, seeing as they both still encrypt the data? What allows an atta...
Background A registration process to acquire an anonymous, verified account goes like this: Registrant provides proof of individuality to a Registrar. Registrar verifies proof, ensures no prior registration, and directs Registrant to a Teller. Teller provides Registrant with anonymous account credentials. At this poi...
Sometime ago I was talking with a friend about security of different anonimity software kits. The most famous software we talked about was Tor. While I was talking about the triple secret used in tor nodes, he asked me a very sensible question: Have you ever asked yourself how are the circuits built? What I immediate...
I already created a PGP key-pair in Thunderbird Enigmail on Ubuntu. Now I would like to change the key, so it uses preferably Camellia-256 for encryption. How can I change the preferred algorithm from AES 256 to Camellia-256 in my existing key? UPDATE: I want to find out how to add the information that I prefer CAMELLI...
Hypothetical: a Windows 7 or 8 computer has a self-encrypting hard drive. It is stolen with the power on, but with the Windows lockscreen on. Are there easy off-the-shelf ways to access the data on the drive? All of the password recovery mechanisms I see for Windows 7/8 appear to require a reboot, which would drop the ...
Can attackers substitute/replace my queries to/from provider? I mean I do HTTP query and its modified on provider-side so query goes modified to a server or reversal situation, when I get modified answer from server by the modifying response on provider-side?
Requirement: In our company Location A uses PGP encryption and sending data over internet. In Location B, we have to decrypt the file. Question is what do we require in Location B Do we need to use the same PGP license or buy new license for decryption?. Do we require to manage the keys in Location B Do we need to us...
I would like to know the best practices to invalidate JWT without hitting db while changing password/logout. I have the idea below to handle above 2 cases by hitting the user database. 1.Incase of password changes, I check for password(hashed) stored in the user db 2.Incase of logout, I save last-logout time in user ...
Can we use the same AD server for both PCI VLAN user and Non PCI VLAN users? How about proxy, we have a Proxy but both PCI and Non PCI user's traffic are flowing through those Proxy. But we have segmented the VLAN for both PCI and Non PCI users Is it PCI compliant?
I'm writing a software which is divided into two separate stand-alone pieces. One is a service like application that handles all the logics, the other one is a GUI application that just works as a front-end and is aimed to be used by the end user. The service would listen to a port and accept requests from the client (...
When analysing Kerberos exchange (and other similars as Needham, Denning, etc.) I wonder why the first message where the identities of the client and remote are not encrypted. In case not encrypted I give a possible attacker the knowledge of who I want to communicate with. As the Client and KDC shares the key we can en...
I am going through the WebGoat exercises, to refresh my knowledge of XSS attacks. Specifically, I am doing the Stage 1 XSS exercise. This exercise has a form that deliberately does not sanitize input. The solution video shows using the JavaScript alert function to put out a message and the session cookie. Stage 3 has a...
I recently read about how HTTPS work and I have some questions to clarify. Pardon me if this sounds silly but I just need to get this clear. Correct me if I am wrong. I got to know that as part of the beginning of TLS handshake there is a asymmetric encryption where public key from the Certificate is used to encrypt th...
Would a site or blog owner know who is reading their site if the visitor is reading it with an RSS reader? Can they get the IP of the person? Say I had a Netvibes account with RSS feeds, can the site owner know which IP or RSS reader is viewing their feeds? If they have trackers or codes on their site or blog, can they...
Take a IM app like WhatsApp. If I send a message to another user while their client is offline, the server holds the message and then delivers it when the receiver's client goes online. It even has those two blue ticks, to show that the other user read the message. Considering an IM app like WhatsApp, would an IM app s...
Is it possible to determine, given a PGP message that you can already decrypt, to determine which other PGP keys that message has also been encrypted for?
I heard that MITM also involves DNS poisoning, which basically tells the Net to take a different route than it was supposed to go.. (I'm not sure if my interpretation is correct..) Given there is an MITM attack happening towards my computer, would it be possible to reverse poison, and cut the MITM out ?
Shuffling an array to create a random stream for encryption is well known. The weakness is in the security of the random number generator that performs the shuffling. But is it true or likely that the same array shuffled by two or more imperfect random number generators becomes more secure as it is shuffled by more num...
A web shop allows customers to order as guest or to create an account. I ordered as guest, entered my email address and the shipping address, and payed per credit card (I had to enter the security code). Some weeks later, I ordered something else, again as a guest. To my surprise, after entering my email address and ...
I am currently working as a technical lead on a project at a financial institution and have a question about how to provide the same level of security expected by the business in an application we are preparing for them. The legacy system today allows payment operators at a terminal window to interact with an AIX and m...
I'm working with a vendor who provides an API with a user registration method clearly designed for human-generated passwords. We're calling the API in an offline server-to-server fashion, however, and registering with the API on behalf of our user. I'm relatively comfortable with the idea of generating our own cryptov...
Most of the discussions about the BREACH vulnerability are around stealing session-based CSRF tokens. But if you can steal a session-based token, could you also steal the session token itself? Obviously there are some finer points of the BREACH attack which I don't understand :) I'm specifically interested in Django. I...
Starting with a one time pad say you want to encrypt some small strings like the words in this sentence but you want to reuse the same OTP key for each string so that when you encounter the same word the ciphered text comes out the same. But say you modify the OTP algorithm in some way, say by jumping around on an ex...
I'm planning to implement a web system wherein APIs and presentation for CRUD in data tables are automatically generated, like that in phpMyAdmin. How I plan to implement this is to construct SQL statements based on requests from the client. Client receives metadata (table, column) information from server. User intera...
A lot of sites offer MD5 or SHA sums to verify the validity of your download, but why do some things rely almost entirely on this? Is there anything in place to prevent people from just replacing the checksum with the malicious binary's checksum?
I'm used to writing web stuff in PHP and let Apache or nginx handle the actual HTTP handling and load my code via whatever means (mod_php, fcgi, fpm, ...). I'm under the impression that this is a Good Thing(tm), as there have been years and years of hacking, patching and improving these webservers, so they are "battle...