summaryrefslogtreecommitdiff
path: root/source4/rpc_server/epmapper
diff options
context:
space:
mode:
Diffstat (limited to 'source4/rpc_server/epmapper')
-rw-r--r--source4/rpc_server/epmapper/rpc_epmapper.c19
1 files changed, 18 insertions, 1 deletions
diff --git a/source4/rpc_server/epmapper/rpc_epmapper.c b/source4/rpc_server/epmapper/rpc_epmapper.c
index f3285729a6..7bfeaf2fee 100644
--- a/source4/rpc_server/epmapper/rpc_epmapper.c
+++ b/source4/rpc_server/epmapper/rpc_epmapper.c
@@ -116,11 +116,28 @@ static uint32 build_ep_list(TALLOC_CTX *mem_ctx,
struct dcesrv_endpoint *endpoint_list,
struct dcesrv_ep_iface **eps)
{
+ struct dcesrv_endpoint *d;
uint32 total = 0;
(*eps) = NULL;
- /* TODO */
+ for (d=endpoint_list; d; d=d->next) {
+ struct dcesrv_if_list *iface;
+
+ for (iface=d->interface_list;iface;iface=iface->next) {
+ (*eps) = talloc_realloc_p(mem_ctx, *eps,
+ struct dcesrv_ep_iface,
+ total + 1);
+ if (!*eps) {
+ return 0;
+ }
+ (*eps)[total].name = iface->iface.ndr->name;
+ (*eps)[total].uuid = iface->iface.ndr->uuid;
+ (*eps)[total].if_version = iface->iface.ndr->if_version;
+ (*eps)[total].ep_description = d->ep_description;
+ total++;
+ }
+ }
return total;
}