In response to the issues of open deployment environment, weak security measures, vulnerability to security attacks, and insufficient computing and network resources of blockchain edge nodes, a blockchain security architecture based on Trusted Execution Environment (TEE), named P-Dledger, was proposed. In this architecture, by constructing a two-stage trust chain, the trustworthiness of the loaded components was ensured on the basis of meeting requirements for convenient software iteration; by constructing a trustworthy execution framework for smart contracts and a trustworthy data storage based on Serial Peripheral Interface Not OR Flash (SPI NOR Flash), the trustworthy computation of smart contracts and the secure storage of data were guaranteed. Additionally, a monotonically increasing unique identifier was assigned to consensus proposals to restrict the behavior of Byzantine nodes. Experimental and analysis results demonstrate that this architecture ensures the security and trustworthiness of loaded entities, ledger data, and execution processes. When the network latency exceeds 60 ms or the number of nodes is greater than 8, P-Dledger achieves higher throughput than blockchain systems employing Practical Byzantine Fault Tolerance (PBFT) algorithm, and P-Dledger has more stable performance as network latency and the number of nodes increase.