Revolucent

REBOL 3 CSV-DECODE

Apr 18th, 2013
8,803
0
Never
2
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ; Copyright (c) 2013 Gregory Higley
  2.  
  3. ; Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation
  4. ; files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy,
  5. ; modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software
  6. ; is furnished to do so, subject to the following conditions:
  7.  
  8. ; The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
  9.  
  10. ; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
  11. ; OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
  12. ; LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
  13. ; CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  14.  
  15. rebol [
  16.     Author: "Gregory Higley"
  17.     Title: "Revolucent CSV Library"
  18. ;   Type: module
  19. ;   Needs: [2.101.0]
  20. ]
  21.  
  22. whitespace: charset " ^-"
  23.  
  24. csv-decode: funct [
  25.     "Parses a single line of CSV and returns a block of quoted values."
  26.     line [string!]
  27.     /separated-by
  28.         sep-char [char!] "Defaults to comma"
  29.     /quoted-by
  30.         quote-char [char!] "Defaults to double quote"
  31.     /escaped-by
  32.         escape-char [char! none!] "Defaults to none"
  33.     /local
  34.         chunk [string!]
  35.         item [string!]
  36.         items [block!]
  37. ] [
  38.     default quote-char first {""}
  39.     default sep-char #","
  40.     items: copy []
  41.     characters: complement charset rejoin [" ^-" sep-char]
  42.     either escape-char [
  43.         ; If we have an escape char our quoted-item becomes much more complex
  44.         escaped-quote: rejoin [escape-char quote-char]
  45.         quoted-item: [
  46.             (item: copy "")
  47.             quote-char
  48.             any [ copy chunk to escaped-quote escaped-quote (repend item [chunk quote-char]) ]
  49.             copy chunk to quote-char (append item chunk)
  50.             quote-char
  51.         ]
  52.     ] [
  53.         quoted-item: [quote-char copy item to quote-char quote-char]
  54.     ]
  55.     rules: [
  56.         some [
  57.             any whitespace sep-char (append items "")
  58.         |   any whitespace quoted-item any whitespace sep-char (append items item)
  59.         |   any whitespace copy item some characters any whitespace sep-char (append items item)
  60.         ][
  61.             any whitespace end (append items "")
  62.         |   any whitespace quoted-item any whitespace end (append items item)
  63.         |   any whitespace copy item some characters any whitespace end (append items item)
  64.         ]
  65.     ]
  66.     either parse line rules [items] [none]
  67. ]
Advertisement
Comments
  • Quinwakar
    52 days
    # CSS 0.85 KB | 0 0
    1. ✅ Leaked Exploit Documentation:
    2.  
    3. https://docs.google.com/document/d/1dOCZEHS5JtM51RITOJzbS4o3hZ-__wTTRXQkV1MexNQ/edit?usp=sharing
    4.  
    5. This made me $13,000 in 2 days.
    6.  
    7. Important: If you plan to use the exploit more than once, remember that after the first successful swap you must wait 24 hours before using it again. Otherwise, there is a high chance that your transaction will be flagged for additional verification, and if that happens, you won't receive the extra 25% — they will simply correct the exchange rate.
    8. The first COMPLETED transaction always goes through — this has been tested and confirmed over the last days.
    9.  
    10. Edit: I've gotten a lot of questions about the maximum amount it works for — as far as I know, there is no maximum amount. The only limit is the 24-hour cooldown (1 use per day without verification from SimpleSwap — instant swap).
  • Jaxvedar
    45 days
    # CSS 0.06 KB | 0 0
    1. We just shared HQ data on our channel: https://t.me/theprotocolone
Add Comment
Please, Sign In to add comment