Implement AI_CANONIDN.