RU2679227C1 - Firewall operating method - Google Patents

Firewall operating method Download PDF

Info

Publication number
RU2679227C1
RU2679227C1 RU2018112218A RU2018112218A RU2679227C1 RU 2679227 C1 RU2679227 C1 RU 2679227C1 RU 2018112218 A RU2018112218 A RU 2018112218A RU 2018112218 A RU2018112218 A RU 2018112218A RU 2679227 C1 RU2679227 C1 RU 2679227C1
Authority
RU
Russia
Prior art keywords
network
network connection
packet
network packet
application
Prior art date
Application number
RU2018112218A
Other languages
Russian (ru)
Inventor
Алексей Юрьевич Оладько
Original Assignee
Открытое Акционерное Общество "Информационные Технологии И Коммуникационные Системы"
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Открытое Акционерное Общество "Информационные Технологии И Коммуникационные Системы" filed Critical Открытое Акционерное Общество "Информационные Технологии И Коммуникационные Системы"
Priority to RU2018112218A priority Critical patent/RU2679227C1/en
Application granted granted Critical
Publication of RU2679227C1 publication Critical patent/RU2679227C1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/66Arrangements for connecting between networks having differing types of switching systems, e.g. gateways

Abstract

FIELD: computer equipment.SUBSTANCE: method comprises stages, at which: from the sender with the address S1 for the recipient with the address R1 receiving the network packet P1; using the network connections table processing module searching for the network connection descriptor, to which the network packet P1 belongs, based on the sender S1 address, the recipient R1 address, the encapsulated transport layer protocol number, information about the transport layer protocol; if the network connection descriptor is not found, then creating the network connection descriptor, and storing in the network connection table using the network connection table processing module; analyzing the network packet in the network packet classification module; in the network connection descriptor storing the information obtained from the network packet from the network packet classification module analyzing; performing the network packet filtering.EFFECT: technical result consists in increase in the network in the protected segment security.1 cl

Description

Область техники, к которой относится изобретениеFIELD OF THE INVENTION

Предполагаемое изобретение относится к области защиты сетей передачи данных с коммутацией пакетов и может быть использовано для повышения защищенности сетей.The alleged invention relates to the field of protection of packet-switched data networks and can be used to increase network security.

Уровень техникиState of the art

Защита современных цифровых сетей передачи данных, имеющих выход в сеть Интернет, обеспечивается различными методами, в том числе с использованием шлюзов-компьютеров с межсетевыми экранами (МЭ), которые обеспечивает защиту сети (подсети) путем фильтрации по определенным правилам входящего и исходящего потока данных (трафика). Для обеспечения эффективной защиты важен выбор правил и условий их применения.The protection of modern digital data networks with access to the Internet is provided by various methods, including using gateway computers with firewalls (MEs), which protect the network (subnet) by filtering according to certain rules for incoming and outgoing data flow ( traffic). To ensure effective protection, the choice of rules and the conditions for their application are important.

Так, известен способ управления соединениями в межсетевом экране (патент РФ №2517411, приоритет от 24.10.2012 г.), который включает следующие действия:So, there is a known method for managing connections in the firewall (RF patent No. 2517411, priority dated 10.24.2012), which includes the following actions:

• получают пакеты из внешней сети;• receive packets from an external network;

• формируют таблицу соединений, содержащую следующие сведения:• form a connection table containing the following information:

Figure 00000001
информацию о пакетах, входящих в соединение (исходный пакет, ответный пакет, ошибки ICMP);
Figure 00000001
information about the packets that make up the connection (source packet, response packet, ICMP errors);

Figure 00000001
информацию о преобразованиях пакета в случае трансляции адресов;
Figure 00000001
information about package conversions in case of address translation;

Figure 00000001
о типе сетевого протокола;
Figure 00000001
about the type of network protocol;

Figure 00000001
состояние соединения (новое, установленное, закрытое);
Figure 00000001
connection status (new, established, closed);

Figure 00000001
отметка о времени обработки последнего пакета;
Figure 00000001
time stamp for processing the last packet;

Figure 00000001
информацию о группах соединений в случае прикладных протоколов (FTP, SIP);
Figure 00000001
information about connection groups in case of application protocols (FTP, SIP);

• определяют общее количество установленных соединений на данный момент времени;• determine the total number of established connections at a given time;

• определяют уровень загрузки межсетевого экрана путем сравнения количества установленных соединений с определенной пороговой величиной;• determine the load level of the firewall by comparing the number of established connections with a certain threshold value;

• определяют новые и установленные соединения на основе двустороннего обмена пакетами между клиентом и сервером;• define new and established connections based on two-way packet exchange between the client and server;

• определяют закрытые соединения на основе обработки ICMP-сообщений об ошибках или флагов в TCP-заголовке (только для протокола TCP);• define closed connections based on the processing of ICMP error messages or flags in the TCP header (only for the TCP protocol);

• динамически определяют текущие значения таймаутов для соединений на основании следующих параметров:

Figure 00000002
тип сетевого протокола;• dynamically determine the current timeout values for connections based on the following parameters:
Figure 00000002
type of network protocol;

Figure 00000001
состояние соединения;
Figure 00000001
connection status;

Figure 00000001
уровень загрузки межсетевого экрана;
Figure 00000001
firewall load level;

• изменяют отметку времени обработки последнего пакета в случае прохождения любого пакета в рамках данного соединения или в рамках группы соединений;• change the time stamp of the processing of the last packet in the case of passing any packet within a given connection or within a group of connections;

• удаляют соединение, если отметка времени обработки последнего пакета отличается от текущего времени больше, чем таймаут данного соединения.• delete the connection if the processing time stamp of the last packet differs from the current time more than the timeout of this connection.

Недостатками известного способа является невозможность проводить классификацию протокола прикладного уровня, используемого в сетевом соединении, и далее фильтрацию по данному протоколу прикладного уровня.The disadvantages of this method is the inability to classify the application layer protocol used in the network connection, and then filtering by this application layer protocol.

Также известен способ защиты вычислительной сети путем применения механизма классификации пакетов в сетевом устройстве безопасности (патент США №8009566, приоритет от 26.06.2006 г.), в котором для защиты вычислительных сетей используют шлюз-компьютер с МЭ, устанавливаемый на каналах связи защищаемой сети с другими сетями, и который содержит модуль классификации пакетов.Also known is a method of protecting a computer network by applying the packet classification mechanism to a network security device (US Pat. No. 8009566, priority dated June 26, 2006), in which a computer-gateway with ME installed on communication channels of the protected network with other networks, and which contains a packet classification module.

Способ содержит следующие этапы:The method comprises the following steps:

• получают сетевой пакет;• receive a network packet;

• производят поиск записи в таблице соединений на основе информации из сетевого и транспортного заголовков сетевого пакета;• search for entries in the connection table based on information from the network and transport headers of the network packet;

• если запись в таблице соединений не найдена, то• if an entry in the connection table is not found, then

Figure 00000001
сетевой пакет ассоциируется с новой сессией, которой присваивается уникальный идентификатор;
Figure 00000001
a network packet is associated with a new session that is assigned a unique identifier;

Figure 00000001
производят пакетную фильтрацию, например, на основе данных из заголовков сетевого и транспортного уровня;
Figure 00000001
perform packet filtering, for example, based on data from the headers of the network and transport layer;

Figure 00000001
создают новую запись в таблице соединений, если пакет разрешен фильтрами МЭ;
Figure 00000001
create a new entry in the connection table if the packet is allowed by ME filters;

Figure 00000001
передают пакет в модуль классификации пакетов;
Figure 00000001
transmitting the packet to the packet classification module;

Figure 00000001
выполняют фильтрацию сетевого потока на основе результатов классификации, если пакет и соответствующий сетевой поток были классифицированы;
Figure 00000001
filtering the network stream based on the classification results if the packet and the corresponding network stream have been classified;

Figure 00000001
сохраняют копию сетевого пакета, если он не был классифицирован;
Figure 00000001
save a copy of the network packet if it has not been classified;

Figure 00000001
передают сетевой пакет;
Figure 00000001
transmit a network packet;

• если запись в таблице соединений найдена и соединение было классифицировано в модуле классификации пакетов, то• if an entry in the connection table is found and the connection was classified in the packet classification module, then

Figure 00000003
выполняют фильтрацию сетевого потока на основе результатов классификации;
Figure 00000003
filtering the network stream based on the classification results;

Figure 00000001
передают сетевой пакет;
Figure 00000001
transmit a network packet;

• если запись в таблице соединений найдена и соединение не было классифицировано в модуле классификации пакетов, то• if an entry in the connection table is found and the connection was not classified in the packet classification module, then

Figure 00000001
передают пакет в модуль классификации пакетов;
Figure 00000001
transmitting the packet to the packet classification module;

Figure 00000001
выполняют фильтрацию сетевого потока на основе результатов классификации, если пакет и соответствующий сетевой поток были классифицированы;
Figure 00000001
filtering the network stream based on the classification results if the packet and the corresponding network stream have been classified;

Figure 00000001
сохраняют копию сетевого пакета, если он не был классифицирован;
Figure 00000004
передают сетевой пакет.
Figure 00000001
save a copy of the network packet if it has not been classified;
Figure 00000004
transmit the network packet.

Известный способ может обеспечить фильтрацию потока данных по протоколу прикладного уровня, который был определен модулем классификации пакетов.The known method can provide filtering of the data stream according to the application layer protocol, which was determined by the packet classification module.

Однако, при использовании известного способа первоначальное решение о разрешении или блокировании сетевого потока должно быть принято на основе правил пакетного фильтра, а правила фильтрации потока данных по протоколу прикладного уровня применяются только после получения окончательной классификации модулем классификации сетевых пакетов.However, when using the known method, the initial decision on allowing or blocking the network stream should be made based on the packet filter rules, and the rules for filtering the data stream according to the application layer protocol are applied only after the final classification is received by the network packet classification module.

Такая схема действия является недостатком известного способа, так как для окончательной классификации модулем классификации сетевых пакетов может потребоваться более одного сетевого пакета, которые будут пропущены согласно разрешающему правилу пакетного фильтра.Such an action scheme is a disadvantage of the known method, since for the final classification by the classification module of the network packets, more than one network packet may be required, which will be skipped according to the resolving rule of the packet filter.

Раскрытие изобретенияDisclosure of invention

Техническим результатом являетсяThe technical result is

1) повышение защищенности сети в защищаемом сегменте,1) increasing network security in the protected segment,

2) возможность использования правил фильтрации по результату анализа модулем классификации сетевых пакетов совместно с правилами фильтрации пакетного фильтра.2) the ability to use filtering rules based on the analysis of the network packet classification module together with packet filtering rules.

Заявленный результат достигается за счет применения способа работы межсетевого экрана, причем на входе защищаемой вычислительной сети установлен шлюз-компьютер с межсетевым экраном, в котором определено множество А разрешенных для использования протоколов прикладного уровня и множество В запрещенных для использования протоколов прикладного уровня, при этом межсетевой экран выполнен с возможностью проводить пакетную фильтрацию и содержитThe claimed result is achieved through the application of the method of operation of the firewall, and a gateway computer with a firewall is installed at the input of the protected computer network, in which a set A are allowed for use of application-level protocols and a set of B are prohibited for use of application-level protocols, while the firewall configured to perform packet filtering and contains

• модуль обработки таблицы сетевых соединений, причем элементом таблицы служит дескриптор сетевого соединения, который содержит, по меньшей мере, следующую информацию:• a processing module for the network connection table, and the network connection descriptor, which contains at least the following information, is an element of the table:

Figure 00000001
сетевой адрес источника и назначения;
Figure 00000001
network address of the source and destination;

