Chilkat 21-Dec-2021 — PHP Versions to Internal PHP API Versions

What’s going on in Chilkat support today… 1. Error: PHP Startup: chilkat_9_5_0: Unable to initialize module $ php test.php PHP Warning: PHP Startup: chilkat_9_5_0: Unable to initialize module Module compiled with module API=20210902 PHP compiled with module API=20151012 These options need to match in Unknown on line 0 PHP Warning: dl(): Dynamically loaded extensions aren’t enabled in /home/chilkat/chilkat_9_5_0.php on line […]

PHP Script for Downloading, Installing, and Testing Chilkat

Here is a bash shell script for downloading, unpacking, installing, and testing the 64-bit PHP 7.4 extension for Chilkat. 1) It assumes PHP 7.4 was installed to $HOME/phps/php74. 2) This example is downloading Chilkat version (change the wget URL to the latest version) export PATH=$HOME/phps/php74/bin:$PATH php -v cd if [ ! -d testing ]; then mkdir testing fi cd […]

Start Browser from Client-Side PHP Script

Let’s say you have a PHP script (not PHP on a web server, but simply a .php script that you run from a command line), this is one way to start/launch a browser and automatically load/navigate to a URL. <?php // Type “start iexplore” and press “Enter” to open Internet Explorer and view its default home screen. // Alternatively, type […]

PHP AES/Rijndael Encryption Confusion

AES is not exactly synonymous with “Rijndael”. AES is a (restricted) variant of Rijndael. AES has a fixed block size of 128 bits and a key size of 128, 192, or 256 bits, whereas Rijndael is specified with block and key sizes in any multiple of 32 bits, both with a minimum of 128 and a maximum of 256 bits. […]

PHP Three-Key Triple-DES (3DES) Test Vector

This post provides PHP sample code for matching a test vector (known answer test). 3DES Settings: ECB Mode 192-bit key (i.e. 3 8-bit keys) ASCII Key Bytes: 1234567890123456ABCDEFGH ASCII Text to Encrypt: The quick brown fox jumped over the lazy dog Pads with zero bytes Hexadecimalized Encrypted Result: 13d4d3549493d2870f93c3e0812a06de467e1f9c0bfb16c0 70ede5cabbd3ca62f217a7ae8d47f2c7bf62eb309323b58b PHP Code: <?php $cipher = mcrypt_module_open(MCRYPT_3DES, ”, MCRYPT_MODE_ECB, ”); // […]