Please Wait, Loading...

Wednesday, 4 January 2017

Mengamankan Akses Website Menggunakan .htacces

Berikut ialah panduan praktis untuk mengamankan aplikasi berbasis website kita dengan menggunakan .htaccess :
  1. Konfigurasi ulang utk webserver anda, untuk tutorial ini menggunakan webserver apache

    # vi /etc/httpd/conf/httpd.conf
    <Directory "/var/www/html">
    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://httpd.apache.org/docs/2.2/mod/core.html#options
    # for more information.
    #

    # Mengamankan akses ke folder
        Options Indexes FollowSymLinks
    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   Options FileInfo AuthConfig Limit
    #
       # aktifkan .htaccess
        AllowOverride All

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   Options FileInfo AuthConfig Limit
    #
        AllowOverride None

    #
    # Controls who can get stuff from this server.
    #
        Order allow,deny
        Allow from all
    </Directory>
  2. Buat file .htaccess dan tempatkan di dalam direktori website anda
    AuthName "Restricted Area"
    AuthType Basic
    AuthUserFile /home/mysqlweb/public_html/.htpasswd
    AuthGroupFile /dev/null
    require valid-user
  3. Buat file .htpasswd, bisa menggunakan htpasswd generator online seperti http://aspirine.org/htpasswd_en.html atau http://htpasswdgenerator.net/ dan lain sebagainya :
    #admin PasswordAdminWebsite
    admin:$apr1$2aUZu.iI$jpny/50c8lP6vA4FrBtRl/
    Semoga bermanfaat..

Posted By Administrator09:15

Friday, 30 December 2016

Block the Microsoft “Auto IP-Listening” Service

Pernahkan anda berpikir jika sofware OS windows yang anda pakai, dapat digunakan sbg "Spy Tools"..? Pertanyaannya tsb kemungkinan besar dapat di jawab dengan jawaban "bisa dan itu sesuatu hal yang mungkin terjadi..".

Tips berikut adalah bagaimana agar Bagaimana Suatu Sistem Operasi yang ada di komputer kita khususnya Sistem Operasi Windows tidak dapat mendapatkan IP Address kita tanpa adanya perijinan dari kita, berikut langkah-langkahnya :

1) Buka REGEDIT dan tekan Enter

2) HKEY_LOCAL_MACHINE

4) SYSTEM

5) CurrentControlSet

6) Services

7) NLaSvc

8) Parameters

9) Internet

10)  “EnableActiveProibing” dan Set menjadi Bernilai “0”
 Semoga bermanfaat..

Posted By Administrator04:28

Friday, 23 December 2016

Solusi Kirim Email Di Framework CI "fsockopen()"

Solusi ketika anda dihadapkan oleh pesan error

 Asumsi disini bahwa konfigurasi mail sudah sesuai :
public function lupa_password(){
        $email = $this->input->post('email');
        $data_user = $this->m_lapor_api->check_email($email)->result();
        if(count($data_user)>1){
            foreach($data_user as $data){
                $this->load->library('email');
                $email = $data->email;
                $config = Array(
                    'protocol' => "smtp",
                    'smtp_host' => "domain.com",
                    'smtp_port' => 465,
                    'smtp_user' => "admin@domain.com",
                    'smtp_pass' => "passwordUserMail",
                    'smtp_crypto' => "ssl", //can be 'ssl' or 'tls' for example
                    'mailtype' => "html",
                    'smtp_timeout' => "4",
                    'charset' => "iso-8859-1",
                    'wordwrap' => TRUE
                );
                $this->email->initialize($config);
                $this->email->set_newline("\r\n");
                // Set to, from, message, etc.
                $this->email->to($email);
                $this->email->from("admin@domain.com","Layanan Email");
                $this->email->bcc("admin@domain.com");
                $this->email->subject("Layanan Lupa Password");
                $this->email->message("password anda ".$data->password);   
               
                if(! $this->email->send()){
                    echo "sukses";
                }else{
                    echo "gagal";
                }
            }
        }
        echo $this->email->print_debugger();
    }
 Jika script diatas dicoba maka akan muncul pesan error diatas, bagaimana solusinya, solusinya ialah mengganti :
'protocol' => "smtp"
Dengan :
'protocol' => "sendmail",

Demikian solusi praktis dari kasus  "fsockopen()... ", Semoga Bermanfaat





Posted By Administrator22:16

Monday, 5 December 2016

Solusi "The requested URL /zabbix was not found on this server"

Ketika zabbix anda di update versi nya terutama dari versi 2.xx ke 3.xx, maka suatu ketika server zabbix anda akan error dengan error "The requested URL /zabbix was not found on this server",  bagaimana solusinya, berikut langkah-langkah solusi untuk kasus tersebut :

Cek paket zabbix terinstall
yum list installed | grep zabbix
output dari perintah tsb :
fping.x86_64                  2.4b2-16.el6      @zabbix-non-supported
zabbix-agent.x86_64           3.0.3-1.el6       @zabbix
zabbix-release.noarch         3.0-1.el6         installed
zabbix-server-mysql.x86_64    3.0.3-1.el6       @zabbix
zabbix-web.noarch             3.0.3-1.el6       @zabbix
zabbix-web-mysql.noarch        3.0.3-1.el6       @zabbix
Copikan :
cp /usr/share/doc/zabbix-web-3.5.3/httpd22-example.conf /etc/httpd/conf.d/zabbix.conf
Restart webserver :
 service httpd restart
Semoga Bermanfaat

Posted By Administrator18:24