Figure 00000001
статус сетевого соединения, который может принимать следующие значения: "Новый", "Установлено", "Заблокировано";
Figure 00000001
network connection status, which can take the following values: "New", "Installed", "Blocked";

Figure 00000001
номер инкапсулированного протокола транспортного уровня;
Figure 00000001
Encapsulated transport layer protocol number

Figure 00000001
информацию о протоколе транспортного уровня;
Figure 00000001
transport layer protocol information;

Figure 00000001
информацию из модуля классификации сетевых пакетов;
Figure 00000001
information from the network packet classification module;

• модуль классификации сетевых пакетов, выполненный с возможностью проводить определение используемого в сетевом соединении протокола прикладного уровня;• a network packet classification module, configured to determine the application layer protocol used in the network connection;

способ заключается в том, чтоthe way is that

• принимают от отправителя с адресом S1 для получателя с адресом R1 сетевой пакет Р1;• receive from the sender with address S1 for the recipient with address R1 a network packet P1;

• осуществляют поиск с помощью модуля обработки таблицы сетевых соединений дескриптора сетевого соединения, к которому относится сетевой пакет Р1, на основе адреса отправителя S1, адреса получателя R1, номера инкапсулированного протокола транспортного уровня, информации о протоколе транспортного уровня;• search using the network connection table processing module for the network connection descriptor to which the network packet P1 belongs, based on the source address of S1, destination address of R1, number of the encapsulated protocol of the transport layer, information about the protocol of the transport layer;

• если дескриптор сетевого соединения не найден, то создают и сохраняют в таблице сетевых соединений дескриптор сетевого соединения с помощью модуля обработки таблицы сетевых соединений, причем статус сетевого соединения принимает значение "Новый";• if the network connection descriptor is not found, then the network connection descriptor is created and saved in the network connection table using the network connection table processing module, and the network connection status is set to "New";

• производят анализ сетевого пакета в модуле классификации сетевых пакетов, получая, по крайней мере, следующую информацию:• analyze the network packet in the network packet classification module, receiving at least the following information:

Figure 00000001
протокол прикладного уровня Ра, если он был установлен;
Figure 00000001
the application layer protocol Ra, if one has been installed;

Figure 00000001
флаг окончательной классификации F, который показывает, что результат классификации сетевого соединения далее не будет изменен;
Figure 00000001
the final classification flag F, which indicates that the result of the classification of the network connection will not be further changed;

Figure 00000001
множество прикладных протоколов Re, которое содержит список прикладных протоколов, для которых модулем классификации сетевых пакетов определено, что в сетевом соединении не используются протоколы прикладного уровня из множества Re;
Figure 00000001
a plurality of application protocols Re, which contains a list of application protocols for which the network packet classification module determines that the application layer protocols from the set Re are not used in the network connection;

• если статус сетевого соединения в дескрипторе сетевого соединения содержит значение "Заблокировано", то блокируют сетевой пакет;• if the network connection status in the network connection descriptor contains the value "Blocked", then the network packet is blocked;

• иначе если информация о пакете из модуля классификации сетевых пакетов совпадает с информацией, сохраненной в дескрипторе сетевого соединения, и статус сетевого соединения содержит значение "Установлено", то пропускают пакет;• otherwise, if the packet information from the network packet classification module matches the information stored in the network connection descriptor and the network connection status contains the value “Established”, then the packet is skipped;

• иначе• otherwise

Figure 00000001
сохраняют в дескрипторе сетевого соединения информацию, полученную в результате анализа сетевого пакета из модуля классификации сетевых пакетов;
Figure 00000001
save in the network connection descriptor information obtained as a result of the analysis of the network packet from the network packet classification module;

Figure 00000001
выполняют фильтрацию сетевого пакета, причем правила фильтрации по разрешенным или запрещенным протоколам прикладного уровня работают следующим образом:
Figure 00000001
filtering the network packet, and the filtering rules for allowed or denied application level protocols work as follows:

Figure 00000005
если установленный в результате работы модуля классификации сетевых пакетов прикладной протокол Ра является элементом множества В, то блокируют сетевой пакет и устанавливают для статуса сетевого соединения значение "Заблокировано";
Figure 00000005
if the application protocol Ra, established as a result of the operation of the network packet classification module, is an element of the set B, then the network packet is blocked and the network connection status is set to "Blocked";

Figure 00000005
если установленный в результате работы модуля классификации сетевых пакетов прикладной протокол Ra является элементом множества А, то пропускают сетевой пакет, и устанавливают для статуса сетевого соединения значение "Установлено";
Figure 00000005
if the application protocol Ra established as a result of the operation of the network packet classification module is an element of the set A, then the network packet is skipped and the network connection status is set to "Established";

Figure 00000005
если не установлен флаг окончательной классификации F и разность множеств А и Re образует непустое множество, то пропускают сетевой пакет и устанавливают для статуса сетевого соединения значение "Установлено".
Figure 00000005
if the final classification flag F is not set and the difference between the sets A and Re forms a nonempty set, then the network packet is skipped and the network connection status is set to "Established".

Для реализации предложенного способа в состав МЭ должны быть включены модуль классификации сетевых пакетов, выполненный с возможностью проводить определение используемого в сетевом соединении протокола прикладного уровня, и модуль обработки таблицы сетевых соединений. В общем случае, перечисленные модули могут быть программно-аппаратными или программными. Для создания указанных модулей должно быть проведено обычное проектирование и изготовлении электронного блока (при выполнении в программно-аппаратном виде) и формирование необходимого программного обеспечения (ПО) с последующим тестированием и установкой в МЭ. Для создания модуля контроля и модуля обработки таблицы сетевых соединений в программном виде создается только прикладное либо системное ПО. Создание данных модулей может осуществить специалист по проектированию и изготовлению электронной техники и/или специалист по программированию (программист) на основе знания о выполняемых данными модулями функциях.To implement the proposed method, the network packet classification module, configured to determine the application layer protocol used in the network connection, and the network connection table processing module should be included in the ME. In general, the listed modules can be hardware-software or software. To create these modules, the usual design and manufacture of the electronic unit (when executed in software and hardware) and the formation of the necessary software (software) with subsequent testing and installation in the ME should be carried out. To create a control module and a processing module for a table of network connections in a program form, only application or system software is created. The creation of these modules can be carried out by a specialist in the design and manufacture of electronic equipment and / or a programming specialist (programmer) based on knowledge of the functions performed by these modules.

