  The device-to-device (D2D) communication is one of the promising technologies
of the future Internet of Things (IoT), but its security-related issues remain
challenging. The block-chain is considered to be a secure and reliable
distributed ledger, so we can treat the device user equipment (D-UE) request
for the reusing resources of cellular user equipment (C-UE) as a transaction
and put it into a transaction pool, then package the record into the
block-chain. In this paper, we study the D2D communication resource allocation
scheme based on sparse code multiple access (SCMA). Firstly, the system's
interference model and block-chain-based transaction flow are analyzed. Then we
propose the optimization problem so that C-UE can get the maximum revenue by
sharing its resources to D-UE. This problem is NP-hard, so we propose a
heuristic algorithm based on semi-definite relaxation (SDR) programming to
solve it. Finally, the performance of the proposed algorithm is verified by
simulation of different system parameters.
