We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
$
String location does not point to the character $ and instead points to the first character of the identifier name.
string.location.begin [should be equal] string.token_id.location.begin
location.begin
location.end
def test_string_id_location(self): ymod = yaramod.Yaramod() yara_file = ymod.parse_string(r'''rule rule1 : Tag1 { strings: $1 = "Hello World!" condition: false } ''') s = yara_file.rules[0].strings[0] self.assertEqual(s.token_id.location.begin.line, 3) self.assertEqual(s.token_id.location.begin.column, 9) self.assertEqual(s.token_id.location.end.line, 3) self.assertEqual(s.token_id.location.end.column, 10) self.assertEqual(s.location.begin.line, 3) self.assertEqual(s.location.begin.column, 9) # FIXME: Wrong - 10 / Correct - 9 self.assertEqual(s.location.end.line, 3) self.assertEqual(s.location.end.column, 10)
The text was updated successfully, but these errors were encountered:
No branches or pull requests
String location does not point to the character
$
and instead points to the first character of the identifier name.string.location.begin [should be equal] string.token_id.location.begin
location.begin
should point to the$
characterlocation.end
should point to the last character of the string value (depending on the string type)The text was updated successfully, but these errors were encountered: