Monday, March 26, 2012

problem rendering a logo (external static image)

Hi,
I am having a problem rendering a logo, which is inside my asp.net
application, but first let me clear out what is exactly what I want to do and
what I have been able to do:
I am using soap access to render reports in our asp.net application, and it
works well (aside from a performance issue which I have not yet looked at).
The reports contain a logo, and it gets displayed pretty well. So basically,
everything is working.
The problem resides in that we wont be giving external access to Reporting
Services and the url of the images being displayed are pointing to reporting
services. I know there is a work around, since I could configure it as an
embedded image, and then use the render stream method of the web service. I
want to avoid doing so, since it is just a simple static image, which is
already rendered on the asp.net application. If I do so, I will have to deal
with creating temporary copies of it, and then deleting them (which I dont
know when to ... but that is another story).
So, the question is: is there a simple way to render the report in such a
way the image url the browser receive is that of the static file saved in our
asp.net application? if so, will exporting to other formats keep working
normally?I have been digging about the issue, and I dont seem to find any way to do
what I wanna do, in fact it seems that not being able to show external images
directly
from their source is by design ...
so, I am stuck with the normal routes ... I did find around in the boards,
how I can do it without ever writting the images to disk ... here, the post
before the last one
http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&threadm=uzmGLaeAEHA.3316%40TK2MSFTNGP11.phx.gbl&rnum=1&prev=/groups%3Fq%3Daspx%2Bimage%2Bgroup:*.reportingsvcs%2Bauthor:teo%26hl%3Den%26lr%3D%26ie%3DUTF-8%26scoring%3Dd%26selm%3DuzmGLaeAEHA.3316%2540TK2MSFTNGP11.phx.gbl%26rnum%3D1
In normal use of images it sounds pretty great, but I am concerned in my
case this might unnecesarily degrade performance (since I would be calling
the web service per image served, even if it is an already server image to
that client ... and it is a logo that appears on every page ... and the
report is showing all pages), even more than saving a copy of the static
image per client to the server, and then figuring out when to delete them
(and the way it is showed on the thread I posted above, doesnt help either
... because it assumes the image will get served once, and mine gets served
several times ...)
I would highly appreciate any lights in this, since I am in the dark ...
a couple comments:
to be honest, altough I undestand security implications I am not sure if it
solves the problem more than making devs lifes harder (I usually dont make
this type of comment :P :(:( ) ...
(*) One can render the report trough Soap access and get the images from rs,
then one is the server, in fact as long as u use the same generated id that u
get from the render call, u can even serve the image from a different
location (and setting the streamroot appropiately) ... in fact when using it
trough Soap access u can more easily mess with the reports itself (mess as
modify :P) ... this is a pretty good reason why restricting truly external
images when rendering in HTML trough soap access doesnt make any sense, it
isnt adding any degree of security ... in my opinion ...

No comments:

Post a Comment