merge branch
authorFrantišek Dvořák <valtri@civ.zcu.cz>
Fri, 9 Nov 2007 18:18:05 +0000 (18:18 +0000)
committerFrantišek Dvořák <valtri@civ.zcu.cz>
Fri, 9 Nov 2007 18:18:05 +0000 (18:18 +0000)
org.glite.jp.index/Makefile
org.glite.jp.index/config/glite-jp-index-dbsetup.sql
org.glite.jp.index/examples/jpis-test.c
org.glite.jp.index/examples/query-tests/dump1.sql
org.glite.jp.index/project/version.properties
org.glite.jp.index/src/bones_server.c
org.glite.jp.index/src/db_ops.c
org.glite.jp.index/src/soap_ops.c
org.glite.jp.index/src/soap_ps_calls.c

index 8037980..84a7b81 100644 (file)
@@ -5,7 +5,7 @@ top_builddir=${top_srcdir}/${builddir}
 stagedir=.
 distdir=.
 globalprefix=glite
-lbprefix=lb
+jpprefix=jp
 package=glite-lb-server
 version=0.0.0
 PREFIX=/opt/glite
@@ -13,7 +13,6 @@ PREFIX=/opt/glite
 glite_location=/opt/glite
 nothrflavour=gcc32
 thrflavour=gcc32pthr
-expat_prefix=/opt/expat
 gsoap_prefix=/software/gsoap-2.6
 
 CC=gcc
@@ -162,6 +161,7 @@ ws_is_typeref.o: ws_is_typeref.c ${is_prefix}H.h ws_typemap.h ws_is_typeref.h so
 jpis-client.o: jpis-client.c ${is_prefix}H.h soap_version.h
 jpis-test.o: jpis-client.c ${is_prefix}H.h soap_version.h
 conf.o: conf.c ${is_prefix}H.h soap_version.h
+common.o: common.h common.c
 
 ${ws_prefix}C.o: ${ws_prefix}C.c
        $(CC) -c $(CPPFLAGS) $(CFLAGS) -Wno-unused-parameter $<
