Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
  #1  
Old 12-09-2005, 10:15 AM
thalamus's Avatar
thalamus thalamus is offline
 
Join Date: Sep 2005
Location: UK
Posts: 66
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Text Obfuscate

I'm trying to find something that will allow me to add a set of bbcode tags (something like [safe]text here[/safe] which, although showing the text on the post, will basically encode the output on the searchable page to an 'encode64' result - this to avoid search engines etc from picking up on the "text here" and thereby adding a little security to what's posted.

I'm sure I saw this somewhere before and if anyone's done this I'd appreciate any info rather than having to reinvent the wheel. Please? TIA.
Reply With Quote
  #2  
Old 12-09-2005, 10:17 AM
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Location: Germany
Posts: 6,863
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How would users decode it?
Reply With Quote
  #3  
Old 12-09-2005, 10:30 AM
thalamus's Avatar
thalamus thalamus is offline
 
Join Date: Sep 2005
Location: UK
Posts: 66
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Automated, hopefully - simply, the user would post thus:

"I spoke to [safe]Andrew Smith[/safe] today and we were talking about...."

so the post itself would read:

"I spoke to Andrew Smith today and we were talking about..."

but the View Source on the html page itself would read:

"I spoke to gtYdhjdjijrh8aeh today and we were talking about... "

so that the actual name, for instance, could not be seen by search bots/spiders. This would add a certain safety to any posts that may contain names and such who's privacy is to be respected. I was thinking of using a base64 javascript function for this, would this be the best way to go?
Reply With Quote
  #4  
Old 12-09-2005, 12:00 PM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Impossible!

If it shows to the user, it is in the html source. You could however create 1 that would not display to guests.
Reply With Quote
  #5  
Old 12-09-2005, 12:35 PM
thalamus's Avatar
thalamus thalamus is offline
 
Join Date: Sep 2005
Location: UK
Posts: 66
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hmm - I think its possible by using javascript so that the view source would say something like:

""I spoke to <script type="javascript">document.write(base64_decode('gt Ydhjdjijrh8aeh'))</script> today and we were talking about... "

but I'm sure there's no such function built in... or am I wrong?
Reply With Quote
  #6  
Old 12-09-2005, 01:33 PM
sully02 sully02 is offline
 
Join Date: Jul 2004
Posts: 161
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by thalamus
hmm - I think its possible by using javascript so that the view source would say something like:

""I spoke to <script type="javascript">document.write(base64_decode('gt Ydhjdjijrh8aeh'))</script> today and we were talking about... "

but I'm sure there's no such function built in... or am I wrong?
I know there is a product/plugin here that obfuscates email addresses on the boards. Let me link you to that, perhaps you can work on that to get what you need...

https://vborg.vbsupport.ru/showthrea...ess+obfuscator
Reply With Quote
  #7  
Old 12-09-2005, 02:07 PM
thalamus's Avatar
thalamus thalamus is offline
 
Join Date: Sep 2005
Location: UK
Posts: 66
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for the link - I've had a look and it's not quite the solution I'm looking for. I'll have to see how I can get it to be set up within the class_bbcode.php and find the hooks that will be needed to parse it up. Looks like I'll have to use the php base64_encode() function within the parser, then use a javascript decode as document.write (as above) to reproduce the original text on the posts. I'll keep this thread posted as to my progress
Reply With Quote
  #8  
Old 12-11-2005, 07:35 AM
thalamus's Avatar
thalamus thalamus is offline
 
Join Date: Sep 2005
Location: UK
Posts: 66
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well for anyone who's interested, I managed to work this out although it meant adding code to two php files (class_bbcode.php and class_bbcode_alt.php) and adding a function to vbulletin_global.js.

Basically I'm using the php function base64_encode within the class_bbcode.php call when parsing the text for the tag, and returning a html string that contains a javascript call to a decode64 function that I've added to the .js file. Seems to work great, and the html return string can also have a 'span style=color:' tag to highlight the obfuscated word.

If anyone wants the code and instructions (I have no idea how to write it up as a plugin etc) let me know.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:06 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02550 seconds
  • Memory Usage 2,226KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (8)post_thanks_box
  • (8)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (8)post_thanks_postbit_info
  • (8)postbit
  • (8)postbit_onlinestatus
  • (8)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete