Re: Handling MS "Internet Shortcuts" and "Links"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2015-05-01 16:00 GMT+02:00 David A. Cobb <superbiskit@xxxxxxx>:
[...]
> However, if I click the URL file in a "Directory List" served from Apache, I
> get the plain text file displayed.  I can go to the target with one or two
> extra steps, but it's a PITA.


It's a text file, so that's the expected result, since there are no special
handlers for .url-Files in httpd.

> It seems what I should do is to parse the file in the server and send a
> "Permanently Moved To" redirection to the browser.

I don't think you can achieve this with the likes of mod_rewrite, mod_setenvif
etc. It should require a proper program, e.g. via CGI, mod_perl
mod_php or the likes, plus probably a RewriteRule to start the script
whenever a .url file is requested. Or maybe mod_lua and a LuaOutputFilter.

> Or, I suppose, I could simply do the redirection; but somehow that feels less safe.

Not sure what you're trying to say here.

> Now, if I can be allowed a second question in the same post, can I do the
> same thing with Microsoft ".lnk" shortcuts?  It would be a simple script
> operation to transform the local FileSystem path to a "localhost:8080/"
> path.

That's actually not trivial in the general case, since it's not
necessarily obvious
how file system paths map to URLs.

rainer

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx





[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux