System optimization for key management is an essential method to facilitate the wide application of key management in cryptography protocols. In the paper, we presented a threshold recovering algorithm for key distribution protocols. In the algorithm, the private keys from KGC (Key Generating Center) is encrypted and then shared among the applier members. The attack on the encrypted private keys and the threshold scheme proves computationally infeasible with exponent complexity. Besides, the threshold recovering algorithm is independent of the KGC without leakage of private information of the subgroup; therefore the threshold recovering of private keys renders effective protection for the secrecy of private parameters and applier identity. As to the efficiency of key management algorithms, we presented improved authenticated encryption scheme for key management. In the scheme, the secret transmission of essential parameters is reinforced with integrity and authenticity verification algorithms in an integrated mode; thus greatly improves the efficiency of key management.