Loading src/out-certs.c +22 −1 Original line number Diff line number Diff line Loading @@ -10,6 +10,8 @@ static void cert_out_open(struct Output *out, FILE *fp) { UNUSEDPARM(out); UNUSEDPARM(fp); } Loading @@ -18,6 +20,7 @@ cert_out_open(struct Output *out, FILE *fp) static void cert_out_close(struct Output *out, FILE *fp) { UNUSEDPARM(out); fprintf(fp, "{finished: 1}\n"); } Loading @@ -27,7 +30,17 @@ static void cert_out_status(struct Output *out, FILE *fp, time_t timestamp, int status, unsigned ip, unsigned ip_proto, unsigned port, unsigned reason, unsigned ttl) { /* certificates only come with banner info, so there is no port info * to report */ UNUSEDPARM(out); UNUSEDPARM(fp); UNUSEDPARM(timestamp); UNUSEDPARM(status); UNUSEDPARM(ip); UNUSEDPARM(ip_proto); UNUSEDPARM(port); UNUSEDPARM(reason); UNUSEDPARM(ttl); } Loading @@ -41,6 +54,14 @@ cert_out_banner(struct Output *out, FILE *fp, time_t timestamp, const unsigned char *px, unsigned length) { unsigned i; UNUSEDPARM(ip_proto); UNUSEDPARM(ip); UNUSEDPARM(timestamp); UNUSEDPARM(fp); UNUSEDPARM(out); UNUSEDPARM(ttl); if (length > 5 && memcmp(px, "cert:", 5) == 0) { px += 5; length -= 5; Loading src/out-json.c +6 −0 Original line number Diff line number Diff line Loading @@ -10,6 +10,8 @@ static void json_out_open(struct Output *out, FILE *fp) { UNUSEDPARM(out); UNUSEDPARM(fp); } Loading @@ -18,6 +20,7 @@ json_out_open(struct Output *out, FILE *fp) static void json_out_close(struct Output *out, FILE *fp) { UNUSEDPARM(out); fprintf(fp, "{finished: 1}\n"); } Loading @@ -30,6 +33,7 @@ json_out_status(struct Output *out, FILE *fp, time_t timestamp, int status, { char reason_buffer[128]; UNUSEDPARM(out); UNUSEDPARM(timestamp); fprintf(fp, "{ "); fprintf(fp, " ip: \"%u.%u.%u.%u\", ", Loading Loading @@ -93,6 +97,8 @@ json_out_banner(struct Output *out, FILE *fp, time_t timestamp, { char banner_buffer[65536]; UNUSEDPARM(ttl); UNUSEDPARM(timestamp); fprintf(fp, "{ "); fprintf(fp, " ip: \"%u.%u.%u.%u\", ", Loading src/proto-ssl.c +2 −2 Original line number Diff line number Diff line Loading @@ -1082,7 +1082,7 @@ ssl_selftest(void) &more ); } if (0) { /*if (0) { const char *foo = (char*)banout_string(banout1, PROTO_X509_CERT); printf("-----BEGIN CERTIFICATE-----\n"); for (;;) { Loading @@ -1096,7 +1096,7 @@ ssl_selftest(void) } printf("-----END CERTIFICATE-----\n"); } }*/ banner1_destroy(banner1); banout_release(banout1); Loading src/proto-tcp.c +2 −0 Original line number Diff line number Diff line Loading @@ -413,6 +413,8 @@ tcpcon_destroy_tcb( struct TCP_Control_Block **r_entry; struct BannerOutput *banout; UNUSEDPARM(reason); //printf("." "tcb age = %u-sec, reason=%u \n", time(0) - tcb->when_created, reason); /* Loading vs10/masscan.vcxproj +2 −0 Original line number Diff line number Diff line Loading @@ -29,7 +29,9 @@ <ClCompile Include="..\src\in-binary.c" /> <ClCompile Include="..\src\masscan-app.c" /> <ClCompile Include="..\src\out-binary.c" /> <ClCompile Include="..\src\out-certs.c" /> <ClCompile Include="..\src\out-grepable.c" /> <ClCompile Include="..\src\out-json.c" /> <ClCompile Include="..\src\out-null.c" /> <ClCompile Include="..\src\out-redis.c" /> <ClCompile Include="..\src\out-text.c" /> Loading Loading
src/out-certs.c +22 −1 Original line number Diff line number Diff line Loading @@ -10,6 +10,8 @@ static void cert_out_open(struct Output *out, FILE *fp) { UNUSEDPARM(out); UNUSEDPARM(fp); } Loading @@ -18,6 +20,7 @@ cert_out_open(struct Output *out, FILE *fp) static void cert_out_close(struct Output *out, FILE *fp) { UNUSEDPARM(out); fprintf(fp, "{finished: 1}\n"); } Loading @@ -27,7 +30,17 @@ static void cert_out_status(struct Output *out, FILE *fp, time_t timestamp, int status, unsigned ip, unsigned ip_proto, unsigned port, unsigned reason, unsigned ttl) { /* certificates only come with banner info, so there is no port info * to report */ UNUSEDPARM(out); UNUSEDPARM(fp); UNUSEDPARM(timestamp); UNUSEDPARM(status); UNUSEDPARM(ip); UNUSEDPARM(ip_proto); UNUSEDPARM(port); UNUSEDPARM(reason); UNUSEDPARM(ttl); } Loading @@ -41,6 +54,14 @@ cert_out_banner(struct Output *out, FILE *fp, time_t timestamp, const unsigned char *px, unsigned length) { unsigned i; UNUSEDPARM(ip_proto); UNUSEDPARM(ip); UNUSEDPARM(timestamp); UNUSEDPARM(fp); UNUSEDPARM(out); UNUSEDPARM(ttl); if (length > 5 && memcmp(px, "cert:", 5) == 0) { px += 5; length -= 5; Loading
src/out-json.c +6 −0 Original line number Diff line number Diff line Loading @@ -10,6 +10,8 @@ static void json_out_open(struct Output *out, FILE *fp) { UNUSEDPARM(out); UNUSEDPARM(fp); } Loading @@ -18,6 +20,7 @@ json_out_open(struct Output *out, FILE *fp) static void json_out_close(struct Output *out, FILE *fp) { UNUSEDPARM(out); fprintf(fp, "{finished: 1}\n"); } Loading @@ -30,6 +33,7 @@ json_out_status(struct Output *out, FILE *fp, time_t timestamp, int status, { char reason_buffer[128]; UNUSEDPARM(out); UNUSEDPARM(timestamp); fprintf(fp, "{ "); fprintf(fp, " ip: \"%u.%u.%u.%u\", ", Loading Loading @@ -93,6 +97,8 @@ json_out_banner(struct Output *out, FILE *fp, time_t timestamp, { char banner_buffer[65536]; UNUSEDPARM(ttl); UNUSEDPARM(timestamp); fprintf(fp, "{ "); fprintf(fp, " ip: \"%u.%u.%u.%u\", ", Loading
src/proto-ssl.c +2 −2 Original line number Diff line number Diff line Loading @@ -1082,7 +1082,7 @@ ssl_selftest(void) &more ); } if (0) { /*if (0) { const char *foo = (char*)banout_string(banout1, PROTO_X509_CERT); printf("-----BEGIN CERTIFICATE-----\n"); for (;;) { Loading @@ -1096,7 +1096,7 @@ ssl_selftest(void) } printf("-----END CERTIFICATE-----\n"); } }*/ banner1_destroy(banner1); banout_release(banout1); Loading
src/proto-tcp.c +2 −0 Original line number Diff line number Diff line Loading @@ -413,6 +413,8 @@ tcpcon_destroy_tcb( struct TCP_Control_Block **r_entry; struct BannerOutput *banout; UNUSEDPARM(reason); //printf("." "tcb age = %u-sec, reason=%u \n", time(0) - tcb->when_created, reason); /* Loading
vs10/masscan.vcxproj +2 −0 Original line number Diff line number Diff line Loading @@ -29,7 +29,9 @@ <ClCompile Include="..\src\in-binary.c" /> <ClCompile Include="..\src\masscan-app.c" /> <ClCompile Include="..\src\out-binary.c" /> <ClCompile Include="..\src\out-certs.c" /> <ClCompile Include="..\src\out-grepable.c" /> <ClCompile Include="..\src\out-json.c" /> <ClCompile Include="..\src\out-null.c" /> <ClCompile Include="..\src\out-redis.c" /> <ClCompile Include="..\src\out-text.c" /> Loading