Forum Discussion
Jorge_Cabanilla
Nimbostratus
Jul 08, 2010Send a binary file as content in http:response, I need help
Hi,
Some one knows how to send a binary file as content in an HTTP:respond?
Is it possible to assign a file to a variable?
How to read a file?
I need the next:
set ::my_variable
Then in the http:response assign it as follows:
HTTP::respond 200 content $my_variable
Thanks
- hoolio
Cirrostratus
Hi Jorge, - hoolio
Cirrostratus
dupe - Hamish
Cirrocumulus
You have 2 choices. - Jorge_Cabanilla
Nimbostratus
The file that I need to send as content is already encoded as wbxml, Does the LTM has that type of encryption? - Jorge_Cabanilla
Nimbostratus
I tested it using the class external file, but my file is a wbxml type, so in order to retrieve the content I'm using the next command - hoolio
Cirrostratus
Regardless of what content is being sent, you can base64 encode it when you add it to the LTM configuration and then base64 decode it using b64decode. - Jorge_Cabanilla
Nimbostratus
Yes it works using the b64 encryption method and a class . With version 9.4.7 the b64encode command is not available, anyway this is what I did: - Jorge_Cabanilla
Nimbostratus
Yes it works using the b64 encryption method and a class . With version 9.4.7 the b64encode command is not available, anyway this is what I did:
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects