DEV Community

MustafaSamedYeyin
MustafaSamedYeyin

Posted on

Ways to Authentication

Authentication Types :

  1. Password Authentication
  2. HTTP Basic Access Authentication
  3. Session
  4. Cookie
  5. Token
  6. JWT
  7. SSO

Password Authentication

Temel Authencation tipidir.
Kullanıcı ad ve şifre unique olması gerekir.
Bruto-force dictionary saldırılarına açıktır.

HTTP Basic Access Authentication :

Web browser gerektirir.
Credentials Base64 olarak encode edilir.
Authorization: Basic olarakŞifreHeaderIcerisindeGonderilir.

Encode edildiğinde kolaylıkla decode edilebilir, Encrypt etmek için TLS kullanılır.
Man-in-the-middle için attack için açıktır.

Session - Cookie

Bu iki kavram Authentication takip etmek için kullanılır.
Oturum için bir session ID generate edilir, Sonraki istekler için client cookie üzerinde tuttuğu session'ı gönderir. Genelde server-side tarafı header üzerinde Set-Cookie ile SessionId gönderir.

Basic Token

  • Stateless'dır.
  • Serve side handling daha kolaydır.
  • Local storage'da tutar.
  • UserId gönderir.

JWT (JSON Web Token)

  • JWT Token parçaları :
    Header : HMAC, SHA256 ve RSA.
    Payload : Public claims, and private claims.
    Signature :
    Created using the encoded header, encoded payload, and a secret.

  • JWT üzerinde claims sayısı arttıkça bandwidth usage artabilir. BitWise Operatör kullanılabilir.

SSO

  • Basitçe söylemek gerekirse SSO uygulamanıza farklı bir uygulamanın bilgileriyle girilmesini sağlar.

  • SSO çalışma mantığı olarak.

  • Uygulamanıza giriş yapmak isteyen kullanıcı : SSO service'i authentication server giriş yapar, credentials check eder, user için global session tutar tutar ve token yaratır. Uygulamanız SSO servisine register olur. Uygulamanız SSO servisine register olduktan sonra token validate olur.

AWS Security LIVE!

Join us for AWS Security LIVE!

Discover the future of cloud security. Tune in live for trends, tips, and solutions from AWS and AWS Partners.

Learn More

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more