SlideShare une entreprise Scribd logo
1  sur  31
Télécharger pour lire hors ligne
DCERPC                         Endpoint Mapper             Samba3 RPC Server     Why?




                          DCERPC and Endpoint Mapper

                             Andreas Schneider <asn@samba.org>

                                                 Red Hat


                                             May 11th, 2011




Andreas Schneider <asn@samba.org>                                              Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?




DCERPC and Endpoint Mapper
      1 DCERPC
              How does RPC work?
      2 Endpoint Mapper
              Concept
              Functions and Details
      3 Samba3 RPC Server
              Overview
              Robustness
              Scalability
      4 Why?
              Franky
              FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

How does RPC work?


DCERPC and Endpoint Mapper
      1 DCERPC
              How does RPC work?
      2 Endpoint Mapper
              Concept
              Functions and Details
      3 Samba3 RPC Server
              Overview
              Robustness
              Scalability
      4 Why?
              Franky
              FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper     Samba3 RPC Server     Why?

How does RPC work?


Abbreviations




             DCE: Distributed (Disturbed) Computing Environment
             RPC: Remote Procedure Call
             NDR: Network Data Representation
             IDL: Interface description language




Andreas Schneider <asn@samba.org>                                      Red Hat
DCERPC and Endpoint Mapper
DCERPC                            Endpoint Mapper                 Samba3 RPC Server     Why?

How does RPC work?


The RPC process


                                                     Server

                     Application                    Application



                     Client Stub                    Server Stub



                     RPC Library                    RPC Library



                      Transport                      Transport




Andreas Schneider <asn@samba.org>                                                     Red Hat
DCERPC and Endpoint Mapper
DCERPC                                  Endpoint Mapper   Samba3 RPC Server     Why?

How does RPC work?


Application

              spoolss: Printing application displaying a list of printers
              regedit: Display all values of a key

                           Server

            Application   Application



            Client Stub   Server Stub



            RPC Library   RPC Library



             Transport     Transport




Andreas Schneider <asn@samba.org>                                             Red Hat
DCERPC and Endpoint Mapper
DCERPC                                  Endpoint Mapper   Samba3 RPC Server     Why?

How does RPC work?


Client Stubs

              spoolss: Your application calling dcerpc spoolss EnumPrinters
              regedit: Your application calling dcerpc winreg EnumValues

                           Server

            Application   Application



            Client Stub   Server Stub



            RPC Library   RPC Library



             Transport     Transport




Andreas Schneider <asn@samba.org>                                             Red Hat
DCERPC and Endpoint Mapper
DCERPC                                  Endpoint Mapper   Samba3 RPC Server     Why?

How does RPC work?


Run-time Library
      RPC client implementation creating a RPC bind
              Establishes the connection
              Authenticates the user

                           Server

            Application   Application



            Client Stub   Server Stub



            RPC Library   RPC Library



             Transport     Transport




Andreas Schneider <asn@samba.org>                                             Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server           Why?

How does RPC work?


Transports



             ncacn np: SMB Named Pipes transport
             ncacn ip tcp: DCE/RPC over TCP/IP
             ncalrpc: Local interprocess communication
             ncacn http: DCE/RPC over HTTP
             ncadg ip udp, ncacn at dsp, ncacn nb ipx, ncacn dnet nsp, ...




Andreas Schneider <asn@samba.org>                                        Red Hat
DCERPC and Endpoint Mapper
DCERPC                                  Endpoint Mapper   Samba3 RPC Server     Why?

How does RPC work?


Run-time Library
              The RPC Server accepting a connection over a transport and
              creating the RPC bind
              After successfull authentication it calls the Server Stub

                           Server

            Application   Application



            Client Stub   Server Stub



            RPC Library   RPC Library



             Transport     Transport




Andreas Schneider <asn@samba.org>                                             Red Hat
DCERPC and Endpoint Mapper
DCERPC                                  Endpoint Mapper   Samba3 RPC Server     Why?

How does RPC work?


Server Stubs
      This unmarshals the packet and calls the application
      implementation
           spoolss: spoolss EnumPrinters
           regedit: winreg EnumValues

                           Server

            Application   Application



            Client Stub   Server Stub



            RPC Library   RPC Library



             Transport     Transport




Andreas Schneider <asn@samba.org>                                             Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Concept


DCERPC and Endpoint Mapper
      1 DCERPC
              How does RPC work?
      2 Endpoint Mapper
              Concept
              Functions and Details
      3 Samba3 RPC Server
              Overview
              Robustness
              Scalability
      4 Why?
              Franky
              FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Concept


Abbreviations




             EPM: Endpoint Mapper
             UUID: Universally Unique Identifier (man uuidgen)
             NDR: Network Data Representation




Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server           Why?

Concept


Terminology



             Endpoint: An endpoint could be a port or a pipe and provide
             several interfaces
             Interface: An interface is a RPC service provided by an
             endpoint
      The named pipe PIPEnetlogon can be used for netlogon and
      lsarpc connections.




Andreas Schneider <asn@samba.org>                                          Red Hat
DCERPC and Endpoint Mapper
DCERPC                          Endpoint Mapper                 Samba3 RPC Server     Why?

Concept


Remember: The RPC process


                                                   Server

                   Application                    Application



                   Client Stub                    Server Stub



                   RPC Library                    RPC Library



                    Transport                      Transport




Andreas Schneider <asn@samba.org>                                                   Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server          Why?

Concept


Endpoint operations



             Each RPC service allocates one or more endpoints dynamically
             on server startup
             Endpoint mapper maintains information about those
             endpoints
             The Endpoint Mapper listens on port 135 TCP/IP or on
             PIPEepmapper




Andreas Schneider <asn@samba.org>                                       Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Functions and Details


DCERPC and Endpoint Mapper
       1 DCERPC
                How does RPC work?
       2 Endpoint Mapper
                Concept
                Functions and Details
       3 Samba3 RPC Server
                Overview
                Robustness
                Scalability
       4 Why?
                Franky
                FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper     Samba3 RPC Server            Why?

Functions and Details


Function overview


       The most important function of the endpoint mapper.
               epm Insert Add specified entries to an endpoint map.
               epm Delete Delete specified entries from an endpoint map.
               epm Lookup Lookup entries in an endpoint map.
               epm Map Apply some algorithm to an endpoint map to
               produce a list of protocol towers. (Provide an uuid and get an
               endpoint)
               epm LookupHandleFree Free an epm Lookup or epm Map
               entry handle.



Andreas Schneider <asn@samba.org>                                           Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Functions and Details


Example




       Wireshark trace ...




Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper     Samba3 RPC Server             Why?

Functions and Details


An endpoint tower


       A tower has up to 6 floors, 4 at least
          1    Floor1: Provides the RPC interface identifier (netlogon uuid).
          2    Floor2: Transfer syntax (NDR endcoded)
          3    Floor3: RPC protocol identifier (ncacn tcp ip, ncacn np, ...)
          4    Floor4: Port address (e.g. TCP Port: 49156, PIPE)
          5    Floor5: Transport (e.g. IP:192.168.51.10, NB:krikkit)
          6    Floor6: Routing




Andreas Schneider <asn@samba.org>                                              Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Overview


DCERPC and Endpoint Mapper
      1 DCERPC
              How does RPC work?
      2 Endpoint Mapper
              Concept
              Functions and Details
      3 Samba3 RPC Server
              Overview
              Robustness
              Scalability
      4 Why?
              Franky
              FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Overview


RPC Endpoints




             Added support for TCP/IP and NCALRPC
             Other processes can register at EPM (OpenChange) over
             NCALRPC




Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Robustness


DCERPC and Endpoint Mapper
       1 DCERPC
              How does RPC work?
       2 Endpoint Mapper
              Concept
              Functions and Details
       3 Samba3 RPC Server
              Overview
              Robustness
              Scalability
       4 Why?
              Franky
              FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper       Samba3 RPC Server     Why?

Robustness


Robustness



      Client
             RPC service tries to register serveral times
             After successful registration we do connection monitoring
      Server
             We monitor the client connection
             If it goes away, delete the endpoints




Andreas Schneider <asn@samba.org>                                        Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Scalability


DCERPC and Endpoint Mapper
        1 DCERPC
              How does RPC work?
        2 Endpoint Mapper
              Concept
              Functions and Details
        3 Samba3 RPC Server
              Overview
              Robustness
              Scalability
        4 Why?
              Franky
              FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper    Samba3 RPC Server            Why?

Scalability


Pre-fork




        We started to implement a mutex locking based pre-fork model.
              Parent binds all sockets and then forks a number of children
              Childs have a lock around the accept(3) call
              Prototype working for our spoolss daemon




Andreas Schneider <asn@samba.org>                                            Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Franky


DCERPC and Endpoint Mapper
         1 DCERPC
              How does RPC work?
         2 Endpoint Mapper
              Concept
              Functions and Details
         3 Samba3 RPC Server
              Overview
              Robustness
              Scalability
         4 Why?
              Franky
              FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

Franky


Franky




             A lot of infrastructure has been created for Franky
             EPM allows us to have multiple daemons




Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server     Why?

FreeIPA


DCERPC and Endpoint Mapper
          1 DCERPC
              How does RPC work?
          2 Endpoint Mapper
              Concept
              Functions and Details
          3 Samba3 RPC Server
              Overview
              Robustness
              Scalability
          4 Why?
              Franky
              FreeIPA

Andreas Schneider <asn@samba.org>                                    Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper   Samba3 RPC Server            Why?

FreeIPA


FreeIPA




      FreeIPA is something like Active Directory but for Linux only.
             We want to be able to do forest trusts with Active Directory
             For this we need LSA and Netlogon (SAMR)
             pdb ipa and ’net rpc trust’




Andreas Schneider <asn@samba.org>                                           Red Hat
DCERPC and Endpoint Mapper
DCERPC                         Endpoint Mapper          Samba3 RPC Server     Why?

FreeIPA




                                        Questions & Answers

             Slides http://www.samba.org/~asn/




Andreas Schneider <asn@samba.org>                                           Red Hat
DCERPC and Endpoint Mapper

Contenu connexe

Tendances

NoSQL afternoon in Japan Kumofs & MessagePack
NoSQL afternoon in Japan Kumofs & MessagePackNoSQL afternoon in Japan Kumofs & MessagePack
NoSQL afternoon in Japan Kumofs & MessagePackSadayuki Furuhashi
 
RIPE 80: Buffers and Protocols
RIPE 80: Buffers and ProtocolsRIPE 80: Buffers and Protocols
RIPE 80: Buffers and ProtocolsAPNIC
 
Rpc (Distributed computing)
Rpc (Distributed computing)Rpc (Distributed computing)
Rpc (Distributed computing)Sri Prasanna
 
Remote Procedure Call (RPC) Server creation semantics &amp; call semantics
Remote Procedure Call (RPC) Server creation semantics &amp; call semanticsRemote Procedure Call (RPC) Server creation semantics &amp; call semantics
Remote Procedure Call (RPC) Server creation semantics &amp; call semanticssvm
 
CS 6390 Project design report
CS 6390 Project design reportCS 6390 Project design report
CS 6390 Project design reportRaj Gupta
 
CS 6390 Project design report
CS 6390 Project design reportCS 6390 Project design report
CS 6390 Project design reportAbhishek Datta
 
RPC communication,thread and processes
RPC communication,thread and processesRPC communication,thread and processes
RPC communication,thread and processesshraddha mane
 

Tendances (14)

NoSQL afternoon in Japan Kumofs & MessagePack
NoSQL afternoon in Japan Kumofs & MessagePackNoSQL afternoon in Japan Kumofs & MessagePack
NoSQL afternoon in Japan Kumofs & MessagePack
 
RIPE 80: Buffers and Protocols
RIPE 80: Buffers and ProtocolsRIPE 80: Buffers and Protocols
RIPE 80: Buffers and Protocols
 
Rpc (Distributed computing)
Rpc (Distributed computing)Rpc (Distributed computing)
Rpc (Distributed computing)
 
Cs 704 d rpc
Cs 704 d rpcCs 704 d rpc
Cs 704 d rpc
 
Sania rtp
Sania rtpSania rtp
Sania rtp
 
Rtp
RtpRtp
Rtp
 
Remote Procedure Call (RPC) Server creation semantics &amp; call semantics
Remote Procedure Call (RPC) Server creation semantics &amp; call semanticsRemote Procedure Call (RPC) Server creation semantics &amp; call semantics
Remote Procedure Call (RPC) Server creation semantics &amp; call semantics
 
Real-Time Streaming Protocol
Real-Time Streaming Protocol Real-Time Streaming Protocol
Real-Time Streaming Protocol
 
CS 6390 Project design report
CS 6390 Project design reportCS 6390 Project design report
CS 6390 Project design report
 
CS 6390 Project design report
CS 6390 Project design reportCS 6390 Project design report
CS 6390 Project design report
 
RPC communication,thread and processes
RPC communication,thread and processesRPC communication,thread and processes
RPC communication,thread and processes
 
RTP.ppt
RTP.pptRTP.ppt
RTP.ppt
 
Rtp
RtpRtp
Rtp
 
Rtsp
RtspRtsp
Rtsp
 

En vedette

Luis Hernandez Power Point
Luis Hernandez   Power PointLuis Hernandez   Power Point
Luis Hernandez Power Pointalumniupc
 
مساله برج هانوی
مساله برج هانویمساله برج هانوی
مساله برج هانویguestc0f47ed
 
Key Journals (ARE)
Key Journals (ARE)Key Journals (ARE)
Key Journals (ARE)ntuHLP
 
Ref Works Guide (ARE)
Ref Works Guide (ARE)Ref Works Guide (ARE)
Ref Works Guide (ARE)ntuHLP
 
Using eSearch and key databases
Using eSearch and key databasesUsing eSearch and key databases
Using eSearch and key databasesntuHLP
 
Modelo Brief Creativo
Modelo Brief CreativoModelo Brief Creativo
Modelo Brief Creativoalumniupc
 

En vedette (8)

Luis Hernandez Power Point
Luis Hernandez   Power PointLuis Hernandez   Power Point
Luis Hernandez Power Point
 
مساله برج هانوی
مساله برج هانویمساله برج هانوی
مساله برج هانوی
 
Project SEANERGY Foundation Brief
Project SEANERGY Foundation BriefProject SEANERGY Foundation Brief
Project SEANERGY Foundation Brief
 
Key Journals (ARE)
Key Journals (ARE)Key Journals (ARE)
Key Journals (ARE)
 
Perfect
PerfectPerfect
Perfect
 
Ref Works Guide (ARE)
Ref Works Guide (ARE)Ref Works Guide (ARE)
Ref Works Guide (ARE)
 
Using eSearch and key databases
Using eSearch and key databasesUsing eSearch and key databases
Using eSearch and key databases
 
Modelo Brief Creativo
Modelo Brief CreativoModelo Brief Creativo
Modelo Brief Creativo
 

Similaire à DCERPC and Endpoint Mapper

Accelerating Ceph with RDMA and NVMe-oF
Accelerating Ceph with RDMA and NVMe-oFAccelerating Ceph with RDMA and NVMe-oF
Accelerating Ceph with RDMA and NVMe-oFinside-BigData.com
 
Name Based Net Architectures
Name Based Net ArchitecturesName Based Net Architectures
Name Based Net Architectureswebhostingguy
 
Distributes objects and Rmi
Distributes objects and RmiDistributes objects and Rmi
Distributes objects and RmiMayank Jain
 
Introduction to C++ Remote Procedure Call (RPC)
Introduction to C++ Remote Procedure Call (RPC)Introduction to C++ Remote Procedure Call (RPC)
Introduction to C++ Remote Procedure Call (RPC)Abdelrahman Al-Ogail
 
Introduction to Remote Procedure Call
Introduction to Remote Procedure CallIntroduction to Remote Procedure Call
Introduction to Remote Procedure CallAbdelrahman Al-Ogail
 
2010-04-13 Reactor Pattern & Event Driven Programming 2
2010-04-13 Reactor Pattern & Event Driven Programming 22010-04-13 Reactor Pattern & Event Driven Programming 2
2010-04-13 Reactor Pattern & Event Driven Programming 2Lin Jen-Shin
 
Wireshark
WiresharkWireshark
Wiresharkbtohara
 
Node.js and Cassandra
Node.js and CassandraNode.js and Cassandra
Node.js and CassandraStratio
 
Workshop Wireshark
Workshop Wireshark Workshop Wireshark
Workshop Wireshark Fabio Rosa
 
Kernel Recipes 2014 - NDIV: a low overhead network traffic diverter
Kernel Recipes 2014 - NDIV: a low overhead network traffic diverterKernel Recipes 2014 - NDIV: a low overhead network traffic diverter
Kernel Recipes 2014 - NDIV: a low overhead network traffic diverterAnne Nicolas
 
Analyzing Time-Series Data with Apache Spark and Cassandra - StampedeCon 2016
Analyzing Time-Series Data with Apache Spark and Cassandra - StampedeCon 2016Analyzing Time-Series Data with Apache Spark and Cassandra - StampedeCon 2016
Analyzing Time-Series Data with Apache Spark and Cassandra - StampedeCon 2016StampedeCon
 
Remote procedure calls
Remote procedure callsRemote procedure calls
Remote procedure callsimnomus
 
Dos(rpc)avishek130650107020
Dos(rpc)avishek130650107020Dos(rpc)avishek130650107020
Dos(rpc)avishek130650107020Avishek Sarkar
 
Open Shift.Run2019 マイクロサービスの開発に疲れる前にdaprを使おう
Open Shift.Run2019 マイクロサービスの開発に疲れる前にdaprを使おうOpen Shift.Run2019 マイクロサービスの開発に疲れる前にdaprを使おう
Open Shift.Run2019 マイクロサービスの開発に疲れる前にdaprを使おうkei omizo
 

Similaire à DCERPC and Endpoint Mapper (20)

Accelerating Ceph with RDMA and NVMe-oF
Accelerating Ceph with RDMA and NVMe-oFAccelerating Ceph with RDMA and NVMe-oF
Accelerating Ceph with RDMA and NVMe-oF
 
Lecture9
Lecture9Lecture9
Lecture9
 
Name Based Net Architectures
Name Based Net ArchitecturesName Based Net Architectures
Name Based Net Architectures
 
Distributes objects and Rmi
Distributes objects and RmiDistributes objects and Rmi
Distributes objects and Rmi
 
Introduction to C++ Remote Procedure Call (RPC)
Introduction to C++ Remote Procedure Call (RPC)Introduction to C++ Remote Procedure Call (RPC)
Introduction to C++ Remote Procedure Call (RPC)
 
Introduction to Remote Procedure Call
Introduction to Remote Procedure CallIntroduction to Remote Procedure Call
Introduction to Remote Procedure Call
 
Polyraptor
PolyraptorPolyraptor
Polyraptor
 
2010-04-13 Reactor Pattern & Event Driven Programming 2
2010-04-13 Reactor Pattern & Event Driven Programming 22010-04-13 Reactor Pattern & Event Driven Programming 2
2010-04-13 Reactor Pattern & Event Driven Programming 2
 
cyclades eswc2016
cyclades eswc2016cyclades eswc2016
cyclades eswc2016
 
Wireshark
WiresharkWireshark
Wireshark
 
Node.js and Cassandra
Node.js and CassandraNode.js and Cassandra
Node.js and Cassandra
 
Workshop Wireshark
Workshop Wireshark Workshop Wireshark
Workshop Wireshark
 
Kernel Recipes 2014 - NDIV: a low overhead network traffic diverter
Kernel Recipes 2014 - NDIV: a low overhead network traffic diverterKernel Recipes 2014 - NDIV: a low overhead network traffic diverter
Kernel Recipes 2014 - NDIV: a low overhead network traffic diverter
 
SPARQLstream and Morph-streams
SPARQLstream and Morph-streamsSPARQLstream and Morph-streams
SPARQLstream and Morph-streams
 
Title Subtitle
Title SubtitleTitle Subtitle
Title Subtitle
 
Title Subtitle
Title SubtitleTitle Subtitle
Title Subtitle
 
Analyzing Time-Series Data with Apache Spark and Cassandra - StampedeCon 2016
Analyzing Time-Series Data with Apache Spark and Cassandra - StampedeCon 2016Analyzing Time-Series Data with Apache Spark and Cassandra - StampedeCon 2016
Analyzing Time-Series Data with Apache Spark and Cassandra - StampedeCon 2016
 
Remote procedure calls
Remote procedure callsRemote procedure calls
Remote procedure calls
 
Dos(rpc)avishek130650107020
Dos(rpc)avishek130650107020Dos(rpc)avishek130650107020
Dos(rpc)avishek130650107020
 
Open Shift.Run2019 マイクロサービスの開発に疲れる前にdaprを使おう
Open Shift.Run2019 マイクロサービスの開発に疲れる前にdaprを使おうOpen Shift.Run2019 マイクロサービスの開発に疲れる前にdaprを使おう
Open Shift.Run2019 マイクロサービスの開発に疲れる前にdaprを使おう
 

Dernier

Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfSeasiaInfotech2
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embeddingZilliz
 
Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesZilliz
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 

Dernier (20)

Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdf
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embedding
 
Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector Databases
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 

DCERPC and Endpoint Mapper

  • 1. DCERPC Endpoint Mapper Samba3 RPC Server Why? DCERPC and Endpoint Mapper Andreas Schneider <asn@samba.org> Red Hat May 11th, 2011 Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 2. DCERPC Endpoint Mapper Samba3 RPC Server Why? DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 3. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 4. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? Abbreviations DCE: Distributed (Disturbed) Computing Environment RPC: Remote Procedure Call NDR: Network Data Representation IDL: Interface description language Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 5. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? The RPC process Server Application Application Client Stub Server Stub RPC Library RPC Library Transport Transport Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 6. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? Application spoolss: Printing application displaying a list of printers regedit: Display all values of a key Server Application Application Client Stub Server Stub RPC Library RPC Library Transport Transport Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 7. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? Client Stubs spoolss: Your application calling dcerpc spoolss EnumPrinters regedit: Your application calling dcerpc winreg EnumValues Server Application Application Client Stub Server Stub RPC Library RPC Library Transport Transport Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 8. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? Run-time Library RPC client implementation creating a RPC bind Establishes the connection Authenticates the user Server Application Application Client Stub Server Stub RPC Library RPC Library Transport Transport Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 9. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? Transports ncacn np: SMB Named Pipes transport ncacn ip tcp: DCE/RPC over TCP/IP ncalrpc: Local interprocess communication ncacn http: DCE/RPC over HTTP ncadg ip udp, ncacn at dsp, ncacn nb ipx, ncacn dnet nsp, ... Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 10. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? Run-time Library The RPC Server accepting a connection over a transport and creating the RPC bind After successfull authentication it calls the Server Stub Server Application Application Client Stub Server Stub RPC Library RPC Library Transport Transport Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 11. DCERPC Endpoint Mapper Samba3 RPC Server Why? How does RPC work? Server Stubs This unmarshals the packet and calls the application implementation spoolss: spoolss EnumPrinters regedit: winreg EnumValues Server Application Application Client Stub Server Stub RPC Library RPC Library Transport Transport Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 12. DCERPC Endpoint Mapper Samba3 RPC Server Why? Concept DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 13. DCERPC Endpoint Mapper Samba3 RPC Server Why? Concept Abbreviations EPM: Endpoint Mapper UUID: Universally Unique Identifier (man uuidgen) NDR: Network Data Representation Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 14. DCERPC Endpoint Mapper Samba3 RPC Server Why? Concept Terminology Endpoint: An endpoint could be a port or a pipe and provide several interfaces Interface: An interface is a RPC service provided by an endpoint The named pipe PIPEnetlogon can be used for netlogon and lsarpc connections. Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 15. DCERPC Endpoint Mapper Samba3 RPC Server Why? Concept Remember: The RPC process Server Application Application Client Stub Server Stub RPC Library RPC Library Transport Transport Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 16. DCERPC Endpoint Mapper Samba3 RPC Server Why? Concept Endpoint operations Each RPC service allocates one or more endpoints dynamically on server startup Endpoint mapper maintains information about those endpoints The Endpoint Mapper listens on port 135 TCP/IP or on PIPEepmapper Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 17. DCERPC Endpoint Mapper Samba3 RPC Server Why? Functions and Details DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 18. DCERPC Endpoint Mapper Samba3 RPC Server Why? Functions and Details Function overview The most important function of the endpoint mapper. epm Insert Add specified entries to an endpoint map. epm Delete Delete specified entries from an endpoint map. epm Lookup Lookup entries in an endpoint map. epm Map Apply some algorithm to an endpoint map to produce a list of protocol towers. (Provide an uuid and get an endpoint) epm LookupHandleFree Free an epm Lookup or epm Map entry handle. Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 19. DCERPC Endpoint Mapper Samba3 RPC Server Why? Functions and Details Example Wireshark trace ... Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 20. DCERPC Endpoint Mapper Samba3 RPC Server Why? Functions and Details An endpoint tower A tower has up to 6 floors, 4 at least 1 Floor1: Provides the RPC interface identifier (netlogon uuid). 2 Floor2: Transfer syntax (NDR endcoded) 3 Floor3: RPC protocol identifier (ncacn tcp ip, ncacn np, ...) 4 Floor4: Port address (e.g. TCP Port: 49156, PIPE) 5 Floor5: Transport (e.g. IP:192.168.51.10, NB:krikkit) 6 Floor6: Routing Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 21. DCERPC Endpoint Mapper Samba3 RPC Server Why? Overview DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 22. DCERPC Endpoint Mapper Samba3 RPC Server Why? Overview RPC Endpoints Added support for TCP/IP and NCALRPC Other processes can register at EPM (OpenChange) over NCALRPC Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 23. DCERPC Endpoint Mapper Samba3 RPC Server Why? Robustness DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 24. DCERPC Endpoint Mapper Samba3 RPC Server Why? Robustness Robustness Client RPC service tries to register serveral times After successful registration we do connection monitoring Server We monitor the client connection If it goes away, delete the endpoints Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 25. DCERPC Endpoint Mapper Samba3 RPC Server Why? Scalability DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 26. DCERPC Endpoint Mapper Samba3 RPC Server Why? Scalability Pre-fork We started to implement a mutex locking based pre-fork model. Parent binds all sockets and then forks a number of children Childs have a lock around the accept(3) call Prototype working for our spoolss daemon Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 27. DCERPC Endpoint Mapper Samba3 RPC Server Why? Franky DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 28. DCERPC Endpoint Mapper Samba3 RPC Server Why? Franky Franky A lot of infrastructure has been created for Franky EPM allows us to have multiple daemons Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 29. DCERPC Endpoint Mapper Samba3 RPC Server Why? FreeIPA DCERPC and Endpoint Mapper 1 DCERPC How does RPC work? 2 Endpoint Mapper Concept Functions and Details 3 Samba3 RPC Server Overview Robustness Scalability 4 Why? Franky FreeIPA Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 30. DCERPC Endpoint Mapper Samba3 RPC Server Why? FreeIPA FreeIPA FreeIPA is something like Active Directory but for Linux only. We want to be able to do forest trusts with Active Directory For this we need LSA and Netlogon (SAMR) pdb ipa and ’net rpc trust’ Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper
  • 31. DCERPC Endpoint Mapper Samba3 RPC Server Why? FreeIPA Questions & Answers Slides http://www.samba.org/~asn/ Andreas Schneider <asn@samba.org> Red Hat DCERPC and Endpoint Mapper