From the blog

What Makes Firmware Vulnerabilities So Deadly?

Published October 20, 2020 WRITTEN BY ED TITTEL Ed Tittel is a long-time IT industry writer and consultant who specializes in matters of networking, security, and Web technologies. For a copy of his resume, a list of publications, his personal blog, and more, please visit www.edtittel.com or follow @EdTittel Simply put, firmware is low-level software usually stored in a near-silicon form (ROM, EEPROM, or flash memory) that is used during the initial steps of bootstrapping and starting up a computer, printer, or some other kind of electronic device. Alternatively, firmware may serve to drive device-level communications with other components in a computer or other electronic device. Well-known instances of firmware include BIOS, UEFI, codes in audio devices or components, and so forth. Where there’s firmware, there’s often microcode as well… According to an ancient (1967) Datamation article firmware also describes a writable control store (a specialized limited set of high-speed memory locations) that contained so-called “microcode” to define and implement a computer’s instruction set. This is what drives instructions that CPUs can execute, and can be reloaded to update, specialize or modify the current instruction set. Firmware thus sits between hardware (the registers, processing units, busses, and so forth) and binary code (software instructions that have been translated into machine instructions for step-by-step execution). This is often called microcode and basically provides the irreducible elements in a CPU (or other processor) that supports individual machine instructions. Because firmware sits between hardware and software and is neither of those things, it’s long been called firmware. These two early and well-publicized microcode vulnerabilities appeared in 2017/2018 Because microcode may be updated or modified, it can also be attacked Over the past 4-5 years, for example, Intel processors have shown themselves susceptible to numerous, colorfully named microcode attacks. Two early instances of such attacks include Meltdown, aka Rogue Data Cache Load, identified as CVE-2017-5754; and Spectre, identified as CVE-2017-5715. Meltdown, if foisted, can sever the isolation normally maintained between user applications and the OS, allowing programs to ransack all memory on a compromised device. Spectre is similar, but enables attackers to force normally secure, error-free applications into leaking memory contents (secrets) to other applications. Thus, a malicious application could then “sniff” memory from normally secure code without throwing errors or other means of detection. There are many more such vulnerabilities now known in the wild. As recently as September 1, 2020, Intel published a Microcode update for a broad range of its processors that covered 4 additional microcode vulnerabilities, to wit: CVE-2019-11091 – Microarchitectural Data Sampling Uncacheable Memory (MDSUM) CVE-2018-12126 – Microarchitectural Store Buffer Data Sampling (MSBDS)? CVE-2018-12127 – Microarchitectural Load Port Data Sampling (MLPDS) CVE-2018-12130 – Microarchitectural Fill Buffer Data Sampling (MFBDS) Where the danger in firmware/microcode vulnerabilities lies Firmware (and microcode) operate at the lowest level within the devices they inhabit. They take up residence before a BIOS or OS starts up, and operate outside their purview and control. If an attacker can foist a firmware or microcode exploit, there’s very little runtime software can do to counter (or even detect) its presence and behaviors. Thus, a successful firmware or microcode exploit usually gives an attacker free rein and unlimited access to a compromised device (though they may also need direct access to that device to foist the exploit, or take advantage of its abilities). […]

Read More

Learn How To Build MVVM Pattern Based App In 20 Minutes

MVVM is a software architectural pattern that facilitates the separation of the development of the graphical user interface via a markup language or GUI code from the development of the business logic or back-end logic so that the view is not dependent on any specific model platform. In this Skill Sprint in 20 minutes, you can learn how to apply this MVVM pattern to your Delphi applications smoothly.  Model-View-ViewModel The MVVM design pattern decouples your application code and separates the concerns of your application. You must care about MVVM because it is the way to write maintainable, testable code. The compelling reason is the ease of maintenance. Utilize MVVM and, your app will never become a legacy application. How can you achieve within Delphi? The answer is separating the software. ViewModel – Present data to the view View – User interface Model – Business logic or back-end Be sure to watch the whole session to learn more about the MVVM pattern and the demo using the Delphi.

Read More

FL Studio Is A Massively Popular Digital Audio Workstation Software Built In Delphi

Image-Line Software is the Belgian based creator of FL Studio, one of the most popular Digital Audio Workstations (DAWs) available on the market for creating music. FL Studio is installed more than 30,000 times per day (more than 10 million installations a year) by users in more than 200 countries, including power users such as Avicii, Martin Garrix, Afrojack, and Mike Oldfield. “Delphi is very important for us as a development tool because it allows us to do inline assembly and link function to the code directly. With classic development tools, that process is much clumsier. However with Delphi you can just add a button and double click; it speeds up coding and allows us to work in the language we know best.” – Jean-Marie Cannie, CTO and Founder Case Study https://www.embarcadero.com/case-study/image-line-software-case-study Download https://www.image-line.com/ Screenshot Gallery

