Skip to content

Commit

Permalink
openssl-gnutls: removed dead code
Browse files Browse the repository at this point in the history
  • Loading branch information
franku committed Sep 17, 2018
1 parent ef4237d commit 39b09ed
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 36 deletions.
30 changes: 0 additions & 30 deletions core/src/lib/tls_gnutls.cc
Expand Up @@ -46,7 +46,6 @@ struct TlsContext {
const void *pem_userdata;
unsigned char *dhdata;
bool VerifyPeer;
bool tls_enable;
bool tls_require;
};

Expand Down Expand Up @@ -233,35 +232,6 @@ void FreeTlsContext(TLS_CONTEXT *ctx)
free(ctx);
}

bool GetTlsRequire(TLS_CONTEXT *ctx)
{
return (ctx) ? ctx->tls_require : false;
}

void SetTlsRequire(TLS_CONTEXT *ctx, bool value)
{
if (ctx) {
ctx->tls_require = value;
}
}

bool GetTlsEnable(TLS_CONTEXT *ctx)
{
return (ctx) ? ctx->tls_enable : false;
}

void SetTlsEnable(TLS_CONTEXT *ctx, bool value)
{
if (ctx) {
ctx->tls_enable = value;
}
}

bool GetTlsVerifyPeer(TLS_CONTEXT *ctx)
{
return (ctx) ? ctx->VerifyPeer : false;
}

/*
* Certs are not automatically verified during the handshake.
*/
Expand Down
6 changes: 0 additions & 6 deletions core/src/lib/tls_openssl.h
Expand Up @@ -23,7 +23,6 @@

typedef std::shared_ptr<PskCredentials> sharedPskCredentials;

DLL_IMP_EXP int hex2bin(char *str, unsigned char *out, unsigned int max_out_len);
DLL_IMP_EXP void FreeTlsContext(std::shared_ptr<TLS_CONTEXT> &ctx);

#ifdef HAVE_TLS
Expand All @@ -40,11 +39,6 @@ DLL_IMP_EXP void TlsLogConninfo(JobControlRecord *jcr, TLS_CONNECTION *tls_conn,
DLL_IMP_EXP bool TlsBsockConnect(BareosSocket *bsock);
DLL_IMP_EXP void TlsBsockShutdown(BareosSocket *bsock);
DLL_IMP_EXP void FreeTlsConnection(TLS_CONNECTION *tls_conn);
DLL_IMP_EXP bool GetTlsRequire(TLS_CONTEXT *ctx);
DLL_IMP_EXP void SetTlsRequire(TLS_CONTEXT *ctx, bool value);
DLL_IMP_EXP bool GetTlsEnable(TLS_CONTEXT *ctx);
DLL_IMP_EXP void SetTlsEnable(TLS_CONTEXT *ctx, bool value);
DLL_IMP_EXP bool GetTlsVerifyPeer(TLS_CONTEXT *ctx);
DLL_IMP_EXP bool TlsPolicyHandshake(BareosSocket *bs, bool initiated_by_remote,
uint32_t local, uint32_t *remote);
DLL_IMP_EXP std::shared_ptr<TLS_CONTEXT> new_tls_context(const char *CaCertfile, const char *CaCertdir,
Expand Down

0 comments on commit 39b09ed

Please sign in to comment.