~ubuntu-branches/ubuntu/karmic/gnupg2/karmic-updates

« back to all changes in this revision

Viewing changes to g10/gpgv.c

  • Committer: Bazaar Package Importer
  • Author(s): Eric Dorland
  • Date: 2009-03-08 22:46:47 UTC
  • mfrom: (1.1.11 upstream)
  • Revision ID: james.westby@ubuntu.com-20090308224647-gq17gatcl71lrc2k
Tags: 2.0.11-1
* New upstream release. (Closes: #496663)
* debian/control: Make the description a little more distinctive than
  gnupg v1's. Thanks Jari Aalto. (Closes: #496323)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* gpgv.c - The GnuPG signature verify utility
2
2
 * Copyright (C) 1998, 1999, 2000, 2001, 2002, 2005,
3
 
 *               2006 Free Software Foundation, Inc.
 
3
 *               2006, 2008 Free Software Foundation, Inc.
4
4
 *
5
5
 * This file is part of GnuPG.
6
6
 *
51
51
#include "call-agent.h"
52
52
 
53
53
 
54
 
enum cmd_and_opt_values { aNull = 0,
55
 
    oQuiet        = 'q',
56
 
    oVerbose      = 'v',
57
 
    oBatch        = 500,
58
 
    oKeyring,
59
 
    oIgnoreTimeConflict,                      
60
 
    oStatusFD,
61
 
    oLoggerFD,
62
 
    oHomedir,
63
 
aTest };
 
54
enum cmd_and_opt_values {
 
55
  aNull = 0,
 
56
  oQuiet          = 'q',
 
57
  oVerbose        = 'v',
 
58
  oBatch          = 500,
 
59
  oKeyring,
 
60
  oIgnoreTimeConflict,                      
 
61
  oStatusFD,
 
62
  oLoggerFD,
 
63
  oHomedir,
 
64
  aTest
 
65
};
64
66
 
65
67
 
66
68
static ARGPARSE_OPTS opts[] = {
67
 
 
68
 
    { 301, NULL, 0, N_("@\nOptions:\n ") },
69
 
 
70
 
    { oVerbose, "verbose",   0, N_("verbose") },
71
 
    { oQuiet,   "quiet",     0, N_("be somewhat more quiet") },
72
 
    { oKeyring, "keyring"   ,2, N_("take the keys from this keyring")},
73
 
    { oIgnoreTimeConflict, "ignore-time-conflict", 0, 
74
 
                           N_("make timestamp conflicts only a warning") },
75
 
    { oStatusFD, "status-fd" ,1, N_("|FD|write status info to this FD") },
76
 
    { oLoggerFD, "logger-fd",1, "@" },
77
 
    { oHomedir, "homedir", 2, "@" },   /* defaults to "~/.gnupg" */
78
 
 
79
 
{0} };
 
69
  ARGPARSE_group (300, N_("@\nOptions:\n ")),
 
70
  
 
71
  ARGPARSE_s_n (oVerbose, "verbose", N_("verbose")),
 
72
  ARGPARSE_s_n (oQuiet,   "quiet",   N_("be somewhat more quiet")),
 
73
  ARGPARSE_s_s (oKeyring, "keyring", 
 
74
                N_("|FILE|take the keys from the keyring FILE")),
 
75
  ARGPARSE_s_n (oIgnoreTimeConflict, "ignore-time-conflict",
 
76
                N_("make timestamp conflicts only a warning")),
 
77
  ARGPARSE_s_i (oStatusFD, "status-fd",
 
78
                N_("|FD|write status info to this FD")),
 
79
  ARGPARSE_s_i (oLoggerFD, "logger-fd", "@"),
 
80
  ARGPARSE_s_s (oHomedir, "homedir", "@"),
 
81
 
 
82
  ARGPARSE_end ()
 
83
};
80
84
 
81
85
 
82
86
 
83
87
int g10_errors_seen = 0;
84
88
 
 
89
 
 
90
static char *
 
91
make_libversion (const char *libname, const char *(*getfnc)(const char*))
 
92
{
 
93
  const char *s;
 
94
  char *result;
 
95
  
 
96
  s = getfnc (NULL);
 
97
  result = xmalloc (strlen (libname) + 1 + strlen (s) + 1);
 
98
  strcpy (stpcpy (stpcpy (result, libname), " "), s);
 
99
  return result;
 
100
}
 
101
 
