updates.
authorPekka Riikonen <priikone@silcnet.org>
Sun, 18 Nov 2001 13:40:36 +0000 (13:40 +0000)
committerPekka Riikonen <priikone@silcnet.org>
Sun, 18 Nov 2001 13:40:36 +0000 (13:40 +0000)
README.CVS
apps/silcer/src/Makefile.in
apps/silcer/src/silcerapp.cc
apps/silcer/ui/SilcerFirstsetupDlg.glade [new file with mode: 0644]
distributions

index 5fa6246ac57f9f8e788d2d322b753e6cbe9aa11e..e7568ead1ca31985c33708f802e9e21d0c4fbb70 100644 (file)
@@ -153,6 +153,13 @@ Following directories currently exist in SILC source tree.
         Includes SILC server.  There can be some extra files that will
         never appear in public distribution, such as, configuration files.
 
         Includes SILC server.  There can be some extra files that will
         never appear in public distribution, such as, configuration files.
 
+  win32/
+
+       Includes win32 Toolkit specific files.  It includes MSVC++
+       Workspace files.  The win32/tests includes example code for
+       use of SILC Toolkit and SILC Client Library on Win32 GUI 
+       application.
+
 
 Howto Compile SILC Source Tree
 ==============================
 
 Howto Compile SILC Source Tree
 ==============================
index 4aeecae44f9536e8517a6f376ed90969ff0869d0..82a479c515258ef025c03a17d47d5c0b00e1b4f7 100644 (file)
@@ -16,9 +16,9 @@
 #
 #  Makefile.am
 #
 #
 #  Makefile.am
 #
-#  Author: Pekka Riikonen <priikone@poseidon.pspt.fi>
+#  Author: Pekka Riikonen <priikone@silcnet.org>
 #
 #
-#  Copyright (C) 2000 - 2001 Pekka Riikonen
+#  Copyright (C) 2001 Pekka Riikonen
 #
 #  This program is free software; you can redistribute it and/or modify
 #  it under the terms of the GNU General Public License as published by
 #
 #  This program is free software; you can redistribute it and/or modify
 #  it under the terms of the GNU General Public License as published by
@@ -141,6 +141,8 @@ cflags_set = @cflags_set@
 cxxflags_set = @cxxflags_set@
 install_sh = @install_sh@
 
 cxxflags_set = @cxxflags_set@
 install_sh = @install_sh@
 
+silc_top_srcdir = ../../
+
 bin_PROGRAMS = silcer
 silcer_SOURCES = silcer.cc             \
                silcerapp.cc            \
 bin_PROGRAMS = silcer
 silcer_SOURCES = silcer.cc             \
                silcerapp.cc            \
@@ -153,12 +155,10 @@ silcer_SOURCES = silcer.cc                \
 
 
 silcer_LDADD = @EXTRA_GNOME_LIBS@ -lxml \
 
 
 silcer_LDADD = @EXTRA_GNOME_LIBS@ -lxml \
-       -L/home/priikone/silc/lib -lsilcclient -lsilc
+       -L$(silc_top_srcdir)/lib -lsilcclient -lsilc
 
 silcer_LDFLAGS = 
 
 
 silcer_LDFLAGS = 
 
-silc_top_srcdir = /home/priikone/silc
-
 INCLUDES = @EXTRA_GNOME_CFLAGS@ -DENABLE_NLS \
        -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \
        -DDATADIR=\"$(datadir)\" \
 INCLUDES = @EXTRA_GNOME_CFLAGS@ -DENABLE_NLS \
        -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \
        -DDATADIR=\"$(datadir)\" \
index b73ceb492b2ae4f8c331c23b5558c0429d1cf719..fa9e0fc545b1e3f53fc4b671805b40f778065366 100644 (file)
@@ -211,21 +211,34 @@ SilcerApp::SilcerApp(int argc, char **argv)
 
   // Initialize SILC Client Library */
   silc_client = silc_client_alloc(&ops, NULL, NULL, "SILC-1.0-0.6.2");
 
   // Initialize SILC Client Library */
   silc_client = silc_client_alloc(&ops, NULL, NULL, "SILC-1.0-0.6.2");
