mirror of
https://github.com/vanhauser-thc/thc-hydra.git
synced 2025-08-21 13:53:59 -07:00
big int to stdint switch
This commit is contained in:
parent
74931e3b58
commit
f124c26fc6
73 changed files with 1364 additions and 1235 deletions
19
hydra-ncp.c
19
hydra-ncp.c
|
@ -1,4 +1,3 @@
|
|||
|
||||
/*
|
||||
* Novell Network Core Protocol Support - by David Maciejak @ GMAIL dot com
|
||||
* Tested on Netware 6.5
|
||||
|
@ -26,7 +25,7 @@ void dummy_ncp() {
|
|||
#include <ncp/nwcalls.h>
|
||||
|
||||
extern char *HYDRA_EXIT;
|
||||
extern int child_head_no;
|
||||
extern int32_t child_head_no;
|
||||
|
||||
typedef struct __NCP_DATA {
|
||||
struct ncp_conn_spec spec;
|
||||
|
@ -37,14 +36,14 @@ typedef struct __NCP_DATA {
|
|||
//uncomment line below to see more trace stack
|
||||
//#define NCP_DEBUG
|
||||
|
||||
int start_ncp(int s, char *ip, int port, unsigned char options, char *miscptr, FILE * fp) {
|
||||
int32_t start_ncp(int32_t s, char *ip, int32_t port, unsigned char options, char *miscptr, FILE * fp) {
|
||||
|
||||
char *login;
|
||||
char *pass;
|
||||
char context[256];
|
||||
unsigned int ncp_lib_error_code;
|
||||
uint32_t ncp_lib_error_code;
|
||||
char *empty = "";
|
||||
int object_type = NCP_BINDERY_USER;
|
||||
int32_t object_type = NCP_BINDERY_USER;
|
||||
|
||||
_NCP_DATA *session;
|
||||
|
||||
|
@ -135,9 +134,9 @@ int start_ncp(int s, char *ip, int port, unsigned char options, char *miscptr, F
|
|||
return 1; //reconnect
|
||||
}
|
||||
|
||||
void service_ncp(char *ip, int sp, unsigned char options, char *miscptr, FILE * fp, int port, char *hostname) {
|
||||
int run = 1, next_run = 1, sock = -1;
|
||||
int myport = PORT_NCP;
|
||||
void service_ncp(char *ip, int32_t sp, unsigned char options, char *miscptr, FILE * fp, int32_t port, char *hostname) {
|
||||
int32_t run = 1, next_run = 1, sock = -1;
|
||||
int32_t myport = PORT_NCP;
|
||||
|
||||
hydra_register_socket(sp);
|
||||
if (memcmp(hydra_get_next_pair(), &HYDRA_EXIT, sizeof(HYDRA_EXIT)) == 0)
|
||||
|
@ -153,7 +152,7 @@ void service_ncp(char *ip, int sp, unsigned char options, char *miscptr, FILE *
|
|||
sock = hydra_connect_tcp(ip, myport);
|
||||
port = myport;
|
||||
if (sock < 0) {
|
||||
if (quiet != 1) fprintf(stderr, "[ERROR] Child with pid %d terminating, can not connect\n", (int) getpid());
|
||||
if (quiet != 1) fprintf(stderr, "[ERROR] Child with pid %d terminating, can not connect\n", (int32_t) getpid());
|
||||
hydra_child_exit(1);
|
||||
}
|
||||
next_run = 2;
|
||||
|
@ -184,7 +183,7 @@ void service_ncp(char *ip, int sp, unsigned char options, char *miscptr, FILE *
|
|||
|
||||
#endif
|
||||
|
||||
int service_ncp_init(char *ip, int sp, unsigned char options, char *miscptr, FILE * fp, int port, char *hostname) {
|
||||
int32_t service_ncp_init(char *ip, int32_t sp, unsigned char options, char *miscptr, FILE * fp, int32_t port, char *hostname) {
|
||||
// called before the childrens are forked off, so this is the function
|
||||
// which should be filled if initial connections and service setup has to be
|
||||
// performed once only.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue