Pras' Labs

Instalasi Let's Encrypt Dan Konfigurasi HTTPS Di Aplikasi Nginx Pada CentOS 7

Let’s Encrypt adalah Certificate Authority (CA) yang gratis dan terotomatisasi yang berjalan untuk kepentingan umum. Let’s Encrypt adalah sebuah layanan yang disediakan oleh Internet Security Research Group (ISRG). Prinsip-prinsip dasar dari Let’s Encrypt adalah gratis, otomatis, aman, transparan, terbuka, dan koperatif. Instalasi Let’s Encrypt Instalasi Let’s Encrypt sudo yum -y install git bc sudo git clone https://github.com/letsencrypt/letsencrypt /opt/letsencrypt Buat sertifikat baru untuk domain example.com, sebelumnya hentikan dulu aplikasi Nginx ...

Konfigurasi Email Server Dengan SPF Dan DKIM Di Aplikasi Postfix Pada CentOS 7

Setelah kita melakukan instalasi email server, cek skor email server di website Mail Tester. Salah satu contoh hasil pengecekan website tersebut sebagai berikut. Content: [Text] [HTML] [Source] SpamAssassin: [Score] The famous spam filter SpamAssassin. A score below -5 is considered spam. Authentication: We check if the server you are sending from is authenticated [SPF] Sender Policy Framework (SPF) is an email validation system designed to prevent email spam by detecting email spoofing, a common vulnerability, by verifying sender IP addresses. [Sender ID] Sender ID is like SPF, but it checks the FROM address, not the bounce address. [DKIM] DomainKeys Identified Mail (DKIM) is a method for associating a domain name to an email message, thereby allowing a person, role, or organization to claim some responsibility for the message. [DMARC record] A DMARC policy allows a sender to indicate that their emails are protected by SPF and/or DKIM, and give instruction if neither of those authentication methods passes. Please be sure you have a DKIM and SPF set before using DMARC. [PTR record] Reverse DNS lookup or reverse DNS resolution (rDNS) is the determination of a domain name that is associated with a given IP address. Some companies such as AOL will reject any message sent from a server without rDNS, so you must ensure that you have one. You cannot associate more than one domain name with a single IP address. [A record] We check if there is a mail server (A Record) behind your hostname. Errors: Checks whether your message is well formatted or not. [Image alternate tag] alt attributes provide a textual alternative to your images. It is a useful fallback for people suffering from sight problems and for cases where your images cannot be displayed. [HTML elements] Checks whether your message contains dangerous html elements such as javascript, iframes, embed content or applet. [URL shortener] Checks whether your message uses URL shortener systems. [List-Unsubscribe header] The List-Unsubscribe header is required if you send mass emails, it enables the user to easily unsubscribe from your mailing list. [Blacklist] Matches your server IP address against 22 of the most common ipv4 blacklists. Untuk meningkatkan skor, kita bisa memperbaiki konfigurasi email server dengan SPF dan DKIM ...

Membuat Virtual Machine di FreeBSD dengan bhyve dan vm-bhyve

Sejak FreeBSD 10.0-RELEASE, hypervisor bhyve (lisensi BSD) sudah menjadi bagian dari base system. Hypervisor adalah aplikasi yang bisa membuat dan menjalankan virtual machine atau yang biasa disebut guest di dalam sebuah sistem operasi. Guest yang didukung oleh bhyve cukup banyak, termasuk FreeBSD, OpenBSD, dan banyak distribusi Linux. Saat ini bhyve hanya mendukung konsol serial dan tidak bisa menampilkan konsol grafik. Bhyve membutuhkan prosesor baru yang mendukung Intel Extended Page Tables (EPT) atau AMD Rapid Virtualization Indexing (RVI), yang dikenal juga sebagai Nested Page Tables (NPT). Untuk Linux atau FreeBSD guest dengan vCPU (virtualCPU) membutuhkan dukungan VMX unrestricted mode (UG). Cara termudah untuk mengecek dukungan prosesor untuk bhyve adalah dengan menjalankan #dmesg# atau melihat isi /var/run/dmesg.boot untuk fitur POPCNT di baris Features dan EPT dan UG di baris VT-x. Panduan yang cukup lengkap untuk menggunakan bhyve dapat diakses di halaman ini ...

