Unveiling the Role of AI in Cybersecurity: Beneficial or Detrimental?