85
102
static const char *
86
103
my_strusage( int level )
87
104
{
88
 
    const char *p;
89
 
    switch( level ) {
90
 
      case 11: p = "gpgv (GnuPG)";
91
 
        break;
92
 
      case 13: p = VERSION; break;
93
 
      case 17: p = PRINTABLE_OS_NAME; break;
94
 
      case 19: p =
95
 
            _("Please report bugs to <gnupg-bugs@gnu.org>.\n");
96
 
        break;
97
 
      case 1:
98
 
      case 40:  p =
99
 
            _("Usage: gpgv [options] [files] (-h for help)");
100
 
        break;
101
 
      case 41:  p =
102
 
            _("Syntax: gpg [options] [files]\n"
103
 
              "Check signatures against known trusted keys\n");
104
 
        break;
105
 
 
106
 
      default:  p = NULL;
 
105
  static char *ver_gcry;
 
106
  const char *p;
 
107
 
 
108
  switch (level)
 
109
    {
 
110
    case 11: p = "gpgv (GnuPG)";
 
111
      break;
 
112
    case 13: p = VERSION; break;
 
113
    case 17: p = PRINTABLE_OS_NAME; break;
 
114
    case 19: p =  _("Please report bugs to <gnupg-bugs@gnu.org>.\n");
 
115
        break;
 
116
    case 1:
 
117
    case 40: p = _("Usage: gpgv [options] [files] (-h for help)");
 
118
      break;
 
119
    case 41: p = _("Syntax: gpg [options] [files]\n"
 
120
                   "Check signatures against known trusted keys\n");
 
121
        break;
 
122
 
 
123
    case 20:
 
124
      if (!ver_gcry)
 
125
        ver_gcry = make_libversion ("libgcrypt", gcry_check_version);
 
126
      p = ver_gcry;
 
127
      break;
 
128
 
 
129
 
 
130
    default: p = NULL;
107
131
    }
108
 
    return p;
 
132
  return p;
109
133
}
110
134
 
111
135
 
113
137
int
114
138
main( int argc, char **argv )
115
139
{
116
 
    ARGPARSE_ARGS pargs;
117
 
    int rc=0;
118
 
    strlist_t sl;
119
 
    strlist_t nrings=NULL;
120
 
    unsigned configlineno;
121
 
 
122
 
    set_strusage (my_strusage);
123
 
    log_set_prefix ("gpgv", 1);
124
 
 
125
 
    /* Make sure that our subsystems are ready.  */
126
 
    init_common_subsystems ();
127
 
 
128
 
    gnupg_init_signals (0, NULL);
129
 
    i18n_init();
130
 
 
131
 
    opt.command_fd = -1; /* no command fd */
132
 
    opt.pgp2_workarounds = 1;
133
 
    opt.keyserver_options.options|=KEYSERVER_AUTO_KEY_RETRIEVE;
134
 
    opt.trust_model = TM_ALWAYS;
135
 
    opt.batch = 1;
136
 
 
137
 
    opt.homedir = default_homedir ();
138
 
 
139
 
    tty_no_terminal(1);
140
 
    tty_batchmode(1);
141
 
    disable_dotlock();
142
 
 
143
 
    pargs.argc = &argc;
144
 
    pargs.argv = &argv;
145
 
    pargs.flags=  1;  /* do not remove the args */
146
 
    while( optfile_parse( NULL, NULL, &configlineno, &pargs, opts) ) {
147
 
        switch( pargs.r_opt ) {
148
 
          case oQuiet: opt.quiet = 1; break;
149
 
          case oVerbose: 
150
 
            opt.verbose++; 
151
 
            opt.list_sigs=1;
152
 
            gcry_control (GCRYCTL_SET_VERBOSITY, (int)opt.verbose);
153
 
            break;
154
 
          case oKeyring: append_to_strlist( &nrings, pargs.r.ret_str); break;
155
 
          case oStatusFD: set_status_fd( pargs.r.ret_int ); break;
156
 
          case oLoggerFD: 
157
 
            log_set_fd (translate_sys2libc_fd_int (pargs.r.ret_int, 1));
158
 
            break;
159
 
          case oHomedir: opt.homedir = pargs.r.ret_str; break;
160
 
          case oIgnoreTimeConflict: opt.ignore_time_conflict = 1; break;
161
 
          default : pargs.err = 2; break;
 
140
  ARGPARSE_ARGS pargs;
 
141
  int rc=0;
 
142
  strlist_t sl;
 
143
  strlist_t nrings=NULL;
 
144
  unsigned configlineno;
 
145
  
 
146
  set_strusage (my_strusage);
 
147
  log_set_prefix ("gpgv", 1);
 
148
  
 
149
  /* Make sure that our subsystems are ready.  */
 
150
  i18n_init();
 
151
  init_common_subsystems ();
 
152
  
 
153
  gnupg_init_signals (0, NULL);
 
154
 
 
155
  opt.command_fd = -1; /* no command fd */
 
156
  opt.pgp2_workarounds = 1;
 
157
  opt.keyserver_options.options|=KEYSERVER_AUTO_KEY_RETRIEVE;
 
158
  opt.trust_model = TM_ALWAYS;
 
159
  opt.batch = 1;
 
160
 
 
161
  opt.homedir = default_homedir ();
 
162
 
 
163
  tty_no_terminal(1);
 
164
  tty_batchmode(1);
 
165
  disable_dotlock();
 
166
  
 
167
  pargs.argc = &argc;
 
168
  pargs.argv = &argv;
 
169
  pargs.flags=  1;  /* do not remove the args */
 
170
  while (optfile_parse( NULL, NULL, &configlineno, &pargs, opts))
 
171
    {
 
172
      switch (pargs.r_opt)
 
173
        {
 
174
        case oQuiet: opt.quiet = 1; break;
 
175
        case oVerbose: 
 
176
          opt.verbose++; 
 
177
          opt.list_sigs=1;
 
178
          gcry_control (GCRYCTL_SET_VERBOSITY, (int)opt.verbose);
 
179
          break;
 
180
        case oKeyring: append_to_strlist( &nrings, pargs.r.ret_str); break;
 
181
        case oStatusFD: set_status_fd( pargs.r.ret_int ); break;
 
182
        case oLoggerFD: 
 
183
          log_set_fd (translate_sys2libc_fd_int (pargs.r.ret_int, 1));
 
184
          break;
 
185
        case oHomedir: opt.homedir = pargs.r.ret_str; break;
 
186
        case oIgnoreTimeConflict: opt.ignore_time_conflict = 1; break;
 
187
        default : pargs.err = ARGPARSE_PRINT_ERROR; break;
162
188
        }
163
189
    }
164
 
 
165
 
    if( log_get_errorcount(0) )
166
 
        g10_exit(2);
167
 
 
168
 
     if( opt.verbose > 1 )
169
 
        set_packet_list_mode(1);
170
 
 
171
 
    if( !nrings )  /* no keyring given: use default one */
172
 
        keydb_add_resource ("trustedkeys" EXTSEP_S "gpg", 0, 0);
173
 
    for(sl = nrings; sl; sl = sl->next )
174
 
        keydb_add_resource (sl->d, 0, 0 );
175
 
    
176
 
    FREE_STRLIST (nrings);
177
 
    
178
 
    if( (rc = verify_signatures( argc, argv ) ))
179
 
        log_error("verify signatures failed: %s\n", g10_errstr(rc) );
180
 
 
181
 
    /* cleanup */
182
 
    g10_exit(0);
183
 
    return 8; /*NEVER REACHED*/
 
190
  
 
191
  if (log_get_errorcount (0))
 
192
    g10_exit(2);
 
193
 
 
194
  if (opt.verbose > 1)
 
195
    set_packet_list_mode(1);
 
196
  
 
197
  if (!nrings)  /* no keyring given: use default one */
 
198
    keydb_add_resource ("trustedkeys" EXTSEP_S "gpg", 0, 0);
 
199
  for (sl = nrings; sl; sl = sl->next)
 
200
    keydb_add_resource (sl->d, 0, 0 );
 
201
    
 
202
  FREE_STRLIST (nrings);
 
203
    
 
204
  if ( (rc = verify_signatures( argc, argv ) ))
 
205
    log_error("verify signatures failed: %s\n", g10_errstr(rc) );
 
206
  
 
207
  /* cleanup */
 
208
  g10_exit (0);
 
209
  return 8; /*NOTREACHED*/
184
210
}
185
211
 
186
212
 
187
213
void
188
214
g10_exit( int rc )
189
215
{
190
 
    rc = rc? rc : log_get_errorcount(0)? 2 :
191
 
                        g10_errors_seen? 1 : 0;
192
 
    exit(rc );
 
216
  rc = rc? rc : log_get_errorcount(0)? 2 : g10_errors_seen? 1 : 0;
 
217
  exit(rc );
193
218
}
194
219
 
195
220
 
200
225
int
201
226
check_signatures_trust( PKT_signature *sig )
202
227
{
203
 
    return 0;
 
228
  (void)sig;
 
229
  return 0;
204
230
}
205
231
 
206
232
void
207
 
read_trust_options(byte *trust_model,ulong *created,ulong *nextcheck,
208
 
                   byte *marginals,byte *completes,byte *cert_depth) {}
 
233
read_trust_options(byte *trust_model, ulong *created, ulong *nextcheck,
 
234
                   byte *marginals, byte *completes, byte *cert_depth) 
 
235
{
 
236
  (void)trust_model;
 
237
  (void)created;
 
238
  (void)nextcheck;
 
239
  (void)marginals;
 
240
  (void)completes;
 
241
  (void)cert_depth;
 
242
}
209
243
 
210
244
/* Stub: 
211
245
 * We don't have the trustdb , so we have to provide some stub functions
215
249
int
216
250
cache_disabled_value(PKT_public_key *pk)
217
251
{
 
252
  (void)pk;
218
253
  return 0;
219
254
}
220
255
 
221
256
void
222
 
check_trustdb_stale(void) {}
 
257
check_trustdb_stale(void) 
 
258
{
 
259
}
223
260
 
224
261
int
225
262
get_validity_info (PKT_public_key *pk, PKT_user_id *uid)
226
263
{
227
 
    return '?';
 
264
  (void)pk;
 
265
  (void)uid;
 
266
  return '?';
228
267
}
229
268
 
230
269
unsigned int
231
270
get_validity (PKT_public_key *pk, PKT_user_id *uid)
232
271
{
 
272
  (void)pk;
 
273
  (void)uid;
233
274
  return 0;
234
275
}
235
276
 
236
277
const char *
237
278
trust_value_to_string (unsigned int value)
238
279
{
 
280
  (void)value;
239
281
  return "err";
240
282
}
241
283
 
242
284
const char *
243
 
uid_trust_string_fixed(PKT_public_key *key,PKT_user_id *uid)
 
285
uid_trust_string_fixed (PKT_public_key *key, PKT_user_id *uid)
244
286
{
 
287
  (void)key;
 
288
  (void)uid;
245
289
  return "err";
246
290
}
247
291
 
248
292
int
249
293
get_ownertrust_info (PKT_public_key *pk)
250
294
{
251
 
    return '?';
 
295
  (void)pk;
 
296
  return '?';
252
297
}
253
298
 
254
299
unsigned int
255
300
get_ownertrust (PKT_public_key *pk)
256
301
{
257
 
    return TRUST_UNKNOWN;
 
302
  (void)pk;
 
303
  return TRUST_UNKNOWN;
258
304
}
259
305
 
260
306
 
264
310
 */
265
311
 
266
312
struct keyserver_spec *
267
 
keyserver_match(struct keyserver_spec *spec) { return NULL; }
268
 
 
269
 
int
270
 
keyserver_import_keyid( u32 *keyid, void *dummy )
271
 
{
272
 
    return -1;
273
 
}
274
 
 
275
 
int
276
 
keyserver_import_cert(const char *name) { return -1; }
277
 
 
278
 
int
279
 
keyserver_import_pka(const char *name,unsigned char *fpr) { return -1; }
280
 
 
281
 
int
282
 
keyserver_import_name(const char *name,struct keyserver_spec *spec)
283
 
{
284
 
  return -1;
285
 
}
286
 
 
287
 
int
288
 
keyserver_import_ldap(const char *name) { return -1; }
 
313
keyserver_match (struct keyserver_spec *spec)
 
314
{
 
315
  (void)spec;
 
316
  return NULL; 
 
317
}
 
318
 
 
319
int
 
320
keyserver_import_keyid (u32 *keyid, void *dummy)
 
321
{
 
322
  (void)keyid;
 
323
  (void)dummy;
 
324
  return -1;
 
325
}
 
326
 
 
327
int
 
328
keyserver_import_cert (const char *name)
 
329
{
 
330
  (void)name;
 
331
  return -1; 
 
332
}
 
333
 
 
334
int
 
335
keyserver_import_pka (const char *name,unsigned char *fpr)
 
336
{
 
337
  (void)name;
 
338
  (void)fpr;
 
339
  return -1;
 
340
}
 
341
 
 
342
int
 
343
keyserver_import_name (const char *name,struct keyserver_spec *spec)
 
344
{
 
345
  (void)name;
 
346
  (void)spec;
 
347
  return -1;
 
348
}
 
349
 
 
350
int
 
351
keyserver_import_ldap (const char *name)
 
352
{
 
353
  (void)name;
 
354
  return -1;
 
355
}
289
356
 
290
357
/* Stub:
291
358
 * No encryption here but mainproc links to these functions.
292
359
 */
293
360
int
294
 
get_session_key( PKT_pubkey_enc *k, DEK *dek )
295
 
{
296
 
    return G10ERR_GENERAL;
297
 
}
298
 
/* Stub: */
299
 
int
300
 
get_override_session_key( DEK *dek, const char *string )
301
 
{
302
 
    return G10ERR_GENERAL;
303
 
}
304
 
/* Stub: */
305
 
int
306
 
decrypt_data( void *procctx, PKT_encrypted *ed, DEK *dek )
307
 
{
308
 
    return G10ERR_GENERAL;
 
361
get_session_key (PKT_pubkey_enc *k, DEK *dek)
 
362
{
 
363
  (void)k;
 
364
  (void)dek;
 
365
  return G10ERR_GENERAL;
 
366
}
 
367
 
 
368
/* Stub: */
 
369
int
 
370
get_override_session_key (DEK *dek, const char *string)
 
371
{
 
372
  (void)dek;
 
373
  (void)string;
 
374
  return G10ERR_GENERAL;
 
375
}
 
376
 
 
377
/* Stub: */
 
378
int
 
379
decrypt_data (void *procctx, PKT_encrypted *ed, DEK *dek)
 
380
{
 
381
  (void)procctx;
 
382
  (void)ed;
 
383
  (void)dek;
 
384
  return G10ERR_GENERAL;
309
385
}
310
386
 
311
387
 
312
388
/* Stub:
313
 
 * No interactive commnds, so we don't need the helptexts
 
389
 * No interactive commands, so we don't need the helptexts
314
390
 */
315
391
void
316
 
display_online_help( const char *keyword )
 
392
display_online_help (const char *keyword)
317
393
{
 
394
  (void)keyword;
318
395
}
319
396
 
320
397
/* Stub:
321
398
 * We don't use secret keys, but getkey.c links to this
322
399
 */
323
400
int
324
 
check_secret_key( PKT_secret_key *sk, int n )
 
401
check_secret_key (PKT_secret_key *sk, int n)
325
402
{
326
 
    return G10ERR_GENERAL;
 
403
  (void)sk;
 
404
  (void)n;
 
405
  return G10ERR_GENERAL;
327
406
}
328
407
 
329
408
/* Stub:
330
409
 * No secret key, so no passphrase needed 
331
410
 */
332
411
DEK *
333
 
passphrase_to_dek( u32 *keyid, int pubkey_algo,
334
 
                   int cipher_algo, STRING2KEY *s2k, int mode,
 
412
passphrase_to_dek (u32 *keyid, int pubkey_algo,
 
413
                   int cipher_algo, STRING2KEY *s2k, int mode,
335
414
                   const char *tmp, int *canceled)
336
415
{
 
416
  (void)keyid;
 
417
  (void)pubkey_algo;
 
418
  (void)cipher_algo;
 
419
  (void)s2k;
 
420
  (void)mode;
 
421
  (void)tmp;
 
422
 
337
423
  if (canceled)
338
424
    *canceled = 0;
339
425
  return NULL;
340
426
}
341
427
 
342
 
struct keyserver_spec *parse_preferred_keyserver(PKT_signature *sig) {return NULL;}
343
 
struct keyserver_spec *parse_keyserver_uri(const char *uri,int require_scheme,
344
 
                                           const char *configname,
345
 
                                           unsigned int configlineno)
346
 
{
347
 
  return NULL;
348
 
}
349
 
 
350
 
void free_keyserver_spec(struct keyserver_spec *keyserver) {}
 
428
struct keyserver_spec *
 
429
parse_preferred_keyserver(PKT_signature *sig) 
 
430
{
 
431
  (void)sig;
 
432
  return NULL;
 
433
}
 
434
 
 
435
struct keyserver_spec *
 
436
parse_keyserver_uri (const char *uri, int require_scheme,
 
437
                     const char *configname, unsigned int configlineno)
 
438
{
 
439
  (void)uri;
 
440
  (void)require_scheme;
 
441
  (void)configname;
 
442
  (void)configlineno;
 
443
  return NULL;
 
444
}
 
445
 
 
446
void 
 
447
free_keyserver_spec (struct keyserver_spec *keyserver)
 
448
{
 
449
  (void)keyserver;
 
450
}
351
451
 
352
452
/* Stubs to avoid linking to photoid.c */
353
 
void show_photos(const struct user_attribute *attrs,int count,PKT_public_key *pk) {}
354
 
int parse_image_header(const struct user_attribute *attr,byte *type,u32 *len) {return 0;}
355
 
char *image_type_to_string(byte type,int string) {return NULL;}
 
453
void 
 
454
show_photos (const struct user_attribute *attrs, int count, PKT_public_key *pk)
 
455
{
 
456
  (void)attrs;
 
457
  (void)count;
 
458
  (void)pk;
 
459
}
 
460
 
 
461
int 
 
462
parse_image_header (const struct user_attribute *attr, byte *type, u32 *len)
 
463
{
 
464
  (void)attr;
 
465
  (void)type;
 
466
  (void)len;
 
467
  return 0;
 
468
}
 
469
 
 
470
char *
 
471
image_type_to_string (byte type, int string)
 
472
{
 
473
  (void)type;
 
474
  (void)string;
 
475
  return NULL;
 
476
}
356
477
 
357
478
#ifdef ENABLE_CARD_SUPPORT
358
 
int agent_scd_getattr (const char *name, struct agent_card_info_s *info) {return 0;}
 
479
int 
 
480
agent_scd_getattr (const char *name, struct agent_card_info_s *info)
 
481
{
 
482
  (void)name;
 
483
  (void)info;
 
484
  return 0;
 
485
}
359
486
#endif /* ENABLE_CARD_SUPPORT */
360
487
 
361
 
/* Stubs to void linking to ../cipher/cipher.c */
362
 
const char *cipher_algo_to_string( int algo ) { return "?";}
363
 
void disable_cipher_algo( int algo ) {}
364
 
int check_cipher_algo( int algo ) { return -1;}
365
 
unsigned int cipher_get_keylen( int algo ) { return 0; }
366
 
unsigned int cipher_get_blocksize( int algo ) {return 0;}
367
 
gcry_cipher_hd_t cipher_open( int algo, int mode, int secure ) { return NULL;}
368
 
void cipher_close( gcry_cipher_hd_t c ) {}
369
 
int cipher_setkey( gcry_cipher_hd_t c, byte *key, unsigned keylen ) { return -1;}
370
 
void cipher_setiv( gcry_cipher_hd_t c, const byte *iv, unsigned ivlen ){}
371
 
void cipher_encrypt( gcry_cipher_hd_t c, byte *outbuf,
372
 
                     byte *inbuf, unsigned nbytes ) {}
373
 
void cipher_decrypt( gcry_cipher_hd_t c, byte *outbuf,
374
 
                     byte *inbuf, unsigned nbytes ) {}
375
 
void cipher_sync( gcry_cipher_hd_t c ) {}
376
 
 
377
 
 
378
 
 
379
488
/* We do not do any locking, so use these stubs here */
380
 
void disable_dotlock(void) {}
381
 
DOTLOCK create_dotlock( const char *file_to_lock ) { return NULL; }
382
 
void destroy_dotlock (DOTLOCK h) {}
383
 
int make_dotlock( DOTLOCK h, long timeout ) { return 0;}
384
 
int release_dotlock( DOTLOCK h ) {return 0;}
385
 
void remove_lockfiles(void) {}
 
489
void 
 
490
disable_dotlock (void)
 
491
{
 
492
}
 
493
 
 
494
DOTLOCK 
 
495
create_dotlock (const char *file_to_lock)
 
496
{
 
497
  (void)file_to_lock;
 
498
  return NULL;
 
499
}
 
500
 
 
501
void 
 
502
destroy_dotlock (DOTLOCK h)
 
503
{
 
504
  (void)h;
 
505
}
 
506
 
 
507
int
 
508
make_dotlock (DOTLOCK h, long timeout)
 
509
{
 
510
  (void)h;
 
511
  (void)timeout;
 
512
  return 0;
 
513
}
 
514
 
 
515
int
 
516
release_dotlock (DOTLOCK h)
 
517
{
 
518
  (void)h;
 
519
  return 0;
 
520
}
 
521
 
 
522
void 
 
523
remove_lockfiles (void)
 
524
{
 
525
}
 
526