Web used for terror training, spy says