{"id":178,"date":"2014-10-08T06:21:00","date_gmt":"2014-10-08T06:21:00","guid":{"rendered":"http:\/\/tastaturkind.ch\/?p=178"},"modified":"2014-10-08T06:21:00","modified_gmt":"2014-10-08T06:21:00","slug":"178","status":"publish","type":"post","link":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/2014\/10\/08\/178\/","title":{"rendered":"Protocol Handler Launcher"},"content":{"rendered":"<p><code>; #########################################################################<\/p>\n<p>;   Launches a Program when registered as a Protocol Handler<br \/>\n;   The protocol is stripped from the argument (here hardcoded 7 digits \"abcdef:\")<\/p>\n<p>; #########################################################################<\/p>\n<p>      .386<br \/>\n      .model flat, stdcall  ; 32 bit memory model<br \/>\n      option casemap :none  ; case sensitive<\/p>\n<p>      include \\MASM32\\INCLUDE\\windows.inc<br \/>\n      include \\MASM32\\INCLUDE\\kernel32.inc<br \/>\n      include \\MASM32\\INCLUDE\\shell32.inc<br \/>\n      include \\MASM32\\INCLUDE\\masm32.inc<br \/>\n      include \\masm32\\macros\\macros.asm<\/p>\n<p>      includelib \\MASM32\\LIB\\kernel32.lib<br \/>\n      includelib \\MASM32\\LIB\\shell32.lib<br \/>\n      includelib \\MASM32\\LIB\\masm32.lib<\/p>\n<p>      Init  PROTO<br \/>\n; #########################################################################<\/p>\n<p>.data<br \/>\n    open     db \"open\",0<br \/>\n    dir      db 512 dup (0)  ; buffer for command line<br \/>\n    file     db 1024 dup (0) ; buffer for the file to open<br \/>\n    protocol db 64 dup (0)   ; buffer for the Protocol Handler part<\/p>\n<p>.code<\/p>\n<p>start:<\/p>\n<p>    invoke GetCL,1,ADDR dir<br \/>\n    invoke GetCL,2,ADDR file<\/p>\n<p>    mov edi, ptr$(protocol)  ; put pointer to protocol<br \/>\n    invoke ShellExecute,0,ADDR open,ADDR dir,ADDR file+7,NULL,SW_SHOW  ; strip calldw:<br \/>\n    invoke ExitProcess,eax<\/p>\n<p>end start<\/p>\n<p>; #########################################################################<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>; ######################################################################### ; Launches a Program when registered as a Protocol Handler ; The protocol is stripped from the argument (here hardcoded 7 digits &#8222;abcdef:&#8220;) ; ######################################################################### .386 .model flat, stdcall ; 32 bit memory model option casemap :none ; &hellip; <a href=\"https:\/\/oliver-frick.ch\/wordpress\/index.php\/2014\/10\/08\/178\/\">Weiterlesen <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-178","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/posts\/178","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/comments?post=178"}],"version-history":[{"count":0,"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/posts\/178\/revisions"}],"wp:attachment":[{"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/media?parent=178"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/categories?post=178"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/oliver-frick.ch\/wordpress\/index.php\/wp-json\/wp\/v2\/tags?post=178"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}