summary refs log tree commit diff
path: root/crypto/src/tls/TlsFatalAlertReceived.cs
blob: adf71d5b9d1a0ce13d6591173eed6e251152b9e7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
using System;
using System.Runtime.Serialization;

namespace Org.BouncyCastle.Tls
{
    [Serializable]
    public class TlsFatalAlertReceived
        : TlsException
    {
        protected readonly short m_alertDescription;

        public TlsFatalAlertReceived(short alertDescription)
            : base(Tls.AlertDescription.GetText(alertDescription))
        {
            this.m_alertDescription = alertDescription;
        }

        protected TlsFatalAlertReceived(SerializationInfo info, StreamingContext context)
            : base(info, context)
        {
        }

        public virtual short AlertDescription
        {
            get { return m_alertDescription; }
        }
    }
}