Method and system for verifying authenticity of offline course information in insurance industry
Through the verification of check-in and return distance and picture Exif information, the reliability problem of offline course information verification in the insurance industry has been solved, and the efficiency and accuracy of course information have been improved.
Patent Information
- Application Number
- CN202411332486.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-24
- Publication Date
- 2025-01-07
AI Technical Summary
The reliability of offline course information verification in the insurance industry is not high, and it is difficult for existing technology to effectively verify the course participation and the authenticity of photos.
By obtaining the check-in and refund position information of the instructor and students, calculating the check-in and refund distance, and verifying the similarity and integrity of the teaching time and the Exif information of the picture, ensuring the authenticity of the course information.
It improves the reliability of offline course information verification, prevents the forgery and reuse of photos, and ensures that the superior management agency can effectively review the authenticity of the course.
Smart Images

Figure CN119273505A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of information verification, and in particular to a method and system for verifying the authenticity of offline course information in the insurance industry. Background Art
[0002] The training courses involved in the insurance industry are usually aimed at improving employees' professional knowledge, sales skills, customer service capabilities and compliance awareness to adapt to the ever-changing market and regulatory environment. In order to enhance the training or teaching of grassroots units such as workplaces and teams, the superior management agency often requires the upload of training records through the system, which generally include course information, trainee information and course site photos.
[0003] However, in daily work, there are often some training records that are easy to forge in order to prove participation in completing training tasks. The authenticity of course information can be easily forged or reused by only using the attendance and check-out records of trainees and uploading on-site photos. It is easy to forge photos or reuse old photos, and it is impossible to effectively verify the actual participants and participation. This also brings great difficulties to the superior management agency's review of the authenticity of the course.
[0004] In response to this problem, the present invention provides a method and system for verifying the authenticity of offline course information in the insurance industry to solve the above problem. Summary of the invention
[0005] In order to solve the problems existing in the prior art, the present invention innovatively proposes a method and system for verifying the authenticity of offline course information in the insurance industry, which effectively solves the problem of low reliability of authenticity verification of offline course information in the insurance industry caused by the prior art, and effectively improves the reliability of authenticity verification of offline course information in the insurance industry.
[0006] A first aspect of the present invention provides a method for verifying the authenticity of offline course information in the insurance industry, comprising:
[0007] Obtain the start information of offline courses in the insurance industry, generate dynamic QR codes for lecturers and students to sign in respectively, calculate the sign-in distance between students and lecturers based on the current device location information of the lecturer and the student, and perform sign-in verification before the class based on the sign-in distance between students and lecturers;
[0008] Obtain the teaching time information, randomly push confirmation messages to some students who have signed in during the teaching period, and verify the teaching process based on the randomly pushed confirmation messages;
[0009] Obtain the end-of-course information of offline courses in the insurance industry, generate dynamic QR codes for lecturers and students to sign out respectively, calculate the sign-out distance between the student and lecturer based on the current device location information of the lecturer and the student, and perform sign-out verification after the course based on the sign-out distance between the student and lecturer;
[0010] Get the on-site pictures of the insurance industry's offline courses and their Exif information, and perform picture similarity and integrity verification based on the on-site pictures and their Exif information; if the pre-class sign-in verification, teaching process verification, post-class sign-out verification, picture similarity and integrity verification are all passed, then the authenticity verification of the insurance industry's offline course information passes, otherwise the authenticity verification of the insurance industry's offline course information fails.
[0011] Optionally, the calculating the check-in distance between the student and the lecturer according to the current device location information of the lecturer and the current device location information of the student, and performing the check-in verification before the class based on the check-in distance between the student and the lecturer specifically includes:
[0012] According to the longitude and latitude coordinates in the current device location information of the lecturer and the longitude and latitude coordinates in the current device location information of the student, the Ellipsoid.Sphere model is used to calculate the check-in distance between the student and the lecturer.
[0013] Determine whether the check-in distance between all students and the instructor is less than the preset distance threshold. If the check-in distance between a student and the instructor is not less than the preset distance threshold, the pre-class check-in verification fails. Otherwise, the pre-class check-in verification passes.
[0014] Optionally, the calculating the sign-out distance between the student and the lecturer according to the current device location information of the lecturer when signing out and the current device location information of the student when signing out, and performing the sign-out verification after the class based on the sign-out distance between the student and the lecturer specifically includes:
[0015] According to the latitude and longitude coordinates in the current device location information of the lecturer when signing out and the latitude and longitude coordinates in the current device location information of the student when signing out, the Ellipsoid.Sphere model is used to calculate the sign-out distance between the student and the lecturer, the distance between the lecturer when signing out and when signing in, and the distance between the student when signing in and signing out;
[0016] Determine whether the sign-out distance between all students and lecturers, the distance between the lecturer's sign-out and sign-in, and the distance between the students' sign-in and sign-out are all less than the preset distance threshold; if there is a student and lecturer whose sign-out distance is not less than the preset distance threshold, or any of the distance between the lecturer's sign-out and sign-in, the distance between the student's sign-in and sign-out, and the distance between the student and lecturer's sign-out is not less than the preset distance threshold, then the pre-class sign-out verification fails; otherwise, the pre-class sign-in verification passes.
[0017] Optionally, the image similarity and integrity verification based on the teaching scene image and the Exif information of the teaching scene image specifically includes:
[0018] Based on the hash value of the on-site teaching pictures and the hash value of the pictures to be compared in the historical picture library, the picture similarity verification is performed;
[0019] Image integrity verification is performed based on the image's Exif information.
[0020] Furthermore, the image similarity verification based on the hash value of the teaching site image and the hash value of the image to be compared in the historical image library specifically includes:
[0021] Get the paths of the teaching scene picture and the picture to be compared respectively, convert the paths of the teaching scene picture and the picture to be compared into files respectively, and convert the teaching scene picture and the picture to be compared into BufferedImage type based on the converted files;
[0022] Scale the lecture scene pictures and the pictures to be compared to the set size;
[0023] Convert the zoomed lecture scene pictures and the pictures to be compared into grayscale images;
[0024] Convert the teaching scene pictures converted into grayscale images and the pictures to be compared into byte arrays, and perform binarization processing on the converted byte arrays;
[0025] The byte array corresponding to the teaching scene picture after binarization is used as the hash array hash1 of the teaching scene picture, and the byte array corresponding to the picture to be compared after binarization is used as the hash array hash2 of the picture to be compared. The ratio of the array elements of the hash array hash1 of the teaching scene picture and the hash array hash2 of the picture to be compared to the total array elements of the hash array hash1 of the teaching scene picture or the hash array hash2 of the picture to be compared is calculated. If the array elements of the hash array hash1 of the teaching scene picture and the hash array hash2 of the picture to be compared are the same, the ratio of the array elements of the hash array hash1 of the teaching scene picture and the hash array hash2 of the picture to be compared is used as the similarity between the teaching scene picture and the picture to be compared; if the similarity exceeds the preset similarity threshold, the similarity verification of the teaching scene pictures fails, otherwise, the similarity verification of the teaching scene pictures succeeds.
[0026] Optionally, the Exif information includes shooting coordinates, shooting time, mobile phone manufacturer, and mobile phone model.
[0027] Furthermore, the image integrity verification based on the Exif information of the image specifically includes:
[0028] Determine whether the Exif information of the lecture scene picture to be verified is missing or empty. If it is missing or empty, the picture integrity verification fails. If it is not missing or empty, the picture integrity verification passes.
[0029] Optionally, it also includes:
[0030] Based on the Exif information of the image, the rationality of the image is verified.
[0031] Furthermore, the image rationality verification based on the Exif information of the image specifically includes:
[0032] Determine whether the photo of the class scene is taken between the sign-in start time and the sign-out start time. If the photo of the class scene is not taken between the sign-in start time and the sign-out start time, the photo of the class scene is not taken between classes, and the photo rationality verification fails;
[0033] Determine whether the distances between the position corresponding to the shooting coordinates of the teaching site picture and the check-in positions of all students or lecturers, and the check-out positions of all students or lecturers are less than the preset distance threshold. If the number of times the distances between the position corresponding to the shooting coordinates of the teaching site picture and the check-in positions of all students or lecturers, and the check-out positions of all students or lecturers are greater than the preset distance threshold exceeds the preset number threshold, then the teaching site picture is not taken between classes, and the picture rationality verification fails.
[0034] A second aspect of the present invention provides a system for verifying the authenticity of offline course information in the insurance industry, comprising:
[0035] The sign-in verification module obtains the start information of offline courses in the insurance industry, generates dynamic QR codes for lecturers and course students to sign in respectively, calculates the sign-in distance between the student and the lecturer based on the current device location information of the lecturer and the student, and performs sign-in verification before the class based on the sign-in distance between the student and the lecturer;
[0036] The teaching process verification module obtains the teaching time and randomly pushes confirmation messages to some students who have signed in during the teaching period. Based on the randomly pushed confirmation messages, the teaching process is verified.
[0037] The sign-out verification module obtains the end-of-course information of offline courses in the insurance industry, generates dynamic QR codes for lecturers and students to sign out respectively, calculates the sign-out distance between the student and the lecturer based on the current device location information of the lecturer and the student, and performs sign-out verification after the course based on the sign-out distance between the student and the lecturer;
[0038] The picture verification module obtains the teaching site pictures of the offline courses in the insurance industry and the Exif information of the teaching site pictures, and performs picture similarity and integrity verification based on the teaching site pictures and the Exif information of the teaching site pictures. If the pre-class sign-in verification, teaching process verification, post-class sign-out verification, picture similarity and integrity verification are all verified, then the authenticity verification of the offline course information in the insurance industry passes, otherwise the authenticity verification of the offline course information in the insurance industry fails.
[0039] The technical solution adopted by the present invention includes the following technical effects:
[0040] 1. The present invention calculates the check-in distance between the student and the lecturer based on the current device location information of the lecturer's check-in and the current device location information of the student's check-in, and performs check-in verification before the class based on the check-in distance between the student and the lecturer; during the class, randomly pushes confirmation messages to some of the signed-in students, and performs teaching process verification based on the randomly pushed confirmation messages; calculates the check-out distance between the student and the lecturer based on the current device location information of the lecturer's check-out and the current device location information of the student's check-out, and performs check-out verification after the class based on the check-out distance between the student and the lecturer; obtains on-site pictures of offline courses in the insurance industry and the distance of the lecturer The Exif information of the class scene pictures is used to verify the picture similarity and integrity based on the class scene pictures and the Exif information of the class scene pictures; if the pre-class sign-in verification, teaching process verification, post-class sign-out verification, picture similarity and integrity verification are all passed, the authenticity verification of the insurance industry offline course information is passed, otherwise the authenticity verification of the insurance industry offline course information fails, which effectively solves the problem of low reliability of the authenticity verification of the insurance industry offline course information caused by the existing technology, and effectively improves the reliability of the authenticity verification of the insurance industry offline course information.
[0041] 2. The technical solution of the present invention can not only verify the similarity of pictures based on the hash value of the pictures of the teaching site and the hash value of the pictures to be compared in the historical picture library; but also verify the integrity of the pictures based on the Exif information of the pictures, further improving the reliability of the authenticity verification of offline course information in the insurance industry.
[0042] 3. The technical solution of the present invention performs image rationality verification based on the Exif information of the image, further improving the reliability of authenticity verification of offline course information in the insurance industry.
[0043] 4. The technical solution of the present invention verifies the rationality of the image through the shooting time and shooting coordinates in the image Exif information, further improving the reliability of the authenticity verification of offline course information in the insurance industry.
[0044] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0046] Figure 1 This is a schematic diagram of a process of a method in Example 1 of the present invention;
[0047] Figure 2 It is a schematic diagram of the structure of the system of Example 2 in the solution of the present invention. DETAILED DESCRIPTION
[0048] In order to clearly illustrate the technical features of the present solution, the present invention is described in detail below through specific implementation methods and in conjunction with the accompanying drawings. The disclosure below provides many different embodiments or examples for realizing different structures of the present invention. In order to simplify the disclosure of the present invention, the components and settings of specific examples are described below. In addition, the present invention may repeat reference numbers and / or letters in different examples. This repetition is for the purpose of simplification and clarity, and does not itself indicate the relationship between the various embodiments and / or settings discussed. It should be noted that the components illustrated in the accompanying drawings are not necessarily drawn to scale. The present invention omits the description of known components and processing techniques and processes to avoid unnecessary limitations on the present invention.
[0049] Embodiment 1
[0050] like Figure 1 As shown, the present invention provides a method for verifying the authenticity of offline course information in the insurance industry, comprising:
[0051] S1, obtain the teaching start information of offline courses in the insurance industry, generate dynamic QR codes for lecturers and course students to sign in respectively, calculate the sign-in distance between the student and the lecturer according to the current device location information of the lecturer and the current device location information of the student, and perform sign-in verification before the class based on the sign-in distance between the student and the lecturer;
[0052] S2, obtaining the teaching time information, randomly pushing confirmation messages to some students who have signed in during the teaching period, and verifying the teaching process based on the randomly pushed confirmation messages;
[0053] S3, obtain the end-of-course information of offline courses in the insurance industry, generate dynamic QR codes for lecturers and students to sign out respectively, calculate the sign-out distance between the student and the lecturer according to the current device location information of the lecturer and the student, and perform sign-out verification after the course based on the sign-out distance between the student and the lecturer;
[0054] S4, obtaining the lecture site pictures of the offline courses in the insurance industry and the Exif information of the lecture site pictures, and performing picture similarity and integrity verification based on the lecture site pictures and the Exif information of the lecture site pictures;
[0055] S5, judging whether the pre-class sign-in verification, the teaching process verification, the post-class sign-out verification, the image similarity and integrity verification are all verified. If the judgment result is yes, executing step S6; if the judgment result is no, executing step S7;
[0056] S6, the authenticity verification of offline course information in the insurance industry has been passed;
[0057] S7, authenticity verification of offline course information in the insurance industry failed.
[0058] Among them, in step S1, the relevant processing program is developed in Java language, and the device and location information are obtained by using the JSSDK method of the APP (a software development kit designed specifically for JavaScript, allowing developers to use specific services or functions in web pages or web applications). The lecturer fills in the basic teaching information (the teaching start information is one of them), triggers the course start logic, forms a dynamic sign-in QR code, and obtains the latitude and longitude information of the current course (the lecturer signs in the current device location information) and time information through the JSSDK method, which mainly includes the following aspects of verification:
[0059] S1.1, check-in time control, set the check-in validity time to time0, unit is minutes. If time exceeds time0, you will not be able to scan the code to check in. After the check-in countdown ends, the check-in entrance will be automatically closed and the check-in QR code display will be closed.
[0060] S1.2, dynamic QR code setting, set the dynamic switching time of the QR code to time1, in seconds, the default is 10 seconds. After the time exceeds, a new sign-in QR code will be dynamically generated to further prevent remote sign-in by forwarding the sign-in code through screenshots, etc.
[0061] S1.3, according to the current device location information of the lecturer and the current device location information of the student, calculate the check-in distance between the student and the lecturer, and perform the check-in verification before the class based on the check-in distance between the student and the lecturer.
[0062] Specifically, according to the longitude and latitude coordinates in the current device location information of the lecturer and the longitude and latitude coordinates in the current device location information of the student, the Ellipsoid.Sphere model (a common earth model, a mathematical model used to describe the shape of the earth) is used to calculate the check-in distance between the student and the lecturer;
[0063] After the lecturer starts signing in, the system obtains the lecturer's current device location information through JSSDK, records the longitude and latitude information, records the double type variable teacherLat as the lecturer's latitude value, and records the double type variable teacherLng as the lecturer's longitude value. When a student signs in during the effective time of time0, the system obtains the current student's sign-in device location information through JSSDK, records the longitude and latitude information, records the double type variable studentLat as the sign-in student's latitude value, and records the double type variable studentLng as the sign-in student's longitude value. The org.gavaghan.geodesy library (a Java library for processing geographic location data, which provides a series of methods to calculate distance, direction and other geographic location-related data) and the Ellipsoid.Sphere ellipsoid model are used to implement precise distance measurement based on longitude and latitude. The specific calculation of the sign-in distance between the student and the lecturer is as follows:
[0064] Calculate the teacher's position: Get the longitude and latitude values of the data type GlobalCoordinates (global coordinates or global coordinates) through the GlobalCoordinates(teacherLat, teacherLng) method and record it as source.
[0065] Calculate the student's location: Get the longitude and latitude values of the GlobalCoordinates data type through the GlobalCoordinates(studentLat, studentLng) method and record it as target.
[0066] Then, through the GeodeticCalculator().calculateGeodeticCurve method (a method for calculating the geodetic segment between two geographic coordinates), the teacher and student point source, target and ellipsoid model Ellipsoid.Sphere are taken as parameters to get the GeodeticCurve type value and record it as geoCurve.
[0067] Finally, the distance value of type Double can be obtained through geoCurve.getEllipsoidalDistance() (a function that calculates the distance between two points through longitude and latitude), which is recorded as meter, that is, the check-in distance between the student and the instructor.
[0068] Determine whether the check-in distance between all students and the instructor is less than the preset distance threshold. If the check-in distance between a student and the instructor is not less than the preset distance threshold, the pre-class check-in verification fails. Otherwise, the pre-class check-in verification passes.
[0069] The preset distance threshold can be set to distanceMax, in meters. Considering the accuracy issue, the default value is 500m. If the meter value is greater than the distanceMax threshold, check-in cannot be performed.
[0070] Among them, in step S2, the teaching period detection (teaching process verification) sets the minimum time courseMinTime for the start and end of the course (i.e. the minimum duration of the course) in minutes, with a default of 30 minutes. Within the minimum time, a random time is selected and a confirmation message is pushed to the signed-in students. The confirmation is performed within the valid waitTime, and the waitTime defaults to two minutes. If the confirmation is not made, the sign-out cannot be performed.
[0071] The number of students who sign in is recorded as N, the default number of people to whom the confirmation message is pushed is Math.floor(N / 2), the start time is recorded as startTime, and the earliest end time is: startTime+courseMinTime. Within this time distance, a random time randomNumber is obtained through the random nextInt method (read function in Java, that is, the read result is an int type data and returns an int value), and a confirmation message is randomly pushed at randomNumber minutes.
[0072] Among them, in step S3, the sign-out information is verified. The instructor uploads the end-of-course information, and then triggers the course sign-out logic to form a dynamic sign-out QR code. The system obtains the latitude and longitude information and time information of the current course through JSSDK, which mainly includes the following aspects of verification:
[0073] S3.1, sign-out time control, set the sign-out validity time to time2, in minutes. If time2 is exceeded, you will not be able to scan the code to sign out. After the sign-out countdown ends, the sign-out entrance will be automatically closed, and the sign-out QR code display will be closed.
[0074] S3.2, dynamic QR code setting, set the QR code dynamic switching time to time3, in seconds, the default is 10 seconds. After the time exceeds, a new sign-out QR code will be dynamically generated to further prevent remote sign-out by forwarding the sign-out code through screenshots, etc.
[0075] S3.3, according to the current device location information of the lecturer when signing out and the current device location information of the student when signing out, calculate the sign-out distance between the student and the lecturer, and perform the sign-out verification after the class based on the sign-out distance between the student and the lecturer.
[0076] Specifically: according to the longitude and latitude coordinates in the current device location information of the lecturer when signing out and the longitude and latitude coordinates in the current device location information of the student when signing out, the Ellipsoid.Sphere model is used to calculate the sign-out distance between the student and the lecturer, the distance between the lecturer when signing out and signing in, the distance between the student when signing in and signing out, and the distance between the student and the lecturer when signing out;
[0077] After the lecturer turns on sign-out, the system obtains the lecturer's current device location information through JSSDK, records the longitude and latitude information, records the double type variable teacherLat1 as the lecturer's latitude value, and records the double type variable teacherLng1 as the lecturer's longitude value. When the student signs out within the effective time of time2, the system obtains the current student's sign-out device location information through JSSDK, records the longitude and latitude information, records the double type variable studentLat1 as the sign-out student's latitude value, and records the double type variable studentLng1 as the sign-out student's longitude value. Using the calculation method in S1.3, calculate the distance m1 between the two longitudes when the lecturer signs out and signs in, the distance m2 between the two longitudes when the student signs in and signs out, and the distance m3 between the student and the lecturer when signing out.
[0078] Determine whether the sign-out distance between all students and lecturers, the distance between the lecturer's sign-out and sign-in, and the distance between the students' sign-in and sign-out are all less than the preset distance threshold. If there is a student whose sign-out distance between the lecturer is not less than the preset distance threshold, or any of the distance between the lecturer's sign-out and sign-in, and the distance between the students' sign-in and sign-out is not less than the preset distance threshold, then the pre-class sign-out verification fails; otherwise, the pre-class sign-in verification passes.
[0079] When m1 is greater than the distanceMax threshold, the sign-out process cannot be started. When m2 and m3 are greater than the distanceMax threshold, evaluation and sign-in cannot be performed.
[0080] Among them, in step S4, based on the teaching scene pictures (lecturer's teaching photos and students' proof photos uploaded) and the Exif information of the teaching scene pictures, the picture similarity and integrity verification specifically includes:
[0081] S4.1, based on the hash value of the lecture scene picture and the hash value of the picture to be compared in the historical picture library, perform picture similarity verification;
[0082] S4.2, based on the Exif information of the image, perform image integrity verification.
[0083] It should be noted that the execution order of steps S4.1 and S4.2 can be step S4.1 executed first, or step S4.2 executed first, and the present invention does not limit this.
[0084] Wherein, step S4.1 specifically includes:
[0085] S4.1.1 respectively obtain the paths of the teaching scene picture and the picture to be compared, convert the paths of the teaching scene picture and the picture to be compared into files respectively, and based on the converted files, convert the teaching scene picture and the picture to be compared into BufferedImage type;
[0086] Verify the similarity of pictures taken at the lecture site to prevent the same picture from being used multiple times. Use the fingerprint similarity comparison method to process the current picture and compare the similarity with the historical picture library. Set a threshold. If the threshold is exceeded, the picture is suspected of being used repeatedly and is written into the suspected problem label library.
[0087] Hash is a common cryptographic technology used to convert messages of any length into summary information of fixed length and ensure that any modification to the original message will result in different summary information. Hash technology is widely used in information security, data integrity verification and digital signature.
[0088] Hash characteristics: Compression: No matter how long the input message is, the length of the generated hash value is fixed.
[0089] Computational ease: The operation of computing hash values is easy, even when the amount of data being processed is large.
[0090] Collision resistance: It is difficult to find two different input messages that hash to the same value, also known as a "hash collision".
[0091] Hash algorithm: Simply put, it is to generate a value after processing any input in a specific way (hash function). This value is equivalent to the address where the data is stored, and the input data is stored in this address.
[0092] Hash algorithm, also known as hash algorithm, is a method of creating a small digital "fingerprint" from any file. Like fingerprint, hash algorithm is a mark that uses shorter information to ensure the uniqueness of a file. This mark is related to every byte of the file, and it is difficult to find a reverse pattern.
[0093] Specifically, the paths of the lecture scene picture and the picture to be compared are recorded as URL1 and URL2 respectively, and then the paths are converted into files through the new File method, and then the pictures are converted into BufferedImage types through the ImageIO.read(file) method (the picture reading function in Java), and recorded as image1 and image2.
[0094] S4.1.2, scale the lecture scene picture and the picture to be compared to the set size;
[0095] Scale the image to the specified size. First, create a new image with HASH_SIZE of 16 and image type BufferedImage.TYPE_3BYTE_BGR through the new BufferedImage method (an important class for processing images in Java), and record it as newResult. Then, get the Graphics value (the parameter value used in the graphics processing process) through the getGraphics method (a function for obtaining image parameters in Java), record it as g, and finally scale the image to the specified size through the drawImage method (drawing the specified Image at the specified position), and record it as hashImage.
[0096] S4.1.3, converting the scaled teaching scene picture and the picture to be compared into grayscale images;
[0097] Convert the hashImage in S4.1.2 to a grayscale image. Use the BufferedImage method to set the image type to BufferedImage.TYPE_BYTE_GRAY based on the length and width of the hashImage image, create a new BufferedImage, record it as grayImage, and use the ColorConvertOp class to perform pixel-by-pixel color conversion on the data in the source image grayImage through the ColorSpace object array and assign it to grayImage.
[0098] S4.1.4, converting the teaching scene picture converted into grayscale image and the picture to be compared into byte array, and performing binarization processing on the converted byte array;
[0099] Convert the grayscale image grayImage in S4.1.3 to a byte array. Convert the grayImage image to a byte array value through the getData and getDataElements methods (functions for obtaining data in Java), and record it as matrixGray. Binarize the byte array value matrixGray. First, reassign the value to the new byte array dst through the matrixGray.clone() method, then convert the matrixGray array elements to unsigned integers and calculate the mean, record it as mean, then convert the dst array elements to unsigned integers and compare each element with mean. If it is greater than or equal to mean, it is 1, otherwise it is 0, and the binarization is completed.
[0100] S4.1.5, use the byte array corresponding to the teaching scene picture after binarization processing as the hash array hash1 of the teaching scene picture, use the byte array corresponding to the picture to be compared after binarization processing as the hash array hash2 of the picture to be compared, calculate the ratio of the array elements that are the same in the hash array hash1 of the teaching scene picture and the hash array hash2 of the picture to be compared, to the total array elements of the hash array hash1 of the teaching scene picture or the hash array hash2 of the picture to be compared, and use the ratio of the array elements that are the same in the hash array hash1 of the teaching scene picture and the hash array hash2 of the picture to be compared to the total array elements of the hash array hash1 of the teaching scene picture or the hash array hash2 of the picture to be compared as the similarity between the teaching scene picture and the picture to be compared; if the similarity exceeds the preset similarity threshold, the similarity verification of the teaching scene pictures fails, otherwise, the similarity verification of the teaching scene pictures succeeds.
[0101] Create a new int variable sameCount and initialize it to 0. Loop through the variable hash1, record the index as index and compare. If hash1[index] is equal to hash2[index], add 1 to sameCount. After the loop, divide the sameCount value by hash1.length to get the float type value percent, which is the similarity value. The value range is (0.0-1.0). Set the similarity threshold same. The default value is 0.9, which can be adjusted according to the actual situation. If the threshold is exceeded, the course site picture and the picture to be compared will be marked and written into the suspected problem tag library.
[0102] Among them, the Exif information in step S4.2 may include shooting coordinates, shooting time, mobile phone manufacturer, and mobile phone model.
[0103] The APP's JSSDK method is used to obtain the lecturer's mobile device information (authorization required), and the information is converted into a string and recorded as: phoneInfo. At the same time, the backend triggers the course site picture verification function, analyzes the course site pictures from multiple dimensions through multi-threading, forms multiple types of suspected tags, and feedbacks the analysis results, which is convenient for the superior auditor to further confirm through the suspected tags.
[0104] Use Java programming language combined with metadata-extractor library (a component library for extracting Exif information of pictures and videos) to automatically obtain the Exif information of pictures, and obtain the shooting coordinates, shooting time, mobile phone model and other information of the photos.
[0105] Metadata, also known as intermediary data or relay data, is data about data, mainly information describing data properties. It is used to support functions such as indicating storage location, historical data, resource search, and file records. Metadata is information about the organization of data, data domains, and their relationships.
[0106] Image metadata is a set of tags embedded in image files. It is similar to file attributes, but there are many types. For digital images, the most common metadata are EXIF, IPTC and XMP. EXIF is usually automatically added by digital cameras when taking photos, such as camera model, lens, exposure, image size and other information.
[0107] Exchangeable Image File (Exif) information: The relevant parameters of the image retained when it was taken: such as image information (manufacturer, resolution, etc.), camera shooting records (ISO, white balance, saturation, sharpness, etc.), thumbnails (thumbnail width, height, etc.), GPS (longitude, latitude, altitude at the time of shooting), etc., are stored in the image header file according to the image file standard.
[0108] Metadata information acquisition. In the project Pom.xml, introduce com.drewnoakes.metadata-extractor, select the latest version, and use ImageMetadataReader to uniformly obtain metadata information. There are also targeted classes for Jpg, Png, Gif, etc., such as JpegMetadataReader, PngMetadataReader, GifMetadataReader, etc.
[0109] First, convert the image to be analyzed into a file, and then convert the image file into a Metadata object through the imageMetadataReader.readMetadata(file) method and record it as metadata.
[0110] Then, get a list of Directory type data through the metadata.getDirectories() method, loop the list, and record each loop object as a directory.
[0111] Then, get the Tag type data list through the directory.getTags() method, loop the list, and record each loop object as a tag.
[0112] Finally, get the tag name through tag.getTagName() and get the tag information through tag.getDescription(). The following is an example of the tag name and tag information in the image Exif information (only part of the relevant data is shown):
[0113] Image Height===4096pixels
[0114] Image Width===8192pixels
[0115] Image Width === 8192 pixels Image Height === 4096 pixels Make === HUAWEI Model === YAL-AL10 Date / Time === 2021:03:21 14:13:31 ExifVersion === 2.30 Date / Time Original === 2021:03:21 14:13:31 Date / Time Digitized === 2021:03:21 14:13:31 ExifImage Width === 8192 pixels ExifImage Height === 4096 pixels File Source === Digital Still Camera(DSC) GPS Version ID === 2.300 GPSLatitude Ref === N GPS Latitude === 28°14'37.6" GPS Longitude Ref === E GPSLongitude === 112°53'24.86" GPS Altitude Ref === Sea level GPS Altitude === 126 metres Image Width === 192 pixels Image Height === 90 pixels Compression === JPEG
[0116] Detected File Type Name === JPEG
[0117] Detected File Type Long Name === Joint Photographic Experts Group
[0118] Detected MIME Type === image / jpeg
[0119] Expected File Name Extension === jpg
[0120] File Name === 1.jpg
[0121] File Size === 14057645 bytes
[0122] File Modified Date === Tuesday March 23 20:14:37 +08:00 2021
[0123] In the above information, Make and Model indicate the manufacturer and model of the mobile phone respectively; GPS Version ID, GPSLatitude Ref, GPS Latitude, GPS Longitude Ref, GPS Longitude, GPS Altitude Ref, and GPS Altitude indicate the latitude and longitude information of GPS; Date / Time Digitized indicates the time when the image was created; and FileModified Date indicates the time when the image was modified.
[0124] Convert the longitude and latitude data in the metadata information. Obtain the Collection of GpsDirectory type through the getDirectoriesOfType method, record it as gpsDirectories, then traverse the collection to obtain the data of GpsDirectory type, record it as gps, and then obtain the GeoLocation type data through the gps.getGeoLocation() method, record it as geoLocation, and finally, obtain the longitude value of Double type through the geoLocation.getLongitude() method, record it as lng, and obtain the latitude value of Double type through the geoLocation.getLatitude() method, record it as lat, where lng and lat are the longitude and latitude values when the picture was taken.
[0125] Step S4.2 specifically includes:
[0126] Determine whether the Exif information of the lecture scene picture to be verified is missing or empty. If it is missing or empty, the picture integrity verification fails. If it is not missing or empty, the picture integrity verification passes.
[0127] Based on the Exif information of the on-site teaching picture to be verified, obtain the make information, that is, the mobile phone manufacturer name information and model information, and then use the lecturer's sign-out current device information phoneInfo to determine whether the lecturer's sign-out current device contains the mobile phone manufacturer name and model information in make through the contains method (a method in Java used to check whether a List contains a specified element). If not, suspect that the source of the picture is problematic and write it into the suspected problem tag library.
[0128] If there is little EXIF information or no shooting coordinates, shooting time, mobile phone manufacturer, or mobile phone model information, it can be suspected that the image has been edited and is not the original image, and is written into the suspected problem tag library.
[0129] Furthermore, step S4 further includes:
[0130] S4.3, based on the Exif information of the image, verify the rationality of the image.
[0131] It should be noted that the execution order of step S4.3 is after the execution order of step S4.2.
[0132] Step 4.3 specifically includes:
[0133] Determine whether the photo of the class scene is taken between the sign-in start time and the sign-out start time. If the photo of the class scene is not taken between the sign-in start time and the sign-out start time, the photo of the class scene is not taken between classes, and the photo rationality verification fails;
[0134] Determine whether the photo shooting time Date / Time Digitized is between the class start time (sign-in start time) and the class end time (sign-out start time). Record the sign-in start time as signIn, the sign-out start time as signOut, and the photo shooting time Digitized as Date / Time Digitized. Convert the three dates to milliseconds using the getTime() method and compare them. If Digitized is less than signIn or Digitized is greater than signOut, it means that the photo was not taken between classes, and it is written into the suspected problem tag library.
[0135] Determine whether the distances between the position corresponding to the shooting coordinates of the teaching site picture and the check-in positions of all students or lecturers, and the check-out positions of all students or lecturers are less than the preset distance threshold. If the number of times the distances between the position corresponding to the shooting coordinates of the teaching site picture and the check-in positions of all students or lecturers, and the check-out positions of all students or lecturers are greater than the preset distance threshold exceeds the preset number threshold, then the teaching site picture is not taken between classes, and the picture rationality verification fails.
[0136] According to the method in step S1.3, the distance between the position corresponding to the shooting coordinates of the teaching scene picture and the sign-in position L1 of all students, the distance between the position corresponding to the shooting coordinates of the teaching scene picture and the sign-in position L2 of the lecturer, the distance between the position corresponding to the shooting coordinates of the teaching scene picture and the sign-out position of all students L3, and the distance between the position corresponding to the shooting coordinates of the teaching scene picture and the sign-out position of the lecturer L4 are all less than the preset distance threshold (distanceMax threshold); if the number of times (one time for one student) between the position corresponding to the shooting coordinates of the teaching scene picture and the sign-in position L1 of all students, the position corresponding to the shooting coordinates of the teaching scene picture and the sign-in position L2 of the lecturer, the distance between the position corresponding to the shooting coordinates of the teaching scene picture and the sign-out position of all students L3, and the distance between the position corresponding to the shooting coordinates of the teaching scene picture and the sign-out position of the lecturer L4 is greater than the preset distance threshold, the data and the number of times exceeding the distanceMax threshold are written into the suspected problem label library.
[0137] Based on S1-S7, the authenticity verification of offline courses is completed. The superior management agency can more quickly determine the authenticity of the course based on the suspected problem labels fed back, facilitate the management of grassroots courses, and improve work quality and efficiency.
[0138] The present invention calculates the check-in distance between the student and the lecturer based on the current device location information of the lecturer when signing in and the current device location information of the student when signing in, and performs check-in verification before the class based on the check-in distance between the student and the lecturer; during the class, randomly pushes confirmation messages to some of the signed-in students, and performs verification of the class process based on the randomly pushed confirmation messages; calculates the check-out distance between the student and the lecturer based on the current device location information of the lecturer when signing out and the current device location information of the student when signing out, and performs check-out verification after the class based on the check-in distance between the student and the lecturer; obtains on-site pictures of offline courses in the insurance industry and the distance of the class The Exif information of the on-site pictures is used to verify the image similarity and integrity based on the teaching site pictures and the Exif information of the teaching site pictures; if the pre-class sign-in verification, teaching process verification, post-class sign-out verification, image similarity and integrity verification are all passed, the authenticity verification of the offline course information in the insurance industry is passed, otherwise the authenticity verification of the offline course information in the insurance industry fails, which effectively solves the problem of low reliability of the authenticity verification of the offline course information in the insurance industry caused by the existing technology, and effectively improves the reliability of the authenticity verification of the offline course information in the insurance industry.
[0139] The technical solution of the present invention can not only perform image similarity verification based on the hash value of the teaching site picture and the hash value of the picture to be compared in the historical picture library; but also perform image integrity verification based on the Exif information of the picture, further improving the reliability of authenticity verification of offline course information in the insurance industry.
[0140] The technical solution of the present invention performs image rationality verification based on the Exif information of the image, further improving the reliability of authenticity verification of offline course information in the insurance industry.
[0141] In the technical solution of the present invention, the rationality of the image is verified through two aspects (dimensions) such as the shooting time and shooting coordinates in the image Exif information, thereby further improving the reliability of the authenticity verification of offline course information in the insurance industry.
[0142] Embodiment 2
[0143] like Figure 2 As shown, the technical solution of the present invention also provides a verification system for the authenticity of offline course information in the insurance industry, including:
[0144] The sign-in verification module 101 obtains the teaching start information of the offline course of the insurance industry, generates dynamic QR codes for the lecturer and the course students to sign in respectively, calculates the sign-in distance between the student and the lecturer according to the current device location information of the lecturer and the current device location information of the student, and performs sign-in verification before the class based on the sign-in distance between the student and the lecturer;
[0145] The teaching process verification module 102 obtains the teaching time, randomly pushes confirmation messages to some students who have signed in during the teaching period, and verifies the teaching process based on the randomly pushed confirmation messages;
[0146] The sign-out verification module 103 obtains the end-of-course information of offline courses in the insurance industry, generates dynamic QR codes for the instructor and the course students to sign out respectively, calculates the sign-out distance between the student and the instructor according to the current device location information of the instructor and the student, and performs sign-out verification after the course based on the sign-out distance between the student and the instructor;
[0147] The picture verification module 104 obtains the teaching site pictures of the offline courses in the insurance industry and the Exif information of the teaching site pictures, and performs picture similarity and integrity verification based on the teaching site pictures and the Exif information of the teaching site pictures. If the pre-class sign-in verification, teaching process verification, post-class sign-out verification, picture similarity and integrity verification are all verified, then the authenticity verification of the offline course information in the insurance industry passes, otherwise the authenticity verification of the offline course information in the insurance industry fails.
[0148] It should be noted that the execution function steps of the sign-in verification module 101, the teaching process verification module 102, the sign-out verification module 103, and the picture verification module 104 in the embodiment of the present invention correspond to the method flow of the first embodiment, and will not be repeated in this embodiment.
[0149] The present invention calculates the check-in distance between the student and the lecturer based on the current device location information of the lecturer when signing in and the current device location information of the student when signing in, and performs check-in verification before the class based on the check-in distance between the student and the lecturer; during the class, randomly pushes confirmation messages to some of the signed-in students, and performs verification of the class process based on the randomly pushed confirmation messages; calculates the check-out distance between the student and the lecturer based on the current device location information of the lecturer when signing out and the current device location information of the student when signing out, and performs check-out verification after the class based on the check-in distance between the student and the lecturer; obtains on-site pictures of offline courses in the insurance industry and the distance of the class The Exif information of the on-site pictures is used to verify the image similarity and integrity based on the teaching site pictures and the Exif information of the teaching site pictures; if the pre-class sign-in verification, teaching process verification, post-class sign-out verification, image similarity and integrity verification are all passed, the authenticity verification of the offline course information in the insurance industry is passed, otherwise the authenticity verification of the offline course information in the insurance industry fails, which effectively solves the problem of low reliability of the authenticity verification of the offline course information in the insurance industry caused by the existing technology, and effectively improves the reliability of the authenticity verification of the offline course information in the insurance industry.
[0150] The technical solution of the present invention can not only perform image similarity verification based on the hash value of the teaching site picture and the hash value of the picture to be compared in the historical picture library; but also perform image integrity verification based on the Exif information of the picture, further improving the reliability of authenticity verification of offline course information in the insurance industry.
[0151] The technical solution of the present invention performs image rationality verification based on the Exif information of the image, further improving the reliability of authenticity verification of offline course information in the insurance industry.
[0152] The technical solution of the present invention verifies the rationality of the image through two aspects (dimensions) such as the shooting time and shooting coordinates in the image Exif information, further improving the reliability of the authenticity verification of offline course information in the insurance industry.
[0153] Although the above describes the specific implementation mode of the present invention in conjunction with the accompanying drawings, it is not intended to limit the scope of protection of the present invention. Those skilled in the art should understand that various modifications or variations that can be made by those skilled in the art on the basis of the technical solution of the present invention without creative work are still within the scope of protection of the present invention.
Claims
1. A method for verifying the authenticity of offline course information in the insurance industry, characterized in that: include: Obtain the start information of offline courses in the insurance industry, generate dynamic QR codes for lecturers and students to sign in respectively, calculate the sign-in distance between students and lecturers based on the current device location information of the lecturer and the student, and perform sign-in verification before the class based on the sign-in distance between students and lecturers; Obtain the teaching time information, randomly push confirmation messages to some students who have signed in during the teaching period, and verify the teaching process based on the randomly pushed confirmation messages; Obtain the end-of-course information of offline courses in the insurance industry, generate dynamic QR codes for lecturers and students to sign out respectively, calculate the sign-out distance between the student and lecturer based on the current device location information of the lecturer and the student, and perform sign-out verification after the course based on the sign-out distance between the student and lecturer; Get the on-site pictures of the insurance industry's offline courses and their Exif information, and perform picture similarity and integrity verification based on the on-site pictures and their Exif information; if the pre-class sign-in verification, teaching process verification, post-class sign-out verification, picture similarity and integrity verification are all passed, then the authenticity verification of the insurance industry's offline course information passes, otherwise the authenticity verification of the insurance industry's offline course information fails.
2. A method for verifying the authenticity of offline course information in the insurance industry according to claim 1, characterized in that: The method of calculating the check-in distance between the student and the lecturer based on the current device location information of the lecturer and the current device location information of the student, and performing the check-in verification before the class based on the check-in distance between the student and the lecturer specifically includes: According to the longitude and latitude coordinates in the current device location information of the lecturer and the longitude and latitude coordinates in the current device location information of the student, the Ellipsoid.Sphere model is used to calculate the check-in distance between the student and the lecturer. Determine whether the check-in distance between all students and the instructor is less than the preset distance threshold. If the check-in distance between a student and the instructor is not less than the preset distance threshold, the pre-class check-in verification fails. Otherwise, the pre-class check-in verification passes.
3. A method for verifying the authenticity of offline course information in the insurance industry according to claim 1, characterized in that: The method of calculating the sign-out distance between the student and the lecturer according to the current device location information of the lecturer and the current device location information of the student when the lecturer signs out, and performing the sign-out verification after the class based on the sign-out distance between the student and the lecturer specifically includes: According to the longitude and latitude coordinates in the current device location information of the lecturer when signing out and the longitude and latitude coordinates in the current device location information of the student when signing out, the Ellipsoid.Sphere model is used to calculate the sign-out distance between the student and the lecturer, the distance between the lecturer when signing out and when signing in, and the distance between the student when signing in and signing out; Determine whether the sign-out distance between all students and lecturers, the distance between the lecturer's sign-out and sign-in, and the distance between the students' sign-in and sign-out are all less than the preset distance threshold. If there is a student whose sign-out distance between the lecturer is not less than the preset distance threshold, or any of the distance between the lecturer's sign-out and sign-in, and the distance between the students' sign-in and sign-out is not less than the preset distance threshold, then the pre-class sign-out verification fails; otherwise, the pre-class sign-in verification passes.
4. A method for verifying the authenticity of offline course information in the insurance industry according to claim 1, characterized in that: The image similarity and integrity verification based on the teaching scene image and the Exif information of the teaching scene image specifically includes: Based on the hash value of the on-site teaching pictures and the hash value of the pictures to be compared in the historical picture library, the picture similarity verification is performed; Image integrity verification is performed based on the image's Exif information.
5. A method for verifying the authenticity of offline course information in the insurance industry according to claim 4, characterized in that: The image similarity verification based on the hash value of the teaching scene image and the hash value of the image to be compared in the historical image library specifically includes: Get the paths of the teaching scene picture and the picture to be compared respectively, convert the paths of the teaching scene picture and the picture to be compared into files respectively, and convert the teaching scene picture and the picture to be compared into BufferedImage type based on the converted files; Scale the lecture scene pictures and the pictures to be compared to the set size; Convert the zoomed lecture scene pictures and the pictures to be compared into grayscale images; Convert the teaching scene pictures converted into grayscale images and the pictures to be compared into byte arrays, and perform binarization processing on the converted byte arrays; The byte array corresponding to the teaching scene picture after binarization is used as the hash array hash1 of the teaching scene picture, and the byte array corresponding to the picture to be compared after binarization is used as the hash array hash2 of the picture to be compared. The ratio of the array elements of the hash array hash1 of the teaching scene picture and the hash array hash2 of the picture to be compared to the total array elements of the hash array hash1 of the teaching scene picture or the hash array hash2 of the picture to be compared is calculated. If the array elements of the hash array hash1 of the teaching scene picture and the hash array hash2 of the picture to be compared are the same, the ratio of the array elements of the hash array hash1 of the teaching scene picture and the hash array hash2 of the picture to be compared is used as the similarity between the teaching scene picture and the picture to be compared; if the similarity exceeds the preset similarity threshold, the similarity verification of the teaching scene pictures fails, otherwise, the similarity verification of the teaching scene pictures succeeds.
6. A method for verifying the authenticity of offline course information in the insurance industry according to claim 4, characterized in that: The Exif information includes shooting coordinates, shooting time, mobile phone manufacturer, and mobile phone model.
7. A method for verifying the authenticity of offline course information in the insurance industry according to claim 6, characterized in that: The image integrity verification based on the Exif information of the image specifically includes: Determine whether the Exif information of the lecture scene picture to be verified is missing or empty. If it is missing or empty, the picture integrity verification fails. If it is not missing or empty, the picture integrity verification passes.
8. A method for verifying the authenticity of offline course information in the insurance industry according to claim 6, characterized in that: Also includes: Based on the Exif information of the image, the rationality of the image is verified.
9. A method for verifying the authenticity of offline course information in the insurance industry according to claim 8, characterized in that: The image rationality verification based on the Exif information of the image specifically includes: Determine whether the photo of the class scene is taken between the sign-in start time and the sign-out start time. If the photo of the class scene is not taken between the sign-in start time and the sign-out start time, the photo of the class scene is not taken between classes, and the photo rationality verification fails; Determine whether the distances between the position corresponding to the shooting coordinates of the teaching site picture and the check-in positions of all students or lecturers, and the check-out positions of all students or lecturers are less than the preset distance threshold. If the number of times the distances between the position corresponding to the shooting coordinates of the teaching site picture and the check-in positions of all students or lecturers, and the check-out positions of all students or lecturers are greater than the preset distance threshold exceeds the preset number threshold, then the teaching site picture is not taken between classes, and the picture rationality verification fails.
10. A verification system for the authenticity of offline course information in the insurance industry, characterized in that: include: The sign-in verification module obtains the start information of offline courses in the insurance industry, generates dynamic QR codes for lecturers and course students to sign in respectively, calculates the sign-in distance between the student and the lecturer based on the current device location information of the lecturer and the student, and performs sign-in verification before the class based on the sign-in distance between the student and the lecturer; The teaching process verification module obtains the teaching time and randomly pushes confirmation messages to some students who have signed in during the teaching period. Based on the randomly pushed confirmation messages, the teaching process is verified. The sign-out verification module obtains the end-of-course information of offline courses in the insurance industry, generates dynamic QR codes for lecturers and students to sign out respectively, calculates the sign-out distance between the student and the lecturer based on the current device location information of the lecturer and the student, and performs sign-out verification after the course based on the sign-out distance between the student and the lecturer; The picture verification module obtains the teaching site pictures of the offline courses in the insurance industry and the Exif information of the teaching site pictures, and performs picture similarity and integrity verification based on the teaching site pictures and the Exif information of the teaching site pictures. If the pre-class sign-in verification, teaching process verification, post-class sign-out verification, picture similarity and integrity verification are all verified, then the authenticity verification of the offline course information in the insurance industry passes, otherwise the authenticity verification of the offline course information in the insurance industry fails.