LEXICAL CONVOLUTION IN ANALYZING THE SIMILARITY OF PROGRAM TEXTS - Pavlov , V. G. (Systems and Technologies, 2023)
The article is devoted to solving the problem of copyright protection on texts of computer programs. Although at the legislative level, the source and object codes of computer programs are recognized as subject to protection and to copyright, the practical implementation of this is not perfect. The reason is that, historically, the problem of protecting authorship of literary texts arose first, and then this approach spread to the texts of computer programs. In this case, program codes are considered only as a kind of literary texts, therefore, for the analysis of their similarity, the same techniques are proposed that apply to literary texts. They do not take into account the peculiarities of the texts of computer programs, especially the grammatical rules for constructing program codes. Unlike the grammar of literary texts, the syntax of programming languages is built on stricter rules, which have a formalized form and are described using metalanguages. Therefore, any operator or instruction has in its composition the constant expressions, which, when compiling a computer program, are considered as standard tokens of a particular programming language. Their names and locations cannot be arbitrary, and therefore they define, as it were, the lexical skeleton of the program. But when creating program code, its author has the opportunity to freely use proper names for certain components of a computer program – variable names, labels, developed functions, etc. These names refer to user tokens and are not considered as permanent command components when compiled. They can be easily exchanged in the source code without any change in the sequence of standard tokens. Such “cloning” of program code by dishonest users often remains invisible, because software tools for finding the similarity of texts give a significantly underestimated result, since they do not distinguish between standard and user tokens in the texts being compared. The same wrong approach to the texts of computer programs can also provide an overestimation when compared due to the same disadvantages. This is proved by the examples given in the article. The article proposes an approach in which standard tokens are separated from user tokens in the texts of computer programs, As a result, the latter have much less influence on the result of checking the similarity of texts. This transformation, which is called lexical convolution, is demonstrated on the instance of the basic constructions of the C programming language and a fragment of the software code. At the same time, it is possible to expand on the other program languages.