patch-include_arpa_nameser_h 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. --- openswan-2.6.38.orig/include/arpa/nameser.h 2012-03-23 22:33:43.000000000 +0100
  2. +++ openswan-2.6.38/include/arpa/nameser.h 2014-03-26 19:50:18.000000000 +0100
  3. @@ -55,7 +55,6 @@
  4. #include <sys/param.h>
  5. #include <sys/types.h>
  6. -#include <sys/cdefs.h>
  7. /*
  8. * Revision information. This is the release date in YYYYMMDD format.
  9. @@ -505,62 +504,66 @@ typedef enum __ns_cert_types {
  10. #define ns_makecanon __ns_makecanon
  11. #define ns_samename __ns_samename
  12. -__BEGIN_DECLS
  13. -int ns_msg_getflag __P((ns_msg, int));
  14. -u_int ns_get16 __P((const u_char *));
  15. -u_long ns_get32 __P((const u_char *));
  16. -void ns_put16 __P((u_int, u_char *));
  17. -void ns_put32 __P((u_long, u_char *));
  18. -int ns_initparse __P((const u_char *, int, ns_msg *));
  19. -int ns_skiprr __P((const u_char *, const u_char *, ns_sect, int));
  20. -int ns_parserr __P((ns_msg *, ns_sect, int, ns_rr *));
  21. -int ns_sprintrr __P((const ns_msg *, const ns_rr *,
  22. - const char *, const char *, char *, size_t));
  23. -int ns_sprintrrf __P((const u_char *, size_t, const char *,
  24. +#ifdef __cplusplus
  25. +extern "C" {
  26. +#endif
  27. +int ns_msg_getflag (ns_msg, int);
  28. +u_int ns_get16 (const u_char *);
  29. +u_long ns_get32 (const u_char *);
  30. +void ns_put16 (u_int, u_char *);
  31. +void ns_put32 (u_long, u_char *);
  32. +int ns_initparse (const u_char *, int, ns_msg *);
  33. +int ns_skiprr (const u_char *, const u_char *, ns_sect, int);
  34. +int ns_parserr (ns_msg *, ns_sect, int, ns_rr *);
  35. +int ns_sprintrr (const ns_msg *, const ns_rr *,
  36. + const char *, const char *, char *, size_t);
  37. +int ns_sprintrrf (const u_char *, size_t, const char *,
  38. ns_class, ns_type, u_long, const u_char *,
  39. size_t, const char *, const char *,
  40. - char *, size_t));
  41. -int ns_format_ttl __P((u_long, char *, size_t));
  42. -int ns_parse_ttl __P((const char *, u_long *));
  43. -u_int32_t ns_datetosecs __P((const char *cp, int *errp));
  44. -int ns_name_ntol __P((const u_char *, u_char *, size_t));
  45. -int ns_name_ntop __P((const u_char *, char *, size_t));
  46. -int ns_name_pton __P((const char *, u_char *, size_t));
  47. -int ns_name_unpack __P((const u_char *, const u_char *,
  48. - const u_char *, u_char *, size_t));
  49. -int ns_name_pack __P((const u_char *, u_char *, int,
  50. - const u_char **, const u_char **));
  51. -int ns_name_uncompress __P((const u_char *, const u_char *,
  52. - const u_char *, char *, size_t));
  53. -int ns_name_compress __P((const char *, u_char *, size_t,
  54. - const u_char **, const u_char **));
  55. -int ns_name_skip __P((const u_char **, const u_char *));
  56. -void ns_name_rollback __P((const u_char *, const u_char **,
  57. - const u_char **));
  58. -int ns_sign __P((u_char *, int *, int, int, void *,
  59. - const u_char *, int, u_char *, int *, time_t));
  60. -int ns_sign2 __P((u_char *, int *, int, int, void *,
  61. + char *, size_t);
  62. +int ns_format_ttl (u_long, char *, size_t);
  63. +int ns_parse_ttl (const char *, u_long *);
  64. +u_int32_t ns_datetosecs (const char *cp, int *errp);
  65. +int ns_name_ntol (const u_char *, u_char *, size_t);
  66. +int ns_name_ntop (const u_char *, char *, size_t);
  67. +int ns_name_pton (const char *, u_char *, size_t);
  68. +int ns_name_unpack (const u_char *, const u_char *,
  69. + const u_char *, u_char *, size_t);
  70. +int ns_name_pack (const u_char *, u_char *, int,
  71. + const u_char **, const u_char **);
  72. +int ns_name_uncompress (const u_char *, const u_char *,
  73. + const u_char *, char *, size_t);
  74. +int ns_name_compress (const char *, u_char *, size_t,
  75. + const u_char **, const u_char **);
  76. +int ns_name_skip (const u_char **, const u_char *);
  77. +void ns_name_rollback (const u_char *, const u_char **,
  78. + const u_char **);
  79. +int ns_sign (u_char *, int *, int, int, void *,
  80. + const u_char *, int, u_char *, int *, time_t);
  81. +int ns_sign2 (u_char *, int *, int, int, void *,
  82. const u_char *, int, u_char *, int *, time_t,
  83. - u_char **, u_char **));
  84. -int ns_sign_tcp __P((u_char *, int *, int, int,
  85. - ns_tcp_tsig_state *, int));
  86. -int ns_sign_tcp2 __P((u_char *, int *, int, int,
  87. + u_char **, u_char **);
  88. +int ns_sign_tcp (u_char *, int *, int, int,
  89. + ns_tcp_tsig_state *, int);
  90. +int ns_sign_tcp2 (u_char *, int *, int, int,
  91. ns_tcp_tsig_state *, int,
  92. - u_char **, u_char **));
  93. -int ns_sign_tcp_init __P((void *, const u_char *, int,
  94. - ns_tcp_tsig_state *));
  95. -u_char *ns_find_tsig __P((u_char *, u_char *));
  96. -int ns_verify __P((u_char *, int *, void *,
  97. + u_char **, u_char **);
  98. +int ns_sign_tcp_init (void *, const u_char *, int,
  99. + ns_tcp_tsig_state *);
  100. +u_char *ns_find_tsig (u_char *, u_char *);
  101. +int ns_verify (u_char *, int *, void *,
  102. const u_char *, int, u_char *, int *,
  103. - time_t *, int));
  104. -int ns_verify_tcp __P((u_char *, int *, ns_tcp_tsig_state *, int));
  105. -int ns_verify_tcp_init __P((void *, const u_char *, int,
  106. - ns_tcp_tsig_state *));
  107. -int ns_samedomain __P((const char *, const char *));
  108. -int ns_subdomain __P((const char *, const char *));
  109. -int ns_makecanon __P((const char *, char *, size_t));
  110. -int ns_samename __P((const char *, const char *));
  111. -__END_DECLS
  112. + time_t *, int);
  113. +int ns_verify_tcp (u_char *, int *, ns_tcp_tsig_state *, int);
  114. +int ns_verify_tcp_init (void *, const u_char *, int,
  115. + ns_tcp_tsig_state *);
  116. +int ns_samedomain (const char *, const char *);
  117. +int ns_subdomain (const char *, const char *);
  118. +int ns_makecanon (const char *, char *, size_t);
  119. +int ns_samename (const char *, const char *);
  120. +#ifdef __cplusplus
  121. +}
  122. +#endif
  123. #ifdef BIND_4_COMPAT
  124. #include <arpa/nameser_compat.h>