OpenVAS Scanner  7.0.1~git
nasl_http.h File Reference
#include "nasl_lex_ctxt.h"
Include dependency graph for nasl_http.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

tree_cellhttp_open_socket (lex_ctxt *)
 
tree_cellhttp_close_socket (lex_ctxt *)
 
tree_cellhttp_get (lex_ctxt *)
 
tree_cellhttp_head (lex_ctxt *)
 
tree_cellhttp_post (lex_ctxt *)
 
tree_cellhttp_delete (lex_ctxt *)
 
tree_cellhttp_put (lex_ctxt *)
 
tree_cellnasl_http_recv_headers (lex_ctxt *)
 
tree_cellcgibin (lex_ctxt *)
 
tree_cellnasl_is_cgi_installed (lex_ctxt *)
 
tree_cellnasl_http_keepalive_send_recv (lex_ctxt *)
 
tree_cellnasl_http_share_exists (lex_ctxt *)
 

Function Documentation

◆ cgibin()

tree_cell* cgibin ( lex_ctxt )

Definition at line 247 of file nasl_http.c.

248 {
249  const char *path = prefs_get ("cgi_path");
250  tree_cell *retc;
251 
252  (void) lexic;
253  if (path == NULL)
254  path = "/cgi-bin:/scripts";
255  retc = alloc_typed_cell (CONST_DATA);
256  retc->x.str_val = g_strdup (path);
257  retc->size = strlen (path);
258 
259  return retc;
260 }

References alloc_typed_cell(), CONST_DATA, TC::size, TC::str_val, and TC::x.

Here is the call graph for this function:

◆ http_close_socket()

tree_cell* http_close_socket ( lex_ctxt )

Definition at line 53 of file nasl_http.c.

54 {
55  return nasl_close_socket (lexic);
56 }

References nasl_close_socket().

Here is the call graph for this function:

◆ http_delete()

tree_cell* http_delete ( lex_ctxt )

Definition at line 230 of file nasl_http.c.

231 {
232  return _http_req (lexic, "DELETE");
233 }

References _http_req().

Here is the call graph for this function:

◆ http_get()

tree_cell* http_get ( lex_ctxt )

Definition at line 199 of file nasl_http.c.

200 {
201  return _http_req (lexic, "GET");
202 }

References _http_req().

Referenced by plugin_do_run().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ http_head()

tree_cell* http_head ( lex_ctxt )

Definition at line 211 of file nasl_http.c.

212 {
213  return _http_req (lexic, "HEAD");
214 }

References _http_req().

Here is the call graph for this function:

◆ http_open_socket()

tree_cell* http_open_socket ( lex_ctxt )

Definition at line 47 of file nasl_http.c.

48 {
49  return nasl_open_sock_tcp_bufsz (lexic, 65536);
50 }

References nasl_open_sock_tcp_bufsz().

Here is the call graph for this function:

◆ http_post()

tree_cell* http_post ( lex_ctxt )

Definition at line 221 of file nasl_http.c.

222 {
223  return _http_req (lexic, "POST");
224 }

References _http_req().

Here is the call graph for this function:

◆ http_put()

tree_cell* http_put ( lex_ctxt )

Definition at line 239 of file nasl_http.c.

240 {
241  return _http_req (lexic, "PUT");
242 }

References _http_req().

Here is the call graph for this function:

◆ nasl_http_keepalive_send_recv()

tree_cell* nasl_http_keepalive_send_recv ( lex_ctxt )

◆ nasl_http_recv_headers()

tree_cell* nasl_http_recv_headers ( lex_ctxt )

◆ nasl_http_share_exists()

tree_cell* nasl_http_share_exists ( lex_ctxt )

◆ nasl_is_cgi_installed()

tree_cell* nasl_is_cgi_installed ( lex_ctxt )
nasl_close_socket
tree_cell * nasl_close_socket(lex_ctxt *lexic)
Definition: nasl_socket.c:905
CONST_DATA
@ CONST_DATA
Definition: nasl_tree.h:93
TC::str_val
char * str_val
Definition: nasl_tree.h:112
TC::x
union TC::@2 x
TC::size
int size
Definition: nasl_tree.h:109
nasl_open_sock_tcp_bufsz
tree_cell * nasl_open_sock_tcp_bufsz(lex_ctxt *lexic, int bufsz)
Definition: nasl_socket.c:417
TC
Definition: nasl_tree.h:104
_http_req
static tree_cell * _http_req(lex_ctxt *lexic, char *keyword)
Definition: nasl_http.c:75
alloc_typed_cell
tree_cell * alloc_typed_cell(int typ)
Definition: nasl_tree.c:40