diff options
Diffstat (limited to 'source4/libnet')
-rw-r--r-- | source4/libnet/libnet_become_dc.c | 8 | ||||
-rw-r--r-- | source4/libnet/libnet_become_dc.h | 12 |
2 files changed, 17 insertions, 3 deletions
diff --git a/source4/libnet/libnet_become_dc.c b/source4/libnet/libnet_become_dc.c index 7d1341e172..3f3bfe16b6 100644 --- a/source4/libnet/libnet_become_dc.c +++ b/source4/libnet/libnet_become_dc.c @@ -90,6 +90,7 @@ struct libnet_BecomeDC_state { struct becomeDC_fsmo rid_manager_fsmo; struct libnet_BecomeDC_CheckOptions _co; + struct libnet_BecomeDC_PrepareDB _pp; struct libnet_BecomeDC_Callbacks callbacks; }; @@ -1481,7 +1482,12 @@ static NTSTATUS becomeDC_prepare_db(struct libnet_BecomeDC_state *s) { if (!s->callbacks.prepare_db) return NT_STATUS_OK; - return s->callbacks.prepare_db(s->callbacks.private_data, NULL); + s->_pp.domain = &s->domain; + s->_pp.forest = &s->forest; + s->_pp.source_dsa = &s->source_dsa; + s->_pp.dest_dsa = &s->dest_dsa; + + return s->callbacks.prepare_db(s->callbacks.private_data, &s->_pp); } static void becomeDC_drsuapi2_bind_recv(struct rpc_request *req); diff --git a/source4/libnet/libnet_become_dc.h b/source4/libnet/libnet_become_dc.h index cffa0fd129..7549e369e4 100644 --- a/source4/libnet/libnet_become_dc.h +++ b/source4/libnet/libnet_become_dc.h @@ -75,11 +75,19 @@ struct libnet_BecomeDC_DestDSA { uint32_t user_account_control; }; +struct libnet_BecomeDC_PrepareDB { + const struct libnet_BecomeDC_Domain *domain; + const struct libnet_BecomeDC_Forest *forest; + const struct libnet_BecomeDC_SourceDSA *source_dsa; + const struct libnet_BecomeDC_DestDSA *dest_dsa; +}; + struct libnet_BecomeDC_Callbacks { void *private_data; NTSTATUS (*check_options)(void *private_data, - const struct libnet_BecomeDC_CheckOptions *options); - NTSTATUS (*prepare_db)(void *private_data, void *todo); + const struct libnet_BecomeDC_CheckOptions *info); + NTSTATUS (*prepare_db)(void *private_data, + const struct libnet_BecomeDC_PrepareDB *info); NTSTATUS (*schema_chunk)(void *private_data, void *todo); NTSTATUS (*config_chunk)(void *private_data, void *todo); NTSTATUS (*domain_chunk)(void *private_data, void *todo); |