Category Archives: Linux

Ways to protect your WordPress site – Heart Internet Blog – Focusing on all aspects of the web

As WordPress grows in popularity, it becomes more important to protect your WordPress installation. Here are our tips for securing your WordPress site.

If you would like a managed WordPress hosting solution visit http://www.wordpressrepair.co.uk

 

Source: Ways to protect your WordPress site – Heart Internet Blog – Focusing on all aspects of the web

PHP connection to Microsoft SQL server from LAMP server

We have recently been working on a project for a client that involves dynamically creating web pages from data stored in a Microsoft SQL database. The solution is based on a LAMP (Linux, Apache, MySQL and PHP) server running Ubuntu.

Why not use IIS I hear you ask? Mainly because of costs and licensing and the Ubuntu server will be running several Web sites.

Here is a very basic example of the PHP code using PDO and DBLIB:

$user="username";
$password="password";
$dbh= new PDO('dblib:host=SERVERNAME\SQLSERVERINSTANCE;dbname=DBNAME',$user,$password);

$query = “SELECT * FROM SOME_TABLE”;
$statement = $dbh->prepare($query);
$statement->execute();
$result = $statement->fetchAll(PDO::FETCH_ASSOC);

var_dump($result);

You need to install the DBLIB PDO driver:

sudo apt-get install php7.0-sybase

Fail2ban Linux Security

Fail2ban scans log files (e.g. /var/log/apache/error_log) and bans IPs that show the malicious signs — too many password failures, seeking for exploits, etc. Generally Fail2Ban is then used to update firewall rules to reject the IP addresses for a specified amount of time, although any arbitrary other action (e.g. sending an email) could also be configured. Out of the box Fail2Ban comes with filters for various services (apache, courier, ssh, etc).Fail2Ban is able to reduce the rate of incorrect authentications attempts however it cannot eliminate the risk that weak authentication presents. Configure services to use only two factor or public/private authentication mechanisms if you really want to protect services.

Source: Fail2ban

2016 New Software Development Projects.

Software Development Projects for 2016

Are you consider a new software development project in 2016 ? If so I am available for short and long term projects during 2016. I normally work from my office in Botley, Southampton.

I have experience in working in several different development environments such as Windows, Apple and Linux and languages C#, Python, PHP, JavaScript (Jquery) and Swift.

Example project types:

  • Windows applications.
  • Linux.
  • Web based applications.
  • Web / screen scraping.
  • IOT.
  • Mobile applications.

If you have a project or product in mind don’t hesitate to get in touch, I am only an Email away.

Ifor@idh.org.uk