Opened 10 years ago

Closed 7 months ago

# scanning algorithm?

Reported by: Owned by: wadeb Committo-Ergo-Sum normal DoxygenPlugin normal security hole ttressieres 0.10

Hi, I'm having some trouble getting this plugin to work with more than one Doxygen directory - it keeps putting "html" in the wrong places.

My generated HTML files are in the following directories:

c:/tl/base/doc/html/*
c:/tl/ngl/doc/html/*
c:/tl/apk/doc/html/*
c:/tl/apk/tools/apkedit/doc/html/*


I set my root to c:/, and put the tag [doxygen:tl/ngl/doc] with html_out as html, and all I get are error pages.

Now, say I have a class apkString in apkedit, it would be great to be able to write [doxygen:apkString] and have the plugin just find it. Maybe support for multiple defaults would covert it.

Best regards,

Wade Brainerd Technical Directory Activision Central Technology

### comment:1 follow-up: ↓ 2 Changed 10 years ago by cboos

Just to be sure: you set the Trac Release to 0.9, are you using the 0.9 branch of the plugin? If so, double check the DoxygenPlugin documentation, the html_output is something new I added on the 0.10 branch.

I had the impression that support for multiple documentations was not working as it should in the 0.9 branch, therefore a lot of changes were made in the 0.10 branch, and the setup you described should work there, e.g.

[doxygen]
path = C:
default_documentation = tl/base/doc
wiki_index = DoxyGen
html_output = html


  * [doxygen:tl/base/doc/index base]
* [doxygen:tl/ngl/doc/index ngl]
* [doxygen:tl/apk/doc/index apk]
* [doxygen:tl/apk/tools/apkedit/doc/index apkedit]


Please tell me if the above works or not with 0.10, as it should. For 0.9, I'm afraid I won't be able to help...

Also, your suggestion of using multiple default documentations is interesting; I was about implementing it, but thought that maybe it would be confusing... now if other people are feeling like it would be an useful addition, I can do it.

### comment:2 in reply to: ↑ 1 ; follow-up: ↓ 3 Changed 10 years ago by wadeb

• Trac Release changed from 0.9 to 0.10

Just to be sure: you set the Trac Release to 0.9, are you using the 0.9 branch of the plugin? If so, double check the DoxygenPlugin documentation, the html_output is something new I added on the 0.10 branch.

You're right, I mis-flagged it as 0.9 when it should have been 0.10. Both my Trac install and DoxygenPlugin are the 0.10 versions.

I was able to get my DoxyGen wiki page to show links with this configuration:

[doxygen]
path = c:/
default_documentation = tl/ngl/doc
wiki_index = DoxyGen
html_output = html


and the following wiki index:

= Online Documentation =

* [doxygen:tl/base/doc/index Base Library Documentation] -- Documentation for the base library.
* [doxygen:tl/ngl/doc/index NGL Documentation] -- Documentation for the NGL Graphics library.
* [doxygen:tl/jobqueue/doc/index JobQueue Documentation] -- Documentation for the JobQueue data processing library.
* [doxygen:tl/apk/doc/index APK Documentation] -- Documentation for the APK runtime library.
* [doxygen:tl/apk/tools/apkedit/doc/index APKEdit Documentation] -- Documentation for the APKEdit tool library.


However, when I click the links that appear, I am redirected to this URL:

The requested URL /trac/doxygen/tl\ngl\doc\html/index.html was not found on this server. Apache/2.0.59 (Win32) mod_python/3.2.10 Python/2.4.3 Server at tltest.activision.com Port 80

Also, your suggestion of using multiple default documentations is interesting; I was about implementing it, but thought that maybe it would be confusing... now if other people are feeling like it would be an useful addition, I can do it.

I think it would be handy for people who have as many documentation roots as I do. Maybe default_documentation could take a comma separated list, or it could be expanded to a search_locations ini entry...

Thanks for the great plugin, btw!

### comment:3 in reply to: ↑ 2 ; follow-up: ↓ 4 Changed 10 years ago by cboos

• Status changed from new to assigned

... However, when I click the links that appear, I am redirected to this URL: http://tltest.activision.com/trac/doxygen/tl%5Cngl%5Cdoc%5Chtml/... and receive this error:

The requested URL /trac/doxygen/tl\ngl\doc\html/index...

Ugh, this is what you get when you develop on Linux... you tend to easily forget the distinction between os.path and posix.path :)

Thanks for the detailed report, I hope I'll find some time later today to fix this.

### comment:4 in reply to: ↑ 3 Changed 10 years ago by ttressieres

• Cc ttressieres added; anonymous removed

... However, when I click the links that appear, I am redirected to this URL: http://tltest.activision.com/trac/doxygen/tl%5Cngl%5Cdoc%5Chtml/... and receive this error:

The requested URL /trac/doxygen/tl\ngl\doc\html/index...

Ugh, this is what you get when you develop on Linux... you tend to easily forget the distinction between os.path and posix.path :)

Thanks for the detailed report, I hope I'll find some time later today to fix this.

There is another problem on Windows platform, you have to open the search.idx in binary mode: replace

fd = open(index)


with

fd = open(index, 'rb')


### comment:5 Changed 10 years ago by jeffk@…

I would like to add my 0x2c to this point... I was almost finished setting up doxygen plugin on my trac installation for my open source code at http://clicker.jdkoftinoff.com/projects/trac/jdks/

when I noticed that clicking on a [doxygen:libjdkwn/index] sent the browser to a url ending in: ....jdks/doxygen/libjdkwn/html/index.html?path=%2Fvar%2Fcache%2Fdoxygen%2Flibjdkwn%2Fhtml%2Findex.html

that really is a security hole. On your own trac/doxygen installation, try replacing ?path=.... with ?path=%2Fetc%2fpasswd .... or any other world readable file...

### Changed 10 years ago by ttressieres

some change to win32 port - use posixpath

### comment:6 Changed 7 months ago by Committo-Ergo-Sum

• Resolution set to fixed
• Status changed from assigned to closed

Versions > 0.11 fixes it.

Last edited 7 months ago by rjollos (previous) (diff)

### comment:7 Changed 7 months ago by rjollos

• Description modified (diff)
• Owner changed from cboos to Committo-Ergo-Sum