<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Rahul Vigneswaran on Medium]]></title>
        <description><![CDATA[Stories by Rahul Vigneswaran on Medium]]></description>
        <link>https://medium.com/@rahul_vigneswaran?source=rss-531a02b3390f------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*yBWD-jw2mScmEXZD</url>
            <title>Stories by Rahul Vigneswaran on Medium</title>
            <link>https://medium.com/@rahul_vigneswaran?source=rss-531a02b3390f------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 01:42:30 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@rahul_vigneswaran/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[PyTorch Vs Tensorflow]]></title>
            <link>https://medium.com/@rahul_vigneswaran/pytorch-vs-tensorflow-f78587e642a7?source=rss-531a02b3390f------2</link>
            <guid isPermaLink="false">https://medium.com/p/f78587e642a7</guid>
            <category><![CDATA[pytorch]]></category>
            <category><![CDATA[imperative-programming]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[tensorflow]]></category>
            <category><![CDATA[computer-science]]></category>
            <dc:creator><![CDATA[Rahul Vigneswaran]]></dc:creator>
            <pubDate>Fri, 07 Jun 2019 16:58:44 GMT</pubDate>
            <atom:updated>2019-06-07T16:58:44.837Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/820/1*-JnZAekQFeDKqiYfRTar0A.png" /></figure><p>The well documented <strong>Tensorflow</strong> was the Go-to for everyone who was interested in machine learning but in recent days, <strong>PyTorch</strong> has been steadily gaining momentum in the field. There are plenty of materials out there that dive deep into the Pytorch Vs Tensorflow fight. In this post, I will try to explain some of the key points that may influence one’s decision.</p><h3>PyTorch</h3><p>It is true that Pytorch has been gaining momentum in the past few years but only when we take a clear look at the demographics of the users, it is evident that almost everyone who opts for PyTorch belongs to the <strong>research community</strong>.</p><h4>So, why does PyTorch attracts the research community?</h4><ul><li><strong>Imperative Programming: </strong>This means that PyTorch does computation as we type it like most of the Python does. This enables python like abilities where we can include loops inside loops</li></ul><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fcarbon.now.sh%2Fembed%3Fbg%3Drgba%28255%252C255%252C255%252C1%29%26t%3Done-light%26wt%3Dnone%26l%3Dpython%26ds%3Dtrue%26dsyoff%3D20px%26dsblur%3D68px%26wc%3Dtrue%26wa%3Dtrue%26pv%3D56px%26ph%3D56px%26ln%3Dtrue%26fm%3DHack%26fs%3D14px%26lh%3D143%2525%26si%3Dfalse%26es%3D2x%26wm%3Dfalse%26code%3Db%252520%25253D%2525201%25250Ac%252520%25253D%2525202%25250Aa%252520%25253D%252520b%252520%25252B%252520c%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520&amp;url=https%3A%2F%2Fcarbon.now.sh%2F%3Fbg%3Drgba%28255%25252C255%25252C255%25252C1%29%26t%3Done-light%26wt%3Dnone%26l%3Dpython%26ds%3Dtrue%26dsyoff%3D20px%26dsblur%3D68px%26wc%3Dtrue%26wa%3Dtrue%26pv%3D56px%26ph%3D56px%26ln%3Dtrue%26fm%3DHack%26fs%3D14px%26lh%3D143%252525%26si%3Dfalse%26es%3D2x%26wm%3Dfalse%26code%3Db%25252520%2525253D%252525201%2525250Ac%25252520%2525253D%252525202%2525250Aa%25252520%2525253D%25252520b%25252520%2525252B%25252520c%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520&amp;image=https%3A%2F%2Fcarbon.now.sh%2Fstatic%2Fbanner.png&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=now" width="1024" height="473" frameborder="0" scrolling="no"><a href="https://medium.com/media/f285cbe17e1262c9ed8681a7fdecc983/href">https://medium.com/media/f285cbe17e1262c9ed8681a7fdecc983/href</a></iframe><p>For example, if we execute the code given aside, the computation a = b + c is done at the exact same place as the line is written, which means computation is done the moment the compiler executes that <strong>line 3</strong>.</p><p><strong>Dynamic Graphs: </strong>This means that the computational graphs are built dynamically as the program is run. <em>So, how is this feature advantageous to the user? </em>Dynamic building of the graphs enables us to make neural networks that are flexible and dynamic in nature, (i.e.) PyTorch would be useful when we want the structure of the neural network to change depending on the input data. A very good use case for such an ability would be <a href="https://lilianweng.github.io/lil-log/2018/11/30/meta-learning.html">Meta-Learning</a>.</p><h3>Tensorflow</h3><p>Unlike PyTorch, the larger demographics of people who use Tensorflow belong to the <strong>production community</strong>.</p><h4>So, why does PyTorch attracts the research community?</h4><ul><li><strong>Symbolic Programming: </strong>Contrast to<strong> </strong>Imperative programming, Symbolic programming doesn&#39;t run the computation as the line is executed. It first creates a computation graph and the computation is done towards the end of the program.</li></ul><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fcarbon.now.sh%2Fembed%3Fbg%3Drgba%28255%252C255%252C255%252C1%29%26t%3Done-light%26wt%3Dnone%26l%3Dpython%26ds%3Dtrue%26dsyoff%3D20px%26dsblur%3D68px%26wc%3Dtrue%26wa%3Dtrue%26pv%3D56px%26ph%3D56px%26ln%3Dtrue%26fm%3DHack%26fs%3D14px%26lh%3D143%2525%26si%3Dfalse%26es%3D2x%26wm%3Dfalse%26code%3Dimport%252520tensorflow%252520as%252520tf%25250A%25250Aa%252520%25253D%252520tf.constant%285%25252Cname%25253D%252522a%252522%29%25250Ab%252520%25253D%252520tf.constant%2815%25252Cname%25253D%252522b%252522%29%25250A%25250Ac%252520%25253D%252520tf.add%28a%25252Cb%25252Cname%25253D%252522c%252522%29%25250A%25250Aprint%28c%29%25250A%25250Asess%252520%25253D%252520tf.Session%28%29%25250A%25250Aoutput%252520%25253D%252520sess.run%28c%29%25250Aprint%28output%29%25250A%25250A%25250Asess.close%28%29%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520%252520&amp;url=https%3A%2F%2Fcarbon.now.sh%2F%3Fbg%3Drgba%28255%25252C255%25252C255%25252C1%29%26t%3Done-light%26wt%3Dnone%26l%3Dpython%26ds%3Dtrue%26dsyoff%3D20px%26dsblur%3D68px%26wc%3Dtrue%26wa%3Dtrue%26pv%3D56px%26ph%3D56px%26ln%3Dtrue%26fm%3DHack%26fs%3D14px%26lh%3D143%252525%26si%3Dfalse%26es%3D2x%26wm%3Dfalse%26code%3Dimport%25252520tensorflow%25252520as%25252520tf%2525250A%2525250Aa%25252520%2525253D%25252520tf.constant%285%2525252Cname%2525253D%25252522a%25252522%29%2525250Ab%25252520%2525253D%25252520tf.constant%2815%2525252Cname%2525253D%25252522b%25252522%29%2525250A%2525250Ac%25252520%2525253D%25252520tf.add%28a%2525252Cb%2525252Cname%2525253D%25252522c%25252522%29%2525250A%2525250Aprint%28c%29%2525250A%2525250Asess%25252520%2525253D%25252520tf.Session%28%29%2525250A%2525250Aoutput%25252520%2525253D%25252520sess.run%28c%29%2525250Aprint%28output%29%2525250A%2525250A%2525250Asess.close%28%29%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520%25252520&amp;image=https%3A%2F%2Fcarbon.now.sh%2Fstatic%2Fbanner.png&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=now" width="1024" height="473" frameborder="0" scrolling="no"><a href="https://medium.com/media/bd5b7ef95c4f66f89eaf72215aa7dcb9/href">https://medium.com/media/bd5b7ef95c4f66f89eaf72215aa7dcb9/href</a></iframe><p>For example, let us execute the code given aside. As we can see, the addition operation is done in <strong>line 6</strong>, so, if it were for PyTorch executing <strong>line 8</strong> would have given the output <strong>“20” </strong>but since Tensorflow follows symbolic programming, the output is just a Tensor and is “Tensor(&quot;c_5:0&quot;, shape=(), dtype=int32)”. At this stage, as the lines are executed, only the computational graph is being built. In order to run the computation, <strong>line 10 </strong>and<strong> 12 </strong>are required. As a result, line 13 gives the output “20”.</p><ul><li><strong>Static Graphs: </strong>This means that the computational graph is first built and is fixed during the actual computation. Therefore, it involves two steps — First, to create the computational graph and then do the actual computation. The main advantage of them is that the generated graphs can be reused easily with other placeholder values without the need to rebuild the graph from scratch and as the graphs are built first, we can optimize it before carrying out the actual expensive computation. Also, by doing so, the actual process becomes extremely efficient.</li></ul><p>One more advantage of Tensorflow is that it was made by keeping scalable production in mind and therefore is field tested by Google to the extreme. This makes it very reliable and efficient. But it comes at a cost of some rigidity.</p><h3>tl;dr of this tl;dr</h3><p>The best tl;dr I saw online for this battle is <a href="https://www.edureka.co/blog/pytorch-vs-tensorflow/">here</a> and is as follows,</p><blockquote>“I would use Pytorch at Home and Tensorflow at Work.”</blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f78587e642a7" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Survey on Network and Host-based Intrusion Detection Systems]]></title>
            <link>https://medium.com/@rahul_vigneswaran/survey-on-network-and-host-based-intrusion-detection-systems-8b02b4ef897?source=rss-531a02b3390f------2</link>
            <guid isPermaLink="false">https://medium.com/p/8b02b4ef897</guid>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[intrusion-detection]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[big-data]]></category>
            <category><![CDATA[deep-learning]]></category>
            <dc:creator><![CDATA[Rahul Vigneswaran]]></dc:creator>
            <pubDate>Fri, 17 May 2019 17:36:52 GMT</pubDate>
            <atom:updated>2019-05-17T17:36:52.373Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0PlVQEr9ACkMQw-Or8R2wQ.jpeg" /></figure><h3>Abstract</h3><p>The techniques of deep learning have become the state of the art methodology for executing complicated tasks from various domains of computer vision, natural language processing, and several other areas. Due to its rapid development and promising benchmarks in those fields, researchers started experimenting with this technique to perform in the area of, especially in intrusion detection related tasks. Deep learning is a subset and a natural extension of classical Machine learning and an evolved model of neural networks. This paper contemplates and discusses all the methodologies related to the leading edge Deep learning and Neural network models purposing to the arena of Intrusion Detection Systems.</p><h3>Introduction</h3><p>The field of cybersecurity has recently gained a significant importance due to the digitalization of developing countries. In several other perspectives, it is even considered as a new way of warfare, due to which several nations are pushing towards a more robust firewall for all the nation’s digital assets. This lead to the development of Intrusion Detection System (IDS), which acts as the first layer of the system and helps in identifying the inbound threats which must be apprehended for safety reasons.</p><p>IDSs are a strategically placed layer in the system that detects threats and monitors the exchanged packets. These type if security layers are there in existence since 1980’s [1]. They use the hard-coded algorithms to analyze the patterns in the captured data and filter the anomalies. These have proven effective in certain cases but due to its inherent if-else nature, the problem of false positive or false negative alarms was a common issue. Due to the false triggers of alarms by the IDS, network administrators faced increased difficulty in handling intrusion reports. Also, their inability to tackle unknown attack types rendered them useless.</p><p>Commonly there are two types of IDS that exists, namely :</p><ol><li><strong>Network based Intrusion Detection System (NIDS):</strong> NIDS is a platform which is independent and aims at detecting intrusions by examination of network traffic and monitoring multiple hosts. These type of system access traffic by behaving like a parasite to the network hub, a switch specifically designed for port mirroring. For accuracy and efficiency, the sensors are situated at the strategically chosen choke locations, often in the demilitarized zone. These receptors collect all the network data and analyze the contents of packets.</li><li><strong>Host-based Intrusion Detection System (HIDS):</strong> It usually has a singular agent embedded onto a host system that detects intrusions by going through the logs, calls made by the system, modifications of file-system and other states and activities. In HIDS, a software agent is a sensor.</li></ol><p>Traditionally, these IDS systems take advantage and make use of the signatures of known attacks to identify the inbound attacks. But due to the rapid advancement of new types of malware whose signatures are unknown, the filtering of ever-increasing types of state of the art malware becomes difficult. This paved way for the conjunction of machine learning and cybersecurity. IDS in machine learning is a classification problem. Therefore, possibly an unbiased dataset is used for training the model and that model is optimized for integrating into the IDS to predict malware more accurately. This whole prediction principle eliminates the complete dependency of malware signatures for detection, hence acting as an advantage over traditional IDS.</p><p>For the prediction model to work more efficiently, we need to feed it with a lot of training data. Often these raw data are unlabelled and come with improper feature engineering. The pitfall with traditional machine learning is that the training data must be labelled properly for the model to discover patterns and therefore provide prediction results. But this is not always possible to the vast size of the data. This is where Deep Learning (DL) has explicit advantages over conventional algorithms in scenarios of processing data that is unstructured. Pattern discovery can be done without the ancillary task of labelling. In classical machine learning theory, engineering features become an imperative part. DL lacks the feature scrutiny. This becomes vital in plots where the objective is to segregate fraudulent sequences versus non-fraudulent sequences and justify how we reached our conclusions. Fortunately, the ultimate motive of an IDS is this, which makes deep learning a perfect match for Intrusion Detection Systems.</p><h3>Big Data Analytics</h3><p>Presently, the current networks of computers are generating a huge amount of data traffic in a fast past. This generation of data is increasing continuously and the types of data that the network traffic contains is also different. Current traffic of the public satisfies all the three V’s of big data namely, volume, velocity, and variety [2]. Big Data is a term implicates the large volume of data (structured &amp; unstructured) that deluge business worldwide at a faster rate than anyone can predict. A large pool of data doesn’t always signify that everything is useful and this calls for a tool that can extract the essence from it to decide the cardinal step. This is where the Analytics of the so-called Big Data comes into play. Rapid digitization has to lead the current world to a point where we might run out storage capabilities soon. This implicates a much-required need to deduce the pool of data into useful decisions.</p><p>Detection of intrusion often involves analyzing Big data. This is defined as a research problem which the technologies of computing which are mainstream cannot cope up with the flow of information. Even an isolated source of the event can lead to Big data challenges. According to [3], a 1 Gigabytes/second of continuous network data can cause issues related to Big Data for Intrusion Detection even when inspecting deep data packets. Traditional storage methods like Relational databases inherently have the capacity to effectively gamut against the nature of Big data challenges caused by detection of intrusion. A common solution used to handle such problems is an open sourced tool called Hadoop. It is a storage platform which is distributed and is generously open-sourced. It has the capability to run on most of the hardware and has been exploited to better entertain the Big Data storage requirements of gigantic Volume and agility along with potentially very versatile data structures that are natively heterogeneous. Hadoop is collective name for several other technologies such as Pig, MapReduce, Hive, HDFS, etc.. [4] proposes the use of these technologies to overcome the hurdles in big data and states that the 3Vs are not sufficient to handle these issues and hence introduces the 3Cs concept — Cardinality, Continuity, and Complexity.</p><p>The process of mining this Big data and analyzing it is called Big Data analytics. The fast-paced emendations in aspects of processing, storing and analyzing of Big Data in recent years includes :</p><ol><li>The rapid decrease in storage expense and CPU power.</li><li>Cost-effectiveness and Flexibility of Cloud computing and Datacenters in accordance with storage and elastic computation.</li><li>Development of revolutionary and new frameworks such as Hadoop.</li></ol><p>The ultimate objective of Big Data analytics for IDS is to ensure promising, market-ready real-time intelligence. Even though it has a compelling future, there are several problems (such as data provenance, privacy) that must be diminished in order to unleash the actual potential of it.</p><h3>Neural Networks</h3><p>A Neural Network is a paradigm related to the processing of information whose thought process is motivated by the way the nervous systems of several biological parts, such as the brain, analyze and segregate information. The important aspect of this approach is the novel assembly of the system that processes information. It is built with numerous neurons which are highly connected with each other, working in unison to understand the training dataset and solve problems specific to the set. These, like people, learn by example. Learning in biological environment systems involves tuning of these links that between the neurons of multiple layers. This is true of artificial neural networks as well.</p><h3>Deep Learning</h3><p>It is a natural extension to the existing field of ML exercised with models that are motivated by the assembly and function of brain cells. One of the key aspects of Neural networks is scalability which signifies that the result’s superiority is directly proportional to the amount of data that we use but it also implies the need for significantly more computational time. In addition to the advantage of easy scaling another often stated plus point is their intuitive ability to eliminate the burden of large-scale feature engineering. Especially, DL shines in scenarios which require analogue input-outputs which enables it to work with RGB pixel data from images, text data from documents or audio data from music files rather than limiting the user to use quantities in a tabular format.</p><h3>Neural Networks and Deep learning techniques for Network based IDS (NIDS)</h3><p>The aim of an IDS is to detect abnormalities in the traffic and mitigate a possible intrusion. This must be done in an efficient way considering the ever-increasing variants of malware and types of attacks in the field of cybersecurity. The use of signature-based and traditional if-else algorithm based detection layers have been drawn ineffective which calls for the inclusion of AI in the field of NIDS to predict an inbound attack that is likely to cause damage or theft of digital assets.</p><p>Many researchers have been actively working for years now to experiment with different types of techniques and datasets to establish a Network-based IDS that has superhuman accuracies and capabilities. The use of deep learning and artificial neural networks have proven effective in such applications due to the improvement in the computational power of the commercially viable processors. To overcome the principle challenges of a traditional intrusion detection systems, [5] has proposed and implemented an analysis method that combines the abilities of kernel PCA and LSTM-RNN. To obtain the desired result, features like pre-processing of data, extraction of features, detection of attacks have been incorporated into the layer proposed by it. They have used the NSL-KDD dataset for benchmarking and has outperformed the capabilities shown by SVM, neural network, and Bayesian methods.</p><p>The experiments done by [6] with LSTM-RNNs on the KDD99 dataset has shown an accuracy of 93.82% due to their inherent ability to correlate consecutive records of connections by peeking back in time. An avant-garde DL technique for NIDs has been discussed by [7], in which they have adduced an NDAE (Non-symmetric Deep Auto-Encoder) for learning in unsupervised conditions. The outcome of it when benchmarked against both KDD99 and NSL-KDD datasets has shown a 5% improvement in accuracy and 98.81% reduction in training time. [8] has done a comparative study of deep learning like vanilla DNN, self-taught learning (STL) approach, RNN based LSTM on the KDD99 dataset and then compared with a baseline shallow algorithm that uses multinomial logistic regression to evaluate if deep learning models perform better in this scenario. An important observation that STL model could be used in a scenario where the data is unclean is made by this experimentation.</p><p>As a whole, when various methods of deep learning and neural network methods are compared with each other and studied, one can attain a state of understanding that different scenarios require different AI models. Even in NIDS, most of the models can be made to have high accuracy when proper hyperparameter tuning is done. One of the major drawback reported by all the researchers is the availability of latest ID dataset. All the research that is currently done is based on either original or modified old datasets which don’t consider the more advanced threats that the modern day NIDS is required to filter.</p><p>[11] takes a rather different approach to the whole intrusion detection system. The model learns the user behaviour and when it the new behaviour doesn’t match it, the alarm is triggered indicating a possible security breach. In this, a backpropagation neural network has been used and the results turned out with a 96% accuracy in detection of events that are unusual, with a false-alarm rate of 7%. On the other hand, [12] takes into account a variety of neural network structures to figure out the appropriate model for the current scenario. Fortunately, an early barring corroboration method is also administered during the training to substantially escalate the capability of the network to generalize, which lends an accuracy rate of 91% and 87% with two hidden neuron layers and one hidden neuron layers respectively.</p><p>The use of Genetic Network Programming is undertaken by [13] and has been combined with the fuzzy set theory for better results. KDD99 and 98 datasets have been used for benchmarking which lends success rates that are high compared with other ML techniques and data mining which is crisp with GNP. A common problem faced by all the existing approaches are false-alarm rates, however small it may be, they can cause a lot of unwanted distractions to the system administrators and an ideal IDS would have zero false-alarm rates. In the path towards the ideal IDS, [14] has tried to enhance the system’s performance by using keyword selection and neural networks. [15] have applied the technique of deletion of features one at a time for performing experiments on NNs and SVMs to estimate the hierarchy of priority of DARPA ID dataset’s input features. Hence, doing so, they have identified the important features for IDS and as a result, drastically reduced the training time.</p><p>Taking into account the reality that, terabytes of data pour through the IDS if we tried to analyze the entire traffic flow, [16] has developed an anomaly detector that considers the only certain portion of attack space that is deemed vital for the detecting things such as protocols, that are forecastable. Within the limitations of the experimental setup, the conclusions show that this model truly responds to the anomalies, not to signatures of known attacks.</p><p>[17] has taken a notable approach to IDS. Convolutional neural networks have a structure that favours computer vision and has provided significant results in that field. This significance is being transported to cybersecurity by using CNN-RNN in IDS layers and one of the main reason for choosing such an approach is the model’s ability to extract high-level features and represent the consolidated form of low-level features. Both [18] and [19] have used KDD99 as their benchmarking datasets and the former tries to run a comparison between shallow and deep neural networks in the scenario of NIDS and approves that many of the inherent characteristics of deep networks provide an overall advantage for it compared to shallow networks while the later experiments the usage of stacked-RNNs. The stacked-RNN models show reduced false-alarm rate due to its nature and potential to learn complex temporal behaviours quickly.</p><h3>Neural Networks and Deep learning techniques for Host based IDS (HIDS)</h3><p>A host-based intrusion detection system (HIDS) is a scheme that supervises and logs activities of the computer on which it is installed to alert the admin in case the protocols are breached. Host-based IDS can be conceived as an agent that oversees and analyzes whether anything or anyone (both internal and external), has bypassed the security policy of the system. NIDS is usually placed at the demilitarized zone of the network. Its purpose is to check the incoming data and eliminate threats and then pass the data forward to the proprietor if the existence of potentially malicious packets is non-existent with the transmission of data. It is more focused on the singular local node, unlike NIDS. [9] has made comprehensive experimentation by using DNNs and SVMs (Support Vector Machines) on the KDD-DARPA benchmarking dataset for making an Host-based IDS to overcome the drawbacks of the traditional hard-coded logic and algorithms. The accuracy has been concluded as greater than 99% with a training time of 17.77 sec. But here too the pitfall of inability to train with new attack patterns have been cautioned.</p><p>An approach where Radial basis functions neural networks as containers are being used by [10] for host-based IDS which proves robust compared to the soft computing methods with very low training time and high accuracy in prediction. Therefore the answer to the question about superiority is very important. The ultimate solution is using both NIDS and HIDS in conjunction with each other and AI integrated into them. In order for the host (and network) to remain secure, it is essential that we should select the right IDS scheme that is appropriate for the provided circumstances.</p><h3>Conclusion</h3><p>As the importance of IDS in the day-to-day digital world is more obvious, the necessity for a more accurate model with no false alarm rate has become apparent. To attain an algorithm that is more robust to the ever-increasing variety of malware and threats, researchers have taken an array of paths and have succeeded in achieving exponentially high accuracy rates while benchmarking with the existing publicly available dataset. It is clear that, with proper hyperparameter tuning, most of the model existing in the market can achieve superhuman ability in identifying inbound threats, which leads us to the conjunction of most of the research papers that have been made on artificial intelligence based IDS. Due to the basic principle of deep learning which dictates that more data equals more accuracy, we need to train the models with a dataset that has signatures and features of more recent advanced cyber warfare attacks, in order to prepare the research stage IDS into a robust market-ready product.</p><h3><strong>References</strong></h3><ol><li>Hodo, E., Bellekens, X., Hamilton, A., Tachtatzis, C. and Atkinson, R., 2017. Shallow and deep networks intrusion detection system: A taxonomy and survey. arXiv preprint arXiv:1701.02145.</li><li>Manzoor, M.A. and Morgan, Y., 2017. Network intrusion detection system using apache storm. Probe, 4107, p.4166.</li><li>Nassar, M., al Bouna, B., and Malluhi, Q., 2013, June. Secure outsourcing of network flow data analysis. In Big Data (BigData Congress), 2013 IEEE International Congress on (pp. 431–432). IEEE.</li><li>Suthaharan, S., 2014. Big data classification: Problems and challenges in network intrusion prediction with machine learning. ACM SIGMETRICS Performance Evaluation Review, 41(4), pp.70–73.</li><li>Meng, F., Fu, Y. and Lou, F., 2018, March. A network threat analysis method combined with kernel PCA and LSTM-RNN. In Advanced Computational Intelligence (ICACI), 2018 Tenth International Conference on (pp. 508–513). IEEE.</li><li>Staudemeyer, R.C., 2015. Applying long short-term memory recurrent neural networks to intrusion detection. South African Computer Journal, 56(1), pp.136–154.</li><li>Shone, N., Ngoc, T.N., Phai, V.D. and Shi, Q., 2018. A deep learning approach to network intrusion detection. IEEE Transactions on Emerging Topics in Computational Intelligence, 2(1), pp.41–50.</li><li>Lee, B., Amaresh, S., Green, C. and Engels, D., 2018. Comparative Study of Deep Learning Models for Network Intrusion Detection. SMU Data Science Review, 1(1), p.8.</li><li>Mukkamala, S., Janoski, G. and Sung, A., 2002. Intrusion detection using neural networks and support vector machines. In Neural Networks, 2002. IJCNN’02. Proceedings of the 2002 International Joint Conference on (Vol. 2, pp. 1702–1707). IEEE.</li><li>Ahmed, U. and Masood, A., 2009, October. Host based intrusion detection using RBF neural networks. In Emerging Technologies, 2009. ICET 2009. International Conference on (pp. 48–51). IEEE.</li><li>Ryan, J., Lin, M.J. and Miikkulainen, R., 1998. Intrusion detection with neural networks. In Advances in neural information processing systems (pp. 943–949).</li><li>Moradi, M. and Zulkernine, M., 2004, November. A neural network based system for intrusion detection and classification of attacks. In Proceedings of the IEEE International Conference on Advances in Intelligent Systems-Theory and Applications (pp. 15–18).</li><li>Mabu, S., Chen, C., Lu, N., Shimada, K. and Hirasawa, K., 2011. An intrusion-detection model based on fuzzy class-association-rule mining using genetic network programming. IEEE Transactions on Systems, Man, and Cybernetics, Part C (Applications and Reviews), 41(1), pp.130–139.</li><li>Lippmann, R.P. and Cunningham, R.K., 2000. Improving intrusion detection performance using keyword selection and neural networks. Computer networks, 34(4), pp.597–603.</li><li>Sung, A.H. and Mukkamala, S., 2003, January. Identifying important features for intrusion detection using support vector machines and neural networks. In Applications and the Internet, 2003. Proceedings. 2003 Symposium on (pp. 209–216). IEEE.</li><li>Lee, S.C. and Heinbuch, D.V., 2001. Training a neural-network based intrusion detector to recognize novel attacks. IEEE Transactions on systems, man, and Cybernetics-Part A: Systems and Humans, 31(4), pp.294–299.</li><li>Vinayakumar, R., Soman, K.P. and Poornachandran, P., 2017, September. Applying convolutional neural network for network intrusion detection. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 1222–1228). IEEE.</li><li>Rahul, V.K., Vinayakumar, R., Soman, K.P. and Poornachandran, P., 2018, July. Evaluating Shallow and Deep Neural Networks for Network Intrusion Detection Systems in Cyber Security. In 2018 9th International Conference on Computing, Communication and Networking Technologies (ICCCNT) (pp. 1–6). IEEE.</li><li>Vinayakumar, R., Soman, K.P. and Poornachandran, P., 2017. Evaluation of Recurrent Neural Network and its Variants for Intrusion Detection System (IDS). International Journal of Information System Modeling and Design (IJISMD), 8(3), pp.43–63.</li></ol><p>If you have used any of the materials from this article, kindly cite the following papers :</p><ol><li>K. Rahul Vigneswaran, R. Vinayakumar, K. Soman and P. Poornachandran, “Evaluating Shallow and Deep Neural Networks for Network Intrusion Detection Systems in Cyber Security,” 2018 9th International Conference on Computing, Communication and Networking Technologies (ICCCNT), Bangalore, 2018, pp. 1–6.</li><li>Rahul-Vigneswaran, K., Poornachandran, P., &amp; Soman, K.P. (2019). A Compendium on Network and Host based Intrusion Detection Systems. CoRR, abs/1904.03491.</li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8b02b4ef897" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Evaluating Shallow and Deep Neural Networks for Network Intrusion Detection Systems in Cyber…]]></title>
            <link>https://medium.com/@rahul_vigneswaran/machine-learning-in-cyber-security-f3497c1da7f6?source=rss-531a02b3390f------2</link>
            <guid isPermaLink="false">https://medium.com/p/f3497c1da7f6</guid>
            <category><![CDATA[intrusion-detection]]></category>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[deep-neural-networks]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[Rahul Vigneswaran]]></dc:creator>
            <pubDate>Fri, 17 May 2019 17:28:57 GMT</pubDate>
            <atom:updated>2019-05-17T17:28:57.130Z</atom:updated>
            <content:encoded><![CDATA[<h3>Evaluating Shallow and Deep Neural Networks for Network Intrusion Detection Systems in Cyber Security</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1013/1*H1Gbg1x6KFThkBVZIze97g.jpeg" /></figure><h3>Abstract</h3><p>Intrusion detection system (IDS) has become an essential layer in all the latest ICT system due to an urge towards cyber safety in the day-to-day world. Reasons including uncertainty in finding the types of attacks and increased the complexity of advanced cyber attacks, IDS calls for the need for integration of Deep Neural Networks (DNNs). In this paper, DNNs have been utilized to predict the attacks on Network Intrusion Detection System (N-IDS). A DNN with 0.1 rate of learning is applied and is run for 1000 number of epochs and KDDCup-‘99’ dataset has been used for training and benchmarking the network. For comparison purposes, the training is done on the same dataset with several other classical machine learning algorithms and DNN of layers ranging from 1 to 5. The results were compared and concluded that a DNN of 3 layers has superior performance over all the other classical machine learning algorithms.</p><h3>Introduction</h3><p>In the modern world, fast-paced technological advancements have encouraged every organization to adopt the integration of information and communication technology (ICT). Hence creating an environment where every action is routed through that system making the organization vulnerable if the security of the ICT system is compromised. Therefore, this call for a multilayered detection and protection scheme that can handle truly novel attacks on the system as well as able autonomously adapt to the new data.</p><p>There are multiple systems that can be used for shielding such ICT systems from vulnerabilities, namely — anomaly detection and IDSs. A demerit of anomaly-detection systems is the complexity involved in the process of defining rules. Each protocols being analyzed must be defined, implemented and tested for accuracy. Another pitfall relating to anomaly detection is that harmful activity that falls within the usual usage pattern is not recognized. Therefore the need for an IDS that can adapt itself to the recent novel attacks and can be trained as well as deployed by using datasets of irregular distribution becomes indispensable.</p><p>Intrusion Detect Systems (IDSs) are a range of cybersecurity based technology initially developed to detect vulnerabilities and exploits against a target host. The sole use of the IDS is to detect threats. Therefore it is located out-of-band on the infrastructure of the network and is not in the actual real-time communication passage between the sender and receiver of data. Instead, they solutions will often make use of a TAP or SPAN ports to analyze the inline traffic stream’s copy and will try to predict the attack based on a previously trained algorithm, hence making the need of a human intervention trivial [56].</p><p>In the field of cybersecurity, algorithms of machine learning have played an essential part. Especially, due to the incredible performance and potential of deep learning networks in recent days in various problems from a wide variety of fields which were considered unsolvable in past, the reliability of applying it for Artificial Intelligence (AI) and unsupervised challenges have increased [39]. Deep-learning is nothing but a partition of machine-learning that mimics the functions of the human brain and hence the name artificial neural network. The concept of deep learning consists of creating hierarchical representations that are complex that involve the creation of simple building blocks to solving of high-level problems. In recent days the application of deep learning methods are leveraged towards various use cases of cyber security such as [40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55].</p><p>Therefore it becomes obvious that Deep neural networks and IDSs, when combined together, can work at a superhuman level. Also, since the IDSs are out-of-band on the infrastructure, common attacks like DoS which primarily aims at choking the network band to gain access of the host, cannot bottleneck the performance of it, hence this security layer cannot tamper with ease. Towards the end, the sections are organized as follows: Section II reviews the work related to IDS, different deep neural networks and some discussions about KDDCup-‘99’ dataset that was published. Section III takes an in-depth look at Deep Neural Networks (DNN) and the applications of ReLU activation function. Section IV analyses the dataset used in this paper, explain the shortcoming of it and evaluates the final results. Section V concludes and states a plausible workflow into the future of this research work.</p><h3>Related Works</h3><p>The research on ID in network security has existed since the birth of the computer architectures. The use of ML techniques and solutions to holistic IDS has become common in recent days, but training data at hand is limited and are mostly used only for benchmarking purposes. DARPA datasets [1], are one of the most comprehensive datasets available publicly. The data of tepdump offered by the 1998 DARPA ID Evaluation network of 1998 was cleaned and utilized for the KDDCup-contest of 1999 at the 5th International Conference on Knowledge Discovery and Data Mining. The job was to organize the records of the connections that are already preprocessed into either traffic which is normal, or one of the following categories of attack: ‘DoS’, ‘Probing’, ‘R2L’ and ‘U2R’.</p><p>The preprocessing of the KDDCup-‘99’ competition’s data was done using the MADAMID framework [2]. The entries that used variants of decision trees showed only marginal differences in performance occupied the first three places [3, 4, 5]. The first 17 submissions of the competition were all benchmarked to perform well and are summarized [6]. The majority of published results were tested and trained with only 10\% training set observing the feature reduction on the KDDCup-‘99’ datasets [7, 8, 9]. Few researchers used custom built datasets, with extracted from the 10\% KDDCup-‘99’ training set [10, 11, 12].</p><p>There are a number of interesting publications where the results are indirectly compared due to the use of different training and test datasets. In a paper [13], genetic algorithm and decision trees were used for automatic rule generation for an intelligent system for enhancing the capability of an existing IDS. The integrated utilization of neural networks in IDS was suggested by [14] and [15]. [16] proposed an application of recurrent neural networks (RNNs) and [17] compared the neural network architectures’ performance for statistical anomaly detection to datasets from four different scenarios.</p><p>Although the datasets of KDDCup-‘99’ has various issues [18], [19] argues that they are still an effective benchmarking dataset which is publicly available to compare different intrusion detection methods.</p><p>The fundamental reason for the popularity of ML-based approaches is because of its capability to attack the constantly evolving complex and diverse threats to achieve an acceptable false positive rate of ID with a reasonable computational cost. In early stages, [36] used PNrule method which is derived from P-rules and N-rules to figure out the existence and non-existence of the class respectively. This has an advantage due to the enhancement of the detection rate in the other types of attacks except for the U2R category.</p><p>An extrapolation to traditional Feed Forward Networks (FFN) in the plane of taking inspiration from biological elements, is a network named Convolutional Neural Network (CNN). In early stages, CNN was used for processing of images by making use of normal 2D layers, pooling 2D layers and completely connected layers. [37] studied the applications of CNN for IDS with the KDDCup of ‘99’ dataset and compared the results with several other bleeding-edge algorithms. After a broad analysis, they have concluded the superiority of CNN over the other algorithms. The study of the utilization of the Long Short-Term Memory (LSTM) classifier was conducted by [38] with the same dataset. It has been stated that because of the capability of LSTM to see into the past and relate the successive records of connections demonstrates usefulness towards intrusion detection systems.</p><p>The ultimate motive of this paper is to exploit the possibility of the randomness of the inbound cyber attack which is unsuspicious to human sight but can be filtered by adding an artificial intelligence layer to the network. Hence, by training the neural network with the existing cyber attacks data, it can learn to predict an inbound attack easily and can either alert the system or initiate a pre-programmed response which may abstain the attack from proceeding further. As a result, millions worth, aftershock collateral damage and expensive data leaks can be prevented just by simply adding an extra layer to the security system. The benchmarking dataset used for training the networks are bygone and for better real-time robustness of the algorithm, more recent data must be used for retraining before deploying in the field. The obligatory of this paper is to introduce the essence of artificial neural networks into the much rapidly evolving field of cybersecurity.</p><h3>Background</h3><p>Deep neural networks (DNNs) are Artificial Neural Network (ANN) with a multi-layered structure comprised within the input-output layers. They can model complex non-linear relationships and can generate computational models where the object is expressed in terms of the layered composition of primitives.</p><p>Below we roughly cover simple DNNs and applications of ReLU and why it is preferred over other activation functions.</p><h4>Deep Neural Network (DNN)</h4><p>While traditional machine learning algorithms are linear, deep neural networks are stacked in an increasing hierarchy of complexity as well as abstraction. Each layer applies a nonlinear transformation onto its input and creates a statistical model as output from what it learns. In simple terms, the input layer is received by the input layer and passed onto the first hidden layer. These hidden layers perform mathematical computations on our inputs. One of the challenges in creating neural networks is deciding the hidden layers’ count and the count of the neurons for each layer. Each neuron has an activation function which is used to standardize the output from the neuron. The “Deep” in Deep learning refers to having more than one layer which is hidden. The output layer returns the output data. Until the output has reached an acceptable level of accuracy, epochs are continued.</p><h4>Application of rectified linear units (ReLU)</h4><p>ReLu has turned out to be more efficient and have the capacity to accelerate the entire training process altogether [20]. Usually, Neural networks use a sigmoidal activation function or tanh (hyperbolic tangent) activation functions. But these functions are prone to vanishing gradient problem [21]. Vanishing gradient occurs when lower layers of a DNN have gradients of nearly null because units of higher layers are nearly saturated at the asymptotes of the tanh function. ReLU offers an alternative to sigmoidal non-linearity which addresses the issues mentioned so far [22].</p><h3>Experiments</h3><p>We consider Keras [23] as a wrapper on top of TensorFlow[24] as software framework. For exponentially increasing the agility of processing of data in deep-learning architectures, a GPU enabled tensorflow in a single Nvidia-GK110BGL-Tesla-k40 has been used.</p><h4>Datasets description</h4><p>The DARPA’s program for ID evaluation of 1998 was managed and prepared by Lincoln Labs of MIT. The main objective of this is to analyze and conduct research in ID. A standardized dataset was prepared, which included various types of intrusions which imitated a military environment and was made publicly available. The KDD intrusion detection contest’s dataset of 1999 was a well-refined version of this [25].</p><h4>Shortcomings of KDDCup-‘99’ dataset</h4><p>ReLu has turned out to be more efficient and have the A detailed report and major shortcomings of the provided synthetic data set such as KDDCup-‘98’ and KDDCup-‘99’’ were discussed by [26]. The main condemnation was that they failed to validate their data set a simulation of real-world network traffic profile. Irrespective of all these criticisms, the dataset of KDDCup-‘99’ has been used as an effective dataset by many researchers for bench-marking the IDS algorithms over the years. In contrast to the critiques about the creation of the dataset, [27] has revealed a detailed analysis of the contents, identified the non-uniformity and simulated the artifacts in the simulated network traffic data.</p><p>The reasons behind why the machine learning classifiers have limited capability in identifying the attacks that belong to the content categories — R2L, U2R in KDDCup-‘99’ datasets have been discussed by [28]. They have concluded that it is not possible to get an acceptable detection rate using classical ML algorithms. It is also stated the possibility of getting a high detection rate in most of the cases by producing a refined and augmented data set by combining the train and test sets. However, a significant approach has not been discussed.</p><p>The DARPA / KDDCup-‘88 failed to evaluate the traditional IDS resulting in many major criticisms. To eradicate this [29] used Snort ID system on DARPA / KDDCup-‘98’ tcpdump traces. The system performed poorly resulting in low accuracy and the impermissible false positive rates. It failed in detecting dos and probing category but contrasting performing better than the detection of R2L and U2R.</p><p>Despite the harsh criticisms [30], still KDDCup-‘99’ set is one of the most widely used publicly available bench-marking datasets reliable for studies related to IDS evaluation and other security-related tasks [31]. In the effort of mitigating the underlying problems existing with KDDCup-‘99’ set, a refined version of dataset named NSL-KDD was proposed by [31]. It removed the connection redundancy records in the entire train and test data. In addition to that, the invalid records were also removed from the test data. These measures prevent the classifier from being biased in the direction of the more frequent records. Even after the refinement, this failed to solve the issues reported by [32, 33], and a new dataset named UNSW-NB15 was proposed.</p><h4>DARPA / KDDCup-‘99’ dataset</h4><p>The DARPA’s ID evaluation group, accumulated network based data of IDS by simulation of an air force base LAN by over 1000s of UNIX nodes and for continuously 9 weeks, 100s of users at a given time in Lincoln Labs which was then divided into 7 and 2 weeks of training and testing respectively to extract the raw dump data TCP. MIT’s lab with extensive financial support from DARPA and AFRL, used Windows and UNIX nodes for almost all of the inbound intrusions from an alienated LAN, unlike other OS nodes. For the purpose of the dataset, 7 distinct scenarios and 32 distinct attacks which total up to 300 attacks were simulated.</p><p>Since the year of release of KDD-‘99’ dataset [34], it is the most vastly utilized data for evaluating several IDSs. This dataset is grouped together by almost 4,900,000 individual connections which include a feature count of 41. The simulated attacks were categorized broadly as given below :</p><ol><li><strong>Denial-of-Service-Attack (DoS):</strong> Intrusion where a person aims to make a host inaccessible to its actual purpose by briefly or sometimes permanently disrupting services by flooding the target machine with enormous amounts of requests and hence overloading the host [35].</li><li><strong>User-to-Root-Attack (U2R):</strong> A category of commonly used manoeuvre by the perpetrator start by trying to gain access to a user’s pre-existing access and exploiting the holes to obtain root control.</li><li><strong>Remote-to-Local-Attack (R2L):</strong> The intrusion in which the attacker can send data packets to the target but has no user account on that machine itself, try to exploit one vulnerability to obtain local access cloaking themselves as the existing user of the target machine.</li><li><strong>Probing-Attack:</strong> The type in which the perpetrator tries to gather information about the computers of the network and the ultimate aim for doing so is to get past the firewall and gaining root access.</li></ol><p>KDDCup-‘99’ set is classified into the following three groups:</p><ol><li><strong>Basic features:</strong> Attributes obtained from a connection of TCP/IP comes from this group. Majority of these features results in implicitly delaying the detection.</li><li><strong>Traffic features:</strong> Features computed w.r.t. a window of time is categorized under this group. This can be further subdivided into 2 groups:</li><li><strong>“Same host” features</strong> The connections that have identical end host as the connection under consideration for the continuously 2 seconds fall into this category and serves the purpose of calculating the statistics of protocol behaviour, etc.</li><li><strong>“Same service” features:</strong> The connections that are only having identical services to the present connection for the last two seconds fall under this category.</li><li><strong>Content features:</strong> Generally probing attacks and DoS attacks have at least some kind of frequent sequential intrusion patterns unlike R2L and U2R attacks. This is due to the reason that they involve multiple connections to a single set of a host(s) under short span of time while the other 2 intrusions are integrated into the packets of data partitions in which generally only one connection is involved. For the detection of these types of attacks, we need some unique features by which we will be able to search for some irregular behaviour. These are called content features.</li></ol><h3>Identifying network parameters</h3><p>Hyper-tuning of parameters to figure out the optimum set of parameters to achieve the desired result is all by itself a separate field with plenty of future scope for research. In this paper, the learning is kept constant at 0.01 while the other parameters where optimized. The count of the neurons in a layer was experimented by changing it over the range of 2 to 1024. After that, the count was further increased to 1280 but didn’t yield any appreciable increase in accuracy. Therefore the neuron count was tuned to 1024.</p><h3>Identifying network structures</h3><p>Conventionally, increasing the count of the layers results in better results compared to increasing the neuron count in a layer. Therefore, the following network topologies were used in order to scrutinize and conclude the optimum network structure for our input data.</p><ul><li>DNN with 1,2,3,4,5 layers.</li></ul><p>For all the above network topologies, 100 epochs were run and the results were observed. Finally, the best performance was shown by DNN 3 layer compared to all the others. To broaden the search for better results, all the common classical machine learning algorithms were used and the results were compared to the DNN 3 layer, which still outperformed every single classical algorithm. The detailed statistical results for different network structures are reported in Table I.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/620/1*592OiDh12-tx5sHkiDhbpA.png" /><figcaption><em>Table I: Network Structure Information</em></figcaption></figure><h3>Proposed Architecture</h3><p>An overview of proposed DNN’s architecture for all use cases is shown in Fig. 1. This comprises of a hidden-layer count of 5 and an output layer. The input layer consists of 41 neurons. The neurons in input-layer to hidden-layer and hidden to output-layer are connected completely. The back-propagation mechanism is used to train the DNN networks. The proposed network is composed of fully connected layers, bias layers and dropout layers to make the network more robust.</p><p><strong>Input and hidden layers:</strong> This layer consists of 41 neurons. These are then fed into the hidden layers. Hidden layers use ReLU as the non-linear activation function. Then weights are added to feed them forward to the next hidden layer. The neuron count in each hidden layer is decreased steadily from the first to the output to make the outputs more accurate and at the same time reducing the computational cost.</p><p><strong>Regularization:</strong> To make the whole process efficient and time-saving, Dropout (0.01). The function of the dropout is to unplug the neurons randomly, making the model more robust and hence preventing it from over-fitting the training set.</p><p><strong>Output layer and classification:</strong> The out layer consists only of two neurons — Attack and Benign. Since the 1024 neurons from the previous layer must be converted into just 2 neurons, a sigmoid activation function is used. Due to the nature of the sigmoid function, it returns only two outputs, hence favouring the binary classification that was intended in this paper.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/801/1*-oiglgworPyUXMnlfxhriw.png" /><figcaption><em>Figure I: Proposed architecture</em></figcaption></figure><h3>Results</h3><p>For the scope of this paper, the KDDCup-‘99’ dataset was fed into classical ML algorithms as well as DNNs of varying hidden layers. After the training is completed, all models were compared for f1-score, accuracy, recall and precision with the test dataset. The scores for the same has been compared in detail in Table II.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/782/0*hJXw-TmWHZUVU_C2.png" /><figcaption><em>Table II: Results</em></figcaption></figure><p><em>*Support Vector Machine</em></p><p>DNN 3 layer network has outperformed all the other classical machine learning algorithms. It is so because of the ability of DNNs to extract data and features with higher abstraction and the non-linearity of the networks adds up to the advantage when compared with the other algorithms.</p><h3>Conclusion</h3><p>This paper has elaborately recapitulated the usefulness of DNNs in IDS comprehensively. For the purpose of reference, other classical ML algorithms have been accounted and compared against the results of DNN. The publicly available KDDCup-‘99’ dataset has been primarily used as the bench-marking tool for the study, through which the superiority of the DNN over the other compared algorithms have been documented clearly. For further refinement of the algorithm, this paper takes into account of DNNs with different counts of hidden layers and it was concluded that a DNN with 3 layers has been proven to be effective and accurate of all.</p><p>Since the neurons are trained with a bygone benchmarking dataset, as discussed several times in this paper, this comes as a pitfall for this methodology. Fortunately, it can be vanquished by using a fresh dataset with the essences of the latest attack strategies before the actual deployment of this artificial intelligence layer to the existing network systems to ensure the agility of the algorithm’s real-world capabilities.</p><p>From the empirical results of this paper, we may claim that deep learning methods are a promising direction towards cyber security tasks, but even though the performance on artificial dataset is exceptional, application of the same on network traffic in the real-time which contains more complex and recent attack types is necessary. Additionally, studies regarding the flexibility of these DNNs in adversarial environments are required. The increase in vast variants of deep learning algorithms calls for an overall evaluation of these algorithms in regard to its effectiveness towards IDSs. This will be one of the direction towards IDS research can travel and hence will remain as a work of future.</p><h3>References</h3><ol><li>R. Lippmann, J. Haines, D. Fried, J. Korba and K. Das. “The 1999 DARPA off-line intrusion detection evaluation”. Computer networks, vol. 34, no. 4, pp. 579– 595, 2000. DOI <a href="http://dx.doi.org/10.1016/S1389-">http://dx.doi.org/10.1016/S1389-</a> 1286(00)00139–0.</li><li>W. Lee and S. Stolfo. “A framework for constructing features and models for intrusion detectionsystems”. ACM transactions on information and system security, vol. 3, no. 4, pp. 227–261, 2000. DOI <a href="http://dx.doi./">http://dx.doi.</a> Org/10.1145/382912.382914.</li><li>B. Pfahringer. “Winning the KDD99 classification cup: Bagged boosting”. SIGKDD explorations newsletter, vol. 1, pp. 65–66, 2000. DOI <a href="http://dx.doi.org/10.">http://dx.doi.org/10.</a> 1145/846183.846200.</li><li>M. Vladimir, V. Alexei and S. Ivan. “The MP13 approach to the KDD’99 classifier learning contest”. SIGKDD explorations newsletter, vol. 1, pp. 76– 77, 2000. DOI <a href="http://dx.doi.org/10.1145/846183.">http://dx.doi.org/10.1145/846183.</a> 846202.</li><li>R. Agarwal and M. Joshi. “PNrule: A new framework for learning classier models in data mining”. Tech. Rep. 00–015, Department of Computer Science, University of Minnesota, 2000.</li><li>C. Elkan. “Results of the KDD’99 classifier learning”. SIGKDD explorations newsletter, vol. 1, pp. 63– 64, 2000. DOI <a href="http://dx.doi.org/10.1145/846183.">http://dx.doi.org/10.1145/846183.</a> 846199.</li><li>S. Sung, A.H. Mukkamala. “Identifying important features for intrusion detection using support vector machines and neural networks”. In Proceedings of the symposium on applications and the Internet (SAINT), pp. 209–216. IEEE Computer Society, 2003. DOI http: //dx.doi.org/10.1109/saint.2003.1183050.</li><li>H. Kayacik, A. Zincir-Heywood and M. Heywood. “Selecting features for intrusion detection: A feature relevance analysison KDD 99 intrusion detection datasets”. In Proceedings of the third annual conference on privacy, security and trust (PST). 2005.</li><li>C. Lee, S. Shin and J. Chung. “Network intrusion detection through genetic feature selection”. In Seventh ACIS international conference on software engineering, artificial intelligence, networking, and parallel/distributed computing (SNPD), pp. 109–114. IEEE Computer Society, 2006</li><li>S. Chavan, K. Shah, N. Dave, S. Mukherjee, A. Abraham and S. Sanyal. “Adaptive neuro-fuzzy intrusion detection systems”. In Proceedings of the international conference on information technology: Coding and computing (ITCC), vol. 1, pp. 70–74. IEEE Computer Society, 2004. DOI <a href="http://dx.doi.org/">http://dx.doi.org/</a> 10.1109/itcc.2004.1286428.</li><li>S. Chebrolu, A. Abraham and J. Thomas. “Feature deduction and ensemble design of intrusion detection systems”. Computers \&amp; security, vol. 24, no. 4, pp. 295–307, 2005. DOI <a href="http://dx.doi.org/10.1016/j.">http://dx.doi.org/10.1016/j.</a> Cose.2004.09.008.</li><li>Y. Chen, A. Abraham and J. Yang. “Feature selection and intrusion detection using hybrid flexible neural tree”. In Advances in neural networks (ISNN), vol. 3498 of Lecture notes in computer science, pp. 439– 444. Springer Berlin / Heidelberg, 2005. DOI http: //dx.doi.org/10.1007/11427469_71.</li><li>C. Sinclair, L. Pierce and S. Matzner. “An application of machine learning to network intrusion detection”. In Proceedings of the 15th annual computer security applications conference (ACSAC), pp. 371–377. IEEE Computer Society, 1999. DOI <a href="http://dx.doi.org/">http://dx.doi.org/</a> 10.1109/csac.1999.816048.</li><li>H. Debar, M. Becker and D. Siboni. “A neural network component for an intrusion detection system”. In Proceedings of the IEEE computer society symposium on research in security and privacy, pp. 240–250. IEEE Computer Society, 1992. DOI <a href="http://dx.doi.org/">http://dx.doi.org/</a> 10.1109/risp.1992.213257.</li><li>J. Cannady. “Artificial neural networks for misuse detection”. In Proceedings of the 1998 national information systems security conference (NISSC), pp. 443–456. Citeseer, 1998.</li><li>H. Debar and B. Dorizzi. “An application of a recurrent network to an intrusion detection system”. In International joint conference on neural networks, 1992. IJCNN., vol. 2, pp. 478 –483 vol.2. jun 1992. DOI <a href="http://dx.doi.org/10.1109/ijcnn.">http://dx.doi.org/10.1109/ijcnn.</a> 1992.226942.</li><li>Z. Zhang, J. Lee, C. Manikopoulos, J. Jorgenson and J. Ucles. “Neural networks in statistical anomaly intrusion detection”. Neural network world, vol. 11, no. 3, pp. 305–316, 2001.</li><li>J. McHugh. “Testing intrusion detection systems: A critique of the 1998 and 1999 DARPA intrusion detection system evaluations as performed by Lincoln Laboratory”. ACM transactions on information and system security, vol. 3, no. 4, pp. 262–294, 2000. DOI <a href="http://dx.doi.org/10.1145/382912.382923.">http://dx.doi.org/10.1145/382912.382923.</a></li><li>M. Tavallaee, E. Bagheri, W. Lu and A. A. Ghorbani. “A detailed analysis of the KDD CUP 99 data set”. In IEEE symposium on computational intelligence for security and defense applications, Cisda, pp. 1–6. IEEE, Jul. 2009. DOI <a href="http://dx.doi.org/10.1109/cisda.">http://dx.doi.org/10.1109/cisda.</a> 2009.5356528.</li><li>X. Glorot, A. Bordes, and Y. Bengio, “Deep sparse rectifier neural networks,” in Proceedings of the Fourteenth International Conference on Artificial Intelligence and Statistics, 2011, pp. 315–323.</li><li>Bengio, Y., Simard, P. and Frasconi, P., 1994. Learning long-term dependencies with gradient descent is difficult. IEEE transactions on neural networks, 5(2), pp.157–166.</li><li>Maas, A.L., Hannun, A.Y. and Ng, A.Y., 2013, June. Rectifier nonlinearities improve neural network acoustic models. In Proc. icml (Vol. 30, №1, p. 3).</li><li>F. Chollet, “Keras (2015),” URL <a href="http://keras./">http://keras.</a> Io, 2017.</li><li>M. Abadi, P. Barham, J. Chen, Z. Chen, A. Davis, J. Dean, M. Devin, S. Ghemawat, G. Irving, M. Isard et al., “Tensorflow: A system for large-scale machine learning.” in OSDI, vol. 16, 2016, pp. 265–283.</li><li>Stolfo, S., Fan, W. and Lee, W., KDD-CUP-99 Task Description. 1999–10–28)[2009–05–08]. <a href="http://kdd./">http://KDD.</a> ics. uci. edu/databases/kddcup99/task, html.</li><li>J. McHugh. “Testing intrusion detection systems: A critique of the 1998 and 1999 DARPA intrusion detection system evaluations as performed by Lincoln Laboratory”. ACM transactions on information and system security, vol. 3, no. 4, pp. 262–294, 2000. DOI <a href="http://dx.doi.org/10.1145/382912.382923.">http://dx.doi.org/10.1145/382912.382923.</a></li><li>M. Mahoney and P. Chan. “An analysis of the 1999 DARPA/Lincoln Laboratory evaluation data for network anomaly detection”. In Recent advances in intrusion detection, vol. 2820 of Lecture notes in computer science, pp. 220–237. Springer Berlin / Heidelberg, 2003.</li><li>Sabhnani, Maheshkumar, and Gursel Serpen. “Why machine learning algorithms fail in misuse detection on KDD intrusion detection data set.” Intelligent Data Analysis 8, no. 4 (2004): 403–415.</li><li>S. Brugger and J. Chow. “An assessment of the DARPA IDS evaluation dataset using snort”. Tech. Rep. CSE-2007–1, Department of Computer Science, University of California, Davis (UCDAVIS), 2005.</li><li>J. McHugh. “Testing intrusion detection systems:A critique of the 1998 and 1999 DARPA intrusion detection system evaluations as performed by Lincoln Laboratory”. ACM transactions on information and system security, vol. 3, no. 4, pp. 262–294, 2000. DOI <a href="http://dx.doi.org/10.1145/382912.382923.">http://dx.doi.org/10.1145/382912.382923.</a></li><li>Tavallaee, Mahbod, Ebrahim Bagheri, Wei Lu, and Ali-A. Ghorbani. “A detailed analysis of the KDD CUP 99 data set.” In Proceedings of the Second IEEE Symposium on Computational Intelligence for Security and Defence Applications 2009. 2009.</li><li>Moustafa, Nour, and Jill Slay. “The evaluation of Network Anomaly Detection Systems: Statistical analysis of the U[8] H. Kayacik, A. Zincir-Heywood and M. Heywood. “Selecting features for intrusion detection: A feature relevance analysison KDD 99 intrusion detection datasets”. In Proceedings of the third annual conference on privacy, security and trust (PST). 2005.</li><li>Moustafa, Nour, and Jill Slay. “UNSW-NB15: a comprehensive data set for network intrusion detection systems (UNSW-NB15 network data).”Military Communications and Information Systems Conference (MilCIS), 2015. IEEE, 2015.</li><li>KDD Cup 1999. Available on: <a href="http://kdd.ics.uci.edu/database[8]">http://kdd.ics.uci.edu/database[8]</a> H. Kayacik, A. Zincir-Heywood and M. Heywood. “Selecting features for intrusion detection: A feature relevance analysison KDD 99 intrusion detection datasets”. In Proceedings of the third annual conference on privacy, security and trust (PST). 2005.</li><li>McDowell, M. (2013). Understanding Denial-of-Service Attacks US-CERT. United States Computer Emergency Readiness Team.</li><li>R. Agarwal and M. V. Joshi, “Pnrule: A new framework for learning classifier models in data mining (a case-study in network intrusion detection),” in Proceedings of the 2001 SIAM International Conference on Data Mining. SIAM, 2001, pp. 1–17.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Applying convolutional neural network for network intrusion detection. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 1222–1228). IEEE.</li><li>Staudemeyer, R. C. (2015). Applying long short-term memory recurrent neural networks to intrusion detection. South African Computer Journal, 56(1), 136–154.</li><li>Sommer, R. and Paxson, V., 2010, May. Outside the closed world: On using machine learning for network intrusion detection. In Security and Privacy (SP), 2010 IEEE Symposium on (pp. 305–316). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2018). Evaluating deep learning approaches to characterize and classify malicious URL’s. Journal of Intelligent \&amp; Fuzzy Systems, 34(3), 1333–1343.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2018). Detecting malicious domain names using deep learning approaches at scale. Journal of Intelligent \&amp; Fuzzy Systems, 34(3), 1355–1367.</li><li>Vinayakumar, R., Soman, K. P., Poornachandran, P., \&amp; Sachin Kumar, S. (2018). Evaluating deep learning approaches to characterize and classify the DGAs at scale. Journal of Intelligent \&amp; Fuzzy Systems, 34(3), 1265–1276.</li><li>Vinayakumar, R., Poornachandran, P., \&amp; Soman, K. P. (2018). Scalable Framework for Cyber Threat Situational Awareness Based on Domain Name Systems Data Analysis. In Big Data in Engineering Applications (pp. 113–142). Springer, Singapore.</li><li>Vinayakumar, R., Soman, K. P., Poornachandran, P., \&amp; Sachin Kumar, S. (2018). Detecting Android malware using long short-term memory (LSTM). Journal of Intelligent \&amp; Fuzzy Systems, 34(3), 1277–1288.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Deep encrypted text categorization. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 364–370). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Secure shell (ssh) traffic analysis with flow based features using shallow and deep networks. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 2026–2032). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Evaluating shallow and deep networks for secure shell (ssh) traffic analysis. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 266–274). IEEE.</li><li>Vinayakumar, R., Soman, K. P., Velan, K. S., \&amp; Ganorkar, S. (2017, September). Evaluating shallow and deep networks for ransomware detection and classification. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 259–265). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Applying deep learning approaches for network traffic prediction. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 2353–2358). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Long short-term memory based operation log anomaly detection. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 236–242). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Deep android malware detection and classification. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 1677–1683). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Applying convolutional neural network for network intrusion detection. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 1222–1228). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017, September). Evaluating effectiveness of shallow and deep networks to intrusion detection system. In Advances in Computing, Communications and Informatics (ICACCI), 2017 International Conference on (pp. 1282–1289). IEEE.</li><li>Vinayakumar, R., Soman, K. P., \&amp; Poornachandran, P. (2017). Evaluation of Recurrent Neural Network and its Variants for Intrusion Detection System (IDS). International Journal of Information System Modeling and Design (IJISMD), 8(3), 43–63.</li><li>Vysakh S Mohan, Vinayakumar R, Soman Kp and Prabaharan Poornachandran. S.P.O.O.F Net: Syntactic Patterns for identification of Ominous Online Factors In Security and Privacy Workshops (SPW), 2018 IEEE [InPress].</li><li>LeCun, Y., Bengio, Y. and Hinton, G., 2015. Deep learning. nature, 521(7553), p.436.</li></ol><p>Please find the below resources</p><ul><li><a href="https://github.com/rahulvigneswaran/Intrusion-Detection-Systems">Github Repository</a></li><li><a href="https://ieeexplore.ieee.org/abstract/document/8494096">Proceedings and Paper</a></li><li>If you have used any of the materials from this article, kindly cite the following papers :</li></ul><ol><li>K. Rahul Vigneswaran, R. Vinayakumar, K. Soman and P. Poornachandran, “Evaluating Shallow and Deep Neural Networks for Network Intrusion Detection Systems in Cyber Security,” 2018 9th International Conference on Computing, Communication and Networking Technologies (ICCCNT), Bangalore, 2018, pp. 1–6.</li><li>Rahul-Vigneswaran, K., Poornachandran, P., &amp; Soman, K.P. (2019). A Compendium on Network and Host based Intrusion Detection Systems. CoRR, abs/1904.03491.</li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f3497c1da7f6" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>