Переглянути джерело

Unexport time_support.h.

These are only used by crypto/asn1 and not externally.

Change-Id: I2e6a28828fd81a4e3421eed1e98f0a65197f4b88
Reviewed-on: https://boringssl-review.googlesource.com/13868
Reviewed-by: David Benjamin <davidben@google.com>
Commit-Queue: David Benjamin <davidben@google.com>
CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
kris/onging/CECPQ3_patch15
David Benjamin 7 роки тому
committed by CQ bot account: commit-bot@chromium.org
джерело
коміт
699e55bb0e
9 змінених файлів з 38 додано та 98 видалено
  1. +0
    -1
      crypto/CMakeLists.txt
  2. +1
    -0
      crypto/asn1/CMakeLists.txt
  3. +0
    -1
      crypto/asn1/a_gentm.c
  4. +0
    -1
      crypto/asn1/a_time.c
  5. +0
    -1
      crypto/asn1/a_utctm.c
  6. +35
    -0
      crypto/asn1/asn1_locl.h
  7. +1
    -1
      crypto/asn1/time_support.c
  8. +0
    -91
      include/openssl/time_support.h
  9. +1
    -2
      util/doc.config

+ 0
- 1
crypto/CMakeLists.txt Переглянути файл

@@ -129,7 +129,6 @@ add_library(
thread_none.c
thread_pthread.c
thread_win.c
time_support.c

$<TARGET_OBJECTS:stack>
$<TARGET_OBJECTS:lhash>


+ 1
- 0
crypto/asn1/CMakeLists.txt Переглянути файл

@@ -35,6 +35,7 @@ add_library(
tasn_new.c
tasn_typ.c
tasn_utl.c
time_support.c
x_bignum.c
x_long.c
)


+ 0
- 1
crypto/asn1/a_gentm.c Переглянути файл

@@ -61,7 +61,6 @@

#include <openssl/err.h>
#include <openssl/mem.h>
#include <openssl/time_support.h>

#include "asn1_locl.h"



+ 0
- 1
crypto/asn1/a_time.c Переглянути файл

@@ -63,7 +63,6 @@
#include <openssl/buf.h>
#include <openssl/err.h>
#include <openssl/mem.h>
#include <openssl/time_support.h>

#include "asn1_locl.h"



+ 0
- 1
crypto/asn1/a_utctm.c Переглянути файл

@@ -61,7 +61,6 @@

#include <openssl/err.h>
#include <openssl/mem.h>
#include <openssl/time_support.h>

#include "asn1_locl.h"



+ 35
- 0
crypto/asn1/asn1_locl.h Переглянути файл

@@ -57,7 +57,42 @@
*
*/

#ifndef OPENSSL_HEADER_ASN1_ASN1_LOCL_H
#define OPENSSL_HEADER_ASN1_ASN1_LOCL_H

#include <time.h>

#include <openssl/asn1.h>

#if defined(__cplusplus)
extern "C" {
#endif


/* Wrapper functions for time functions. */

/* OPENSSL_gmtime wraps |gmtime_r|. See the manual page for that function. */
struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result);

/* OPENSSL_gmtime_adj updates |tm| by adding |offset_day| days and |offset_sec|
* seconds. */
int OPENSSL_gmtime_adj(struct tm *tm, int offset_day, long offset_sec);

/* OPENSSL_gmtime_diff calculates the difference between |from| and |to| and
* outputs the difference as a number of days and seconds in |*out_days| and
* |*out_secs|. */
int OPENSSL_gmtime_diff(int *out_days, int *out_secs, const struct tm *from,
const struct tm *to);


/* Internal ASN1 structures and functions: not for application use */

int asn1_utctime_to_tm(struct tm *tm, const ASN1_UTCTIME *d);
int asn1_generalizedtime_to_tm(struct tm *tm, const ASN1_GENERALIZEDTIME *d);


#if defined(__cplusplus)
} /* extern C */
#endif

#endif /* OPENSSL_HEADER_ASN1_ASN1_LOCL_H */

crypto/time_support.c → crypto/asn1/time_support.c Переглянути файл

@@ -59,7 +59,7 @@
#define _POSIX_C_SOURCE 201410L /* for gmtime_r */
#endif

#include <openssl/time_support.h>
#include "asn1_locl.h"

#include <time.h>


+ 0
- 91
include/openssl/time_support.h Переглянути файл

@@ -1,91 +0,0 @@
/* Written by Richard Levitte (richard@levitte.org) for the OpenSSL
* project 2001.
* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
* project 2008.
*/
/* ====================================================================
* Copyright (c) 2001 The OpenSSL Project. 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. All advertising materials mentioning features or use of this
* software must display the following acknowledgment:
* "This product includes software developed by the OpenSSL Project
* for use in the OpenSSL Toolkit. (http://www.OpenSSL.org/)"
*
* 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
* endorse or promote products derived from this software without
* prior written permission. For written permission, please contact
* licensing@OpenSSL.org.
*
* 5. Products derived from this software may not be called "OpenSSL"
* nor may "OpenSSL" appear in their names without prior written
* permission of the OpenSSL Project.
*
* 6. Redistributions of any form whatsoever must retain the following
* acknowledgment:
* "This product includes software developed by the OpenSSL Project
* for use in the OpenSSL Toolkit (http://www.OpenSSL.org/)"
*
* THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
* EXPRESSED 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 OpenSSL PROJECT OR
* ITS 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.
* ====================================================================
*
* This product includes cryptographic software written by Eric Young
* (eay@cryptsoft.com). This product includes software written by Tim
* Hudson (tjh@cryptsoft.com). */

#ifndef OPENSSL_HEADER_TIME_SUPPORT_H
#define OPENSSL_HEADER_TIME_SUPPORT_H

#include <openssl/base.h>

#include <time.h>

#if defined(__cplusplus)
extern "C" {
#endif


/* Wrapper functions for time functions. */


/* OPENSSL_gmtime wraps |gmtime_r|. See the manual page for that function. */
struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result);

/* OPENSSL_gmtime_adj updates |tm| by adding |offset_day| days and |offset_sec|
* seconds. */
int OPENSSL_gmtime_adj(struct tm *tm, int offset_day, long offset_sec);

/* OPENSSL_gmtime_diff calculates the difference between |from| and |to| and
* outputs the difference as a number of days and seconds in |*out_days| and
* |*out_secs|. */
int OPENSSL_gmtime_diff(int *out_days, int *out_secs, const struct tm *from,
const struct tm *to);


#if defined(__cplusplus)
} /* extern C */
#endif

#endif /* OPENSSL_HEADER_TIME_SUPPORT_H */

+ 1
- 2
util/doc.config Переглянути файл

@@ -16,8 +16,7 @@
"include/openssl/obj.h",
"include/openssl/pool.h",
"include/openssl/rand.h",
"include/openssl/stack.h",
"include/openssl/time_support.h"
"include/openssl/stack.h"
]
},{
"Name": "Low-level crypto primitives",


Завантаження…
Відмінити
Зберегти