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 2f515e9b Lines: 0 144 0.0 %
Date: 2024-04-21 15:09:00 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, "workgroup", r->workgroup);
     101           0 :         ndr_print_string(ndr, "realm", r->realm);
     102           0 :         ndr_print_string(ndr, "bind_path", r->bind_path);
     103           0 :         ndr_print_string(ndr, "ldap_server_name", r->ldap_server_name);
     104           0 :         ndr_print_string(ndr, "server_site_name", r->server_site_name);
     105           0 :         ndr_print_string(ndr, "client_site_name", r->client_site_name);
     106           0 :         ndr_print_time_t(ndr, "current_time", r->current_time);
     107           0 :         ndr_print_string(ndr, "schema_path", r->schema_path);
     108           0 :         ndr_print_string(ndr, "config_path", r->config_path);
     109           0 :         ndr_print_int32(ndr, "ldap_page_size", r->ldap_page_size);
     110           0 :         ndr->depth--;
     111             : }
     112             : 
     113           0 : _PUBLIC_ void ndr_print_ads_ldap_buf_in(struct ndr_print *ndr, const char *name, const struct ads_ldap_buf_in *r)
     114             : {
     115           0 :         ndr_print_struct(ndr, name, "ads_ldap_buf_in");
     116           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     117           0 :         ndr->depth++;
     118           0 :         ndr_print_uint32(ndr, "ofs", r->ofs);
     119           0 :         ndr_print_uint32(ndr, "needed", r->needed);
     120           0 :         ndr_print_uint32(ndr, "left", r->left);
     121           0 :         ndr_print_uint32(ndr, "max_wrapped", r->max_wrapped);
     122           0 :         ndr_print_uint32(ndr, "min_wrapped", r->min_wrapped);
     123           0 :         ndr_print_uint32(ndr, "size", r->size);
     124           0 :         ndr_print_ptr(ndr, "buf", r->buf);
     125           0 :         ndr->depth++;
     126           0 :         if (r->buf) {
     127           0 :                 ndr_print_uint8(ndr, "buf", *r->buf);
     128             :         }
     129           0 :         ndr->depth--;
     130           0 :         ndr->depth--;
     131             : }
     132             : 
     133           0 : _PUBLIC_ void ndr_print_ads_ldap_buf_out(struct ndr_print *ndr, const char *name, const struct ads_ldap_buf_out *r)
     134             : {
     135           0 :         ndr_print_struct(ndr, name, "ads_ldap_buf_out");
     136           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     137           0 :         ndr->depth++;
     138           0 :         ndr_print_uint32(ndr, "ofs", r->ofs);
     139           0 :         ndr_print_uint32(ndr, "left", r->left);
     140           0 :         ndr_print_uint32(ndr, "max_unwrapped", r->max_unwrapped);
     141           0 :         ndr_print_uint32(ndr, "sig_size", r->sig_size);
     142           0 :         ndr_print_uint32(ndr, "size", r->size);
     143           0 :         ndr_print_ptr(ndr, "buf", r->buf);
     144           0 :         ndr->depth++;
     145           0 :         if (r->buf) {
     146           0 :                 ndr_print_uint8(ndr, "buf", *r->buf);
     147             :         }
     148           0 :         ndr->depth--;
     149           0 :         ndr->depth--;
     150             : }
     151             : 
     152           0 : _PUBLIC_ void ndr_print_ads_saslwrap(struct ndr_print *ndr, const char *name, const struct ads_saslwrap *r)
     153             : {
     154           0 :         ndr_print_struct(ndr, name, "ads_saslwrap");
     155           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     156           0 :         ndr->depth++;
     157           0 :         ndr_print_ads_saslwrap_type(ndr, "wrap_type", r->wrap_type);
     158           0 :         ndr_print_ptr(ndr, "wrap_ops", r->wrap_ops);
     159             :         /* [ignore] 'wrap_ops' */
     160           0 :         ndr_print_ptr(ndr, "sbiod", r->sbiod);
     161             :         /* [ignore] 'sbiod' */
     162           0 :         ndr_print_ptr(ndr, "mem_ctx", r->mem_ctx);
     163             :         /* [ignore] 'mem_ctx' */
     164           0 :         ndr_print_ptr(ndr, "wrap_private_data", r->wrap_private_data);
     165             :         /* [ignore] 'wrap_private_data' */
     166           0 :         ndr_print_ads_ldap_buf_in(ndr, "in", &r->in);
     167           0 :         ndr_print_ads_ldap_buf_out(ndr, "out", &r->out);
     168           0 :         ndr->depth--;
     169             : }
     170             : 
     171           0 : _PUBLIC_ void ndr_print_ads_ldap(struct ndr_print *ndr, const char *name, const struct ads_ldap *r)
     172             : {
     173           0 :         ndr_print_struct(ndr, name, "ads_ldap");
     174           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     175           0 :         ndr->depth++;
     176           0 :         ndr_print_ptr(ndr, "ld", r->ld);
     177             :         /* [ignore] 'ld' */
     178           0 :         ndr_print_sockaddr_storage(ndr, "ss", &r->ss);
     179           0 :         ndr_print_time_t(ndr, "last_attempt", r->last_attempt);
     180           0 :         ndr_print_int32(ndr, "port", r->port);
     181           0 :         ndr->depth--;
     182             : }
     183             : 
     184           0 : static void ndr_print_flags_ads_struct(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct ads_struct *r)
     185             : {
     186           0 :         ndr_print_ads_struct(ndr, name, r);
     187           0 : }
     188             : 
     189           0 : _PUBLIC_ void ndr_print_ads_struct(struct ndr_print *ndr, const char *name, const struct ads_struct *r)
     190             : {
     191           0 :         ndr_print_struct(ndr, name, "ads_struct");
     192           0 :         if (r == NULL) { ndr_print_null(ndr); return; }
     193           0 :         ndr->depth++;
     194           0 :         ndr_print_ads_server(ndr, "server", &r->server);
     195           0 :         ndr_print_ads_auth(ndr, "auth", &r->auth);
     196           0 :         ndr_print_ads_config(ndr, "config", &r->config);
     197           0 :         ndr_print_ads_saslwrap(ndr, "ldap_wrap_data", &r->ldap_wrap_data);
     198           0 :         ndr_print_ads_ldap(ndr, "ldap", &r->ldap);
     199           0 :         ndr->depth--;
     200             : }
     201             : 
     202             : #ifndef SKIP_NDR_TABLE_ads
     203             : static const struct ndr_interface_public_struct ads_public_structs[] = {
     204             :         {
     205             :                 .name = "ads_struct",
     206             :                 .struct_size = sizeof(struct ads_struct ),
     207             :                 .ndr_push = (ndr_push_flags_fn_t) ndr_push_ads_struct,
     208             :                 .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_ads_struct,
     209             :                 .ndr_print = (ndr_print_function_t) ndr_print_flags_ads_struct,
     210             :         },
     211             :         { .name = NULL }
     212             : };
     213             : 
     214             : static const struct ndr_interface_call ads_calls[] = {
     215             :         { .name = NULL }
     216             : };
     217             : 
     218             : static const char * const ads_endpoint_strings[] = {
     219             :         "ncacn_np:[\\pipe\\ads]", 
     220             : };
     221             : 
     222             : static const struct ndr_interface_string_array ads_endpoints = {
     223             :         .count  = 1,
     224             :         .names  = ads_endpoint_strings
     225             : };
     226             : 
     227             : static const char * const ads_authservice_strings[] = {
     228             :         "host", 
     229             : };
     230             : 
     231             : static const struct ndr_interface_string_array ads_authservices = {
     232             :         .count  = 1,
     233             :         .names  = ads_authservice_strings
     234             : };
     235             : 
     236             : 
     237             : const struct ndr_interface_table ndr_table_ads = {
     238             :         .name           = "ads",
     239             :         .num_calls      = 0,
     240             :         .calls          = ads_calls,
     241             :         .num_public_structs     = 1,
     242             :         .public_structs         = ads_public_structs,
     243             :         .endpoints      = &ads_endpoints,
     244             :         .authservices   = &ads_authservices
     245             : };
     246             : 
     247             : #endif /* SKIP_NDR_TABLE_ads */

Generated by: LCOV version 1.14