Re-Introduction to Python

Python is one of the programming languages which can claim to be both simple and powerful. Python is an easy to learn, powerful programming language with efficient high-level data structures and a simple but effective approach to object oriented programming. Python’s elegant syntax and dynamic typing, together with its interpreted nature, make it an ideal language for scripting and rapid application development in many areas in many platforms. Guido van Rossum, the creator of the Python language, named the language after the BBC show “Monty Python’s Flying Circus”. ...

Playing with Ansible and FreeBSD

By default, FreeBSD doesn’t install a python package in its standard distribution. So, we need to install python, either manually or using ansible module. ansible freebsd-host -m raw -a 'env ASSUME_ALWAYS_YES=YES pkg install python' -u root Of course before we can use ansible we have to install public key authentication and enable SSH to root user in FreeBSD host from controller machine. FreeBSD install python in different path than Linux machine, so we must set variable for the python interpreter, either in host file or variable files. ...

The End of Generation of Tinkerers

The Prologue My college was the only college I know that gave the chance to its students to run the college network infrastructures. It encourages the students to study more outside their respective fields and share the knowledge in a community. Only a handful of people know that in the early days, the network infrastructure of my college, was built through the hands of its own students and the tradition to maintain it has been passed through the new generation of students. ...

Akuisisi Data Sensor LM35 dengan Arduino

Ini adalah tulisan pertama di blog ini yang membahas tentang hardware dan yang pertama menggunakan bahasa Indonesia. Sensor temperatur LM35 (datasheet) adalah sensor IC (Integrated Circuit) yang memberikan respon terhadap perubahan temperatur di sekitarnya dalam bentuk keluaran tegangan analog. Sensor temperatur LM35 bekerja pada tegangan 4 sampai 30V dan mempunyai respon linear 10mV/derajat Celcius pada rentang -55 sampai 150 derajat Celcius berdasarkan datasheet yang tersedia. Akuisisi data menggunakan sensor temperatur ini adalah percobaan sederhana yang bisa dikembangkan untuk perangkat Internet of Thing. Garis besar percobaan ini adalah keluaran dari sensor LM35 dibaca oleh Arduino melalui pin input analog (A0). Pin input analog Arduino mengeluarkan nilai dengan resolusi 10 bit untuk rentang 0 sampai 5V. Untuk mengetahui tegangan keluaran dari sensor LM35, diperlukan perhitungan berikut ini, ...

Percona Server 5.6 Installation on CentOS 6

Percona Server 5.6 is the latest release of drop-in replacement for MySQL®. The new version offers all the improvements found in MySQL 5.6 Community Edition plus scalability, availability, backup, and security features found only in MySQL 5.6 Enterprise Edition, which requires a support contract from Oracle to access. Percona Server 5.6 is free, open source software which includes superior diagnostics and improved integration with other Percona software. In this documentation, I will show how to install Percona Server 5.6 on CentOS 6. ...

Beanstalkd Installation on CentOS 6

Beanstalkd is a simple, fast work queue. Its interface is generic, but was originally designed for reducing the latency of page views in high-volume web applications by running time-consuming tasks asynchronously. In this documentation, I will show how to install Beanstalkd on CentOS 6. Install Beanstalkd from EPEL repository using yum sudo rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm sudo yum install beanstalkd Enable and start Beanstalkd service sudo chkconfig beanstalkd on sudo service beanstalkd start Reference: https://kr.github.io/beanstalkd/download.html ...

Sensu Installation on CentOS 6

Sensu is often described as the “monitoring router”. Essentially, Sensu takes the results of “check” scripts run across many systems, and if certain conditions are met; passes their information to one or more “handlers”. Checks are used, for example, to determine if a service like Apache is up or down. Checks can also be used to collect data, such as MySQL query statistics or Rails application metrics. Handlers take actions, using result information, such as sending an email, messaging a chat room, or adding a data point to a graph. There are several types of handlers, but the most common and most powerful is “pipe”, a script that receives data via standard input. Check and handler scripts can be written in any language, and the community repository continues to grow! In this documentation, I will show how to install Sensu on CentOS 6. ...