Merge branch 'upstream' into debian
[moonshot-ui.git] / src / moonshot-webp-parser.c
diff --git a/src/moonshot-webp-parser.c b/src/moonshot-webp-parser.c
new file mode 100644 (file)
index 0000000..746012a
--- /dev/null
@@ -0,0 +1,1089 @@
+/* moonshot-webp-parser.c generated by valac 0.34.9, the Vala compiler
+ * generated from moonshot-webp-parser.vala, do not modify */
+
+/*
+ * Copyright (c) 2011-2016, JANET(UK)
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * 3. Neither the name of JANET(UK) nor the names of its contributors
+ *    may be used to endorse or promote products derived from this software
+ *    without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+*/
+
+#include <glib.h>
+#include <glib-object.h>
+#include <stdlib.h>
+#include <string.h>
+#include <stdio.h>
+#include <glib/gi18n-lib.h>
+#include <glib/gstdio.h>
+#include <libmoonshot.h>
+#include <gee.h>
+
+
+#define TYPE_MOONSHOT_LOGGER (moonshot_logger_get_type ())
+#define MOONSHOT_LOGGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_MOONSHOT_LOGGER, MoonshotLogger))
+#define MOONSHOT_LOGGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_MOONSHOT_LOGGER, MoonshotLoggerClass))
+#define IS_MOONSHOT_LOGGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_MOONSHOT_LOGGER))
+#define IS_MOONSHOT_LOGGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_MOONSHOT_LOGGER))
+#define MOONSHOT_LOGGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_MOONSHOT_LOGGER, MoonshotLoggerClass))
+
+typedef struct _MoonshotLogger MoonshotLogger;
+typedef struct _MoonshotLoggerClass MoonshotLoggerClass;
+#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
+#define _g_free0(var) (var = (g_free (var), NULL))
+
+#define WEB_PROVISIONING_TYPE_PARSER (web_provisioning_parser_get_type ())
+#define WEB_PROVISIONING_PARSER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), WEB_PROVISIONING_TYPE_PARSER, WebProvisioningParser))
+#define WEB_PROVISIONING_PARSER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), WEB_PROVISIONING_TYPE_PARSER, WebProvisioningParserClass))
+#define WEB_PROVISIONING_IS_PARSER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), WEB_PROVISIONING_TYPE_PARSER))
+#define WEB_PROVISIONING_IS_PARSER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), WEB_PROVISIONING_TYPE_PARSER))
+#define WEB_PROVISIONING_PARSER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), WEB_PROVISIONING_TYPE_PARSER, WebProvisioningParserClass))
+
+typedef struct _WebProvisioningParser WebProvisioningParser;
+typedef struct _WebProvisioningParserClass WebProvisioningParserClass;
+
+#define TYPE_ID_CARD (id_card_get_type ())
+#define ID_CARD(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_ID_CARD, IdCard))
+#define ID_CARD_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_ID_CARD, IdCardClass))
+#define IS_ID_CARD(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_ID_CARD))
+#define IS_ID_CARD_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_ID_CARD))
+#define ID_CARD_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_ID_CARD, IdCardClass))
+
+typedef struct _IdCard IdCard;
+typedef struct _IdCardClass IdCardClass;
+
+#define TYPE_RULE (rule_get_type ())
+typedef struct _Rule Rule;
+
+#define TYPE_TRUST_ANCHOR (trust_anchor_get_type ())
+#define TRUST_ANCHOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_TRUST_ANCHOR, TrustAnchor))
+#define TRUST_ANCHOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_TRUST_ANCHOR, TrustAnchorClass))
+#define IS_TRUST_ANCHOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_TRUST_ANCHOR))
+#define IS_TRUST_ANCHOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_TRUST_ANCHOR))
+#define TRUST_ANCHOR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_TRUST_ANCHOR, TrustAnchorClass))
+
+typedef struct _TrustAnchor TrustAnchor;
+typedef struct _TrustAnchorClass TrustAnchorClass;
+#define _moonshot_error_free0(var) ((var == NULL) ? NULL : (var = (moonshot_error_free (var), NULL)))
+
+struct _Rule {
+       gchar* pattern;
+       gchar* always_confirm;
+};
+
+
+extern MoonshotLogger* web_provisioning_logger;
+MoonshotLogger* web_provisioning_logger = NULL;
+
+GType moonshot_logger_get_type (void) G_GNUC_CONST;
+gint web_provisioning_main (gchar** args, int args_length1);
+MoonshotLogger* moonshot_logger_new (const gchar* name);
+MoonshotLogger* moonshot_logger_construct (GType object_type, const gchar* name);
+GType web_provisioning_parser_get_type (void) G_GNUC_CONST;
+WebProvisioningParser* web_provisioning_parser_new (const gchar* path);
+WebProvisioningParser* web_provisioning_parser_construct (GType object_type, const gchar* path);
+void web_provisioning_parser_parse (WebProvisioningParser* self);
+void moonshot_logger_trace (MoonshotLogger* self, const gchar* message, GError* e);
+GType id_card_get_type (void) G_GNUC_CONST;
+IdCard** web_provisioning_parser_get_cards (WebProvisioningParser* self, int* result_length1);
+GType rule_get_type (void) G_GNUC_CONST;
+Rule* rule_dup (const Rule* self);
+void rule_free (Rule* self);
+void rule_copy (const Rule* self, Rule* dest);
+void rule_destroy (Rule* self);
+Rule* id_card_get_rules (IdCard* self, int* result_length1);
+static Rule* _vala_array_dup1 (Rule* self, int length);
+GeeArrayList* id_card_get_services (IdCard* self);
+const gchar* id_card_get_display_name (IdCard* self);
+const gchar* id_card_get_username (IdCard* self);
+const gchar* id_card_get_password (IdCard* self);
+const gchar* id_card_get_issuer (IdCard* self);
+GType trust_anchor_get_type (void) G_GNUC_CONST;
+TrustAnchor* id_card_get_trust_anchor (IdCard* self);
+const gchar* trust_anchor_get_ca_cert (TrustAnchor* self);
+const gchar* trust_anchor_get_subject (TrustAnchor* self);
+const gchar* trust_anchor_get_subject_alt (TrustAnchor* self);
+const gchar* trust_anchor_get_server_cert (TrustAnchor* self);
+static void _vala_Rule_array_free (Rule* array, gint array_length);
+static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func);
+static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func);
+
+
+static gunichar string_get_char (const gchar* self, glong index) {
+       gunichar result = 0U;
+       glong _tmp0_ = 0L;
+       gunichar _tmp1_ = 0U;
+#line 1124 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
+       g_return_val_if_fail (self != NULL, 0U);
+#line 1125 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
+       _tmp0_ = index;
+#line 1125 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
+       _tmp1_ = g_utf8_get_char (((gchar*) self) + _tmp0_);
+#line 1125 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
+       result = _tmp1_;
+#line 1125 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
+       return result;
+#line 151 "moonshot-webp-parser.c"
+}
+
+
+static gpointer _g_object_ref0 (gpointer self) {
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       return self ? g_object_ref (self) : NULL;
+#line 158 "moonshot-webp-parser.c"
+}
+
+
+static Rule* _vala_array_dup1 (Rule* self, int length) {
+       Rule* result;
+       int i;
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       result = g_new0 (Rule, length);
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       for (i = 0; i < length; i++) {
+#line 169 "moonshot-webp-parser.c"
+               Rule _tmp0_ = {0};
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               rule_copy (&self[i], &_tmp0_);
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               result[i] = _tmp0_;
+#line 175 "moonshot-webp-parser.c"
+       }
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       return result;
+#line 179 "moonshot-webp-parser.c"
+}
+
+
+static const gchar* string_to_string (const gchar* self) {
+       const gchar* result = NULL;
+#line 1420 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
+       g_return_val_if_fail (self != NULL, NULL);
+#line 1421 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
+       result = self;
+#line 1421 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
+       return result;
+#line 191 "moonshot-webp-parser.c"
+}
+
+
+static void _vala_Rule_array_free (Rule* array, gint array_length) {
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       if (array != NULL) {
+#line 198 "moonshot-webp-parser.c"
+               int i;
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               for (i = 0; i < array_length; i = i + 1) {
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       rule_destroy (&array[i]);
+#line 204 "moonshot-webp-parser.c"
+               }
+       }
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       g_free (array);
+#line 209 "moonshot-webp-parser.c"
+}
+
+
+gint web_provisioning_main (gchar** args, int args_length1) {
+       gint result = 0;
+       MoonshotLogger* _tmp0_ = NULL;
+       gint arg_index = 0;
+       gint force_flat_file_store = 0;
+       gboolean bad_switch = FALSE;
+       gboolean _tmp18_ = FALSE;
+       gboolean _tmp19_ = FALSE;
+       gchar* webp_file = NULL;
+       gchar** _tmp26_ = NULL;
+       gint _tmp26__length1 = 0;
+       gint _tmp27_ = 0;
+       const gchar* _tmp28_ = NULL;
+       gchar* _tmp29_ = NULL;
+       const gchar* _tmp30_ = NULL;
+       gboolean _tmp31_ = FALSE;
+       WebProvisioningParser* webp = NULL;
+       const gchar* _tmp35_ = NULL;
+       WebProvisioningParser* _tmp36_ = NULL;
+       WebProvisioningParser* _tmp37_ = NULL;
+       MoonshotLogger* _tmp38_ = NULL;
+       WebProvisioningParser* _tmp39_ = NULL;
+       IdCard** _tmp40_ = NULL;
+       gint _tmp40__length1 = 0;
+       IdCard** _tmp41_ = NULL;
+       gint _tmp41__length1 = 0;
+       gchar* _tmp42_ = NULL;
+       gchar* _tmp43_ = NULL;
+       gchar* _tmp44_ = NULL;
+       gchar* _tmp45_ = NULL;
+       WebProvisioningParser* _tmp46_ = NULL;
+       IdCard** _tmp47_ = NULL;
+       gint _tmp47__length1 = 0;
+       IdCard** _tmp48_ = NULL;
+       gint _tmp48__length1 = 0;
+#line 40 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp0_ = moonshot_logger_new ("WebProvisioning (WebpParser)");
+#line 40 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _g_object_unref0 (web_provisioning_logger);
+#line 40 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       web_provisioning_logger = _tmp0_;
+#line 42 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       arg_index = -1;
+#line 43 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       force_flat_file_store = 0;
+#line 44 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       bad_switch = FALSE;
+#line 260 "moonshot-webp-parser.c"
+       {
+               gboolean _tmp1_ = FALSE;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               arg_index = 1;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp1_ = TRUE;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               while (TRUE) {
+#line 269 "moonshot-webp-parser.c"
+                       gint _tmp3_ = 0;
+                       gchar** _tmp4_ = NULL;
+                       gint _tmp4__length1 = 0;
+                       gchar* arg = NULL;
+                       gchar** _tmp5_ = NULL;
+                       gint _tmp5__length1 = 0;
+                       gint _tmp6_ = 0;
+                       const gchar* _tmp7_ = NULL;
+                       gchar* _tmp8_ = NULL;
+                       gunichar c = 0U;
+                       const gchar* _tmp9_ = NULL;
+                       gunichar _tmp10_ = 0U;
+                       gunichar _tmp11_ = 0U;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       if (!_tmp1_) {
+#line 285 "moonshot-webp-parser.c"
+                               gint _tmp2_ = 0;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp2_ = arg_index;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               arg_index = _tmp2_ + 1;
+#line 291 "moonshot-webp-parser.c"
+                       }
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp1_ = FALSE;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp3_ = arg_index;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp4_ = args;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp4__length1 = args_length1;
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       if (!(_tmp3_ < _tmp4__length1)) {
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               break;
+#line 305 "moonshot-webp-parser.c"
+                       }
+#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp5_ = args;
+#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp5__length1 = args_length1;
+#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp6_ = arg_index;
+#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp7_ = _tmp5_[_tmp6_];
+#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp8_ = g_strdup (_tmp7_);
+#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       arg = _tmp8_;
+#line 47 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp9_ = arg;
+#line 47 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp10_ = string_get_char (_tmp9_, (glong) 0);
+#line 47 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       c = _tmp10_;
+#line 48 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp11_ = c;
+#line 48 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       if (_tmp11_ == ((gunichar) '-')) {
+#line 329 "moonshot-webp-parser.c"
+                               const gchar* _tmp12_ = NULL;
+                               const gchar* _tmp13_ = NULL;
+                               gchar* _tmp14_ = NULL;
+                               const gchar* _tmp15_ = NULL;
+                               gunichar _tmp16_ = 0U;
+                               gunichar _tmp17_ = 0U;
+#line 49 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp12_ = arg;
+#line 49 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp13_ = g_utf8_next_char (_tmp12_);
+#line 49 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp14_ = g_strdup (_tmp13_);
+#line 49 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _g_free0 (arg);
+#line 49 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               arg = _tmp14_;
+#line 50 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp15_ = arg;
+#line 50 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp16_ = string_get_char (_tmp15_, (glong) 0);
+#line 50 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               c = _tmp16_;
+#line 51 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp17_ = c;
+#line 51 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               switch (_tmp17_) {
+#line 51 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       case 'f':
+#line 358 "moonshot-webp-parser.c"
+                                       {
+#line 53 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               force_flat_file_store = 1;
+#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               break;
+#line 364 "moonshot-webp-parser.c"
+                                       }
+                                       default:
+                                       {
+#line 56 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               bad_switch = TRUE;
+#line 57 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               break;
+#line 372 "moonshot-webp-parser.c"
+                                       }
+                               }
+                       } else {
+#line 60 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _g_free0 (arg);
+#line 60 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               break;
+#line 380 "moonshot-webp-parser.c"
+                       }
+#line 45 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _g_free0 (arg);
+#line 384 "moonshot-webp-parser.c"
+               }
+       }
+#line 63 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp19_ = bad_switch;
+#line 63 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       if (_tmp19_) {
+#line 63 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp18_ = TRUE;
+#line 393 "moonshot-webp-parser.c"
+       } else {
+               gint _tmp20_ = 0;
+               gchar** _tmp21_ = NULL;
+               gint _tmp21__length1 = 0;
+#line 63 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp20_ = arg_index;
+#line 63 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp21_ = args;
+#line 63 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp21__length1 = args_length1;
+#line 63 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp18_ = _tmp20_ != (_tmp21__length1 - 1);
+#line 406 "moonshot-webp-parser.c"
+       }
+#line 63 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       if (_tmp18_) {
+#line 410 "moonshot-webp-parser.c"
+               FILE* _tmp22_ = NULL;
+               const gchar* _tmp23_ = NULL;
+               gchar** _tmp24_ = NULL;
+               gint _tmp24__length1 = 0;
+               const gchar* _tmp25_ = NULL;
+#line 65 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp22_ = stdout;
+#line 65 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp23_ = _ ("Usage %s [-f] WEB_PROVISIONING_FILE\n" \
+" -f: add identities to flat file store.\n");
+#line 65 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp24_ = args;
+#line 65 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp24__length1 = args_length1;
+#line 65 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp25_ = _tmp24_[0];
+#line 65 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               fprintf (_tmp22_, _tmp23_, _tmp25_);
+#line 66 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               result = -1;
+#line 66 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               return result;
+#line 432 "moonshot-webp-parser.c"
+       }
+#line 68 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp26_ = args;
+#line 68 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp26__length1 = args_length1;
+#line 68 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp27_ = arg_index;
+#line 68 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp28_ = _tmp26_[_tmp27_];
+#line 68 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp29_ = g_strdup (_tmp28_);
+#line 68 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       webp_file = _tmp29_;
+#line 70 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp30_ = webp_file;
+#line 70 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp31_ = g_file_test (_tmp30_, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR);
+#line 70 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       if (!_tmp31_) {
+#line 452 "moonshot-webp-parser.c"
+               FILE* _tmp32_ = NULL;
+               const gchar* _tmp33_ = NULL;
+               const gchar* _tmp34_ = NULL;
+#line 72 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp32_ = stdout;
+#line 72 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp33_ = _ ("%s does not exist\n");
+#line 72 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _tmp34_ = webp_file;
+#line 72 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               fprintf (_tmp32_, _tmp33_, _tmp34_);
+#line 73 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               result = -1;
+#line 73 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               _g_free0 (webp_file);
+#line 73 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               return result;
+#line 470 "moonshot-webp-parser.c"
+       }
+#line 76 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp35_ = webp_file;
+#line 76 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp36_ = web_provisioning_parser_new (_tmp35_);
+#line 76 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       webp = _tmp36_;
+#line 77 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp37_ = webp;
+#line 77 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       web_provisioning_parser_parse (_tmp37_);
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp38_ = web_provisioning_logger;
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp39_ = webp;
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp40_ = web_provisioning_parser_get_cards (_tmp39_, &_tmp40__length1);
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp41_ = _tmp40_;
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp41__length1 = _tmp40__length1;
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp42_ = g_strdup_printf ("%i", _tmp41__length1);
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp43_ = _tmp42_;
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp44_ = g_strconcat ("Have ", _tmp43_, " IdCards", NULL);
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp45_ = _tmp44_;
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       moonshot_logger_trace (_tmp38_, _tmp45_, NULL);
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _g_free0 (_tmp45_);
+#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _g_free0 (_tmp43_);
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp46_ = webp;
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp47_ = web_provisioning_parser_get_cards (_tmp46_, &_tmp47__length1);
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp48_ = _tmp47_;
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _tmp48__length1 = _tmp47__length1;
+#line 514 "moonshot-webp-parser.c"
+       {
+               IdCard** card_collection = NULL;
+               gint card_collection_length1 = 0;
+               gint _card_collection_size_ = 0;
+               gint card_it = 0;
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               card_collection = _tmp48_;
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               card_collection_length1 = _tmp48__length1;
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+               for (card_it = 0; card_it < _tmp48__length1; card_it = card_it + 1) {
+#line 526 "moonshot-webp-parser.c"
+                       IdCard* _tmp49_ = NULL;
+                       IdCard* card = NULL;
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       _tmp49_ = _g_object_ref0 (card_collection[card_it]);
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                       card = _tmp49_;
+#line 533 "moonshot-webp-parser.c"
+                       {
+                               IdCard* _tmp50_ = NULL;
+                               MoonshotError* _error_ = NULL;
+                               gchar** rules_patterns = NULL;
+                               gchar** _tmp52_ = NULL;
+                               gint rules_patterns_length1 = 0;
+                               gint _rules_patterns_size_ = 0;
+                               gchar** rules_always_confirm = NULL;
+                               gchar** _tmp53_ = NULL;
+                               gint rules_always_confirm_length1 = 0;
+                               gint _rules_always_confirm_size_ = 0;
+                               Rule* rules = NULL;
+                               IdCard* _tmp54_ = NULL;
+                               Rule* _tmp55_ = NULL;
+                               gint _tmp55__length1 = 0;
+                               Rule* _tmp56_ = NULL;
+                               gint _tmp56__length1 = 0;
+                               Rule* _tmp57_ = NULL;
+                               gint _tmp57__length1 = 0;
+                               gint rules_length1 = 0;
+                               gint _rules_size_ = 0;
+                               gchar** svcs = NULL;
+                               IdCard* _tmp58_ = NULL;
+                               GeeArrayList* _tmp59_ = NULL;
+                               GeeArrayList* _tmp60_ = NULL;
+                               gint _tmp61_ = 0;
+                               gint _tmp62_ = 0;
+                               gchar** _tmp63_ = NULL;
+                               gint svcs_length1 = 0;
+                               gint _svcs_size_ = 0;
+                               Rule* _tmp80_ = NULL;
+                               gint _tmp80__length1 = 0;
+                               MoonshotLogger* _tmp100_ = NULL;
+                               IdCard* _tmp101_ = NULL;
+                               const gchar* _tmp102_ = NULL;
+                               const gchar* _tmp103_ = NULL;
+                               const gchar* _tmp104_ = NULL;
+                               gchar* _tmp105_ = NULL;
+                               gchar* _tmp106_ = NULL;
+                               IdCard* _tmp107_ = NULL;
+                               const gchar* _tmp108_ = NULL;
+                               const gchar* _tmp109_ = NULL;
+                               IdCard* _tmp110_ = NULL;
+                               const gchar* _tmp111_ = NULL;
+                               const gchar* _tmp112_ = NULL;
+                               IdCard* _tmp113_ = NULL;
+                               const gchar* _tmp114_ = NULL;
+                               const gchar* _tmp115_ = NULL;
+                               IdCard* _tmp116_ = NULL;
+                               const gchar* _tmp117_ = NULL;
+                               const gchar* _tmp118_ = NULL;
+                               gchar** _tmp119_ = NULL;
+                               gint _tmp119__length1 = 0;
+                               gchar** _tmp120_ = NULL;
+                               gint _tmp120__length1 = 0;
+                               gchar** _tmp121_ = NULL;
+                               gint _tmp121__length1 = 0;
+                               IdCard* _tmp122_ = NULL;
+                               TrustAnchor* _tmp123_ = NULL;
+                               TrustAnchor* _tmp124_ = NULL;
+                               const gchar* _tmp125_ = NULL;
+                               const gchar* _tmp126_ = NULL;
+                               IdCard* _tmp127_ = NULL;
+                               TrustAnchor* _tmp128_ = NULL;
+                               TrustAnchor* _tmp129_ = NULL;
+                               const gchar* _tmp130_ = NULL;
+                               const gchar* _tmp131_ = NULL;
+                               IdCard* _tmp132_ = NULL;
+                               TrustAnchor* _tmp133_ = NULL;
+                               TrustAnchor* _tmp134_ = NULL;
+                               const gchar* _tmp135_ = NULL;
+                               const gchar* _tmp136_ = NULL;
+                               IdCard* _tmp137_ = NULL;
+                               TrustAnchor* _tmp138_ = NULL;
+                               TrustAnchor* _tmp139_ = NULL;
+                               const gchar* _tmp140_ = NULL;
+                               const gchar* _tmp141_ = NULL;
+                               gint _tmp142_ = 0;
+                               MoonshotError* _tmp143_ = NULL;
+                               MoonshotError* _tmp144_ = NULL;
+#line 82 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp50_ = card;
+#line 82 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               if (_tmp50_ == NULL) {
+#line 618 "moonshot-webp-parser.c"
+                                       MoonshotLogger* _tmp51_ = NULL;
+#line 83 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp51_ = web_provisioning_logger;
+#line 83 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       moonshot_logger_trace (_tmp51_, "Skipping null IdCard", NULL);
+#line 84 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _g_object_unref0 (card);
+#line 84 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       continue;
+#line 628 "moonshot-webp-parser.c"
+                               }
+#line 88 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp52_ = g_new0 (gchar*, 0 + 1);
+#line 88 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules_patterns = _tmp52_;
+#line 88 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules_patterns_length1 = 0;
+#line 88 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _rules_patterns_size_ = rules_patterns_length1;
+#line 89 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp53_ = g_new0 (gchar*, 0 + 1);
+#line 89 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules_always_confirm = _tmp53_;
+#line 89 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules_always_confirm_length1 = 0;
+#line 89 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _rules_always_confirm_size_ = rules_always_confirm_length1;
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp54_ = card;
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp55_ = id_card_get_rules (_tmp54_, &_tmp55__length1);
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp56_ = _tmp55_;
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp56__length1 = _tmp55__length1;
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp57_ = (_tmp56_ != NULL) ? _vala_array_dup1 (_tmp56_, _tmp56__length1) : ((gpointer) _tmp56_);
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp57__length1 = _tmp56__length1;
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules = _tmp57_;
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules_length1 = _tmp57__length1;
+#line 92 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _rules_size_ = rules_length1;
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp58_ = card;
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp59_ = id_card_get_services (_tmp58_);
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp60_ = _tmp59_;
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp61_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp60_);
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp62_ = _tmp61_;
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp63_ = g_new0 (gchar*, _tmp62_ + 1);
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               svcs = _tmp63_;
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               svcs_length1 = _tmp62_;
+#line 93 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _svcs_size_ = svcs_length1;
+#line 682 "moonshot-webp-parser.c"
+                               {
+                                       gint i = 0;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       i = 0;
+#line 687 "moonshot-webp-parser.c"
+                                       {
+                                               gboolean _tmp64_ = FALSE;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               _tmp64_ = TRUE;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               while (TRUE) {
+#line 694 "moonshot-webp-parser.c"
+                                                       gint _tmp66_ = 0;
+                                                       IdCard* _tmp67_ = NULL;
+                                                       GeeArrayList* _tmp68_ = NULL;
+                                                       GeeArrayList* _tmp69_ = NULL;
+                                                       gint _tmp70_ = 0;
+                                                       gint _tmp71_ = 0;
+                                                       gchar** _tmp72_ = NULL;
+                                                       gint _tmp72__length1 = 0;
+                                                       gint _tmp73_ = 0;
+                                                       IdCard* _tmp74_ = NULL;
+                                                       GeeArrayList* _tmp75_ = NULL;
+                                                       GeeArrayList* _tmp76_ = NULL;
+                                                       gint _tmp77_ = 0;
+                                                       gpointer _tmp78_ = NULL;
+                                                       gchar* _tmp79_ = NULL;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       if (!_tmp64_) {
+#line 712 "moonshot-webp-parser.c"
+                                                               gint _tmp65_ = 0;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp65_ = i;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               i = _tmp65_ + 1;
+#line 718 "moonshot-webp-parser.c"
+                                                       }
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp64_ = FALSE;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp66_ = i;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp67_ = card;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp68_ = id_card_get_services (_tmp67_);
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp69_ = _tmp68_;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp70_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp69_);
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp71_ = _tmp70_;
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       if (!(_tmp66_ < _tmp71_)) {
+#line 94 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               break;
+#line 738 "moonshot-webp-parser.c"
+                                                       }
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp72_ = svcs;
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp72__length1 = svcs_length1;
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp73_ = i;
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp74_ = card;
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp75_ = id_card_get_services (_tmp74_);
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp76_ = _tmp75_;
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp77_ = i;
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp78_ = gee_abstract_list_get ((GeeAbstractList*) _tmp76_, _tmp77_);
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _g_free0 (_tmp72_[_tmp73_]);
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp72_[_tmp73_] = (gchar*) _tmp78_;
+#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       _tmp79_ = _tmp72_[_tmp73_];
+#line 762 "moonshot-webp-parser.c"
+                                               }
+                                       }
+                               }
+#line 98 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp80_ = rules;
+#line 98 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp80__length1 = rules_length1;
+#line 98 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               if (_tmp80__length1 > 0) {
+#line 772 "moonshot-webp-parser.c"
+                                       gint i = 0;
+                                       Rule* _tmp81_ = NULL;
+                                       gint _tmp81__length1 = 0;
+                                       gchar** _tmp82_ = NULL;
+                                       Rule* _tmp83_ = NULL;
+                                       gint _tmp83__length1 = 0;
+                                       gchar** _tmp84_ = NULL;
+                                       Rule* _tmp85_ = NULL;
+                                       gint _tmp85__length1 = 0;
+#line 100 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       i = 0;
+#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp81_ = rules;
+#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp81__length1 = rules_length1;
+#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp82_ = g_new0 (gchar*, _tmp81__length1 + 1);
+#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules_patterns = (_vala_array_free (rules_patterns, rules_patterns_length1, (GDestroyNotify) g_free), NULL);
+#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules_patterns = _tmp82_;
+#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules_patterns_length1 = _tmp81__length1;
+#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _rules_patterns_size_ = rules_patterns_length1;
+#line 102 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp83_ = rules;
+#line 102 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp83__length1 = rules_length1;
+#line 102 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp84_ = g_new0 (gchar*, _tmp83__length1 + 1);
+#line 102 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules_always_confirm = (_vala_array_free (rules_always_confirm, rules_always_confirm_length1, (GDestroyNotify) g_free), NULL);
+#line 102 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules_always_confirm = _tmp84_;
+#line 102 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules_always_confirm_length1 = _tmp83__length1;
+#line 102 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _rules_always_confirm_size_ = rules_always_confirm_length1;
+#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp85_ = rules;
+#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp85__length1 = rules_length1;
+#line 816 "moonshot-webp-parser.c"
+                                       {
+                                               Rule* r_collection = NULL;
+                                               gint r_collection_length1 = 0;
+                                               gint _r_collection_size_ = 0;
+                                               gint r_it = 0;
+#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               r_collection = _tmp85_;
+#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               r_collection_length1 = _tmp85__length1;
+#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                               for (r_it = 0; r_it < _tmp85__length1; r_it = r_it + 1) {
+#line 828 "moonshot-webp-parser.c"
+                                                       Rule _tmp86_ = {0};
+                                                       Rule r = {0};
+#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       rule_copy (&r_collection[r_it], &_tmp86_);
+#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                       r = _tmp86_;
+#line 835 "moonshot-webp-parser.c"
+                                                       {
+                                                               gchar** _tmp87_ = NULL;
+                                                               gint _tmp87__length1 = 0;
+                                                               gint _tmp88_ = 0;
+                                                               Rule _tmp89_ = {0};
+                                                               const gchar* _tmp90_ = NULL;
+                                                               gchar* _tmp91_ = NULL;
+                                                               gchar* _tmp92_ = NULL;
+                                                               gchar** _tmp93_ = NULL;
+                                                               gint _tmp93__length1 = 0;
+                                                               gint _tmp94_ = 0;
+                                                               Rule _tmp95_ = {0};
+                                                               const gchar* _tmp96_ = NULL;
+                                                               gchar* _tmp97_ = NULL;
+                                                               gchar* _tmp98_ = NULL;
+                                                               gint _tmp99_ = 0;
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp87_ = rules_patterns;
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp87__length1 = rules_patterns_length1;
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp88_ = i;
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp89_ = r;
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp90_ = _tmp89_.pattern;
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp91_ = g_strdup (_tmp90_);
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _g_free0 (_tmp87_[_tmp88_]);
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp87_[_tmp88_] = _tmp91_;
+#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp92_ = _tmp87_[_tmp88_];
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp93_ = rules_always_confirm;
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp93__length1 = rules_always_confirm_length1;
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp94_ = i;
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp95_ = r;
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp96_ = _tmp95_.always_confirm;
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp97_ = g_strdup (_tmp96_);
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _g_free0 (_tmp93_[_tmp94_]);
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp93_[_tmp94_] = _tmp97_;
+#line 106 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp98_ = _tmp93_[_tmp94_];
+#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               _tmp99_ = i;
+#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               i = _tmp99_ + 1;
+#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                                               rule_destroy (&r);
+#line 894 "moonshot-webp-parser.c"
+                                                       }
+                                               }
+                                       }
+                               }
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp100_ = web_provisioning_logger;
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp101_ = card;
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp102_ = id_card_get_display_name (_tmp101_);
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp103_ = _tmp102_;
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp104_ = string_to_string (_tmp103_);
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp105_ = g_strconcat ("Installing IdCard named '", _tmp104_, "'", NULL);
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp106_ = _tmp105_;
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               moonshot_logger_trace (_tmp100_, _tmp106_, NULL);
+#line 111 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _g_free0 (_tmp106_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp107_ = card;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp108_ = id_card_get_display_name (_tmp107_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp109_ = _tmp108_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp110_ = card;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp111_ = id_card_get_username (_tmp110_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp112_ = _tmp111_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp113_ = card;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp114_ = id_card_get_password (_tmp113_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp115_ = _tmp114_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp116_ = card;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp117_ = id_card_get_issuer (_tmp116_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp118_ = _tmp117_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp119_ = rules_patterns;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp119__length1 = rules_patterns_length1;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp120_ = rules_always_confirm;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp120__length1 = rules_always_confirm_length1;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp121_ = svcs;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp121__length1 = svcs_length1;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp122_ = card;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp123_ = id_card_get_trust_anchor (_tmp122_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp124_ = _tmp123_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp125_ = trust_anchor_get_ca_cert (_tmp124_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp126_ = _tmp125_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp127_ = card;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp128_ = id_card_get_trust_anchor (_tmp127_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp129_ = _tmp128_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp130_ = trust_anchor_get_subject (_tmp129_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp131_ = _tmp130_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp132_ = card;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp133_ = id_card_get_trust_anchor (_tmp132_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp134_ = _tmp133_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp135_ = trust_anchor_get_subject_alt (_tmp134_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp136_ = _tmp135_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp137_ = card;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp138_ = id_card_get_trust_anchor (_tmp137_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp139_ = _tmp138_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp140_ = trust_anchor_get_server_cert (_tmp139_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp141_ = _tmp140_;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp142_ = force_flat_file_store;
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               moonshot_install_id_card (_tmp109_, _tmp112_, _tmp115_, _tmp118_, _tmp119_, _tmp119__length1, _tmp120_, _tmp120__length1, _tmp121_, _tmp121__length1, _tmp126_, _tmp131_, _tmp136_, _tmp141_, _tmp142_, &_tmp143_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _moonshot_error_free0 (_error_);
+#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _error_ = _tmp143_;
+#line 126 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _tmp144_ = _error_;
+#line 126 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               if (_tmp144_ != NULL) {
+#line 1005 "moonshot-webp-parser.c"
+                                       FILE* _tmp145_ = NULL;
+                                       MoonshotError* _tmp146_ = NULL;
+                                       const gchar* _tmp147_ = NULL;
+#line 128 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp145_ = stderr;
+#line 128 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp146_ = _error_;
+#line 128 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _tmp147_ = _tmp146_->message;
+#line 128 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       fprintf (_tmp145_, "Error: %s", _tmp147_);
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       svcs = (_vala_array_free (svcs, svcs_length1, (GDestroyNotify) g_free), NULL);
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules = (_vala_Rule_array_free (rules, rules_length1), NULL);
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules_always_confirm = (_vala_array_free (rules_always_confirm, rules_always_confirm_length1, (GDestroyNotify) g_free), NULL);
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       rules_patterns = (_vala_array_free (rules_patterns, rules_patterns_length1, (GDestroyNotify) g_free), NULL);
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _moonshot_error_free0 (_error_);
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       _g_object_unref0 (card);
+#line 129 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                                       continue;
+#line 1031 "moonshot-webp-parser.c"
+                               }
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               svcs = (_vala_array_free (svcs, svcs_length1, (GDestroyNotify) g_free), NULL);
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules = (_vala_Rule_array_free (rules, rules_length1), NULL);
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules_always_confirm = (_vala_array_free (rules_always_confirm, rules_always_confirm_length1, (GDestroyNotify) g_free), NULL);
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               rules_patterns = (_vala_array_free (rules_patterns, rules_patterns_length1, (GDestroyNotify) g_free), NULL);
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _moonshot_error_free0 (_error_);
+#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+                               _g_object_unref0 (card);
+#line 1045 "moonshot-webp-parser.c"
+                       }
+               }
+       }
+#line 133 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       result = 0;
+#line 133 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _g_object_unref0 (webp);
+#line 133 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       _g_free0 (webp_file);
+#line 133 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       return result;
+#line 1057 "moonshot-webp-parser.c"
+}
+
+
+int main (int argc, char ** argv) {
+#if !GLIB_CHECK_VERSION (2,35,0)
+       g_type_init ();
+#endif
+#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-webp-parser.vala"
+       return web_provisioning_main (argv, argc);
+#line 1067 "moonshot-webp-parser.c"
+}
+
+
+static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) {
+       if ((array != NULL) && (destroy_func != NULL)) {
+               int i;
+               for (i = 0; i < array_length; i = i + 1) {
+                       if (((gpointer*) array)[i] != NULL) {
+                               destroy_func (((gpointer*) array)[i]);
+                       }
+               }
+       }
+}
+
+
+static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) {
+       _vala_array_destroy (array, array_length, destroy_func);
+       g_free (array);
+}
+
+
+