Skip to main content

Posts

Showing posts from May, 2015

Generate SSH Keys in Ubuntu

An SSH key allows you to establish a secure connection between your computer and a remote server. This type of connection run by generating an SSH key in your local computer (or remote computer, keep private and public key in local computer, then store the public key in remote server. In Ubuntu, you can use this command: $ ssh-keygen -t rsa -C "lukibsubekti@gmail.com"

How To Use Git in Netbeans

Git is a popular version control application nowadays. Recently I have created a note about its differences with SVN and how to use it in Eclipse. There are many Git client tools. But I just want to show how to use Netbeans built in Git tools. It makes development process easier because it has been integrated with the IDE.
Create Remote Git Repository We need remote Git repository so everyone can store or receive any revision or updated files through the networks. We can setup our own Git server or use public Git server like Github. In this note, I use Github. 1. Create an account in Github and create an empty Git repository
2. Get the remote repository link
Create a New Project in Netbeans and Create Local Git Repository After we have a remote Git repository, we can create a project which will be stored to remote repository. We also need to create local repository before we can push any revision and files to remote repository. 1. Create a project. For example, I create PHP Application…

Create a Self-Signed SSL Certificate using OpenSSL

Self-Signed SSL Certificate can be used if you want to try to make secure connection to a server by encrypting the data like HTTPS connection. This is the method:
create a directory to store the certificate filesrun $ sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /path/to/yourkey.key -out /path/to/yourcert.crt to generate the key and certificate files.req: This specifies a subcommand for X.509 certificate signing request (CSR) management. X.509 is a public key infrastructure standard that SSL adheres to for its key and certificate managment. Since we are wanting to create a new X.509 certificate, this is what we want.

-x509: This option specifies that we want to make a self-signed certificate file instead of generating a certificate request.

-nodes: This option tells OpenSSL that we do not wish to secure our key file with a passphrase. Having a password protected key file would get in the way of Apache starting automatically as we would have to enter the passw…

Install PostgreSQL in Ubuntu 14.04

In Ubuntu 14.04, PostgreSQL repository isn't listed by default. We must add the record first.
Run $ nano /etc/apt/sources.list.d/pgdg.list to add repository list fileAdd deb http://apt.postgresql.org/pub/repos/apt/ trusty-pgdg main in the fileRun $ wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | \
sudo apt-key add -Run $ sudo apt-get update then $ sudo apt-get install postgresql-9.4 For administrator we can install pgadmin3
$ sudo apt-get install pgadmin3

For client tools we can install postgresql-client
$ sudo apt-get install postgresql-client

Check integrity of a file using MD5 sum and verify authenticity via GPG

When you download a file from a website, sometime the website also provide some codes of MD5 sum result to check file integrity after downloading. MD5 sum result can be generated using this command.
$ md5sum download.file
Then you can compare your result with code provided by the website.

Next, to verify authenticity via GPG, use this following steps.
- download the public key
- download the authenticity key
- run: $ gpg --import publickey.asc
- run: $ gpg --verify authkey.asc downloaded.file