This paper investigates the basic trust problem in regard of the cyber security of Maritime Autonomous Surface Ship (MASS) system, and presents a blockchain based scheme for trust management. The main idea of using blockchain is that the mobile entities in the MASS operational environment constitute a decentralized opportunity network, which makes blockchain an appealing tool to provide a solution to maintaining trust over the dynamics of the entities. This paper elaborates the mechanism by which the MASS entities participate in the main chain. Firstly, the paper illustrates how the certificates of the entities are encoded into the chain, and how they are indexed in the chain. Secondly, at the consensus layer of the blockchain technique, the paper discusses how the witness, who temporarily has the right of producing a block and append it to the chain, can be elected among the nodes and how to incorporate the nodes to maintain the blockchain from the proof-of-stake perspective. Finally, this paper demonstrates how the MASS entities can use the authentication information carried in the blockchain to secure data exchange in their operational environment.