-  silc_client->realname = "pekka riikonen";
-  silc_client->username = "priikone";
-  silc_client->hostname = "mun.oma.kone";
+  silc_client->realname = "Foo T. Bar";
+  silc_client->username = "foobar";
+  silc_client->hostname = "foo.bar.foobar.com";
   silc_cipher_register_default();
   silc_pkcs_register_default();
   silc_hash_register_default();
   silc_hmac_register_default();
   silc_cipher_register_default();
   silc_pkcs_register_default();
   silc_hash_register_default();
   silc_hmac_register_default();
-  silc_create_key_pair("rsa", 1024, "kk", "UN=priikone, "
-                      "HN=pelle.kuo.fi.ssh.com", 
+
+  // XXXXX
+  // In real application at this point it would be of course checked 
+  // whether ~/.silc direectory or something exists and key pair exists.
+  // If not then some firstsetup-wizard would be lauched that creates
+  // the keypair.  In our example we'll always create a key pair. :(
+  silc_create_key_pair("rsa", 1024, "kk", "UN=foobar, "
+                      "HN=foo.bar.foobar.com", 
                       &silc_client->public_key, &silc_client->private_key);
                       &silc_client->public_key, &silc_client->private_key);
+
+  // We are ready to initialize the SILC Client library.
   silc_client_init(silc_client);
 
   silc_client_init(silc_client);
 
-  // Setup SILC scheduler as timeout task
+  // Setup SILC scheduler as timeout task. This will handle the SILC
+  // client library every 50 milliseconds.  It will actually make the
+  // SILC client work on background.
   Gnome::Main::timeout.connect(slot(this, &SilcerApp::silc_scheduler), 50);
 
   Gnome::Main::timeout.connect(slot(this, &SilcerApp::silc_scheduler), 50);
 
+  // XXXXX
+  // This is now used to directly connect to silc.silcnet.org router
+  // XXXXX
   silc_schedule_task_add(silc_client->schedule, 0, connect_client, 
                         silc_client, 0, 1, SILC_TASK_TIMEOUT, 
                         SILC_TASK_PRI_NORMAL); 
   silc_schedule_task_add(silc_client->schedule, 0, connect_client, 
                         silc_client, 0, 1, SILC_TASK_TIMEOUT, 
                         SILC_TASK_PRI_NORMAL); 
@@ -278,6 +291,10 @@ GladeXML *SilcerApp::load_resource(const char *name, const char *filename)
 
 gint SilcerApp::silc_scheduler()
 {
 
 gint SilcerApp::silc_scheduler()
 {
+  // Run the SILC client once, and return immediately.  This function
+  // is called every 50 milliseconds by the Gnome main loop, to process
+  // SILC stuff.  This function will read data, and write data to network,
+  // etc.  Makes the client library tick! :)
   silc_client_run_one(silc_client);
   return 1;
 }
   silc_client_run_one(silc_client);
   return 1;
 }
