In this paper a hyperconnectivity class that tries to address the leakage problem typical of connected filters is used. It shows similarities with the theory of viscous lattices. A novel algorithm to perform attribute filtering of viscoushyperconnected components is proposed. First, the max-tree of the image eroded by a structuring element is built: it represents the hierarchy of the cores of the hyperconnected components. Then, a processing phase takes place and the node attributes are updated consistently with the pixels of the actual hyperconnected components. Any state-of-the-art algorithm can be used to build the max-tree of the component cores. An issue arises: edges of components are not always correctly preserved. Implementation and performance are presented. A possible solution is put forward and it will be treated in future work.