index 485c04f..97a5a2f 100644 (file)
@@ -1,35 +1,35 @@
 create table jobs (
-        jobid          char(32)        binary not null,
-        dg_jobid        varchar(255)    binary not null,
-        ownerid         char(32)        binary not null,
-        aclid           char(32)        binary null,
-       ps              varchar(255)    not null,
+       `jobid`         char(32)        binary not null,
+       `dg_jobid`        varchar(255)    binary not null,
+       `ownerid`         char(32)        binary not null,
+       `aclid`           char(32)        binary null,
+       `ps`            varchar(255)    not null,
 
-        primary key (jobid),
-        unique (dg_jobid),
-        index (jobid),
+       primary key (jobid),
+       unique (dg_jobid),
+       index (jobid),
        index (dg_jobid)
 );
 
 create table attrs (
-               attrid          char(32)        binary not null,
-        name           varchar(255)    binary not null,
-       indexed         int             not null,
-       type            char(32)        binary null,
+       `attrid`                char(32)        binary not null,
+       `name`          varchar(255)    binary not null,
+       `indexed`               int             not null,
+       `type`          char(32)        binary null,
 
-        primary key (attrid),
-        index (attrid),
+       primary key (attrid),
+       index (attrid),
        index (name)
 );
 
 create table feeds (
-       uniqueid        int             auto_increment not null,
-       feedid          char(32)        binary unique,
-       state           int             not null,
-       locked          int             not null,
-       source          varchar(255)    not null,
-       expires         datetime,
-       condition       mediumblob      null,
+       `uniqueid`      int             auto_increment not null,
+       `feedid`                char(32)        binary unique,
+       `state`         int             not null,
+       `locked`                int             not null,
+       `source`                varchar(255)    not null,
+       `expires`               datetime,
+       `condition`     mediumblob      null,
 
         primary key (uniqueid),
         index (uniqueid),
@@ -38,16 +38,16 @@ create table feeds (
 );
 
 create table acls (
-        aclid           char(32)        binary not null,
-        value           mediumblob      not null,
-        refcnt          int             not null,
+       `aclid`           char(32)        binary not null,
+       `value`           mediumblob      not null,
+       `refcnt`          int             not null,
 
         primary key (aclid)
 );
 
 create table users (
-        userid          char(32)        binary not null,
-        cert_subj       varchar(255)    binary not null,
+       `userid`          char(32)        binary not null,
+       `cert_subj`       varchar(255)    binary not null,
 
         primary key (userid),
         unique (cert_subj)
@@ -58,10 +58,10 @@ create table users (
 # value is created only for attributes configured to be indexed
 #
 #create table attr_<attrid> (
-#        jobid         char(32)        binary not null,
-#        value         varchar(255)    binary not null,
-#        full_value    mediumblob      not null,
-#        origin                int             not null,
+#        `jobid`               char(32)        binary not null,
+#        `value`               varchar(255)    binary not null,
+#        `full_value`  mediumblob      not null,
+#        `origin`              int             not null,
 #
 #        index (jobid),
 #        index (value)
index 4f14c8a..04d5f7d 100644 (file)
@@ -94,14 +94,12 @@ int main(int argc,char *argv[])
                        {
                                edg_wll_GssCred         cred = NULL;
                                edg_wll_GssStatus       gss_code;
-                               char                    *subject = NULL;
 
-                               if ( edg_wll_gss_acquire_cred_gsi(NULL, NULL, &cred, &subject, &gss_code) ) {
+                               if ( edg_wll_gss_acquire_cred_gsi(NULL, NULL, &cred, &gss_code) ) {
                                        printf("Cannot obtain credentials - exiting.\n");
                                        return EINVAL;
                                }
-                               rec->owner = soap_strdup(soap, subject);
-                               free(subject);
+                               rec->owner = soap_strdup(soap, cred->name);
                        }
                        rec->__sizeprimaryStorage = 0;
                        rec->primaryStorage = NULL;
index 1953b66..0fd7cea 100644 (file)
@@ -43,11 +43,11 @@ UNLOCK TABLES;
 /*!40000 ALTER TABLE `acls` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_1005bc536e987ca1e027a5b8f84c9a67`
+-- Table structure for table `attr_ac7ea0b2cd17deedbc569733597059ae`
 --
 
-DROP TABLE IF EXISTS `attr_1005bc536e987ca1e027a5b8f84c9a67`;
-CREATE TABLE `attr_1005bc536e987ca1e027a5b8f84c9a67` (
+DROP TABLE IF EXISTS `attr_ac7ea0b2cd17deedbc569733597059ae`;
+CREATE TABLE `attr_ac7ea0b2cd17deedbc569733597059ae` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -57,21 +57,21 @@ CREATE TABLE `attr_1005bc536e987ca1e027a5b8f84c9a67` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_1005bc536e987ca1e027a5b8f84c9a67`
+-- Dumping data for table `attr_ac7ea0b2cd17deedbc569733597059ae`
 --
 
 
-/*!40000 ALTER TABLE `attr_1005bc536e987ca1e027a5b8f84c9a67` DISABLE KEYS */;
-LOCK TABLES `attr_1005bc536e987ca1e027a5b8f84c9a67` WRITE;
+/*!40000 ALTER TABLE `attr_ac7ea0b2cd17deedbc569733597059ae` DISABLE KEYS */;
+LOCK TABLES `attr_ac7ea0b2cd17deedbc569733597059ae` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_1005bc536e987ca1e027a5b8f84c9a67` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_ac7ea0b2cd17deedbc569733597059ae` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_12aaad5454b6e3e44cb4f4a432336af4`
+-- Table structure for table `attr_5de12c1776c3130b9d27a7502a13e11c`
 --
 
-DROP TABLE IF EXISTS `attr_12aaad5454b6e3e44cb4f4a432336af4`;
-CREATE TABLE `attr_12aaad5454b6e3e44cb4f4a432336af4` (
+DROP TABLE IF EXISTS `attr_5de12c1776c3130b9d27a7502a13e11c`;
+CREATE TABLE `attr_5de12c1776c3130b9d27a7502a13e11c` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -81,21 +81,21 @@ CREATE TABLE `attr_12aaad5454b6e3e44cb4f4a432336af4` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_12aaad5454b6e3e44cb4f4a432336af4`
+-- Dumping data for table `attr_5de12c1776c3130b9d27a7502a13e11c`
 --
 
 
-/*!40000 ALTER TABLE `attr_12aaad5454b6e3e44cb4f4a432336af4` DISABLE KEYS */;
-LOCK TABLES `attr_12aaad5454b6e3e44cb4f4a432336af4` WRITE;
+/*!40000 ALTER TABLE `attr_5de12c1776c3130b9d27a7502a13e11c` DISABLE KEYS */;
+LOCK TABLES `attr_5de12c1776c3130b9d27a7502a13e11c` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_12aaad5454b6e3e44cb4f4a432336af4` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_5de12c1776c3130b9d27a7502a13e11c` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_29d3ef83b39b8cf690e8113df316835a`
+-- Table structure for table `attr_f496f5d872a2d04ee626045477f340db`
 --
 
-DROP TABLE IF EXISTS `attr_29d3ef83b39b8cf690e8113df316835a`;
-CREATE TABLE `attr_29d3ef83b39b8cf690e8113df316835a` (
+DROP TABLE IF EXISTS `attr_f496f5d872a2d04ee626045477f340db`;
+CREATE TABLE `attr_f496f5d872a2d04ee626045477f340db` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -105,21 +105,21 @@ CREATE TABLE `attr_29d3ef83b39b8cf690e8113df316835a` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_29d3ef83b39b8cf690e8113df316835a`
+-- Dumping data for table `attr_f496f5d872a2d04ee626045477f340db`
 --
 
 
-/*!40000 ALTER TABLE `attr_29d3ef83b39b8cf690e8113df316835a` DISABLE KEYS */;
-LOCK TABLES `attr_29d3ef83b39b8cf690e8113df316835a` WRITE;
+/*!40000 ALTER TABLE `attr_f496f5d872a2d04ee626045477f340db` DISABLE KEYS */;
+LOCK TABLES `attr_f496f5d872a2d04ee626045477f340db` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_29d3ef83b39b8cf690e8113df316835a` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_f496f5d872a2d04ee626045477f340db` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_5023d8d4cc249460dd947a878153027f`
+-- Table structure for table `attr_34d7a9e823c6948d525362d2709bdfcd`
 --
 
-DROP TABLE IF EXISTS `attr_5023d8d4cc249460dd947a878153027f`;
-CREATE TABLE `attr_5023d8d4cc249460dd947a878153027f` (
+DROP TABLE IF EXISTS `attr_34d7a9e823c6948d525362d2709bdfcd`;
+CREATE TABLE `attr_34d7a9e823c6948d525362d2709bdfcd` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -129,21 +129,21 @@ CREATE TABLE `attr_5023d8d4cc249460dd947a878153027f` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_5023d8d4cc249460dd947a878153027f`
+-- Dumping data for table `attr_34d7a9e823c6948d525362d2709bdfcd`
 --
 
 
-/*!40000 ALTER TABLE `attr_5023d8d4cc249460dd947a878153027f` DISABLE KEYS */;
-LOCK TABLES `attr_5023d8d4cc249460dd947a878153027f` WRITE;
+/*!40000 ALTER TABLE `attr_34d7a9e823c6948d525362d2709bdfcd` DISABLE KEYS */;
+LOCK TABLES `attr_34d7a9e823c6948d525362d2709bdfcd` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_5023d8d4cc249460dd947a878153027f` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_34d7a9e823c6948d525362d2709bdfcd` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_52942b8c70bab8491ab5d3b9713d79f5`
+-- Table structure for table `attr_824794b00ee73be550f893b99ceaa643`
 --
 
-DROP TABLE IF EXISTS `attr_52942b8c70bab8491ab5d3b9713d79f5`;
-CREATE TABLE `attr_52942b8c70bab8491ab5d3b9713d79f5` (
+DROP TABLE IF EXISTS `attr_824794b00ee73be550f893b99ceaa643`;
+CREATE TABLE `attr_824794b00ee73be550f893b99ceaa643` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -153,21 +153,21 @@ CREATE TABLE `attr_52942b8c70bab8491ab5d3b9713d79f5` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_52942b8c70bab8491ab5d3b9713d79f5`
+-- Dumping data for table `attr_824794b00ee73be550f893b99ceaa643`
 --
 
 
-/*!40000 ALTER TABLE `attr_52942b8c70bab8491ab5d3b9713d79f5` DISABLE KEYS */;
-LOCK TABLES `attr_52942b8c70bab8491ab5d3b9713d79f5` WRITE;
+/*!40000 ALTER TABLE `attr_824794b00ee73be550f893b99ceaa643` DISABLE KEYS */;
+LOCK TABLES `attr_824794b00ee73be550f893b99ceaa643` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_52942b8c70bab8491ab5d3b9713d79f5` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_824794b00ee73be550f893b99ceaa643` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_6bc44144bf813a2ad7d67cb2adbdaf42`
+-- Table structure for table `attr_ac1e0e146f3e1bee11d6e40d07e60abb`
 --
 
-DROP TABLE IF EXISTS `attr_6bc44144bf813a2ad7d67cb2adbdaf42`;
-CREATE TABLE `attr_6bc44144bf813a2ad7d67cb2adbdaf42` (
+DROP TABLE IF EXISTS `attr_ac1e0e146f3e1bee11d6e40d07e60abb`;
+CREATE TABLE `attr_ac1e0e146f3e1bee11d6e40d07e60abb` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -177,21 +177,21 @@ CREATE TABLE `attr_6bc44144bf813a2ad7d67cb2adbdaf42` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_6bc44144bf813a2ad7d67cb2adbdaf42`
+-- Dumping data for table `attr_ac1e0e146f3e1bee11d6e40d07e60abb`
 --
 
 
-/*!40000 ALTER TABLE `attr_6bc44144bf813a2ad7d67cb2adbdaf42` DISABLE KEYS */;
-LOCK TABLES `attr_6bc44144bf813a2ad7d67cb2adbdaf42` WRITE;
+/*!40000 ALTER TABLE `attr_ac1e0e146f3e1bee11d6e40d07e60abb` DISABLE KEYS */;
+LOCK TABLES `attr_ac1e0e146f3e1bee11d6e40d07e60abb` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_6bc44144bf813a2ad7d67cb2adbdaf42` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_ac1e0e146f3e1bee11d6e40d07e60abb` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_760a84e0ff89fa3f4e96ec82adfd92f1`
+-- Table structure for table `attr_7636d6368c1cf53bc5511241cac9751f`
 --
 
-DROP TABLE IF EXISTS `attr_760a84e0ff89fa3f4e96ec82adfd92f1`;
-CREATE TABLE `attr_760a84e0ff89fa3f4e96ec82adfd92f1` (
+DROP TABLE IF EXISTS `attr_7636d6368c1cf53bc5511241cac9751f`;
+CREATE TABLE `attr_7636d6368c1cf53bc5511241cac9751f` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -201,21 +201,21 @@ CREATE TABLE `attr_760a84e0ff89fa3f4e96ec82adfd92f1` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_760a84e0ff89fa3f4e96ec82adfd92f1`
+-- Dumping data for table `attr_7636d6368c1cf53bc5511241cac9751f`
 --
 
 
-/*!40000 ALTER TABLE `attr_760a84e0ff89fa3f4e96ec82adfd92f1` DISABLE KEYS */;
-LOCK TABLES `attr_760a84e0ff89fa3f4e96ec82adfd92f1` WRITE;
+/*!40000 ALTER TABLE `attr_7636d6368c1cf53bc5511241cac9751f` DISABLE KEYS */;
+LOCK TABLES `attr_7636d6368c1cf53bc5511241cac9751f` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_760a84e0ff89fa3f4e96ec82adfd92f1` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_7636d6368c1cf53bc5511241cac9751f` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_7c3be9defcbcf9f0e7890600d9c204ac`
+-- Table structure for table `attr_64ea5318d74aca823630ba9ca38971e0`
 --
 
-DROP TABLE IF EXISTS `attr_7c3be9defcbcf9f0e7890600d9c204ac`;
-CREATE TABLE `attr_7c3be9defcbcf9f0e7890600d9c204ac` (
+DROP TABLE IF EXISTS `attr_64ea5318d74aca823630ba9ca38971e0`;
+CREATE TABLE `attr_64ea5318d74aca823630ba9ca38971e0` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -225,21 +225,21 @@ CREATE TABLE `attr_7c3be9defcbcf9f0e7890600d9c204ac` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_7c3be9defcbcf9f0e7890600d9c204ac`
+-- Dumping data for table `attr_64ea5318d74aca823630ba9ca38971e0`
 --
 
 
-/*!40000 ALTER TABLE `attr_7c3be9defcbcf9f0e7890600d9c204ac` DISABLE KEYS */;
-LOCK TABLES `attr_7c3be9defcbcf9f0e7890600d9c204ac` WRITE;
+/*!40000 ALTER TABLE `attr_64ea5318d74aca823630ba9ca38971e0` DISABLE KEYS */;
+LOCK TABLES `attr_64ea5318d74aca823630ba9ca38971e0` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_7c3be9defcbcf9f0e7890600d9c204ac` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_64ea5318d74aca823630ba9ca38971e0` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_862e3dd7c5da90c9a659a32a41f63af8`
+-- Table structure for table `attr_81a1d6b95da954e977f22f78417b98a8`
 --
 
-DROP TABLE IF EXISTS `attr_862e3dd7c5da90c9a659a32a41f63af8`;
-CREATE TABLE `attr_862e3dd7c5da90c9a659a32a41f63af8` (
+DROP TABLE IF EXISTS `attr_81a1d6b95da954e977f22f78417b98a8`;
+CREATE TABLE `attr_81a1d6b95da954e977f22f78417b98a8` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -249,21 +249,21 @@ CREATE TABLE `attr_862e3dd7c5da90c9a659a32a41f63af8` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_862e3dd7c5da90c9a659a32a41f63af8`
+-- Dumping data for table `attr_81a1d6b95da954e977f22f78417b98a8`
 --
 
 
-/*!40000 ALTER TABLE `attr_862e3dd7c5da90c9a659a32a41f63af8` DISABLE KEYS */;
-LOCK TABLES `attr_862e3dd7c5da90c9a659a32a41f63af8` WRITE;
+/*!40000 ALTER TABLE `attr_81a1d6b95da954e977f22f78417b98a8` DISABLE KEYS */;
+LOCK TABLES `attr_81a1d6b95da954e977f22f78417b98a8` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_862e3dd7c5da90c9a659a32a41f63af8` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_81a1d6b95da954e977f22f78417b98a8` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_982d06bdc65d3a4240b36a060a09886e`
+-- Table structure for table `attr_e6c0fb3b99f16296db2623c02f0d5c6f`
 --
 
-DROP TABLE IF EXISTS `attr_982d06bdc65d3a4240b36a060a09886e`;
-CREATE TABLE `attr_982d06bdc65d3a4240b36a060a09886e` (
+DROP TABLE IF EXISTS `attr_e6c0fb3b99f16296db2623c02f0d5c6f`;
+CREATE TABLE `attr_e6c0fb3b99f16296db2623c02f0d5c6f` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -273,21 +273,21 @@ CREATE TABLE `attr_982d06bdc65d3a4240b36a060a09886e` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_982d06bdc65d3a4240b36a060a09886e`
+-- Dumping data for table `attr_e6c0fb3b99f16296db2623c02f0d5c6f`
 --
 
 
-/*!40000 ALTER TABLE `attr_982d06bdc65d3a4240b36a060a09886e` DISABLE KEYS */;
-LOCK TABLES `attr_982d06bdc65d3a4240b36a060a09886e` WRITE;
+/*!40000 ALTER TABLE `attr_e6c0fb3b99f16296db2623c02f0d5c6f` DISABLE KEYS */;
+LOCK TABLES `attr_e6c0fb3b99f16296db2623c02f0d5c6f` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_982d06bdc65d3a4240b36a060a09886e` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_e6c0fb3b99f16296db2623c02f0d5c6f` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_9892f81a8175c09bd00afcb152f510ad`
+-- Table structure for table `attr_474e4207c49813e09915732c80c0e1cc`
 --
 
-DROP TABLE IF EXISTS `attr_9892f81a8175c09bd00afcb152f510ad`;
-CREATE TABLE `attr_9892f81a8175c09bd00afcb152f510ad` (
+DROP TABLE IF EXISTS `attr_474e4207c49813e09915732c80c0e1cc`;
+CREATE TABLE `attr_474e4207c49813e09915732c80c0e1cc` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -297,22 +297,22 @@ CREATE TABLE `attr_9892f81a8175c09bd00afcb152f510ad` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_9892f81a8175c09bd00afcb152f510ad`
+-- Dumping data for table `attr_474e4207c49813e09915732c80c0e1cc`
 --
 
 
-/*!40000 ALTER TABLE `attr_9892f81a8175c09bd00afcb152f510ad` DISABLE KEYS */;
-LOCK TABLES `attr_9892f81a8175c09bd00afcb152f510ad` WRITE;
-INSERT INTO `attr_9892f81a8175c09bd00afcb152f510ad` VALUES ('593e62a063231f8c623b74406b3e12b0','CertSubj','S:7201:F::CertSubj',3),('9276789a0093ad44457655ef03ade36a','CertSubj','S:7201:S::CertSubj',2);
+/*!40000 ALTER TABLE `attr_474e4207c49813e09915732c80c0e1cc` DISABLE KEYS */;
+LOCK TABLES `attr_474e4207c49813e09915732c80c0e1cc` WRITE;
+INSERT INTO `attr_474e4207c49813e09915732c80c0e1cc` VALUES ('593e62a063231f8c623b74406b3e12b0','CertSubj','S:7201:F::CertSubj',3),('9276789a0093ad44457655ef03ade36a','CertSubj','S:7201:S::CertSubj',2);
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_9892f81a8175c09bd00afcb152f510ad` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_474e4207c49813e09915732c80c0e1cc` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_9a812abe1262a90858b7be792f198596`
+-- Table structure for table `attr_e2d5742f6e917ea2e949d49b9fa0c1b3`
 --
 
-DROP TABLE IF EXISTS `attr_9a812abe1262a90858b7be792f198596`;
-CREATE TABLE `attr_9a812abe1262a90858b7be792f198596` (
+DROP TABLE IF EXISTS `attr_e2d5742f6e917ea2e949d49b9fa0c1b3`;
+CREATE TABLE `attr_e2d5742f6e917ea2e949d49b9fa0c1b3` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -322,21 +322,21 @@ CREATE TABLE `attr_9a812abe1262a90858b7be792f198596` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_9a812abe1262a90858b7be792f198596`
+-- Dumping data for table `attr_e2d5742f6e917ea2e949d49b9fa0c1b3`
 --
 
 
-/*!40000 ALTER TABLE `attr_9a812abe1262a90858b7be792f198596` DISABLE KEYS */;
-LOCK TABLES `attr_9a812abe1262a90858b7be792f198596` WRITE;
+/*!40000 ALTER TABLE `attr_e2d5742f6e917ea2e949d49b9fa0c1b3` DISABLE KEYS */;
+LOCK TABLES `attr_e2d5742f6e917ea2e949d49b9fa0c1b3` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_9a812abe1262a90858b7be792f198596` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_e2d5742f6e917ea2e949d49b9fa0c1b3` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_a1e9e0a1b7943cc041fefb5da65868f9`
+-- Table structure for table `attr_941ae4f469950ed63ad19822dbcf5427`
 --
 
-DROP TABLE IF EXISTS `attr_a1e9e0a1b7943cc041fefb5da65868f9`;
-CREATE TABLE `attr_a1e9e0a1b7943cc041fefb5da65868f9` (
+DROP TABLE IF EXISTS `attr_941ae4f469950ed63ad19822dbcf5427`;
+CREATE TABLE `attr_941ae4f469950ed63ad19822dbcf5427` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -346,22 +346,22 @@ CREATE TABLE `attr_a1e9e0a1b7943cc041fefb5da65868f9` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_a1e9e0a1b7943cc041fefb5da65868f9`
+-- Dumping data for table `attr_941ae4f469950ed63ad19822dbcf5427`
 --
 
 
-/*!40000 ALTER TABLE `attr_a1e9e0a1b7943cc041fefb5da65868f9` DISABLE KEYS */;
-LOCK TABLES `attr_a1e9e0a1b7943cc041fefb5da65868f9` WRITE;
-INSERT INTO `attr_a1e9e0a1b7943cc041fefb5da65868f9` VALUES ('593e62a063231f8c623b74406b3e12b0','Done','S:7201:F::Done',3),('9276789a0093ad44457655ef03ade36a','Ready','S:7201:S::Ready',1);
+/*!40000 ALTER TABLE `attr_941ae4f469950ed63ad19822dbcf5427` DISABLE KEYS */;
+LOCK TABLES `attr_941ae4f469950ed63ad19822dbcf5427` WRITE;
+INSERT INTO `attr_941ae4f469950ed63ad19822dbcf5427` VALUES ('593e62a063231f8c623b74406b3e12b0','Done','S:7201:F::Done',3),('9276789a0093ad44457655ef03ade36a','Ready','S:7201:S::Ready',1);
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_a1e9e0a1b7943cc041fefb5da65868f9` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_941ae4f469950ed63ad19822dbcf5427` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_a9c522a79597e1bfd2bd687d42d557b7`
+-- Table structure for table `attr_97b3c128ab54e621c806b9ffe5c45185`
 --
 
-DROP TABLE IF EXISTS `attr_a9c522a79597e1bfd2bd687d42d557b7`;
-CREATE TABLE `attr_a9c522a79597e1bfd2bd687d42d557b7` (
+DROP TABLE IF EXISTS `attr_97b3c128ab54e621c806b9ffe5c45185`;
+CREATE TABLE `attr_97b3c128ab54e621c806b9ffe5c45185` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -371,21 +371,21 @@ CREATE TABLE `attr_a9c522a79597e1bfd2bd687d42d557b7` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_a9c522a79597e1bfd2bd687d42d557b7`
+-- Dumping data for table `attr_97b3c128ab54e621c806b9ffe5c45185`
 --
 
 
-/*!40000 ALTER TABLE `attr_a9c522a79597e1bfd2bd687d42d557b7` DISABLE KEYS */;
-LOCK TABLES `attr_a9c522a79597e1bfd2bd687d42d557b7` WRITE;
+/*!40000 ALTER TABLE `attr_97b3c128ab54e621c806b9ffe5c45185` DISABLE KEYS */;
+LOCK TABLES `attr_97b3c128ab54e621c806b9ffe5c45185` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_a9c522a79597e1bfd2bd687d42d557b7` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_97b3c128ab54e621c806b9ffe5c45185` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_c47f78255056386d2b3da6d506d1f244`
+-- Table structure for table `attr_04ffb63c6978549209734fc02e8d688d`
 --
 
-DROP TABLE IF EXISTS `attr_c47f78255056386d2b3da6d506d1f244`;
-CREATE TABLE `attr_c47f78255056386d2b3da6d506d1f244` (
+DROP TABLE IF EXISTS `attr_04ffb63c6978549209734fc02e8d688d`;
+CREATE TABLE `attr_04ffb63c6978549209734fc02e8d688d` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -395,22 +395,22 @@ CREATE TABLE `attr_c47f78255056386d2b3da6d506d1f244` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_c47f78255056386d2b3da6d506d1f244`
+-- Dumping data for table `attr_04ffb63c6978549209734fc02e8d688d`
 --
 
 
-/*!40000 ALTER TABLE `attr_c47f78255056386d2b3da6d506d1f244` DISABLE KEYS */;
-LOCK TABLES `attr_c47f78255056386d2b3da6d506d1f244` WRITE;
-INSERT INTO `attr_c47f78255056386d2b3da6d506d1f244` VALUES ('593e62a063231f8c623b74406b3e12b0','VOCE','S:7201:F::VOCE',3);
+/*!40000 ALTER TABLE `attr_04ffb63c6978549209734fc02e8d688d` DISABLE KEYS */;
+LOCK TABLES `attr_04ffb63c6978549209734fc02e8d688d` WRITE;
+INSERT INTO `attr_04ffb63c6978549209734fc02e8d688d` VALUES ('593e62a063231f8c623b74406b3e12b0','VOCE','S:7201:F::VOCE',3);
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_c47f78255056386d2b3da6d506d1f244` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_04ffb63c6978549209734fc02e8d688d` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_d193237d94c17244ebba4ce049759371`
+-- Table structure for table `attr_48f1a123884d6e24fe205c0f1c60c686`
 --
 
-DROP TABLE IF EXISTS `attr_d193237d94c17244ebba4ce049759371`;
-CREATE TABLE `attr_d193237d94c17244ebba4ce049759371` (
+DROP TABLE IF EXISTS `attr_48f1a123884d6e24fe205c0f1c60c686`;
+CREATE TABLE `attr_48f1a123884d6e24fe205c0f1c60c686` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -420,21 +420,21 @@ CREATE TABLE `attr_d193237d94c17244ebba4ce049759371` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_d193237d94c17244ebba4ce049759371`
+-- Dumping data for table `attr_48f1a123884d6e24fe205c0f1c60c686`
 --
 
 
-/*!40000 ALTER TABLE `attr_d193237d94c17244ebba4ce049759371` DISABLE KEYS */;
-LOCK TABLES `attr_d193237d94c17244ebba4ce049759371` WRITE;
+/*!40000 ALTER TABLE `attr_48f1a123884d6e24fe205c0f1c60c686` DISABLE KEYS */;
+LOCK TABLES `attr_48f1a123884d6e24fe205c0f1c60c686` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_d193237d94c17244ebba4ce049759371` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_48f1a123884d6e24fe205c0f1c60c686` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_e019a506c890326966714893ac3e8cf5`
+-- Table structure for table `attr_52df8110aad9f80fd33a96073bfe58e7`
 --
 
-DROP TABLE IF EXISTS `attr_e019a506c890326966714893ac3e8cf5`;
-CREATE TABLE `attr_e019a506c890326966714893ac3e8cf5` (
+DROP TABLE IF EXISTS `attr_52df8110aad9f80fd33a96073bfe58e7`;
+CREATE TABLE `attr_52df8110aad9f80fd33a96073bfe58e7` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -444,21 +444,21 @@ CREATE TABLE `attr_e019a506c890326966714893ac3e8cf5` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_e019a506c890326966714893ac3e8cf5`
+-- Dumping data for table `attr_52df8110aad9f80fd33a96073bfe58e7`
 --
 
 
-/*!40000 ALTER TABLE `attr_e019a506c890326966714893ac3e8cf5` DISABLE KEYS */;
-LOCK TABLES `attr_e019a506c890326966714893ac3e8cf5` WRITE;
+/*!40000 ALTER TABLE `attr_52df8110aad9f80fd33a96073bfe58e7` DISABLE KEYS */;
+LOCK TABLES `attr_52df8110aad9f80fd33a96073bfe58e7` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_e019a506c890326966714893ac3e8cf5` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_52df8110aad9f80fd33a96073bfe58e7` ENABLE KEYS */;
 
 --
--- Table structure for table `attr_e26a86a86bfc6799461d999860e57d81`
+-- Table structure for table `attr_47a0c544b03cd51e37f3ad7f9e0a0a62`
 --
 
-DROP TABLE IF EXISTS `attr_e26a86a86bfc6799461d999860e57d81`;
-CREATE TABLE `attr_e26a86a86bfc6799461d999860e57d81` (
+DROP TABLE IF EXISTS `attr_47a0c544b03cd51e37f3ad7f9e0a0a62`;
+CREATE TABLE `attr_47a0c544b03cd51e37f3ad7f9e0a0a62` (
   `jobid` varchar(32) character set latin1 collate latin1_bin NOT NULL default '',
   `value` varchar(255) character set latin1 collate latin1_bin NOT NULL default '',
   `full_value` mediumblob NOT NULL,
@@ -468,14 +468,14 @@ CREATE TABLE `attr_e26a86a86bfc6799461d999860e57d81` (
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
 --
--- Dumping data for table `attr_e26a86a86bfc6799461d999860e57d81`
+-- Dumping data for table `attr_47a0c544b03cd51e37f3ad7f9e0a0a62`
 --
 
 
-/*!40000 ALTER TABLE `attr_e26a86a86bfc6799461d999860e57d81` DISABLE KEYS */;
-LOCK TABLES `attr_e26a86a86bfc6799461d999860e57d81` WRITE;
+/*!40000 ALTER TABLE `attr_47a0c544b03cd51e37f3ad7f9e0a0a62` DISABLE KEYS */;
+LOCK TABLES `attr_47a0c544b03cd51e37f3ad7f9e0a0a62` WRITE;
 UNLOCK TABLES;
-/*!40000 ALTER TABLE `attr_e26a86a86bfc6799461d999860e57d81` ENABLE KEYS */;
+/*!40000 ALTER TABLE `attr_47a0c544b03cd51e37f3ad7f9e0a0a62` ENABLE KEYS */;
 
 --
 -- Table structure for table `attrs`
@@ -499,7 +499,7 @@ CREATE TABLE `attrs` (
 
 /*!40000 ALTER TABLE `attrs` DISABLE KEYS */;
 LOCK TABLES `attrs` WRITE;
-INSERT INTO `attrs` VALUES ('52942b8c70bab8491ab5d3b9713d79f5','http://egee.cesnet.cz/en/Schema/JP/System:owner',1,'mediumblob'),('6bc44144bf813a2ad7d67cb2adbdaf42','http://egee.cesnet.cz/en/Schema/JP/System:jobId',1,'mediumblob'),('862e3dd7c5da90c9a659a32a41f63af8','http://egee.cesnet.cz/en/Schema/JP/System:regtime',0,'mediumblob'),('9892f81a8175c09bd00afcb152f510ad','http://egee.cesnet.cz/en/Schema/LB/Attributes:user',1,'mediumblob'),('e019a506c890326966714893ac3e8cf5','http://egee.cesnet.cz/en/Schema/LB/Attributes:aTag',0,'mediumblob'),('d193237d94c17244ebba4ce049759371','http://egee.cesnet.cz/en/Schema/LB/Attributes:eNodes',0,'mediumblob'),('5023d8d4cc249460dd947a878153027f','http://egee.cesnet.cz/en/Schema/LB/Attributes:RB',1,'mediumblob'),('c47f78255056386d2b3da6d506d1f244','http://egee.cesnet.cz/en/Schema/LB/Attributes:CE',1,'mediumblob'),('29d3ef83b39b8cf690e8113df316835a','http://egee.cesnet.cz/en/Schema/LB/Attributes:UIHost',1,'mediumblob'),('a9c522a79597e1bfd2bd687d42d557b7','http://egee.cesnet.cz/en/Schema/LB/Attributes:CPUTime',0,'mediumblob'),('12aaad5454b6e3e44cb4f4a432336af4','http://egee.cesnet.cz/en/Schema/LB/Attributes:NProc',0,'mediumblob'),('a1e9e0a1b7943cc041fefb5da65868f9','http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatus',1,'mediumblob'),('760a84e0ff89fa3f4e96ec82adfd92f1','http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatusDate',0,'mediumblob'),('9a812abe1262a90858b7be792f198596','http://egee.cesnet.cz/en/Schema/LB/Attributes:retryCount',0,'mediumblob'),('e26a86a86bfc6799461d999860e57d81','http://egee.cesnet.cz/en/Schema/LB/Attributes:jobType',0,'mediumblob'),('1005bc536e987ca1e027a5b8f84c9a67','http://egee.cesnet.cz/en/Schema/LB/Attributes:nsubjobs',0,'mediumblob'),('7c3be9defcbcf9f0e7890600d9c204ac','http://egee.cesnet.cz/en/Schema/LB/Attributes:lastStatusHistory',0,'mediumblob'),('982d06bdc65d3a4240b36a060a09886e','http://egee.cesnet.cz/en/Schema/LB/Attributes:fullStatusHistory',0,'mediumblob');
+INSERT INTO `attrs` VALUES ('824794b00ee73be550f893b99ceaa643','http://egee.cesnet.cz/en/Schema/JP/System:owner',1,'mediumblob'),('ac1e0e146f3e1bee11d6e40d07e60abb','http://egee.cesnet.cz/en/Schema/JP/System:jobId',1,'mediumblob'),('81a1d6b95da954e977f22f78417b98a8','http://egee.cesnet.cz/en/Schema/JP/System:regtime',0,'mediumblob'),('474e4207c49813e09915732c80c0e1cc','http://egee.cesnet.cz/en/Schema/LB/Attributes:user',1,'mediumblob'),('52df8110aad9f80fd33a96073bfe58e7','http://egee.cesnet.cz/en/Schema/LB/Attributes:aTag',0,'mediumblob'),('48f1a123884d6e24fe205c0f1c60c686','http://egee.cesnet.cz/en/Schema/LB/Attributes:eNodes',0,'mediumblob'),('34d7a9e823c6948d525362d2709bdfcd','http://egee.cesnet.cz/en/Schema/LB/Attributes:RB',1,'mediumblob'),('04ffb63c6978549209734fc02e8d688d','http://egee.cesnet.cz/en/Schema/LB/Attributes:CE',1,'mediumblob'),('f496f5d872a2d04ee626045477f340db','http://egee.cesnet.cz/en/Schema/LB/Attributes:UIHost',1,'mediumblob'),('97b3c128ab54e621c806b9ffe5c45185','http://egee.cesnet.cz/en/Schema/LB/Attributes:CPUTime',0,'mediumblob'),('5de12c1776c3130b9d27a7502a13e11c','http://egee.cesnet.cz/en/Schema/LB/Attributes:NProc',0,'mediumblob'),('941ae4f469950ed63ad19822dbcf5427','http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatus',1,'mediumblob'),('7636d6368c1cf53bc5511241cac9751f','http://egee.cesnet.cz/en/Schema/LB/Attributes:finalStatusDate',0,'mediumblob'),('e2d5742f6e917ea2e949d49b9fa0c1b3','http://egee.cesnet.cz/en/Schema/LB/Attributes:retryCount',0,'mediumblob'),('47a0c544b03cd51e37f3ad7f9e0a0a62','http://egee.cesnet.cz/en/Schema/LB/Attributes:jobType',0,'mediumblob'),('ac7ea0b2cd17deedbc569733597059ae','http://egee.cesnet.cz/en/Schema/LB/Attributes:nsubjobs',0,'mediumblob'),('64ea5318d74aca823630ba9ca38971e0','http://egee.cesnet.cz/en/Schema/LB/Attributes:lastStatusHistory',0,'mediumblob'),('e6c0fb3b99f16296db2623c02f0d5c6f','http://egee.cesnet.cz/en/Schema/LB/Attributes:fullStatusHistory',0,'mediumblob');
 UNLOCK TABLES;
 /*!40000 ALTER TABLE `attrs` ENABLE KEYS */;
 
index 7e0ffc1..3bb1b78 100644 (file)
@@ -60,7 +60,6 @@ static struct glite_srvbones_service stab = {
 static time_t          cert_mtime;
 static char            *server_cert, *server_key, *cadir;
 static edg_wll_GssCred         mycred = NULL;
-static char            *mysubj;
 
 static char            *port = GLITE_JPIS_DEFAULT_PORT_STR;
 static int             debug = 1;
@@ -157,8 +156,8 @@ int main(int argc, char *argv[])
        if ( cadir ) setenv("X509_CERT_DIR", cadir, 1);
        edg_wll_gss_watch_creds(server_cert, &cert_mtime);
 
-       if ( !edg_wll_gss_acquire_cred_gsi(server_cert, server_key, &mycred, &mysubj, &gss_code)) 
-               fprintf(stderr,"Server idenity: %s\n",mysubj);
+       if ( !edg_wll_gss_acquire_cred_gsi(server_cert, server_key, &mycred, &gss_code)) 
+               fprintf(stderr,"Server idenity: %s\n",mycred ? mycred->name : "NULL");
        else fputs("WARNING: Running unauthenticated\n",stderr);
 
        // XXX: more tests needed
@@ -408,11 +407,11 @@ int newconn(int conn,struct timeval *to,void *data)
        switch (edg_wll_gss_watch_creds(server_cert,&cert_mtime)) {
                case 0: break;
                case 1: if (!edg_wll_gss_acquire_cred_gsi(server_cert,server_key,
-                                               &newcred,NULL,&gss_code))
+                                               &newcred,&gss_code))
                        {
 
                                printf("[%d] reloading credentials\n",getpid()); /* XXX: log */
-                               edg_wll_gss_release_cred(&mycred, NULL);
+                               edg_wll_gss_release_cred(mycred, NULL);
                                mycred = newcred;
                        }
                        break;
index 25e581a..5ea7619 100644 (file)
@@ -7,6 +7,7 @@
 #include <string.h>
 #include <assert.h>
 #include <stdio.h>
+#include <ctype.h>
 
 #include <glite/lbu/trio.h>
 #include <glite/jp/types.h>
 #define TABLE_PREFIX_DATA "attr_"
 #define SQLCMD_DROP_DATA_TABLE "DROP TABLE " TABLE_PREFIX_DATA "%s"
 #define SQLCMD_CREATE_DATA_TABLE "CREATE TABLE " TABLE_PREFIX_DATA "%s (\n\
-        jobid          CHAR(32)    BINARY NOT NULL,\n\
-        value          %s          BINARY NOT NULL,\n\
-        full_value     %s          NOT NULL,\n\
-        origin         INT         NOT NULL,\n\
+        `jobid`          CHAR(32)    BINARY NOT NULL,\n\
+        `value`          %s          BINARY NOT NULL,\n\
+        `full_value`     %s          NOT NULL,\n\
+        `origin`         INT         NOT NULL,\n\
 \n\
         INDEX (jobid),\n\
         INDEX (value)\n\
@@ -260,7 +261,17 @@ fail:
  * Convert attribute name to attribute id.
  */
 char *glite_jpis_attr_name2id(const char *name) {
-       return str2md5(name);
+       size_t i, len;
+       char *lname, *id;
+
+       len = strlen(name);
+       lname = malloc(len + 1);
+       for (i = 0; i < len + 1; i++) lname[i] = tolower(name[i]);
+       id = str2md5(lname);
+       free(lname);
+
+       return id;
+//     return str2md5(name);
 }
 
 
@@ -667,6 +678,10 @@ int glite_jpis_lazyInsertJob(glite_jpis_context_t ctx, const char *ps, const cha
 
        lprintf("\n");
 
+       if (!jobid || !owner) {
+               glite_jpis_stack_error(ctx->jpctx, EINVAL, "jobid and owner is mandatory (jobid=%s, owner=%s)!\n", jobid, owner);
+               goto fail;
+       }
        md5_jobid = str2md5(jobid);
        md5_cert = str2md5(owner);
        GLITE_JPIS_PARAM(ctx->param_jobid, ctx->param_jobid_len, md5_jobid);
index 5d2484d..bd266fe 100644 (file)
@@ -153,7 +153,13 @@ static int checkIndexedConditions(glite_jpis_context_t ctx, struct _jpelem__Quer
        for (k=0; k < in->__sizeconditions; k++) {
                for (j=0; j < i; j++) {
                        char *attr = GLITE_SECURITY_GSOAP_LIST_GET(in->conditions, k)->attr;
-                       if (!strcmp(attr, GLITE_JP_ATTR_JOBID) || !strcmp(attr, indexed_attrs[j])) {
+
+                       if (!attr) {
+                               glite_jpis_stack_error(ctx->jpctx, EINVAL, "condition attribute no %d is NULL", j);
+                               ret = 0;
+                               goto end;
+                       }
+                       if (!strcasecmp(attr, GLITE_JP_ATTR_JOBID) || !strcasecmp(attr, indexed_attrs[j])) {
                                ret = 0;
                                goto end;
                        }
@@ -300,7 +306,7 @@ static char *get_sql_or(glite_jpis_context_t ctx, struct jptype__indexQuery *con
                if (record->op == jptype__queryOp__EXISTS) {
                        /* no additional conditions needed when existing is enough */
                } else {
-                       if (strcmp(condition->attr, GLITE_JP_ATTR_JOBID) == 0) {
+                       if (strcasecmp(condition->attr, GLITE_JP_ATTR_JOBID) == 0) {
                                value = get_sql_stringvalue(record->value);
                                if (!value) goto err;
                                value2 = get_sql_stringvalue(record->value2);
@@ -345,12 +351,12 @@ static int get_jobids(glite_jpis_context_t ctx, struct _jpelem__QueryJobs *in, c
                condition = GLITE_SECURITY_GSOAP_LIST_GET(in->conditions, i);
 
                /* attr name */
-               if (strcmp(condition->attr, GLITE_JP_ATTR_JOBID) == 0) {
+               if (strcasecmp(condition->attr, GLITE_JP_ATTR_JOBID) == 0) {
                        /* no subset from attr_ table, used jobs table instead */
                        attr_md5 = NULL;
                        qa = strdup("");
                } else {
-                       attr_md5 = str2md5(condition->attr);
+                       attr_md5 = glite_jpis_attr_name2id(condition->attr);
                        add_attr_table(attr_md5, &attr_tables);
 
                        /* origin */
@@ -464,7 +470,7 @@ static int get_attr(struct soap *soap, glite_jpis_context_t ctx, char *jobid, ch
 
        memset(&jav,0,sizeof(jav));
        jobid_md5 = str2md5(jobid);
-       attr_md5 = str2md5(attr_name);
+       attr_md5 = glite_jpis_attr_name2id(attr_name);
        trio_asprintf(&query,"SELECT full_value FROM attr_%|Ss WHERE jobid = \"%s\"",
                attr_md5, jobid_md5);
        free(attr_md5);
index 7fc1305..5b3edc0 100644 (file)
@@ -56,7 +56,7 @@ static int refresh_gsoap(glite_jpis_context_t ctx, struct soap *soap) {
        static const struct timeval to = {tv_sec: 7200, tv_usec: 0};
        glite_gsplugin_Context  plugin_ctx;
 
-       if (edg_wll_gss_acquire_cred_gsi(ctx->conf->server_cert, ctx->conf->server_key, &cred, NULL, &gss_code) != 0) {
+       if (edg_wll_gss_acquire_cred_gsi(ctx->conf->server_cert, ctx->conf->server_key, &cred, &gss_code) != 0) {
                edg_wll_gss_get_error(&gss_code,"",&et);
                glite_jpis_stack_error(ctx->jpctx, EINVAL, "can't refresh certificates (%s)", et);
                free(et);