Edgewall Software
Modify

Opened 10 years ago

Closed 10 years ago

Last modified 9 years ago

#10521 closed defect (worksforme)

Network file links not working on wiki

Reported by: bhockley@… Owned by:
Priority: normal Milestone:
Component: wiki system Version: 0.12.2
Severity: normal Keywords:
Cc: franz.mayer@… Branch:
Release Notes:
API Changes:
Internal Changes:

Description

After the upgrade from Trac 0.11 to 0.12 wiki links pointing to network file shares are no longer working in Firefox and Chrome. The links are displayed on the page, with correct HTML that works outside of the trac page, but is unresponsive when clicked on.

This error occurs on our main and test trac deployments, and with multiple client computers.

Installed plugins:

  • Test Management
  • Account Manager
  • Sub tickers
  • RPC XML
  • Wiki print

Attachments (0)

Change History (6)

comment:1 by osimons, 10 years ago

Resolution: worksforme
Status: newclosed

See new-ish setting for [wiki] safe_schemes - wiki:TracIni#wiki-section. If you check your trac.ini.sample file, you should find the current defaults for this setting:

[wiki]
safe_schemes = cvs,file,ftp,git,irc,http,https,news,sftp,smb,ssh,svn,svn+ssh

You don't actually say what your links look like, but I suppose adding your schema to the list should solve it for you. Please reopen ticket if you think it is another issue.

comment:2 by framay <franz.mayer@…>, 10 years ago

I am facing the same problem. When defining a link like [file:///N:\path\to\folder linkname] (where N is the network share name in Windows) the link is printed correctly. But when clicking on it, nothing happens (tested on Firefox 9.0.1, Chrome 16.0.912.75 and IE 9). When I copy the link and paste it in the browser URL bar it works fine.

Option safe_schemes is set to cvs,file,ftp,git,irc,http,https,news,sftp,smb,ssh,svn,svn+ssh

We are using Trac 0.13dev-r10854 with a bunch of plugins: Attachment-Policy-Plugin, Budgeting-Plugin, CKIntegration, Gefasoft-ODFReport, ProjectPlugin, Roadmap-Plugin, SettingsPlugin, TicketDisplay, TracAccountManager, XMailPlugin

Is it a browser or security issue?

comment:3 by framay <franz.mayer@…>, 10 years ago

Cc: franz.mayer@… added
Resolution: worksforme
Status: closedreopened

I did some more testing. This link [file://///servername/sub/path\to\folder linkname] isn't working either (N: represents \\servername\sub on windows, so it's just a substitute).

Though, when I paste following HTML in a static HTML file on a different server the link works:

<a href="file:///N:\path\to\folder" class="ext-link">
<span class="icon">&#8203;</span>
linkname</a>

Though, when I paste it on a web server in a dynamic web page it doesn't work.

in reply to:  3 comment:4 by Christian Boos, 10 years ago

Resolution: worksforme
Status: reopenedclosed

Replying to framay <franz.mayer@…>:

I did some more testing. This link [file://///servername/sub/path\to\folder linkname] isn't working either (N: represents \\servername\sub on windows, so it's just a substitute).

That's another problem: file:/// links only work directly "out of the box" in IE (see http://trac-hacks.org/wiki/WikiGoodiesPlugin#MoreaboutUNCpathsupport for more info)

comment:5 by bhockley@…, 10 years ago

My apologies for forgetting the link formats. I updated trac.ini to include the safe_schemes from the sample ini file.

wiki: Technical Design

generated html:

<p>
See <a class="ext-link" href="file:////server/Company/Projects/POP123 - Enhancements/Technical/Design/Product Editor"><span class="icon"> </span>Technical Design</a>
</p>

I'm just not getting how the page source shows a perfectly legit link, but just doesn't respond when clicked. Yet if I save the page and load a local copy it works fine.

Browsers:

  • Chrome 16.0.912.75 m
  • Firefox 7.0.1
  • IE 9.0.8112.16421
Last edited 10 years ago by Thijs Triemstra (previous) (diff)

in reply to:  5 comment:6 by framay <franz.mayer@…>, 10 years ago

Replying to bhockley@…:

I'm just not getting how the page source shows a perfectly legit link, but just doesn't respond when clicked. Yet if I save the page and load a local copy it works fine.

It's not a bug, it's a (security) feature, see stackoverflow entry; see stackoverflow for possible workarounds.

Btw: Jira is facing the same problem, see JIRA Knowledge Base.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The ticket will remain with no owner.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from (none) to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.