Home » security

Tag Archives: security

Spring Security Login Example

In this article we will learn how to use spring security to create a simple login page. You will need an IDE (I am using IDEA IntelliJ), JDK 1.8 or later, Maven 3.0+. 1. Introduction The Spring Framework provides a comprehensive programming and configuration model for modern Java-based enterprise applications – on any kind of deployment platform. A key element ...

Read More »

Java Servlet Security Example

The @ServletSecurity annotation is used to define the access control or the security constraints to the servlets. In this tutorial, we will see how to configure the Basic Authentication in the servlets. 1. Introduction If developers are planning on using the Basic Authentication they must be aware that if they use the plain HTTP requests, the username, and password can ...

Read More »

Apache Hadoop Knox Tutorial

In this tutorial, we will learn about Apache Knox. Knox provides the REST API Gateway for the Apache Hadoop Ecosystem. We will go through the basics of Apache Knox in the following sections.                     1. Introduction Apache Knox is the open source project under Apache Software Foundation similar to most other ...

Read More »

JAX-WS Security Example

In this example we shall learn, how to implement JAX-WS security to SOAP web services. Security is always critical to web services. When talking about web services security here, following security issues are considered: Wire-level security Assurance between client and web service that they are the only one communicating. Data encryption. Assurance that received message is same as sent message. ...

Read More »

Play! Framework Security Example

Today, security has become a priority in most web applications. Even giant enterprises have security issues that are found from time to time. The first barrier to avoid this issues is a login page to avoid people from seeing information they are not meant to see. Also, there are headers that mitigate security issues and provide an extra level of ...

Read More »

Java Nio SSL Example

This is an example of a non-blocking I/O provided by java.nio using SSL handshake.                     1. Definition of Secure Sockets Layer Protocol (SSL) SSL is the secure communication protocol of choice for a large part of the Internet community. There are many applications of SSL in existence, since it is capable ...

Read More »

How To Configure Tomcat To Support SSL Or Https

In this short example we are going to see how to configure Tomcat to support SSL protocol, and thus https connections. 1. Create a Self – Signed Certificate for the Server For SSL to work (properly) it is obligatory for the  Server to identify himself to the client. To do that, the Server will need a certificate. Of course, when ...

Read More »

Application Authentication With JAX-WS

In this example we are going to see how to implement a simple application level authentication in JAX-WS. The notion of authentication is very well covered and its necessity is quite clear. In our tutorial we are going to authenticate a client to the endpoint server. The idea is straight forward. The client who wants to consume the Web Service, ...

Read More »

Generate a File Checksum value in Java

In this tutorial we are going to see how to generate a file’s Checksum value in Java using the SHA-1 hash function. If you are working on your applications security specs it might be useful to consider using checksums to improve the security and integrity of file transfer or file sharing actions. In short, the basic steps one should take ...

Read More »

Set File permissions in Java example

With this example we shall show you how to set file permissions with Java. This is a very important task to take into consideration when you’re working in a shared system. Although this operation is operation system specific, Java offers a generic API that you can use in all platforms. As you know in UNIX systems you can go much ...

Read More »