Read More

Build Modern Delphi/C++ Builder Web Applications Using IntraWeb Framework and IWBootStrap

Thinking to write a new web application or modernize your existing application into web framework for Delphi/C++ Builder Framework? AToZed Softwares provides an Amazing FullStack/ClientServer Focused Web Framework to build applications faster. Installs into IDE, Modeled on VCL, Visual Client Designer. The client built from the JS and HTML library. Delphi UI event handlers run on servers, extensible via typescript. Features: Development paradigm is very close to Desktop applications. IntraWeb 14 is free for 10.3 Rio users, however you can purchase a license and update to the latest IntraWeb 15 with HTTP.sys support and much more. Ultimate Edition available for more deployment and other options. Easy to Get Started with powerful components. Flexible to create as ISAPI dll, Windows Service or Standalone application. How to build a sample IntraWeb Application in Delphi. File->NewItems->IntraWebFolder->IntraWeb Application Wizard->Choose ApplicationType as Standalone Application. The Standalone Application Server is a web application that includes, an embedded web server, the IntraWeb core code and your code. When you are developing your application, simply running the SA Server and typing http://127.0.0.1:8888/$/start on your browser is enough for running your application. http://127.0.0.1 stands for the local host, 8888 is the port the embedded web server is listening to (check TIWServerControllerBase for learning about the Port property) and /$/start is the IntraWeb command that forces the start of a new user session. Create a Main Form Drag and Drop the IntraWeb components such as IWButton, IWList, IWEdit for Client Side implementations. Run the Application-> Standalone application dialog is open with multiple Browser options for debugging purpose. Open with Chrome or Firefox browser. Test the Main Form with some logic built in the Client side implementations. In the background the standalone server side application generates the HTML.CSS,JavaScript and shown in a browser for your Delphi IntraWeb Client App. To Deploy follow the steps here You can deploy the created application in IIS server or run as windows service or ISAPI application. You can grab your Free Bundled edition Key here To modernize your Intra Web Delphi Client App with more stunning styles and templates use IWBootstrapFramework. An open source Bootstrap wrapper framework for IntraWeb. The same way you use for create traditional Intraweb Aplications, you can use. With very little effort you can create a single applications that look awesome in mobile devices and desktop at the same time. It’s light and fast so it provides a great experience for the end user in any device. Check this below Video for the Demonstration for IntraWeb and IWBootstrapFramework. With Some Excellent Features a good Road Map is planned for the IntraWeb and its Coming Soon. Please check the what the updates are in the below Video. For other products and updates about IntraWeb check here

Read More

Learn About Executing Local SQL Queries Within Your Delphi Apps Using FireDAC

The FireDAC.TFDLocalSQL MegaFMX sample is divided in three tabs where each tab demonstrates single Local SQL usage case. Each tab has dedicated SQLite in-memory connection established using the TFDConnection with only single parameter DriverID=SQLite. When no Database parameter value is specified then FireDAC SQLite driver opens an in-memory connection. It will be used as a Local SQL engine. The TFDLocalSQL component for each page serves as a hub to Local SQL engine, allowing to register datasets with the Local SQL engine. Also there is a TMemo where the Local SQL query is defined before executing it using a TFDQuery component. The TFDLocalSQL.Connection and TFDQuery.Connection properties are set to the same SQLite in-memory TFDConnection. Visual components such as the TGrid and the TBindNavigator are bind to the TFDQuery using Live Bindings. Location You can find the MegaFMX sample project at: Start | Programs | Embarcadero RAD Studio Sydney | Samples and then navigate to: Object PascalDataBaseFireDACSamplesComp LayerTFDLocalSQLMegaFMX. Subversion Repository: You can find Delphi code samples in GitHub Repositories. Search by name into the samples repositories according to your RAD Studio version. How to Use the Sample Navigate to the location given above and open: Press F9 or choose Run > Run. Move to the different tabs. Click Open to open the connection and see the content on the grid. Note: You can navigate through the records with the TDBNavigators. Implementation The sample is divided in tabs. The TFDMemTables are defined and filled with data by code. CSV DB (dyna) The first page represents the Comma-Separated Values (CSV) text file database with SQL query capabilities. The text files are stored in C:UsersPublicDocumentsEmbarcaderoStudio15.0SamplesObject PascalDatabaseFireDACDBData folder. The FDConnection1 provides SQLite in-memory connection. For that DriverName property is set to SQLite. The FDLocalSQL1.Connection and the FDQuery1.Connection are set to the FDConnection1. Clicking Open, inserts the lines of the Memo1 on the FDQuery1 and executes the Local SQL query: procedure TfrmMain.Button1Click(Sender: TObject); begin FDQuery1.Close; FDQuery1.SQL := Memo1.Lines; FDQuery1.Open; end; procedure TfrmMain.Button1Click(Sender: TObject); begin   FDQuery1.Close;   FDQuery1.SQL := Memo1.Lines;   FDQuery1.Open; end; Is shows the result on the Grid1 grid. Heterogeneous Query (dyna) The second page represents the ability to perform a heterogeneous SQL query, where several joined tables are prefixed by a schema name. There a schema name corresponds to a FireDAC connection definition name. The connection definitions are stored in the C:UsersPublicDocumentsEmbarcaderoStudioFireDACFDConnectionsDefs.ini file. So, the tables with different schema names will be obtained from the different (heterogeneous) database connections. The basic setup is similar to first page. Each schema name is handled by a dedicated TFDLocalSQL component. For that the property TFDLocalSQL.SchemaName is used: FDLocalSQL2 = SQLite_Demo FDLocalSQL3 = Access_Demo. The FDLocalSQL2 and FDLocalSQL3 OnGetDataSet event handlers are used to dynamically resolve a reference to an unknown table name and to provide a dataset with the data. For that event handler creates TFDQuery component and sets it ConnectionName to the schema name and SQL property to select * from table query: procedure TfrmMain.FDLocalSQL2GetDataSet(ASender: TObject; const ASchemaName, AName: String; var ADataSet: TDataSet; var AOwned: Boolean); var oQry: TFDQuery; begin oQry := TFDQuery.Create(nil); try oQry.Name := AName; oQry.ConnectionName := ASchemaName; oQry.SQL.Text := ‘select * from ‘ + AName; oQry.Open; except oQry.Free; raise; end; ADataSet := oQry; AOwned := True; end; 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 procedure TfrmMain.FDLocalSQL2GetDataSet(ASender: TObject; const ASchemaName,   AName: String; var ADataSet: TDataSet; var AOwned: Boolean); var   oQry: TFDQuery; begin   oQry := TFDQuery.Create(nil);   try     oQry.Name := AName;     oQry.ConnectionName := ASchemaName;     oQry.SQL.Text := ‘select * from ‘ + AName;     oQry.Open;   except     oQry.Free;     raise;   end;   ADataSet := oQry;   AOwned := True; end; Clicking Open, inserts the lines of the Memo2 on the FDQuery2 and executes […]

Read More

Learn How To Build Responsive Apps Faster Using Delphi Parallel Programming Library

Building Responsive Apps becomes the most essential need for all Modern Desktop, Mobile and Web applications in all platforms to meet the customer needs. Do you want to wow your customers with greater experience for your Delphi/C++ Builder Applications ? Don’t know how to create responsive apps with Parallel Programming Library ? Don’t Worry! This post will guide you to learn about PPL. Task: A Task is like a parallel procedure. A Task runs parallel to the main thread. Tasks do no start right away, they are held in a queue and it is managed by a Master thread which allocates thread from a thread pool. It works like Master-Worker pattern with a Thread pool. Thread Pool has a number of threads. Based on CPU the threads are avialable and start when CPU time is available.Tasks run best without serializing dependencies. Check the tutorial for Task here Future: Future is like a parallel function. A future is actually a task with return result you wait for it (unless the Future gets completed) . The future method returns an instance of IFuture into the variable defined of type T. Check the tutorial for Future here. Tasks Chaining: Task can be chained together, e.g) Tasks can wait for results from other tasks. This uses TTask.Wait like how TFuture does. WaitForAll task in a list, or WaitForAnyone to complete. Parallel For : A Parallel.For Splits a for loop into pieces that run in parallel. It runs through data in parallel( data parallelism) and waits for completion. Use task if you don’t want to wait in thread. Parallel.For uses Task. Tutorial for Paralle.For here Create Responsive Apps : A Responsive Application never blocks the user interface while processing the data in background and it never waits. Immediate feedback and responsive gives user the great experience. Perceived speed is not equals to actual speed get data and run operations in parallel. Check this Video for the Delphi Parallel Programming Library to create responsive Apps: Get to know about the PPL which Delphi/C++ Builder offers. Want to know more about Task Monitoring, Locking, Pools, Patterns and more? See below video.

