Java 2 Ada - Tag release2023-08-20T14:14:31+00:00Stephane Carrezurn:md5:d12e23c53b2436d6becce3d51ddbdf38AWAAda BFD 1.3.0urn:md5:0f5fbfe07c452321316d3dea42e681502023-08-20T14:14:31+00:002023-08-20T14:14:31+00:00Stephane CarrezreleaseELFCOFFbinutilsAda
<div class="post-text"><h5>[Ada/ada-bfd-1.3.jpg](Ada/ada-bfd-1.3.jpg)</h5><ol><li><ol><li>Integration with Alire</li></ol></li></ol><p>For Linux users only, the <a href="Ada BFD">Ada BFD</a>(https://github.com/stcarrez/ada-bfd) has an associated Alire crate which allows you to use it easily. To get access to the Alire crate, you should add the <a href="AWA Alire index">AWA Alire index</a>(https://github.com/stcarrez/awa-alire-index) in your Alire configuration as follows:</p><p>``` alr index <del>add=https://github.com/stcarrez/awa-alire-index.git </del>name awa ```</p><p>Then, you can get access to the crate by using</p><p>``` alr with bfdada ```</p><p>Let's see how to use this library...</p><ol><li><ol><li>Declarations</li></ol></li></ol><p>The <a href="Ada BFD">Ada BFD</a>(https://github.com/stcarrez/ada-bfd) library provides a set of Ada bindings that give access to the BFD library. A binary file such as an object file, an executable or an archive is represented by the `Bfd.Files.File_Type` limited type. The symbol table is represented by the `Bfd.Symbols.Symbol_Table` limited type. These two types hold internal data used and managed by the BFD library.</p><p>```<a href="ada">ada</a> with Bfd.Files; with Bfd.Sections; with Bfd.Symbols; ...</p><pre><code> File : Bfd.Files.File_Type;
Symbols : Bfd.Symbols.Symbol_Table;
</code></pre><p>```</p><ol><li><ol><li>Opening the BFD file</li></ol></li></ol><p>The first step is to use the `Open` procedure to read the object or executable file whose path is given as argument. The `File_Type` parameter will be initialized to get access to the binary file information. The `Check_Format` function must then be called to let the BFD library gather the file format information and verify that it is an object file or an executable.</p><p>```<a href="ada">ada</a> Bfd.Files.Open (File, Path, ""); if Bfd.Files.Check_Format (File, Bfd.Files.OBJECT) then</p><pre><code> ...
</code></pre><p>end if; ```</p><p>The `File_Type` uses finalization so that it will close and reclaim resources automatically.</p><ol><li><ol><li>Loading the symbol table</li></ol></li></ol><p>The symbol table is loaded by using the `Read_Symbols` procedure.</p><p>```<a href="ada">ada</a></p><pre><code> Bfd.Symbols.Read_Symbols (File, Symbols);
</code></pre><p>```</p><p>The resources used by the symbol table will be freed when the symbol table instance is finalized.</p><ol><li><ol><li>Find nearest line</li></ol></li></ol><p>Once the symbol table is loaded, we can use the `Find_Nearest_Line` function to find the nearest line of a function knowing some address. This is almost a part of that function that the <a href="addr2line (1)">addr2line (1)</a>(https://www.man7.org/linux/man-pages/man1/addr2line.1.html) command is using.</p><p>```<a href="ada">ada</a> File_Name, Func_Name : Ada.Strings.Unbounded.Unbounded_String; Text_Section : Bfd.Sections.Section; Line : Natural; Pc : constant Bfd.Vma_Type := ...; ...</p><pre><code> Text_Section := Bfd.Sections.Find_Section (File, ".text");
Bfd.Symbols.Find_Nearest_Line (File => File,
Sec => Text_Section,
Symbols => Symbols,
Addr => Pc,
Name => File_Name,
Func => Func_Name,
Line => Line);
</code></pre><p>```</p><p>One tricky aspect of using `Find_Nearest_Line` is the fact that the address we are giving must **sometimes** be converted to an offset within the text region. With <a href="Address space layout randomization (ASLR)">Address space layout randomization (ASLR)</a>(https://en.wikipedia.org/wiki/Address_space_layout_randomization) a program is mapped at a random address when it executes. Before calling `Find_Nearest_Line`, we must subtract the base address of the memory region. We must now find the virtual address of the start of the text region that is mapped in memory. While the program is running, you can find the base address of the program by looking at the `/proc/self/maps` file. This special file indicates the list of memory regions used by the process with the addresses, flags and other information. Without ASLR, the program is almost always loaded at the `0x00400000` address.</p><p>``` 00400000-007f9000 r-xp 00000000 fd:01 12067645 /home/... 009f8000-009fa000 r--p 003f8000 fd:01 12067645 /home/... 009fa000-00a01000 rw-p 003fa000 fd:01 12067645 /home/... ```</p><p>But when it is mapped at a random address, we get a different address each time the program is launched:</p><p>``` 55d5983d9000-55d598592000 r--p 00000000 fc:02 1573554 /... 55d598592000-55d599376000 r-xp 001b9000 fc:02 1573554 /... 55d599376000-55d5997ed000 r--p 00f9d000 fc:02 1573554 /... 55d5997ee000-55d5998bb000 r--p 01414000 fc:02 1573554 /... 55d5998bb000-55d5998c6000 rw-p 014e1000 fc:02 1573554 /... ```</p><p>In that case, the value to use it the first address of first `r--p` region associated with the program (here `0x55d5983d9000`).</p><p>Another method to know the virtual base address is to use the <a href="dl_iterate_phdr (3)">dl_iterate_phdr (3)</a>(https://man7.org/linux/man-pages/man3/dl_iterate_phdr.3.html) function and look at the shared objects which are loaded. This function must be executed by the program itself: it gets as parameter a callback function which is called for each loaded shared object and a data parameter that will be passed to the callback.</p><p>```</p><ol><li>include <dlfcn.h></li></ol><p>static int dl_callback (struct dl_phdr_info* info, size_t size, void* data) {</p><pre><code> /* VM base address is: info->dlpi_addr */
return 0;
</code></pre><p>} ...</p><pre><code> dl_iterate_phdr (dl_callback, 0);
</code></pre><p>```</p><p>When the callback is called, you can get the name of the shared object by looking at `info->dlpi_name` and the virtual base address by looking at `info->dlpi_addr`.</p><p><a href="Ada BFD">Ada BFD</a>(https://github.com/stcarrez/ada-bfd) is a very specific library that is not always easy to use due to the complexity of binary program representation (ELF, DWARF, ...) and program execution. It is however used in very specific contexts such as the <a href="Muen Separation Kernel">Muen Separation Kernel</a>(https://muen.codelabs.ch/) and the <a href="Memory Analysis Tool">Memory Analysis Tool</a>(https://github.com/stcarrez/mat).</p></div> Reentrant scanner and parser with Aflex and Ayaccurn:md5:549bf23cdcd37b17183eaafe7543f19c2023-05-14T19:02:00+00:002023-05-14T19:02:00+00:00Stephane CarrezAdalexyaccreleasegeneratorbison
<div class="post-text"><h5>[Aflex and Ayacc](Ada/Aflex-Ayacc-code.jpg)</h5><ol><li><ol><li>What's new in Aflex 1.6</li></ol></li></ol><p>- Support the flex options `%option output`, `%option nooutput`, `%option yywrap`, `%option noinput`,</p><pre><code> `%option noyywrap`, `%option unput`, `%option nounput`, `%option bufsize=NNN` to better control the
generated `_IO` package.
</code></pre>- <a href="Aflex">Aflex</a>(https://github.com/Ada-France/aflex) templates provide more control for tuning the code generation and<pre><code> they are embedded with [Advanced Resource Embedder](https://gitlab.com/stcarrez/resource-embedder)
</code></pre>- Support to define Ada code block in the scanner that is inserted in the generated scanner - New option -P to generate a private Ada package for DFA and IO - New directive `%option reentrant` and `%yyvar` to generate a recursive scanner - New directive `%yydecl` to allow passing parameters to `YYLex`<pre><code> or change the default function name
</code></pre><p>Example of `%option` directives to tell <a href="Aflex">Aflex</a>(https://github.com/Ada-France/aflex) to avoid generating several function or procedures and customize the buffer size.</p><p>```<a href="Ada">Ada</a> %option nounput %option noinput %option nooutput %option noyywrap %option bufsize=1024 ```</p><p>The tool supports some code block injection at various places in the generated scanner. The code block has the following syntax where `<block-name>` is the name of the code block:</p><p>```<a href="Ada">Ada</a> %<block-name> {</p><pre><code> -- Put Ada code here
</code></pre><p>} ```</p><p>The `%yytype` code block can contain type declaration, function and procedure declarations. It is injected within the `YYLex` function in the declaration part. The `%yyinit` code block can contain statements that are executed at beginning of the `YYLex` function. The `%yyaction` code block can contain statements that are executed before running any action. The `%yywrap` code block can contain statements which are executed when the end of current file is reached to start parsing a next input.</p><ol><li><ol><li>What's new in Ayacc 1.4</li></ol></li></ol><p>- Support the Bison `%define variable value` option to configure the parser generator - Support the Bison `%code name { ... }` directive to insert code verbatim into the output parser - Recognize some Bison variables `api.pure`, `api.private`, `parse.error`, `parse.stacksize`,</p><pre><code> `parse.name`, `parse.params`, `parse.yyclearin`, `parse.yyerrok`, `parse.error`
</code></pre>- New option `-S skeleton` to allow using an external skeleton file for the parser generator - <a href="Ayacc">Ayacc</a>(https://github.com/Ada-France/ayacc) templates provide more control for tuning the code generation and<pre><code> they are embedded with [Advanced Resource Embedder](https://gitlab.com/stcarrez/resource-embedder)
</code></pre>- New option `-P` to generate a private Ada package for the tokens package - Improvement to allow passing parameters to `YYParse` for the grammar rules - New `%lex` directive to control the call of `YYLex` function - Fix #6: ayacc gets stuck creating an infinitely large file after encountering a comment in an action<p>The generator supports two code block injections, the first one `decl` is injected in the `YYParse` procedure declaration and the `init` is injected as first statements to be executed only once when the procedure is called. The syntax is borrowed from the Bison parser:</p><p>```<a href="Ada">Ada</a> %code decl {</p><pre><code> -- Put Ada declarations
</code></pre><p>} %code init {</p><pre><code> -- Put Ada statements
</code></pre><p>} ```</p><p>Some other Bison like improvements have been introduced to control the generation of the parser code.</p><p>``` %define parse.error true %define parse.stacksize 256 %define parse.yyclearin false %define parse.yyerrok false %define parse.name MyParser ```</p><ol><li><ol><li>How to use</li></ol></li></ol><p>The easiest way to use <a href="Ayacc">Ayacc</a>(https://github.com/Ada-France/ayacc) and <a href="Aflex">Aflex</a>(https://github.com/Ada-France/aflex) is to use <a href="Alire">Alire</a>(https://github.com/alire-project/alire), get the sources, build them and install them. You can do this as follows:</p><p>``` alr get aflex cd aflex_1.6.0_b3c21d99 alr build alr install alr get ayacc cd ayacc_1.4.0_c06f997f alr build alr install ```</p><ul><li>UPDATE*: the `alr install` command is available only with <a href="Alire">Alire</a>(https://github.com/alire-project/alire) 2.0.</li></ul><p>Using these tools is done in two steps:</p><p>1. a first step to call `aflex` or `ayacc` command with the scanner file or grammar file, 2. a second step to call `gnatchop` to split the generated file in separate Ada files</p><p>For example, with a `calc_lex.l` scanner file, you would use:</p><p>``` aflex calc_lex.l gnatchop -w calc_lex.ada ```</p><p>And with a `calc.y` grammar file:</p><p>``` ayacc calc.y gnatchop -w calc.ada ```</p><p>To know more about how to write a scanner file or grammar file, have a look at <a href="Aflex 1.5 and Ayacc 1.3.0">Aflex 1.5 and Ayacc 1.3.0</a>(https://blog.vacs.fr/vacs/blogs/post.html?post=2021/12/18/Aflex-1.5-and-Ayacc-1.3.0) which explains more into details some of these aspects.</p><ol><li><ol><li>Highlight on reentrancy</li></ol></li></ol><p>By default <a href="Aflex">Aflex</a>(https://github.com/Ada-France/aflex) and <a href="Ayacc">Ayacc</a>(https://github.com/Ada-France/ayacc) generate a scanner and a parser which use global variables declared in a generated Ada package. These global variables contain some state about the scanner such as the current file being scanned. The <a href="Ayacc">Ayacc</a>(https://github.com/Ada-France/ayacc) parser generates on its side two global variables `YYLVal` and `YYVal`.</p><p>Using global variables creates some strong restrictions when using the generated scanner and parser: we can scan and parse only one file at a time. It cannot be used in a multi-thread environment unless the scan and parse is protected from concurrent access. We cannot use easily some grammars that need to recurse and parse another file such as an included file.</p><ol><li><ol><li><ol><li>Reentrant scanner</li></ol></li></ol></li></ol><p>The reentrant scanner is created by using the `-R` option or the `%option reentrant` directive. The scanner will then need a specific declaration with a context parameter that will hold the scanner state and variables. The context parameter has its type generated in the `Lexer_IO` package. The `%yydecl` directive in the scanner file must be used to declare the `YYLex` function with its parameters. By default the name of the context variable is `Context` but you can decide to customize and change it to another name by using the `%yyvar` directive.</p><p>``` %option reentrant %yyvar Context %yydecl function YYLex (Context : in out Lexer_IO.Context_Type) return Token ```</p><p>When the `reentrant` option is activated, <a href="Aflex">Aflex</a>(https://github.com/Ada-France/aflex) will generate a first `Context_Type` limited type in the `Lexer_DFA` package and another one in the `Lexer_IO` package. The generator can probably be improved in the future to provide a single package with a single type declaration. The `Lexer_DFA` package contains the internal data structures for the scanner to maintain its state and the `Lexer_IO` package holds the input file as well as the `YYLVal` and `YYVal` values.</p><ol><li><ol><li><ol><li>Reentrant parser</li></ol></li></ol></li></ol><p>On its side, <a href="Ayacc">Ayacc</a>(https://github.com/Ada-France/ayacc) uses the `YYLVal` and `YYVal` variables. By default, it generates them in the `_tokens` package that contains the list of parser symbols. It must not generate them and it must now use the scanner `Context_Type` to hold them as well as the scanner internal state. The setup requires several steps:</p><p>1. The reentrant parser is activated by using the `%define api.pure`</p><pre><code> directive similar to the [bison %define](https://www.gnu.org/software/bison/manual/html_node/_0025define-Summary.html).
</code></pre><p>2. The `%lex` directive must be used to define how the `YYLex` function must be called since it now has some</p><pre><code> context parameter.
</code></pre><p>3. The scanner context variable must be declared somewhere, either as parameter to the `YYParse`</p><pre><code> procedure or as a local variable to `YYParse`. This is done using the new `%code decl` directive
and allows to customize the local declaration part of the `YYParse` generated procedure.
</code></pre><p>4. We must give visibility of the `YYLVal` and `YYVal` values defined in the scanner context variable.</p><pre><code> Again, we can do this within the `%code decl` directive.
</code></pre><p>A simple reentrant parser could be defined by using:</p><p>```<a href="Ada">Ada</a> %define api.pure true %lex YYLex (Scanner) %code decl {</p><pre><code> Scanner : Lexer_IO.Context_Type;
YYLVal : YYSType renames Scanner.YYLVal;
YYVal : YYSType renames Scanner.YYVal;
</code></pre><p>} ```</p><p>However, this simple form is not really useful as you may need to open the file and setup the scanner to read from it. It is probably better to pass the scanner context as parameter to the `YYParse` procedure. For this, we can use the `%define parse.params` directive to control the procedure parameters. The reentrant parser is declared as follows:</p><p>```<a href="Ada">Ada</a> %lex YYLex (Scanner) %define api.pure true %define parse.params "Scanner : in out Lexer_IO.Context_Type" %code decl {</p><pre><code> YYLVal : YYSType renames Scanner.YYLVal;
YYVal : YYSType renames Scanner.YYVal;
</code></pre><p>} ```</p><p>To use the reentrant parser and scanner, we only need to declare the scanner context, open the file by using the `Lexer_IO.Open_Input` procedure and call the `YYParse` procedure as follows:</p><p>```<a href="Ada">Ada</a></p><pre><code> Scanner : Lexer_IO.Context_Type;
...
Lexer_IO.Open_Input (Scanner, "file-to-scan");
YYParse (Scanner);
</code></pre><p>```</p><ol><li><ol><li><ol><li>Grammar examples:</li></ol></li></ol></li></ol><p>To have a more complete example of a reentrant parser, you may have a look at the following files:</p><ul><li><a href="porion-templates-parser-lexer.l">porion-templates-parser-lexer.l</a>(https://gitlab.com/stcarrez/porion/-/blob/master/src/parser/porion-templates-parser-lexer.l)</li><li><a href="porion-templates-parser-parser.y">porion-templates-parser-parser.y</a>(https://gitlab.com/stcarrez/porion/-/blob/master/src/parser/porion-templates-parser-parser.y)</li></ul></div> AWA 2.4.0urn:md5:d54e438ac8145e0e1e6b4ce8524b75272022-08-07T21:12:20+00:002022-08-07T21:12:20+00:00Stephane CarrezAdawebRESTOAuthrelease
<div class="post-text"><p>The framework provides several ready to use and extendable modules that are common to many web applications. This includes the login, authentication, users, permissions, managing comments, tags, votes, documents, images. It provides a complete blog, question and answers and a wiki module.</p><p>AWA simplifies the Web Application development by taking care of user management authentication and by providing the foundations on top of which you can construct your own application. AWA provides a powerful permission management that gives flexibility to applications to grant access and protect your user's resources.</p><p>A typical architecture of an AWA application is represented by the picture below:</p><h5>[Ada Web Application architecture](Ada/awa_architecture_overview.png)</h5><ol><li><ol><li>Using AWA with Alire</li></ol></li></ol><p>To use AWA with Alire, you should first register a new index to get access to the AWA crates and its dependencies.</p><p>``` alr index <del>add git+https://github.com/stcarrez/awa-alire-index </del>name awa ```</p><p>After this command, the `alr` command should give you access to the AWA crates and you can check that with the command:</p><p>``` alr search awa ```</p><p>Once you have setup the Alire index, you can import the `awa` framework and the `dynamo` associated tool by using the following commands:</p><p>``` alr init demo cd demo alr with awa alr with dynamo alr with servletada_aws alr build ```</p><p>Note, if you are using FreeBSD, you should probably use the following command to build (because the MariaDB shared libraries are installed in `/usr/local/lib/mariadb` directory):</p><p>``` alr build -- -largs -L/usr/local/lib/mariadb ```</p><p>Once the `dynamo` tool is built, you can use it to setup your project by using the `create-project` command. To run the `dynamo` tool, you must run it by using the `alr exec` command because Alire will setup some environment variables and `PATH` that gives access to Dynamo and AWA configuration files.</p><p>``` alr exec <del> dynamo create-project -l apache </del>web demo Ada.Lovelace@planet.dev ```</p><p>Change the `demo.gpr` GNAT project that was generated by `alr` and replace `demo.adb` by `demo-server.adb`. That later source has been generated by `dynamo` and it contains everything to setup, prepare and run the Web server. Once this is done, build the application:</p><p>``` alr build ```</p><p>The <a href="Atlas AWA Demonstrator">Atlas AWA Demonstrator</a>(https://github.com/stcarrez/atlas) is also available as Alire crates. Two versions are available, the `atlas` crate is using the Ada Web Server and the `atlas_ews` is using the Embedded Web Server. To play to Atlas, you can try one of the following commands:</p><p>``` alr get atlas</p><ol><li>or</li></ol><p>alr get altas_ews ```</p><ol><li><ol><li>Debian packages</li></ol></li></ol><p>Debian packages are also available for Ubuntu 20, Ubuntu 22 and Debian 11. The repository also includes a Debian package for Alire 1.2. Choose **one** of the following configuration and add it to your `/etc/apt/sources.list` configuration.</p><p>``` deb <a href="https://apt.vacs.fr/ubuntu-focal">https://apt.vacs.fr/ubuntu-focal</a> focal main</p><ol><li>or</li></ol><p>deb <a href="https://apt.vacs.fr/ubuntu-jammy">https://apt.vacs.fr/ubuntu-jammy</a> jammy main</p><ol><li>or</li></ol><p>deb <a href="https://apt.vacs.fr/debian-bullseye">https://apt.vacs.fr/debian-bullseye</a> bullseye main ```</p><p>And you can run the following command to accept the signed packages:</p><p>``` wget -O - <a href="https://apt.vacs.fr/apt.vacs.fr.gpg.key">https://apt.vacs.fr/apt.vacs.fr.gpg.key</a> | sudo apt-key add - ```</p><ol><li><ol><li><ol><li><a href="AWA 2.4.0">AWA 2.4.0</a>(https://github.com/stcarrez/ada-awa/releases/tag/2.4.0) Download: <a href="awa-2.4.0.tar.gz">awa-2.4.0.tar.gz</a>(http://download.vacs.fr/ada-awa/awa-all-2.4.0.tar.gz)</li></ol></li></ol></li></ol><pre><code> - Add support for SQL queries embedded in applications with ARE
- Fix #20: Do not use git:// protocol
- New EasyMDE plugin to integrate the Easy Markdown Editor
- Update AWA blog and AWA wiki to use the EasyMDE editor for Markdown
- Use Dynamo 1.3.0, Ada Server Faces 1.5.0, Ada Servlet 1.6.0, OpenAPI Ada 0.6.0
- Use Ada Wiki 1.4.0, Ada Database Objects 2.3.0
- Use Ada Keystore 1.3.3, Ada EL 1.8.5, Ada Utility Library 2.5.0
</code></pre><ol><li><ol><li><ol><li><a href="Dynamo 1.3.0">Dynamo 1.3.0</a>(https://github.com/stcarrez/dynamo/releases/tag/1.3.0) Download: <a href="dynamo-1.3.0.tar.gz">dynamo-1.3.0.tar.gz</a>(http://download.vacs.fr/dynamo/dynamo-1.3.0.tar.gz)</li></ol></li></ol></li></ol><pre><code> - Fix #5: Generated body does not compile when an enumeration of another UML package is used
- Fix #7: No default type for SQL generation of a column that uses an enumeration
- Fix #9: Option or configuration to disable some SQL generation
- Fix #10: Definition of an UML datatype with a tagged value raises an exception
- Fix #12: Avoid emitting a full qualified type name for types declared in the current package
- Fix #16: Improvement in Markdown documentation generator
- Fix #17: YAML parser: accessibility check failure
- Fix #18: Generate database operation to reload an object
- Fix #19: Add dynamo configuration through environment support
- Fix #20: Give access to the man page from alire
- Fix $21: Generated procedure Create is missing overriding keyword
</code></pre><ol><li><ol><li><ol><li><a href="OpenAPI Ada 0.6.0">OpenAPI Ada 0.6.0</a>(https://github.com/stcarrez/swagger-ada/releases/tag/0.6.0) Download: <a href="openapi-ada-0.6.0.tar.gz">openapi-ada-0.6.0.tar.gz</a>(http://download.vacs.fr/openapi-ada/openapi-ada-0.6.0.tar.gz)</li></ol></li></ol></li></ol><pre><code> - Rename Swagger package into OpenAPI and provide a Swagger package for compatibility
- Update the openapi generator to version 6.0.0
- Add support for text/plain response
- Add support to use external Ada types in OpenAPI definitions
- Add support for multiple response types
- Add support for binary responses
- Add support for Ada enum generation for OpenAPI enums
- Integrate Swagger UI v4.13.0
</code></pre><ol><li><ol><li><ol><li><a href="Ada Server Faces 1.5.0">Ada Server Faces 1.5.0</a>(https://github.com/stcarrez/ada-asf/releases/tag/1.5.0) Download: <a href="ada-asf-1.5.0.tar.gz">ada-asf-1.5.0.tar.gz</a>(http://download.vacs.fr/ada-asf/ada-asf-1.5.0.tar.gz)</li></ol></li></ol></li></ol><p>- New widget <w:progress> to display horizontal/vertical progress bars</p><ol><li><ol><li><ol><li><a href="Ada Servlet 1.6.0">Ada Servlet 1.6.0</a>(https://github.com/stcarrez/ada-servlet/releases/tag/1.6.0) Download: <a href="ada-servlet-1.6.0.tar.gz">ada-servlet-1.6.0.tar.gz</a>(http://download.vacs.fr/ada-servlet/ada-servlet-1.6.0.tar.gz)</li><pre><code> - Fix #4: Alire servletada_aws GNAT project fails due to missing Naming rule
- Fix #5: The Input_Line_Size_Limit parameter is not taken into account
- Fix #6: GNAT configuration project is not correct to build with debugging
- Fix #7: Constraint error raised when matching empty path routes
- Fix #11: Support for Embedded Web Server
- Fix #12: Support for multiple response types in REST operations
</code></pre></ol></li></ol></li></ol><ol><li><ol><li><ol><li><a href="Ada Security 1.4.1">Ada Security 1.4.1</a>(https://github.com/stcarrez/ada-security/releases/tag/1.4.1) Download: <a href="ada-security-1.4.1.tar.gz">ada-security-1.4.1.tar.gz</a>(http://download.vacs.fr/ada-security/ada-security-1.4.1.tar.gz)</li></ol></li></ol></li></ol><pre><code> - Fix Alire GNAT project to build in debug mode
- Fix Security.Random that generates shorter random string
</code></pre><ol><li><ol><li><ol><li><a href="Ada Database Objects 2.3.0">Ada Database Objects 2.3.0</a>(https://github.com/stcarrez/ada-ado/releases/tag/2.3.0) Download: <a href="ada-ado-2.3.0.tar.gz">ada-ado-2.3.0.tar.gz</a>(http://download.vacs.fr/ada-ado/ada-ado-2.3.0.tar.gz)</li></ol></li></ol></li></ol><pre><code> - Fix #4: Is_Loaded predicate operation is false when an object is not yet inserted in the database
- Fix #5: Exception raised when SQLite Query_Statement is finalized if the SQL query was invalid
- Fix #7: Update SQLite support to 3.31.1
- Fix #8: Add SQlite busy handler to handle the SQLITE_BUSY error
- Fix #9: Better handling of SQLITE_BUSY error
- Fix #10: Error 'XML query file does not exist' when the query is loaded from a static embedded loader
</code></pre><ol><li><ol><li><ol><li><a href="Ada Wiki Engine 1.5.0">Ada Wiki Engine 1.5.0</a>(https://github.com/stcarrez/ada-wiki/releases/tag/1.5.0) Download: <a href="ada-wiki-1.5.0.tar.gz">ada-wiki-1.5.0.tar.gz</a>(http://download.vacs.fr/ada-wiki/ada-wiki-1.5.0.tar.gz)</li><pre><code> - Add support for Textile markup language
- Rewrote the Markdown parser to better follow the Common Mark Specification
</code></pre></ol></li></ol></li></ol><ol><li><ol><li><ol><li><a href="Ada Utility Library 2.5.0">Ada Utility Library 2.5.0</a>(https://github.com/stcarrez/ada-util/releases/tag/2.5.0) Download: <a href="ada-util-2.5.0.tar.gz">ada-util-2.5.0.tar.gz</a>(http://download.vacs.fr/ada-util/ada-util-2.5.0.tar.gz)</li></ol></li></ol></li></ol><pre><code> - New examples to illustrate the IO stream composition
- New examples for JSON parser and Util.Beans.Objects
- Add support to set environment variables when launching a process (without changing the current process environment!)
- Add support to indent XML output streams
- New package Util.Files.Rolling to provide a rolling file manager
- New package Util.Beans.Objects.Iterators to easily iterate over objects
- Add a new log appender to support rolling log files with size and time based policies
- New operation Util.Files.Delete_Tree to delete a directory tree and work arround
for GNAT bug gcc/63222 and gcc/56055
- New operation Util.Files.Realpath to find the canonicalized absolute path of a file
- New package Util.Blobs to hold binary content with reference counting
- New package Util.Http.Headers to provide some HTTP helper operations
- Add support for Blob in bean objects
- Fix compilation on NetBSD 9.2
- Fix compilation with AWS >= 22.0
</code></pre></div> Advanced Resource Embedder 1.2.0urn:md5:9d168c833ee907e95a358d21ce9436f82022-01-23T09:04:00+00:002022-01-23T09:04:00+00:00Stephane CarrezAdageneratorCGorelease
<div class="post-text"><h5>[Embedding SQL in binary](Ada/resource-embedder-bin.png)</h5><p>The new release contains the following fixes:</p><p>- Fix Ada generator to be able to use other binary content types</p><pre><code> such as `System.Storage_Elements.Storage_Array`
</code></pre>- Fix Ada generator to escape special characters in strings<p>Since the previous version, Fabien Chouteau asked to be able to use an Ada system type to represent a binary content. This is now possible by using the following XML extract for the description to tell the resource embedder how to integrate the file and generate the Ada source code:</p><p>```XML <package></p><pre><code> <resource name='Resources.Help'
format='binary'
type='access constant System.Storage_Elements.Storage_Array'>
<install mode='copy'>
<fileset dir="help">
<include name="**/*.txt"/>
</fileset>
</install>
</resource>
...
</code></pre><p></package> ```</p><p>With the above description, the Ada code generator produces the following package specification:</p><p>```Ada with System.Storage_Elements; package Resources.Help is</p><pre><code> type Content_Access is access constant System.Storage_Elements.Storage_Array;
type Name_Access is access constant String;
type Name_Array is array (Natural range <>) of Name_Access;
Names : constant Name_Array;
function Get_Content (Name : String)
access constant System.Storage_Elements.Storage_Array;
</code></pre><p>private</p><pre><code> ...
</code></pre><p>end Resources.Help; ```</p><p>This example is available in <a href="Embedding help and documentation in Ada (binary)">Embedding help and documentation in Ada (binary)</a>(https://gitlab.com/stcarrez/resource-embedder/tree/master/examples/ada-help-binary). If you prefer to use `String` instead of a `Storage_Array`, have a look at the <a href="Embedding help and documentation in Ada">Embedding help and documentation in Ada</a>(https://gitlab.com/stcarrez/resource-embedder/tree/master/examples/ada-help). Both examples are similar but they are exposing the file using different Ada types.</p><p>To install the tool, follow the instructions given in the initial announcement: <a href="Advanced Resource Embedder for Ada, C and Go">Advanced Resource Embedder for Ada, C and Go</a>(https://blog.vacs.fr/vacs/blogs/post.html?post=2021/06/11/Advanced-Resource-Embedder).</p><p>If you want to know more about the tool, have a look at its documentation:</p><ul><li><a href="Resource Embedder Guide">Resource Embedder Guide</a>(https://resource-embedder.readthedocs.io/en/latest/) <a href="PDF">PDF</a>(https://gitlab.com/stcarrez/resource-embedder/blob/master/docs/are-book.pdf)</li><li>Man page: <a href="are (1)">are (1)</a>(https://gitlab.com/stcarrez/resource-embedder/blob/master/docs/are.md)</li></ul><p>and if you have ideas for improvements, fork the project and submit a pull request!</p></div> Aflex 1.5 and Ayacc 1.3.0urn:md5:45a1bebacf173ea548b9a06d2555561c2021-12-19T13:03:00+00:002021-12-19T13:03:00+00:00Stephane Carrezreleasegeneratorlexyaccbison
<div class="post-text"><ol><li><ol><li>Aflex Version 1.5.2021</li></ol></li></ol><p>The new release provides the following changes:</p><p>- Fix crash when the scanner file uses characters in range 128..255, - Fixed various compilation warnings, - Use `gprbuild` to build and support `alr`, - Reduced number of style compilation warnings in generated code</p><p>To install Aflex, you can use the <a href="Alire">Alire</a>(https://github.com/alire-project/alire) tool by using:</p><p>```<a href="sh">sh</a></p><pre><code> alr get aflex
cd aflex_1.5.2021_33198b8f
alr build
</code></pre><p>```</p><p>You can also build and install it as easily with the following commands:</p><p>```<a href="sh">sh</a></p><pre><code> git clone https://github.com/Ada-France/aflex.git
cd aflex
make
sudo make install
</code></pre><p>```</p><p>You can also install the following Debian package: <a href="aflex_1.5.2021">aflex_1.5.2021</a>(https://blog.vacs.fr/vacs/debian/ubuntu-focal/aflex_1.5.2021_amd64.html).</p><ol><li><ol><li>Ayacc Version 1.3.0</li></ol></li></ol><p>The Ayacc release provides a little bit more improvements:</p><p>- New option `-C` to disable the generation of `yyclearin` procedure, - New option `-E` to disable the generation of `yyerrok` procedure, - New option `-D` to write the generated files to the directory specified, - New option `-k` to keep the case of grammar symbols, - Fixed various compilation warnings, - Generate constants for shift reduce and goto arrays, - Better strong typing in the generated state tables, - Reduced number of style compilation warnings in generated code</p><p>To install Ayacc with <a href="Alire">Alire</a>(https://github.com/alire-project/alire) tool use:</p><p>```<a href="sh">sh</a></p><pre><code> alr get ayacc
cd ayacc_1.3.0_9b8bf854
alr build
</code></pre><p>```</p><p>You can also build and install it as easily with the following commands:</p><p>```<a href="sh">sh</a></p><pre><code> git clone https://github.com/Ada-France/ayacc.git
cd ayacc
make
sudo make install
</code></pre><p>```</p><p>You can also install the following Debian package: <a href="ayacc_1.3.0">ayacc_1.3.0</a>(https://blog.vacs.fr/vacs/debian/ubuntu-focal/ayacc_1.3.0_amd64.html).</p><ol><li><ol><li>Development with Aflex and Ayacc</li></ol></li></ol><p>Aflex is a tool for generating a scanner that recognizes lexical patterns in text. Ayacc uses a BNF-like specification of a grammar to generate an Ada parser for that grammar. These two tools are tightly coupled together. First the scanner's role is to identify tokens that are used by the grammar file. Second, the parser will use the scanner to ask for tokens as it parses the input content.</p><p>The generated parser provides a main procedure `YYParse` which is the entry point to parse an input content. For this, it calls the `YYLex` function provided by the generated scanner.</p><p>The development model is that you write a scanner file that describes the lexical patterns and the grammar file in the BNF-like specification. Aflex reads the scanner file and generates the scanner. Ayacc reads the grammar file and produces the parser. The scanner and parser are composed of several Ada packages and they are used by each other to exchange some types and operations.</p><h5>[Aflex and Ayacc Development Model](Ada/aflex-ayacc.jpg)</h5><p>Ayacc and Aflex need a number of Ada types for their work and the important types are controlled by the Ayacc grammar. They also share some global variables to hold a token that was parsed or describe the current parser state. The list of possible tokens is generated by Ayacc in the `<Parser>_Tokens` package and represented by the `Token` type.</p><p>```<a href="Ada">Ada</a> package <Parser>_Tokens</p><pre><code> type Token is (T_AND, T_OR, T_STRING, ...);
</code></pre><p>end <Parser>_Tokens; ```</p><p>Aflex will generate the `YYLex` function that returns a `Token` type:</p><p>```<a href="Ada">Ada</a></p><pre><code> function YYLex return <Parser>_Tokens.Token;
</code></pre><p>```</p><p>On its side Ayacc generates the `YYParse` procedure in the generated package body. It is up to you and your grammar to decide whether this procedure must be exported as is or encapsulated to another operation.</p><p>```<a href="Ada">Ada</a></p><pre><code> procedure YYParse;
</code></pre><p>```</p><ol><li><ol><li>Writing a scanner with Aflex</li></ol></li></ol><p>The scanner file describes regular expressions and Ada code which are executed when some input text matches the regular expression. The scanner file contains basically three areas separated by a line containing only `%%`. The global layout is:</p><p>```<a href="C">C</a> definitions %% rules %% user code ```</p><p>The scanner extracts below are taken from a CSS parser written in Ada, the complete scanner file is <a href="css-parser-lexer.l">css-parser-lexer.l</a>(https://github.com/stcarrez/ada-css/blob/master/src/parser/css-parser-lexer.l). I highlight here some interesting parts of that lexer.</p><p>The definitions section contains a set of configuration options that tells the Aflex generator how to generate the final Ada scanner. First, the `%unit` directive allows to control the Ada package name used by the final scanner. The scanner package can be a child package which gives a lot of flexibility and control for the program organization.</p><p>```<a href="C">C</a> %unit CSS.Parser.Lexer %option case-insensitive %option yylineno ```</p><p>The `%option case-insensitive` tells Aflex to ignore case when generating the scanner and the `%option yylineno` instructs it to maintain a variable `yylineno` that indicates the current line number. It also maintains the `yylinecol` variable that indicates the column number of the current token. This is useful to keep track of token position in order to report them when an error occurs.</p><p>Because writing regular expressions is difficult, Aflex allows you to create named definitions where you give a name to a regular expression. A regular expression can use another named definition, hence simplifying the creation of complex regular expressions.</p><p>```<a href="C">C</a> h <a href="0-9a-f">0-9a-f</a> nonascii <a href="240-377">240-377</a> unicode \{h}{1,6}(rn|<a href="trnf">trnf</a>)? escape {unicode}|\<a href="^rnf0-9a-f">^rnf0-9a-f</a> string1 "(<a href="^nrf\"">^nrf\"</a>|\{nl}|{escape})*" string2 '(<a href="^nrf\'">^nrf\'</a>|\{nl}|{escape})*' string {string1}|{string2} nl n|rn|r|f ```</p><p>When all named definitions are written, the next section separated by the `%%` marker defines the rules that describe a pattern and an associated action. The pattern is a regular expression and the action corresponds to some Ada code that is executed. Aflex is not aware of the Ada grammar and does not check its validity. It uses the action code as is and write it in the final Ada file. When an action is complex and must be written in several lines, the action block can be enclosed by `{` and `}` (this syntax comes from the C lexer, the two symbols are of course omitted in the final program).</p><p>The extract below shows several pattern and actions:</p><p>```<a href="C">C</a> %% - return '-'; + return '+'; "and" { return T_AND; } "or" { return T_OR; } "not" { return T_NOT; } {string} { Set_String (YYLVal, YYText, yylineno, yylinecol); return T_STRING; } ```</p><p>Here, when the scanner finds the `-` or `+` symbols, it returns the `-` and `+` token. If it finds the word '`and`', it returns the token `T_AND`.</p><p>The last rule of this example will match a CSS string such as `"red"` or `'blue'` and we will get these results when the `YYText` function is called. The action will execute the `Set_String` procedure whose purpose is to populate the `YYLVal` variable (not shown in the example, and for the curious, that procedure is provided by the private part of the parent package `CSS.Parser`, hence it is visible by the generated scanner package `CSS.Parser.Lexer`).</p><p>The last section of the lexer file contains the user Ada code that will be used for the Ada scanner code generation. This section should contain a definition of the scanner package specification with any necessary `with` units. It must also provide the declaration of the `YYLex` function that should return a `Token` type.</p><p>```<a href="Ada">Ada</a> %% with CSS.Parser.Parser_Tokens; package CSS.Parser.Lexer is</p><pre><code> use CSS.Parser.Parser_Tokens;
</code></pre><pre><code> function YYLex return Token;
</code></pre><p>end CSS.Parser.Lexer;</p><p>with Ada.Text_IO; with CSS.Parser.Lexer_dfa; with CSS.Parser.Lexer_io; package body CSS.Parser.Lexer is</p><pre><code> use CSS.Parser.Lexer_dfa;
use CSS.Parser.Lexer_io;
</code></pre><pre><code> pragma Style_Checks (Off);
pragma Warnings (Off);
</code></pre><ol><li><ol><li></li></ol></li></ol><p>end CSS.Parser.Lexer; ```</p><p>The package body must also be written and it should contain a `##` marker which is the place where the Aflex generator will write the scanner code with the `YYLex` function body.</p><p>Because Aflex does not parse the Ada action code in the scanner file, it is not able to indent correctly the final program. The `pragma Style_Checks (Off);` is useful to remove the indentation warnings that the compiler could emit.</p><p>Aflex also generates a `<Lexer>_io` package and a `<Lexer>_dfa` package which provides helper operations for the generated scanner. The `<Lexer>_dfa` package defines two important functions that give access to the current token as a text.</p><p>```<a href="Ada">Ada</a> package CSS.Parser.Lexer_dfa is</p><pre><code> function YYText return String;
function YYLength return Integer;
</code></pre><p>end CSS.Parser.Lexer_dfa; ```</p><p>For example, if the scanner finds the input string `"red"`, the `YYLex` function will return the `T_STRING` value and the `YYText` function will contain the string `"red"`.</p><p>The `<Lexer>_io` package defines the `Open_Input` procedure that opens the file that must be parsed. The package also defines several other procedures and functions but most of them are dedicated to the scanner.</p><p>```<a href="Ada">Ada</a> package CSS.Parser.Lexer_io is</p><pre><code> procedure Open_Input (Fname : in String);
</code></pre><p>end CSS.Parser.Lexer_io; ```</p><ol><li><ol><li><ol><li>Code generation</li></ol></li></ol></li></ol><p>The Ada scanner is generated by running the `aflex` tool. The `-m` option tells the tool to avoid emitting Ada `with` clauses to the `Text_IO` package, the `-s` option disables the default lex rule that emits an echo of unmatched scanner input to the standard output and the `-L` option disables the `#line` directives.</p><p>```<a href="sh">sh</a></p><pre><code> aflex -ms -L css-parser-lexer.l
gnatchop -w css-parser-lexer.ada
</code></pre><p>```</p><p>The tool generates a single Ada file that contains the specification and the body and it must be split by using `gnatchop` to produce the <a href="css-parser-lexer.ads">css-parser-lexer.ads</a>(https://github.com/stcarrez/ada-css/blob/master/src/parser/css-parser-lexer.ads) specification and <a href="css-parser-lexer.adb">css-parser-lexer.adb</a>(https://github.com/stcarrez/ada-css/blob/master/src/parser/css-parser-lexer.adb) package body.</p><ol><li><ol><li>Writing a parser with Ayacc</li></ol></li></ol><p>Ayacc uses the BNF-like grammar definition to generate the parser written in Ada. The grammar file is similar to a grammar file created for <a href="Yacc">Yacc</a>(https://en.wikipedia.org/wiki/Yacc) or <a href="Bison">Bison</a>(https://www.gnu.org/software/bison/) but it contains Ada code for the grammar actions. The grammar file starts with a set of definitions that enumerates the available tokens and declares the main type to describe a parser state.</p><p>Similar to the scanner file, the `%unit` directive allows to control the name of the generated Ada package. I've found very convenient to provide a parent Ada package that defines various types and operations that the generated parser can use. By using the `%unit` and specifying a child package, the generated parser can easily access those operations and types even if they are declared in the private part.</p><p>```<a href="C">C</a> %unit CSS.Parser.Parser %token T_STRING %token T_AND %token T_OR %token T_NOT ```</p><p>The Ayacc generated parser uses a stack to keep track and maintain the state while parsing a content. Each stack entry represents a grammar rule that was recognized and it is possible to also record some specific information. For this, the declaration part must declare the `YYSType` Ada type. That type describes the state and information about a grammar rule. The parser pushes or pops values on the stack according to the grammar rules that are recognized (after a _shift_ or _reduce_ operation). The `YYSType` cannot be a limited type nor can it be abstract because the value must be copied to or from the `YYLVal` global variable.</p><p>In the following definition, the `YYSType` is in fact declared in the private part of the parent package `CSS.Parser` (again, that type is visible to the parser because it is one of its child package).</p><p>```<a href="Ada">Ada</a> {</p><pre><code> subtype YYSType is CSS.Parser.YYstype;
</code></pre><p>} ```</p><p>After the declaration part, the `%%` separator introduces a list of BNF-like rules. Some grammar rules can be associated with some actions which are executed when the grammar rule is recognized. With Ayacc, the action is an Ada code which can contain `$n` constructs which give access to values of the rule elements. In fact, the `$n` values refers to values in the parser stack and the `$$` value is the `YYVal` variable. When an action is executed, this is known as a _reduce_ action and all the rule elements are replaced by the `$$` result.</p><p>```<a href="Ada">Ada</a> %% expr :</p><pre><code> expr operator term
{ CSS.Parser.Set_Expr ($$, $1, $3); }
|
expr term
{ CSS.Parser.Set_Expr ($$, $1, $2); }
|
term
;
</code></pre><p>```</p><p>In this grammar rule extract, the `$$` refers to the current rule value (`YYVal`), the `$1` contains the value of the first element and so on. It is not possible to exceed the number of elements described by the rule. These values are of type `YYSType`. When the rule action is finished, the elements matched by the rule are removed from the stack and the current value `$$` (`YYVal`) is pushed on top of the stack.</p><p>It is possible to write complex action code in the grammar file but this is not very convenient. In many cases, it is easier to provide procedures or functions that the generated parser can use for the action to perform its work.</p><p>After the grammar rules, a last `%%` separator introduces the final Ada code used by the parser generator. That last section must contain the `##` marker which represents the place where Ayacc will emit the body of the parser. The Ada code should also declare the `yyerror` procedure that is called by the generated parser when a syntax error is detected.</p><p>Below is a partial example of such final Ada code:</p><p>```<a href="Ada">Ada</a> %% with CSS.Core.Sheets; package CSS.Parser.Parser is</p><pre><code> Error_Count : Natural := 0;
</code></pre><pre><code> function Parse (Content : in String;
Document : in CSS.Core.Sheets.CSSStylesheet_Access) return Integer;
</code></pre><p>end CSS.Parser.Parser;</p><p>with CSS.Parser.Parser_Goto; with CSS.Parser.Parser_Tokens; with CSS.Parser.Parser_Shift_Reduce; with CSS.Parser.Lexer_io; with CSS.Parser.Lexer; with CSS.Parser.Lexer_dfa; with Ada.Text_IO; package body CSS.Parser.Parser is</p><pre><code> procedure YYParse;
</code></pre><pre><code> procedure yyerror (Message : in String := "syntax error");
</code></pre><pre><code> procedure yyerror (Message : in String := "syntax error") is
begin
Error_Count := Error_Count + 1;
end yyerror;
</code></pre><pre><code> function Parse (Content : in String;
Document : in CSS.Core.Sheets.CSSStylesheet_Access) return Integer is
begin
Error_Count := 0;
CSS.Parser.Lexer_Dfa.yylineno := 1;
CSS.Parser.Lexer_Dfa.yylinecol := 1;
CSS.Parser.Lexer_IO.Open_Input (Content);
CSS.Parser.Parser.Document := Document;
YYParse;
return Error_Count;
end Parse;
</code></pre><ol><li><ol><li></li></ol></li></ol><p>end CSS.Parser.Parser; ```</p><p>To prepare the scanner to read a content, you will have to call the `Open_Input` procedure with the file name as parameter. Then, all you have to do is call the `YYParse` procedure that will call the `YYLex` function and proceed with the scanning and parsing of the input file.</p><ol><li><ol><li><ol><li>Code generation</li></ol></li></ol></li></ol><p>The Ada parser is generated by running the `ayacc` tool. The `-n` option controls the size of the parser stack (the default is 8192). The `-k` option tells the generator to keep the case of tokens as they are written in the grammar file (the default is that it converts the token using mixed case). The `-s` option prints some statistics about the grammar. This is useful to understand and check the shift/reduce and reduce/reduce conflicts that could arise in the grammar. The `-e` option controls the extension of the generated file.</p><p>```<a href="sh">sh</a></p><pre><code> ayacc -n 256 -k -s -e .ada css-parser-parser.y
gnatchop -w css-parser-parser.ada
</code></pre><p>```</p><p>The tool generates a single Ada file that contains the specification and the body and it must be split by using `gnatchop` to produce the <a href="css-parser-parser.ads">css-parser-parser.ads</a>(https://github.com/stcarrez/ada-css/blob/master/src/parser/css-parser-parser.ads) specification and <a href="css-parser-parser.adb">css-parser-parser.adb</a>(https://github.com/stcarrez/ada-css/blob/master/src/parser/css-parser-parser.adb) package body.</p><ol><li><ol><li>Going further</li></ol></li></ol><p>Both tools are very close to the lex/flex and yacc/bison Unix tools which means that most tips and documentation that you will find on Lex and Yacc are common and applicable to Aflex and Ayacc. Writing the grammar file is probably the most difficult task and the <a href="GNU Bison documentation">GNU Bison documentation</a>(https://www.gnu.org/software/bison/manual/html_node/index.html) seriously helps in that task.</p><p>Looking at how scanner and grammar files are written in some other projects can help. Below is a non exhaustive list of scanner and grammar files that can be processed by Aflex and Ayacc:</p><ol><li><ol><li><ol><li>Scanner examples</li></ol></li></ol></li></ol><ul><li>Aflex example <a href="example.l">example.l</a>(https://github.com/Ada-France/aflex/blob/master/doc/example.l)</li><li>Aflex example <a href="test95.l">test95.l</a>(https://github.com/Ada-France/aflex/blob/master/doc/test95.l)</li><li>Aflex example <a href="options.l">options.l</a>(https://github.com/Ada-France/aflex/blob/master/doc/options.l)</li><li>Ayacc calc example <a href="calc_lex.l">calc_lex.l</a>(https://github.com/Ada-France/ayacc/blob/master/examples/calc/calc_lex.l)</li><li>Ayacc Ada83 scanner example <a href="ada_lex.l">ada_lex.l</a>(https://github.com/Ada-France/ayacc/blob/master/examples/ada_parser/ada_lex.l)</li><li>Ada CSS, CSS 3 scanner <a href="css-parser-lexer.l">css-parser-lexer.l</a>(https://github.com/stcarrez/ada-css/blob/master/src/parser/css-parser-lexer.l)</li><li>Ada CSS, CSS 3 definition rule scanner <a href="css-analysis-parser-lexer.l">css-analysis-parser-lexer.l</a>(https://github.com/stcarrez/ada-css/blob/master/tools/parser/css-analysis-parser-lexer.l)</li><li>Memory Analysis Tool, expression scanner <a href="mat-expressions-lexer.l">mat-expressions-lexer.l</a>(https://github.com/stcarrez/mat/blob/master/mat/src/parser/mat-expressions-lexer.l)</li></ul><ol><li><ol><li><ol><li>Grammar examples</li></ol></li></ol></li></ol><ul><li>Ayacc calc example <a href="calc.y">calc.y</a>(https://github.com/Ada-France/ayacc/blob/master/examples/calc/calc.y)</li><li>Ayacc Ada83 grammar example <a href="ada.y">ada.y</a>(https://github.com/Ada-France/ayacc/blob/master/examples/ada_parser/ada.y)</li><li>Ada CSS, CSS 3 parser <a href="css-parser-parser.y">css-parser-parser.y</a>(https://github.com/stcarrez/ada-css/blob/master/src/parser/css-parser-parser.y)</li><li>Ada CSS, CSS 3 definition rule parser <a href="css-analysis-parser-parser.y">css-analysis-parser-parser.y</a>(https://github.com/stcarrez/ada-css/blob/master/tools/parser/css-analysis-parser-parser.y)</li><li>Memory Analysis Tool, expression parser <a href="mat-expressions-parser.y">mat-expressions-parser.y</a>(https://github.com/stcarrez/mat/blob/master/mat/src/parser/mat-expressions-parser.y)</li></ul></div> AWA 2.3.0urn:md5:69399f402572f7858add3af5941186332021-07-31T08:53:25+00:002021-07-31T08:53:25+00:00Stephane CarrezAdaframeworkrelease
<div class="post-text"><p>The framework provides several ready to use and extendable modules that are common to many web applications. This includes the login, authentication, users, permissions, managing comments, tags, votes, documents, images. It provides a complete blog, question and answers and a wiki module.</p><p>AWA simplifies the Web Application development by taking care of user management authentication and by providing the foundations on top of which you can construct your own application. AWA provides a powerful permission management that gives flexibility to applications to grant access and protect your user's resources.</p><p>A typical architecture of an AWA application is represented by the picture below:</p><p>((Ada/awa_architecture_overview.png|awa_architecture_overview.png|C|Ada Web Application architecture)</p><p>This version of AWA integrates smoothly with <a href="https://blog.vacs.fr/vacs/blogs/post.html?post=2019/12/26/AKT-a-tool-to-store-and-protect-your-sensitive-information">Ada Keystore</a> in order to protect the server sensitive configuration.</p><h3>AWA, Version 2.3.0</h3><ul><li>Update Trumbowyg editor to version 2.23.0</li><li>Fix generation of og:image meta for blog articles written in Markdown</li><li>Fix wiki preview with latest xkhtmltoimage 0.12.6</li><li>Use Dynamo 1.2.2, Ada Server Faces 1.4.3, Ada Servlet 1.5.2, OpenAPI Ada 0.5.0</li><li>Use Ada Wiki 1.3.2, Ada Database Objects 2.2.0</li><li>Use Ada Keystore 1.3.2, Ada EL 1.8.3, Ada Utility Library 2.4.1</li></ul><p>Links: <a href="http://download.vacs.fr/ada-awa/ada-awa-2.3.0.tar.gz">Download</a> <a href="https://github.com/stcarrez/ada-awa">GitHub</a> <a href="https://gitlab.com/stcarrez/ada-awa">GitLab</a></p><h3>Dynamo, Version 1.2.2</h3><ul><li>Fix the SQL type definition for double on PostgreSQL</li><li>Fix double support and nullable entity_type</li><li>Fix SQL generation for a foreign key with variable length</li></ul><p>Links: <a href="http://download.vacs.fr/dynamo/dynamo-1.2.2.tar.gz">Download</a> <a href="https://github.com/stcarrez/dynamo">GitHub</a> <a href="https://gitlab.com/stcarrez/dynamo">GitLab</a></p><h3>Swagger Ada, Version 0.5.0</h3><ul><li>Fix for GNAT 2021</li><li>Update the openapi generator to version 5.2.0</li></ul><p>Links: <a href="http://download.vacs.fr/swagger-ada/swagger-ada-0.5.0.tar.gz">Download</a> <a href="https://github.com/stcarrez/swagger-ada">GitHub</a> <a href="https://gitlab.com/stcarrez/swagger-ada">GitLab</a></p><h3>Ada Servlet, Version 1.5.2</h3><ul><li>Fix for GNAT 2021</li></ul><p>Links: <a href="http://download.vacs.fr/ada-servlet/ada-servlet-1.5.2.tar.gz">Download</a> <a href="https://github.com/stcarrez/ada-servlet">GitHub</a> <a href="https://github.com/stcarrez/ada-servlet">GitLab</a></p><h3>Ada Wiki Library, Version 1.3.2</h3><ul><li>Fix <hr> and <br> generation to follow HTML5 convention.</li><li>Add option -H to the render example</li><li>Fix for GNAT 2021</li></ul><p>Links: <a href="http://download.vacs.fr/ada-wiki/ada-wiki-1.3.2.tar.gz">Download</a> <a href="https://github.com/stcarrez/ada-wiki">GitHub</a> <a href="https://gitlab.com/stcarrez/ada-wiki">GitLab</a></p><h3>Ada Server Faces, Version 1.4.3</h3><ul><li>Add jQuery 3.6.0</li><li>Add a programmer's guide</li><li>Remove very old jQuery 1.11.3, jQuery UI 1.11.4, jQuery Chosen 1.4.2</li></ul><p>Links: <a href="http://download.vacs.fr/ada-asf/ada-asf-1.4.3.tar.gz">Download</a> <a href="https://github.com/stcarrez/ada-asf">GitHub</a> <a href="https://gitlab.com/stcarrez/ada-asf">GitLab</a></p><h3>Ada Database Objects, Version 2.2.0</h3><ul><li>Improvement of query loaders</li><li>Fix reading database schema with float/double values</li><li>Rename Get_Double into Get_Long_Float</li></ul><p>Links: <a href="http://download.vacs.fr/ada-ado/ada-ado-2.2.0.tar.gz">Download</a> <a href="https://github.com/stcarrez/ada-ado">GitHub</a> <a href="https://gitlab.com/stcarrez/ada-ado">GitLab</a></p><h3>Ada EL Library, Version 1.8.3</h3><ul><li>Fix compilation warning with GNAT 2021</li></ul><p>Links: <a href="http://download.vacs.fr/ada-el/ada-el-1.8.3.tar.gz">Download</a> <a href="https://github.com/stcarrez/ada-el">GitHub</a> <a href="https://gitlab.com/stcarrez/ada-el">GitLab</a></p><h3>Ada Utility Library, Version 2.4.1</h3><ul><li>Fix compilation issues with GNAT 2021</li><li>Fix serialization of Util.Beans.Objects holding arrays or maps</li></ul><p>Links: <a href="http://download.vacs.fr/ada-util/ada-util-2.4.1.tar.gz">Download</a> <a href="https://github.com/stcarrez/ada-util">GitHub</a> <a href="https://gitlab.com/stcarrez/ada-util">GitLab</a></p><h3>Ada Keystore, Version 1.3.2</h3><ul><li>Minor compilation warning fixes</li></ul><p>Links: <a href="http://download.vacs.fr/ada-keystore/ada-keystore-1.3.2.tar.gz">Download</a> <a href="https://github.com/stcarrez/ada-keystore">GitHub</a> <a href="https://github.com/stcarrez/ada-keystore">GitLab</a></p><p>All these Ada projects can be downloaded individually but they are also packaged together to help in their download and build process. You can also download everything at <a href="http://download.vacs.fr/ada-awa/awa-all-2.3.0.tar.gz">http://download.vacs.fr/ada-awa/awa-all-2.3.0.tar.gz</a></p><p>After downloading the <a href="http://download.vacs.fr/ada-awa/awa-all-2.3.0.tar.gz">awa-all-2.3.0.tar.gz</a> package, have a look at the <a href="http://ada-awa.readthedocs.io/en/latest/">Ada Web Application Programmer's Guide</a> to learn how to build, install and start using all this.</p><p>If you don't have time to build all this, a docker container is available: <a href="https://hub.docker.com/r/ciceron/ada-awa/">https://hub.docker.com/r/ciceron/ada-awa/</a></p><h2>Debian packages</h2><p>I've created and setup a Debian repository to give access to several Debian packages for several Ada projects that I manage. The goal is to provide some easy and ready to use packages to simplify and help in the installation of various Ada libraries.</p><h3>Access to the repository</h3><p>The repository packages are signed with GPG. To get the verification key and setup the <code>apt-get</code> tool, you should run the following command:</p><pre><code>wget -O - https://apt.vacs.fr/apt.vacs.fr.gpg.key | sudo apt-key add -
</code></pre><h3>Ubuntu 18.04 Bionic Beaver</h3><p>A first repository provides Debian packages targeted at Ubuntu 18.04 bionic. They are built with the <code>gnat-7</code> package and depend on <code>libgpr1-dev</code>, <code>libaws3.3.2.2-dev</code> and <code>libxmlada-sax7-dev</code>. Add the following line to your <code>/etc/apt/sources.list</code> configuration:</p><pre><code>deb https://apt.vacs.fr/ubuntu-bionic bionic main
</code></pre><h3>Ubuntu 20.04 Focal Fossa</h3><p>A second repository provides Debian packages targeted at Ubuntu 20.04 focal. They are built with the <code>gnat-9</code> package and depend on <code>libgnatprj7-dev</code>, <code>libaws19-dev</code> and <code>libxmlada-sax9-dev</code>. Add the following line to your <code>/etc/apt/sources.list</code> configuration:</p><pre><code>deb https://apt.vacs.fr/ubuntu-focal focal main
</code></pre><h3>Debian 10 Buster</h3><p>A third repository provides Debian packages targeted at Debian 10 buster. They are built with the <code>gnat-8</code> package and depend on <code>libgpr2-dev</code>, <code>libaws18-dev</code> and <code>libxmlada-sax8-dev</code>. Add the following line to your <code>/etc/apt/sources.list</code> configuration:</p><pre><code>deb https://apt.vacs.fr/debian-buster buster main
</code></pre><h3>Installation</h3><p>Once you've added the configuration line, you can install the packages:</p><pre><code>sudo apt-get update
sudo apt-get install -y dynamo akt libawa2-dev libawa-unit2-dev
</code></pre><p>The <a href="https://github.com/stcarrez/ada-awa">Ada Web Application</a> framework contains several plugins which are provided by separate Debian packages.</p><pre><code>sudo apt-get install -y libawa-blogs2-dev libawa-questions2-dev libawa-wikis2-dev libawa-setup2-dev
</code></pre><p>The documentation is packaged in separate Debian packages, you can install them with:</p><pre><code>sudo apt-get install -y libawa-doc libado-doc libawa-doc libkeystoreada-doc libsecurity-doc libutilada-doc libwikiada-doc
</code></pre></div> New release Ada BFD 1.2.0urn:md5:49b106f1dd4b211d749df14de73863ab2021-04-11T18:37:21+00:002021-04-11T18:37:21+00:00Stephane CarrezbinutilsreleaseAdaELF
<div class="post-text"><p>The new release is a cleanup and update of the library to support newer version of GNU binutils. The main changes are below:</p><ul><li>Cleanup build process and use gprinstall for installation</li><li>Fix build with binutils > 2.34</li><li>Remove invalid API: `Bfd.Set_Error_Handler`</li><li>Remove fake API: `Bfd.Symbols.Is_Local_Label_Name`</li></ul><ol><li><ol><li>Installation</li></ol></li></ol><p>To use the Ada BFD library, you may either build it from the sources <a href="ada-bfd-1.2.0.tar.gz">ada-bfd-1.2.0.tar.gz</a>(https://download.vacs.fr/ada-bfd/ada-bfd-1.2.0.tar.gz) or install the Debian packages.</p><p>To build from the sources, you need to have a working GNAT Ada compiler as well as the `binutils-dev` Debian package installed. Then, run the following commands:</p><p>```sh git clone <a href="https://github.com/stcarrez/ada-bfd.git">https://github.com/stcarrez/ada-bfd.git</a> cd ada-bfd ./configure make build check install ```</p><p>For the Debian package installation, use the configuration that corresponds to your setup:</p><p>``` deb <a href="https://apt.vacs.fr/ubuntu-bionic">https://apt.vacs.fr/ubuntu-bionic</a> bionic main deb <a href="https://apt.vacs.fr/ubuntu-focal">https://apt.vacs.fr/ubuntu-focal</a> focal main deb <a href="https://apt.vacs.fr/debian-buster">https://apt.vacs.fr/debian-buster</a> buster main ```</p><p>and then run:</p><p>``` sudo apt-get update</p><ol><li>Bionic: sudo apt-get install libbfdada1-dev</li><li>Focal: sudo apt-get install libbfdada2-dev</li><li>Buster: sudo apt-get install libbfdada3-dev</li></ol><p>```</p><ol><li><ol><li>Reading the ELF sections</li></ol></li></ol><p>Using the Ada BFD library in a projet is quite easy, the first step is to add the following line in your GNAT project file:</p><p>``` <a href="Ada">Ada</a> with "bfdada"; ```</p><p>To access the information of a binary, you must first define an instance of the `File_Type` and open the file. You will do this as follows:</p><p>``` <a href="Ada">Ada</a> with Bfd.Files;</p><pre><code> ...
Path : constant String := "..."; -- the binary to load
File : Bfd.Files.File_Type;
...
Bfd.Files.Open (File, Path, "");
</code></pre><p>```</p><p>Looking at the ELF section is easily made by using the `Section_Iterator` provided by the `Bfd.Sections` package.</p><p>```ada with Bfd.Sections;</p><pre><code> ...
Iter : Bfd.Sections.Section_Iterator := Bfd.Sections.Get_Sections (File);
...
while Bfd.Sections.Has_Element (Iter) loop
declare
S : constant Bfd.Sections.Section := Bfd.Sections.Element (Iter);
begin
Ada.Text_IO.Put_Line (Bfd.Sections.Get_Name (S));
end;
Bfd.Sections.Next (Iter);
end loop;
</code></pre><p>```</p><p>The library contains several examples that show different features of the Ada BFD library:</p><p>| <a href="bfdinfo.adb">bfdinfo.adb</a>(https://github.com/stcarrez/ada-bfd/blob/master/samples/bfdinfo.adb) | ./bin/bfdinfo ./bin/bfdgen | Open BFD file, get flags, list sections and symbols | | <a href="sections.adb">sections.adb</a>(https://github.com/stcarrez/ada-bfd/blob/master/samples/sections.adb) | ./bin/sections ./bin/bfdgen | Display the ELF sections with the `Bfd.Sections` | | <a href="symbol.adb">symbol.adb</a>(https://github.com/stcarrez/ada-bfd/blob/master/samples/symbol.adb) | ./bin/symbol ./bin/bfdgen main | Read the symbol table with `Bfd.Symbols` | | <a href="disassemble.adb">disassemble.adb</a>(https://github.com/stcarrez/ada-bfd/blob/master/samples/disassemble.adb) | ./bin/disassemble ./bin/bfdgen | Disassemble the text section with `Bfd.Disassemble` |</p></div> AWA 2.2.0urn:md5:7cf2c06fdc7fb95d1d33bae39809e88d2021-03-20T16:33:31+00:002021-03-20T16:33:31+00:00Stephane CarrezAdareleaseframework
<div class="post-text"><p>The framework provides several ready to use and extendable modules that are common to many web applications. This includes the login, authentication, users, permissions, managing comments, tags, votes, documents, images. It provides a complete blog, question and answers and a wiki module.</p><p>AWA simplifies the Web Application development by taking care of user management authentication and by providing the foundations on top of which you can construct your own application. AWA provides a powerful permission management that gives flexibility to applications to grant access and protect your user's resources.</p><p>A typical architecture of an AWA application is represented by the picture below:</p><p>((Ada/awa_architecture_overview.png|awa_architecture_overview.png|C|Ada Web Application architecture)</p><p>This version of AWA integrates smoothly with <a href="https://blog.vacs.fr/vacs/blogs/post.html?post=2019/12/26/AKT-a-tool-to-store-and-protect-your-sensitive-information">Ada Keystore</a> in order to protect the server sensitive configuration.</p><h3>AWA, Version 2.2.0</h3><ul><li>Fixed the Markdown js editor configuration</li><li>Send an event when a blog post is published (allows customisation such as sending e-mails)</li><li>Use Dynamo 1.2.1, Ada Server Faces 1.4.2, Ada Servlet 1.5.1, OpenAPI Ada 0.4.0</li><li>Use Ada Security 1.4.0, Ada Wiki 1.3.1, Ada Database Objects 2.1.2</li><li>Use Ada Keystore 1.3.1, Ada EL 1.8.2, Ada Utility Library 2.4.0</li></ul><p>Download: <a href="http://download.vacs.fr/ada-awa/ada-awa-2.2.0.tar.gz">http://download.vacs.fr/ada-awa/ada-awa-2.2.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-awa">https://github.com/stcarrez/ada-awa</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-awa">https://gitlab.com/stcarrez/ada-awa</a></p><h3>Dynamo, Version 1.2.1</h3><ul><li>Fix uninitialized float values in generated code</li></ul><p>Download: <a href="http://download.vacs.fr/dynamo/dynamo-1.2.1.tar.gz">http://download.vacs.fr/dynamo/dynamo-1.2.1.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/dynamo">https://github.com/stcarrez/dynamo</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/dynamo">https://gitlab.com/stcarrez/dynamo</a></p><h3>Swagger Ada, Version 0.4.0</h3><ul><li>Update the openapi generator to version 5.1.0</li></ul><p>Download: <a href="http://download.vacs.fr/swagger-ada/swagger-ada-0.4.0.tar.gz">http://download.vacs.fr/swagger-ada/swagger-ada-0.4.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/swagger-ada">https://github.com/stcarrez/swagger-ada</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/swagger-ada">https://gitlab.com/stcarrez/swagger-ada</a></p><h3>Ada Servlet, Version 1.5.1</h3><ul><li>Cleanup the examples</li><li>Fix registration and support of application with an empty registration URI</li></ul><p>Download: <a href="http://download.vacs.fr/ada-servlet/ada-servlet-1.5.1.tar.gz">http://download.vacs.fr/ada-servlet/ada-servlet-1.5.1.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-servlet">https://github.com/stcarrez/ada-servlet</a></p><p>GitLab: <a href="https://github.com/stcarrez/ada-servlet">https://github.com/stcarrez/ada-servlet</a></p><h3>Ada Wiki Library, Version 1.3.1</h3><ul><li>Minor cleanup for the build</li></ul><p>Download: <a href="http://download.vacs.fr/ada-wiki/ada-wiki-1.3.1.tar.gz">http://download.vacs.fr/ada-wiki/ada-wiki-1.3.1.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-wiki">https://github.com/stcarrez/ada-wiki</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-wiki">https://gitlab.com/stcarrez/ada-wiki</a></p><h3>Ada Server Faces, Version 1.4.2</h3><ul><li>Fix compilation warnings</li><li>Cleanup build and examples</li></ul><p>Download: <a href="http://download.vacs.fr/ada-asf/ada-asf-1.4.2.tar.gz">http://download.vacs.fr/ada-asf/ada-asf-1.4.2.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-asf">https://github.com/stcarrez/ada-asf</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-asf">https://gitlab.com/stcarrez/ada-asf</a></p><h3>Ada Database Objects, Version 2.1.2</h3><ul><li>Fix uninitialized float values in generated code used by unit tests</li></ul><p>Download: <a href="http://download.vacs.fr/ada-ado/ada-ado-2.1.2.tar.gz">http://download.vacs.fr/ada-ado/ada-ado-2.1.2.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-ado">https://github.com/stcarrez/ada-ado</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-ado">https://gitlab.com/stcarrez/ada-ado</a></p><h3>Ada EL Library, Version 1.8.2</h3><ul><li>Minor build cleanup</li></ul><p>Download: <a href="http://download.vacs.fr/ada-el/ada-el-1.8.2.tar.gz">http://download.vacs.fr/ada-el/ada-el-1.8.2.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-el">https://github.com/stcarrez/ada-el</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-el">https://gitlab.com/stcarrez/ada-el</a></p><h3>Ada Utility Library, Version 2.4.0</h3><ul><li>Add support to customize and provide application specific log appenders (example in ada-keystore)</li><li>Improvement of read/write streams to chain LZMA, AES, Base64</li><li>Add examples to show LZMA compress+AES encryption, AES decryption+LZMA decompress</li><li>Fix compilation with GNAT 10</li><li>New package Util.Properties.Form to help in parsing application/x-www-form-urlencoded</li><li>Fixed the Util.Tests.Get_Test_Path semantic and use the results directory</li><li>Drop detection of buggy gcc 4.7.2</li></ul><p>Download: <a href="http://download.vacs.fr/ada-util/ada-util-2.4.0.tar.gz">http://download.vacs.fr/ada-util/ada-util-2.4.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-util">https://github.com/stcarrez/ada-util</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-util">https://gitlab.com/stcarrez/ada-util</a></p><h3>Ada Security Library, Version 1.4.0</h3><ul><li>Add support to authenticate with Gitlab and GitHub</li><li>Update Yahoo! authenticate to use OpenId connect</li><li>Update the AWS demo to add Gitlab and Github</li></ul><p>Download: <a href="http://download.vacs.fr/ada-security/ada-security-1.4.0.tar.gz">http://download.vacs.fr/ada-security/ada-security-1.4.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-security">https://github.com/stcarrez/ada-security</a></p><p>GitLab: <a href="https://github.com/stcarrez/ada-security">https://github.com/stcarrez/ada-security</a></p><p>All these Ada projects can be downloaded individually but they are also packaged together to help in their download and build process. You can also download everything at <a href="http://download.vacs.fr/ada-awa/awa-all-2.2.0.tar.gz">http://download.vacs.fr/ada-awa/awa-all-2.2.0.tar.gz</a></p><p>After downloading the <a href="http://download.vacs.fr/ada-awa/awa-all-2.2.0.tar.gz">awa-all-2.2.0.tar.gz</a> package, have a look at the <a href="http://ada-awa.readthedocs.io/en/latest/">Ada Web Application Programmer's Guide</a> to learn how to build, install and start using all this.</p><p>If you don't have time to build all this, a docker container is available: <a href="https://hub.docker.com/r/ciceron/ada-awa/">https://hub.docker.com/r/ciceron/ada-awa/</a></p><h2>Debian packages</h2><p>I've created and setup a Debian repository to give access to several Debian packages for several Ada projects that I manage. The goal is to provide some easy and ready to use packages to simplify and help in the installation of various Ada libraries.</p><h3>Access to the repository</h3><p>The repository packages are signed with GPG. To get the verification key and setup the <code>apt-get</code> tool, you should run the following command:</p><pre><code>wget -O - https://apt.vacs.fr/apt.vacs.fr.gpg.key | sudo apt-key add -
</code></pre><h3>Ubuntu 18.04 Bionic Beaver</h3><p>A first repository provides Debian packages targeted at Ubuntu 18.04 bionic. They are built with the <code>gnat-7</code> package and depend on <code>libgpr1-dev</code>, <code>libaws3.3.2.2-dev</code> and <code>libxmlada-sax7-dev</code>. Add the following line to your <code>/etc/apt/sources.list</code> configuration:</p><pre><code>deb https://apt.vacs.fr/ubuntu-bionic bionic main
</code></pre><h3>Ubuntu 20.04 Focal Fossa</h3><p>A second repository provides Debian packages targeted at Ubuntu 20.04 focal. They are built with the <code>gnat-9</code> package and depend on <code>libgnatprj7-dev</code>, <code>libaws19-dev</code> and <code>libxmlada-sax9-dev</code>. Add the following line to your <code>/etc/apt/sources.list</code> configuration:</p><pre><code>deb https://apt.vacs.fr/ubuntu-focal focal main
</code></pre><h3>Debian 10 Buster</h3><p>A third repository provides Debian packages targeted at Debian 10 buster. They are built with the <code>gnat-8</code> package and depend on <code>libgpr2-dev</code>, <code>libaws18-dev</code> and <code>libxmlada-sax8-dev</code>. Add the following line to your <code>/etc/apt/sources.list</code> configuration:</p><pre><code>deb https://apt.vacs.fr/debian-buster buster main
</code></pre><h3>Installation</h3><p>Once you've added the configuration line, you can install the packages:</p><pre><code>sudo apt-get update
sudo apt-get install -y dynamo akt libawa2-dev libawa-unit2-dev
</code></pre><p>The <a href="https://github.com/stcarrez/ada-awa">Ada Web Application</a> framework contains several plugins which are provided by separate Debian packages.</p><pre><code>sudo apt-get install -y libawa-blogs2-dev libawa-questions2-dev libawa-wikis2-dev libawa-setup2-dev
</code></pre><p>The documentation is packaged in separate Debian packages, you can install them with:</p><pre><code>sudo apt-get install -y libawa-doc libado-doc libawa-doc libkeystoreada-doc libsecurity-doc libutilada-doc libwikiada-doc
</code></pre><p>For the curious, you may browse the repository <a href="https://blog.vacs.fr/vacs/debian/ubuntu-focal/index.html">here</a>.</p></div> New release of AKT with Fuse supporturn:md5:f45e95e3497aa7a80095da3bfbede6ce2021-03-07T19:08:00+00:002021-03-07T19:08:00+00:00Stephane CarrezAdaSecurityreleaseStorage
<div class="post-text"><p>Data are stored in secure wallets protected and signed by their own AES-256 key.</p><p>Wallets are protected by a master key using AES-256-CBC and the wallet master key is protected by a user password. The wallet defines up to 7 slots that identify a password key that is able to unlock the master key. To open a wallet, it is necessary to unlock one of these 7 slots by providing the correct password. Wallet key slots are protected by the user's password and the PBKDF2-HMAC-256 algorithm, a random salt, a random counter and they are encrypted using AES-256-CBC. A wallet key slot can also be protected by a GPG private key.</p><p>Data stored in the wallet are protected by their own encryption keys using AES-256-CBC. Big contents are stored in several data blocks and each data block is encrypted by using its own AES-256-CBC encryption key. Encryption keys are protected by the master key using AES-256-CBC. Data blocks are then signed using HMAC-256.</p><p>A wallet can contain another wallet which is then protected by its own encryption keys and passwords (with 7 independent slots). Because the child wallet has its own master key, it is necessary to known the primary password and the child password to unlock the parent wallet first and then the child wallet.</p><h3>Installation</h3><p>You can install AKT by using the Debian 10 and Ubuntu 20.04 or 18.04 packages. First, setup to accept the signed packages:</p><pre><code class="lang-sh">wget -O - https://apt.vacs.fr/apt.vacs.fr.gpg.key | sudo apt-key add -
</code></pre><p>and choose one of the <code>echo</code> command according to your Linux distribution:</p><pre><code class="lang-sh"># Ubuntu 20.04
# echo "deb https://apt.vacs.fr/ubuntu-focal focal main" | sudo tee -a /etc/apt/sources.list.d/vacs.list
# Ubuntu 18.04
# echo "deb https://apt.vacs.fr/ubuntu-bionic bionic main" | sudo tee -a /etc/apt/sources.list.d/vacs.list
# Debian 10
# echo "deb https://apt.vacs.fr/debian-buster buster main" | sudo tee -a /etc/apt/sources.list.d/vacs.list
</code></pre><p>Then, launch the apt update command:</p><pre><code class="lang-sh">sudo apt-get update
</code></pre><p>and install the tool using:</p><pre><code class="lang-sh">sudo apt-get install -y akt
</code></pre><p>You can also build from the source by using the following commands:</p><pre><code class="lang-sh">sudo apt-get install -y make gnat-7 gprbuild git gnupg2 libfuse-dev
git clone --recursive https://github.com/stcarrez/ada-keystore.git
cd ada-keystore
./configure --enable-fuse
</code></pre><h3>Using AKT</h3><p>To setup a keystore file and protect it with your GPG key, use the following command:</p><pre><code class="lang-sh">akt create secure.akt --gpg your-gpg-key-id
</code></pre><p>The keystore content can be mounted as a filesystem so that the encrypted content are directly available to existing applications as regular files. The <code>mount</code> command starts the fuse daemon and puts the command as a background fuse daemon to serve as a fuse filesystem and make the content visible through the mount point.</p><pre><code class="lang-sh">akt mount secure.akt /mnt
</code></pre><p>After the mount is successful, you can copy or access any file stored in the secure keystore. By default the Fuse filesystem is configured to ask the kernel to avoid caching the decrypted content. This has an impact on the performance since every access requires to decrypt the content.</p><p>To unmount the filesystem, you must use the <code>umount</code> command.</p><pre><code class="lang-sh">umount /mnt
</code></pre><p>Sometimes, you may have to force the umount by running:</p><pre><code>sudo umount /mnt
</code></pre></div> Ada Web Application release 2.1.0urn:md5:7d5d71414984faf192ae0188d08cf7762020-11-15T21:12:45+00:002020-11-15T21:12:45+00:00Stephane CarrezAdareleaseframework
<div class="post-text"><p>The framework provides several ready to use and extendable modules that are common to many web applications. This includes the login, authentication, users, permissions, managing comments, tags, votes, documents, images. It provides a complete blog, question and answers and a wiki module.</p><p>AWA simplifies the Web Application development by taking care of user management authentication and by providing the foundations on top of which you can construct your own application. AWA provides a powerful permission management that gives flexibility to applications to grant access and protect your user's resources.</p><p>A typical architecture of an AWA application is represented by the picture below:</p><p>((Ada/awa_architecture_overview.png|awa_architecture_overview.png|C|Ada Web Application architecture)</p><p>This version of AWA integrates smoothly with <a href="https://blog.vacs.fr/vacs/blogs/post.html?post=2019/12/26/AKT-a-tool-to-store-and-protect-your-sensitive-information">Ada Keystore</a> in order to protect the server sensitive configuration.</p><h3>AWA, Version 2.1.0</h3><ul><li>Update Trumbowyg editor to version 2.21.0</li><li>Fix compilation issues with GNAT 2020</li><li>Update mail UI component to attach external files</li><li>Improved setup for secure configuration with Ada Keystore</li><li>Use Dynamo 1.2.0, Ada Server Faces 1.4.1, Ada Servlet 1.5.0, OpenAPI Ada 0.3.0</li><li>Use Ada Security 1.3.1, Ada Wiki 1.3.0, Ada Database Objects 2.1.1</li><li>Use Ada Keystore 1.2.1, Ada EL 1.8.1, Ada Utility Library 2.3.0</li></ul><p>Download: <a href="http://download.vacs.fr/ada-awa/ada-awa-2.1.0.tar.gz">http://download.vacs.fr/ada-awa/ada-awa-2.1.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-awa">https://github.com/stcarrez/ada-awa</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-awa">https://gitlab.com/stcarrez/ada-awa</a></p><h3>Dynamo, Version 1.2.0</h3><ul><li>Integrate ArgoUML 0.35.2-2020-07-05</li><li>Fix SQL generation with 'auto' generator</li><li>Fix XML Hibernate mapping support</li><li>Improvement in SQL schema generation</li></ul><p>Download: <a href="http://download.vacs.fr/dynamo/dynamo-1.2.0.tar.gz">http://download.vacs.fr/dynamo/dynamo-1.2.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/dynamo">https://github.com/stcarrez/dynamo</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/dynamo">https://gitlab.com/stcarrez/dynamo</a></p><h3>Swagger Ada, Version 0.3.0</h3><ul><li>Install the openapi generator</li><li>Update the openapi generator to version 5.0.0</li><li>Update to use Swagger UI 3.36.0</li><li>Fixed Ada client code generator to support `FreeFormObject` and multi-path parameters</li><li>Add support for HTTP HEAD, OPTIONS and PATCH requests</li><li>Initial implementation of Swagger OpenAPI to easily implement REST clients and servers</li></ul><p>Download: <a href="http://download.vacs.fr/swagger-ada/swagger-ada-0.3.0.tar.gz">http://download.vacs.fr/swagger-ada/swagger-ada-0.3.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/swagger-ada">https://github.com/stcarrez/swagger-ada</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/swagger-ada">https://gitlab.com/stcarrez/swagger-ada</a></p><h3>Ada Servlet, Version 1.5.0</h3><ul><li>Added support for PATCH and fix OPTIONS and HEAD requests</li><li>Added a Docker image to play with Ada Servlet</li></ul><p>Download: <a href="http://download.vacs.fr/ada-servlet/ada-servlet-1.5.0.tar.gz">http://download.vacs.fr/ada-servlet/ada-servlet-1.5.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-servlet">https://github.com/stcarrez/ada-servlet</a></p><p>GitLab: <a href="https://github.com/stcarrez/ada-servlet">https://github.com/stcarrez/ada-servlet</a></p><h3>Ada Wiki Library, Version 1.3.0</h3><ul><li>New plugin and filter to setup and expand variables in Wiki texts</li><li>Add support for Markdown tables</li><li>Fixes in the Markdown and Creole syntax parsers</li><li>New Ada Wiki Engine Programmer's Guide</li></ul><p>Download: <a href="http://download.vacs.fr/ada-wiki/ada-wiki-1.3.0.tar.gz">http://download.vacs.fr/ada-wiki/ada-wiki-1.3.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-wiki">https://github.com/stcarrez/ada-wiki</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-wiki">https://gitlab.com/stcarrez/ada-wiki</a></p><h3>Ada Server Faces, Version 1.4.1</h3><ul><li>Fix translations, compilation warnings</li></ul><p>Download: <a href="http://download.vacs.fr/ada-asf/ada-asf-1.4.1.tar.gz">http://download.vacs.fr/ada-asf/ada-asf-1.4.1.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-asf">https://github.com/stcarrez/ada-asf</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-asf">https://gitlab.com/stcarrez/ada-asf</a></p><h3>Ada Database Objects, Version 2.1.1</h3><ul><li>Fix using the configuration with multiple config environments</li></ul><p>Download: <a href="http://download.vacs.fr/ada-ado/ada-ado-2.1.1.tar.gz">http://download.vacs.fr/ada-ado/ada-ado-2.1.1.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-ado">https://github.com/stcarrez/ada-ado</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-ado">https://gitlab.com/stcarrez/ada-ado</a></p><h3>Ada EL Library, Version 1.8.1</h3><ul><li>Fix compilation issue with GNAT 2020</li></ul><p>Download: <a href="http://download.vacs.fr/ada-el/ada-el-1.8.1.tar.gz">http://download.vacs.fr/ada-el/ada-el-1.8.1.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-el">https://github.com/stcarrez/ada-el</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-el">https://gitlab.com/stcarrez/ada-el</a></p><h3>Ada Utility Library, Version 2.3.0</h3><ul><li>New stream operations to read/write UTF-8 sequences in Wide_Wide character</li><li>Fix AES encryption in CFB, OFB and CTR modes</li><li>Add HTTP support for HEAD, OPTIONS, PATCH requests</li></ul><p>Download: <a href="http://download.vacs.fr/ada-util/ada-util-2.3.0.tar.gz">http://download.vacs.fr/ada-util/ada-util-2.3.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-util">https://github.com/stcarrez/ada-util</a></p><p>GitLab: <a href="https://gitlab.com/stcarrez/ada-util">https://gitlab.com/stcarrez/ada-util</a></p><h3>Ada Security Library, Version 1.3.1</h3><ul><li>Fix AWS example</li></ul><p>Download: <a href="http://download.vacs.fr/ada-security/ada-security-1.3.1.tar.gz">http://download.vacs.fr/ada-security/ada-security-1.3.1.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-security">https://github.com/stcarrez/ada-security</a></p><p>GitLab: <a href="https://github.com/stcarrez/ada-security">https://github.com/stcarrez/ada-security</a></p><p>All these Ada projects can be downloaded individually but they are also packaged together to help in their download and build process. You can also download everything at <a href="http://download.vacs.fr/ada-awa/awa-all-1.1.0.tar.gz">http://download.vacs.fr/ada-awa/awa-all-1.1.0.tar.gz</a></p><p>After downloading the <a href="http://download.vacs.fr/ada-awa/awa-all-1.1.0.tar.gz">awa-all-1.1.0.tar.gz</a> package, have a look at the <a href="http://ada-awa.readthedocs.io/en/latest/">Ada Web Application Programmer's Guide</a> to learn how to build, install and start using all this.</p><p>If you don't have time to build all this, a docker container is available: <a href="https://hub.docker.com/r/ciceron/ada-awa/">https://hub.docker.com/r/ciceron/ada-awa/</a></p><h2>Debian packages</h2><p>I've created and setup a Debian repository to give access to several Debian packages for several Ada projects that I manage. The goal is to provide some easy and ready to use packages to simplify and help in the installation of various Ada libraries.</p><h3>Access to the repository</h3><p>The repository packages are signed with GPG. To get the verification key and setup the <code>apt-get</code> tool, you should run the following command:</p><pre><code>wget -O - https://apt.vacs.fr/apt.vacs.fr.gpg.key | sudo apt-key add -
</code></pre><h3>Ubuntu 18.04 Bionic Beaver</h3><p>A first repository provides Debian packages targeted at Ubuntu 18.04 bionic. They are built with the <code>gnat-7</code> package and depend on <code>libgpr1-dev</code>, <code>libaws3.3.2.2-dev</code> and <code>libxmlada-sax7-dev</code>. Add the following line to your <code>/etc/apt/sources.list</code> configuration:</p><pre><code>deb https://apt.vacs.fr/ubuntu-bionic bionic main
</code></pre><h3>Ubuntu 20.04 Focal Fossa</h3><p>A second repository provides Debian packages targeted at Ubuntu 20.04 focal. They are built with the <code>gnat-9</code> package and depend on <code>libgnatprj7-dev</code>, <code>libaws19-dev</code> and <code>libxmlada-sax9-dev</code>. Add the following line to your <code>/etc/apt/sources.list</code> configuration:</p><pre><code>deb https://apt.vacs.fr/ubuntu-focal focal main
</code></pre><h3>Installation</h3><p>Once you've added the configuration line, you can install the packages:</p><pre><code>sudo apt-get update
sudo apt-get install -y dynamo akt libawa2-dev libawa-unit2-dev
</code></pre><p>The <a href="https://github.com/stcarrez/ada-awa">Ada Web Application</a> framework contains several plugins which are provided by separate Debian packages.</p><pre><code>sudo apt-get install -y libawa-blogs2-dev libawa-questions2-dev libawa-wikis2-dev libawa-setup2-dev
</code></pre><p>The documentation is packaged in separate Debian packages, you can install them with:</p><pre><code>sudo apt-get install -y libawa-doc libado-doc libawa-doc libkeystoreada-doc libsecurity-doc libutilada-doc libwikiada-doc
</code></pre><p>For the curious, you may browse the repository <a href="https://blog.vacs.fr/vacs/debian/ubuntu-focal/index.html">here</a>.</p></div> New version of Ada Web Applicationurn:md5:a1a6bbc8fba7d3f154dc5e44201020362020-05-01T20:49:00+00:002020-05-01T20:49:00+00:00Stephane CarrezreleaseAdaframework
<div class="post-text"><p>The framework provides several ready to use and extendable modules that are common to many web applications. This includes the login, authentication, users, permissions, managing comments, tags, votes, documents, images. It provides a complete blog, question and answers and a wiki module.</p><p>AWA simplifies the Web Application development by taking care of user management authentication and by providing the foundations on top of which you can construct your own application. AWA provides a powerful permission management that gives flexibility to applications to grant access and protect your user's resources.</p><p>A typical architecture of an AWA application is represented by the picture below:</p><p>((Ada/awa_architecture_overview.png|awa_architecture_overview.png|C|Ada Web Application architecture)</p><p>This version of AWA integrates smoothly with <a href="https://blog.vacs.fr/vacs/blogs/post.html?post=2019/12/26/AKT-a-tool-to-store-and-protect-your-sensitive-information">Ada Keystore</a> in order to protect the server sensitive configuration.</p><h4>Ada Web Application, Version 2.0</h4><ul><li>Refactoring of build process and installation</li><li>New audit manager for database auditing</li><li>Support for Postgresql</li><li>Improvements of images and storage plugins</li><li>Update Trumbowyg editor to version 2.18.0</li><li>Update Flot library to version 4.2.0</li><li>Support for commands to configure, start, stop the server</li><li>New mail UI component <mail:attachment> to send attachments</li></ul><h4>Dynamo, Version 1.0.0</h4><ul><li>Improvement and fixes in the YAML database model files</li><li>Add support for Nullable_String type</li><li>Generate Postgresql SQL files from the model files</li><li>Add support for database record auditing</li><li>Add support for floating point</li><li>Add support for CSS and Javascript merge in the dist command</li></ul><h4>Ada Database Objects, Version 2.1.0</h4><ul><li>Added Is_Modified predicate on database objects</li><li>Fix SQLite Load_Schema to avoid loading SQLite specific tables</li><li>Support for Postgresql database</li><li>Improvement for errors reported by database drivers</li><li>New audit framework to track database record changes</li><li>Added support for floating point numbers</li><li>Serialize queries in JSON/XML streams</li></ul><h4>Ada Keystore, Version 1.2.0</h4><ul><li>Added support for Fuse with a new mount command in akt (beta!)</li><li>Fix the implementation to iterate with Keystore.Properties</li></ul><h4>Ada Server Faces, Version 1.4.0</h4><ul><li>Performance improvement for the Facelet cache</li><li>Integrate jQuery 3.4.1, jQuery UI 1.12.1, jQuery Chosen 1.8.7</li><li>New <f:validateRegex> to validate an input field with a regular expression</li></ul><h4>Ada Utility Library, Version 2.2.0</h4><ul><li>New Wait_Empty operation on fifo.</li><li>Add Get_Count and Wait operation on executors</li></ul><h4>Ada EL Library, Version 1.8.0</h4><ul><li>New Expand procedure to expand the properties in place</li></ul><h4>Ada Wiki Library, Version 1.2.1</h4><ul><li>Minor configuration and code coverage support</li><li>Corrections in the Markdown syntax parser</li></ul><h4>Ada Security Library, Version 1.3.0</h4><ul><li>Add support to extend the authenticate manager and allow to use custom authentication through the Set_Default_Factory operation.</li></ul><h4>Ada Servlet, Version 1.4.0</h4><ul><li>Added support to configure the web container</li></ul></div> New releases of Ada Web Application et al.urn:md5:44e0baba83e31d696caedfb6dc2055162018-07-15T21:17:00+00:002018-07-15T21:17:00+00:00Stephane CarrezAdarelease
<div class="post-text"><h3>Ada Utility Library, Version 1.9.0</h3><ul><li>Improvement and fixes of the JSON, XML, CSV serialization</li><li>Improvement of properties to also read and describe INI files</li><li>Add encoders to support SHA256 and HMAC-SHA256</li><li>Added a command package for implementation of command line tools</li><li>Added event timer list management</li><li>Fix on the HTTP curl support</li><li>Implementation of x-www-form-urlencoded serialization</li><li>Added localized date parsing</li></ul><p>Download: <a href="http://download.vacs.fr/ada-util/ada-util-1.9.0.tar.gz">http://download.vacs.fr/ada-util/ada-util-1.9.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-util">https://github.com/stcarrez/ada-util</a></p><h3>Ada EL, Version 1.6.1</h3><ul><li>Fix minor compilation warnings and build with Ada 2012</li></ul><p>Download: <a href="http://download.vacs.fr/ada-el/ada-el-1.6.1.tar.gz">http://download.vacs.fr/ada-el/ada-el-1.6.1.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-el">https://github.com/stcarrez/ada-el</a></p><h3>Ada Security, Version 1.1.2</h3><ul><li>OAuth 2.0 server implementation (RFC 6749)</li><li>Improvement of the role based security policy</li></ul><p>Download: <a href="http://download.vacs.fr/ada-security/ada-security-1.2.0.tar.gz">http://download.vacs.fr/ada-security/ada-security-1.2.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-security">https://github.com/stcarrez/ada-security</a></p><h3>Ada Database Objects, Version 1.2.0</h3><ul><li>Improvement of SQLite connection management</li><li>Fix logs to avoid having password in clear text in logs</li><li>Fix lazy object loading</li><li>Fix link issue on Fedora</li></ul><p>Download: <a href="http://download.vacs.fr/ada-ado/ada-ado-1.2.0.tar.gz">http://download.vacs.fr/ada-ado/ada-ado-1.2.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-ado">https://github.com/stcarrez/ada-ado</a></p><h3>Ada Server Faces, Version 1.1.0</h3><ul><li>New EL function util:translate for translation with a resource bundle</li><li>New REST servlet with support for server API implementation</li><li>Provide pre-defined beans in ASF contexts: requestScope</li><li>Add support for servlet requests to retrieve the body content as a stream</li><li>Improvement of navigation rules to allow setting the return status</li><li>Moved the servlet support in a separate project: ada-servlet</li><li>Integrate jQuery datetime picker</li></ul><p>Download: <a href="http://download.vacs.fr/ada-asf/ada-asf-1.2.0.tar.gz">http://download.vacs.fr/ada-asf/ada-asf-1.2.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-asf">https://github.com/stcarrez/ada-asf</a></p><h3>Ada Servlet, Version 1.2.0</h3><ul><li>New REST servlet with support for server API implementation</li><li>Add support for servlet requests to retrieve the body content as a stream</li><li>Moved the Ada Servlet implementation outside of Ada Server Faces in a separate project</li></ul><p>Download: <a href="http://download.vacs.fr/ada-servlet/ada-servlet-1.2.0.tar.gz">http://download.vacs.fr/ada-servlet/ada-servlet-1.2.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-servlet">https://github.com/stcarrez/ada-servlet</a></p><h3>Ada Wiki Engine, Version 1.1.0</h3><ul><li>New condition plugins for the conditional inclusion of wiki content</li><li>Added support for <b>NOTOC</b> by the TOC filter</li></ul><p>Download: <a href="http://download.vacs.fr/ada-wiki/ada-wiki-1.1.0.tar.gz">http://download.vacs.fr/ada-wiki/ada-wiki-1.1.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-wiki">https://github.com/stcarrez/ada-wiki</a></p><h3>Swagger Ada, Version 0.1.0</h3><ul><li>Initial implementation of Swagger OpenAPI to easily implement REST clients and servers</li></ul><p>Download: <a href="http://download.vacs.fr/swagger-ada/swagger-ada-0.1.0.tar.gz">http://download.vacs.fr/swagger-ada/swagger-ada-0.1.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/swagger-ada">https://github.com/stcarrez/swagger-ada</a></p><h3>Dynamo, Version 0.9.0</h3><ul><li>New type ASF.Parts.Part in the Dynamo UML model</li><li>Add support to generate ASF Upload method in UML Ada beans</li><li>Add support to generate AWA event actions</li><li>Generate JSON/XML serialization code for UML classes</li><li>Update the 'create-database' command to support SQLite</li><li>Fix model generation for multiple primary keys per table</li><li>Add support for <exclude> patterns in the dist command</li><li>Add support for YAML database model files</li></ul><p>Download: <a href="http://download.vacs.fr/dynamo/dynamo-0.9.0.tar.gz">http://download.vacs.fr/dynamo/dynamo-0.9.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/dynamo">https://github.com/stcarrez/dynamo</a></p><h3>AWA, Version 1.1.0</h3><ul><li>New trumbowyg plugin for WYSIWYG Javascript editor</li><li>New setup plugin for AWA application setup</li><li>Moved the samples to a separate project</li><li>New wiki plugin to write online wiki-based documentation</li><li>New flotcharts plugin to integraph jQuery Flot to display various graphs</li><li>Improvement of configure, build and installation with gprinstall when available</li><li>New counter plugin to track wiki page and blog post reads</li><li>Moved the wiki engine to Ada Wiki library</li><li>Support to display images in blog post</li><li>New image selector for wiki and blog post editors</li><li>Add a programmer's guide</li></ul><p>Download: <a href="http://download.vacs.fr/ada-awa/ada-awa-1.1.0.tar.gz">http://download.vacs.fr/ada-awa/ada-awa-1.1.0.tar.gz</a></p><p>GitHub: <a href="https://github.com/stcarrez/ada-awa">https://github.com/stcarrez/ada-awa</a></p><p>All these Ada projects can be downloaded individually but they are also packaged together to help in their download and build process. You can also download everything at <a href="http://download.vacs.fr/ada-awa/awa-all-1.1.0.tar.gz">http://download.vacs.fr/ada-awa/awa-all-1.1.0.tar.gz</a></p><p>After downloading the <a href="http://download.vacs.fr/ada-awa/awa-all-1.1.0.tar.gz">awa-all-1.1.0.tar.gz</a> package, have a look at the <a href="http://ada-awa.readthedocs.io/en/latest/">Ada Web Application Programmer's Guide</a> to learn how to build, install and start using all this.</p><p>If you don't have time to build all this, a docker container is available: <a href="https://hub.docker.com/r/ciceron/ada-awa/">https://hub.docker.com/r/ciceron/ada-awa/</a></p></div> New releases for Ada Util, Ada EL, Ada Security, Ada Database Objects, Ada Server Faces, Dynamourn:md5:d75b63a536405863b31ee59b83c5b15a2015-12-30T22:00:00+00:002015-12-30T22:00:00+00:00Stephane CarrezAdarelease
<div class="post-text"><h3>Ada Utility Library, Version 1.8.0</h3><ul><li>Added support for immediate flush and file appending to the file logger</li><li>Added support for RFC7231/RFC2616 date conversion</li><li>Improvement of configure and installation process with gprinstall (if available)</li><li>Added file system stat/fstat support</li><li>Use gcc intrinsics for atomic counters (Intel, Arm)</li></ul><p>Download: <a href="http://download.vacs.fr/ada-util/ada-util-1.8.0.tar.gz">http://download.vacs.fr/ada-util/ada-util-1.8.0.tar.gz</a><br>GitHub: <a href="https://github.com/stcarrez/ada-util">https://github.com/stcarrez/ada-util</a></p><h3>Ada EL, Version 1.6.0</h3><ul><li>Added support for thread local EL context</li><li>Improvement of configure and installation process with gprinstall (if available)</li></ul><p>Download: <a href="http://download.vacs.fr/ada-el/ada-el-1.6.0.tar.gz">http://download.vacs.fr/ada-el/ada-el-1.6.0.tar.gz</a><br>GitHub: <a href="https://github.com/stcarrez/ada-el">https://github.com/stcarrez/ada-el</a></p><h3>Ada Security, Version 1.1.2</h3><ul><li>Improvement of configure and installation process with gprinstall (if available)</li></ul><p>Download: <a href="http://download.vacs.fr/ada-security/ada-security-1.1.2.tar.gz">http://download.vacs.fr/ada-security/ada-security-1.1.2.tar.gz</a><br>GitHub: <a href="https://github.com/stcarrez/ada-security">https://github.com/stcarrez/ada-security</a></p><h3>Ada Database Objects, Version 1.1.0</h3><ul><li>Fix link issue on Fedora</li><li>Detect MariaDB as a replacement for MySQL</li><li>Improvement of configure and installation process with gprinstall (if available)</li></ul><p>Download: <a href="http://download.vacs.fr/ada-ado/ada-ado-1.1.0.tar.gz">http://download.vacs.fr/ada-ado/ada-ado-1.1.0.tar.gz</a><br>GitHub: <a href="https://github.com/stcarrez/ada-ado">https://github.com/stcarrez/ada-ado</a></p><h3>Ada Server Faces, Version 1.1.0</h3><ul><li>New EL function util:formatDate</li><li>New request route mapping with support for URL component extraction and parameter injection in Ada beans</li><li>Improvement of configure, build and installation with gprinstall when available</li><li>Integrate jQuery 1.11.3 and jQuery UI 1.11.4</li><li>Integrate jQuery Chosen 1.4.2</li><li>New component <w:chosen> for the Chosen support</li><li>Added a servlet cache control filter</li></ul><p>Download: <a href="http://download.vacs.fr/ada-asf/ada-asf-1.1.0.tar.gz">http://download.vacs.fr/ada-asf/ada-asf-1.1.0.tar.gz</a><br>GitHub: <a href="https://github.com/stcarrez/ada-asf">https://github.com/stcarrez/ada-asf</a></p><h3>Dynamo, Version 0.8.0</h3><ul><li>Support to generate Markdown documentation</li><li>Support to generate query Ada bean operations</li><li>Better code generation and support for UML Ada beans</li></ul><p>Download: <a href="http://download.vacs.fr/dynamo/dynamo-0.8.0.tar.gz">http://download.vacs.fr/dynamo/dynamo-0.8.0.tar.gz</a><br>GitHub: <a href="https://github.com/stcarrez/dynamo">https://github.com/stcarrez/dynamo</a></p></div> Ada BFD 1.1.0 is availableurn:md5:db12f172ade35c17c3e28dc974c1fac62015-05-16T13:31:00+00:002015-05-16T13:31:00+00:00Stephane CarrezreleaseCOFFELFbinutils
<div class="post-text"><p>I've added the support to the GNU demangler so that it is now possible to demangle symbols. You can demangle C++, Java and Ada symbols. To use the demangler you need a BFD file which is a limited type.</p><pre><code class="lang-ada">with Bfd.Files;
with Bfd.Symbols;
...
File : Bfd.Files.File_Type;
</code></pre><p>The BFD file is opened as follows:</p><pre><code class="lang-ada"> Bfd.Files.Open (File, Path, "");
</code></pre><p>Then, you may convert any symbol name using the <code>Demangle</code> function:</p><pre><code class="lang-ada"> Name : String := Bfd.Symbols.Demangle (File, "bfd__symbols__get_name",
Constants.DMGL_GNAT);
</code></pre><p>Sources are now moved to GitHub: <a href="https://github.com/stcarrez/ada-bfd">https://github.com/stcarrez/ada-bfd</a></p><p>You can download the release at: <a href="http://download.vacs.fr/ada-bfd/ada-bfd-1.1.0.tar.gz">http://download.vacs.fr/ada-bfd/ada-bfd-1.1.0.tar.gz</a></p></div> Ada BFD 1.0.1 is availableurn:md5:f6fe870b3f286a5697e740034e27b4a72014-12-24T15:51:43+00:002014-12-24T15:51:43+00:00Stephane CarrezreleaseCOFFELFbinutils
<div class="post-text"><p>Ada BFD is an Ada binding for the <a href="http://www.gnu.org/software/binutils/">GNU Binutils BFD</a> library.</p><p>It allows to read binary ELF, COFF files by using the GNU BFD and allows your program to read ELF sections, get access to the symbol table and use the disassembler.</p><p>The new version fixes build and compilation issues with recent releases of GNU Binutils and it also provides support to build Debian packages.</p><p><a href="http://download.vacs.fr/ada-bfd/ada-bfd-1.0.1.tar.gz">http://download.vacs.fr/ada-bfd/ada-bfd-1.0.1.tar.gz</a></p></div> Ada Web Application 1.0.0 is availableurn:md5:dfe48f23f439d5e7555e65c2fbef001c2014-07-27T17:59:44+00:002014-07-27T17:59:44+00:00Stephane CarrezAdarelease
<div class="post-text"><p><a href="http://code.google.com/p/ada-awa/">Ada Web Application</a> is a framework to build web applications.</p><p>The new version of AWA provides:</p><ul><li>New countries plugin to provide country/region/city data models</li><li>New settings plugin to control application user settings</li><li>New tags plugin to easily add tags in applications</li><li>New <code><awa:tagList></code> and <code><awa:tagCloud></code> components for tag display</li><li>Add tags to the question and blog plugins</li><li>Add comments to the blog post</li></ul><p>AWA can be downloaded at <a href="http://blog.vacs.fr/vacs/download.html">http://blog.vacs.fr/vacs/download.html</a></p><p>A live demonstration of various features provided by AWA is available at <a href="http://demo.vacs.fr/atlas">http://demo.vacs.fr/atlas</a></p><p>A small <a href="https://code.google.com/p/ada-awa/wiki/Tutorial">tutorial</a> explains how you can easily setup a project, design the UML model, and use the features provided by the <a href="http://code.google.com/p/ada-awa/">Ada Web Application</a> framework.</p></div> New releases available for Ada Utility, Ada EL, Ada Security, Ada Server Faces, ADO, Dynamourn:md5:116d2f2bcdfd66686715481de04479a22014-07-27T14:48:28+00:002014-07-27T14:48:28+00:00Stephane CarrezAdarelease
<div class="post-text"><p>A maintenance release is available for the following Ada packages:</p><h2>Ada Utility Library: Version 1.7.1</h2><ul><li>Support XmlAda 2014</li><li>Fixed Get_Week_Start/Get_Week_End when the system timezone is different than the asked timezone</li></ul><p>Download: <a href="http://download.vacs.fr/ada-util/ada-util-1.7.1.tar.gz">http://download.vacs.fr/ada-util/ada-util-1.7.1.tar.gz</a></p><h3>Ada EL: Version 1.5.1</h3><ul><li>Fix minor configuration issue with GNAT 2014</li></ul><p>Download: <a href="http://download.vacs.fr/ada-el/ada-el-1.5.1.tar.gz">http://download.vacs.fr/ada-el/ada-el-1.5.1.tar.gz</a></p><h3>Ada Security: Version 1.1.1</h3><ul><li>Fix minor configuration issue with GNAT 2014</li></ul><p>Download: <a href="http://download.vacs.fr/ada-security/ada-security-1.1.1.tar.gz">http://download.vacs.fr/ada-security/ada-security-1.1.1.tar.gz</a></p><h3>Ada Server Faces: Version 1.0.1</h3><ul><li>Fix minor configuration issue with GNAT 2014</li><li>Fix concurrent issues in facelet and session cache implementation</li></ul><p>Download: <a href="http://download.vacs.fr/ada-asf/ada-asf-1.0.1.tar.gz">http://download.vacs.fr/ada-asf/ada-asf-1.0.1.tar.gz</a></p><h3>Ada Database Objects: Version 1.0.1</h3><ul><li>Fix minor configuration issue with GNAT 2014</li></ul><p>Download: <a href="http://download.vacs.fr/ada-ado/ada-ado-1.0.1.tar.gz">http://download.vacs.fr/ada-ado/ada-ado-1.0.1.tar.gz</a></p><h3>Dynamo: Version 0.7.1</h3><ul><li>Fix minor configuration issue with GNAT 2014</li></ul><p>Download: <a href="http://download.vacs.fr/dynamo/dynamo-0.7.1.tar.gz">http://download.vacs.fr/dynamo/dynamo-0.7.1.tar.gz</a></p></div> Dynamo 0.7.0 is availableurn:md5:0c85b61b2cf36654e04ed478a2e7504f2014-05-12T19:28:07+00:002014-05-12T19:28:07+00:00Stephane CarrezreleaseAdaMDEUMLgenerator
<div class="post-text"><p><a href="https://code.google.com/p/ada-gen/">Dynamo</a> is a code generator used to generate <a href="https://code.google.com/p/ada-gen/">Ada Web Application</a> or database mappings.</p><ul><li>New project template to generate Gtk Ada application</li><li>Register the new module in the application when they are added</li><li>Update the current testsuite when new tests are added</li><li>New stereotype for Ada bean generation</li><li>Support for the creation of Debian packages</li><li>New command <code>add-form</code> and <code>add-module-operation</code></li></ul><p>You can download the new version at <a href="http://download.vacs.fr/dynamo/dynamo-0.7.0.tar.gz">http://download.vacs.fr/dynamo/dynamo-0.7.0.tar.gz</a></p></div> Ada Database Objects 1.0.0 is availableurn:md5:f3a71ec86752c66e0669b9f18b5e1f9c2014-04-27T15:52:00+00:002014-04-27T15:52:00+00:00Stephane CarrezAdarelease
<div class="post-text"><p>From a <a href="http://en.wikipedia.org/wiki/Unified_Modeling_Language">UML</a> class diagram model, the <a href="https://code.google.com/p/ada-gen/">Dynamo</a> code generator generates the Ada mapping files for UML classes. A UML class represents a database table and the generator defines an Ada tagged record in the mapping file to give access to the table. Saving a database record is as simple as invoking the <code>Set</code> procedure generated for each class attribute and calling the <code>Save</code> operation to persist the record in the database.</p><pre><code class="lang-ada">with Samples.User.Model;
with ADO.Sessions;
...
DB : ADO.Sessions.Master_Session
User : Samples.User.Model.User_Ref;
...
User.Set_Name (Name);
User.Set_Email (Email);
User.Set_Description ("My friend " & Name);
User.Set_Status (0);
User.Save (DB);
</code></pre><p>The version 1.0.0 of the library brings the following improvements:</p><ul><li>Support to load query results in Ada bean datasets</li><li>Added support to load dynamic database drivers</li><li>Port on FreeBSD</li><li>Support for the creation of Debian packages</li></ul><p>Debian packages are provided in the <a href="http://apt.vacs.fr/ubuntu-raring">http://apt.vacs.fr/ubuntu-raring</a> and <a href="http://apt.vacs.fr/ubuntu-precise">http://apt.vacs.fr/ubuntu-precise</a> repository.</p><p>You can download the new version at <a href="http://download.vacs.fr/ada-ado/ada-ado-1.0.0.tar.gz">http://download.vacs.fr/ada-ado/ada-ado-1.0.0.tar.gz</a></p></div> Ada Server Faces 1.0.0 is availableurn:md5:2580f0269f372e3ce10301fe392b48342014-04-05T19:30:53+00:002014-04-05T19:30:53+00:00Stephane CarrezAdarelease
<div class="post-text"><p>Ada Server Faces is a framework that allows to create Web applications using the same design patterns as the Java Server Faces (See JSR 252, JSR 314, or JSR 344). The presentation pages benefit from the <a href="http://en.wikipedia.org/wiki/Facelets">Facelets</a> <a href="http://en.wikipedia.org/wiki/Web_template_system">Web template system</a> and the runtime takes advantages of the Ada language safety and performance.</p><p>A new release is available with several features that help writing online applications:</p><ul><li>Add support for Facebook and Google+ login</li><li>Javascript support for popup and editable fields</li><li>Added support to enable/disable mouseover effect in lists</li><li>New EL function util:iso8601</li><li>New component <w:autocomplete> for input text with autocompletion</li><li>New component <w:gravatar> to render a gravatar image</li><li>New component <w:like> to render a Facebook, Twitter or Google+ like button</li><li>New component <w:panel> to provide collapsible div panels</li><li>New components <w:tabView> and <w:tab> for tabs display</li><li>New component <w:accordion> to display accordion tabs</li><li>Add support for JSF <f:facet>, <f:convertDateTime>, <h:doctype></li><li>Support for the creation of Debian packages</li></ul><p>You can try the <a href="http://demo.vacs.fr/demo/widgets/view.html">online demonstration</a> of the new widget components and download this new release at <a href="http://download.vacs.fr/ada-asf/ada-asf-1.0.0.tar.gz">http://download.vacs.fr/ada-asf/ada-asf-1.0.0.tar.gz</a></p></div>