{"id":7303,"date":"2021-01-17T20:34:29","date_gmt":"2021-01-17T11:34:29","guid":{"rendered":"http:\/\/weblog.okumura.com\/?p=7303"},"modified":"2021-01-17T20:34:29","modified_gmt":"2021-01-17T11:34:29","slug":"sun-jan-17-2021-make-holux-eztour-usable-even-after-holuxs-failure","status":"publish","type":"post","link":"https:\/\/weblog.okumura.com\/?p=7303","title":{"rendered":"Sun. Jan. 17, 2021 Make HOLUX ezTour usable, even after HOLUX&#8217;s failure"},"content":{"rendered":"\n<p>This entry is English translation of essense of my Japanese entry titled &#8220;2020\/12\/10(\u6728) HOLUX ezTour \u3092\u5fa9\u6d3b\u3055\u305b\u308b\u2026&#8221;<br><br>After HOLUX had been bankrupted, HOLUX m-241 (and m-241Plu)&#8217;s logger software ezTour stop showing Google Maps properly. I tried to restore this.<\/p>\n\n\n\n<p>ezTour uses Google Maps API key: &#8220;AIzaSyBuAcOB_vBhIk5EcBGT4zMQ8NNPh7ORKjA&#8221;. Of course HOLUX had been paying for this key, but after HOLUX&#8217;s failure, they stop paying and Google stop Maps API service to this key, so that ezTour is no longer able to show Google Maps.<\/p>\n\n\n\n<p>I start looking ezTour exe binary by use of a binary editor tool (I used Stirling), and found that the API key shown above in UTF-16 format. Google Maps API key can be obtained by anyone. I got mine and replace the API key in the binary file by the binary editor.<\/p>\n\n\n\n<p>The API key is tied to accessing domain name. The domain ezTour using to access Google Maps is holux.com, so I need to modify the URL part which can be found in the binary in UTF-16 format as well.<\/p>\n\n\n\n<p>One of the original URL part is &#8220;<a rel=\"noreferrer noopener\" href=\"http:\/\/gomap.holux.com\/uploadhtmlfile.php\" target=\"_blank\">http:\/\/gomap.holux.com\/uploadhtmlfile.php<\/a>&#8220;. This is hard coded in the ezTour binary. As I don&#8217;t own holux.com domain, so I need to replace this URL with my own domain. I used the binary editor again to replace this URL. I found a few other URL&#8217;s and replace domain part of all of them.<\/p>\n\n\n\n<p>Actually, my own domain is bit longer than holux.com, so I need to shorten the rest part of URL like, modify &#8220;uploadhtmlfile.php&#8221; to &#8220;updhtml.php&#8221;, so that the total length of accessing URL isn&#8217;t changed.<\/p>\n\n\n\n<p>I can&#8217;t see the actual script of uploadhtmlfile.php, but I can assume that it saves the received content to the file named after [proj_id] query string with &#8220;.html&#8221; extension. So I created a PHP script as below. (My server&#8217;s document root is  \/volume1\/web\/ and you need to modify that part to actual document root of your web server if you use this script.)<\/p>\n\n\n\n<blockquote class=\"wp-block-quote\"><p>&lt;?php<br>\/\/ ezTour uploader (emulated)<br>\/\/ Fri. Oct. 04, 2019 by Hirotoshi OKUMURA<\/p><p>$uploaddir = \u2018\/volume1\/web\/ezToolD\/TGV\/ezTour\/\u2019; \/\/ need to be changed for actual path for that web server\u2019s document root<br>$uploadfile = $uploaddir . basename($_POST[\u2018proj_id\u2019]) . \u2018.html\u2019;<\/p><p>echo \u2018&lt;pre&gt;\u2019;<br>if (move_uploaded_file($_FILES[\u2018file\u2019][\u2018tmp_name\u2019], $uploadfile)) {<br>echo \u201cFile uploaded.\\n\u201d;<br>} else {<br>echo \u201cError on move_uploaded_file()\\n\u201d;<br>}<\/p><p>&gt;<\/p><cite>updhtml.php<\/cite><\/blockquote>\n\n\n\n<p><\/p>\n\n\n\n<p>In my tweet below, you can see the screen shot of working ezTour even after the date of HOLUX failure.<\/p>\n\n\n\n<blockquote class=\"twitter-tweet\"><p lang=\"ja\" dir=\"ltr\">2019\/09\/14(\u571f) \u306b\u3064\u3076\u3084\u3044\u305f <a href=\"https:\/\/twitter.com\/hashtag\/HOLUX?src=hash&amp;ref_src=twsrc%5Etfw\">#HOLUX<\/a> <a href=\"https:\/\/twitter.com\/hashtag\/m241?src=hash&amp;ref_src=twsrc%5Etfw\">#m241<\/a> <a href=\"https:\/\/twitter.com\/hashtag\/m241Plus?src=hash&amp;ref_src=twsrc%5Etfw\">#m241Plus<\/a> \u7528 <a href=\"https:\/\/twitter.com\/hashtag\/ezTour?src=hash&amp;ref_src=twsrc%5Etfw\">#ezTour<\/a> \u306e\u5fa9\u6d3b\u65b9\u6cd5\u5b9f\u65bd\u5f8c\u3082\u3001<br><br>You must enable Billing on the Google Cloud Project at <a href=\"https:\/\/t.co\/xT21Dz9jKT\">https:\/\/t.co\/xT21Dz9jKT<\/a><br><br>\u3068\u3044\u3046\u30a8\u30e9\u30fc\u304c\u51fa\u308b\u3088\u3046\u306b\u306a\u3063\u3066\u3057\u307e\u3063\u305f\u304c\u3001\u3055\u3089\u306b\u8272\u3005\u5909\u66f4\u3057\u3066\u3001ezTour \u3092\u5fa9\u6d3b\u3055\u305b\u305f\u3002\u3053\u3061\u3089\u304c\u5fa9\u6d3b\u5f8c\u306e\u753b\u9762\u3067\u3059\u3002 <a href=\"https:\/\/t.co\/HermTvxXdN\">pic.twitter.com\/HermTvxXdN<\/a><\/p>&mdash; Hirotoshi Okumura (@okumura1967) <a href=\"https:\/\/twitter.com\/okumura1967\/status\/1180128933078953989?ref_src=twsrc%5Etfw\">October 4, 2019<\/a><\/blockquote> <script async src=\"https:\/\/platform.twitter.com\/widgets.js\" charset=\"utf-8\"><\/script>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>This entry is English translation of essense of my Japanese entry titled &#8220;2020\/12\/10(\u6728) HOLUX ezTour \u3092\u5fa9\u6d3b&hellip; <\/p>\n<p><a class=\"moretag\" href=\"https:\/\/weblog.okumura.com\/?p=7303\">\u5168\u6587\u3092\u8aad\u3080<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[10],"tags":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=\/wp\/v2\/posts\/7303"}],"collection":[{"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=7303"}],"version-history":[{"count":5,"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=\/wp\/v2\/posts\/7303\/revisions"}],"predecessor-version":[{"id":7308,"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=\/wp\/v2\/posts\/7303\/revisions\/7308"}],"wp:attachment":[{"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=7303"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=7303"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/weblog.okumura.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=7303"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}