Last active
April 28, 2024 09:21
-
-
Save PotatoPwn/7197a02839db3fb6b4a1e3db43d9623c to your computer and use it in GitHub Desktop.
Revisions
-
PotatoPwn revised this gist
Apr 28, 2024 . 1 changed file with 5 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -36,6 +36,10 @@ int main() Fullname = ConvertToPuni("You"); Password = ConvertToPuni("Cunt"); bool Result = FilterPassword(AccountName, Fullname, Password, 0); printf("Password Strong > %s\n", Result ? "True" : "False"); return 0; } -
PotatoPwn revised this gist
Apr 28, 2024 . 1 changed file with 4 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -24,8 +24,11 @@ PUNICODE_STRING ConvertToPuni(char* Character) int main() { // Passfilt.dll // Build Project in 32bit if using 32bit Passfilt.dll & ViseVersa _FilterPassword FilterPassword = reinterpret_cast<_FilterPassword>(GetProcAddress(LoadLibrary("Passfilt.dll"), "PasswordFilter")); PUNICODE_STRING AccountName, Fullname, Password; -
PotatoPwn created this gist
Apr 28, 2024 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,38 @@ #include <iostream> #include <Windows.h> #include <SubAuth.h> using _FilterPassword = BOOLEAN(*)(PUNICODE_STRING AccountName, PUNICODE_STRING FullName, PUNICODE_STRING Password, BOOLEAN IsSet); PUNICODE_STRING ConvertToPuni(char* Character) { int Len = MultiByteToWideChar(CP_UTF8, 0, Character, -1, NULL, 0); PWSTR StringAlloc = static_cast<PWSTR>(LocalAlloc(LMEM_ZEROINIT, Len * sizeof(WCHAR))); MultiByteToWideChar(CP_UTF8, 0, Character, -1, StringAlloc, Len); PUNICODE_STRING Value = static_cast<PUNICODE_STRING>(LocalAlloc(LMEM_ZEROINIT, sizeof(UNICODE_STRING))); Value->Buffer = StringAlloc; Value->Length = Len; Value->MaximumLength = Len; return Value; } int main() { _FilterPassword FilterPassword = reinterpret_cast<_FilterPassword>(GetProcAddress(LoadLibrary("PassFilter.dll"), "PasswordFilter")); PUNICODE_STRING AccountName, Fullname, Password; AccountName = ConvertToPuni("Fuck"); Fullname = ConvertToPuni("You"); Password = ConvertToPuni("Cunt"); FilterPassword(AccountName, Fullname, Password, 0); return 0; }