Skip to content

Commit

Permalink
url_decode license_key postbody template part if it starts with %
Browse files Browse the repository at this point in the history
  • Loading branch information
peak3d committed Mar 21, 2018
1 parent 622d59d commit 3b092d4
Show file tree
Hide file tree
Showing 5 changed files with 53 additions and 47 deletions.
90 changes: 45 additions & 45 deletions .travis.yml
@@ -1,45 +1,45 @@
language: cpp

#
# Define the build matrix
#
# Travis defaults to building on Ubuntu Precise when building on
# Linux. We need Trusty in order to get up to date versions of
# cmake and g++.
#
env:
global:
- app_id=inputstream.adaptive

matrix:
include:
- os: linux
dist: trusty
sudo: required
compiler: gcc
- os: linux
dist: trusty
sudo: required
compiler: clang
- os: osx
osx_image: xcode9.2

#
# Some of the OS X images don't have cmake, contrary to what people
# on the Internet say
#
before_install:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then which cmake || brew update ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then which cmake || brew install cmake ; fi

#
# The addon source is automatically checked out in $TRAVIS_BUILD_DIR,
# we'll put the Kodi source on the same level
#
before_script:
- cd $TRAVIS_BUILD_DIR/..
- git clone --depth=1 https://github.com/xbmc/xbmc.git -b master
- cd ${app_id} && mkdir build && cd build
- cmake -DADDONS_TO_BUILD=${app_id} -DADDON_SRC_PREFIX=$TRAVIS_BUILD_DIR/.. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=$TRAVIS_BUILD_DIR/../xbmc/addons -DPACKAGE_ZIP=1 $TRAVIS_BUILD_DIR/../xbmc/cmake/addons

script: make
language: cpp

#
# Define the build matrix
#
# Travis defaults to building on Ubuntu Precise when building on
# Linux. We need Trusty in order to get up to date versions of
# cmake and g++.
#
env:
global:
- app_id=inputstream.adaptive

matrix:
include:
- os: linux
dist: trusty
sudo: required
compiler: gcc
- os: linux
dist: trusty
sudo: required
compiler: clang
- os: osx
osx_image: xcode9.2

#
# Some of the OS X images don't have cmake, contrary to what people
# on the Internet say
#
before_install:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then which cmake || brew update ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then which cmake || brew install cmake ; fi

#
# The addon source is automatically checked out in $TRAVIS_BUILD_DIR,
# we'll put the Kodi source on the same level
#
before_script:
- cd $TRAVIS_BUILD_DIR/..
- git clone --depth=1 https://github.com/xbmc/xbmc.git -b master
- cd ${app_id} && mkdir build && cd build
- cmake -DADDONS_TO_BUILD=${app_id} -DADDON_SRC_PREFIX=$TRAVIS_BUILD_DIR/.. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=$TRAVIS_BUILD_DIR/../xbmc/addons -DPACKAGE_ZIP=1 $TRAVIS_BUILD_DIR/../xbmc/cmake/addons

script: make
2 changes: 1 addition & 1 deletion README.md
@@ -1,4 +1,4 @@
# inputstream.adaptive (2.2.6)
# inputstream.adaptive (2.2.7)

This is an adaptive file addon for kodi's new InputStream Interface.

Expand Down
2 changes: 1 addition & 1 deletion inputstream.adaptive/addon.xml.in
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<addon
id="inputstream.adaptive"
version="2.2.6"
version="2.2.7"
name="InputStream Adaptive"
provider-name="peak3d">
<requires>@ADDON_DEPENDS@</requires>
Expand Down
3 changes: 3 additions & 0 deletions wvdecrypter/wvdecrypter.cpp
Expand Up @@ -697,6 +697,9 @@ bool WV_CencSingleSampleDecrypter::SendSessionMessage()
//Process body
if (!blocks[2].empty())
{
if (blocks[2][0] == '%')
blocks[2] = url_decode(blocks[2]);

insPos = blocks[2].find("{SSM}");
if (insPos != std::string::npos)
{
Expand Down
3 changes: 3 additions & 0 deletions wvdecrypter/wvdecrypter_android.cpp
Expand Up @@ -515,6 +515,9 @@ bool WV_CencSingleSampleDecrypter::SendSessionMessage(AMediaDrmByteArray &sessio
//Process body
if (!blocks[2].empty())
{
if (blocks[2][0] == '%')
blocks[2] = url_decode(blocks[2]);

insPos = blocks[2].find("{SSM}");
if (insPos != std::string::npos)
{
Expand Down

0 comments on commit 3b092d4

Please sign in to comment.