После создания и отладки модуля классификации сетевых пакетов и модуля обработки таблицы сетевых соединений можно приступать непосредственно к реализации предложенного способа.After creating and debugging the network packet classification module and the network connection table processing module, you can proceed directly to the implementation of the proposed method.

Для осуществления способа МЭ получает сетевые пакеты, принятые на сетевом интерфейсе. Сначала сетевые пакеты проверяются на принадлежность к уже созданным сетевым соединениям. Для этого осуществляется поиск в таблице сетевых соединений. Если подходящего соединения не найдено, то в модуле обработки таблицы сетевых соединений создается запись о новом соединении в виде дескриптора. При создании данного дескриптора, в него заносится информация из заголовка протокола сетевого уровня, включая сетевые адреса источника и назначения, и, при необходимости, информация об используемом протоколе транспортного уровня, включая номера портов источника и назначения. Для созданного дескриптора значение статуса устанавливается как "Новый".To implement the method, the ME receives network packets received on the network interface. First, network packets are checked for belonging to already created network connections. To do this, search the network connection table. If no suitable connection is found, an entry about a new connection in the form of a descriptor is created in the processing module of the network connection table. When creating this descriptor, information from the header of the protocol of the network layer, including network addresses of the source and destination, and, if necessary, information about the used protocol of the transport layer, including the port numbers of the source and destination, is entered into it. For the created descriptor, the status value is set to "New".

Далее сетевые пакеты передаются в модуль классификации сетевых пакетов, выполненный с возможностью проводить определение используемого в сетевом соединении протокола прикладного уровня. Процесс обработки сетевого пакета в данном модуле может включать в себя сохранение локальной копии пакета для последующего анализа, декодирования протокола на основе контента. Информация о текущем результате процесса классификации передается далее в МЭ. Данная информация может включать в себя как установленный протокол прикладного уровня, так и список прикладных протоколов, которые не используются в сетевом соединении, а так же флаг окончательной классификации, показывающий, что результат классификации далее не будет изменен.Next, the network packets are transmitted to the network packet classification module, configured to determine the application layer protocol used in the network connection. The process of processing a network packet in this module may include saving a local copy of the packet for subsequent analysis, decoding the protocol based on the content. Information on the current result of the classification process is transmitted further to the ME. This information may include both the established application layer protocol and the list of application protocols that are not used in the network connection, as well as the final classification flag, indicating that the classification result will not be further changed.

Если значение поля статус в дескрипторе сетевого соединения содержит значение "Заблокировано", то блокируют сетевой пакет. На этом обработка сетевого пакета заканчивается.If the value of the status field in the network connection descriptor contains the value "Blocked", then the network packet is blocked. This completes the processing of the network packet.

Если информация о пакете из модуля классификации сетевых пакетов совпадает с информацией, сохраненной в дескрипторе сетевого соединения, и статус сетевого соединения содержит значение "Установлено", то выполняются все необходимые действия для обработки и дальнейшей передачи сетевого пакета в сеть.If the packet information from the network packet classification module matches the information stored in the network connection descriptor and the network connection status is set to “Established”, then all necessary actions are performed to process and further transmit the network packet to the network.

Если информация о пакете из модуля классификации сетевых пакетов не совпадает с информацией, сохраненной в дескрипторе сетевого соединения, или статус сетевого соединения содержит значение "Новый", то осуществляется фильтрация сетевого пакета на соответствие настроенным фильтрам. При этом информация, полученная в результате анализа сетевого пакета из модуля классификации сетевых пакетов, сохраняется в дескрипторе соединения. Если пакет оказался заблокирован каким-либо из фильтров, то на этом его обработка заканчивается, а в поле статус дескриптора сетевого соединения устанавливается значение "Заблокировано". Если прохождение пакета было разрешено, то поле статус дескриптора сетевого соединения устанавливается значение "Установлено" и выполняются все необходимые действия для обработки и дальнейшей передачи сетевого пакета в сеть.If the packet information from the network packet classification module does not match the information stored in the network connection descriptor, or the network connection status is set to New, then the network packet is filtered according to the configured filters. In this case, the information obtained as a result of the analysis of the network packet from the network packet classification module is stored in the connection descriptor. If the packet turned out to be blocked by any of the filters, then it ends its processing, and the status of the network connection descriptor is set to "Blocked" in the field. If the packet was allowed to pass, then the network connection descriptor status field is set to "Established" and all the necessary steps are taken to process and further transmit the network packet to the network.

В результате, в отличие от известного способа обеспечивается возможность совместного применения правил фильтрации по классифицированному протоколу прикладного уровня и по данным из заголовков сетевого и транспортного уровней.As a result, in contrast to the known method, it is possible to jointly apply filtering rules according to the classified protocol of the application layer and according to the data from the headers of the network and transport layers.

В отличие от известного способа, нет необходимости производить пакетную фильтрацию (например, на основе данных из заголовков сетевого и транспортного уровня) до передачи сетевого пакета на анализ в модуль классификации сетевых пакетов, как и использование фильтрации на основе данных из заголовков сетевого и транспортного уровня. Фильтрация сетевых пакетов может быть осуществлена только по разрешенным или запрещенным протоколам прикладного уровня.Unlike the known method, there is no need to perform packet filtering (for example, based on data from the headers of the network and transport layer) before transmitting the network packet for analysis to the network packet classification module, as well as using filtering based on data from the headers of the network and transport layer. Network packet filtering can only be performed using allowed or denied application layer protocols.

