Nowadays, IoT devices are ubiquitous. Addressing data security issues in resource-limited devices is a key focus of IoT security. Therefore, lightweight cryptographic algorithms and their security research have received increasing attention. The uBlock is a lightweight block cipher proposed in 2019, which has advantages in software performance and hardware implementation, such as efficiency and low energy consumption. Research shows that the uBlock can effectively resist traditional analysis methods such as integral analysis and differential analysis. However, there is currently a lack of related research showing that the uBlock can effectively resist side-channel analysis. In this paper, we successfully complete the correlation power analysis on the uBlock and give specific experimental results. Subsequently, we propose a masking countermeasure for the uBlock software implementation and prove its security against correlation power analysis. Its implementation shows that the protected uBlock has increased code size, time, and RAM consumption by 37.73%, 38.31%, and 20.80%, respectively, compared to the unprotected one.