Skip to content

Commit

Permalink
core: move existing MD5 hash implementation into new core subfolder c…
Browse files Browse the repository at this point in the history
…rypto
  • Loading branch information
henningw committed Oct 3, 2019
1 parent 075c74f commit 6c89219
Show file tree
Hide file tree
Showing 10 changed files with 9 additions and 7 deletions.
1 change: 1 addition & 0 deletions src/Makefile.sources
Expand Up @@ -15,6 +15,7 @@ sources=$(filter-out $(auto_gen), $(wildcard *.c) \
$(wildcard core/parser/*.c) $(wildcard core/parser/digest/*.c) \
$(wildcard core/parser/contact/*.c) $(wildcard core/parser/sdp/*.c) \
$(wildcard core/rand/*.c) $(wildcard core/rand/isaac/*.c) ) \
$(wildcard core/crypto/*.c) \
$(wildcard core/cfg/*.c) $(auto_gen)
ifeq ($(CORE_TLS), 1)
sources+= $(wildcard tls/*.c)
Expand Down
2 changes: 1 addition & 1 deletion src/core/char_msg_val.h
Expand Up @@ -29,7 +29,7 @@
#include "parser/msg_parser.h"
#include "parser/parse_to.h"
#include "parser/parse_from.h"
#include "md5utils.h"
#include "crypto/md5utils.h"

/*! \brief calculate characteristic value of a message -- this value
is used to identify a transaction during the process of
Expand Down
2 changes: 2 additions & 0 deletions src/core/config.h
Expand Up @@ -35,6 +35,8 @@
#ifndef config_h
#define config_h

#include "crypto/md5utils.h"

#define SIP_PORT 5060 /*!< default SIP port if none specified */
#define SIPS_PORT 5061 /*!< default SIP port for TLS if none specified */

Expand Down
2 changes: 1 addition & 1 deletion src/core/md5.c → src/core/crypto/md5.c
Expand Up @@ -20,7 +20,7 @@
#include <sys/types.h>
#include <string.h>

#include "endianness.h"
#include "../endianness.h"
#include "md5.h"

#ifndef __OS_solaris
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions src/core/md5utils.c → src/core/crypto/md5utils.c
Expand Up @@ -33,8 +33,8 @@
#include <string.h>
#include "md5.h"
#include "md5utils.h"
#include "dprint.h"
#include "ut.h"
#include "../dprint.h"
#include "../ut.h"


/*!
Expand Down
2 changes: 1 addition & 1 deletion src/core/md5utils.h → src/core/crypto/md5utils.h
Expand Up @@ -28,7 +28,7 @@
#ifndef _MD5UTILS_H
#define _MD5UTILS_H

#include "str.h"
#include "../str.h"

#define MD5_LEN 32

Expand Down
1 change: 1 addition & 0 deletions src/core/forward.c
Expand Up @@ -50,6 +50,7 @@
#include "data_lump.h"
#include "ut.h"
#include "mem/mem.h"
#include "crypto/md5utils.h"
#include "msg_translator.h"
#include "sr_module.h"
#include "ip_addr.h"
Expand Down
1 change: 0 additions & 1 deletion src/core/msg_translator.c
Expand Up @@ -91,7 +91,6 @@
#include "mem/mem.h"
#include "dprint.h"
#include "config.h"
#include "md5utils.h"
#include "data_lump.h"
#include "data_lump_rpl.h"
#include "ip_addr.h"
Expand Down
1 change: 0 additions & 1 deletion src/core/parser/msg_parser.h
Expand Up @@ -35,7 +35,6 @@
#include "../lump_struct.h"
#include "../flags.h"
#include "../ip_addr.h"
#include "../md5utils.h"
#include "../config.h"
#include "parse_def.h"
#include "parse_cseq.h"
Expand Down

0 comments on commit 6c89219

Please sign in to comment.