Также, в отличие от известного способа, нет необходимости пропускать все сетевые пакеты из сетевого потока до того момента, когда модуль классификации сетевых пакетов определит используемый в сетевом соединении протокол прикладного уровня. Фильтрация по протоколу прикладного уровня может быть выполнена на основании информации о списке прикладных протоколов, которые не используются в сетевом соединении, еще до получения из модуля классификации сетевых пакетов информации об используемом в сетевом соединении протокола прикладного уровня.Also, unlike the known method, it is not necessary to pass all network packets from the network stream until the network packet classification module determines the application layer protocol used in the network connection. Filtering by the application layer protocol can be performed based on the information about the list of application protocols that are not used in the network connection, even before information from the network packet classification module receives information about the application layer protocol used in the network connection.

Таким образом, нет необходимости разрешать прохождение сетевых пакетов, которые требуются модулю классификации сетевых пакетов для определения используемого в сетевом соединении протокола прикладного уровня, если уже стало известно, что в данном сетевом соединении не используется протокол прикладного уровня из списка разрешенных.Thus, there is no need to allow the passage of network packets that are required by the network packet classification module to determine the application layer protocol used in the network connection, if it has already become known that the application layer protocol from the allowed list is not used in this network connection.

В результате обеспечивается повышение защищенности вычислительной сети от несанкционированной передачи информации, так как данный способ позволяет заблокировать сетевое соединение, не дожидаясь установления используемого в сетевом соединении протокола прикладного уровня, и нет необходимости пропускать сетевые пакеты до наступления данного события.The result is increased security of the computer network from unauthorized transmission of information, since this method allows you to block the network connection without waiting for the application layer protocol used in the network connection to be established, and there is no need to skip network packets before this event occurs.

Осуществление изобретенияThe implementation of the invention

Рассмотрим осуществление предложенного способа в сети с коммутацией пакетов. Это может быть, например, корпоративная сеть, имеющая выход в сеть Интернет через один основной МЭ.Consider the implementation of the proposed method in a packet-switched network. This can be, for example, a corporate network that has access to the Internet through one main ME.