Read More

Learn How To Create A Custom List View Adapter With A Python Server In This Sample For Delphi

Location You can find the CustomAdapter sample project at: Start | Programs | Embarcadero RAD Studio Sydney | Samples and navigate to: Object PascalMulti-Device SamplesUser InterfaceListViewCustomAdapter Subversion Repository: You can find Delphi code samples in GitHub Repositories. Search by name into the samples repositories according to your RAD Studio version. Description The CustomAdapter sample shows how to create a custom list view adapter. This specific implementation of a custom adapter obtains image files from a remote server. How to Run the Sample Run the server: Install Python 2 to run the server script. On the project folder, open server.py using a text editor, and update the values of the HOST and PORT variables. Notes: The default values should let you test this sample application on your development PC. To run this sample application on a mobile device, you must update HOST so that it contains the IP address where your mobile devices can reach your development PC. If the default post is busy in your development PC, you must change the value of PORT. Run server.py. Run the sample application: Open the sample application project file. Open the main form of the sample application in the Code Editor and update the value of the Host constant, so that the host and port match those that you configured on the server script. Run the sample application. How It Works After you start this sample application, it displays the following form: Click the Load Pictured button to load 30 list view items from the custom list view adapter. Please follow the link below for more information to the original post: http://docwiki.embarcadero.com/CodeExamples/Sydney/en/FMX.ListViewCustomAdapter

Read More

Quickly Build A Web Front End Using Delphi/C++ Builder With No Front End Web Technologies Knowledge

Surprised with the Title? Yes without knowledge of HTML, CSS, JavaScriptyou can build from Delphi/C++Builder your Web Front end using some of the Client/Server(FullStack) or Client-Focused third party web frameworks. Curious to know how these frameworks do this? This post will help you to understand. What does a web front end framework does exactly: Visual Layout Designed in IDE to render in the browser with HTML, JavaScript & CSS. Using Delphi or other visual designers to create a visual layout. No need to know HTML, CSS, or javascript, may allow customization through HTML, CSS, and JavaScript. No special client plugins required. Some create both server and client-side functionality. Some use pascal to Javascript Transpilers. Transpilers : Transcompiler(translating compiler) or source to source compiler Converts or Translates one programming language to another one. Usually, only a sunset or special dialect of the source language is supported. Platform-specific libraries not supported. Frequently used to convert high level, type-safe, languages into javascript. Examples: Typescript or CoffeeScript transpilers. Some of the Pascal to JavaScript Compilers listed Below : Commercial: OpenSource: C++ to Javascript ; Based on LLVM , Open Source, Compiles C++ to JavaScript. Visual Design Front End Frameworks : AtoZed Software’s IntraWeb: Runs into IDE creating both front end and backed end, Modeled on VCL, Visual Client Designer. The client built from the JS and HTML library. Delphi UI event handlers run on servers, extensible via typescript. Supported by Third Party like TMS Software. Thinfinity Virtual UI By CybeleSoft: Transforms you desktop application into a web application. Includes Javascript Remote Object (jsRO) framework. Full HTML 5 cross-browser client. Server redirects GDI/GDI+ calls to Javascript client. FMSoft UniGui: Installs into Delphi IDE, VCL like design and use. Provides data-aware controls, supports desktop and mobile. Allows optional javascript for client-side events and VCL like server event handlers. SMS (Emphasis on Node.js and cloud-based development) and Elevate Web Builder ( Emphasis on data-driven development) uses Delphi like IDE to design the UI and an Object Pascal to JavaScript transpiler to Create HTML, CSS, Javascript. Watch the video for Overview of web frameworks and some of the front end framework Demonstration. To know more about the list of available frameworks for Delphi have a look on this post.

Read More

High-Performance Remote Cloud Logger For Cross-Platform Delphi/C++Builder Application

