LCOV - code coverage report
Current view: top level - bin/default/source3/librpc/gen_ndr - ndr_ads.c (source / functions) Hit Total Coverage
Test: coverage report for master 70ed9daf Lines: 0 143 0.0 %
Date: 2024-01-11 09:59:51 Functions: 0 15 0.0 %

          Line data    Source code
       1             : /* parser auto-generated by pidl */
       2             : 
       3             : #include "includes.h"
       4             : #include "bin/default/source3/librpc/gen_ndr/ndr_ads.h"
       5             : 
       6             : #include "librpc/gen_ndr/ndr_nbt.h"
       7           0 : _PUBLIC_ enum ndr_err_code ndr_push_ads_saslwrap_type(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum ads_saslwrap_type r)
       8             : {
       9           0 :         NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
      10           0 :         return NDR_ERR_SUCCESS;
      11             : }
      12             : 
      13           0 : _PUBLIC_ enum ndr_err_code ndr_pull_ads_saslwrap_type(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum ads_saslwrap_type *r)
      14             : {
      15           0 :         uint16_t v;
      16           0 :         NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
      17           0 :         *r = v;
      18           0 :         return NDR_ERR_SUCCESS;
      19             : }
      20             : 
      21           0 : _PUBLIC_ void ndr_print_ads_saslwrap_type(struct ndr_print *ndr, const char *name, enum ads_saslwrap_type r)
      22             : {
      23           0 :         const char *val = NULL;
      24             : 
      25           0 :         switch (r) {
      26           0 :                 case ADS_SASLWRAP_TYPE_PLAIN: val = "ADS_SASLWRAP_TYPE_PLAIN"; break;
      27           0 :                 case ADS_SASLWRAP_TYPE_SIGN: val = "ADS_SASLWRAP_TYPE_SIGN"; break;
      28           0 :                 case ADS_SASLWRAP_TYPE_SEAL: val = "ADS_SASLWRAP_TYPE_SEAL"; break;
      29             :         }
      30           0 :         ndr_print_enum(ndr, name, "ENUM", val, r);
      31           0 : }
      32             : 
      33           0 : _PUBLIC_ enum ndr_err_code ndr_push_ads_auth_flags(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
      34             : {
      35           0 :         NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
      36           0 :         return NDR_ERR_SUCCESS;
      37             : }
      38             : 
      39           0 : _PUBLIC_ enum ndr_err_code ndr_pull_ads_auth_flags(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
      40             : {
      41           0 :         uint32_t v;
      42           0 :         NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
      43           0 :         *r = v;
      44           0 :         return NDR_ERR_SUCCESS;
      45             : }
      46             : 
      47           0 : _PUBLIC_ void ndr_print_ads_auth_flags(struct ndr_print *ndr, const char *name, uint32_t r)
      48             : {
      49           0 :         ndr_print_uint32(ndr, name, r);
      50           0 :         ndr->depth++;
      51           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_DISABLE_KERBEROS", ADS_AUTH_DISABLE_KERBEROS, r);
      52           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_NO_BIND", ADS_AUTH_NO_BIND, r);
      53           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_ANON_BIND", ADS_AUTH_ANON_BIND, r);
      54           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_SIMPLE_BIND", ADS_AUTH_SIMPLE_BIND, r);
      55           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_ALLOW_NTLMSSP", ADS_AUTH_ALLOW_NTLMSSP, r);
      56           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_SASL_SIGN", ADS_AUTH_SASL_SIGN, r);
      57           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_SASL_SEAL", ADS_AUTH_SASL_SEAL, r);
      58           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_SASL_FORCE", ADS_AUTH_SASL_FORCE, r);
      59           0 :         ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ADS_AUTH_USER_CREDS", ADS_AUTH_USER_CREDS, r);
      60           0 :         ndr->depth--;
      61           0 : }
      62             : 
      63           0 : _PUBLIC_ void ndr_print_ads_server(struct ndr_print *ndr, const char *name, const struct ads_server *r)
      64             : {
      65           0 :         ndr_print_struct(ndr, name, "ads_server");
      66           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
      67           0 :         ndr->depth++;
      68           0 :         ndr_print_string(ndr, "realm", r->realm);
      69           0 :         ndr_print_string(ndr, "workgroup", r->workgroup);
      70           0 :         ndr_print_string(ndr, "ldap_server", r->ldap_server);
      71           0 :         ndr_print_uint8(ndr, "gc", r->gc);
      72           0 :         ndr_print_uint8(ndr, "no_fallback", r->no_fallback);
      73           0 :         ndr->depth--;
      74             : }
      75             : 
      76           0 : _PUBLIC_ void ndr_print_ads_auth(struct ndr_print *ndr, const char *name, const struct ads_auth *r)
      77             : {
      78           0 :         ndr_print_struct(ndr, name, "ads_auth");
      79           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
      80           0 :         ndr->depth++;
      81           0 :         ndr_print_string(ndr, "realm", r->realm);
      82           0 :         ndr_print_string(ndr, "password", r->password);
      83           0 :         ndr_print_string(ndr, "user_name", r->user_name);
      84           0 :         ndr_print_string(ndr, "kdc_server", r->kdc_server);
      85           0 :         ndr_print_ads_auth_flags(ndr, "flags", r->flags);
      86           0 :         ndr_print_int32(ndr, "time_offset", r->time_offset);
      87           0 :         ndr_print_string(ndr, "ccache_name", r->ccache_name);
      88           0 :         ndr_print_time_t(ndr, "tgt_expire", r->tgt_expire);
      89           0 :         ndr_print_time_t(ndr, "tgs_expire", r->tgs_expire);
      90           0 :         ndr_print_time_t(ndr, "renewable", r->renewable);
      91           0 :         ndr->depth--;
      92             : }
      93             : 
      94           0 : _PUBLIC_ void ndr_print_ads_config(struct ndr_print *ndr, const char *name, const struct ads_config *r)
      95             : {
      96           0 :         ndr_print_struct(ndr, name, "ads_config");
      97           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
      98           0 :         ndr->depth++;
      99           0 :         ndr_print_nbt_server_type(ndr, "flags", r->flags);
     100           0 :         ndr_print_string(ndr, "realm", r->realm);
     101           0 :         ndr_print_string(ndr, "bind_path", r->bind_path);
     102           0 :         ndr_print_string(ndr, "ldap_server_name", r->ldap_server_name);
     103           0 :         ndr_print_string(ndr, "server_site_name", r->server_site_name);
     104           0 :         ndr_print_string(ndr, "client_site_name", r->client_site_name);
     105           0 :         ndr_print_time_t(ndr, "current_time", r->current_time);
     106           0 :         ndr_print_string(ndr, "schema_path", r->schema_path);
     107           0 :         ndr_print_string(ndr, "config_path", r->config_path);
     108           0 :         ndr_print_int32(ndr, "ldap_page_size", r->ldap_page_size);
     109           0 :         ndr->depth--;
     110             : }
     111             : 
     112           0 : _PUBLIC_ void ndr_print_ads_ldap_buf_in(struct ndr_print *ndr, const char *name, const struct ads_ldap_buf_in *r)
     113             : {
     114           0 :         ndr_print_struct(ndr, name, "ads_ldap_buf_in");
     115           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     116           0 :         ndr->depth++;
     117           0 :         ndr_print_uint32(ndr, "ofs", r->ofs);
     118           0 :         ndr_print_uint32(ndr, "needed", r->needed);
     119           0 :         ndr_print_uint32(ndr, "left", r->left);
     120           0 :         ndr_print_uint32(ndr, "max_wrapped", r->max_wrapped);
     121           0 :         ndr_print_uint32(ndr, "min_wrapped", r->min_wrapped);
     122           0 :         ndr_print_uint32(ndr, "size", r->size);
     123           0 :         ndr_print_ptr(ndr, "buf", r->buf);
     124           0 :         ndr->depth++;
     125           0 :         if (r->buf) {
     126           0 :                 ndr_print_uint8(ndr, "buf", *r->buf);
     127             :         }
     128           0 :         ndr->depth--;
     129           0 :         ndr->depth--;
     130             : }
     131             : 
     132           0 : _PUBLIC_ void ndr_print_ads_ldap_buf_out(struct ndr_print *ndr, const char *name, const struct ads_ldap_buf_out *r)
     133             : {
     134           0 :         ndr_print_struct(ndr, name, "ads_ldap_buf_out");
     135           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     136           0 :         ndr->depth++;
     137           0 :         ndr_print_uint32(ndr, "ofs", r->ofs);
     138           0 :         ndr_print_uint32(ndr, "left", r->left);
     139           0 :         ndr_print_uint32(ndr, "max_unwrapped", r->max_unwrapped);
     140           0 :         ndr_print_uint32(ndr, "sig_size", r->sig_size);
     141           0 :         ndr_print_uint32(ndr, "size", r->size);
     142           0 :         ndr_print_ptr(ndr, "buf", r->buf);
     143           0 :         ndr->depth++;
     144           0 :         if (r->buf) {
     145           0 :                 ndr_print_uint8(ndr, "buf", *r->buf);
     146             :         }
     147           0 :         ndr->depth--;
     148           0 :         ndr->depth--;
     149             : }
     150             : 
     151           0 : _PUBLIC_ void ndr_print_ads_saslwrap(struct ndr_print *ndr, const char *name, const struct ads_saslwrap *r)
     152             : {
     153           0 :         ndr_print_struct(ndr, name, "ads_saslwrap");
     154           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     155           0 :         ndr->depth++;
     156           0 :         ndr_print_ads_saslwrap_type(ndr, "wrap_type", r->wrap_type);
     157           0 :         ndr_print_ptr(ndr, "wrap_ops", r->wrap_ops);
     158             :         /* [ignore] 'wrap_ops' */
     159           0 :         ndr_print_ptr(ndr, "sbiod", r->sbiod);
     160             :         /* [ignore] 'sbiod' */
     161           0 :         ndr_print_ptr(ndr, "mem_ctx", r->mem_ctx);
     162             :         /* [ignore] 'mem_ctx' */
     163           0 :         ndr_print_ptr(ndr, "wrap_private_data", r->wrap_private_data);
     164             :         /* [ignore] 'wrap_private_data' */
     165           0 :         ndr_print_ads_ldap_buf_in(ndr, "in", &r->in);
     166           0 :         ndr_print_ads_ldap_buf_out(ndr, "out", &r->out);
     167           0 :         ndr->depth--;
     168             : }
     169             : 
     170           0 : _PUBLIC_ void ndr_print_ads_ldap(struct ndr_print *ndr, const char *name, const struct ads_ldap *r)
     171             : {
     172           0 :         ndr_print_struct(ndr, name, "ads_ldap");
     173           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     174           0 :         ndr->depth++;
     175           0 :         ndr_print_ptr(ndr, "ld", r->ld);
     176             :         /* [ignore] 'ld' */
     177           0 :         ndr_print_sockaddr_storage(ndr, "ss", &r->ss);
     178           0 :         ndr_print_time_t(ndr, "last_attempt", r->last_attempt);
     179           0 :         ndr_print_int32(ndr, "port", r->port);
     180           0 :         ndr->depth--;
     181             : }
     182             : 
     183           0 : static void ndr_print_flags_ads_struct(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct ads_struct *r)
     184             : {
     185           0 :         ndr_print_ads_struct(ndr, name, r);
     186           0 : }
     187             : 
     188           0 : _PUBLIC_ void ndr_print_ads_struct(struct ndr_print *ndr, const char *name, const struct ads_struct *r)
     189             : {
     190           0 :         ndr_print_struct(ndr, name, "ads_struct");
     191           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     192           0 :         ndr->depth++;
     193           0 :         ndr_print_ads_server(ndr, "server", &r->server);
     194           0 :         ndr_print_ads_auth(ndr, "auth", &r->auth);
     195           0 :         ndr_print_ads_config(ndr, "config", &r->config);
     196           0 :         ndr_print_ads_saslwrap(ndr, "ldap_wrap_data", &r->ldap_wrap_data);
     197           0 :         ndr_print_ads_ldap(ndr, "ldap", &r->ldap);
     198           0 :         ndr->depth--;
     199             : }
     200             : 
     201             : #ifndef SKIP_NDR_TABLE_ads
     202             : static const struct ndr_interface_public_struct ads_public_structs[] = {
     203             :         {
     204             :                 .name = "ads_struct",
     205             :                 .struct_size = sizeof(struct ads_struct ),
     206             :                 .ndr_push = (ndr_push_flags_fn_t) ndr_push_ads_struct,
     207             :                 .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_ads_struct,
     208             :                 .ndr_print = (ndr_print_function_t) ndr_print_flags_ads_struct,
     209             :         },
     210             :         { .name = NULL }
     211             : };
     212             : 
     213             : static const struct ndr_interface_call ads_calls[] = {
     214             :         { .name = NULL }
     215             : };
     216             : 
     217             : static const char * const ads_endpoint_strings[] = {
     218             :         "ncacn_np:[\\pipe\\ads]", 
     219             : };
     220             : 
     221             : static const struct ndr_interface_string_array ads_endpoints = {
     222             :         .count  = 1,
     223             :         .names  = ads_endpoint_strings
     224             : };
     225             : 
     226             : static const char * const ads_authservice_strings[] = {
     227             :         "host", 
     228             : };
     229             : 
     230             : static const struct ndr_interface_string_array ads_authservices = {
     231             :         .count  = 1,
     232             :         .names  = ads_authservice_strings
     233             : };
     234             : 
     235             : 
     236             : const struct ndr_interface_table ndr_table_ads = {
     237             :         .name           = "ads",
     238             :         .num_calls      = 0,
     239             :         .calls          = ads_calls,
     240             :         .num_public_structs     = 1,
     241             :         .public_structs         = ads_public_structs,
     242             :         .endpoints      = &ads_endpoints,
     243             :         .authservices   = &ads_authservices
     244             : };
     245             : 
     246             : #endif /* SKIP_NDR_TABLE_ads */

Generated by: LCOV version 1.14