Legal considerations around the U.S. Patent No. 5,838,906, currently held by infamous Eolas company for the single purpose of "defending" it, forces Opera to abstain from implementing any measures that could be interpreted as ”invoking external application providing interaction and display of embedded objects“.
Therefore the user of Opera has to take the burden to ”click-to-activate“ a Flash applet in a web page first, before he is able to use it and interact with it.
This ”click-to-activate“-hassle can be removed individually by an Opera-user on his end (and in his own responsibility!) by patching the Opera binary code.
…
This is first and foremost the result of research done by Rafal aka d.i.z., who was probably the first to distribute an easy to apply patch that was generic in such a way, that you could apply it to various versions (builds) of Opera 9 thru 10. Please read his interesting report on his studies in his blog.
New builds of Opera arrived and the patch stopped working, as the binaries had changed too much. You could introduce new patch patterns into the Rafal's patchscript, but the script got more and more confusing. Thus I re-structured the script to make it easier to introduce new patch patterns into it.
The Patch
You find the more-or-less-carefree all inclusive package, consisting of a patch appliance batch-script for Windows (and 4NT/TakeCommand/TCC), the upx un-/packer and a rudimentary perl binary distribution as helper tools, and a (probably outdated) patchscript as a download here:
The standalone perl patchscript is behind the following link. It is possibly a more recent version than the one embedded in the all inclusive package; you can use this standalone script to update your install of the all inclusive package:
Installation and Usage
Perhaps you need admin-credentials to perform some or all of the following steps!
-
Option A → post-installation patch of opera.dll in Opera's program folder
Extract the all inclusive pack into Opera's binary installation folder (ie probably ”%PROGRAMFILES%\opera\“ on Windows systems). The standalone perl script should be placed into that folder as well.
Now make sure, Opera is not currently running! If it is, though, shut it down and wait long enough for the (sometimes painfully slow) shut down sequence to finish.
To apply the patch you either double click the xa-nocta.bat batch script in the Explorer or you start it from the console. If you prefer to solely use the perl patch script (and do the eventual unpacking and backing up parts yourself), run something like ”perl xa-nocta.pl opera.dll“ from a console command line.
-
Option B → pre-installation patch of Opera's installer (v11+)
For Opera 11+ there is another means to apply the patch being tested. Drag and drop the NewInstaller 7Ziped executable onto the batch script called xa-nocta-the_installer.bat or call that script from the command line passing the path to the installer as an argument. The script will extract the opera.dll binary, apply the patch to it and re-implant it to a copy of the installer. All what's left to do is installing Opera using that modified installer (it will carry a suffix _xanocta) – no need to shut down Opera after the forced (installer-induced) start in order to apply the xaNoCTA patch no more. ☺
Notes
Applying any patch, including the patches included in this package, may or may not be legal, may or may not work. You do it in your very own responsibility. You won't hold anyone responsible for any mishap or disaster than you very self!
This following copyright and license should apply to the files making up the xa-nocta-package, as far as applicable and as far as not contradicting any other existing rights covering those:
Copyright © by XA, 2010-2012. Licensed under a Creative Commons by-nc-sa 3.0 Unported License.
Works (including, but not limited to, new patch byte patterns) that merely extend or make use of the Package, do not, by themselves, cause the Package to be a Derivative. In addition, such works are not considered parts of the Package itself, and are not subject to the terms of the granted license. As far as applicable, the included patch byte patterns shall be considered licensed under a Creative Commons CC0 1.0 Universal license.
Based on work by Rafal / d.i.z and multiple contributors on the MyOpera forums.
Creating plugins
Have a look at the sample plugin xa-nocta-plugin-00-SilentHTTPSUserJS.pl.txt, included in the Zip-Package, to get a clue. 😉 xaNoCTA scans automatically for plugins, finding them stored in the same folder as the main script and matching the filename pattern xa-nocta-plugin-*.pl; that means, you'll have to rename the sample plugins distributed in the all-inclusive-package, changing the double extension .pl.txt into a simple single .pl!
Creating new patch patterns
Besides on this page here, you can find the latest source in a Mercurial repository at Bitbucket.
Look into the xa-nocta.pl patch script. Between lines of ”###…##“ you find the array describing all the implemented possible patches. This is pretty self explanatory. (There is a priority scheme implemented, thus the patches are organized in a two-level-array structure. This is not used up to now.) A patch is resembled by an instruction record like
{
desc => 'Opera 11.00 [1045, 1060]',
assert => undef,
test => qr/\x66\xBA\x2C\x00\xE8(.{4})\xF7\xD8\x1B\xC0\xB0\x01/s,
match => qr/\x66\xBA\x2C\x00\xE8(.{4})\xF7\xD8\x1B\xC0\xF7\xD8/s,
replace => '"\x66\xBA\x2C\x00\xE8$1\xF7\xD8\x1B\xC0\xB0\x01"'
},
Pay attention to the right use of quotes in the replace part!
If your patch applies to an yet unsupported version of Opera – and if it works well, then feel free to post the patch instruction record (like the example above) in the comments to this posting! ☺
Latest Changes
- 2012-08-10
- Support 12.01 32bit build 1532, 12.50 32bit builds 1538,1546.
- Use the /s modifier on RegExps to treat patterns as single line, even if containing some newline char. [Ralf Onat is right, thanks!]
- 2012-07-27
- Support 12.00 32bit builds 1439,1440,1441,1445,1448,1450,1454,1456,1465,1467, 12.01 32bit builds 1473,1486,1491,1517,1520,1528, 12.50 32bit builds 1497,1513.
- 2012-05-30
- New patch strategy (patched params to subroutine have been swapped) supporting 12.00 32bit builds 1359,1360,1372,1380,1383,1385,1386,1387,1406,1413,1417,1422,1424,1429,1431,1433,1438.
- Support 12.00 build 1301,1306,1312,1317,1325,1328,1351_32bit.
- 2012-02-10
- Support 11.61 build 1250, 11.62 builds 1273,1297, 12.00 builds 1256,1272,1289.
- Incorporate modification to certain patch pattern to cover 12.00 build 1301 – contributed by BtEO.
- 2012-01-16
- Included another sample plugin (contributed by BtEO and Nibiru); it should patch away the host name highlightning in the address bar.
- Renamed ”Silent UJS HTTPS“ sample plugin file.
- Support 11.61 builds 1222,1234,1236, 12.00 1232labs.
- 2011-12-22
- Support 11.61 build 1222.
- Relaxed matching for ”Silent UJS HTTPS“ sample plugin.
- 2011-12-22
- Embraced contribution by BtEO for a unified patch pattern supporting Opera 12.00 builds 1085,1090,1105,1116,1155,1174,1191,1211,1213], 11.60 builds 1134,1139,1144,1145,1147,1150,1159,1163,1169,1173,1177,1178,1180,1181,1184,1185.
- Plugin functionality (from pluggable branch) merged into default branch.
- 2011-10-13
- Supports 12.00 build 1085,1090;1105.
- Modified new 1085/1090-patch-strategy to embrace 1105.
- 2011-10-07
- New patch strategy introduced to support patching Ragnarök-based 12.00 build.
- 2011-09-28
- Supports 11.51 builds 1084,1087, 12.00 builds 1017,1020,1027,1033,1039,1042,1047;1054,1060,1065,1076.
- 2011-06-21
- Adapted latest patch pattern to cover build 1052 of Opera 11.50.
- Support 11.50 builds 1040,1049;1052.
- 2011-06-10
- Incorporated new patch strategy for builds of later trait of Opera 11.50.
- Supports 11.50 builds 1024,1027,1031,1035,1036,1037.
- 2011-05-27
- Supports 11.50 builds 1009,1015,1016,1018,1020.
- 2011-05-18
- Supports 11.10 builds 2090,2091,2092 final, 11.11 build 2109 final.
- 2011-04-11
- Supports 11.10 builds 2005,2014,2018,2020,2025,2033,2039,2040,2042,2045,2047,2048,2053,2064,2067,2076,2077,2079,2081,2085,2087.
- 2011-01-26
- Supports 11.00 builds 1164,1169,1175,1179,1189,1190.
- 2011-01-07
- Supports 11.00 build 1160.
- Corrected behavior in case no patch matches.
- 2010-12-17
- Fixes to xa-nocta-the_installer script.
- Now includes full working copy of 7Zip in all inclusive pack. But that's a lot of bytes. Maybe it'd be better to instruct potential users to get 7Zip elsewhere.
- 2010-12-16
- New auxiliary script allows patching opera.dll virtually in the new Opera 11+ installer prior to the actual installation procedure.
- 2010-12-14
- Supports 11.00 build 1104,1111,1128,1133,1136,1140,1145,1149.
- 2010-11-17
- Supports 11.00 build 1094. Cosmetic changes and one MS compatibility fix to batch script.
- 2010-11-15
- Supports 11.00 build 1085.
- 2010-11-14
- Treated MS cmd compatibility issues in wrapper batch script (which is essentially for 4NT/TC).
- 2010-11-11
- Supports 11.00 build 1060. Add license info for the tools packaged into the happy-pack.
- 2010-11-06
- Supports 11.00 build 1055.
- 2010-11-05
- Sorted out oddities in the naming of original, backup and patched files.
- 2010-11-05
- Implemented possibility of an assertion guard for each patch class and/or patch method. If defined, the assert pattern has to match before applying a patch is considered.
- 2010-11-03
- Initial release covering Opera versions 9.x, 10.x, some 10.50 builds, 11.00 builds 1029 and 1045
Originally posted by XAntares:Same here. Btw, it would be nice if the “UserJS warning when used on HTTPS” and “No Addressbar host highlighting” plugins worked on Opera 11.60 Build 1145.Well,this patch about “UserJS warning when used on HTTPS” now could not work on Opera 11.60 beta(build 1147).
Same here. Btw, it would be nice if the “UserJS warning when used on HTTPS” and “No Addressbar host highlighting” plugins worked on Opera 11.60 Build 1145.
Works here. Thanks!
Attempt to patch 11.60 builds 1144,1145 can be checked out from the Bitbucket repository.I already – perhaps overhastily :ko: – uploaded the standard xa-nocta.pl and package as well as the _pluggable pack.
I can also confirm your problem since xa-nocta.bat isn’t working for me.
Something changed betwee 11.60 build 1144 and 1145. xa-nocta-the_installer.bat worked for 1144, but it’s not finding anything in 1145.
So, has anyone managed to get the “No Addressbar host highlighting” plugin to work?
i love often updates.great job!
I have no experience in writing Perl, but I’ll give it a try these few days (your example should be enough for me to start with). Thanks a lot.
Yes, it was ment more like a template or hint than a working solution. The pattern would have to be refined (as searching for a first xDDx05 would be way too coarse an approach).
That plugin script doesn’t work in Opera 12 Alpha (Build 1105).
Maybe you want to use and maintain a NoCTA-plugin?E.g.
#!/usr/bin/perl -w
# xa-nocta — XA No-Click-To-Activate patchscript v1.5.0 / 2011-10-19
#
# Portions copyright (C) by XA, VI 2011 – X 2011.
# Licensed under a Creative Commons CC-by-nd-sa 3.0 Unported license.
# Works (including, but not limited to, new patch byte patterns) that merely
# extend or make use of the Package, do not, by themselves, cause the Package
# to be a Derivative. In addition, such works are not considered parts of the
# Package itself, and are not subject to the terms of the granted license.
# As far as applicable, the included patch byte patterns shall be considered
# licensed under a Creative Commons CC0 1.0 Universal license.
#
# Based on work by Nibiru on the operafan.net forum.
# http://operafan.net/forum/index.php?topic=17407.0
push @main::PATCH_INFO,
{
desc => ‘No Addressbar host highlightning’,
assert => undef,
test => undef,
match => qr/./,
replace => undef,
patchset => [
{
# No Addressbar host highlightning patch by Nibiru
# contributors: Nibiru, XA
desc => ‘Method 1 Opera 11.x, Opera 12.00’,
assert => undef,
test => qr/xD9x05.{4}(?:xD9xBC|x8Bx54)x24/,
match => qr/xDDx05(.{4})(xD9xBC|x8Bx54)x24/,
replace => ‘”xD9x05$1$2×24″‘
},
]
}
;
1;
Как-то так…Внимание! Did not test at all!___Edited on 2011-10-20
That’s very nice, thank you!That reminds me of an Opera.dll hack I saw before on Opera 11, which disables the URL highlighting feature.http://operafan.net/forum/index.php?topic=17407.0Related discussion: http://my.opera.com/community/forums/topic.dml?id=385751&abc=&page=4&skip=150&show=&perscreen=50It was actually a bit disheartening for me to see the best browser, once known for customizability, had to resort to such method to do something fairly simple. It’s not a good time for picky people like me =(
Just bookmark ss64.com for future reference.
Thanks a lot.I vaguely remembered once having stumbled across a way to set DelayedExpansion on the fly — but just didn’t find it any more (and didn’t google enough, apparently ;)).I’ll incorporate your suggestion.… Did I tell already, I don’t like CMD? ^^
When testing for delayed variable expansion you need to move the code for the -donotrecurse check into a label. If %~f0 expands to a path with brackets in (e.g. Program Files (x86)) the script dies at that point because the if block is closed early.Example (you’d probably need to modify the installer patcher too.)Or you could just avoid the whole mess altogether and add SetLocal EnableDelayedExpansion to the top of the script :P; I think it needs to be a separate command from the existing SetLocal.
Thanks for adding support for it.
Latest version does. ;)Updated perl script, .zip package and _pluggable test version.
It doesn’t work on Opera 12 Alpha (Build 1105).
There is a brand new version of the ”pluggable“ branch out, get (and test) it while it’s fresh: 😉
»» xa-nocta_pluggable.zip
Supports 12.00 build 1090.
Plugins can now be passed to xanocta.pl via -P options avoiding CORE::glob dependency in Perl.
xanocta.pl can still scan by itself, given CORE::glob availability and option -p.
Settled for Perl 5.12 to be packed into the all-inclusive-package.
Implemented scan for plugins in batch wrappers; this involves a hack for stupid CMD. CMD needs a feature called “delayed variable expansion” (/V:ON) to support my approach of collecting plugin names. Most folks probably won’t have it enabled in their standard CMDs. So I perform some wizardry to check for the feature, and re-launch the batch file from a feature-enabled second CMD process, if necessary. – Use JP-Soft’s TCC / 4NT and life becomes easy. 😉
Updated anti UserJS-on-HTTPS warning plugin with contributions by BtEO (thanks, well done!).
The Mercurial repository on Bitbucket may give you details on the changes.
Success!xa-nocta-plugin-00.plAnd just for fun, an insight into how I fumbled my way to a result.
Originally posted by XenoAntares:A sample plugin patching away the UserJS-on-HTTPS warning (courtesy of Dither) is included. Please give it a try (and give me feedback)!»» xa-nocta_pluggable.zipDang, this is going to annoy me. The UserJS patch doesn’t work for me with 12.00 [1090].I’m going to try and find a fix, but my experience with such things is extraordinarily limited.
So long, get the prepared xaNoCTA files from Bitbucket.
{
# contributors: XA
desc => ‘Opera 12.00 [1085]’,
assert => undef,
test => qr/x6Ax17x6Ax00x6Ax01xBFxA0x02x00x00xE8(.{4})xF7xD8x1BxC0xB0x01x5FxC2x04x00/,
match => qr/x6Ax17x6Ax00x6Ax01xBFxA0x02x00x00xE8(.{4})xF7xD8x1BxC0xF7xD8x5FxC2x04x00/,
replace => ‘”x6Ax17x6Ax00x6Ax01xBFxA0x02x00x00xE8$1xF7xD8x1BxC0xB0x01x5FxC2x04x00″‘
},
would be the respective patch record in xa-noCTA format.
Changing @6781DAA8
8B 4C 24 04 57 6A 17 6A 00 6A 01 BF A0 02 00 00
E8 03 D3 B2 FF F7 D8 1B C0 F7 D8 5F C2 04 00
to
8B 4C 24 04 57 6A 17 6A 00 6A 01 BF A0 02 00 00
E8 03 D3 B2 FF F7 D8 1B C0 B0 01 5F C2 04 00
works for me right now.
That is
Address dump Command
6781DAA8 8B4C24 04 mov ecx,[dword ss:arg1]
6781DAAC 57 push edi
6781DAAD 6A 17 push 17
6781DAAF 6A 00 push 0
6781DAB1 6A 01 push 1
6781DAB3 BF A0020000 mov edi,2A0
6781DAB8 E8 03D3B2FF call Opera_dll.6734ADC0
6781DABD F7D8 neg eax
6781DABF 1BC0 sbb eax,eax
-6781DAC1 F7D8 neg eax
+6781DAC1 B0 01 mov al,1
6781DAC3 5F pop edi
6781DAC4 C2 0400 retn 4
Feedback?
doesn’t work on 12.00-1085
this is great!
xa-nocta.zip patch for opera.dll works for me in 11.51 release version.
Opera Version11.51Build1087@67415F3Fchange it so it jumps always seems to work. Did anyone get old fix to work?
Thanks for the report, @Shaffle. I’ll investigate.
This patch is a really great idea! I’m testing your xa-nocta_pluggable, and I have the following error twice :Use of uninitialized value in pattern match (m//) at xa-nocta.pl line 134.Code :134 : if (!$patchclass->{match} || ($buf =~ m/$patchclass->{match}/) ) {
Thanks for the sample plugin. The last time I found out someone (d.i.z.) had made a patch for that it had already broken in the latest version and he’d started working for Opera, compromising his ability to generate patches like that.
Originally posted by Sac:I tried this and it worked like a charm, now YouTube works great (although I hate the fact that their new player hides the video controls automatically)… So, it’s necessary to re-patch every time Opera is upgraded, isn’t it? Yes, because every upgrade overwrites Opera.dll.
I tried this and it worked like a charm, now YouTube works great (although I hate the fact that their new player hides the video controls automatically)… So, it’s necessary to re-patch every time Opera is upgraded, isn’t it?
Re-packaged with Activestate Perl 5.6.1_635; previous pack wasn’t sufficient for folks without a MSYS installation.
»» xa-nocta_pluggable.zip [updated version below]
Note: Sample plugin does not work with new Opera 12.00 pre-alpha anymore.
Just to let people know that this xa-nocta.zip located above, that officially supports builds up to 1052 works fine with the latest official and final version 10.50 build 1072 build of Opera :PIn case you don’t know 😛
I cannot think of a way to make it even clearer, where to find the most recent versions, where possibly slightly older. 😉
Here is another thing to try out:
This version not only supports introducing arbitrary patches by editing the Perl script, but also makes use of simple plugins!
A sample plugin patching away the UserJS-on-HTTPS warning (courtesy of Dither) is included. Please give it a try (and give me feedback)!
»» xa-nocta_pluggable.zip [updated version below]
Note: As always you can use your own Perl installation, if you have one. For size reasons there is now a slightly archaic Perl version included, ie Perl 5.6.1 from the MSYS package. That is, because newer versions don’t come self-contained regarding glob – the Perl 5.12 formerly included in the all-inclusive-package will not as-is support this plugin-enabled version!
xa-nocta.pl is the new one.It should be noticed on this article in my opinion.
Which are the files that I need to download again? All of them?Thanks.
Works for me too.I also edited xa-nocta.bat file for better compression.
Originally posted by TheRockSays:Doesn’t work with Opera 11.50 final. Please help. This is God-send.Works for me…did you get the latest perl script?
Are you going by the build numbers posted at the top of the page? If so, don’t, since the latest build there just reflects the last time that the string location changed. It continues to work through build 1074.
Doesn’t work with Opera 11.50 final. Please help. This is God-send.
Wow, that’s what I call rapid application development! 🙂
Patch doesn’t work with today’s snapshot (1052). Worked with yesterday’s and before.
Right. Adapted patch already, works again. ,) You’ll find it now on BitBucket or rather soonish here.
Originally posted by rseiler:…[posting removed by author]Appreciate your comment. 😉 I don’t experience those mentioned phenomena, but others report plenty of crashes with build 1040 (and without noCTA) as well. So I agree, it’s probably a coincidence.
OK, I’m trying that slightly later location now instead of the one from yesterday.
Hey, what’s that all mean?Did you manage to get this thing working?Thanks