Developing Cross-Platform Multi-device Application is made easy with Delphi/C++ Builder. It’s a challenging task to diagnose run-time issues with our application running on various platforms. That too to examine the run time state of our application running on iOS and Android devices are very difficult using the debugger or mobile platform-specific logging. Not to worry. GrijjyCloudLogger solves these challenges and provides remote logging features for Windows, iOS,macOS, Android. GrijjyCloudLogger – Allows you to send log messages over the Intranet or Internet from Windows, Linux, iOS, Android, and macOS devices to a viewer running on Windows. Provides a unified, run-time debug related capabilities like memory and object tracking from these respective platforms. Features: Custom live watches, remote live views of objects, tracking live memory usage, object allocations, growth leaks, and more. Built upon our ZeroMQ Majordomo implementation that allows you to create powerful, lightweight, distributed applications that can route messages over any network, including the Internet.It is extremely fast over the network and can handle numerous connected developers simultaneously. It also uses our Google Protocol Buffers implementation that allows us to encapsulate extensible and arbitrary data and transport the data using efficient payloads. How to use GrijjyCloudLogger : Go to Tools menu in Your IDE-> Getit Package Manager and Type Grijjy and install, it will install all Modules and samples. After installation, Two Icons in Desktop, GrijjyLogBroker, GrijjyLogViewer – includes examples for the console, fire monkey. GrijjyLogBroker: Routes log messages between senders and viewers. By default, the Broker is configured to listen on tcp://localhost:7337. When you use Grijjy.CloudLogging it in your project you need to call the GrijjyLog.Connect() method and provide the address of the Broker. GrijjyLogViewer: The GrijjyLogViewer displays messages that are sent from your app. The Service name in the Connection Settings of the GrijjyLogViewer should match the same Service name you provided to the Grijjy.CloudLogger when calling the Connect() method. Using this technique, all developers in your organization can share the same GrijjyLogBroker. 3. Navigate to the ExampleLogClient.FMX under GrijjyLogViewer samples folder and run the application. Mention the Broker URL and Service Name and send different data that can be viewed in your GrijjyLogViewer. Check the video for GrijjyCloudLogger demonstration here.

Read More

Learn About Powerful WebSockets Solutions For Delphi

The WebSocket is a communication protocol, that makes it possible to open a two-way interactive communication session between the user’s browser and a server. With this, you can send messages to a server and receive event-driven responses without having to poll the server for a reply. Applications that require Real-time data streaming, Synchronization uses WebSocket primarily. Most browsers support the protocol, including Google Chrome, Microsoft Edge, Internet Explorer, Firefox, Safari, and Opera. The WebSocket protocol specification defines ws (WebSocket) and wss (WebSocket Secure) as two new uniform resource identifier (URI) schemes that are used for unencrypted and encrypted connections, respectively. Web Socket Server: A WebSocket server is nothing more than an application listening on any port of a TCP server that follows a specific protocol. The task of creating a custom server tends to scare people; however, it can be straightforward to implement a simple WebSocket server on your platform of choice. In Delphi, we can create our own server directly inheriting from Indy TIdCustomTCPServer. WebSocket servers are often separate and specialized servers (for load-balancing or other practical reasons), so you will often use a reverse proxy (such as a regular HTTP server) to detect WebSocket handshakes, pre-process them, and send those clients to a real WebSocket server. Web Socket Handshake: The server must listen for incoming socket connections using a standard TCP socket. Depending on your platform, this may be handled for you automatically. For example, let’s assume that your server is listening on example.com, port 8000, and your socket server responds to GET requests at example.com/chat. Client HandShake: Even though you’re building a server, a client still has to start the WebSocket handshake process by contacting the server and requesting a WebSocket connection. So, you must know how to interpret the client’s request. The client will send a pretty standard HTTP request with headers that looks like this (the HTTP version must be 1.1 or greater, and the method must be GET): GET /chat HTTP/1.1 Host: example.com:8000 Upgrade: websocket Connection: Upgrade Sec-WebSocket-Key: dGhlIHNhbXBsZSBub25jZQ== Sec-WebSocket-Version: 13 GET /chat HTTP/1.1 Host: example.com:8000 strong>Upgrade: websocket/strong> strong>Connection: Upgrade/strong> Sec–WebSocket–Key: dGhlIHNhbXBsZSBub25jZQ== Sec–WebSocket–Version: 13 When the server receives the handshake request, it should send back a special response that indicates that the protocol will be changing from HTTP to WebSocket. That header looks something like the following (remember each header line ends with rn and put an extra rn after the last one to indicate the end of the header): HTTP/1.1 101 Switching Protocols Upgrade: websocket Connection: Upgrade Sec-WebSocket-Accept: s3pPLMBiTxaQ9kYGzzhZRbK+xOo= strong>HTTP/1.1 101 Switching Protocols/strong> Upgrade: websocket Connection: Upgrade strong>Sec–WebSocket–Accept: s3pPLMBiTxaQ9kYGzzhZRbK+xOo= /strong> Exchanging Data formats : Message is Exchanged in certain formats Between client and server called “Frames”. For more information check here. Existing Solutions Available : Check the video for creating web sockets server and client implementation in Delphi below. WebSocket And Delphi

Read More