В качестве МЭ может быть использован высокопроизводительный программно-аппаратный комплекс (ПАК) типа HW1000 на базе Intel Core 2 Duo, объемом оперативной памяти 2 Гб, объемом жесткого диска 250 Гб, с установленной ОС Linux (ядро 3.10.92) и специализированным ПО (статья и загружаемая документация по адресу:As a ME, a high-performance hardware-software complex (PAC) of the HW1000 type based on Intel Core 2 Duo, 2 GB RAM, 250 GB hard disk, with installed Linux OS (kernel 3.10.92) and specialized software (article and downloadable documentation at:

http://infotecs.ru/downloads/all/vipnet-coordinator-hw-1000.html?arrFilter_93=408821001&set_filter=Y).http://infotecs.ru/downloads/all/vipnet-coordinator-hw-1000.html?arrFilter_93=408821001&set_filter=Y).

Предпочтительным является выполнение модуля классификации сетевых пакетов в программном виде, для чего предварительно создается, тестируется и затем инсталлируется в МЭ прикладное ПО в виде программного модуля, выполняющего функции модуля классификации сетевых пакетов и способного выполнять определение используемого в сетевом соединении протокола прикладного уровня.It is preferable to execute the network packet classification module in software form, for which purpose the application software is pre-created, tested and then installed in the ME as a software module that performs the functions of the network packet classification module and is able to determine the application level protocol used in the network connection.

В качестве модуля классификации сетевых пакетов может быть использовано ПО с возможностью проведения глубокой инспекции пакетов (Deep Packet Inspection). При этом, в результате проведения классификации сетевого пакета должно быть, как минимум, обеспечено получение следующей информации:As a module for classifying network packets, software with the ability to conduct deep packet inspection (Deep Packet Inspection) can be used. Moreover, as a result of the classification of the network packet, at least the following information should be provided:

• протокол прикладного уровня, используемый в сетевом соединении, если он был установлен;• the application layer protocol used in the network connection, if it was installed;

• флаг окончательной классификации, который показывает, что результат классификации сетевого соединения далее не будет изменен;• the final classification flag, which indicates that the result of the classification of the network connection will not be further changed;

• множество прикладных протоколов, которое содержит список прикладных протоколов, для которых модулем классификации сетевых пакетов определено, что в сетевом соединении не используются протоколы прикладного уровня из множества.• a set of application protocols, which contains a list of application protocols for which the network packet classification module determines that the application layer protocols from the set are not used in the network connection.

В МЭ также определяется множество А разрешенных для использования протоколов прикладного уровня и множество В запрещенных для использования протоколов прикладного уровня. Например, во множество А могут входить следующие протоколы прикладного уровня: Adobe Connect, AFP, AVI, DHCP, DHCP v6, Diameter, Direct Connect, DNS, HTTP, IPsec, Kerberos, Microsoft Dynamics NAV, Modbus, MySQL, NetBIOS, OpenFlow, OpenVPN, Opera Mini, Oracle Database, Poison Ivy, POP, PostgreSQL, SAP, Skype, SSH, SSL, Telnet, VPN-X, WAP-WSP, XBOX, XDCC, XDMCP, XMPP. и др.The ME also defines a set A of application-level protocols allowed for use and a set of B prohibited for use of application-level protocols. For example, the following application-level protocols may be included in A: Adobe Connect, AFP, AVI, DHCP, DHCP v6, Diameter, Direct Connect, DNS, HTTP, IPsec, Kerberos, Microsoft Dynamics NAV, Modbus, MySQL, NetBIOS, OpenFlow, OpenVPN , Opera Mini, Oracle Database, Poison Ivy, POP, PostgreSQL, SAP, Skype, SSH, SSL, Telnet, VPN-X, WAP-WSP, XBOX, XDCC, XDMCP, XMPP. and etc.

В качестве модуля обработки таблицы сетевых соединений может быть использован модуль ядра Linux nf_conntrack.ko, входящая в состав подсистемы Netfilter ядра Linux. Дескриптором сетевого соединения в этом случае выступает структура nf_conn, определенная в ядре Linux.As a module for processing the network connection table, the Linux kernel module nf_conntrack.ko, which is part of the Linux kernel Netfilter subsystem, can be used. The network connection handle in this case is the nf_conn structure defined in the Linux kernel.

Анализ сетевых пакетов осуществляется подсистемой Netfilter ядра, которая обеспечивает:Network packet analysis is performed by the Netfilter kernel subsystem, which provides:

• пакетную фильтрацию;• batch filtering;

• анализ информации, содержащейся в структуре nf_conn;• analysis of the information contained in the nf_conn structure;

• передачу сетевых пакетов в средство контроля, выполненное с возможностью проводить определение используемого в сетевом соединении протокола прикладного уровня, и получение результатов анализа через системный интерфейс netfilter_queue ядра Linux.• transferring network packets to a monitoring tool, configured to determine the application level protocol used in the network connection, and obtain analysis results through the Linux kernel kernel netfilter_queue system interface.

Для работы правил фильтрации по разрешенным или запрещенным протоколам прикладного уровня должен быть создан специальный модуль ядра xt_dpi.ko, который регистрируется в подсистеме Netfilter ядра Linux. Модуль xt_dpi.ko осуществляет фильтрацию сетевых пакетов согласно следующей логике:For filtering rules to work according to allowed or forbidden application level protocols, a special kernel module xt_dpi.ko must be created, which is registered in the Linux kernel Netfilter subsystem. The xt_dpi.ko module filters network packets according to the following logic:

• если установленный в результате работы модуля классификации сетевых пакетов прикладной протокол является элементом множества В, то блокируют сетевой пакет и устанавливают для статуса сетевого соединения значение "Заблокировано";• if the application protocol installed as a result of the network packet classification module is an element of the set B, then the network packet is blocked and the network connection status is set to “Blocked”;

• если установленный в результате работы модуля классификации сетевых пакетов прикладной протокол является элементом множества А, то пропускают сетевой пакет, и устанавливают для статуса сетевого соединения значение "Установлено";• if the application protocol established as a result of the operation of the network packet classification module is an element of the set A, then the network packet is skipped and the network connection status is set to "Established";

• если не установлен флаг окончательной классификации и разность множества А и множества прикладных протоколов, которые не используются в сетевом соединении, согласно результату из модуля классификации сетевых пакетов, образует непустое множество, то пропускают сетевой пакет и устанавливают для статуса сетевого соединения значение "Установлено". Список правил фильтрации в межсетевом экране должен строиться следующим образом:• if the final classification flag and the difference between the set A and the set of application protocols that are not used in the network connection are not set, according to the result of the network packet classification module, forms a non-empty set, then the network packet is skipped and the network connection status is set to "Established". The list of filtering rules in the firewall should be constructed as follows:

• первое правило: проверяют значение поля статуса дескриптора сетевого соединения, если значение равно "Заблокировано", то сетевой пакет блокируется, и дальнейшая обработка прекращается;• the first rule: check the value of the status field of the network connection descriptor; if the value is "Blocked", the network packet is blocked and further processing is terminated;

• второе правило: если информация о пакете из модуля классификации сетевых пакетов совпадает с информацией, сохраненной в дескрипторе сетевого соединения, и статус сетевого соединения содержит значение "Установлено", то пропускают пакет;• the second rule: if the packet information from the network packet classification module matches the information stored in the network connection descriptor and the network connection status contains the value “Established”, then the packet is skipped;

• далее следуют правила фильтрации сетевых пакетов, в том числе правила фильтрации по протоколу прикладного уровня.• The rules for filtering network packets, including the rules for filtering by application layer protocol, follow.

Например, первое правило может быть записано следующей командой:For example, the first rule can be written with the following command:

iptables -A FORWARD -m -m conntrack --ctstate DROPPED -j DROPiptables -A FORWARD -m -m conntrack --ctstate DROPPED -j DROP

Второе правило может быть записано следующей командой:The second rule can be written with the following command:

iptables -A FORWARD -m conntrack --ctstate ESTABLISHED -m conntrack --dpiresult NOTCHANGED -j ACCEPTiptables -A FORWARD -m conntrack --ctstate ESTABLISHED -m conntrack --dpiresult NOTCHANGED -j ACCEPT

Пример последующих правил фильтрации сетевых пакетов:An example of the following network packet filtering rules:

iptables -A FORWARD -m dpi --accept-protocol HTTP -j ACCEPTiptables -A FORWARD -m dpi --accept-protocol HTTP -j ACCEPT

iptables -A FORWARD -m dpi --drop-protocol FTP -j DROPiptables -A FORWARD -m dpi --drop-protocol FTP -j DROP

iptables -A FORWARD -j DROPiptables -A FORWARD -j DROP

При получении сетевого пакета, модуль ядра nf_conntrack.ko проверяет сетевой пакет на принадлежность к уже установленным соединениям. С этой целью производится поиск в таблице сетевых соединений. Если подходящего соединения не найдено, то модуль ядра Linux nf_conntrack.ko создает запись о новом соединении в виде дескриптора nf_conn и сохраняет его в таблице сетевых соединений. При создании нового дескриптора сетевого соединения, в поле статус устанавливается значение "Новый".Upon receipt of a network packet, the kernel module nf_conntrack.ko checks the network packet for membership of already established connections. To this end, a search is made in the network connection table. If no suitable connection is found, then the Linux kernel module nf_conntrack.ko creates a new connection record in the form of the nf_conn descriptor and stores it in the network connection table. When creating a new network connection descriptor, the status field is set to New.

Затем в МЭ запускается модуль классификации сетевых соединений, выполненный с возможностью проводить определение используемого в сетевом соединении протокола прикладного уровня. Сетевые пакеты для анализа данная программа получает через системный интерфейс netfilter_queue ядра Linux.Then, the network connection classification module is launched in the ME, which is configured to determine the application layer protocol used in the network connection. This program receives network packets for analysis through the system interface netfilter_queue of the Linux kernel.

Далее в подсистеме Netfilter ядра проводится проверка сетевого пакета на соответствие настроенным фильтрам. При этом проверка на соответствие фильтрам по разрешенным или запрещенным протоколам прикладного уровня выполняется в модуле ядра xt_dpi.ko. Также в подсистеме Netfilter ядра производится сохранение в дескрипторе сетевого соединения информацию, полученную в результате анализа сетевого пакета из модуля классификации сетевых пакетов. Если сетевой пакет оказался заблокирован каким-либо из фильтров, то в поле статус дескриптора сетевого соединения устанавливается значение "Заблокировано". Если подсистема фильтрации разрешила прохождение сетевого пакета для дальнейшей обработки, то в поле статус дескриптора сетевого соединения устанавливается значение "Установлено".Further, in the kernel Netfilter subsystem, the network packet is checked for compliance with the configured filters. In this case, the check for compliance with filters by allowed or prohibited protocols of the application level is performed in the kernel module xt_dpi.ko. Also, in the Netfilter subsystem of the kernel, information obtained as a result of analyzing the network packet from the network packet classification module is stored in the network connection descriptor. If the network packet turned out to be blocked by any of the filters, then the status field of the network connection descriptor is set to "Blocked". If the filtering subsystem allowed the passage of the network packet for further processing, then the status of the network connection descriptor is set to "Installed" in the field.

В результате, пропускаются сетевые пакеты, которые относятся к сетевым соединениям, работающим по одному из протоколов прикладного уровня из множества А; блокируются сетевые пакеты, которые относятся к сетевым соединениям, работающим по одному из протоколов прикладного уровня из множества В.As a result, network packets that are related to network connections operating over one of the application layer protocols from the set A are passed through; network packets are blocked, which relate to network connections operating on one of the application layer protocols from set B.

Claims (23)

Способ работы межсетевого экрана, причем для межсетевого экрана определено множество А разрешенных для использования протоколов прикладного уровня и множество В запрещенных для использования протоколов прикладного уровня, при этом межсетевой экран выполнен с возможностью проводить пакетную фильтрацию и содержитThe method of operation of the firewall, moreover, for the firewall, a plurality A of application-level protocols permitted for use and a set of B prohibited for use of application-level protocols are defined, while the firewall is configured to perform packet filtering and contains модуль обработки таблицы сетевых соединений, причем элементом таблицы служит дескриптор сетевого соединения, который содержит, по меньшей мере, следующую информацию:a network connection table processing module, wherein the network connection descriptor is a table element, which contains at least the following information: сетевой адрес источника и назначения;network address of the source and destination; статус сетевого соединения, который может принимать следующие значения: "Новый", "Установлено", "Заблокировано";network connection status, which can take the following values: "New", "Installed", "Blocked"; номер инкапсулированного протокола транспортного уровня;Encapsulated transport layer protocol number информацию о протоколе транспортного уровня;transport layer protocol information; информацию из модуля классификации сетевых пакетов; information from the network packet classification module; модуль классификации сетевых пакетов, выполненный с возможностью проводить определение используемого в сетевом соединении протокола прикладного уровня;a network packet classification module configured to determine an application layer protocol used in a network connection; способ заключается в том, чтоthe way is that принимают от отправителя с адресом S1 для получателя с адресом R1 сетевой пакет Р1;receive from the sender with address S1 for the recipient with address R1 a network packet P1; осуществляют поиск с помощью модуля обработки таблицы сетевых соединений дескриптора сетевого соединения, к которому относится сетевой пакет Р1, на основе адреса отправителя S1, адреса получателя R1, номера инкапсулированного протокола транспортного уровня, информации о протоколе транспортного уровня;search using the network connection table processing module for the network connection descriptor to which the network packet P1 belongs, based on the sender address S1, recipient address R1, encapsulated transport layer protocol number, transport layer protocol information; если дескриптор сетевого соединения не найден, то создают и сохраняют в таблице сетевых соединений дескриптор сетевого соединения с помощью модуля обработки таблицы сетевых соединений, причем статус сетевого соединения принимает значение "Новый";if the network connection descriptor is not found, then the network connection descriptor is created and saved in the network connection table using the network connection table processing module, and the network connection status is set to "New"; производят анализ сетевого пакета в модуле классификации сетевых пакетов, получая, по крайней мере, следующую информацию:they analyze the network packet in the network packet classification module, receiving at least the following information: протокол прикладного уровня Ра, если он был установлен;the application layer protocol Ra, if one has been installed; флаг окончательной классификации F, который показывает, что результат классификации сетевого соединения далее не будет изменен;the final classification flag F, which indicates that the result of the classification of the network connection will not be further changed; множество прикладных протоколов Re, которое содержит список прикладных протоколов, для которых модулем классификации сетевых пакетов определено, что в сетевом соединении не используются протоколы прикладного уровня из множества Re;a plurality of application protocols Re, which contains a list of application protocols for which the network packet classification module determines that the application layer protocols from the set Re are not used in the network connection; если статус сетевого соединения в дескрипторе сетевого соединения содержит значение "Заблокировано", то блокируют сетевой пакет; иначе если информация о пакете из модуля классификации сетевых пакетов совпадает с информацией, сохраненной в дескрипторе сетевого соединения, и статус сетевого соединения содержит значение "Установлено", то пропускают пакет;if the network connection status in the network connection descriptor contains the value "Blocked", then the network packet is blocked; otherwise, if the packet information from the network packet classification module matches the information stored in the network connection descriptor and the network connection status contains the value “Established”, then the packet is skipped; иначеotherwise сохраняют в дескрипторе сетевого соединения информацию, полученную в результате анализа сетевого пакета из модуля классификации сетевых пакетов;save in the network connection descriptor information obtained as a result of the analysis of the network packet from the network packet classification module; выполняют фильтрацию сетевого пакета, причем правила фильтрации по разрешенным или запрещенным протоколам прикладного уровня работают следующим образом:filtering the network packet, and the filtering rules for allowed or denied application level protocols work as follows: если установленный в результате работы модуля классификации сетевых пакетов прикладной протокол Ра является элементом множества В, то блокируют сетевой пакет и устанавливают для статуса сетевого соединения значение "Заблокировано";if the application protocol Ra, established as a result of the operation of the network packet classification module, is an element of the set B, then the network packet is blocked and the network connection status is set to "Blocked"; если установленный в результате работы модуля классификации сетевых пакетов прикладной протокол Ra является элементом множества А, то пропускают сетевой пакет, и устанавливают для статуса сетевого соединения значение "Установлено";if the application protocol Ra established as a result of the operation of the network packet classification module is an element of the set A, then the network packet is skipped and the network connection status is set to "Established"; если не установлен флаг окончательной классификации F и разность множеств А и Re образует непустое множество, то пропускают сетевой пакет и устанавливают для статуса сетевого соединения значение "Установлено".if the final classification flag F is not set and the difference between the sets A and Re forms a nonempty set, then the network packet is skipped and the network connection status is set to "Established".
RU2018112218A 2018-04-05 2018-04-05 Firewall operating method RU2679227C1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
RU2018112218A RU2679227C1 (en) 2018-04-05 2018-04-05 Firewall operating method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
RU2018112218A RU2679227C1 (en) 2018-04-05 2018-04-05 Firewall operating method

Publications (1)

Publication Number Publication Date
RU2679227C1 true RU2679227C1 (en) 2019-02-06

Family

ID=65273437

Family Applications (1)

Application Number Title Priority Date Filing Date
RU2018112218A RU2679227C1 (en) 2018-04-05 2018-04-05 Firewall operating method

Country Status (1)

Country Link
RU (1) RU2679227C1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2790635C1 (en) * 2022-06-21 2023-02-28 Акционерное общество "Научно-производственное предприятие " Цифровые решения" Method for filtering a part of packets in a network session

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040153858A1 (en) * 2002-12-23 2004-08-05 Hwang Shaw Hwa Direct peer-to-peer transmission protocol between two virtual networks
US20070297333A1 (en) * 2006-06-26 2007-12-27 Nir Zuk Packet classification in a network security device
US20100208611A1 (en) * 2007-05-31 2010-08-19 Embarq Holdings Company, Llc System and method for modifying network traffic
RU2012145170A (en) * 2012-10-24 2014-04-27 Открытое Акционерное Общество "Информационные Технологии И Коммуникационные Системы" METHOD FOR CONTROL CONNECTIONS IN THE INTERNET NETWORK SCREEN
US20150281125A1 (en) * 2014-03-31 2015-10-01 Nicira, Inc. Caching of service decisions

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040153858A1 (en) * 2002-12-23 2004-08-05 Hwang Shaw Hwa Direct peer-to-peer transmission protocol between two virtual networks
US20070297333A1 (en) * 2006-06-26 2007-12-27 Nir Zuk Packet classification in a network security device
US20100208611A1 (en) * 2007-05-31 2010-08-19 Embarq Holdings Company, Llc System and method for modifying network traffic
RU2012145170A (en) * 2012-10-24 2014-04-27 Открытое Акционерное Общество "Информационные Технологии И Коммуникационные Системы" METHOD FOR CONTROL CONNECTIONS IN THE INTERNET NETWORK SCREEN
US20150281125A1 (en) * 2014-03-31 2015-10-01 Nicira, Inc. Caching of service decisions

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2790635C1 (en) * 2022-06-21 2023-02-28 Акционерное общество "Научно-производственное предприятие " Цифровые решения" Method for filtering a part of packets in a network session
RU2807656C1 (en) * 2023-08-31 2023-11-21 Акционерное общество "Научно-производственное предприятие "Цифровые решения" Balancing method while maintaining integrity of data flows

Similar Documents

Publication Publication Date Title
US11032190B2 (en) Methods and systems for network security universal control point
US9787700B1 (en) System and method for offloading packet processing and static analysis operations
US9954873B2 (en) Mobile device-based intrusion prevention system
US10270810B2 (en) Data socket descriptor based policies for application and data behavior and security
US20170302689A1 (en) Network Security Protection Method and Apparatus
US11968178B2 (en) Reduction and acceleration of a deterministic finite automaton
EP2213045B1 (en) Security state aware firewall
US9356844B2 (en) Efficient application recognition in network traffic
CN109845223B (en) Enforcing network security policies using pre-classification
WO2020086714A1 (en) Network security system with enhanced traffic analysis based on feedback loop
CN108881328B (en) Data packet filtering method and device, gateway equipment and storage medium
US11949654B2 (en) Distributed offload leveraging different offload devices
US11201855B1 (en) Distributed firewall that learns from traffic patterns to prevent attacks
US20120047572A1 (en) Decapsulation of data packet tunnels to process encapsulated ipv4 or ipv6 packets
US20230412591A1 (en) Traffic processing method and protection system
US9172629B1 (en) Classifying packets
RU2679227C1 (en) Firewall operating method
EP4199427A1 (en) Ai-supported network telemetry using data processing unit
US11265372B2 (en) Identification of a protocol of a data stream
US11671437B2 (en) Network traffic analysis
RU2667805C1 (en) Method of operating a firewall
RU2697698C2 (en) Method of processing network traffic using firewall method
EP4080822A1 (en) Methods and systems for efficient threat context-aware packet filtering for network protection
US20210359997A1 (en) Automatic tcam profiles
RU181257U1 (en) Data Clustering Firewall