security aspects specific to the Java programming language and libraries.

learn more… | top users | synonyms

2
votes
2answers
70 views

Is writing to /dev/null secure?

I am working on a web-service based crypto project in JAVA. The basic idea is for the client to send a SOAP request to a servlet to encrypt data. For data transmission I am using MIME/data-handlers ...
2
votes
0answers
8 views

How CERT.rsa is interrelated with PackageInfo signatures

I am a newbie in security and cryptography, but I am developing Android applications and now wanna to dive deeper into the Android security mechanisms. I am trying to understand how CERT.rsa (as I ...
0
votes
0answers
20 views

Extract the content of PKCS7 file in Java

I have a PKCS#7 signature that have the content‐type signed data and it embeds an XML document, and I have to extract the xml document from this PKCS7 file. Anyone know how to do that in java ??
1
vote
0answers
18 views

SSLException: Unsupported record version Unknown-84.84 [migrated]

I'm facing a weird issue on our server that happens intermittently not quite often (once a month) and can't figure it out. I've searched for this and found this thread which is pretty similar to my ...
4
votes
1answer
110 views

Is it safe to enable SSLv2 ClientHello support?

In the wake of the POODLE attack, many web sites have dropped support for SSLv3. But some clients still in relatively common use as of May 2015 still initiate the handshake with an SSLv2 ClientHello ...
1
vote
1answer
64 views

How does Memory Corruption apply to Android?

I have researched several DoS attacks within Android e.g.: CVE-2015-1474 CVE-2013-5933 CVE-2013-4710 CVE-2012-6301 etc. And although I found DoS attacks within Android difficult to understand at ...
8
votes
1answer
292 views

Security Risks of BD+

I have recently been reading about the DRM measures on commercial bluray disks, in particular BD+. It seems that this technology involves Java software running in a virtual machine, with full access ...
1
vote
3answers
1k views

Client Authentication by certificates in Google APP Engine java

I am writing an application in Google APP Engine java which authenticate the user by its certificate. I have created a self signed certificate using keytool at client side. I also enable the HTTPS ...
3
votes
2answers
232 views

Secure way to store application settings

What is a proper or, if possible to tell, the best way to store configuration in matters of security? So far I can tell that a database with very restricted access is a good way, but please let's ...
1
vote
0answers
9 views

Need Help: How to do XML Element Encryption using JAVA? [migrated]

I have a question regarding Java programing. I have this .PFX file that contain public key and private key public key algorithm = RSA public key format = X.509 Public Key = Sun RSA public key, 2048 ...
3
votes
2answers
80 views

JKS - Keystore protection and configuration file

It appears that Java Keystore is often used by web server using a configuration file, with the password opening the JKS written in it and also the password protecting the specific entry. How could ...
0
votes
2answers
41 views

encryption protection against lost password

Here is a plan I am thinking about. I haven't seen this proposed, so I thought I would ask about it. Threat we are guarding against: A lost or stolen laptop leading to exposure of sensitive ...
2
votes
2answers
89 views

Understanding salted password hashing using Java

Context: I am using this tutorial and trying to understand and implement salted password hashing using Java. After spending some time on this topic, I figured out that the basic idea is to: Convert ...
1
vote
0answers
42 views

How can I use session salt for encrypting data using AES in CTR mode?

I have to implement a crypto-plugin in Java. The approach followed is conceptually similar to that used for SRTP. The algorithm used for data confidentiality is AES in CTR mode (I'm following a ...
1
vote
0answers
35 views

How get X509 certificate's full cert chain programatically? [migrated]

Imagine I have p12 container of private key and public certificate. When I export p12 public cert to separate .cer file with Java keytool I may click to .cer file and see full cert chain. How may I ...
0
votes
0answers
14 views

unable to download content from login page [migrated]

I am using apache tomcat on linux platform to host website. I put apk link on login page so users/guest can download mobile app but they are unable to download that app. When registered user login to ...
4
votes
3answers
1k views

JInitiator is obsolete and I should reject it on grounds of security, right?

I'm getting a lot of flack and resistance from developers for not allowing a large (200+ users) roll-out of Oracle's JInitiator (http://www.oracle.com/technetwork/testcontent/jinit-084453.html) as ...
1
vote
0answers
18 views

Why is OWASP CSRF-guard falsely detecting an attack when a user simply navigates to any page in my web-app? [migrated]

I'm trying to use OWASP's CSRF-guard in my Java Spring-MVC web-app but it's detecting a CSRF attack for any action a user makes. The web-app loads and as soon as the user tries to navigate to any ...
-1
votes
1answer
151 views

What makes an Android application vulnerable to Cross-site scripting (XSS)?

Definition of XSS If you search the web, there are many different ways to define a cross site scripting attack. Simply put, XSS vulnerabilities occur when a malicious attacker is permitted to inject ...
2
votes
1answer
49 views

REST API - XSS prevention - When and how?

I am currently developing a REST API with Java EE and MySQL, it will feed Data to a Android App. The Data comes from an AngularJS Frontend. So my questions are, when: When do I escape the data? Before ...
0
votes
1answer
67 views

What factors make Android app code vulnerable to Cross-Site Request Forgery attacks?

According to techtarget.com Cross-Site Request Forgery is: a method of attacking a Web site in which an intruder masquerades as a legitimate and trusted user. An XSRF attack can be used to ...
-1
votes
1answer
103 views

What makes an Android application vulnerable to Directory Traversal?

Definition of Directory Traversal Directory traversal is a form of HTTP exploit in which a hacker uses the software on a Web server to access data in a directory other than the server's root ...
0
votes
2answers
134 views

What makes an Android application vulnerable to SQL Injection?

Definition of SQL Injection SQL injection is a code injection technique, used to attack data-driven applications, in which malicious SQL statements are inserted into an entry field for execution ...
2
votes
1answer
144 views

How 'Logjam' attack affects openID since it uses Diffie-Hellman key exchange method?

According to the Diffie-Hellman key exchange get affected by logjam, and openID uses this to establish an association. So how this going to affect OpenID?
2
votes
1answer
467 views

SSL communication between a C# Server and an Android Client App

I'm using a C# server and a C# tcp client example I extracted from the MSDN and I have created a self signed certificate using makecert.exe. I have got this to communicate with one another and it ...
5
votes
2answers
351 views

How can the Android GraphicBuffer::unflatten() vulnerability (CVE-2015-1474) be exploited remotely?

I've been reading up-on DoS (denial-of-service) attacks within android and although I understand attacks like the below, which make use of regular programming functions etc. (Android Web Browser) ...
1
vote
1answer
8k views

Encrypting string in JavaScript and decryption in Java [closed]

I would like to know if there is any library to do encryption in JavaScript and decryption in Java. I have already tried many APIs, but am not getting the same values in Java. I want public-private ...
1
vote
2answers
89 views

Why is “\000” added to the end of passwords prior to hashing with bcrypt?

I am implementing bcrypt for java as found here. Before the actual hash takes place, line 455 of this implementation takes the raw String password, and transforms it into a byte array like so: ...
18
votes
4answers
7k views

Deleting a Java Object securely

I know that in order to delete a Java object I should use character array instead of String, since I can safely erase (rewrite the character array with other data) its content. This seems not to be ...
0
votes
0answers
30 views

Vulnarability test for CVE-2014-2483?

I am in penetration testing on a server with Linux RHEL6/7 os. Vulnarability databases such as http://www.cvedetails.com/ mentioned the vulnarability CVE-2014-2483 for java in linux RHEL systems. I ...
2
votes
2answers
125 views

Best way to securely store passwords for local use?

I am writing a Java application who needs three username/password pairs. I would like to add a "remember me" feature, implying I would have to store passwords on the user's computer. Knowing this ...
0
votes
0answers
60 views

Problem in 'underscore.js' “new Function()” when CSP header is set.

In underscore.js, template rendering causes violation of the 'unsafe-eval' property, with CSP error at following line: "render = new Function(settings.variable || 'obj', '_', source);" The solution ...
-3
votes
1answer
81 views

Have java drive bys stopped working? [closed]

I don't hear or read about Java Drive Bys (DBD) these days. Up until last year we were always warned against java drive by threats. What happened? Have they become obsolete these days? Edit: To be ...
0
votes
0answers
38 views

Securing REST API with HMAC and SPA

I'm developing a JS based SPA and the backend is a rest api which uses HMAC. The site/app doesn't have the concept of registered users but it has the concept of session. How do i make sure that the ...
2
votes
1answer
21 views

How is composed “public host key and certificates (K_S)” in SSH_MSG_KEX_DH_GEX_REPLY message? (SSH2 key exchange)

I'm trying to implement SSH2 key exchange in Java, and having some difficulties. The RFC4419 states, that: The server responds with: byte SSH_MSG_KEX_DH_GEX_REPLY string server public host ...
0
votes
3answers
4k views

Can you write OS-related virus using high level languages like Python

It is a well known fact that OS-related viruses are commonly written in low level languages like C or C++ which require direct access to the kernel of the CPU , I am just wondering if its possible ...
2
votes
1answer
240 views

Can a Java servlet filter be used to pull out scripts that aren't whitelisted?

I might be asking a similar question to this: Whitelisting DOM elements to defeat XSS But I think my proposed solution is different and I was wondering if I could get the community to comment on ...
1
vote
1answer
494 views

Share and store RSA - public key in java server and vice versa

My requirements are: Requirement 1: Share public key to java server. Steps: Generate public-private keys in iOS app. Store the generated keys in keychain. Send generated public key to java server. ...
0
votes
1answer
47 views

Risks of legacy JRE versions?

Certain business applications or legacy software require running older versions of the Java Runtime Environment on client systems, e.g. JRE6 or 7 rather than or in addition to 8. Assuming that ...
0
votes
1answer
928 views

What is the risk of installing Facebook Video Calling jar file?

I'm trying to talk with somebody on Facebook, but after many Facebook privacy scandals, it's a big question. Secondly on OSX, it's giving me the error that “FacebookVideoCalling_v1.6.jar” can’t be ...
0
votes
1answer
365 views

RSA key sizes v/s public key sizes

I am new to cryptography. I have an api provided by a bank. The banks says that they are using RSA algorithm with 2048 bits. We used this api first to get the public key. Here is the sample public ...
1
vote
0answers
74 views

OCSP stapling implementation in JAVA/ Android

I am trying to implement OCSP stapling in JAVA. How can this be implemented ? How can we set OCSPStatusRequest extension for TLS. and how we can verify the response ? Hi, How can we implement OCSP ...
3
votes
4answers
74 views

Is serialisation and HashMaps secure?

I've done some reading in this area and there is very little information about the security of a HashMap. The only article I could find was on IBM's Developer Works site. What hashing function is ...
0
votes
1answer
124 views

Java desktop app vs web service [closed]

I currently have a desktop app written in Java (Swing) which talks to a C-based backend over SSL. I am trying to understand the pros/con from a security perspective to move to a web service model. ...
1
vote
1answer
72 views

Why are unsigned Java applications blocked?

Anyone can purchase a code signing certificate. They are cheap and do not involve much validation. Yet Oracle must have determined that disabling execution of unsigned applications increases security. ...
1
vote
1answer
72 views

Session Fixation - Is that even an issue here?

Someone stepped up to me calling me out on not assigning a new session-ID on successfull login. Basically i was told: The fact that i use the same cookie (with the same SID) in the login-page as well ...
0
votes
0answers
82 views

What is the difference of TrustManager PKIX and SunX509?

Java's JSSE provides two different TrustManagers: PKIX and SunX509 I tried to find out what the differences between both are, but couldn't find any in the documentation. Can you tell me the ...
1
vote
0answers
508 views

Java Updates Restrict Unsafe SSL Renegotiation With Active Directory Servers

We have two active directory (AD) hosts, ead01.domain.com and ead02.domain.com; we also have a corresponding service domain, at eadauth.domain.com which round-robins between these AD hosts (via DNS). ...
0
votes
1answer
120 views

Signature Based Malware Detection

I am developing software for detecting malware based on signature, in Java. I have researched a lot for the approach to move ahead. I found that the basic idea is to store the existing malware ...
1
vote
3answers
81 views

IDS over HTTPS connection

I am designing an anomaly-based intrusion detection system in java. It basically consists of a sniffer that identifies HTTP header fields and then analyze them according to a previous configured XML ...