diff --git a/apps/silcer/ui/SilcerFirstsetupDlg.glade b/apps/silcer/ui/SilcerFirstsetupDlg.glade
new file mode 100644 (file)
index 0000000..25085c5
--- /dev/null
@@ -0,0 +1,439 @@
+<?xml version="1.0"?>
+<GTK-Interface>
+
+<project>
+  <name>Project2</name>
+  <program_name>project2</program_name>
+  <directory></directory>
+  <source_directory>src</source_directory>
+  <pixmaps_directory>pixmaps</pixmaps_directory>
+  <language>C</language>
+  <gnome_support>True</gnome_support>
+  <gettext_support>True</gettext_support>
+</project>
+
+<widget>
+  <class>GtkWindow</class>
+  <name>SilcerFirstsetupDlg</name>
+  <title>window1</title>
+  <type>GTK_WINDOW_TOPLEVEL</type>
+  <position>GTK_WIN_POS_NONE</position>
+  <modal>False</modal>
+  <allow_shrink>False</allow_shrink>
+  <allow_grow>True</allow_grow>
+  <auto_shrink>False</auto_shrink>
+
+  <widget>
+    <class>GnomeDruid</class>
+    <name>druid1</name>
+
+    <widget>
+      <class>GnomeDruidPageStart</class>
+      <name>druidpagestart1</name>
+      <title>Silcer - First Time Setup</title>
+      <text>Silcer Gnome SILC Client
+
+You are running the Silcer for first time. This
+setup wizard will guide you through the setup
+procedure.  You will need to do this only once!
+
+PRESS NEXT TO CONTINUE</text>
+      <title_color>255,255,255</title_color>
+      <text_color>0,0,0</text_color>
+      <background_color>25,25,112</background_color>
+      <logo_background_color>255,255,255</logo_background_color>
+      <textbox_color>255,255,255</textbox_color>
+    </widget>
+
+    <widget>
+      <class>GnomeDruidPageStandard</class>
+      <name>druidpagestandard1</name>
+      <title>Personal Information</title>
+      <title_color>255,255,255</title_color>
+      <background_color>25,25,112</background_color>
+      <logo_background_color>255,255,255</logo_background_color>
+
+      <widget>
+       <class>GtkVBox</class>
+       <child_name>GnomeDruidPageStandard:vbox</child_name>
+       <name>druid-vbox1</name>
+       <homogeneous>False</homogeneous>
+       <spacing>0</spacing>
+       <child>
+         <padding>0</padding>
+         <expand>True</expand>
+         <fill>True</fill>
+       </child>
+
+       <widget>
+         <class>GtkFrame</class>
+         <name>frame1</name>
+         <border_width>5</border_width>
+         <label>Your Information</label>
+         <label_xalign>0.02</label_xalign>
+         <shadow_type>GTK_SHADOW_ETCHED_OUT</shadow_type>
+         <child>
+           <padding>0</padding>
+           <expand>True</expand>
+           <fill>True</fill>
+         </child>
+
+         <widget>
+           <class>GtkTable</class>
+           <name>table1</name>
+           <border_width>45</border_width>
+           <rows>5</rows>
+           <columns>2</columns>
+           <homogeneous>False</homogeneous>
+           <row_spacing>6</row_spacing>
+           <column_spacing>10</column_spacing>
+
+           <widget>
+             <class>GtkLabel</class>
+             <name>label2</name>
+             <label>Real Name:</label>
+             <justify>GTK_JUSTIFY_CENTER</justify>
+             <wrap>False</wrap>
+             <xalign>0</xalign>
+             <yalign>0.5</yalign>
+             <xpad>0</xpad>
+             <ypad>0</ypad>
+             <child>
+               <left_attach>0</left_attach>
+               <right_attach>1</right_attach>
+               <top_attach>0</top_attach>
+               <bottom_attach>1</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>False</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkEntry</class>
+             <name>entry1</name>
+             <can_focus>True</can_focus>
+             <editable>True</editable>
+             <text_visible>True</text_visible>
+             <text_max_length>0</text_max_length>
+             <text></text>
+             <child>
+               <left_attach>1</left_attach>
+               <right_attach>2</right_attach>
+               <top_attach>0</top_attach>
+               <bottom_attach>1</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>True</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkLabel</class>
+             <name>label3</name>
+             <label>Hostname:</label>
+             <justify>GTK_JUSTIFY_CENTER</justify>
+             <wrap>False</wrap>
+             <xalign>0</xalign>
+             <yalign>0.5</yalign>
+             <xpad>0</xpad>
+             <ypad>0</ypad>
+             <child>
+               <left_attach>0</left_attach>
+               <right_attach>1</right_attach>
+               <top_attach>1</top_attach>
+               <bottom_attach>2</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>False</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkLabel</class>
+             <name>label4</name>
+             <label>EMail:</label>
+             <justify>GTK_JUSTIFY_CENTER</justify>
+             <wrap>False</wrap>
+             <xalign>0</xalign>
+             <yalign>0.5</yalign>
+             <xpad>0</xpad>
+             <ypad>0</ypad>
+             <child>
+               <left_attach>0</left_attach>
+               <right_attach>1</right_attach>
+               <top_attach>2</top_attach>
+               <bottom_attach>3</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>False</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkEntry</class>
+             <name>entry2</name>
+             <can_focus>True</can_focus>
+             <editable>True</editable>
+             <text_visible>True</text_visible>
+             <text_max_length>0</text_max_length>
+             <text></text>
+             <child>
+               <left_attach>1</left_attach>
+               <right_attach>2</right_attach>
+               <top_attach>1</top_attach>
+               <bottom_attach>2</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>True</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkEntry</class>
+             <name>entry3</name>
+             <can_focus>True</can_focus>
+             <editable>True</editable>
+             <text_visible>True</text_visible>
+             <text_max_length>0</text_max_length>
+             <text></text>
+             <child>
+               <left_attach>1</left_attach>
+               <right_attach>2</right_attach>
+               <top_attach>2</top_attach>
+               <bottom_attach>3</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>True</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkLabel</class>
+             <name>label5</name>
+             <label>Username:</label>
+             <justify>GTK_JUSTIFY_CENTER</justify>
+             <wrap>False</wrap>
+             <xalign>0</xalign>
+             <yalign>0.5</yalign>
+             <xpad>0</xpad>
+             <ypad>0</ypad>
+             <child>
+               <left_attach>0</left_attach>
+               <right_attach>1</right_attach>
+               <top_attach>3</top_attach>
+               <bottom_attach>4</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>False</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkEntry</class>
+             <name>entry4</name>
+             <can_focus>True</can_focus>
+             <editable>True</editable>
+             <text_visible>True</text_visible>
+             <text_max_length>0</text_max_length>
+             <text></text>
+             <child>
+               <left_attach>1</left_attach>
+               <right_attach>2</right_attach>
+               <top_attach>3</top_attach>
+               <bottom_attach>4</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>True</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkLabel</class>
+             <name>label6</name>
+             <label>
+               PRESS NEXT TO CONTINUE!</label>
+             <justify>GTK_JUSTIFY_CENTER</justify>
+             <wrap>False</wrap>
+             <xalign>0</xalign>
+             <yalign>0.5</yalign>
+             <xpad>0</xpad>
+             <ypad>0</ypad>
+             <child>
+               <left_attach>1</left_attach>
+               <right_attach>2</right_attach>
+               <top_attach>4</top_attach>
+               <bottom_attach>5</bottom_attach>
+               <xpad>0</xpad>
+               <ypad>0</ypad>
+               <xexpand>False</xexpand>
+               <yexpand>False</yexpand>
+               <xshrink>False</xshrink>
+               <yshrink>False</yshrink>
+               <xfill>True</xfill>
+               <yfill>False</yfill>
+             </child>
+           </widget>
+         </widget>
+       </widget>
+      </widget>
+    </widget>
+
+    <widget>
+      <class>GnomeDruidPageStandard</class>
+      <name>druidpagestandard2</name>
+      <title>Authentication Key Generation</title>
+      <title_color>255,255,255</title_color>
+      <background_color>25,25,112</background_color>
+      <logo_background_color>255,255,255</logo_background_color>
+
+      <widget>
+       <class>GtkVBox</class>
+       <child_name>GnomeDruidPageStandard:vbox</child_name>
+       <name>druid-vbox2</name>
+       <homogeneous>False</homogeneous>
+       <spacing>0</spacing>
+       <child>
+         <padding>0</padding>
+         <expand>True</expand>
+         <fill>True</fill>
+       </child>
+
+       <widget>
+         <class>GtkFrame</class>
+         <name>frame2</name>
+         <border_width>5</border_width>
+         <label_xalign>0</label_xalign>
+         <shadow_type>GTK_SHADOW_ETCHED_OUT</shadow_type>
+         <child>
+           <padding>0</padding>
+           <expand>True</expand>
+           <fill>True</fill>
+         </child>
+
+         <widget>
+           <class>GtkVBox</class>
+           <name>vbox1</name>
+           <border_width>30</border_width>
+           <homogeneous>False</homogeneous>
+           <spacing>0</spacing>
+
+           <widget>
+             <class>GtkLabel</class>
+             <name>label7</name>
+             <label>Random pool generation in progress...</label>
+             <justify>GTK_JUSTIFY_CENTER</justify>
+             <wrap>False</wrap>
+             <xalign>0.5</xalign>
+             <yalign>0.5</yalign>
+             <xpad>0</xpad>
+             <ypad>0</ypad>
+             <child>
+               <padding>0</padding>
+               <expand>False</expand>
+               <fill>False</fill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkProgressBar</class>
+             <name>progressbar1</name>
+             <value>0</value>
+             <lower>0</lower>
+             <upper>100</upper>
+             <bar_style>GTK_PROGRESS_CONTINUOUS</bar_style>
+             <orientation>GTK_PROGRESS_LEFT_TO_RIGHT</orientation>
+             <activity_mode>True</activity_mode>
+             <show_text>False</show_text>
+             <format>%P %%</format>
+             <text_xalign>0.5</text_xalign>
+             <text_yalign>0.5</text_yalign>
+             <child>
+               <padding>1</padding>
+               <expand>False</expand>
+               <fill>False</fill>
+             </child>
+           </widget>
+
+           <widget>
+             <class>GtkLabel</class>
+             <name>label8</name>
+             <label>
+
+Setup Wizard is generating random data and entropy for
+Authentication Key Generation process.  Please, move
+your mouse pointer around to generate random data.</label>
+             <justify>GTK_JUSTIFY_CENTER</justify>
+             <wrap>False</wrap>
+             <xalign>0.5</xalign>
+             <yalign>0.5</yalign>
+             <xpad>0</xpad>
+             <ypad>0</ypad>
+             <child>
+               <padding>0</padding>
+               <expand>False</expand>
+               <fill>False</fill>
+             </child>
+           </widget>
+         </widget>
+       </widget>
+      </widget>
+    </widget>
+
+    <widget>
+      <class>GnomeDruidPageFinish</class>
+      <name>druidpagefinish1</name>
+      <title>Setup Completed</title>
+      <text>The Setup Wizard is completed! 
+
+PRESS FINISH TO CONTINUE!</text>
+      <background_color>25,25,112</background_color>
+      <logo_background_color>255,255,255</logo_background_color>
+      <textbox_color>255,255,255</textbox_color>
+      <text_color>0,0,0</text_color>
+      <title_color>255,255,255</title_color>
+    </widget>
+  </widget>
+</widget>
+
+</GTK-Interface>
index e55e5e0f35f761b713569d8c4fbf79f0bb473f72..c628aa46ff9fd2febcfe98e3860695c90d334aa6 100644 (file)
@@ -53,7 +53,7 @@ toolkit_SUBDIRS=lib irssi silc silcd doc includes win32
 toolkit_SUBDIRS_lib=$(COMMONDIRS)
 toolkit_SUBDIRS_doc=$(COMMONDIRS)
 toolkit_DISTLABEL=SILC_DIST_TOOLKIT
 toolkit_SUBDIRS_lib=$(COMMONDIRS)
 toolkit_SUBDIRS_doc=$(COMMONDIRS)
 toolkit_DISTLABEL=SILC_DIST_TOOLKIT
-toolkit_EXTRA_DIST=README.CVS README.WIN32
+toolkit_EXTRA_DIST=README.CVS README.WIN32 silcer
 
 # Irssi SILC Client distribution
 client_SUBDIRS=lib irssi doc includes
 
 # Irssi SILC Client distribution
 client_SUBDIRS=lib irssi doc includes