diff --git "a/stack_exchange/IS/Information Security 2020.csv" "b/stack_exchange/IS/Information Security 2020.csv" new file mode 100644--- /dev/null +++ "b/stack_exchange/IS/Information Security 2020.csv" @@ -0,0 +1,65322 @@ +Id,PostTypeId,AcceptedAnswerId,ParentId,CreationDate,DeletionDate,Score,ViewCount,Body,OwnerUserId,OwnerDisplayName,LastEditorUserId,LastEditorDisplayName,LastEditDate,LastActivityDate,Title,Tags,AnswerCount,CommentCount,FavoriteCount,ClosedDate,CommunityOwnedDate,ContentLicense +223502,1,223509,,1/1/2020 6:21,,0,88,"
And if so, what protections are available against this kind of thing?
+",113770,,,,,1/1/2020 12:58,Can an ethernet device plugged into a switch block all the other ethernet devices?,Suppose I symmetrically encrypt a file with a passphrase using GNU Privacy Guard and send it to a friend. I use the latest version and all the defaults, so AES-128 encryption is used, with the salt and s2k_count
used for the password derivation function automatically generated.
I then tell my friend the passphrase and ask them to open it.
+ +Are the salt, S2K type, s2k_count
, and so on included in the file somehow, so that my friend can decrypt the file knowing only the password?
I suspect the answer is affirmative but I have not been able to find it in the documentation.
+",223884,,223884,,1/1/2020 12:36,1/1/2020 13:31,Is all metadata necessary for decryption included in a symmetrically encrypted GNU Privacy Guard message?,Assume we have only access to the traffic between two module (Hardware, Software, ...) and These modules communicate with SSL (PSK). +Is it possible to assess AES encryption of this traffic? +some features like key length, AES cypher mode or any other important parameter
+",79940,,,,,1/1/2020 14:18,AES Traffic Security Assesment,Just listened to a bit of the Darknet Diaries podcast episode on NotPetya. It’s insane just the damage it was able to cause even if it was only able to infect one machine initially. Which got me wondering: how could a similar large-scale attack happened?
+ +Then I thought about cell towers. Our phones blindly connect to them every day. In fact, attackers can set up rogue towers that trick phones into connecting to them instead in order to perform a MITM attack. They just have to broadcast a stronger signal. That’s crazy.
+ +So I was wondering: aren’t cell towers basically routers? If so, if an attacker was able to take control of one, and if they had some sort of iOS/Android 0-day in how devices receive packets or whatever, could an attacker essentially spread such a wide-scale attack like NotPetya launched?
+",224269,,,,,1/1/2020 15:29,"Are cell towers basically routers? If so, could one be hacked to spread malware to all connected devices?",From what I can tell there were two main TMP files present on the infected USB stick. The smaller of the two would run first and hook various functions related to viewing files so as to hide the LNK and TMP files.
+ +While this was happening would it not raise suspicions? Someone would view the USB stick, see the six files and then they would just disappear?
+",,user224270,98538,,1/2/2020 11:25,1/2/2020 11:25,How did Stuxnet prevent the user from seeing the malicious files on a USB stick?,Certificate authentication on https has always been one of my huge knowledge gaps ,and was trying to fill it today.
+ +I have made some progress on the client side certificate authentication but however there's some fundamental question that can't get my head around.
+ +I have worked with third parties that use to send the certificate (and passphrase) over and then we were able to start using their services. Unfortunately I wasn't involved at all in the process so not even sure if it's my misunderstanding. Assuming that was correct, please let me know if not, my questions are
+ +I understand the question is both simple and vague but can't really see the use case of this exchange, from what I have been reading for a while
+ +Thanks
+",224271,,,,,1/1/2020 16:50,"In client side certificate authentication why, if, do we need to share the certificate",I use the free version of proton VPN because it has such a nice interface. From my understanding, when I connect to one of their VPNs located in the US, my information passes through an encrypted tunnel visible to my ISP, then to an entry node, then to a relay node, then to an exit node, then to where my internet activities are told to go.
+ +Let's say I was a cautious internet ""criminal"", and my ISP believed me to be such. They've hired one of you to come out to their location and make some guesses about what i was using their service for and you are really good at your job.
+ +What would you be able to tell my ISP?
+ +Tough question so thanks in advance!
+",120861,,,,,1/1/2020 20:18,What can my ISP see regarding my VPN tunnel?,For example, my website has Email/Password login and the ""sign in with Google"" button. If a user creates an account with their email and a password, then decides to sign in using the ""sign in with Google"" button, but using the same email as their email/password account, should we let them into their account? Or should the sign in attempt be blocked and the user redirected to the email/password login form?
+ +Email/Password Account Email: example@gmail.com +Google Account Login Attempt: example@gmail.com
+ +Thanks!
+",224278,,,,,1/1/2020 20:51,What is a login flow method to prevent account jacking when your website has Email/Password sign in AND Google Sign in?,I'm planning to start a distributed crawler in order to avoid common limitations imposed by servers/CDN like rate limit, region filter, and others.
+ +My idea is to have a central server and multiple agents that will run on different networks. These agents will be SOCKS5 servers. The central server will round-robin the requests in the pool of agents (SOCKS5 servers) to access the origin (website).
+ +I’ve been thinking about P2P systems using asymmetric keys and wondering if there is anyway to recover an identity in the event it was compromised using some kind of web-of-trust.
+ +This seems to be a large issue compared to a regular system (using a central authority) that can remove the intruder's access and restore control of the account to the real owner (Digicert, facebook, twitter, etc...).
+ +What if a master key pair was generated by a user and then used to create a subkey. Then using 16+ random bytes the master keys private component could be encrypted. The public and encrypted private key parts can be stored on the network publicly. The public part of this master key would be the root identity for that user.
+ +The owner could choose 5+ nodes on the network (friends?) to store parts of the passphrase used to encrypt the master key private component and then erase it's knowledge of those bytes.
+ +The subkey would be the active user identity (with it's own AES password protecting the private part). Should this client get phished, forget their password, or someone steal their sub-key private component, we could use the peers to restore the master key and revoke this subkey. Then we could generate and sign a new subkey.
+ +I'm not sure how this would work other than the client sending a request to each node and them verifying the client though some out-of-bands way (phone call? Text?) before sending their part of the master key password.
+ +Would this work? Are their any existing solutions to this problem?
+",3927,,3927,,1/6/2020 20:36,1/26/2022 4:03,Possible public/private identity recovery after compromise without a centeral authority?,I wrote an implementation of a non-interactive zero-knowledge proof system as outline in this research paper. As far as I can tell, it functions flawlessly as intended with text secrets such as authentication passwords.
+ +# USER REGISTRATION:
+ # CLIENT-SIDE
+ client_zk = ZKProof.new(bits=256, curve_name=""secp256k1"")
+ signature = client_zk.create_signature(""Passw0rd"")
+ # send zk.params and signature to server for persistent storage
+
+
+# USER AUTHENTICATION:
+ # SERVER-SIDE
+ server_zk = ZKProof(client_zk.params)
+ token = ZKProof.random_token(bits=256)
+ # send token to client
+
+ # CLIENT-SIDE
+ challenge = client_zk.create_challenge(""Passw0rd"", token)
+ # send challenge to server
+
+ # SERVER-SIDE
+ if server_zk.prove_challenge(challenge, signature, token):
+ # user is authenticated...
+
+
+While this use case is great for something like user databases, it does nothing for data protection. I am designing an application which will store encrypted text on the server. If I use a symmetric encryption algorithm, I can create proofs to ensure that the user is in possession of a particular password (assuming it was honestly registered when the key was created), however I have no way of VERIFYING that the encrypted data received by the server was indeed encrypted using that password since the server does not have access to the plain text OR encryption key. How can I best approach this?
+ +Note: I CAN actually verify that a password (or key) was used to generate a zero-knowledge PROOF, but not the actual integrity of the data itself.
+",44529,,,,,1/2/2020 5:53,Verify Encryption Key with Non-Interactive Zero-Knowledge Proof,This is a duplicate of a stack overflow question, since it might apply more to security and authentication best practices.
+ +I'm working on auth between a Chrome Extension, Google Cloud Platform, and trying to send the id_token
JWT to an AWS server to retrieve user data (and/or establish a session?).
My question is this -- how can I prevent chrome extensions with tabs
permissions from reading the GET request or the redirected URI which has the fully-validated user JWT?
The JWT confirms that a user is who they are, but how do I know my Chrome Extension is the one making the request to my backend?
+ +I have a few ideas:
+ +Maybe I can make a private window that only my extension can control
Maybe I can somehow use the nonce or get the nonce from my server first
Maybe my chrome extension has a private key or some way to verify itself with my backend, which has the public key
Any help would be appreciated, it's difficult to research this specific scenario.
+ +var url = 'https://accounts.google.com/o/oauth2/v2/auth' +
+ '?client_id=' + encodeURIComponent(chrome.runtime.getManifest().oauth2.client_id) +
+ '&response_type=id_token' +
+ '&redirect_uri=' + encodeURIComponent(chrome.identity.getRedirectURL()) +
+ '&scope=' + encodeURIComponent(chrome.runtime.getManifest().oauth2.scopes.join(' ')) +
+ '&nonce=' + Math.floor(Math.random() * 10000000);
+
+chrome.windows.create({ url: 'about:blank' }, function ({ tabs }) {
+ chrome.tabs.onUpdated.addListener(
+ function googleAuthorizationHook(tabId, changeInfo, tab) {
+ if (tab.id === tabs[0].id) {
+ if (tab.title !== 'about:blank') {
+ console.log(url);
+ if (tab.title.startsWith(chrome.identity.getRedirectURL())) {
+ const id_token = tab.title.split('#')[1];
+ console.log(id_token);
+ } else {
+ console.error(tab.title)
+ }
+
+ chrome.tabs.onUpdated.removeListener(googleAuthorizationHook);
+ chrome.tabs.remove(tab.id);
+ }
+ }
+ }
+ );
+
+ chrome.tabs.update(tabs[0].id, { 'url': url });
+});
+
+",90061,,,,,1/2/2020 1:16,Can Chrome Extensions steal OAuth tokens from redirect-uri?,What is the difference between a digital certificate and a digital signature?
+ +Read on the internet that the digital signature is the result of encrypting with a private key, the 'hash' of the message to be sent. As for the digital certificate it is not very clear to me.
+",224059,,6253,,1/2/2020 22:01,1/2/2020 22:08,Difference between certificate and digital signature,In TOTP implementations, it's always suggested that you give your users recovery codes. Should I treat these like tokens? Display them once and hash them?
+ +If so, I'd love to know why. If not, I'm curious too.
+",224297,,6253,,1/2/2020 9:39,1/2/2020 11:00,How should I store TOTP recovery codes on the server end?,Hopefully this question won't come across too closely to a which product is best as that is not my intention.
+ +I am moving into a larger property and I would like to setup some home security now i'm not 100% sure on I should be aware of and how to possibly mitigate being broken into. +I also do not know the area much at all, it appears to be a quiet English town.
+ +My main concerns are physical security and security of my home network.
+ +Thoughts on physical was to either just get an alarm or some kind of IP camera setup covering the front and rear of the property but after hearing some rather alarming news Nest camera hacks I do however have a few raspberry pi's that could be setup as PI ip camera. But I'm not sure if that would make it more or less secure. One consideration is the property has a shed which will probably contain some bikes and tools which I would like to secure which makes me lead toward camera's +is having a set of camera's considered more secure? and if so, to what extent against what threat.
+ +For home network security, I'm far more concerned the area generally has fairly tech savvy people due to lots of technical companies in the area. I've not moved in yet but I will probably just use whatever is supplied by the CSP with the nicest looking package. I'll then change the SSID and any passwords that came by default.
+ +While I'm fairly technical I do not know that much about security and what I do know I can't seem to apply to this, as in how do I take what I think might be an issue and break it up into threats and actions so on. threat analysis I guess it would be called?
+ +So after all that,
+ +There is this Web App which uses cloudflare and to bypass certain things I had to find a way to access the actual web server directly. I tried numerous things and finally I think I have found the actual server's IP but seems like direct access to IP is blocked as am greeted with this error.
+ +Error 1003 Ray ID:
+Direct IP access not allowed
+
+
+What header (or referer's value? ) to supply with our original request so that the web server accepts my request as a request routed via cloudflare's reverse proxy?
+ +In other words, I want the actual server to believe am coming via cloudflare. I believe to do that we have to supply specific header or a specific referer's value but I can't figure out what to supply in actual request. Any help would he appreciated.
+ +Thanks.
+",224309,,,,,1/2/2020 13:42,Is there any way to pretend like we are routing our request via cloudflare?,My company has a 'bring your own device' policy. You connect your device to the WiFi, and then open a citrix environment through a web portal. Basically, everything inside the citrix env is company-software/email. Outside is your own software/mail/browser.
+ +I know that anything I do online outside of the citrix environment still transfers over company WiFi with the possibility that it is inspected.
+ +Very recently however, the connection to the internet outside the citrix environment ceased to work, I assume by design, since now I get a pop-up asking me to install a certificate that is clearly issued by the company. This should restore internet connection.
+ +My questions:
+ +Will this give them any additional ways to monitor my machine over the old situation?
+ +Will they for example be able to inspect end-to-end encrypted messages?
+ +Is it a good idea to accept this kind of a certificate given the fact that I am a contractor and work for multiple clients?
+ +Additional point to consider: +Some of our developments require work/testing outside of this citrix environment, due to shortcomings of the VM. Still, there is no need or possibility to connect to any company resource (network shares etc...) from outside the VM.
+ +EDIT +My question is specifically what kind of (additional) negative consequences this certificate will/might have, versus before, when we could access internet without any certificate installed. Therefor I think this question is different from Can my employer see what I do on the internet when I am connected to the company network?
+ +EDIT
+Example: this happens when opening outlook.
+
I've been using BitWarden as my main password keeper, would like to ask if it's safe? I know that everything is not 100% safe but still want to know if they are worth it.
+ +All my passwords are different beside some accounts password.
+ +I know there is also keepass but can't really be annoyed to backup it each time because I also use a lot my mobile and BitWarden has a mobile application that is really helpful.
+",224315,,76718,,1/2/2020 14:30,2/22/2021 5:01,Is BitWarden trusted?,I reported a flaw to the security team and they changed the UIDs from regular integers to hash kind of a thing. Like this, XXXX-XXXX-and-so-on
+ +I still want to try and bypass things but I don't understand what kind of hashing is this? I have seen a lot of applications using this kind of hash for tokens, UIDs etc. Characters are separated by -
(dash or a hyphen) in these kind of tokens.
What possible risks/attack vectors could be introduced be allowing my server application to make outbound calls to a 3rd party REST API? The 3rd party REST API is off premises and owned and operated by the 3rd party.
+ +In order to clarify and limit scope let's just focus on attacks that result in impact on our business (so DoS and things like that would count). Let's also assume that it's properly protected via HTTPS. The users will be other businesses and the on-boarding would be controlled, so there's very little room for bad actors to inject themselves as legitimate system users.
+ +The data from the 3rd party is not essential/used/trusted in our system. In fact our calling out is purely a notification of an event being sent in a fire-and-forget scenario.
+",111417,,129883,,1/2/2020 17:28,1/2/2020 17:28,Security Risk of outbound web calls,Recently, when staying in a rented apartment, I signed in to the YouTube app on the smart TV by entering a code using chrome on my tablet to pair them. I was planning to log out before I vacated the apartment but forgot to do so.
+ +What are the security implementations of this? I am not bothered by people seeing my viewing history on YouTube etc., but obviously wouldn't like anyone to access any other google services via my account.
+",37242,,,,,1/21/2022 20:06,Didn't log out of YouTube - Is this a problem?,There is a requirement for an unattended, publicly-accessible machine that I have to only allow company-approved USB devices (e.g., USB mass storage, keyboard, mouse, Bluetooth, etc.,) and block all the rest (non-approved).
+ +Even though PID, VID, serial number are unique identifiers to USB devices, but, if somebody knows those information he/she can easily create a USB with the identifiers mentioned above and produce an approved USB.
+ +Is there any way that I can add unique and secure identifiers to USBs (except VID, PID, S/N) and set up a mechanism to differentiate between company approved USBs and non-approved ones and allow only the approved ones?
+ +Expected result: Secure USB for devices that are left unattended (e.g., kiosk) in public places.
+",224324,,6253,,1/2/2020 17:20,10/24/2021 1:05,Secure USB (unique identifier),I am about to go travelling to some high risk countries where corrupt officials will most likely try to go through my laptop and external HDD.
+ +I am using Linux Mint and LUKS. Could someone please tell me based on these pictures whether I have encrypted them both properly, this includes the cache (or whatever it is called) as I would hate to leak information. I know that /boot can stay unencrypted.
+ + + +Picture of external HDD after I entered password:
+
I can provide more information upon request.
+ +Thank you
+",111952,,,,,1/3/2020 14:05,Have I used LUKS properly?,Searched around and couldn't find a similar question.
+ +I've gotten tired of waiting for an 2FA SMS to come every time I check my email. So I got to setting up an app similar to say Google Authentication on my desktop, so that when I get prompted for a code I can just copy/paste from my toolbar.
+ +I can see how this basically defeats the 2FA purpose though right?
+",79228,,6253,,1/2/2020 17:31,1/2/2020 18:49,Is there a security problem with having two factor auth running on the same machine that's requesting access?,A similar question has been asked here:
+ +Can hackers detect my operating system?
+ +My question is, if malicious file has been downloaded off of a secure 3rd party website (i.e. not owned/controlled by the malware writer), would this malware be able to detect which operating system it has been downloaded to? Or would the malware need to be tailored to one particular OS?
+",215324,,,,,1/2/2020 17:30,Can an already downloaded malicious file detect the operating system?,If you have multiple products/sites under a common domain, what are the advantages and disadvantages, from user convenience to security, of having a common login page? For example, this site uses https://security.stackexchange.com/users/login for login. Google uses accounts.google.com and Microsoft uses login.live.com. However Apple doesn't have a common page, Facebook has the login form on the home page and most banks do too.
+",168571,,,,,1/27/2022 10:56,What are the tradeoffs between a common login site and login-per-site?,I noticed this while testing SNI-based HTTPS filtering for fun. My test was to block mail.yahoo.com, but allow other yahoo.com services. Here are my tests using Chrome:
+ +Access mail.yahoo.com by entering the full URL https://mail.yahoo.com: BLOCKED
Access mail.yahoo.com by logging into my Yahoo account via https://yahoo.com, and clicking the ""Mail"" link: NOT BLOCKED
I ran a packet capture while re-creating test #2 and I see there are no Client Hello messages with the mail.yahoo.com name in the SNI extension field. This is why I assume the web filter, which relies on inspecting the SNI extension field, is not blocking the website.
+ +I am trying to understand why I wouldn't see a Client Hello message w/ mail.yahoo.com in the SNI field when running test #2. Is the browser somehow using the same TLS session since the *.yahoo.com certificate is valid for both www.yahoo.com and mail.yahoo.com? I am interested to know more about how this works.
+",224327,,224327,,1/3/2020 2:56,1/3/2020 2:56,No Client Hello w/ SNI when accessing website's subdomain via link,If the intention of attacker is to execute an arbitrary client side script in the context of a web application, is XSS the only possible attack other than compromising the server with an RCE or a sub-resource supply chain attack?
+ +Why I believe this question is not a duplicate: +There are multiple questions dealing with the exploitation of a locked computer on this site, but most of the answers are focused on exploiting a non-hardened system in default configuration. I believe that in recent years, with major advances in encryption and hardware+software authentication (secure boot, bitlocker, virtualization, UEFI,...), the threat model for a hardened laptop is significantly different and therefore, I'm reasking this question under the following scenario:
+ +Technical assumptions:
+ +Assuming I'm sitting somewhere with an attacker, I lock my laptop and leave for 5 minutes, is it feasible for the attacker to gain access to my laptop (either by bypassing the lock screen, or extracting files using some other method (extracting the bitlocker key,...)) before I return, under the condition that I mustn't notice anything suspicious after coming back?
+",224340,,224340,,1/3/2020 2:14,1/3/2020 2:14,What is the physical security (Evil Maid) threat model of a modern hardened laptop?,I'm learning about security, and it seems that all of the security problems I have seen come from input from malicious actors.
+ +I was told that it's possible to check for the existence of bugs in a program, but not possible to check that a program doesn't have any bugs. Following from this, this means that it's not possible to prove that a program is 100% secure (correct me if I'm wrong).
+ +So I was thinking, is it possible for a program to be hacked in some way without explicitly taking user input?
+ +And by hack, I mean making the program do something it wasn't designed to do.
+ +For example: somehow forcing a program to take in user input by other means even though the actual program code doesn't take in user input.
+ +Or subverting the execution of a simple Hello World program and making it execute a shell.
+ +Is it possible to craft a program that doesn't explicitly take user input, but can still be hacked?
+",199580,,6253,,1/3/2020 12:50,1/3/2020 12:50,Can a program that doesn't explicitly take user input be hacked?,What is the security risk of not disabling TLS v1.1/.2 ?
+ +I have multiple websites on Cloudflare
+",162382,,,,,1/3/2020 2:56,main reasons to disable TLS 1.1/1.2,So I booted up two windows 7 64bit sp1 versions in virtualbox and shared their network and the operating systems are vulnerable to the SMB exploit that the wannacry ransomware is using. The Issue is that when I'm running wireshark I don't see any attempts of the SMB exploit on the other machine. Is it because wannacry is detecting the vm?
+ +I want to see SMB activity in my lab, which is my main goal of this test.
+ + +",224102,,,,,1/3/2020 5:29,Wannacry testing in lab - Not getting SMB scan attempts,I'm running https://ngrok.com/ on Windows 10 pro with a custom app made on Node server running locally (can't be Linux) for a test suite that uses both web and desktop integrated. So I'm basically hosting a server on the machine for another internal machine to access via the internet (there is no other way to solve the problem). Not considering securing the app itself but in case someone discovers the IP of the machine what can I do to secure it? The machine cannot use VPN, it's not connected to a domain but just plugged into ethernet. Only minimum software is running and everything else was removed. Everything is up to date and Bitdefender is installed.
+",222398,,,,,9/29/2020 8:02,How to protect Server running on Windows 10 with Node Ngrok against attackers?,I'm working on improving the security of my own system by mitigating the chance sensitive information, (e.g. encryption keys) stored in RAM, are inadvertently written to disk. As of now I know of three common ways this can occur and how they could be mitigated:
+ +Excluding these (as well as tools specifically designed to dump memory) are there any other reasons RAM could unintentionally be written to disk by the operating system?
+ +I would really appreciate any help I could get!
+",224347,,,,,1/3/2020 5:06,In what ways can the contents of RAM be (inadvertently) written to disk?,I am looking for best practice for username/password login. +People have different views for client side hashing on password.
+ +From Google's recommendation +https://cloud.google.com/solutions/modern-password-security-for-system-designers.pdf
+ +The client side hashing should be implemented as below:
+ +++ +Have the client computer hash the password using a cryptographically + secure algorithm and a unique salt provided by the server. When the + password is received by the server, hash it again with a different + salt that is unknown to the client. Be sure to store both salts + securely.
+
My questions are
+ +I agree the server should send a (unique) salt to the client. But why does the server need to hash the client result again with another salt?
Does the above mechanism suggest the server should store both salts as separate columns in the database table? And assume both salts are static (not changed per each login?)
SSL/TLS have mechanism to avoid replay attack. Does the above mechanism provide extra value to counter replay attack? I don't see any random factor about the static salts and I cannot relate anything can address replay attack.
I’m willing to create a system of transferable documents (identified by it’s ID) whose author can transfer his ownership of that document to another person (identified by his/her ID).
+ +For example:
+ +(Item 4 is very important)
+ +We can make sure that the system with it’s author remains untouched by using digital signature. But if Alice made a copy of that document signed when she was the owner, there would be no way to prevent her from saying she is not the owner of the document.
+ +So we would need something to make a signature to expire whenever it is transferred.
+ +IF I HAD A DATABASE: I would simply add that signature to a ban list.
+ +Are there any solutions to preserve the uniqueness of this document?
+",223270,,10863,,1/3/2020 8:23,1/3/2020 8:23,How can I preserve the uniqueness of a document without a database?,We're a company selling embedded devices. Our devices use u-boot & Linux, both being GPL and therefore we have to release the sourcecode as used to build our binary.
+ +We're in the process of implementing more security measures (both to increase reliability as well as protection against IP theft), so of cause encryption becomes a topic. Some people call for the encryption of u-boot and kernel (which is supported by the hardware for the bootloader as well as by u-boot for the kernel).
+ +Is there a reasoning in protecting our GPL covered binaries by encryption? We already have secure boot in place (HW for Bootloader, U-Boot for Kernel, ...)
+",224360,,224360,,1/3/2020 10:42,1/3/2020 10:42,Is there a reasoning encrypting a GPL binary where I have to publish the sourcecode?,We are currently evaluating which authorization type to use for our production AppSync APIs.
+ +As per AWS docs(https://docs.aws.amazon.com/appsync/latest/devguide/security.html, https://aws.amazon.com/blogs/mobile/using-multiple-authorization-types-with-aws-appsync-graphql-apis/ ), AppSync supports multiple authorization types - like API Key based (passing a static API Key), IAM role based.
+ +My questions are around the differences between API Key based approach & IAM based one:
+ +1)why is using a static api-key considered bad for production use cases if all calls to AppSync are HTTPS based(which has good encryption)?
+ +2)Why can't we use a short lived token of our own along with API key & validate that token in a resolver? This would bring in some dynamism as the token is shortlived , so even if somebody hacks and gets this token ; by them time a replay happens the token is already expired?
+ +3)The previous manual token approach seems similar to using an IAM role for Authorization. How safer would it be to use Amazon Cognito's IAM Auth. roles for this be than a manual token approach? Does the SIGV4 standard used by AWS help in anyway here?
+",224363,,,,,1/3/2020 10:38,AWS Appsync authorization - why is IAM authorization safer than API Key based approach,UPDATE: Upon further research, I discovered a library that appears to meet my needs, especially with regard to the chunked aspect. Rather than ""roll my own"", I would be better served to use this well-established library:
+ +https://github.com/defuse/php-encryption
+ +I have a need to encrypt large files (up to 2GB), while at rest, using an amount of memory that is not a function of the input file size.
+ +Accordingly, I intend to employ a ""chunked"" approach whereby I read n bytes of the input file, encrypt it, append it to a file pointer, and repeat until the end of the input file is reached. To decrypt, the process would be reversed, in essence.
+ +I have found what looks to be a fairly reasonable attempt at this:
+ +https://www.php.net/manual/en/function.openssl-encrypt.php#120141
+ +But I have several questions/concerns about the author's code:
+ +$key = substr(sha1($key, true), 0, 16);
+
+
+I thought that perhaps there is a limit to the key length, but passing a key whose lengh is much greater than 16 characters does not seem to cause an encryption/decryption failure, in which case this seems entirely pointless, if not detrimental to the viability of this function.
+ +Doesn't this alteration weaken the key considerably by reducing it to a mere 16 characters in the [a-f0-9]
range?
Use the first 16 bytes of the ciphertext as the next initialization vector
inside the while
loop?$iv = substr($ciphertext, 0, 16);
+
+
+From what I gather, this is strictly necessary for the chunked approach to work because the IV for each chunk must be known while decrypting, and in this implementation, it is obtained from the previous chunk.
+ +My understanding is that where CBC ciphers are concerned, the best-practice is for every call to openssl_encrypt()
to use a maximally random IV. To that end, would it be better to call openssl_random_pseudo_bytes(16)
within each iteration, as the author does initially (outside the loop), and prepend the freshly-generated IV to the chunk? If so, it seems like that would affect the block size/handling such that I would need to make other changes.
In any case, is the author's approach to generating the IV for each chunk sane? Or should I rework this aspect?
+ +How important is HMAC, given that these files are to be uploaded to a server, encrypted at rest, and then downloaded from the same server? The files are encrypted while in transit via TLS over HTTPS, so I'm not concerned about an adversary compromising their integrity while in transit. The server on which the files reside at rest is ""trusted"" in that I control it, but, of course, that does not mean it couldn't be compromised in some capacity. What are the risks in foregoing HMAC, given my use-case, and is it feasible to implement using a chunked approach?
+ +Thanks in advance for any feedback!
+",44399,,44399,,1/3/2020 14:32,1/3/2020 14:32,How does one implement chunked CBC encryption safely; is this implementation flawed?,From my experience, 99%[citation needed] of the time, when you try to log on to a website, and you mistype your password, you get some indication that the login could not proceed due to incorrect information and the password field is cleared out. Usually the username field remains filled in, so you simply have to retype your password.
+ +In a small fraction of instances, I've found that some websites do not clear out the password field after an incorrect login attempt. Is this a security issue? I can't think of how or why it may be, but I find it odd behavior since the overwhelming practice seems to be to clear the password field. Can this practice be exploited in some way by someone?
+ +As an addendum, is there some sort of standard that says the password field should be cleared out after an unsuccessful login attempt or is this practice something that most websites have converged on without formalizing anywhere?
+",134100,,,,,1/6/2020 16:01,Clearing password field after an invalid login attempt,What's the likelihood of a laptop being compromised when it comes directly from a trusted computer store or a large, known computer technology company? Would there be any liability if malware or rookit was discovered?
+ +What checks / scans would you perform if you wanted to be as sure as possible that it hasn't been compromised?
+",224380,,,,,2/2/2020 20:03,Security of a laptop order,With SSH, most of my servers use ed25519 (the twisted Edwards variant EC) for authentication.
+ +I was wondering, after authentication with ed25519, does SSH protocol 2 simple use ephemeral/ephemeral ECDH over curve25519 for the session key?
+ +I can't see what else it's doing unless it converts the ed25519 x,y co-ordinates to curve25519 Montgomery variants to establish the session key.
+ +Example output verbose is:
+ +debug1: kex: algorithm: curve25519-sha256
+debug1: kex: host key algorithm: ssh-ed25519
+debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
+debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
+debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
+debug1: Server host key: ssh-ed25519 SHA256:KvJtkvHyH/+oU3VaDDMQbUHIyI9P+LDLv0FqLdrfmEk
+debug1: Host 'ubuntu-prime.local' is known and matches the ED25519 host key.
+debug1: Found key in /Users/john/.ssh/known_hosts:40
+
+
+My question is, what curve25519
keypairs are being used here?
The description from Mozilla warns that require-sri-for
is obsolete and may be removed at any time.
The feature seems useful, especially for large websites where it's likely that a developer may forget to include an integrity attribute.
+ +Is there a specific reason this has been deprecated? Is there an alternative feature to use instead?
+",31625,,,,,1/5/2020 14:30,Why is CSP require-sri-for marked as obsolete?,My host machine is running Windows 10. I've installed VirtualBox and use it to run an Ubuntu VM. Inside the VM I use Firefox to do all of my web browsing that doesn't involve entering sensitive data like important passwords, financial data or government id info.
+ +I use another separate Ubuntu VM for just the following: +- checking my email and social media +- shopping from amazon and newegg
+ +On my host (the windows machine) I use the paid version of Bit Defender Total Security to perform regular scans and it is configured to its default settings.
+ +Finally for banking and logging into government websites, I use a separate (physical) Chromebook, which is exclusively for those purposes and strictly nothing else.
+ +Is this all a good security practice? Or is it all just a lot of extra work for nothing?
+",224392,,,,,4/14/2021 16:37,Is using virtualbox for web browsing worth it for added security?,So, imagine that a vulnerable app provides a login interface. This login sends the user's credentials to the App's server to authenticate the user. However this is done via HTTP, therefore not secure.
+ +If I were inside the user's LAN network, I could easily perform a MITM and sniff the traffic and therefore the unencrypted credentials.
+ +The questions is, how can I retrieve the credentials of a specific user by knowing this vulnerability WHILST being outside the network? What kind of practical attack vectors would there be?
+ +I set up an external drive for data backup (an SD card inside my laptop card slot). In addition, I connect with a cloud drive for offsite backup (an app that I run only when syncing files).
+ +I always sign in and use my laptop as a 'standard' user. My external drive is set for UAC 'read' privilege only.
+ +I then set my data sync app to run as admin only - meaning I need to type in the admin password before data can be synced to my external drive and to the cloud.
+ +Of course I will remain vigilant about keeping OS and apps updated and avoid clicking email links or downloading unsolicited payloads,etc. -- but in case I miss something and a ransomware comes through, will my Win 10 system stop that ransomware from encrypting my external drive?
+",224395,,,,,6/2/2020 6:30,Will this Setup Protect My Data Files from Malware (e.g. Ransomware)?,I know that you can pass cookies in Wfuzz by using multiple -b parameters like so: wfuzz -w /path/to/wordlist -b cookie1=foo -b cookie2=bar http://example.com/FUZZ
but I am wondering if you can pass a list of cookies, instead of doing them one by one, which takes forever and is ineffecient. I have looked everywhere for an answer it seems but I can't find one.
+",223896,,,,,6/5/2020 11:36,How do I pass a list of cookies to Wfuzz?,gpg
has some preset default settings, which I assume were selected as a compromise between speed and security. I understand that these are good enough for most people.
But, in a situation where speed / performance was not an issue, what defaults could be changed, to make gpg
use stronger parameters, and use even stronger encryption ?
For example, I have read discussions about the s2k-count
default value being not sufficient. I really don't care if my gpg operation takes 50 milliseconds or 200 milliseconds. I would rather err on the side of safety, even if it is overkill.
Specifically, I would like to use the strongest possible values for:
+ +What else could be changed from default values, to make gpg
more secure ?
I am using gpg (GnuPG) 2.2.12
on Debian Buster.
I am aware that Format String Attacks work by having a vulnerable function which allows the user to read values from the stack using %x
and write by using %n
.
Since one of the goals of a Format String Attack can be to overwrite the address of a function in the Global Offset Table, I was wondering does StackGuard prevent this?
+ +I know that StackGuard protects save-return addresses of functions to be overwritten, however, will it help against a Format String Attack if that attack aims to change the GOT values?
+",224408,,,,,10/17/2020 16:01,Does StackGuard prevent Format String Attacks,I'm debugging some edits I made to hostapd which requires me to capture some beacon frames, but I can only capture them with airodump-ng and not with wireshark.
+ +I have a Panda PAU09 adapter running on Kali.
+ +Method #1:
+ +I fire up airmon-ng and put the Panda into monitor mode. Next I run airodump-ng to find the BSSID and channel of my system running hostapd. Then I run airodump-ng again to capture to a file. I open the CAP file in Wireshark, and there are my beacons. COOL! Exactly what I needed!
+ +Method #2:
+ +I put the interface into monitor mode and start Wireshark on that monitor interface. I set the filter to just look for beacons and see tons of them... but none from my AP. I remove the filter and see no traffic at all from the MAC. I even log into the hostAP system to verify the MAC and it is correct. No traffic from that device at all in wireshark, but plenty with airodump.
+ +I'd really like to just use Wireshark.
+ +Thoughts on how to debug?
+ +Thanks.
+",121834,,,,,1/7/2020 1:31,"Why does airodump-ng shows 2.4GHz AP beacons, but wireshark does not?",I bought a used laptop and I'm concerned about the integrity of the firmware on the hardware and bios. I realize these types of malware are very rare.
+ +1) My question is that if I assume that the BIOS or SSD or NIC firmware is indeed compromised from the previous owner, what are some of security features that something like Qubes OS will provide me despite this?
+ +2) I have read that installing AIDE/Tripwire on dom0 at the beginning of a fresh Qubes OS install can be a powerful tool to see whether the BIOS malware infection is going to damage the dom0 and other downstream VMs in any way going forward. Do you think this is useful?
+ +3) The manufacturer website has downloads for BIOS firmware, SSD firmware, wireless LAN/WAN, etc. My BIOS and other firmwares are 1 year out of date. If I update these firmware over windows, and then wipe windows from SSD and start a fresh Qubes OS install, will the firmware stay updated? And will it also remove potential malware that was previously infected?
+ +4) What are some good practices for preventing these types of firmware attacks? My system uses TPM 2.0. Is there a guide to get TPM2.0 working with dom0 to check and analyze logs? Is it a good practice to turn off/not update intel ME, disable intel TXT, AMT, and secureboot? Because that is what I did.
+",224428,,,,,1/4/2020 23:27,Used laptop with potential BIOS/SSD firmware malware,Currently I have a Node JS project that uses the Spotify API. The project displays the users top played artists and tracks. I am following the Authorization Code Flow to obtain the access token. This access token will be used to query certain endpoints to obtain a JSON response of the data that will be used for my project. This token lasts an hour. I am currently storing this access token in a cookie and using this cookie to make new requests.
+ +My question is is this acceptable from a security standpoints? This token does not have the ability to change any of the users profile settings or read sensitive data. However, if another person were able to obtain this token they could use this to see another user's data. Or would it be more secure to store this access token in a database an query the database for access tokens whenever need?
+",224083,,215709,,1/5/2020 12:19,1/5/2020 12:19,Storing third party API tokens in a database,This question was prompted by a recent visit to a certain site that provides (apparently for GDPR reasons) a table with all of your data, including part of your hashed password. I understand this poses no problem in this case (as you would have to be logged in to see this table), but what if this data was made public?
+ +To rephrase more clearly: does revealing part of your password hash (including the hash length) make password cracking (via bruteforce or any other method) any simpler or more efficient than before?
+",224431,,224431,,1/6/2020 18:49,1/10/2020 17:52,Does revealing part of your hash give an attacker advantage when attacking your password?,They say that the last TOR node presents all the information in clear.
+ +If I want to send some sensitive information by TOR, could you encrypt it, and in this way be encrypted by both the TOR nodes, and by my encryption?
+ +Is this possible?
+",224059,,86735,,1/4/2020 21:44,1/4/2020 22:07,Encrypt data within the TOR network,My goal is to develop a piece of software which is illegal in my country. Obviously I don't want anyone to be able to trace the code back to me or prove that I developed it after deployment. +What precautions would be needed? Which pitfalls need to be avoided? Is there a tutorial?
+ +I would suspect that full drive encryption on your development machine and internet connectivity over Tor are required.
+ +What setup would be needed when developing in countries with political repression or similar conditions?
+",224435,,10863,,1/4/2020 23:59,1/5/2020 7:49,Untraceable software development,Before you immediately comment ""you can't trust the client!"", please read the whole question.
+ +I've been reading about how to prevent XSS attacks lately, and everything I've found says that the server should sanitize the data that will be put into the webpage. This would basically look like addToDatabase(filter(userResponse))
. Then the client can safely add display anything that it gets from the server.
I was wondering if it would be safe to store the potentially unsafe data in the server, and have the client filter it when it was received, like addHTML(filter(serverResponse))
. This would stop the data from being executed client-side, so no XSS would take place. I understand that anyone could simply remove that filter
, however all that would do is make themselves vulnerable. Since other clients would filter anything sent to them, a malicious client could could only disable their own filter and mess up themselves.
+(I'm not talking about SQL injection prevention, that would be obviously have to be server-side)
To summarize: The server doesn't sanitize, but the clients sanitize whatever they receive.
+ +Would this be safe?
+",179871,,,,,1/5/2020 5:23,Preventing XSS by filtering data from the server to the client,I am working to set up OpenVPN access to my home network. To do this, I had to contact my ISP, because they had the necessary port blocked at the Gateway/Router that I do not have access to.
+ +In my house, I have a Google WiFi system.
+ +They put the provided Gateway in Bridge mode, instead of Router mode. This solved my problem, but when I ran an nmap against my public IP afterwards, a great number of ports (including vulnerable ones) were now listed as ""open"".
+ +My question is, since I have the router in the house, and I have it set up to block all ports I have not configured to forward, is there any real risk here, having the ports showing as open at the Gateway?
+",194748,,,,,1/5/2020 2:24,Open Ports at ISPs Gateway,Given the plethora of random password generators (RPG) available, I'd like to do some black box testing on some.
+ +Let's take https://passwordsgenerator.net/ for example. Assuming the whole generator is a black box with 0 information about how the passwords are generated (can't even view the .js
stuff), and all we have is a ""Generate password"" button that somehow outputs a seemingly random password each time it's clicked.
We do NOT know:
+ +What we know:
+ +We can get thousands or millions of passwords as testing data. Given just those passwords, can we analyze them to figure out (even just estimate) how cryptographically secured the RPG is?
+ +(I'm not looking for processes enough to generate whole reports and research papers. I'm just thinking of a way the common people can do a ""quick"" and rough test on the RPGs, maybe to choose between the common RPGs)
+",206331,,,,,1/6/2020 13:38,How can one test if a password generator is cryptographically secured?,When looking at entitlements on pycharm CE for macOS, it shows many serious security exceptions. Here are its entitlements:
+ +<dict>
+ <key>com.apple.security.cs.allow-jit</key>
+ <true/>
+ <key>com.apple.security.cs.allow-unsigned-executable-memory</key>
+ <true/>
+ <key>com.apple.security.cs.allow-dyld-environment-variables</key>
+ <true/>
+ <key>com.apple.security.cs.disable-library-validation</key>
+ <true/>
+ <key>com.apple.security.cs.disable-executable-page-protection</key>
+ <true/>
+</dict>
+
+
+Why does pycharm uses such lax security? Is it necessary?
+ +I tried to look into pycharm's source code, and I saw this commit:
+ +++ +Add macOS notarization script
+ +GitOrigin-RevId: e8779699a5c41df82848b335a3aed82b7550c7eb
+ +VladRassokhin authored and intellij-monorepo-bot committed on Jun 5, + 2019 commit 631c91b
+
c1a579488452da099b957305502cda2f4
+ +But I couldn't find a clear reason why pycharm would need these security gaps. Can anyone with knowledge of pycharm's code can shed light on this?
+",143641,,,,,1/5/2020 10:40,Why does pycharm uses lax security on macOS?,Given a setup where we have nginx
sat in a DMZ serving static content, forwarding (REST/WS) requests through a firewall to tomcat
running on a server where other applications are also running:
YOU <> [FW:443] <> (NGINX) <> [FW:8443] <> (TOMCAT)
+ ( APP1 )
+ ( APP2 )
+ ( DB )
+
+
+Can I focus on just the nginx & tomcat applications in terms of patching CVEs/vulnerable dependencies, or must I ensure that all other applications are as 'CVE-free' as possible.
+ +I believe this is different to this question about whether applications behind a public firewall need to be patched.
+",224450,,,,,1/1/2022 18:07,"Fix vulnerabilities in ALL applications, or only client-facing ones?",When a mobile app is sending HTTPS requests, it verifies the server certificate against some kind of certificate store. My question is, would that certificate store be provided by the phone's OS, or would it be packed with the app?
+ +I know I can do certificate pinning, but first I want to know what's the default.
+ +If there's any difference between Android and iOS, I'd want to know that.
+",16116,,,,,1/6/2020 8:59,Do mobile apps have their own certificate store?,If we user both: desktop VPN client + chrome VPN extension +or +if we use just browser's vpn extension,
+ +does ISP see which website/link we visit?
+",224457,,,,,1/5/2020 15:04,Can ISPs see which website we visit when we use desktop VPN client and browser VPN extension?,I assume the state is not 4Gb but that there's a 32bit counter and it's mixing like in chacha. What's the point of creating those 4Gb if there's no entropy to do so. What I mean is that if the first 1024 bits are the same, so would the rest of the 4Gb, so why even offer the option.
+",208898,,,,,1/5/2020 15:04,How can Blake2X produce 4gb digests?,Exposing primary keys is bad practice. How should I expose UUID or BIGSERIAL Primary Keys to clients — hashing, encoding, encrypting? For integers there are libraries like hashids, what about UUID?
+",222160,,,,,1/5/2020 19:56,Exposing UUID or BIGSERIAL Primary Keys,How do you prevent someone from doing an TCP reset attack between client and host without having acess to host?
+ +I am trying to solve a CTF for fun and learning purposes. +In one of the challenges I establish a connection with a server that starts sending me TCP packages, but I am interupted by a third party that sends what appears to be a forged tcp reset. I receive a RST, ACK and the packages stops coming.
+ +I have tried both DROPing and REJECTing the RST package without success, using the following command:
+ +iptables -A INPUT -p tcp --tcp-flags RST RST -j DROP
+
+
+Is there any way that I could nullify the attacker trying to prevent communication between me and the host?
+
Keepassx lets you decide how many transformations rounds need to be run in order to unlock your Keepass database. In my version of Keepassx (2.0.3) the max value seems to be 999,999,999. With that setting it takes my laptop about 22 seconds to unlock the database. I imagine that a beefy workstation would take less time than that. With that in mind, how well can this setting deter someone else from accessing your database, assuming that they managed to get access to it? Let’s just say an individual (not an organization) with a computer made to do this kind of work. How much work can you assume that they will have to do per try with the kind of computation power that they will have access to in twenty years?
+",224469,,,,,1/6/2020 8:02,How well will the max transformation rounds in Keepassx deter an attacker for the next twenty years?,I selfhost my mail server and have earlier downloaded Spamassassin corpus from http://artinvoice.hu/spam to have a head start on the bayes learning.
+ +The artinvoice.hu site is down and has been for weeks.
+Are there any known good alternatives?
I've read that pre-shared keys (PSKs) are symmetric keys shared in advance among communicating parties but have found no explanation as to how the TLS client and server agree upon the value of the PSK. How is this done?
+",224476,,138516,,1/6/2020 5:27,1/6/2020 8:34,How are PSKs agreed upon by the TLS server and client?,Just before Christmas I received the following message in one of my GMail accounts:
+ +++ +Sign-in attempt was blocked
+ +
+ ********@gmail.com [redacted by me]Someone just used your password to try to sign into your account. Google blocked them, but you should check what happened.
+
I signed into that account and looked at the activity (not by clicking the link in the message, of course) and indeed there was a sign in attempt blocked from the Philippines.
+ +I gather this means that an attacker entered the correct user name and password for my account, but was likely blocked because they couldn't pass the MFA challenge. Or maybe Google's fraud detection is actually decent and it knows I've never been to the Philippines? Either way, I immediately changed the password and (as far as I know) the attacker didn't gain control of the account.
+ +However, in the 2 weeks since then, I have received several email verification requests from various online services that I never signed up for -- Spotify, OKCupid, a Nissan dealership in Pennsylvania (that one's interesting), and a few others I've never heard of before. Someone out there is actively using my GMail address to enroll for these services.
+ +The account in question is not my main account, and while the password on it was admittedly weak, it was also unique (I never used it on anything else). I changed it to a password that's much stronger now.
+ +Should I be concerned about this?
+ +Also, if the attacker didn't gain control of the account, why use it to enroll in all these services?
+",171798,,,,,10/30/2021 23:28,My email address is being used to enroll for online services. Should I be concerned?,I posted a question similar to this one on Stack Overflow, but that has not produced any answers so far, so I'm hoping someone here will be able to help me out.
+ +Somewhat simplified, I'm trying to do a POST request via https using Postman (later I'm hoping to reproduce it in PL/SQL under Oracle using UTL_HTTP), but I'm having some certificate-related issues. I have a specific url I'll be trying to reach later, but for testing purposes, I've been using a webhook url just to verify that I could make calls out at all.
+ +I am able to perform a post request to a https-address if I disable SSL Certificate Verification under the Postman settings - so it's apparently possible to reach an outside url, so long as I don't care about the validity of the certificates used.
+ +Proxy issues
+I my problems are due to the fact that I'm behind a proxy at the organization I'm currently working for. If I look at the certificate path for the cert for webhook.site for instance, it looks like the following, where the grayed out parts of cert names are names related to the organization.
The result of this is that when I try to perform https POST requests to webhook without disabling cert verification, it fails with the following error shown in my Postman console:
+ +++ +Error: unable to verify the first certificate.
+
Attempted solutions
+A couple of things I've experimented with to try to solve this:
My hunch is that I just need to get the correct certificate installed in the correct place in order for this to work. The problem is I can't figure out which certificate that should be in this case (or where it should be installed for that matter, though I would assume that adding it under trusted root certificates in the system cert store should suffice?).
+ +Are these assumptions correct? Any tips on how I can figure out exactly which certificate I'm actually missing?
+",42360,,,,,9/27/2021 11:03,How to identify which certificate I'm missing to produce HTTPS calls?,I'm looking into mutual TLS authentication for a B2B API. Is it possible to use mutual TLS authentication using X.509 certificates while relying on Public CAs?
+ +I see that some Public CAs (from CA/Browser Forum) offer signed ""client authentication"" certificates. What fields can I rely on in this case? Would I be able to just map the Subject Name to a user in my application and trust the CA/Browser bundle?
+ +Can ""Public CA 1"" guarantee that ""Public CA 2"" will not sell the exact same certificate to a different company?
+",31030,,,,,1/7/2020 13:32,Client Certificates from Public Certificate Authorities,Just reviewing some logs and I am seeing local scans to several local IP addresses on port 137 within my network. The source IP however is the broadcast IP of the VLAN (.255).
+ +I have checked the logs and I can see the broadcast IP trying to initiate udp 137 connections on several other IP addresses of the same subnet.
+ +Many of the errors being shown are ""The Windows Filtering Platform has blocked a connection"".
+ +I cant really make sense of the Source IP address being the broadcast IP. Has anyone come across this before please? and from your experiences, where should I be looking that I could have missed? Thanks.
+",197502,,,,,1/26/2022 0:03,Local Scans initiated from a VLAN Broadcast IP address,Veracode is reporting a security issue on a piece of code which seems pretty innocuous to me. The code is built with python/Django and the line in question is:
+ +++ +return render(request, 'core/create-user.html', context)
+
The render shortcut for django is pretty standard and it expects a request object, name of template and context to be passed to template. I am not sure why Veracode is complaining for this.
+ +It seems it is picking up the word ""create-user"" from the template name and assuming it be a OS/library method being called for creating a user based on some user input and which is why it is complaining but this sounds pretty dumb to me on behalf of Veracode.
+ +Is it really a security issue, if so why? Or is it a false positive?
+",143010,,,,,1/7/2020 10:14,"VeraCode static code scan of django view reports ""External control of Filename or Path"" on render method",I have the following code in my frontend javascript which basically reads the csrf cookie value and sets that in the ajax calls done via jquery.
+ + var csrftoken = self.getCookie('csrftoken');
+ xhr.setRequestHeader(""X-CSRFToken"", csrftoken);
+
+
+This seems to be a very standard technique and yet Veracode reports it as a vulnerability.
+ +Looking at the details of this kind of vulnerability, at https://cwe.mitre.org/data/definitions/113.html, I don't see how could it be an issue given the http header is being set from client end and not server end. If the csrf token value is injected wrongly, the request would not suceed due to csrf mismatch anyways.
+ +Why does Veracode consider this to be a vulnerability at all or is it a vulnerability that I am unable to understand?
+",143010,,,,,2/25/2022 18:05,"VeraCode static code scan reports ""Improper Neutralization of CRLF Sequences in HTTP Headers"" for frontend code",Is it possible to break a Windows encrypted SAM file where passwords are stored if you have the physical drive offline?
+ +Thanks
+",224512,,,,,1/9/2020 3:39,Breaking SAM windows password file offline,I found CRLF injection on a site but it doesn't has any login, session or anything or that sort. I wonder if there's any way to prove impact of CRLF injection here.
+ +Something that I think can be done is, an attacker can craft the payload in such a way that it would respond with Location
header and user would be redirected to a malicious site. This is called Response Splitting. But I'm not sure if the company would consider this as a vulnerability because user's can only be redirected.
I asked myself if that's the only thing an attacker can do? After sometime I realized XSS can also be perform with response splitting but what would attacker get with XSS as there is no session cookie or anything?
+ +I can't figure out how to show am impact of this, are you aware of any interesting header or anything, any help?
+ +EDIT: I found a broken link to an external site on this same forum and checked for content on wayback.
+ +It says.
+ +++ +Cross-User Defacement: An attacker can make a single request to a vulnerable server that will cause the server to create two responses, the second of which may be misinterpreted as a response to a different request, possibly one made by another user sharing the same TCP connection with the server. This can be accomplished by convincing the user to submit the malicious request themselves, or remotely in situations where the attacker and the user share a common TCP connection to the server, such as a shared proxy server. In the best case, an attacker can leverage this ability to convince users that the application has been hacked, causing users to lose confidence in the security of the application. In the worst case, an attacker may provide specially crafted content designed to mimic the behavior of the application but redirect private information, such as account numbers and passwords, back to the attacker.
+
But I don't understand it properly, can anyone please explain it in simple words?
+",224511,,224511,,1/6/2020 14:56,2/5/2020 16:03,Is there an impact of CRLF injection on static sites?,The following questions regard linux processes with a stack that grows downwards from the end of the process memory.
+ +If I have a buffer overflow on the heap with unlimited size, are there any protection against me overwriting the entire process memory until reaching the stack and overwriting it?
Same question for buffer overflows in mmaped memory regions, which in comparison to the heap can reside closer im memory to the stack
Thanks!
+",224518,,,,,9/28/2020 2:06,Can a heap/mmap buffer overflow overwrite the stack,I am trying to write an API that allows the user to reset their password via their email.
+ +I have been following https://www.smashingmagazine.com/2017/11/safe-password-resets-with-json-web-tokens/, but I am a bit confused. They are sending the email and user_id in the payload as JSON, but they never actually need this information. The only time they use the payload data is when they could easily retrieve the same data from another source.
+ +So what is the point in sending it?
+",224522,,19891,,1/6/2020 18:16,9/28/2021 11:02,What is the point of the payload in reset password API with JWT,I'm working on an Interactive Fiction story in Undum, which is a fully client-side JS/HTML5 framework. I've been reading about Content Security Policy lately (after looking up what a crypto nonce is) and began to wonder if any such thing would be important for code that's entirely client-side. I'd apply some basic CSP if I could, mainly the ban on inline code exec, but it looks like that can only be specified in an HTTP header which I don't control in this case (I think -- there's no transfer happening in my game, but github pages hosts the HTML and JS so HTTP is in use and is presumably controlled by github)
+ +This question addresses a similar concern, but is a simpler context since it will be running locally on that OP's machine. My context will be as follows:
+ +What security concerns might be relevant to a kinda sorta web app like this? There's no sensitive data involved; I'm mostly concerned with any sort of malicious script injection that might be possible.
+",142166,,142166,,1/6/2020 22:11,1/6/2020 22:51,What security concerns are there for a fully client-side JS/HTML5 app?,I'm building an SPA app and I have to use an access token to make requests to an API. The most common way to store the JSON Web Tokens is to use localStorage
, but I have always thought that was a bad idea because of XSS attacks or a user could be socially engineered to go to the console, get the token and give it away.
So I use this JavaScript library called 'secure-ls', which uses localStorage but encrypts the data. The encryption key is randomly generated for each instance of the application, so I don't store it as plain text in the code.
+ +This is what it looks like:
+ +private static _instance: SecureStorage = new SecureStorage({
+ encryptionSecret: crypto.randomBytes(60).toString(),
+});
+
+
+This is what the encrypted data in the console looks like:
+ + + +The plain-text data in localStorage is only available to the code. I believe this is sufficiently secure and I can't see how a hacker could get the plain-text data.
+ +So it leaves me to wonder why more people don't use this method? Or is there some loophole I'm missing in how a hacker could get the data?
+",224539,,,,,1/7/2020 2:55,Is encrypting localStorage data more secure?,Can this method of encryption prevent bruteforce attacks?
+ +If I had a hypothetical table (or function) where every grammatically valid sentence (limited to some number of words) was given an associated number, e.g:
+ +""Good morning, how are you."" = 3283
+""Today is a nice day."" = 2183
+
+
+Then added a number (as a key), e.g:
+ +3283 + 1234 = 4516
+
+
+Wouldn't this final output of 4516
be effectively protected against bruteforce attacks?
Ignoring the difficulty of producing a hashtable/function capable of reducing every valid input into a single number, and the issue of sending the key 1234
securely.
Is there any way of finding the original input only from the output?
+ +Is limiting the domain of the encryption to only valid inputs, an effective method of preventing bruteforce attacks?
+ +If so is there any practical example of this? Why or why not?
+",211767,,211767,,6/13/2020 11:47,6/13/2020 11:47,Can bruteforce attacks be prevented with tables of valid inputs?,There must be a handy way to securely store, say, GCP key.json somewhere on my machine and access it whenever I'm deploying stuff. Backup to cloud is a must. The Apple's Keychain access seems troublesome. Is there a better solution?
+",141727,,,,,1/7/2020 13:52,How do I securely store credentials and key files on my mac?,Proprietary software developed by a (smallish) company is stored in the company's GitHub private repository. For work, software engineers are requested to create company-specific GitHub account bound to their work email address.
+ +But access to the private repository can be granted or revoked independently from the ""account origin"". What can be the risks of using personal (i.e. associated with an email which is not related to the company) GitHub account by developers?
+ +Edit: I see one potential risk: if the account is used also for other things than work, its SSH key is likely to be saved also in places where these ""other things"" are done. This is a potential threat to work repositories; with a dedicated account, it's easier for the developer to keep the key(s) only in work-related (maybe controlled) environments.
+ +Are there any other specific risks?
+",50647,,50647,,1/7/2020 10:26,1/7/2020 10:26,Risks of allowing employees using personal GitHub accounts for work,I've decided to use Argon2id for storing users' passwords in my database. +I have two questions:
+ +I have been using LastPass for a while and I have just seen an option to generate an exposure report. By its output, I assume it checks various sources containing credentials dumps from hacked web applications for matches to my username / e-mail.
+ +The output looks like the following:
+ +{date 1}
+somedomain.com
+
+{date 2}
+some collection name
+
+{date 3}
+Unknown source
+
+
+I am curious about how such applications work behind the scene. Also, is there a way to find out more about my exposed e-mail in such dumps (i.e. more sources).
+ +I see that haveibeenpwned.com lists many breaches, so I could consume their API to validate against my known hostnames. As a side note, somedomain.com
is not listed by Pwned websites.
Question: How do applications such as password managers check leaked credentials and how can I get more results?
+",164712,,164712,,1/7/2020 13:14,1/7/2020 14:34,How do applications such as password managers check leaked credentials and how can I get more results?,A company has several remote branch offices located in relatively dangerous places, such as Iraq, and I'm looking into strategies to secure the SAN in the event of theft or looting. The data is commercially sensitive and contains intellectual property. Some of these offices are mobile, moving locations every couple of months.
+ +Basically, the goals are:
+ +Each site has:
+ +At present, no data is encrypted - for this question, that's what I want to focus on.
+ +Do you have any suggestions? Should we encrypt at the SAN level, the vSphere level, the OS level? How should keys be managed?
+",224584,,224584,,1/7/2020 14:37,1/7/2020 18:37,Strategies to protect SANs in branch offices in risky places,We are currently trying to enhance the security posture of our company, and this means changing how some IT personnel work.
+ +Put precisely, our IT helpdesk currently have 2 separate accounts: 1 for normal day-to-day usage (mails, internet, etc...), and 1 for administrative tasks. The latter is a privileged account having several rights on the AD and some servers.
+ +The way they work is not very secure when it comes to supporting the users: they use their privileged account to login to the user's workstation and perform tasks where admin rights are needed.
+ +But my question is more accurately related to network drives being mapped in their privileged account's profile. They insisted on using the same logon script as with their standard account.
+ +Do you have any recommendations, references to guidelines, and/or best practices in such a case? I'd like to present them some resources to convince them it's not secure to have network drives mapped in this profile.
+ +I tried to explain to them that if they log in a 'contaminated' workstation, their privileges might spread the infection to the network... But they did not understand and argued they need to access some files on the network while assisting the users. They don't want to waste time typing UNC path, etc...
+",219676,,129883,,1/8/2020 7:35,1/8/2020 7:35,Best practices or advice to convince IT admins not to map network drives in privileged sessions with users,Recently, we migrated from Windows 7 to Windows 10 and during that migration, we progressively ran into some issues with our NAS device. To be more precise, we progressively noticed some tcp socket flooding on it while client computers were upgraded to Windows 10. We suspect that our NAS has some difficulties with NTLM, but this is out of this question scope.
+ +Our NAS has a FQDN : filesvr1234.prod.company
+ +We also have a DNS alias pointing to that FQDN : prodfiles.company
+ +Kerberos authentication is enabled on filesvr1234.prod.company, but not on the alias prodfiles.company because we have some legacy apps that need NTLM.
+ +We investigated on those issues by running WireShark while trying to read a file from a samba share on our NAS \prodfiles.company\shared\test.txt.
+ +We observed the following behaviour. +Both Windows 7 and Windows 10 try first to authenticate using Kerberos.
+ +Windows 10 will try authenticate using the alias prodfiles.company (which is the expected behaviour because we access the share with \prodfiles.company\shared\test.txt). It will use NTLM. However, we noticed that Windows 7 uses the FQDN (filesvr1234.prod.company) instead of the DNS alias, even if we access the share using the alias (\prodfiles.company\shared\test.txt). It will use Kerberos.
+ +To see this, we looked at ""SNameString"" in KRB5 packets (Wireshark). +To summarize : +We read a file in \prodfiles.company\shared\test.txt +Windows 7 use filesvr1234.prod.company even if we access the share using prodfiles.company. +Windows 10 use prodfiles.company
+ +Does something changed between Windows 7 and Windows 10 that makes the authentication process to use the DNS alias instead of the FQDN ?
+",178974,,,,,1/7/2020 17:42,Does Kerberos authentication handle DNS names the same way between Windows 7 and Windows 10?,I received a message with the famous link My-love co via Whatsapp and I never clicked on the link; I blocked the contact and deleted the message containing it; such a link was reported as infected by the newspapers.
+ +Despite the fact that I didn't click on it, a strange icon with the profile picture and the name of the person who sent it to me appeared in my home. I reset my phone then and reinstalled WhatsApp by recovering the backup of the chats.
+ +No traces of the infected link in there (because I deleted the message before resetting the phone), so I was no longer worried about it and I sent a message to the contact. +After that, I blocked him again to avoid the possibility of other infected messages.
+ +Today that strange icon with his name and profile picture appears again on my home. I cannot find it in the APPs list.
+ +I never clicked on any link and I did hardware reset, so my questions is:
+ +Why such a virus is there and why it's still there even after the hardware reset? Is it possible that the infected Whatsapp account is able to spread the trojan simply by being there in the contact list of my phone or because I opened his message (even if I didn't click on the link)? Or might my SIM card be virus-infected instead?
+",96606,,96606,,1/7/2020 16:21,1/7/2020 16:21,How I rescue my Android from a trojan and how did I get it?,