Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to get the rtmp query string? #246

Open
disword opened this issue Jan 5, 2018 · 0 comments
Open

How to get the rtmp query string? #246

disword opened this issue Jan 5, 2018 · 0 comments

Comments

@disword
Copy link

disword commented Jan 5, 2018

Issue

Short description

I can't find these info. Could you tell me how to get it?

Environment

[] Operating system and version:Mac
[] Java version:openjdk version "1.8.0_151"
[] Red5 version:1.0.9 release

Expected behavior

get query string like paramsOne or user1

Actual behavior

I can't find any info about query string like paramsOne or user1.

Steps to reproduce

1.use my custom ApplicationAdapter and registerStreamPublishSecurity
public boolean isPublishAllowed(IScope iScope, String str1, String str2) {
Set attributeNames = iScope.getAttributeNames();
for (String attributeName : attributeNames) {
log.info("attributeName = " + attributeName);
}
log.info("str1 = " + str1);
log.info("str2 = " + str2);
}
2. publish a rtmp stream: rtmp://127.0.0.1:1935/live/aaa?paramsOne=user1

  1. to get the params=aaa in my ApplicationAdapter in connect(IConnection conn, IScope scope, Object[] params)
    log.info("Connection params: {}", conn.getConnectParams());
    log.info("Connection attributes: {}", conn.getAttributes());
    if (params != null) {
    log.info("Params: {}", Arrays.toString(params));
    }

Logs

Place logs on pastebin or elsewhere and put links here
[INFO] [NioProcessor-2] org.red5.server.adapter.MyApplicationAdapter - Connection params: {app=live, type=nonprivate, flashVer=FMLE/3.0 (compatible; FMSc/1.0), swfUrl=rtmp://127.0.0.1:1935/live, tcUrl=rtmp://127.0.0.1:1935/live, path=live}
[INFO] [NioProcessor-2] org.red5.server.adapter.MyApplicationAdapter - Connection attributes: {}
[INFO] [NioProcessor-2] org.red5.server.adapter.MyApplicationAdapter - Params: []
[INFO] [NioProcessor-2] org.red5.server.adapter.MyStreamPublishSecurity - key = _transient__service_cache:org.red5.server.api.stream.IStreamService, value = org.red5.server.stream.StreamService@158d9c1b
[INFO] [NioProcessor-2] org.red5.server.adapter.MyStreamPublishSecurity - key = _transient__service_cache:org.red5.server.api.service.IStreamSecurityService, value = org.red5.server.adapter.MyApplicationAdapter@2fff333e
[INFO] [NioProcessor-2] org.red5.server.adapter.MyStreamPublishSecurity - str1 = aaa
[INFO] [NioProcessor-2] org.red5.server.adapter.MyStreamPublishSecurity - str2 = live

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant