In this paper, a novel distributed control algorithm for current sharing and voltage regulation in DC microgrids is proposed. The DC microgrid is composed of several distributed generation units, including buck converters and current loads. The considered model permits an arbitrary network topology and is affected by an unknown load demand and modeling uncertainties. The proposed control strategy exploits a communication network to achieve proportional current sharing using a consensus-like algorithm. Voltage regulation is achieved by constraining the system to a suitable manifold. Two robust control strategies of sliding mode type are developed to reach the desired manifold in a finite time. The proposed control scheme is formally analyzed...