Small Basic Extension – Extended Small Basic Library (ESL) 0.4.1a

3/5/16 UPDATE: Added the 0.4.2a patch and 0.4.3a patch link and info.


Today's featured Small Basic extension comes from Liam McSherry. Here is information about the extension in his words...

Extended Small Basic Library, or ESL, is a small but powerful extension for Microsoft Small Basic. Although it didn't get off to a great start, and I was unable to work on it after the initial release on the 6th of October 2012, it is back, and with a new thread.

ESL is comprised of 12 classes, each of which either expand and improve on the Small Basic standard library, or bring new features of their own into the mix. These include advanced features such as cryptography, tetration, and include useful features such as being able to use C# arrays as storage, which
are significantly faster than Small Basic arrays.

ESL is an open source project, and a link to the source code will be at the end of this post. ESL is currently in an "Alpha" state of development, and may be buggy. All bug reports are welcome, but please try not to continuously report the same bug.

ESL on GitHub:
ESL Download:
ESL on Ohloh:
HTML ReadMe:

A basic "Getting Started" document for ESL is now available. It describes the classes within ESL, as well as providing a few code examples, and any relevant legal information.

Read "Getting Started with ESL": Started with ESL.pdf


Please feel free to provide suggestions in this forum thread. Thanks for your time, and I hope this extension is useful for you.

If you'd like to contribute to ESL, please fork the GitHub repository, and then file a merge request with your changes. It would also be helpful if you used the Issue Tracker provided by GitHub.

Licencing and legal information is available in the README, as well as a list of credits for various components that make up parts of ESL.

Added features in the 0.3.0a update:

  • GZip Compression (untested)
  • RC2 Encryption
  • DES Encryption
  • AES Encryption
  • Fibonacci Number Generation (up to n=138)
  • The mathematical constant e
  • The mathematical constant Phi (a.k.a. the Golden Ratio)
  • Number concatenation (32-bit and 64-bit)
  • HMAC (Hash-based Message Authentication Code) variants of SHA hashes
  • CRC-32 (ANSI X3.66) and CRC-64 (ECMA-182) checksum generation
  • Hyperexponentation (tetration)
  • Further text manipulation (ToUpper, ToLower, Reverse, etc)
  • RIPEMD160 Hash function
  • More file-format definitions
  • Primality checking (whether a number is prime)
  • A new HTML Read-Me

Added features in the 0.4.0a update:

  • Encryption methods have been patched to fix "Bad Data." exceptions; output from encryption is Base64-only now.
  • ESLWeb has been renamed to ESLNetworking.
  • Added an internal IP Address check to ESLNetworking.
  • Added an external IP Address check to ESLNetworking, as well as a check for an Internet connection.
  • OctalFromInteger and OctalToInteger added to ESLMaths
  • ExtractRange and Remove added to ESLText
  • ESLCrypto renamed to ESLSecurity
  • Added a password crack-time estimator to ESLSecurity (crashes incurred from large crack times)
  • ESLStorage now allows for 64 arrays rather than 16.
  • File definitions for ESLFile.Identify() now use the external file ESLFormats.xml.
  • ESLCompute class added
  • ThreadedCall() method added to ESLCompute to allow multithreaded Small Basic programs.
  • The time of compilation has been added to the ESL class.
  • Support for XTEA encryption via an XTEA engine.

Updates in the 0.4.1a patch:

  • Patch for WMI queries bug (found by MartMen here)
  • ESLNetworking.Ping(), which allows developers to measure the amount of time it takes to get a response from a server, in milliseconds
  • Conversion to and from Ternary
  • Methods for mathematics using various radices (e.g. HexMultiply(), OctalDivide()).
  • Generating up to 64-character encryption keys from a password using PBKDF2.


The ESL 0.4.2a patch includes a bug fix, two new feature updates, and an update to the Getting Started Guide!

This patch fixes an error with ESLFile, which was reported by a user via email, and includes some small functionality updates to ESL. These are:

  • ResolveIP added to ESLNetworking. This function transforms an IP address (e.g. into a machine name.
  • ResolveHost added to ESLNetworking. This function transforms a URI (e.g. into an IP address.

The Getting Started with ESL guide has also been updated to include an example usage of these functions.

 You can view the Getting Started guide here: Started with ESL.pdf


ESL 0.4.3a added 2 new features, changes to the encryption methods, and 3 features were removed because they are no longer needed. 

There aren't many changes, although the ones there are serve to make ESL easier to use, and others remove features that either were not in use, or are no longer required.


  • Fast Square Root method added to ESLMaths
    (accurate to 3 decimal places, and based on the Quake 3 fast inverse square root)
  • Method to calculate the sum of numbers 0 to n added to ESLMaths


  • Encryption methods now use PBKDF2 to derive keys and initialisation vectors for encryption. This means your keys can now be any length, as they will be converted to a correct length in a secure manner before encryption.

    Uses 65536 rounds of PBKDF2.


  • Removed PBKDF2 method from ESLSecurity
  • Removed PasswordCrackTime method from ESLSecurity
  • Removed ESLCompute class




Thanks to Liam and the community for all your hard work on this great extension!

Have you used it? What do you think?

   - Ninja Ed

Comments (4)

  1. I updated this with the 0.4.1a patch link and info from Liam's forum thread:…/b8b5f9d8-4936-4666-941d-71de10617666

  2. 3/5/16 UPDATE: Added the 0.4.2a patch and 0.4.3a patch link and info.

  3. Avdiel says:

    The three download sites do not exist as of 9.16.2017. I would like to keep this extension update in my SB lib as I use it in my programs. Suggestions?

Skip to main content