Saturday, January 13, 2018

AWS Certified Solutions Architect - Associate

New year, 2018! New challenges!!

Passed the exam and now I am officially AWS Certified Solutions Architect - Associate. Next is Professional #StayTune

Friday, September 08, 2017

If you need to perform LDAP query against Active Directory with objectGUID as the filter, you need to convert the string representation of that GUID to octetstring.

For example, if the objectGUID string value is: ffe17244-4c77-48e7-9db7-69578be7e232
You need to convert it to: \44\72\e1\ff\77\4c\e7\48\9d\b7\69\57\8b\e7\e2\32

so then you can provide the LDAP filter with:

To do this by C#, use the following function:

        private string convertStringGuidToOctectString(string guid)
            Guid g = Guid.Parse(guid);
            Byte[] gba = g.ToByteArray();

            string result = "";
            foreach (Byte b in gba)
                result = result + @"\" + b.ToString("x2");

            return result;

Good luck!

Wednesday, August 16, 2017

Let's Encrypt and Sophos XG Firewall

I am publishing my web server behind the Sophos XG firewall. I need SSL certificate that is free and trusted by most of internet browsers. The answer is Let's Encrypt.

I use this site to help integrate with Let's Encrypt :

#1 Generate CSR from the XG firewall and download the CSR and the private key
#2 Navigate to and paste the CSR content
#3 Follow the instruction to validate your domain - I did DNS option by inserting TXT value
#4 Once validation is successful, the signed public key is ready to be downloaded
#5 Upload the signed key to XG firewall along with the private key that was downloaded on step #1
#6 (optional) if XG firewall does not trust Let's Encrypt CA, add this to the Trusted CA


Saturday, July 22, 2017

Another .NET app I wrote to help the project to compare the performance between different web proxies

This app helps me to see the respond time that each proxy responds to a request to a particular URL address. You can specify the header, how many request do you want to perform, so that you can create the "worm" graph. It is quite fun to see this running infinitely.

The picture above shows 2 proxies being compared to hit with IE header and 10 iteration to produce the performance graph.

Thursday, June 15, 2017

Tuesday, May 16, 2017

Proxy PAC Tester

I wrote this .NET program to parse the PAC file and test its exception. This provides the GUI, rather than using google unsupported CLI code.

It supports direct fetch from the URL or static PAC file.

Sunday, April 30, 2017

Ubuntu CIFS Mount to Windows

To support SMB2 mount from Ubuntu to Windows, edit the fstab file and include this:

//windows.domain.local/share/folder /mount/point cifs credentials=/root/.credentials,vers=2.0,iocharset=utf8,sec=ntlm,dir_mode=0770,uid=33,gid=33 0 0