Skip to content

Instantly share code, notes, and snippets.

Avatar

Rafael Rivera riverar

View GitHub Profile
View keybase.md

Keybase proof

I hereby claim:

  • I am riverar on github.
  • I am rafael (https://keybase.io/rafael) on keybase.
  • I have a public key whose fingerprint is 3E18 3879 1DB0 7B7C A2B5 F94F 050B 5707 E2BF 6D6A

To claim this, I am signing this object:

@riverar
riverar / gist:4052f4a792ad2b784f8f
Created May 28, 2014
Diff of TrueCrypt 7.1a and "TrueCrypt 7.2" sources
View gist:4052f4a792ad2b784f8f
--- Boot/Windows/BootMain.cpp Mon Jan 19 14:26:12 1970
+++ Boot/Windows/BootMain.cpp Mon Jan 19 14:26:12 1970
@@ -75,7 +75,9 @@
#endif // TC_WINDOWS_BOOT_RESCUE_DISK_MODE
- PrintEndl (3);
+ PrintEndl (2);
+ Print ("WARNING: Using TrueCrypt is not secure");
+ PrintEndl (2);
@riverar
riverar / gist:fd6525579d6bbafc6e48
Last active Jul 6, 2022
C# structures to implement "Aero Glass" blur on Windows 10
View gist:fd6525579d6bbafc6e48
[DllImport("user32.dll")]
internal static extern int SetWindowCompositionAttribute(IntPtr hwnd, ref WindowCompositionAttributeData data);
[StructLayout(LayoutKind.Sequential)]
internal struct WindowCompositionAttributeData
{
public WindowCompositionAttribute Attribute;
public IntPtr Data;
public int SizeOfData;
}
@riverar
riverar / gist:53c2d7293c15e1acc7d7
Created Jul 8, 2015
Contrived C#/WPF example implementing "Aero Glass" blur on Windows 10
View gist:53c2d7293c15e1acc7d7
internal void EnableBlur()
{
var windowHelper = new WindowInteropHelper(this);
var accent = new AccentPolicy();
var accentStructSize = Marshal.SizeOf(accent);
accent.AccentState = AccentState.ACCENT_ENABLE_BLURBEHIND;
var accentPtr = Marshal.AllocHGlobal(accentStructSize);
Marshal.StructureToPtr(accent, accentPtr, false);
@riverar
riverar / skype.js
Created Jul 26, 2015
My first Frida script to fix up Skype's ShellExecuteExW usage
View skype.js
var g_openVerbString = Memory.allocUtf16String("open");
var fn = Module.findExportByName("shell32.dll", "ShellExecuteExW");
Interceptor.attach(fn, {
onEnter: function(args) {
// Right now, SHELLEXECUTEINFO presumably looks like:
// ...
// lpVerb = nullptr
// lpFile = RUNDLL32.EXE
@riverar
riverar / made_by_you_display_scaling.html
Created Jan 8, 2016
Made by you - Display Scaling in Windows 10
View made_by_you_display_scaling.html
<p>Today we are introducing a new series of articles titled ‘Made by you’. If you have feedback on this type of content or other aspects of the Windows Insider Program, please let us know via the <a href="windows-feedback:?contextid=529" target="_blank">Feedback App</a>.&nbsp;&nbsp;</p>
<p>‘Made by you’ highlights how we are addressing feedback from Windows Insiders, how we investigated this feedback to shape Windows, and why we have made&nbsp;these improvements.</p>
<h3>Overview/Introduction </h3>
<p>Windows 10 is an important release for Windows display scaling. It implements a unified approach to display scaling across all SKUs and devices aimed at these goals: </p>
<ol>
<li>Our end users enjoy a mix of UWP and classic desktop applications on desktop SKUs which reliably provide content at a consistent size </li>
@riverar
riverar / inside_wdg_1.html
Last active Feb 10, 2016
Inside WDG - Branches and Rings
View inside_wdg_1.html
<h1>Inside WDG - Branches and Rings</h1>
<p>Today, we’re kicking off a new series of articles we’ll publish regularly to Insider Hub called Inside WDG. WDG is short for the Windows and Devices Group which is the group at Microsoft responsible for Windows as well as Microsoft’s devices such as Surface, Xbox, Lumia, and Band. And with Inside WDG, we want to give Insiders a behind-the-scenes look at how we’re building Windows. It will also give us the opportunity go into greater detail on specific topics that we know are of interest to Insiders. For our first Inside WDG article, we’re going to talk about our Windows branches and rings.</p>
<p>Throughout Windows 10 development and over the past year of the Windows Insider Program, we have evolved how we develop and release Windows. We have learned a lot from our Windows Insiders and customers and have made significant improvements to our product and the tools we use to develop them. Therefore, we would like to take the time to give Windows Insiders some backgrou
@riverar
riverar / inside_wdg_localization.html
Created Apr 4, 2016
Inside WDG - Localization Process
View inside_wdg_localization.html
<p>Hello Windows Insiders!</p>
<p>My name is Miki Albertson and I’m a Program Manager from Windows Localization team. Today I would like to give you a behind-the-scenes look at how WDG products are made available to Windows Insiders in their language. By the way, we call this process “Localization”.</p>
<p>If you have ever wondered about how our products are made available in your markets and in your language, please read on!"</p>
<p>This is a simplified view, but it will give you an overview into main aspects of Localization process.</p>
<p>Each process is explained in detail below. </p>
@riverar
riverar / made_by_you_cortana.html
Created Apr 8, 2016
Made by You - Cortana listens to your feedback!
View made_by_you_cortana.html
<h3>Introduction </h3>
<p>Cortana is really smart, but she isn’t perfect. Cortana does automatically get better, so just using Cortana is a great way to help. In fact, the more you use Cortana the better she gets for everybody. But your feedback is absolutely critical. Feedback helps us identify issues and focus attention to the most urgent needs.</p>
<p>In this article, we’ll show you how to give feedback about Cortana, what we do every day with that critical feedback, and provide real examples where feedback has impacted changes to Cortana.</p>
<h3>Cortana Feedback (How it works and what we do with it) </h3>
<p>One of the key sources of feedback comes from within the Cortana experience. You can provide ideas, likes and dislikes to our team. Each report is recorded by our system, including a screenshot (if you allow), as well as few key details such as the Windows language used. </p>
@riverar
riverar / dummy.exe.manifest
Created May 30, 2016
Long Path Aware sample manifest
View dummy.exe.manifest
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" >
<asmv3:application>
<asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2016/WindowsSettings">
<longPathAware>true</longPathAware>
</asmv3:windowsSettings>
</asmv3:application>
</assembly>